/* About: hero. Owned by the About hero section agent (About page 100x work, 2026-09-24).

   The homepage's family, not a copy of it. One photograph is the whole background and the words sit on
   the left over a soft frosted haze. Where the homepage shows the surgeon in scrubs, this shows the man:
   round 2 (2026-10-24) is Kien's June 2026 portrait in the surgical lab at the Seattle Science
   Foundation, smiling, hands in the pockets of a white coat with my name on it (source 086). Round 1,
   the green jacket, is in tools/photos-2026/snapshot/.

   Two registered plates, built by tools/photos-2026/build_plates.py: the room with me removed, extended
   to the left into defocused wall, and me with an alpha matte. The haze sits between them, so it softens
   the room and never me. hero.js parts them a few pixels under the pointer and on scroll.

   Geometry. The plates are 2240 x 1008, anchored right top, and bleed 3 percent past the frame. My body
   starts 864 canvas pixels from the right edge; with the bleed that is the width plus 3 percent less
   0.909 of the frame's height, or 62 percent of the width when the frame is wider than the canvas.
   --about-hero-body holds that line; the haze fades out and the words stop short of it.

   Below 1100px the phone crop stacks on top and the words sit on a frosted panel over its lower edge,
   as on the homepage. */

.about-hero {
  --about-hero-ease: cubic-bezier(0.28, 0.11, 0.32, 1);
  --about-hero-h: clamp(520px, calc(100vw / 1.62), calc(100svh - var(--nav-h) - 2.5rem));
  --about-hero-body: min(62%, calc(103% - var(--about-hero-h) * 0.909));
  padding-top: var(--nav-h);
  background: var(--paper);
}
.about-hero-frame {
  position: relative; isolation: isolate; overflow: hidden;
  height: var(--about-hero-h);
  background: var(--mist-2);               /* the wall's tone, while the photograph decodes */
}
.about-hero-stage { position: absolute; inset: 0; }
.about-hero-plate { position: absolute; inset: -3%; display: block; will-change: transform; }
.about-hero-pic { position: absolute; inset: 0; display: block; }
.about-hero-img {
  display: block; width: 100%; height: 100%;
  object-fit: cover; object-position: right top;
}
.about-hero-room { z-index: 0; transform-origin: 62% 30%; }
.about-hero-me { z-index: 2; transform-origin: 65% 24%; }   /* my face: the arrival and the scroll close on it */

