/* Eureka · the home page. site.css carries the letters, the colours, the widths, the sky, the header and the footer; this file lays out
   the home's own parts: the opening over the sky of concepts, the stage that plays real recordings (one pattern for all of them),
   the doors, where Eureka stands and the chapters. Built by tools/home.mjs. */
html { scroll-padding-top: calc(var(--top-h) + 12px); }
html.wait body { visibility: hidden; }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
.home > .sky-labels { position: fixed; z-index: 1; transition: opacity .4s ease; }
/* on a narrow screen the names of the sky would fall under the text, so they stay with the opening */
@media (max-width: 1099px) { .past-hero > .sky-labels { opacity: 0; } }
main { position: relative; z-index: 2; overflow-x: clip; }
h1, h2, h3, p, ol, ul, figure { margin: 0; }
ol, ul { padding: 0; list-style: none; }
.wrap { width: 100%; max-width: var(--site-w); margin: 0 auto; padding: 0 var(--pad); }
@media (min-width: 1100px) { .wrap { padding: 0 calc(var(--pad) + 14px); } }
h2 { font: 600 clamp(30px, 3.6vw, 50px)/1.08 var(--font-display); letter-spacing: -0.032em; text-wrap: balance; }
section { position: relative; }

/* words that sit straight on the sky keep a halo of the page colour, so a label or a line behind them never cuts a letter */
.hero-copy, .hint, .sec-head, .say .note { text-shadow: 0 0 16px var(--bg), 0 0 5px var(--bg); }
/* a button has its own background: the halo would blur its letters */
.hero-copy .btn { text-shadow: none; }

/* links that say where they go */
.go, .inline-go, .quiet { display: inline-flex; align-items: center; gap: 7px; font-weight: 600; color: var(--accent); text-decoration: none; }
.go svg, .inline-go svg, .quiet svg { width: 16px; height: 16px; flex: none; transition: transform 0.2s; }
.go:hover, .inline-go:hover, .quiet:hover { text-decoration: underline; text-underline-offset: 4px; }
.go:hover svg, .inline-go:hover svg, .quiet:hover svg { transform: translateX(3px); }
.inline-go { display: inline; }
.inline-go svg { display: inline-block; vertical-align: -3px; margin-left: 6px; }

/* ---------- 1 · the opening ---------- */
.hero { min-height: 78vh; min-height: 78svh; display: flex; padding: calc(var(--top-h) + 11vh) 0 28px; pointer-events: none; }
.hero .wrap { display: flex; flex-direction: column; }
.hero-copy { max-width: 780px; pointer-events: auto; }
/* Eureka's signature, the same words in every language */
.hero .motto { font: 500 clamp(24px, 2.7vw, 40px)/1.15 var(--font-display); letter-spacing: -0.03em; color: var(--accent); margin: 0 0 22px; }
.hero h1 { font: 600 clamp(44px, 6.3vw, 98px)/0.98 var(--font-display); letter-spacing: -0.048em; margin: 0 0 28px; text-wrap: balance; }
.hero h1 em { font: italic 380 1em/1 var(--font-body); letter-spacing: -0.04em; color: var(--accent); padding-right: .06em; }
.hero .lead { font-size: clamp(18px, 1.5vw, 21.5px); line-height: 1.55; color: var(--ink-2); max-width: 620px; margin: 0 0 34px; }
.cta { display: flex; gap: 14px 26px; flex-wrap: wrap; align-items: center; }
.cta .btn svg { width: 19px; height: 19px; }
.cta .btn .eq { display: none; height: 16px; }
.cta .btn.playing svg { display: none; }
.cta .btn.playing .eq { display: inline-flex; }
.cta .quiet { color: var(--ink); font-size: 16px; }
.cta .quiet svg { color: var(--accent); }
.hint { margin-top: auto; padding-top: 48px; max-width: 520px; font-size: 13.5px; line-height: 1.5; color: var(--ink-3); pointer-events: auto; }
.hint small { display: block; margin-top: 6px; font: 500 11.5px/1.4 var(--font-mono); letter-spacing: .04em; }

/* ---------- section heads ---------- */
.hear, .dream, .do, .tuning, .doors, .stands, .read-all { padding: 11vh 0; }
.hear { padding-top: 4vh; }
.sec-head { display: grid; gap: 14px 56px; margin-bottom: 34px; }
.sec-head .lede { display: grid; gap: 12px; color: var(--ink-2); font-size: 17.5px; line-height: 1.6; max-width: 620px; }
@media (min-width: 1000px) { .hear .sec-head, .do .sec-head, .read-all .sec-head { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: end; } }

