/* The landing page: the spine in the first viewport, then secrets, the table, the app, yours, early access. */

/* ---------------------------------------------------------------- hero */
.hero { padding-top: clamp(1.5rem, 4vh, 3rem); }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1fr) 23rem; gap: 2.5rem 3.5rem; align-items: start; }
.hero-copy, .sel-panel { grid-row: 1; }
.hero-copy { max-width: 42rem; }
.hero-copy .lead { margin-top: 1.4rem; }
.ask { display: flex; flex-wrap: wrap; gap: 0.6rem; margin-top: 2rem; max-width: 34rem; }
.ask .input { flex: 1 1 15rem; min-width: 0; height: 3rem; border-radius: 999px; padding: 0 1.25rem; }
.ask .btn { --h: 3rem; padding: 0 1.5rem; font-size: 0.9375rem; }
.ask .say { flex-basis: 100%; padding-left: 1.25rem; }
.ask-alt { margin-top: 0.9rem; font-size: 0.875rem; color: var(--text-2); max-width: 34rem; }

/* the floating panel: what the selected thing touches */
.sel-panel {
  position: relative; height: var(--copy-h, auto); max-height: 25rem; padding: 1.1rem 1.1rem 0.75rem;
  border-radius: 16px; border: 1px solid var(--hairline); background: var(--float);
  overflow-y: auto; overscroll-behavior: contain;
}
.sel-hint { font-size: 0.875rem; color: var(--text-2); }
.sel-hint:empty { display: none; }
.sel-body.swap { animation: sel-in 0.32s var(--ease) both; }
@keyframes sel-in { from { opacity: 0; transform: translateY(0.35rem); } to { opacity: 1; transform: none; } }
.sel-title { font-family: var(--display); font-weight: 300; font-size: 1.5rem; line-height: 1.15; letter-spacing: -0.02em; color: var(--now); text-wrap: balance; }
.sel-status { display: flex; flex-wrap: wrap; align-items: center; gap: 0.35rem 0.6rem; margin-top: 0.6rem; font-size: 0.875rem; }
.sel-meta { margin-top: 0.4rem; font-size: 0.8125rem; line-height: 1.5; color: var(--text-2); }
.sel-sum { margin-top: 0.75rem; font-size: 0.875rem; line-height: 1.6; color: var(--text-2); }
.sel-gm { margin-top: 0.75rem; padding: 0.7rem 0.85rem; border-radius: 12px; border: 1px solid var(--gm-line); background: var(--gm-tint); font-size: 0.8125rem; line-height: 1.55; color: var(--gm-soft); }
.sel-gm b { display: flex; align-items: center; gap: 0.35rem; margin-bottom: 0.2rem; color: var(--gm); font-weight: 600; }
.sel-touch { margin-top: 0.85rem; }
.sel-touch h3 { font-size: 0.8125rem; font-weight: 500; color: var(--text-2); margin: 0.5rem 0 0.1rem; }
.sel-touch h3:first-child { margin-top: 0; }
.sel-touch ul { list-style: none; margin: 0; padding: 0; }
.sel-touch li { display: flex; align-items: center; gap: 0.6rem; min-height: 2.125rem; border-top: 1px solid var(--hairline); font-size: 0.875rem; color: var(--text-2); }
.sel-touch li:first-child { border-top: 0; }
.sel-touch li.lit { color: var(--text); }
.sel-touch li .via { margin-left: auto; font-size: 0.75rem; color: var(--text-2); white-space: nowrap; }
.sel-touch li button { all: unset; display: flex; align-items: center; gap: 0.6rem; flex: 1; min-height: 2.125rem; cursor: pointer; color: inherit; border-radius: 6px; }
.sel-touch li button:hover { color: var(--now-hover); }
.sel-touch li button:focus-visible { outline: 2px solid var(--now); outline-offset: 2px; }
.sel-touch .lp { margin: 0 0.1rem; }
.sel-more {
  position: sticky; bottom: -0.75rem; display: flex; align-items: center; gap: 0.5rem; width: calc(100% + 2.2rem);
  margin: 0 -1.1rem -0.75rem; padding: 0.7rem 1.1rem 0.75rem; border: 0; border-top: 1px solid var(--hairline-strong); border-radius: 0 0 15px 15px;
  background: var(--float); color: var(--text-2);
  font: 500 0.8125rem/1.3 var(--sans); text-align: left; cursor: pointer;
}
.sel-more::after { content: ""; width: 0.4rem; height: 0.4rem; margin-top: -0.2rem; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: rotate(45deg); }
.sel-more:hover { color: var(--text); }
.sel-more:focus-visible { outline: 2px solid var(--now); outline-offset: -2px; }

