@font-face { font-family: 'DIN Condensed'; src: url('/coach-wall/assets/fonts/din-condensed-bold.ttf') format('truetype'); font-display: swap; }
@font-face { font-family: 'Helvetica Neue World'; src: url('/coach-wall/assets/fonts/helvetica-neue-world-roman.woff2') format('woff2'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'Helvetica Neue World'; src: url('/coach-wall/assets/fonts/helvetica-neue-world-bold.woff2') format('woff2'); font-weight: 700; font-display: swap; }

:root {
  color-scheme: dark;
  --green: #00b900;
  --ink: #030504;
  --paper: #f2f1eb;
  --muted: #9ba39d;
  --display: 'DIN Condensed', sans-serif;
  --body: 'Helvetica Neue World', sans-serif;
  --header-height: clamp(64px, 8.4vh, 96px);
}

* { box-sizing: border-box; }
html, body { width: 100%; min-width: 320px; min-height: 100%; margin: 0; background: var(--ink); }
body { min-height: 100svh; overflow: clip; color: var(--paper); font-family: var(--body); }
button, a { -webkit-tap-highlight-color: transparent; }
button { font: inherit; }

.coach-wall { position: relative; width: 100vw; height: 100svh; min-height: 480px; overflow: clip; isolation: isolate; background: var(--ink); }
.coach-wall::before { position: absolute; z-index: 20; inset: 0; border: 1px solid rgba(255,255,255,.08); content: ''; pointer-events: none; }
.coach-header { position: absolute; z-index: 30; top: 0; left: 0; display: flex; width: 100%; height: var(--header-height); align-items: center; justify-content: space-between; padding: 0 clamp(18px, 3.2vw, 64px); background: linear-gradient(180deg, rgba(3,5,4,.98), rgba(3,5,4,.82) 72%, transparent); }
.coach-brand { display: flex; align-items: center; gap: clamp(10px, 1.1vw, 20px); color: white; text-decoration: none; }
.coach-brand img { width: clamp(108px, 10vw, 190px); height: auto; }
.coach-brand i { width: 1px; height: clamp(18px, 2.1vw, 36px); background: var(--green); }
.coach-brand span, .coach-status { font: 700 clamp(10px, .84vw, 16px)/1 var(--body); letter-spacing: .19em; }
.coach-status { display: flex; align-items: center; gap: clamp(12px, 1.6vw, 28px); color: var(--muted); }
.coach-status b { color: white; font-variant-numeric: tabular-nums; }

.coach-overview, .coach-spotlight { position: absolute; z-index: 1; inset: 0; transition: opacity .65s ease, transform .8s cubic-bezier(.22,.75,.2,1); }
.coach-overview[aria-hidden='true'] { opacity: 0; transform: scale(.975); pointer-events: none; }
.coach-overview[aria-hidden='false'] { opacity: 1; transform: scale(1); }
.coach-grid { position: absolute; top: var(--header-height); right: 0; bottom: 0; left: 0; display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); grid-template-rows: repeat(3, minmax(0, 1fr)); }
.coach-tile { position: relative; min-width: 0; min-height: 0; grid-column: span 2; overflow: hidden; padding: 0; border: 0; border-top: 1px solid rgba(255,255,255,.1); border-right: 1px solid rgba(255,255,255,.1); background: #080b09; color: white; cursor: pointer; text-align: left; opacity: 0; animation: tile-arrival .72s cubic-bezier(.22,.75,.2,1) forwards; animation-delay: calc(var(--order) * 55ms + 120ms); }
.coach-grid[data-count='11'] .coach-tile:nth-child(9) { grid-row: 3; grid-column: 2 / span 2; border-left: 1px solid rgba(255,255,255,.1); }
.coach-tile:nth-child(4n) { border-right: 0; }
.coach-tile-photo { width: 100%; height: 100%; object-fit: cover; object-position: 50% 22%; filter: saturate(.7) contrast(1.07) brightness(.82); transition: transform .75s cubic-bezier(.22,.75,.2,1), filter .45s ease; }
.coach-tile-veil { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(3,5,4,.04) 20%, rgba(3,5,4,.86) 100%); }
.coach-tile-icon { position: absolute; top: clamp(9px, 1vw, 18px); right: clamp(9px, 1vw, 18px); width: clamp(32px, 3.4vw, 64px); height: clamp(32px, 3.4vw, 64px); object-fit: contain; filter: drop-shadow(0 5px 14px rgba(0,0,0,.36)); transition: transform .35s ease; }
.coach-tile-copy { position: absolute; right: clamp(12px, 1.4vw, 26px); bottom: clamp(10px, 1.4vw, 25px); left: clamp(12px, 1.4vw, 26px); display: block; }
.coach-tile-copy small { display: block; margin-bottom: .35em; color: var(--green); font: 700 clamp(7px, .72vw, 13px)/1 var(--body); letter-spacing: .13em; text-transform: uppercase; }
.coach-tile-copy b { --fit-min-font: 14px; display: block; padding-block: .04em .08em; font-family: var(--display); font-size: var(--fit-font-size, clamp(18px, 2.05vw, 40px)); font-weight: 700; line-height: .98; letter-spacing: .035em; text-transform: uppercase; text-wrap: balance; }
.coach-tile:is(:hover, :focus-visible) .coach-tile-photo { transform: scale(1.045); filter: saturate(.92) contrast(1.05) brightness(.96); }
.coach-tile:is(:hover, :focus-visible) .coach-tile-icon { transform: rotate(-5deg) scale(1.08); }
.coach-tile:focus-visible { z-index: 2; outline: 2px solid var(--green); outline-offset: -3px; }