/* ---------- the stage: one pattern for every real recording and screen on the home ---------- */
.player { display: grid; grid-template-columns: minmax(0, 1fr); gap: 22px; align-items: start; }
@media (min-width: 1100px) { .player:not(.single) { grid-template-columns: minmax(0, 1fr) 360px; } }
.stage { position: relative; border-radius: 22px; overflow: hidden; background: #04060c; border: 1px solid var(--glass-edge); box-shadow: var(--shadow); }
.stage video { width: 100%; aspect-ratio: 16 / 10; object-fit: contain; background: #04060c; }
.stage-bar { position: absolute; left: 14px; right: 14px; bottom: 14px; display: flex; align-items: center; gap: 16px; padding: 12px 12px 12px 20px; border-radius: 18px; color: #f3ece1;
  background: rgba(7, 11, 22, 0.76); backdrop-filter: blur(16px) saturate(1.3); -webkit-backdrop-filter: blur(16px) saturate(1.3); border: 1px solid rgba(255, 255, 255, 0.12); }
.stage-bar .meta { min-width: 0; flex: 1; display: grid; gap: 5px; }
.stage-bar .trad { font: 500 11px/1 var(--font-mono); letter-spacing: .14em; text-transform: uppercase; color: #f4c46a; }
.stage-bar .title { font: 600 19px/1.2 var(--font-display); letter-spacing: -0.02em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.stage-bar .eq { height: 24px; color: #f4c46a; }
.stage-bar .eq i { width: 4px; }
.listen { flex: none; display: inline-flex; align-items: center; gap: 10px; height: 46px; padding: 0 20px; border-radius: 999px; border: 1px solid #f4c46a; cursor: pointer; background: transparent; color: #f4c46a; font: 650 15px/1 var(--font-body); transition: background-color .2s, color .2s; }
.listen:hover { background: rgba(244, 196, 106, 0.14); }
.listen svg { width: 18px; height: 18px; }
.listen[aria-pressed="true"] { background: #f4c46a; color: #04060c; }
.stage-progress { position: absolute; left: 0; top: 0; z-index: 2; height: 3px; width: 100%; transform-origin: left; transform: scaleX(0); background: linear-gradient(90deg, #f4c46a, #ff9e7a); }
.stage-caption { margin: 16px 4px 0; color: var(--ink-2); font-size: 16.5px; line-height: 1.55; max-width: 68ch; min-height: 3.1em; }
.stage-caption .inline-go { margin-left: 4px; }
.setlist { display: grid; gap: 4px; }
.setlist button { width: 100%; display: grid; grid-template-columns: 24px 76px minmax(0, 1fr) auto; align-items: center; gap: 12px; padding: 8px 12px 8px 10px; border-radius: 16px; border: 1px solid transparent; background: transparent; text-align: left; cursor: pointer; transition: background-color .2s, border-color .2s; }
.setlist button:hover { background: var(--glass); border-color: var(--line); }
.setlist button[aria-pressed="true"] { background: var(--glass-2); border-color: var(--accent); box-shadow: 0 10px 30px -22px rgba(20, 30, 60, .5); }
.setlist .no { font: 500 12px/1 var(--font-mono); color: var(--ink-3); }
.setlist .thumb { width: 76px; height: 48px; border-radius: 9px; overflow: hidden; background: var(--bg-2); border: 1px solid var(--line); }
.setlist .thumb img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 0; }
.setlist .txt { display: grid; gap: 5px; min-width: 0; }
.setlist .txt b { font: 600 15.5px/1.25 var(--font-display); letter-spacing: -0.01em; }
.setlist .txt small { font: 500 11px/1.2 var(--font-mono); letter-spacing: .08em; text-transform: uppercase; color: var(--ink-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.setlist .eq { color: var(--accent); opacity: 0; }
.setlist button[aria-pressed="true"] .eq { opacity: 1; }
/* the four things are four big rows: the verb is what you read first */
.do .setlist button { padding: 12px 14px 12px 12px; }
.do .setlist .txt b { font-size: 21px; letter-spacing: -0.025em; }

/* ---------- 4 · any tuning ---------- */
/* You dream it: the words, then the drawing of the choices; side by side on a wide screen */
.dream-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 28px; align-items: center; }
@media (min-width: 1100px) { .dream-grid { grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 56px; } .dream .sec-head { margin-bottom: 18px; } }
.home-quote { position: relative; margin: 0 0 22px; padding: 2px 0 2px 26px; border-left: 2px solid color-mix(in srgb, var(--accent) 55%, transparent); font: italic 400 18px/1.6 var(--font-display); color: var(--ink); }
.home-quote p { margin: 0; }
.home-quote .home-quote-title { margin: 0 0 .7em; font: 500 11px/1 var(--font-mono); font-style: normal; letter-spacing: .13em; text-transform: uppercase; color: var(--accent); }
.dream-fig { margin: 0; }
.dream-fig img { display: block; width: 100%; height: auto; border-radius: 18px; box-shadow: 0 18px 48px -24px rgba(4, 8, 20, .55);
  /* a drawing with no background of its own: the page's colour, not quite opaque, so the sky only shows faintly behind it */
  background: color-mix(in srgb, var(--bg) 82%, transparent); }
.dream-fig figcaption { margin-top: 12px; font-size: 14px; line-height: 1.5; color: var(--ink-2); }
.tuning-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 28px; align-items: center; }
@media (min-width: 1100px) { .tuning-grid { grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.3fr); gap: 56px; } .tuning .sec-head { margin-bottom: 0; } }

/* ---------- in numbers ---------- */
.num-row { list-style: none; margin: 0 0 22px; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
@media (min-width: 720px) { .num-row { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; } }
@media (min-width: 1100px) { .num-row { grid-template-columns: repeat(6, minmax(0, 1fr)); } }
.num-card { display: flex; flex-direction: column; gap: 6px; padding: 20px 18px 18px; border-radius: 20px; background: var(--glass); border: 1px solid var(--glass-edge);
  backdrop-filter: blur(18px) saturate(1.15); -webkit-backdrop-filter: blur(18px) saturate(1.15); box-shadow: var(--shadow); }
.num-card b { font: 600 44px/1 var(--font-display); letter-spacing: -0.03em; color: var(--accent); font-variant-numeric: tabular-nums; white-space: nowrap; }
.num-card span { color: var(--ink-2); font-size: 15.5px; line-height: 1.35; }
@media (max-width: 719px) { .num-card { padding: 16px 14px 14px; } .num-card b { font-size: 34px; } }

/* ---------- 5 · who it is for ---------- */
.doors-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px 56px; align-items: start; }
@media (min-width: 1100px) { .doors-grid { grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.4fr); } }
.door-grid { display: grid; grid-template-columns: 1fr; gap: 14px; }
@media (min-width: 720px) { .door-grid { grid-template-columns: 1fr 1fr; } .door:last-child:nth-child(odd) { grid-column: 1 / -1; min-height: 0; } }
.door { position: relative; display: flex; flex-direction: column; gap: 12px; padding: 24px 24px 20px; min-height: 200px; border-radius: 20px; background: var(--glass); border: 1px solid var(--glass-edge);
  backdrop-filter: blur(18px) saturate(1.15); -webkit-backdrop-filter: blur(18px) saturate(1.15); box-shadow: var(--shadow); transition: border-color 0.25s ease, transform 0.25s ease; }
.door:hover { border-color: var(--accent); transform: translateY(-2px); }
.door h3 { font: 600 20px/1.2 var(--font-display); letter-spacing: -0.02em; display: flex; align-items: center; gap: 10px; }
.door h3::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); flex: none; }
.door p { color: var(--ink-2); font-size: 16.5px; line-height: 1.5; }
.door .go { margin-top: auto; color: var(--ink); font-size: 15px; }
.door .go svg { color: var(--accent); }
.door .go::after { content: ''; position: absolute; inset: 0; border-radius: inherit; }

/* ---------- 6 · where it stands ---------- */
.stands-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 34px 56px; align-items: start; }
@media (min-width: 1100px) { .stands-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); } .say { position: sticky; top: calc(var(--top-h) + 48px); } }
.say .sec-head { margin-bottom: 18px; }
.say .note { font: 500 12.5px/1.5 var(--font-mono); color: var(--ink-3); margin-bottom: 22px; max-width: 460px; }
/* the milestones sit on a glass card, like the doors: loose text over the moving sky did not read */
.timeline { position: relative; display: grid; --p: 0; --tl-pad: 30px; padding: 22px var(--tl-pad) 10px; border-radius: 22px; background: var(--glass-2); border: 1px solid var(--glass-edge);
  backdrop-filter: blur(20px) saturate(1.15); -webkit-backdrop-filter: blur(20px) saturate(1.15); box-shadow: var(--shadow); }
.timeline::before, .timeline::after { content: ''; position: absolute; left: calc(var(--tl-pad) + 190px); top: 36px; bottom: 30px; width: 3px; border-radius: 3px; background: var(--line-2); }
.timeline::after { background: var(--accent); transform-origin: top; transform: scaleY(var(--p)); }
.step { position: relative; display: grid; grid-template-columns: 170px minmax(0, 1fr); gap: 0 44px; align-items: baseline; padding: 14px 0 20px; }
.step b { text-align: right; font: 600 15px/1.4 var(--font-display); letter-spacing: -0.01em; color: var(--accent); }
.step p { color: var(--ink); font-size: 16.5px; line-height: 1.5; }
.step::before { content: ''; position: absolute; left: 185px; top: 20px; width: 13px; height: 13px; border-radius: 50%; background: var(--bg); border: 3px solid var(--accent); z-index: 1; }
.step.now b { color: var(--accent-2); }
.step.now::before { border-color: var(--accent-2); animation: ring 2.6s ease-out infinite; }
/* the ring repaints the page on every beat, so off the screen it waits (home.js) */
.step.now.is-away::before { animation-play-state: paused; }
@keyframes ring { 0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--accent-2) 60%, transparent); } 100% { box-shadow: 0 0 0 14px transparent; } }