/* ---------------------------------------------------------------- the spine */
.spine-stage { position: relative; margin: clamp(1rem, 3vh, 2rem) 0 0; }
.spine-scroll { overflow-x: auto; overflow-y: hidden; scrollbar-width: none; }
.spine-scroll::-webkit-scrollbar { display: none; }
.spine { min-width: 80rem; }
.spine svg { width: 100%; height: auto; overflow: visible; }
.spine-still { width: 100%; max-width: 76rem; margin: 0 auto; border-radius: 16px; border: 1px solid var(--hairline); }
.spine-cap { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem 1.4rem; margin-top: 0.5rem; font-size: 0.8125rem; color: var(--text-2); }
.spine-cap .key { display: inline-flex; align-items: center; gap: 0.5rem; }
.spine-cap .key-note { margin-left: auto; }
.swipe-hint { display: none; }

/* labels carry a halo of the void, so a line passing under a name never crosses its letters */
.sp-text, .sp-next-title { paint-order: stroke; stroke: var(--void); stroke-width: 5px; stroke-linejoin: round; }
.sp-text { font-family: var(--sans); fill: var(--text-2); transition: fill var(--t-state) var(--ease); }
.sp-next-title { font-family: var(--display); font-weight: 300; fill: var(--now); letter-spacing: -0.02em; }
.sp-date { fill: var(--text-2); }
.sp-arc { font-weight: 300; fill: var(--text-2); }
.sp-node { cursor: pointer; outline: none; }
.sp-node .hit { fill: transparent; }
.sp-node .sel-ring { fill: none; stroke: var(--now); stroke-width: 1.2; opacity: 0; transition: opacity 0.2s var(--ease); }
.sp-node:focus-visible .sel-ring, .sp-node[aria-pressed="true"] .sel-ring { opacity: 1; }
.sp-node:focus-visible .focus-ring { opacity: 1; }
.sp-node .focus-ring { fill: none; stroke: var(--now); stroke-width: 2; opacity: 0; }
.sp-node:hover .sp-text, .sp-node:focus-visible .sp-text, .sp-node.lit .sp-text { fill: var(--text); }
.sp-node .mk, .sp-node .glow, .sp-line { transition: opacity 0.25s var(--ease); }
.spine.has-sel .sp-node:not(.rel):not([aria-pressed="true"]) .mk,
.spine.has-sel .sp-node:not(.rel):not([aria-pressed="true"]) .glow { opacity: 0.16; }
.spine.has-sel .sp-node:not(.rel):not([aria-pressed="true"]) .sp-text { fill: var(--text-2); }
.spine.has-sel .sp-line:not(.rel) { opacity: 0.12; }
.sp-lock { transition: opacity 0.25s var(--ease); }
.spine.has-sel .sp-node:not(.rel):not([aria-pressed="true"]) .sp-lock { opacity: 0.7; }
html.rm .sp-current { display: none; }
.spine.has-sel .sp-node.rel .sp-text, .spine.has-sel .sp-node[aria-pressed="true"] .sp-text { fill: var(--now); }
.spine.has-sel .sp-node.rel .glow { transform-box: fill-box; transform-origin: center; transform: scale(1.6); }
.sp-node .glow { transition: transform 0.25s var(--ease), opacity 0.25s var(--ease); }

