.profile {
  --profile-gutter: clamp(24px,5vw,96px);
  --profile-gap: clamp(40px,6.5vw,112px);
  background: var(--cream);
}
.profile-wrap { width: min(1440px,calc(100% - 2 * var(--profile-gutter))); margin-inline: auto; }
.profile-hero { padding-block: clamp(60px,5.75vw,92px) clamp(75px,8vw,120px); overflow: clip; }
.profile-hero-layout { display: grid; grid-template-columns: minmax(0,.85fr) minmax(0,1.15fr); gap: clamp(35px,4vw,60px) var(--profile-gap); align-items: center; }
.profile-hero-copy { position: relative; z-index: 2; grid-column: 2; grid-row: 2; }
.profile-hero h1 { grid-column: 1 / -1; font: 400 clamp(40px,4.35vw,70px)/1.06 Retro,Georgia,serif; letter-spacing: -.045em; }
.profile-hero h1 > :is(span,em) { display: block; font: inherit; text-wrap: pretty; }
.profile-hero h1 em { font-family: Groovy,Georgia,serif; font-size: .9em; margin-top: .18em; }
.profile-hero h1 .profile-title-line { font: inherit; }
.profile-intro-statement { margin-top: 0; font-size: clamp(23px,1.95vw,28px); line-height: 1.45; letter-spacing: -.025em; font-weight: 500; text-wrap: pretty; }
.profile-intro-bio { margin-top: 30px; font-size: clamp(17px,1.4vw,21px); line-height: 1.7; }
.profile-intro-statement,.profile-intro-bio,.profile-chapter-copy p {
  text-align: var(--copy-alignment,justify); text-align-last: start; hyphens: var(--copy-hyphens,auto); hyphenate-limit-chars: 8 3 3;
}
.profile-portrait-stack { width: 88%; max-width: 360px; grid-column: 1; grid-row: 2; justify-self: start; }
.profile-photo { aspect-ratio: 1122 / 1402; border-radius: 7px; overflow: hidden; background: var(--peach); }
.profile-photo picture,.profile-photo img { width: 100%; height: 100%; display: block; }
.profile-photo img { object-fit: cover; }

.profile-scenes { position: relative; }
.profile-scene { position: relative; padding-block: clamp(65px,7vw,110px); overflow: clip; background: var(--cream); }
.profile-scene--peach { background: var(--peach); }
.profile-scene-layout { display: grid; grid-template-columns: minmax(0,.9fr) minmax(0,1.3fr); gap: var(--profile-gap); align-items: center; }
#pourquoi-ce-metier .profile-scene-layout { grid-template-columns: minmax(0,1.3fr) minmax(0,.9fr); }
#pourquoi-ce-metier .profile-scene-aside { order: 2; position: relative; }
.profile-scene h2 { font: 400 clamp(38px,4.5vw,70px)/1.04 Retro,Georgia,serif; letter-spacing: -.045em; text-wrap: balance; }
.profile-chapter-copy p { font-size: clamp(17px,1.35vw,20px); line-height: 1.65; }
.profile-chapter-copy p+p { margin-top: 1.05em; }
#regard-parcours .profile-chapter-copy {
  position: relative;
  inset-block-start: clamp(-40px, calc((680px - 100svh) * .3), -10px);
}
.profile-pictogram { position: relative; width: min(100%,260px); aspect-ratio: 320 / 220; margin-top: clamp(24px,3vw,38px); color: var(--prune); }
.profile-pictogram > svg { width: 100%; height: 100%; overflow: visible; }
.profile-pictogram-bird { position: absolute; width: 44%; right: 8%; top: 7%; }
.profile-pictogram-bird .bird { width: 100%; height: auto; }
.profile-thread { width: min(100%,420px); aspect-ratio: 760 / 360; margin-top: 22px; pointer-events: none; }
.profile-thread svg { width: 100%; height: 100%; display: block; }

#ma-facon-de-travailler .profile-scene-layout {
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.06fr);
  column-gap: clamp(36px, 5.5vw, 90px);
}
.profile-idea-art {
  width: min(92%, 575px);
  height: auto;
  margin-block-start: clamp(16px, 2vw, 26px);
}

/* Full viewport scenes uncover each other. Text has no translation,
   opacity tween or letter animation. */
.profile-scenes.is-immersive { height: 100svh; isolation: isolate; }
.is-immersive .profile-scene { position: absolute; inset: 0; display: grid; align-items: center; padding-block: calc(var(--header-offset) + 26px) 40px; }
.is-immersive .profile-scene-layout { align-self: center; }
.is-immersive .profile-scene:nth-child(2) { z-index: 1; }
.is-immersive .profile-scene:nth-child(3) { z-index: 2; }
.is-immersive .profile-scene + .profile-scene { will-change: clip-path; }