/* ---------- 7 · every chapter ---------- */
.branches { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); grid-auto-rows: 1fr; gap: 14px; }
.branch { display: flex; flex-direction: column; gap: 10px; padding: 22px 22px 20px; border-radius: 20px; background: var(--glass); border: 1px solid var(--glass-edge); backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px); box-shadow: var(--shadow); text-decoration: none; color: var(--ink); transition: border-color 0.25s ease, transform 0.25s ease; }
.branch:hover { border-color: var(--accent); transform: translateY(-2px); }
.branch .n { font: 500 11px/1 var(--font-mono); color: var(--ink-3); }
.branch h3 { font: 600 20px/1.2 var(--font-display); letter-spacing: -0.02em; margin: 2px 0 0; }
.branch:hover h3 { color: var(--accent); }
.branch p { margin: 0; color: var(--ink-2); font-size: 15.5px; line-height: 1.5; }
.branch-go { margin-top: auto; display: inline-flex; align-items: center; gap: 6px; font: 500 12.5px/1 var(--font-mono); color: var(--accent); }
.branch-go svg { width: 14px; height: 14px; }
/* a card left alone on the last row takes the whole row */
.branch:last-child:nth-child(3n+1) { grid-column: 1 / -1; }

/* ---------- 8 · contact ---------- */
.contact { padding: 4vh 0 14vh; }
.contact-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 48px; align-items: start; }
.contact-grid .sec-head { display: block; }
.contact-grid .lede { margin-top: 14px; }
@media (max-width: 1099px) { .contact-grid { grid-template-columns: 1fr; gap: 32px; } }
.contact-cta { margin-top: 30px; }
.contact-cta .btn svg { width: 20px; height: 20px; }
.btn-line { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--line-2); }
.btn-line:hover { box-shadow: inset 0 0 0 1.5px var(--accent); }