/* the intro: the light runs left to right once, then rests */
html.motion .spine.intro .sp-fil { stroke-dasharray: var(--len) var(--len); stroke-dashoffset: var(--len); animation: draw 1.6s var(--ease) 0.15s forwards; }
html.motion .spine.intro .sp-bloom { opacity: 0; animation: fade-in 0.9s var(--ease) 1.25s forwards; }
html.motion .spine.intro .sp-node, html.motion .spine.intro .sp-line { opacity: 0; animation: fade-in 0.5s var(--ease) forwards; animation-delay: var(--at, 0.4s); }
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes fade-in { to { opacity: 1; } }

/* ---------------------------------------------------------------- sections */
.sec { padding: clamp(5rem, 11vh, 8.5rem) 0; }
.sec-head { max-width: 30rem; }
.sec-head .lead { margin-top: 1.25rem; }
.sec-head-wide { max-width: 44rem; }

/* secrets */
.secrets-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 3rem 4rem; align-items: center; }
.pv-row { display: flex; flex-wrap: wrap; align-items: center; gap: 0.75rem 1rem; margin-top: 2rem; }
.switch { display: inline-flex; align-items: center; gap: 0.75rem; cursor: pointer; font-size: 0.9375rem; font-weight: 500; }
.switch input { position: absolute; opacity: 0; width: 2.5rem; height: 1.5rem; margin: 0; cursor: pointer; }
.switch-ui { position: relative; width: 2.5rem; height: 1.5rem; border-radius: 999px; background: var(--raised); border: 1px solid var(--hairline-strong); transition: background 0.2s var(--ease), border-color 0.2s var(--ease); }
.switch-ui::after { content: ""; position: absolute; top: 3px; left: 3px; width: 1rem; height: 1rem; border-radius: 50%; background: var(--text-2); transition: transform 0.2s var(--ease), background 0.2s var(--ease); }
.switch:hover .switch-ui::after { background: var(--text); }
.switch input:checked + .switch-ui { background: var(--now); border-color: var(--now); }
.switch input:checked + .switch-ui::after { transform: translateX(1rem); background: var(--void); }
.switch input:focus-visible + .switch-ui { outline: 2px solid var(--now); outline-offset: 3px; }
.switch:active .switch-ui::after { transform: scale(0.9); }
.switch input:checked:active + .switch-ui::after { transform: translateX(1rem) scale(0.9); }

.entry { position: relative; padding: 2rem; border-radius: 16px; border: 1px solid var(--hairline); background: var(--float); overflow: hidden; }
.entry::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 2px; background: var(--now); transform: scaleX(0); transform-origin: left; transition: transform 0.45s var(--ease); }
.entry.pv::before { transform: none; }
.entry-name { font-family: var(--display); font-weight: 200; font-size: clamp(2rem, 1.4rem + 1.8vw, 3rem); line-height: 1.05; letter-spacing: -0.025em; color: var(--now); }
.entry-meta { margin-top: 0.5rem; font-size: 0.875rem; color: var(--text-2); }
.entry-cols { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.5rem; margin-top: 1.75rem; transition: grid-template-columns 0.45s var(--ease); }
.entry.pv .entry-cols { grid-template-columns: minmax(0, 1fr) minmax(0, 0fr); gap: 0; }
.entry-part h4 { display: flex; align-items: center; gap: 0.4rem; font-size: 1rem; font-weight: 600; margin-bottom: 0.6rem; }
.entry-part p { font-size: 0.9375rem; line-height: 1.7; }
.ref { text-decoration: underline; text-decoration-color: rgba(232, 234, 240, 0.4); text-underline-offset: 0.22em; }
.gm-block { padding: 1.25rem; border-radius: 16px; border: 1px solid var(--gm-line); background: var(--gm-tint); min-width: 0; transition: opacity 0.3s var(--ease), filter 0.35s var(--ease), transform 0.35s var(--ease); }
.gm-block h4 { color: var(--gm); }
.gm-block p { color: var(--gm-soft); }
.gm-ref { text-decoration-style: dashed; text-decoration-color: rgba(182, 156, 255, 0.55); }
.entry.pv .gm-block { opacity: 0; filter: blur(6px); transform: translateX(1rem); }
.entry-foot { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-top: 1.5rem; }
.entry-foot .tag { transition: opacity 0.3s var(--ease); }
.entry.pv #gm-tag { opacity: 0; }

