/* A fixed professional position lets the work carry the motion and detail. */
@font-face {
  font-family: "Anton";
  src: url("/Resources/Fonts/Anton-Regular.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

[data-hero-active="true"] .site-header {
  background: var(--ink);
  color: var(--hero-yellow);
}
[data-hero-active="true"] .site-header .page-progress { opacity: 0; }
.site-header .wordmark,
.site-header .main-nav { font-family: var(--body); }

.marquee-hero {
  display: flex;
  align-items: center;
  min-height: max(540px, calc(100svh - var(--header-height) - 32px));
  padding: clamp(52px, 8vh, 108px) var(--gutter) clamp(28px, 5vh, 56px);
  background: var(--ink);
  color: var(--hero-yellow);
}
.hero-content { display: flex; flex-direction: column; justify-content: center; width: 100%; min-width: 0; }
.hero-main {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(235px, .3fr);
  align-items: end;
  gap: clamp(24px, 5vw, 84px);
  width: 100%;
}
.hero-position {
  margin: 0;
  color: var(--hero-yellow);
  font: 400 clamp(6rem, 13vw, 15rem)/.91 "Anton", Impact, "Arial Narrow", sans-serif;
  letter-spacing: -.035em;
  text-transform: uppercase;
}
.hero-position span { display: block; }
.hero-aside { padding-bottom: .45em; font-family: var(--body); }
.hero-roles {
  margin: 0 0 clamp(32px, 5vw, 72px);
  color: #efeee7;
  font-size: clamp(1.15rem, 1.8vw, 1.55rem);
  line-height: 1.3;
  letter-spacing: -.02em;
}
.hero-current { display: grid; gap: 6px; margin: 0; font-size: 1rem; line-height: 1.4; }
.hero-current span { color: #aaa99c; font-size: .78rem; text-transform: uppercase; letter-spacing: .04em; }
.hero-current a { width: fit-content; color: var(--hero-yellow); border-bottom: 1px solid currentColor; }
.hero-current a:hover { color: #fff; }
.marquee-hero :focus-visible { outline: 2px solid #fff; outline-offset: 4px; }

@keyframes hero-line-in {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: none; }
}
[data-intro="complete"] .hero-position span:first-child { animation: hero-line-in .42s .02s both; }
[data-intro="complete"] .hero-position span:last-child { animation: hero-line-in .42s .11s both; }
[data-intro="complete"] .hero-aside { animation: hero-line-in .45s .18s both; }

@media (max-width: 1050px) {
  .hero-main { grid-template-columns: minmax(0, 1fr); gap: clamp(36px, 5vh, 62px); }
  .hero-position { font-size: clamp(5.75rem, 16vw, 11rem); }
  .hero-aside { display: flex; align-items: end; justify-content: space-between; gap: 24px; padding: 0; }
  .hero-roles { margin: 0; }
}
@media (max-width: 620px) {
  .marquee-hero { min-height: max(560px, calc(100svh - var(--header-height) - 24px)); padding-top: 48px; }
  .hero-position { font-size: clamp(4.8rem, 17vw, 7.5rem); }
  .hero-aside { align-items: start; }
  .hero-roles { font-size: 1.05rem; }
  .hero-current { font-size: .95rem; }
}
@media (max-width: 390px) {
  .hero-aside { flex-direction: column; gap: 22px; }
  .hero-current { display: block; }
  .hero-current span { display: block; margin-bottom: 5px; }
}
@media (prefers-reduced-motion: reduce) {
  .hero-position span, .hero-aside { animation: none !important; }
}

/* One role at a time, with direct controls and a readable proof panel. */
.role-home { align-items: center; }
.role-intro { margin: 0 0 clamp(30px, 5vw, 70px); font: 400 .9rem/1.5 var(--body); }
.role-intro span { display: inline-block; margin-left: 1em; }
.role-layout { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(280px, .85fr); gap: clamp(32px, 5vw, 80px); align-items: center; min-height: clamp(280px, 34vw, 480px); }
.role-choices { min-width: 0; }
.role-choice { display: flex; flex-direction: column; align-items: flex-start; gap: clamp(14px, 2vw, 28px); width: 100%; text-align: left; padding: 0; border: 0; background: transparent; color: var(--hero-yellow); cursor: pointer; }
.role-choice[hidden], .role-panel[hidden] { display: none; }
.role-index { font: .86rem/1.4 var(--body); }
.role-label { display: block; max-width: 12ch; font: 400 clamp(70px, 9.2vw, 164px)/.96 "Anton", Impact, sans-serif; text-transform: uppercase; letter-spacing: -.035em; overflow-wrap: normal; }
[data-enhanced="true"] .role-choice:not([hidden]) .role-label { animation: role-type-in .62s cubic-bezier(.16,1,.3,1) both; }
.role-details { min-width: 0; }
.role-panel h2 { margin: 0 0 20px; font: 400 1rem/1.4 var(--body); }
.role-panel p { margin: 0; max-width: 25ch; font: 400 clamp(23px, 2.2vw, 36px)/1.3 var(--body); letter-spacing: -.025em; }
.role-panel ul { list-style: none; padding: 0; margin: 32px 0 0; }
.role-panel li { border-top: 1px solid currentColor; }
.role-panel a { display: grid; gap: 6px; padding: 14px 0; color: inherit; font: .83rem/1.4 var(--body); }
.role-panel a strong { font-size: 1.1rem; }
.role-panel a:hover strong { text-decoration: underline; }
.role-link-label { font-size: .72rem; text-transform: uppercase; }
[data-enhanced="true"] .role-panel:not([hidden]) .role-panel-inner { animation: role-reveal .55s .08s cubic-bezier(.16,1,.3,1) both; }
@keyframes role-type-in { from { clip-path: inset(100% 0 0); transform: translateY(.45em) scale(.95); } to { clip-path: inset(0); transform: none; } }
@keyframes role-reveal { from { clip-path: inset(100% 0 0); transform: translateY(22px); } to { clip-path: inset(0); transform: none; } }
@media (max-width: 760px) {
  .role-home { padding-top: 28px; }
  .role-intro span { display: block; margin-left: 0; }
  .role-layout { grid-template-columns: minmax(0,1fr); gap: 28px; min-height: 0; }
  .role-label { font-size: clamp(58px, 14vw, 110px); }
  .role-panel p { max-width: none; }
  .role-panel ul { margin-top: 20px; }
}
@media (prefers-reduced-motion: reduce) {
  [data-enhanced="true"] .role-choice:not([hidden]) .role-label,
  [data-enhanced="true"] .role-panel:not([hidden]) .role-panel-inner { animation: none; }
}

/* A native horizontal surface exposes the next role without extra controls. */
.role-choices { display: flex; gap: 24px; overflow-x: auto; overflow-y: hidden; scroll-snap-type: x mandatory; scrollbar-width: none; cursor: grab; padding-block: 20px; position: relative; overscroll-behavior-x: contain; }
.role-choices::-webkit-scrollbar { display: none; }
.role-choice { flex: 0 0 88%; scroll-snap-align: start; scroll-snap-stop: always; justify-content: center; cursor: inherit; min-width: 0; }
.role-choices::after { content: ""; flex: 0 0 12%; }
.role-label { cursor: text; user-select: text; -webkit-user-select: text; }
.role-choice:not([aria-current="true"]) { opacity: .45; }
.role-choices[data-dragging="true"] { scroll-snap-type: none; cursor: grabbing; }
[data-enhanced="true"] .role-choice:not([hidden]) .role-label { animation: none; }
.role-label { font-size: clamp(54px, 7.5vw, 140px); }
@media (max-width: 760px) { .role-label { font-size: clamp(46px, 12vw, 96px); } }

/* Keep each explanation directly beneath the role typography. */
.role-layout { grid-template-columns: minmax(0, 1fr); gap: clamp(20px, 3vw, 36px); align-items: start; min-height: 0; }
.role-choice { align-items: flex-start; }
.role-label { max-width: 14ch; }
.role-details { width: 88%; }
.role-panel p { max-width: 36ch; }
@media (max-width: 760px) {
  .role-layout { gap: 20px; }
  .role-details { width: 88%; }
}

/* Perspective turn: live HTML faces, with a still reading interval. */
.role-choices { display: grid; overflow: hidden; scroll-snap-type: none; perspective: 1100px; cursor: default; touch-action: pan-y; }
.role-choices::after { display: none; }
.role-choice { grid-area: 1 / 1; width: 100%; min-height: 2.95em; backface-visibility: hidden; transform-origin: center; opacity: 1 !important; }
.role-choice[hidden] { display: none; }
.role-label { max-width: 14ch; }
.role-choices { min-height: clamp(180px, 24vw, 440px); }
@media (max-width: 760px) { .role-choices { min-height: clamp(160px, 37vw, 300px); } }

/* Explanation faces share the title's rotation and pause timeline. */
.role-details { display: grid; perspective: 1100px; }
.role-panel { grid-area: 1 / 1; backface-visibility: hidden; transform-origin: center; }
[data-enhanced="true"] .role-panel:not([hidden]) .role-panel-inner { animation: none; }

/* Fixed stage and axis: depth comes from perspective, not lateral travel. */
.role-home { overflow: hidden; padding-top: clamp(40px, 7vh, 80px); padding-bottom: clamp(40px, 7vh, 80px); }
.role-layout { gap: clamp(28px, 4vh, 48px); }
.role-choices { perspective: 850px; perspective-origin: 50% 50%; min-height: 0; padding: .12em 0; gap: 0; }
.role-choice { justify-content: center; min-height: 0; transform-origin: 50% 50%; }
.role-choice[hidden] { display: flex; visibility: hidden; pointer-events: none; }
.role-label { max-width: 12ch; font-size: clamp(72px, 12.5vw, 220px); line-height: .98; letter-spacing: -.035em; }
.role-details { width: 100%; perspective: 850px; perspective-origin: 50% 50%; }
.role-panel[hidden] { display: block; visibility: hidden; pointer-events: none; }
.role-panel { transform-origin: 50% 50%; }
.role-panel p { max-width: 38ch; font-size: clamp(20px, 2vw, 30px); line-height: 1.45; }
@media (max-width: 760px) {
  .role-choices { min-height: 0; perspective: 600px; }
  .role-label { font-size: clamp(48px, 14.5vw, 108px); }
  .role-details { width: 100%; }
}

/* Let the perspective stage reach the viewport's right edge. */
.role-home .role-layout { width: calc(100% + var(--gutter)); }
.role-home .role-choices { width: 100%; perspective-origin: 65% 50%; }
.role-home .role-choice { transform-origin: 65% 50%; padding-right: var(--gutter); box-sizing: border-box; }
.role-home .role-details { width: 100%; perspective-origin: 65% 50%; }
.role-home .role-panel { transform-origin: 65% 50%; padding-right: var(--gutter); box-sizing: border-box; }

/* Adjacent square-prism faces share the same depth and projection. */
.role-home .role-choices,
.role-home .role-details {
  perspective: max(1200px, 160vw);
  perspective-origin: 50% 50%;
  transform-style: preserve-3d;
  overflow: visible;
}
.role-home .role-choice,
.role-home .role-panel {
  transform-origin: 50% 50%;
  backface-visibility: hidden;
}

/* Stable shared baseline and restrained, angle-dependent yellow shading. */
.role-home .role-choice { justify-content: flex-end; color: inherit; }
.role-home .role-panel { color: inherit; }
.role-home .role-label { color: inherit; }
.role-home .role-choices,
.role-home .role-details { align-items: stretch; }
.role-home .role-panel-inner { padding-top: 0; }

/* Role explanations remain a single line, including narrow viewports. */
.role-home .role-panel p {
  white-space: nowrap;
  max-width: none;
  width: max-content;
  font-size: clamp(10px, 2.05vw, 30px);
}

/* Preserve the current type size while keeping every role description on one line. */
.role-home .role-panel p {
  max-width: none;
  white-space: nowrap;
}
.role-home .role-panel-inner {
  max-width: 100%;
  overflow-x: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--hero-yellow) transparent;
}

/* Larger single-line role explanations. */
.role-home .role-panel p { font-size: clamp(24px, 2.5vw, 38px); }

/* Architectural type study: an oversized, two-line facade and an editorial caption. */
.role-home {
  min-height: calc(100svh - var(--header-height));
  padding-top: clamp(64px, 12svh, 160px);
  padding-bottom: clamp(56px, 9svh, 112px);
  align-items: center;
}
.role-home .role-layout { gap: clamp(32px, 5svh, 64px); }
.role-home .role-choices { padding: .3em 0; }
.role-home .role-label {
  max-width: none;
  font-size: clamp(64px, 14vw, 240px);
  line-height: .94;
  letter-spacing: -.04em;
}
.role-home .role-details { position: relative; }
.role-home .role-details { grid-template-columns: minmax(0, 1fr); }
.role-home .role-panel, .role-home .role-panel-inner { min-width: 0; max-width: 100%; }

.role-home .role-panel-inner { padding-bottom: 8px; }
.role-home .role-panel p { letter-spacing: -.015em; }
@media (max-width: 760px) {
  .role-home { padding-top: 72px; padding-bottom: 64px; }
  .role-home .role-label { font-size: clamp(42px, 14vw, 106px); }
  .role-home .role-layout { gap: 40px; }
}

/* Plain black lets the dimensional typography carry the space. */
.role-home { background: #111111; }
.role-home::before,
.role-home::after { content: none; }

/* Keep the background plain behind the dimensional typography. */
.role-home { position: relative; isolation: isolate; background: #111111; }
.role-home .hero-content { position: relative; z-index: 1; }

/* Original liquid material stays behind crisp, selectable HTML text. */
.liquid-hero { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 0; }
.role-home .hero-content { position: relative; z-index: 1; }

/* Liquid-material composition with roles as the primary readable content. */
.role-home { min-height: calc(100svh - var(--header-height)); padding: clamp(64px, 10svh, 120px) var(--gutter) 32px; }
.role-home .hero-content { display: flex; flex-direction: column; align-items: stretch; gap: clamp(40px, 7svh, 80px); }
.role-home .role-layout { width: 100%; gap: clamp(32px, 5svh, 56px); }
.role-home .role-choices, .role-home .role-details { perspective: none; transform-style: flat; width: 100%; overflow: hidden; }
.role-home .role-choices { padding: .1em 0; }
.role-home .role-choice, .role-home .role-panel { padding-right: 0; }
.role-home .role-label {
  font: 400 clamp(64px, 12.5vw, 220px)/.96 "Anton", sans-serif;
  text-transform: uppercase;
  letter-spacing: -.035em;
  color: var(--hero-yellow);
}
.role-home .role-panel p { font-size: clamp(24px, 2.5vw, 38px); line-height: 1.5; width: max-content; white-space: nowrap; max-width: none; }
.role-home .role-panel-inner { overflow-x: auto; }
.reference-contact { display: grid; gap: 8px; font: .85rem/1.5 var(--body); }
.reference-contact > span { font-size: .75rem; opacity: .7; }
.reference-contact a { color: inherit; width: fit-content; }
@media (max-width: 760px) {
  .role-home { padding-top: 64px; padding-bottom: 32px; }
  .role-home .role-label { font-size: clamp(42px, 14vw, 106px); }
  .role-home .hero-content { gap: 48px; }
}

/* Soft optical focus, as opposed to bloom: no additive glow pass. */
.liquid-hero { filter: blur(2.5px); }

/* Original-color reference material with its measured overscan and optical veils. */
.role-home .liquid-hero {
  inset: -56px;
  width: auto;
  height: auto;
  filter: brightness(1.01);
  background: url('/Resources/Assets/hero-aura-reference.webp') center / cover;
}
.role-home .liquid-hero canvas { display: block; width: 100%; height: 100%; }
.role-home .liquid-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(to bottom, rgba(0,0,0,0) 0%, rgba(0,0,0,.096) 35%, rgba(0,0,0,.36) 65%, rgba(0,0,0,.64) 88%, rgba(0,0,0,.8) 100%), rgba(8,4,5,.2);
}
.role-home .role-label,
.role-home .role-panel p { color: #fff; text-shadow: 0 2px 20px rgba(0,0,0,.65); }
.role-home .reference-contact { color: #fff; }

/* Match the reference's full-bleed presentation and optical softness. */
[data-page="home"] .site-header {
  position: absolute;
  inset: 0 0 auto;
  background: transparent;
  color: #fff;
}
[data-page="home"] .site-header .wordmark { justify-self: start; font-size: 1rem; }
.role-home { min-height: 100svh; padding-top: clamp(120px, 17svh, 190px); }
.role-home .liquid-hero canvas { filter: blur(4px); }
.role-home .liquid-hero::after {
  background: linear-gradient(to bottom, rgba(8,4,5,.55), transparent 160px), linear-gradient(to bottom, rgba(0,0,0,0) 0%, rgba(0,0,0,.096) 35%, rgba(0,0,0,.36) 65%, rgba(0,0,0,.64) 88%, rgba(0,0,0,.8) 100%), rgba(8,4,5,.2);
}
.role-home .role-label {
  font-family: var(--body);
  font-size: clamp(56px, 11vw, 190px);
  font-weight: 400;
  line-height: 1;
  letter-spacing: -.055em;
  text-transform: none;
}
@media (max-width: 760px) {
  .role-home { padding-top: 120px; }
  .role-home .role-label { font-size: clamp(38px, 11.4vw, 84px); }
}

/* Restore adjacent cube faces for synchronized role and explanation changes. */
.role-home .role-choices,
.role-home .role-details {
  perspective: max(1200px, 160vw);
  perspective-origin: 50% 50%;
  transform-style: preserve-3d;
  overflow: visible;
}
.role-home .role-choice,
.role-home .role-panel {
  transform-origin: 50% 50%;
  backface-visibility: hidden;
  color: #fff;
}
.role-home .role-label,
.role-home .role-panel p { color: inherit; }
.role-home .liquid-hero { background: #100d14; }

/* Refraction focus is measured in the shader: preserve fine detail on the far side. */
.role-home .liquid-hero canvas { filter: blur(.75px); }

/* Carry the liquid field beyond the first screen into the reading surface. */
.role-home {
  --reading-bridge: clamp(110px, 19svh, 190px);
  min-height: calc(100svh + var(--reading-bridge));
  padding-bottom: calc(32px + var(--reading-bridge));
}
.role-home::after {
  content: "";
  position: absolute;
  z-index: 2;
  left: 0;
  right: 0;
  bottom: 0;
  height: var(--reading-bridge);
  pointer-events: none;
  background: linear-gradient(to bottom,
    rgba(243,241,233,0) 0%,
    rgba(243,241,233,.035) 15%,
    rgba(243,241,233,.20) 36%,
    rgba(243,241,233,.62) 65%,
    rgba(243,241,233,.94) 87%,
    #f3f1e9 100%);
}
@media (max-width: 760px) {
  .role-home { --reading-bridge: 120px; }
}

/* Hover pauses the role rotation and gives the active title a clear response. */
@media (hover: hover) and (pointer: fine) {
  .role-home .role-choices:hover .role-choice:not([hidden]) .role-label {
    color: #fff;
    text-decoration: underline;
    text-decoration-color: #fff;
    text-decoration-thickness: .045em;
    text-underline-offset: .12em;
  }
}
.hero-contact-links { display: flex; flex-wrap: wrap; gap: 24px; }

/* Reveal the role description on interaction without moving the contact links. */
.role-home .role-details {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity .2s ease, visibility .2s;
}
.role-home [data-description-visible="true"] .role-details {
  opacity: 1;
  visibility: visible;
}
.role-home .role-panel p {
  width: auto;
  max-width: 60ch;
  white-space: normal;
  font-size: clamp(20px, 2.5vw, 38px);
  line-height: 1.5;
}
.role-home .role-panel-inner { overflow: visible; }
@media (prefers-reduced-motion: reduce) {
  .role-home .role-details { transition: none; }
}