.coach-spotlight { background: #030504; }
.coach-spotlight[aria-hidden='true'] { opacity: 0; transform: translateX(2.5%); pointer-events: none; }
.coach-spotlight[aria-hidden='false'] { opacity: 1; transform: translateX(0); }
.spotlight-backdrop { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; filter: saturate(.38) brightness(.27) contrast(1.16); transform: scale(1.035); }
.spotlight-wash { position: absolute; inset: 0; background: linear-gradient(90deg, rgba(3,5,4,.99) 0%, rgba(3,5,4,.94) 35%, rgba(3,5,4,.42) 63%, rgba(3,5,4,.7) 100%), linear-gradient(0deg, #030504 0%, transparent 34%); }
.spotlight-portrait-wrap { position: absolute; right: 3.5vw; bottom: 0; width: min(45vw, 860px); height: calc(100% - var(--header-height) * .68); overflow: hidden; mask-image: linear-gradient(to bottom, #000 80%, transparent 100%); }
.spotlight-portrait { width: 100%; height: 100%; object-fit: cover; object-position: 50% 18%; filter: saturate(.82) contrast(1.06); transform-origin: 60% 55%; }
.coach-spotlight.is-changing .spotlight-backdrop { animation: backdrop-drift 12s linear both; }
.coach-spotlight.is-changing .spotlight-portrait { animation: portrait-arrival .8s cubic-bezier(.22,.75,.2,1) both; }
.spotlight-copy { position: absolute; z-index: 2; top: 20%; left: clamp(24px, 5vw, 96px); width: min(51vw, 970px); }
.spotlight-icon { display: block; width: clamp(58px, 6vw, 116px); height: clamp(58px, 6vw, 116px); margin-bottom: clamp(14px, 2.1vh, 24px); object-fit: contain; filter: drop-shadow(0 12px 30px rgba(0,0,0,.38)); }
.spotlight-copy > p:first-of-type { margin: 0 0 .65em; color: var(--green); font: 700 clamp(11px, 1vw, 19px)/1 var(--body); letter-spacing: .17em; text-transform: uppercase; }
.spotlight-copy h1 { --fit-min-font: 40px; max-width: 100%; margin: 0; font-family: var(--display); font-size: var(--fit-font-size, clamp(52px, min(7.2vw, 13vh), 138px)); font-weight: 700; line-height: .84; letter-spacing: .018em; text-transform: uppercase; text-wrap: balance; }
.spotlight-copy h2 { margin: clamp(14px, 2.2vh, 26px) 0 0; color: var(--paper); font: 700 clamp(18px, 1.65vw, 32px)/1 var(--display); letter-spacing: .09em; text-transform: uppercase; }
.spotlight-detail { max-width: 680px; margin: clamp(12px, 1.8vh, 22px) 0 0; color: #b0b8b2; font: 400 clamp(12px, .94vw, 19px)/1.42 var(--body); letter-spacing: .02em; }

.coach-rail { position: absolute; z-index: 4; right: 3vw; bottom: 4.7vh; left: 3vw; display: grid; grid-template-columns: repeat(var(--coach-count), minmax(0, 1fr)); border-top: 1px solid rgba(255,255,255,.16); }
.coach-rail button { position: relative; display: grid; min-width: 0; grid-template-columns: clamp(24px, 2.25vw, 42px) minmax(0, 1fr); align-items: center; gap: clamp(5px, .55vw, 11px); padding: clamp(8px, 1.05vh, 13px) clamp(5px, .65vw, 12px); border: 0; border-right: 1px solid rgba(255,255,255,.1); background: rgba(3,5,4,.82); color: #747e77; cursor: pointer; }
.coach-rail button:last-child { border-right: 0; }
.coach-rail button::before { position: absolute; top: -2px; right: 0; left: 0; height: 3px; background: var(--green); content: ''; opacity: 0; transform: scaleX(.2); transition: opacity .25s ease, transform .25s ease; }
.coach-rail button[aria-current='true'] { color: white; }
.coach-rail button[aria-current='true']::before { opacity: 1; transform: scaleX(1); }
.coach-rail-icon { width: 100%; aspect-ratio: 1; object-fit: contain; filter: grayscale(.6); opacity: .66; }
.coach-rail button[aria-current='true'] .coach-rail-icon { filter: none; opacity: 1; }
.coach-rail span { overflow: hidden; font: 700 clamp(7px, .58vw, 11px)/1 var(--body); letter-spacing: .05em; text-overflow: ellipsis; text-transform: uppercase; white-space: nowrap; }

.coach-controls { position: absolute; z-index: 40; right: clamp(14px, 2vw, 38px); bottom: clamp(10px, 1.25vh, 18px); display: flex; align-items: center; gap: 3px; transition: opacity .3s ease; }
body[data-mode='overview'] .coach-controls { opacity: 0; pointer-events: none; }
.coach-controls button { min-width: 42px; min-height: 28px; padding: 6px 10px; border: 1px solid rgba(255,255,255,.18); background: rgba(3,5,4,.84); color: #aab1ac; cursor: pointer; font: 700 clamp(7px, .55vw, 10px)/1 var(--body); letter-spacing: .1em; }
.coach-controls button:is(:hover, :focus-visible) { border-color: var(--green); color: white; outline: none; }
.cycle-progress { position: absolute; z-index: 45; right: 0; bottom: 0; left: 0; height: 3px; background: var(--green); transform: scaleX(0); transform-origin: left; }
.cycle-progress.is-running { animation: cycle-progress var(--cycle-duration) linear forwards; }

@keyframes tile-arrival { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: translateY(0); } }
@keyframes portrait-arrival { from { opacity: .25; transform: scale(1.035) translateX(2.5%); } to { opacity: 1; transform: scale(1) translateX(0); } }
@keyframes backdrop-drift { from { transform: scale(1.035); } to { transform: scale(1.095); } }
@keyframes cycle-progress { from { transform: scaleX(0); } to { transform: scaleX(1); } }

@media (max-width: 860px) {
  :root { --header-height: 68px; }
  .coach-header { padding-inline: 16px; }
  .coach-brand span { display: none; }
  .coach-tile-copy b { --fit-min-font: 10px; font-size: var(--fit-font-size, clamp(14px, 4.4vw, 26px)); }
  .coach-tile-copy small { font-size: clamp(6px, 2vw, 10px); }
  .coach-tile-icon { width: clamp(28px, 9vw, 45px); height: clamp(28px, 9vw, 45px); }
  .coach-grid { grid-template-columns: repeat(6, minmax(0, 1fr)); grid-template-rows: repeat(4, minmax(0, 1fr)); }
  .coach-grid[data-count='11'] .coach-tile:nth-child(9) { grid-row: auto; grid-column: span 2; border-left: 0; }
  .coach-grid[data-count='11'] .coach-tile:nth-child(10) { grid-row: 4; grid-column: 2 / span 2; border-left: 1px solid rgba(255,255,255,.1); }
  .coach-tile:nth-child(4n) { border-right: 1px solid rgba(255,255,255,.1); }
  .coach-tile:nth-child(3n) { border-right: 0; }
  .spotlight-portrait-wrap { right: 0; width: 72vw; height: calc(100% - 50px); opacity: .74; }
  .spotlight-wash { z-index: 1; background: linear-gradient(90deg, rgba(3,5,4,.96) 0%, rgba(3,5,4,.78) 55%, rgba(3,5,4,.08) 100%), linear-gradient(0deg, #030504 0%, transparent 46%); }
  .spotlight-copy { top: 18%; left: 7vw; width: 82vw; }
  .spotlight-copy h1 { --fit-min-font: 34px; max-width: 78vw; font-size: var(--fit-font-size, clamp(40px, 10.4vw, 72px)); }
  .spotlight-detail { max-width: 68vw; text-shadow: 0 2px 12px rgba(0,0,0,.9); }
  .coach-rail { right: 0; bottom: 46px; left: 0; grid-template-columns: repeat(var(--coach-count), minmax(54px, 1fr)); overflow-x: auto; scrollbar-width: none; }
  .coach-rail::-webkit-scrollbar { display: none; }
  .coach-rail button { grid-template-columns: 1fr; justify-items: center; padding-inline: 8px; }
  .coach-rail span { display: none; }
  .coach-controls { right: 8px; bottom: 9px; }
}

@media (max-height: 650px) {
  :root { --header-height: 56px; }
  .coach-header { padding-inline: 16px; }
  .coach-brand img { width: 104px; }
  .spotlight-copy { top: 15%; }
  .spotlight-icon { width: 52px; height: 52px; margin-bottom: 10px; }
  .spotlight-copy h1 { font-size: var(--fit-font-size, clamp(44px, min(8.5vw, 14vh), 92px)); }
  .spotlight-copy h2 { margin-top: 10px; }
  .spotlight-detail { margin-top: 8px; }
  .coach-rail { bottom: 38px; }
  .coach-controls { bottom: 6px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