/* the table */
.table-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 3rem 4rem; align-items: start; }
.run { position: relative; padding: 1.75rem 1.75rem 2rem; border-radius: 16px; border: 1px solid var(--hairline); background:
  radial-gradient(28rem 14rem at 30% var(--bloom-y, 30%), rgba(244, 247, 255, 0.055), transparent 70%), var(--void); transition: background-position 0.3s var(--ease); }
.run-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 0.5rem 1rem; padding-bottom: 1.25rem; border-bottom: 1px solid var(--hairline); }
.run-title { font-family: var(--display); font-weight: 300; font-size: 1.375rem; letter-spacing: -0.02em; color: var(--text); }
.rail { position: relative; list-style: none; margin: 1.5rem 0 0; padding: 0 0 0 2.25rem; }
.rail::before { content: ""; position: absolute; left: 0.6rem; top: 0.4rem; bottom: 0.4rem; width: 1px; background: var(--hairline-strong); }
.rail-pulse { position: absolute; top: 0; left: 2.3rem; width: 3px; height: 4rem; border-radius: 3px; background: linear-gradient(to bottom, transparent, var(--now), transparent); pointer-events: none; opacity: 0; }
.beat { position: relative; min-height: 2.75rem; padding: 0.55rem 0; font-size: 0.9375rem; line-height: 1.5; color: var(--text-2); transition: color 0.25s var(--ease); }
.beat::before { content: ""; position: absolute; left: calc(-2.25rem + 0.6rem - 0.625rem); top: 0.7rem; width: 1.25rem; height: 1.25rem; border-radius: 50%; border: 1.5px solid rgba(255, 255, 255, 0.34); background: var(--void); box-sizing: border-box; transition: all 0.25s var(--ease); }
.beat.done { color: var(--text-2); }
.beat.done::before { border-color: var(--text-2); background: var(--text-2) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6 12.5l4 4L18 8' fill='none' stroke='%2307080b' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 0.8rem no-repeat; }
.beat.now { padding: 1rem 0 1.25rem; font-family: var(--display); font-weight: 300; font-size: clamp(1.5rem, 1.1rem + 1.2vw, 2.25rem); line-height: 1.2; letter-spacing: -0.02em; color: var(--now); text-shadow: 0 0 1.75rem rgba(244, 247, 255, 0.22); text-wrap: balance; max-width: 24ch; }
.beat.now::before { top: 1.45rem; border-color: var(--now); box-shadow: 0 0 0 0.3rem rgba(244, 247, 255, 0.1), 0 0 1rem rgba(244, 247, 255, 0.45); }
.beat.now::after { content: attr(data-kind) " · " attr(data-refs); display: block; margin-top: 0.75rem; font-family: var(--sans); font-size: 0.875rem; font-weight: 400; letter-spacing: 0; color: var(--text-2); text-shadow: none; }
.beat.arrive { animation: arrive 0.62s var(--ease) both; }
@keyframes arrive { from { opacity: 0.25; } to { opacity: 1; } }
.run-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 0.75rem 1rem; margin-top: 1.25rem; padding-left: 2.25rem; }