/* the frosted haze under the words: strongest at the left edge, gone before his sleeve */
.about-hero-veil {
  position: absolute; z-index: 1; inset: 0 auto 0 0; pointer-events: none;
  width: calc(var(--about-hero-body) - 1.5vw);
  /* two layers: the haze fading toward him, and a lift over the tables at the foot of the frame, which
     are the busiest thing under the facts */
  background:
    linear-gradient(0deg,
      color-mix(in srgb, var(--mist) 62%, transparent) 0%,
      color-mix(in srgb, var(--mist) 44%, transparent) 26%,
      color-mix(in srgb, var(--mist) 0%, transparent) 52%),
    linear-gradient(90deg,
      color-mix(in srgb, var(--mist) 72%, transparent) 0%,
      color-mix(in srgb, var(--mist) 52%, transparent) 55%,
      color-mix(in srgb, var(--mist) 0%, transparent) 100%);
  -webkit-backdrop-filter: blur(14px) saturate(1.05);
  backdrop-filter: blur(14px) saturate(1.05);
  -webkit-mask-image: linear-gradient(90deg, #000 70%, transparent 100%);
  mask-image: linear-gradient(90deg, #000 70%, transparent 100%);
}

.about-hero-copy {
  position: absolute; z-index: 3; left: var(--gutter); top: 48%; translate: 0 -50%;
  width: calc(var(--about-hero-body) - var(--gutter) - 3.5vw);
}
.about-hero-title {
  font-family: var(--display); font-weight: 700;
  font-size: clamp(2.5rem, 3.85vw, 5.1rem); line-height: 1.02; letter-spacing: -0.022em;
  color: var(--ink);
}
/* each sentence starts its own line: "In Seattle since 1990." never dangles after "Dallas." */
.about-hero-line { display: block; text-wrap: balance; }
.about-hero-lede {
  margin-top: 1.35rem; max-width: 45ch;
  font-size: clamp(1.02rem, 1.12vw, 1.25rem); line-height: 1.6; color: var(--ink-2);
}

/* ---------- the three facts: one big mark each, a short label under it ---------- */
.about-hero-facts {
  position: relative; list-style: none; margin: 2.3rem 0 0; padding: 1.35rem 0 0;
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); column-gap: clamp(1.4rem, 2.4vw, 2.8rem);
  align-items: start; max-width: 32rem;
}
/* a hairline over the row, drawn left to right on arrival */
.about-hero-facts::before {
  content: ''; position: absolute; left: 0; right: 0; top: 0; height: 1px;
  background: var(--line-2); transform-origin: left center;
}
.about-hero-fact {
  display: flex; flex-direction: column; gap: 0.55rem; max-width: 11.5em;
  transition: opacity 0.45s var(--about-hero-ease), translate 0.45s var(--about-hero-ease);
}
.about-hero-big {
  font-family: var(--display); font-weight: 600;
  font-size: clamp(2.1rem, 2.75vw, 3.3rem); line-height: 1; letter-spacing: -0.02em;
  font-variant-numeric: lining-nums tabular-nums; color: var(--ink);
  transition: color 0.45s var(--about-hero-ease);
}
.about-hero-label {
  font-family: var(--label); font-weight: 500; font-size: 0.92rem; line-height: 1.32;
  color: var(--ink-2); letter-spacing: 0.005em;
}

/* 1993: the board's full name takes the label's place on hover, never instead of it at rest */
.about-hero-fact--cert .about-hero-label { display: grid; }
.about-hero-rest, .about-hero-more {
  grid-area: 1 / 1;
  transition: opacity 0.45s var(--about-hero-ease), translate 0.45s var(--about-hero-ease), filter 0.45s var(--about-hero-ease);
}
.about-hero-more { opacity: 0; translate: 0 6px; filter: blur(3px); color: var(--accent-deep); }
/* read aloud between the two, never seen */
.about-hero-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

/* Hello, Hallo: one letter apart. The word arrives in German and settles into English; pointing at it
   brings the German back. The two vowels share one slot. */
.about-hero-hello { white-space: nowrap; }
.about-hero-vowel { position: relative; display: inline-block; }
.about-hero-e, .about-hero-a {
  display: inline-block;
  transition: opacity 0.5s var(--about-hero-ease), translate 0.5s var(--about-hero-ease), filter 0.5s var(--about-hero-ease);
}
.about-hero-a { position: absolute; left: 50%; top: 0; translate: -50% 0.42em; opacity: 0; filter: blur(4px); }

@media (hover: hover) and (pointer: fine) {
  .about-hero-facts:has(.about-hero-fact:hover) .about-hero-fact:not(:hover) { opacity: 0.55; }
  .about-hero-fact:hover { translate: 0 -3px; }
  .about-hero-fact:hover .about-hero-big { color: var(--accent); }
  .about-hero-fact--cert:hover .about-hero-rest { opacity: 0; translate: 0 -6px; filter: blur(3px); }
  .about-hero-fact--cert:hover .about-hero-more { opacity: 1; translate: 0 0; filter: blur(0); }
  .about-hero-fact--speaks:hover .about-hero-e { opacity: 0; translate: 0 -0.42em; filter: blur(4px); }
  .about-hero-fact--speaks:hover .about-hero-a { opacity: 1; translate: -50% 0; filter: blur(0); }
}

/* ---------- arrival ----------
   The room settles in sharp, then the focus racks onto me, the haze clears in, the words rise out of a
   short blur one after another, the hairline draws, and the greeting turns from German into English. */
@media (prefers-reduced-motion: no-preference) {
  .about-hero-room { animation: about-hero-settle 1.9s var(--about-hero-ease) both; }
  .about-hero-me { animation: about-hero-focus 1.7s var(--about-hero-ease) 0.2s both; }
  .about-hero-veil { animation: about-hero-fade 1.2s var(--about-hero-ease) 0.25s both; }
  .about-hero-line, .about-hero-lede {
    animation: about-hero-rise 1s var(--about-hero-ease) both;
    animation-delay: calc(0.3s + var(--i, 0) * 0.11s);
  }
  .about-hero-fact {
    animation: about-hero-rise 0.9s var(--about-hero-ease) backwards;
    animation-delay: calc(0.45s + var(--i, 0) * 0.1s);
  }
  .about-hero-facts::before { animation: about-hero-draw 1.1s var(--about-hero-ease) 0.7s backwards; }
  .about-hero-e { animation: about-hero-in 0.6s var(--about-hero-ease) 2.8s backwards; }
  .about-hero-a { animation: about-hero-out 0.6s var(--about-hero-ease) 2.8s backwards; }
}
/* the focus lands on me by about 1.2s, as the headline arrives; the settle runs on after */
@keyframes about-hero-settle { from { opacity: 0; transform: scale(1.06); } 30% { opacity: 1; } to { opacity: 1; transform: none; } }
@keyframes about-hero-focus {
  from { opacity: 0; filter: blur(14px); transform: scale(1.06); }
  30% { opacity: 1; }
  58% { filter: blur(0.4px); }
  to { opacity: 1; filter: blur(0); transform: none; }
}
@keyframes about-hero-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes about-hero-rise { from { opacity: 0; translate: 0 18px; filter: blur(6px); } to { opacity: 1; translate: 0 0; filter: blur(0); } }
@keyframes about-hero-draw { from { transform: scaleX(0); } to { transform: scaleX(1); } }
@keyframes about-hero-in { from { opacity: 0; translate: 0 0.42em; filter: blur(4px); } to { opacity: 1; translate: 0 0; filter: blur(0); } }
@keyframes about-hero-out { from { opacity: 1; translate: -50% 0; filter: blur(0); } to { opacity: 0; translate: -50% -0.42em; filter: blur(4px); } }

/* ---------- tablets and phones: the photograph on top, the words on a frosted panel ---------- */
@media (max-width: 1099px) {
  .about-hero-frame { height: auto; overflow: visible; background: none; }
  .about-hero-stage {
    position: relative; inset: auto; overflow: hidden; background: var(--mist-2);
    aspect-ratio: 1000 / 1008; max-height: calc(100svh - var(--nav-h) - 7rem); width: 100%;
  }
  .about-hero-plate { inset: 0; }
  .about-hero-img { object-position: center top; }
  .about-hero-me { transform-origin: 50% 24%; }
  .about-hero-veil { display: none; }
  .about-hero-copy {
    position: relative; left: auto; top: auto; translate: none; width: auto;
    margin: -3.4rem var(--gutter) 0; padding: 1.7rem 1.5rem 1.8rem;
    background: color-mix(in srgb, var(--paper) 78%, transparent);
    -webkit-backdrop-filter: blur(18px) saturate(1.15);
    backdrop-filter: blur(18px) saturate(1.15);
    border: 1px solid color-mix(in srgb, var(--paper) 75%, transparent); border-radius: 18px;
    box-shadow: var(--shadow-2);
  }
  .about-hero-title { font-size: clamp(2.1rem, 6.4vw, 3.4rem); }
  .about-hero-lede { font-size: 1.02rem; }
  .about-hero-facts { grid-template-columns: repeat(3, minmax(0, max-content)); column-gap: clamp(1.1rem, 4vw, 2.4rem); }
}
/* narrow phones: the facts become three rows, the mark on the left and its label beside it */
@media (max-width: 560px) {
  .about-hero-facts { grid-template-columns: 1fr; row-gap: 1rem; margin-top: 1.8rem; padding-top: 1.2rem; }
  .about-hero-fact {
    display: grid; grid-template-columns: 5.4rem minmax(0, 1fr); align-items: center; column-gap: 1rem;
    max-width: none;
  }
  .about-hero-big { font-size: 1.95rem; }
  .about-hero-label { font-size: 0.92rem; }
}