/* Keep the curved join in the normal reading flow on shorter screens. */
.profile-scene--peach + .profile-scene { --profile-previous-paper: var(--peach); }
.is-in-flow .profile-scene::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 64px;
  background: var(--profile-previous-paper, var(--cream));
  clip-path: ellipse(100% var(--profile-curve-depth, 0px) at 50% 0);
  pointer-events: none;
}
.is-in-flow .profile-scene-layout { position: relative; }

@media (min-width:800px) and (max-width:1100px) {
  .profile { --profile-gutter: 38px; --profile-gap: 42px; }
  .profile-hero h1 { font-size: 43px; }
  .profile-scene-layout { grid-template-columns: minmax(0,.72fr) minmax(0,1.3fr); }
  #pourquoi-ce-metier .profile-scene-layout { grid-template-columns: minmax(0,1.3fr) minmax(0,.72fr); }
  .profile-scene h2 { font-size: 41px; }
  .profile-chapter-copy p { font-size: 17px; line-height: 1.58; }
}
@media (min-width: 800px) and (max-width: 960px) {
  #about-parcours-title { font-size: clamp(33px,calc(5vw - 7px),41px); }
}
@media screen and (max-width: 799px),
       screen and (max-width: 960px) and (pointer: coarse),
       screen and (max-width: 960px) and (max-height: 500px) {
  .profile-hero h1 em { font-size: inherit; margin-top: 0; }
  .profile-title-line { display: block; white-space: nowrap; }
}
@media (max-width:799px) {
  .profile { --profile-gap: 32px; }
  .profile-hero { padding-block: 52px 72px; }
  .profile-hero-layout { grid-template-columns: minmax(0,1fr); container-type: inline-size; }
  .profile-hero-copy { grid-column: 1; grid-row: 3; }
  /* Size all four lines to fit the longest phrase. */
  .profile-hero h1 { font-size: min(56px,7.8cqw); }
  .profile-portrait-stack { width: min(76%,320px); justify-self: center; margin-top: 8px; }
  .profile-intro-statement { font-size: 21px; }
  .profile-intro-bio { font-size: 17px; }
  .profile-scene-layout,#pourquoi-ce-metier .profile-scene-layout { grid-template-columns: minmax(0,1fr); max-width: 580px; gap: 28px; }
  .profile-scene-aside { display: contents; }
  .profile-scene h2 { order: 0; font-size: clamp(34px,7.5vw,52px); text-wrap: pretty; }
  .profile-chapter-copy { order: 1; }
  #regard-parcours .profile-chapter-copy { inset-block-start: -10px; }
  .profile-pictogram,.profile-thread { order: 2; }
  .profile-pictogram { width: min(76%,240px); margin-top: 8px; }
  .profile-pictogram--flight {
    justify-self: center;
    /* Center the bird, whose trail extends to the left. */
    translate: -20% 0;
  }
  #ma-facon-de-travailler .profile-scene-layout {
    grid-template-columns: minmax(0, 1fr);
    gap: 24px;
  }
  .profile-idea-art {
    order: 1;
    justify-self: center;
    width: min(94%, 440px);
    margin-block-start: 0;
  }
  #ma-facon-de-travailler .profile-chapter-copy { order: 2; }
  #pourquoi-ce-metier .profile-scene-aside { display: block; order: 0; }
  .profile-thread { width: 100%; max-width: 320px; margin-block: 22px 0; }
}
@media (min-width:800px) and (max-height:800px) {
  .is-immersive .profile-scene { padding-block: calc(var(--header-offset) + 16px) 24px; }
  .is-immersive .profile-chapter-copy p { line-height: 1.55; }
  .is-immersive .profile-chapter-copy p+p { margin-top: .8em; }
  .is-immersive .profile-scene h2 { font-size: clamp(38px,4.1vw,58px); }
  .is-immersive .profile-pictogram { max-width: 230px; }
}
@media print {
  .profile-scenes.is-immersive { height: auto !important; transform: none !important; position: static !important; }
  .profile .pin-spacer { height: auto !important; padding: 0 !important; }
  .profile .profile-scene { position: relative !important; clip-path: none !important; height: auto !important; opacity: 1 !important; }
  .profile-scene-layout { transform: none !important; opacity: 1 !important; }
  .is-in-flow .profile-scene::before { display: none; }
}

