/* Spike: animated stage + compact form + joined view. Layered on site.css. */
:root { --melody: #255b7f; --ring: #efbd44; }
/* Smaller form */
.lp .field { padding: 4px 4px 4px 16px; }
.lp .field input { font-size: 15px; padding: 7px 0; }
.lp .button { font-size: 14px; padding: 8px 16px; }
.lp .consent { font-size: 12.5px; margin-top: 12px; }
.lp-title .line { display: block; }
/* Entrance: hidden until stage.js reveals (JS-only; no-JS sees everything) */
.js [data-enter] { opacity: 0; }
/* Joined view: everything else clears */
.lp:has(#joined:not([hidden])) .lp-title, .lp:has(#joined:not([hidden])) .lp-sub, .lp:has(#joined:not([hidden])) .stage { display: none; }
.joined { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 24px 0 40px; }
.joined-icon { width: 64px; height: 64px; fill: none; stroke: var(--navy); stroke-width: 2.5; stroke-linejoin: round; margin-bottom: 8px; }
.joined .state-title { font-family: var(--font-display); font-size: clamp(32px, 5vw, 44px); letter-spacing: -0.02em; margin: 0; }
.joined .state-line { color: var(--muted); margin: 0 0 20px; }
/* Stage */
.stage-score { position: relative; }
.stage-score .score { overflow: visible; }
.hl { fill: var(--gold); opacity: 0; }
.melody-ring { fill: none; stroke: var(--ring); stroke-width: 3; }
.melody-line { fill: none; stroke: var(--melody); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; opacity: 0.85; }
.pointer path { fill: #000; stroke: #fff; stroke-width: 2; stroke-linejoin: round; }
.msg { position: absolute; margin: 0; max-width: min(22rem, 70%); padding: 10px 14px; border-radius: 16px; font-size: clamp(13px, 1.5vw, 15px); line-height: 1.4; opacity: 0; text-align: left; }
.msg-who { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; color: var(--navy); }
.msg-mark { width: 16px; height: auto; }
.dots { display: inline-flex; gap: 4px; height: 14px; align-items: center; }
.dots i { width: 6px; height: 6px; border-radius: 50%; background: var(--ink); opacity: 0.35; display: block; }
/* Footer icons */
.colophon-icons { display: inline-flex; gap: 14px; }
.colophon-icons a { display: inline-grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; color: var(--ink); }
.colophon-icons svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.colophon-icons a:hover { color: var(--navy); }
.colophon-icons a:focus-visible { outline: 3px solid var(--navy); outline-offset: 2px; }
/* Chat sits under the score, never over the notes */
.lp:has(#joined:not([hidden])) .join { display: none; }
@media (max-width: 560px) {
  .stage-score .score { width: 100%; max-width: 100%; margin: 0; }
  .lp .field input { padding: 10px 14px; padding: 11px 18px; font-size: 15px; }
  .lp .field .button { min-height: 44px; font-size: 14px; }
}
@media (max-width: 560px) {
  .stage-score { display: block; overflow: visible; overflow-x: clip; overflow-y: visible; }
}
/* Messages live on the score */
.msg-user { background: var(--navy); color: #fff; border-bottom-right-radius: 4px; right: 0; top: 0; right: auto; white-space: nowrap; border-radius: 16px 16px 16px 4px; box-shadow: 0 4px 14px rgba(0, 0, 0, 0.12); }
.msg-gaspard { background: #fff; color: var(--ink); border: 1.5px solid var(--ink); border-bottom-left-radius: 4px; display: flex; flex-direction: column; gap: 4px; left: 0; top: 0; max-width: min(24rem, 72%); box-shadow: 0 6px 18px rgba(0, 0, 0, 0.12); border-radius: 16px; }
@media (max-width: 560px) {
  .msg { max-width: 88%; font-size: 12.5px; padding: 8px 11px; }
  .msg-gaspard { max-width: 86%; }
}
/* Score sits between the tagline and the form */
.lp-copy { max-width: none; width: 100%; }
.lp-title, .lp-sub { max-width: 40rem; }
.lp .join { max-width: 26rem; margin: 0 auto; }
/* Replay: small, tucked into the card's bottom-right corner */
/* Phones: the form sticks to the bottom of the screen, button last (thumb zone) */
@media (max-width: 560px) {
  .lp .join .field { display: contents; }
  .lp .join #email { order: 1; }
  .lp .join .button { order: 4; width: 100%; }
}
.slur { fill: none; stroke: #000; stroke-width: 1.6; stroke-linecap: round; }
/* About line under the score */
.lp:has(#joined:not([hidden])) .lp-about { display: none; }
.lp-about strong { color: var(--ink); font-weight: 600; display: block; font-size: 17px; margin-bottom: 2px; }
.lp-about, .lp-about strong { text-wrap: balance; }
.lp-about .lp-em { color: var(--ink); font-weight: 600; }
/* v2 scene layers */
.fing { font-family: var(--font-body); font-size: 13px; font-weight: 700; fill: var(--navy); text-anchor: middle; dominant-baseline: middle; paint-order: stroke; stroke: #fffdf5; stroke-width: 3px; }
.flyer { fill: var(--navy); }
.pedal { fill: none; stroke: #B3261E; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.playhead { stroke: #B3261E; stroke-width: 2.5; stroke-linecap: round; }
.pin { position: absolute; display: flex; flex-direction: column; gap: 1px; padding: 6px 10px; border-radius: 10px 10px 10px 2px; background: var(--gold); color: var(--ink); font-size: 12.5px; line-height: 1.25; box-shadow: 0 4px 12px rgba(0, 0, 0, 0.14); opacity: 0; pointer-events: none; white-space: nowrap; }
.pin-label { font-size: 10.5px; font-weight: 700; text-transform: none; color: rgba(0, 0, 0, 0.7); }
.pin-text { font-weight: 600; }
.msg .marking { color: var(--navy); font-weight: 700; font-style: italic; font-family: "Times New Roman", Times, serif; font-size: 1.12em; letter-spacing: 0.02em; }
.chord-mark { fill: rgba(239, 189, 68, 0.18); stroke: var(--gold); stroke-width: 2; }
.weight-arc { fill: none; stroke: var(--gold); stroke-width: 2; stroke-linecap: round; }
.weight { fill: var(--gold); stroke: #8a6a12; stroke-width: 1; }
/* Question dots under the score */
.scene-dots { display: flex; justify-content: center; gap: 8px; margin-top: 14px; }
.scene-dot { width: 8px; height: 8px; padding: 0; border: 0; border-radius: 999px; background: rgba(0, 0, 0, 0.2); cursor: pointer; transition: width 240ms ease, background-color 240ms ease; }
.scene-dot:hover { background: rgba(0, 0, 0, 0.4); }
.scene-dot[aria-current="true"] { width: 24px; background: var(--navy); }
.scene-dot:focus-visible { outline: 2px solid var(--navy); outline-offset: 3px; }
@media (prefers-reduced-motion: reduce) {
  .scene-dot { transition: none; }
}
/* Sideways swipes on the score switch questions; vertical scrolling still works */
.stage { padding-bottom: clamp(16px, 3vw, 28px); touch-action: pan-y; user-select: none; -webkit-user-select: none; }
/* Above the fold: headline, score and the call to action fit the first screen */
.masthead { padding-top: 20px; padding-bottom: 4px; }
.lp { padding-top: clamp(12px, 3vh, 40px); padding-bottom: 32px; }
.lp-title { font-size: clamp(36px, min(6vw, 8vh), 68px); }
.lp-sub { margin-bottom: 0; margin-top: clamp(8px, 1.5vh, 16px); font-size: clamp(16px, 1.6vw, 19px); }
.lp .stage { margin: clamp(24px, 4vw, 40px) auto clamp(24px, 4vw, 36px); max-width: 52rem; margin: clamp(14px, 2.5vh, 28px) auto clamp(14px, 2.5vh, 24px); width: min(52rem, 100%, max(30rem, calc((100svh - 400px) * 1.68))); }
.lp-about { max-width: 34rem; margin: 0 auto clamp(24px, 4vw, 32px); font-size: 16px; line-height: 1.6; color: var(--muted); max-width: 40rem; font-size: 15.5px; max-width: 30rem; margin-top: clamp(20px, 3vh, 32px); margin-bottom: 0; }
/* The call to action flips like a coin to reveal the email field */
.lp .flip-inner { position: relative; display: grid; transform-style: preserve-3d; transition: transform 640ms cubic-bezier(0.34, 1.45, 0.5, 1); }
.lp .flip-front, .lp .flip-back { grid-area: 1 / 1; backface-visibility: hidden; -webkit-backface-visibility: hidden; }
.lp .flip-front { width: 100%; min-height: 52px; font-size: 16px; font-weight: 600; border-radius: 999px; box-shadow: 0 4px 0 var(--ink); }
.lp .flip-front:active { transform: translateY(2px); box-shadow: 0 2px 0 var(--ink); }
.lp .flip-back { transform: rotateY(180deg); }
.lp .is-flipped .flip-inner { transform: rotateY(180deg); }
.lp .flip-submit { width: 44px; min-width: 44px; height: 44px; padding: 0; display: grid; place-items: center; border-radius: 50%; }
.lp .flip-submit svg { width: 20px; height: 20px; fill: none; stroke: #fff; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.lp .join .consent { opacity: 0; transform: translateY(-6px); transition: opacity 300ms ease 260ms, transform 300ms ease 260ms; pointer-events: none; }
.lp .join.is-flipped .consent { opacity: 1; transform: none; pointer-events: auto; }
@media (prefers-reduced-motion: reduce) {
  .lp .flip-inner, .lp .join .consent { transition: none; }
}
@media (max-width: 560px) {
  .lp .join .flip .field { display: flex; flex-direction: row; gap: 6px; padding: 4px 4px 4px 16px; border: 1.5px solid var(--ink); border-radius: 999px; background: #fffdf5; }
  .lp .join .flip .field input { padding: 8px 0; border: 0; background: transparent; }
  .lp .join .flip .field .button { width: 44px; order: 0; }
}
@media (max-width: 560px) {
  .lp .join .flip #email { order: 0; flex: 1; min-width: 0; border: 0; border-radius: 0; background: transparent; padding: 8px 0; outline: none; }
  .lp .join .flip .flip-submit { order: 1; }
  .lp .join .flip .field:focus-within { outline: 2px solid var(--navy); outline-offset: 3px; }
}
.lp .flip .field input:focus { outline: none; }
.lp .flip .field:focus-within { outline: 2px solid var(--navy); outline-offset: 3px; }
/* Phones: the explanation comes first, then the call to action (still pinned to the bottom while scrolling) */
@media (max-width: 560px) {
  .lp .join, .lp .joined { order: 1; }
  .lp-about { margin: 8px auto 20px; margin: 4px auto 16px; }
}
/* Compact call to action; the back widens to fit the email field once flipped */
.lp .flip { perspective: 900px; width: 100%; max-width: 26rem; margin: 0 auto; max-width: 17rem; transition: max-width 420ms cubic-bezier(0.34, 1.3, 0.5, 1); }
.lp .join.is-flipped .flip { max-width: 26rem; }
@media (max-width: 560px) {
  .lp .join .flip { order: 1; width: 100%; max-width: 16rem; margin: 0 auto; }
  .lp .join.is-flipped .flip { max-width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  .lp .flip { transition: none; }
}
@media (max-width: 560px) {
  .lp .join:not(.is-flipped) .consent { display: none; }
}
/* Phones: the first screen fills the height, content centred, the call to action at the bottom (thumb zone) */
@media (max-width: 560px) {
  .lp { padding-top: 0; padding-bottom: 0; }
  .lp-copy { min-height: calc(100svh - 56px); }
  .lp-title { margin-top: auto; font-size: clamp(44px, 12.5vw, 58px); line-height: 1; }
  .lp-sub { font-size: 17px; margin-top: 12px; }
  .lp .stage { margin-bottom: 20px; width: 100%; margin-top: 20px; margin-bottom: 16px; }
  .lp .join { position: sticky; bottom: 0; z-index: 5; display: flex; flex-direction: column; gap: 10px; width: auto; max-width: none; margin: 0 calc(-1 * var(--gutter)); padding: 14px var(--gutter) calc(14px + env(safe-area-inset-bottom)); background: var(--cream); box-shadow: 0 -10px 24px rgba(0, 0, 0, 0.07); border-radius: 18px 18px 0 0; padding-top: 12px; padding-bottom: calc(12px + env(safe-area-inset-bottom)); align-self: stretch; margin-top: auto; padding-top: 16px; padding-bottom: calc(22px + env(safe-area-inset-bottom)); }
  .lp .join .flip-front { min-height: 54px; }
}
/* "Coming soon" line under the call to action */
.lp .join .soon { order: 3; margin: 10px 0 0; font-size: 13px; letter-spacing: 0.01em; color: var(--muted); text-align: center; margin: 10px 0 4px; }
@media (max-width: 560px) {
  .lp .join .error { order: 2; margin: 0; order: 1; }
  .lp .join .soon { order: 2; }
  .lp .join .consent { order: 3; margin: 0; order: 2; order: 3; }
}
/* "Coming soon" closes the paragraph, on its own line */
.lp-about .soon { display: block; margin-top: 8px; font-size: 14px; color: var(--navy); font-weight: 600; }
/* The arrow button sits inside the email pill: no drop shadow, a little inset from the edge */
.lp .flip .flip-submit:active { transform: scale(0.94); box-shadow: none; }
.lp .flip .flip-submit, .lp .join .flip .field .flip-submit { box-shadow: none; width: 38px; min-width: 38px; height: 38px; min-height: 38px; margin: 3px; align-self: center; border: 0; }
/* ---- Secondary pages: same voice as the landing ---------------------------------- */
.notice { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: clamp(32px, 8vh, 96px) 0; }
.notice .state, .notice > div { display: flex; flex-direction: column; align-items: center; }
.notice [hidden] { display: none !important; }
.state-icon { width: 64px; height: 64px; margin-bottom: 14px; fill: none; stroke: var(--navy); stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; }
.notice-title { font-family: var(--font-display); font-weight: 450; font-variation-settings: "opsz" 144; font-size: clamp(32px, 6vw, 52px); line-height: 1.05; letter-spacing: -0.03em; margin: 0; text-wrap: balance; }
.notice-line { margin: 12px 0 0; color: var(--muted); font-size: 17px; max-width: 30rem; text-wrap: balance; }
.notice .notice-action, .notice .tester { margin-top: 24px; display: flex; flex-direction: column; align-items: center; gap: 10px; }
.notice .tester .fineprint, .joined .tester .fineprint { font-size: 13px; color: var(--muted); margin: 0; }
/* Clear room between the tester button (and its 4px raised edge) and the sentence under it. */
.joined .tester .fineprint { margin-top: 18px; }
.notice .tester .fineprint { margin-top: 8px; } /* plus the 10px flex gap */
.notice .state-note, .joined .state-note { margin-top: 20px; font-weight: 600; color: var(--navy); }
/* Raised pill buttons everywhere (as on the landing) */
.notice .button, .joined .button { border-radius: 999px; min-height: 48px; padding: 0 24px; font-size: 15px; font-weight: 600; box-shadow: 0 4px 0 var(--ink); border: 1.5px solid var(--ink); }
.notice .button:active, .joined .button:active { transform: translateY(2px); box-shadow: 0 2px 0 var(--ink); }
.notice .button-quiet, .joined .button-quiet { background: #fffdf5; color: var(--navy); }
.notice .button-quiet:hover, .joined .button-quiet:hover { background: #fff; }
/* Privacy: a readable column with the shield on top */
.prose-page .state-icon, main .state-icon + h1 { display: block; }
main:has(> .state-icon) { text-align: left; }
@media (max-width: 560px) {
  .notice { padding: 24px 0 40px; }
  .notice .button, .joined .button { width: 100%; max-width: 20rem; }
}
/* Phones: the answer is centred on a point of the score, and an absolutely placed box shrinks to
   the room right of that point (about 40% of the stage), which made it tall and narrow. A fixed
   width keeps it to two or three lines. */
@media (max-width: 560px) {
  .msg-gaspard { width: 88%; max-width: 88%; }
}