/* the app's own screens */
.shots { margin-top: 2.5rem; }
.shot-tabs { display: inline-flex; gap: 0.25rem; padding: 0.25rem; border-radius: 999px; border: 1px solid var(--hairline); background: var(--surface); }
.shot-tabs [role="tab"] { height: 2rem; padding: 0 1rem; border-radius: 999px; border: 0; background: transparent; color: var(--text-2); font: 400 0.8125rem/1 var(--sans); cursor: pointer; transition: background var(--t-state) var(--ease), color var(--t-state) var(--ease); }
.shot-tabs [role="tab"]:hover { color: var(--text); }
.shot-tabs [role="tab"][aria-selected="true"] { background: var(--raised); color: var(--now); box-shadow: inset 0 0 0 1px var(--hairline-strong); }
.shot-view { position: relative; margin-top: 1.25rem; border-radius: 16px; border: 1px solid var(--hairline); overflow: hidden; aspect-ratio: 16 / 10; background: var(--void); }
.shot-view picture { display: contents; }
.shot-view img { width: 100%; height: 100%; object-fit: cover; object-position: top left; }
.shot-view img.enter { animation: shot-in 0.42s var(--ease) both; }
@keyframes shot-in { from { opacity: 0; filter: blur(6px); } to { opacity: 1; filter: none; } }

/* yours */
.yours-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 3rem 4rem; align-items: start; }
.facts { margin: 0; }
.facts > div { display: grid; grid-template-columns: 9.5rem minmax(0, 1fr); gap: 0.25rem 2rem; padding: 1rem 0; border-top: 1px solid var(--hairline); }
.facts > div:first-child { border-top: 0; padding-top: 0.25rem; }
.facts dt { color: var(--text-2); font-size: 0.9375rem; }
.facts dd { margin: 0; font-size: 0.9375rem; line-height: 1.65; }

/* early access */
.access { padding-bottom: clamp(5rem, 12vh, 9rem); }
.access-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 3rem 4rem; align-items: start; }
.ask-full { display: grid; gap: 1.1rem; padding: 1.75rem; }
.ask-full .actions .hint { flex: 1 1 12rem; }
#wl-notice { margin-top: 1.5rem; }
.buy { margin-top: 2rem; padding-top: 1.5rem; border-top: 1px solid var(--hairline); display: grid; gap: 0.6rem; justify-items: start; }
.buy-line { font-size: 1rem; }
.price { font-family: var(--display); font-weight: 300; font-size: 1.5rem; color: var(--now); font-variant-numeric: tabular-nums; }

/* ---------------------------------------------------------------- narrower */
@media (max-width: 1100px) {
  .hero-grid { grid-template-columns: minmax(0, 1fr) 20rem; gap: 2rem; }
}
@media (max-width: 1000px) {
  .secrets-grid, .table-grid, .yours-grid, .access-grid { grid-template-columns: minmax(0, 1fr); }
  .sec-head { max-width: 40rem; }
}
@media (max-width: 860px) {
  .hero { display: flex; flex-direction: column; }
  .hero-grid { display: contents; }
  .hero-copy { order: 1; padding: 0 var(--gutter); }
  .spine-stage { order: 2; margin-top: 1.5rem; }
  .sel-panel { order: 3; margin: 1.25rem var(--gutter) 0; height: auto; max-height: none; overflow: visible; }
  .swipe-hint { display: inline; }
  .spine-cap .key-note { margin-left: 0; flex-basis: 100%; }
}
@media (max-width: 760px) {
  .ask .btn { flex: 1 1 100%; }
  .entry { padding: 1.25rem; }
  .entry-cols { grid-template-columns: minmax(0, 1fr); }
  .entry.pv .entry-cols { grid-template-columns: minmax(0, 1fr); }
  .entry.pv .gm-block { transform: translateY(0.5rem); }
  .run { padding: 1.25rem 1.1rem 1.5rem; }
  .facts > div { grid-template-columns: minmax(0, 1fr); }
  .shot-tabs { display: flex; width: 100%; }
  .shot-tabs [role="tab"] { flex: 1 1 0; padding: 0 0.5rem; }
  .shot-view { aspect-ratio: 4 / 3; }
}
@media (max-width: 640px) {
  .shot-view { aspect-ratio: 1 / 1; }      /* a closer crop of each screen, so its text can be read */
}