@media (max-width: 1099px) {
  .branches { grid-template-columns: 1fr 1fr; }
  .branch:last-child:nth-child(3n+1) { grid-column: auto; }
  .branch:last-child:nth-child(odd) { grid-column: 1 / -1; }
}
@media (max-width: 720px) {
  body { font-size: 16px; }
  .hero { min-height: 74svh; padding-top: calc(var(--top-h) + 7vh); }
  .hero h1 { font-size: clamp(38px, 11vw, 52px); margin-bottom: 20px; }
  .hero .lead { font-size: 17px; margin-bottom: 26px; }
  .hear, .dream, .do, .tuning, .doors, .stands, .read-all { padding: 9vh 0; }
  .hear { padding-top: 2vh; }
  .stage { border-radius: 18px; }
  .stage-bar { position: static; border-radius: 0; background: #0a0f1c; border: 0; padding: 12px 12px 12px 16px; gap: 10px; }
  .stage-bar .title { font-size: 16px; }
  .stage-bar .eq { display: none; }
  .listen { height: 40px; padding: 0 15px; font-size: 14px; }
  .setlist button { grid-template-columns: 22px 64px minmax(0, 1fr) auto; gap: 10px; }
  .setlist .thumb { width: 64px; height: 40px; }
  .branches { grid-template-columns: 1fr; }
  .branch:last-child:nth-child(odd) { grid-column: auto; }
  .door { min-height: 0; }
  .timeline { --tl-pad: 18px; }
  .timeline::before, .timeline::after { left: calc(var(--tl-pad) + 6px); }
  .step { grid-template-columns: 1fr; gap: 4px; padding: 6px 0 20px 34px; }
  .step b { text-align: left; }
  .step::before { left: 0; top: 8px; }
}
@media (prefers-reduced-motion: reduce) {
  .step.now::before { animation: none; }
  .door:hover, .btn:hover { transform: none; }
}

/* near the home's words the sky fades: a soft veil of the page's colour behind each block of text, fading out from it */
.hero-copy, .hint, .sec-head, .dream-text, .tuning-text, .say, .stage-caption, .door-grid, .num-row, .branches, .timeline, .contact-cta { position: relative; isolation: isolate; }
.hero-copy::before, .hint::before, .sec-head::before, .dream-text::before, .tuning-text::before, .say::before, .stage-caption::before, .door-grid::before, .num-row::before, .branches::before, .timeline::before, .contact-cta::before {
  content: ''; position: absolute; inset: -48px -72px; z-index: -1; pointer-events: none;
  background: radial-gradient(closest-side, color-mix(in srgb, var(--bg) 62%, transparent) 55%, transparent 100%);
}
