/* Each projection retains its own aspect ratio, scale and exposure. */
.hero-ambient {
  position:absolute; inset:0; pointer-events:none; z-index:0;
}
.hero-ambient-layer {
  position:absolute; left:50%; top:var(--hero-stage-center);
  width:var(--ambient-width,850px); aspect-ratio:var(--ambient-ratio,1.733);
  transform:translate(-50%,-50%); opacity:0;
  transition:opacity 850ms ease-in-out;
  -webkit-mask-image:var(--ambient-mask);
  mask-image:var(--ambient-mask);
  -webkit-mask-size:100% 100%; mask-size:100% 100%;
}
.hero-ambient-layer.is-visible { opacity:min(1,calc(var(--ambient-strength,.4) * var(--ambient-opacity,1.414))); }
.hero-ambient-layer[data-framing="wide"] {
  -webkit-mask-image:var(--ambient-mask-wide);
  mask-image:var(--ambient-mask-wide);
}
.hero-ambient-layer img,
.hero-ambient-layer video {
  display: block; width: 100%; height: 100%; object-fit: contain;
  filter:saturate(.88) brightness(calc(var(--ambient-exposure,1) * var(--ambient-light,1.57)));
}
.hero-particles { z-index: 1; }
.hero { min-height:720px; --hero-stage-center:calc((100% - 300px)/2 + 20px); }
.hero-content { isolation:isolate; position:absolute; left:50%; top:var(--hero-stage-center); transform:translate(-50%,-50%); width:calc(100% - 48px); max-width:1200px; }
.hero-scroll { bottom:25px; }
.hero-scroll span { display:none; }
.hero-content::before {
  content:''; position:absolute; inset:-22px -70px; z-index:-1; pointer-events:none;
  background:radial-gradient(ellipse at center,rgba(10,10,15,.5) 12%,rgba(10,10,15,.2) 45%,transparent 73%);
}
.hero-name { filter:drop-shadow(0 2px 5px #000b); }
.hero-alias { color:#c4bdd0; text-shadow:0 2px 7px #000; }
.hero-tagline { color:#d9d3e2; text-shadow:0 2px 7px #000; }
.hero-project-dock {
  position:absolute; left:50%; bottom:82px; transform:translateX(-50%);
  width:min(calc(100% - 64px),1080px); z-index:4;
  display:flex; flex-direction:column; gap:24px;
}
.hero-projects {
  position:relative; display:flex; gap:16px; justify-content:center;
  align-items:flex-start; padding-left:120px;
}
.hero-projects-label {
  position:absolute; left:0; top:28px; width:105px; text-align:right;
  color:#aaa2b5; text-transform:uppercase; letter-spacing:.16em; font-size:10px;
}
.hero-projects a {
  display:flex; flex-direction:column; align-items:center; gap:7px;
  width:112px; min-width:0; color:#9490a2; font-size:11px; line-height:1.35; text-align:center;
  transition:color .25s;
}
.hero-project-thumb {
  width:clamp(52px,7vh,72px); aspect-ratio:1; flex-shrink:0; padding:4px;
  border:1px solid #ffffff20; border-radius:50%; background:#ffffff03;
  transition:border-color .3s,box-shadow .3s,transform .3s;
}
.hero-project-thumb img { width:100%; height:100%; object-fit:cover; border-radius:50%; opacity:.76; transition:opacity .3s; }
.hero-projects a[data-project="4"] img { object-position:center; }
.hero-projects a:hover,.hero-projects a:focus-visible,.hero-projects a[aria-current="true"] { color:#e3daea; }
.hero-projects a[aria-current="true"] .hero-project-thumb { border-color:#d8a2bb; box-shadow:0 0 0 4px #d8a2bb09,0 0 20px #d8a2bb15; }
.hero-projects a:hover .hero-project-thumb { transform:scale(1.07); border-color:#cab5df; }
.hero-projects a:focus-visible { outline:none; }
.hero-projects a:focus-visible .hero-project-thumb { outline:2px solid #cab5df; outline-offset:4px; }
.hero-projects a:hover img,.hero-projects a[aria-current="true"] img { opacity:1; }
.featured-card[id] { scroll-margin-top:100px; }
.hero-ambient-toggle {
  position: absolute; right: 28px; bottom: 30px; z-index: 3;
  width: 34px; height: 34px; padding: 7px;
  border: 1px solid rgba(136,136,160,.2); border-radius: 50%;
  background: transparent; color: var(--text-muted);
  cursor: pointer; transition: color .2s, border-color .2s;
}
.hero-ambient-toggle[hidden] { display: none; }
.hero-ambient-toggle:hover { color: var(--text-secondary); border-color: var(--text-secondary); }
.hero-ambient-toggle svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.4; }
.hero-ambient-toggle .ambient-play { display: none; }
.hero-ambient-toggle[aria-pressed="true"] .ambient-pause { display: none; }
.hero-ambient-toggle[aria-pressed="true"] .ambient-play { display: block; }
.hero-tuning { position:absolute; right:76px; bottom:30px; z-index:5; color:#d7d2e0; font-size:12px; }
.hero-tuning[hidden] { display:none; }
.hero-tuning summary { cursor:pointer; list-style:none; padding:7px 13px; border:1px solid #ffffff26; border-radius:20px; background:#121218b3; }
.hero-tuning summary::-webkit-details-marker { display:none; }
.hero-tuning[open] summary { border-color:#c5a4c5; }
.hero-tuning-panel { position:absolute; right:0; bottom:46px; width:270px; max-width:calc(100vw - 40px); padding:20px; border:1px solid #ffffff23; border-radius:18px; background:#14141deb; backdrop-filter:blur(20px); box-shadow:0 14px 60px #0005; }
.hero-tuning label { display:flex; justify-content:space-between; gap:16px; margin-bottom:6px; }
.hero-tuning output { color:#e3b4cc; font-variant-numeric:tabular-nums; }
.hero-tuning input { width:100%; accent-color:#d3a0c3; margin:0 0 16px; cursor:ew-resize; }
.hero-tuning select { width:100%; margin:0 0 16px; padding:7px; color:#e5dfea; background:#24212c; border:1px solid #ffffff25; border-radius:7px; font:inherit; }
.hero-tuning p { margin:0 0 14px; color:#9f99ae; font-size:11px; line-height:1.7; }
.hero-tuning button { border:1px solid #ffffff25; padding:5px 9px; border-radius:7px; background:transparent; color:inherit; font:inherit; cursor:pointer; }
#ambientSaveStatus { margin-left:8px; font-size:10px; color:#9f99ae; }
#research-lrm .featured-video,#research-vln .featured-video { object-fit:contain; }
.supplied-project .featured-image,.supplied-project .featured-video { object-fit:contain; }
@media (min-width:900px) and (max-height:760px) {
  .hero-project-dock { gap:18px; bottom:70px; }
  .hero-project-thumb { width:50px; }
  .hero-projects-label { top:20px; }
  .hero-name { font-size:72px; }
}
@media (max-width:899px) {
  .hero { min-height:760px; --hero-stage-center:calc((100% - 330px)/2 + 15px); }
  .hero-project-dock { width:calc(100% - 28px); bottom:96px; gap:38px; }
  .hero-projects { padding-left:0; gap:8px; }
  .hero-projects-label { top:-23px; left:0; width:auto; text-align:left; font-size:8px; }
  .hero-projects a { width:calc((100% - 48px)/7); font-size:9px; gap:7px; }
  .hero-project-thumb { width:clamp(39px,7.4vw,62px); padding:3px; }
  .hero-content { width:calc(100% - 28px); }
  .hero-ambient-toggle { right:18px; bottom:25px; }
  .hero-tuning { right:64px; bottom:25px; }
  .hero-content::before { inset:-22px -20px; }
}
@media (max-width:600px) {
  .hero-name { font-size:clamp(42px,8vw,48px); }
  .hero-tagline { font-size:16px; }
}
@media (prefers-reduced-motion: reduce) {
  .hero-ambient-layer { transition: none; }
}

/* Small section markers keep the existing research-card rhythm. */
.featured-group-title {
  display:flex; align-items:center; gap:20px; margin:0;
  font-size:15px; font-weight:500; letter-spacing:.12em;
  color:var(--text-secondary);
}
.featured-group-title::after { content:''; flex:1; height:1px; background:var(--border-card); }
.featured-card + .featured-group-title { margin-top:28px; }
.about-text .career-path { display:flex; flex-wrap:wrap; align-items:baseline; gap:8px 12px; color:var(--text-primary); font-weight:400; }
.career-path > span:not(.career-arrow) { white-space:nowrap; }
.career-path .career-arrow { color:inherit; }
.career-path small { font-size:.8em; color:inherit; }
