/* Keep & Quit — keepandquit.com
   Light first (Real Sober 1.1 light shell from the app's tokens.ts), dark follows the system.
   Colour lives only in habit cards; chrome and type stay ink/silver (brand-guide.md). */

@font-face {
  font-family: "Inter";
  src: url(/fonts/inter-latin.woff2) format("woff2");
  font-weight: 100 900;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+2010-2027, U+2030-203A, U+20AC, U+2122, U+2190-2193;
}
@font-face {
  font-family: "Inter";
  src: url(/fonts/inter-tr.woff2) format("woff2");
  font-weight: 100 900;
  font-display: swap;
  unicode-range: U+011E-011F, U+0130, U+015E-015F;
}
@font-face {
  font-family: "Anton";
  src: url(/fonts/anton-num.woff2) format("woff2");
  font-weight: 400;
  font-display: swap;
  unicode-range: U+0020, U+0030-003A;
}

:root {
  color-scheme: light dark;
  --bg: #f4f5f7;
  --surface: #ffffff;
  --elev: #e9ebf0;
  --raised: #dcdfe6;
  --line: #e1e4ea;
  --ink: #121318;
  --ink2: #4a4f5f;
  --ink3: #676c7b;
  --on-ink: #ffffff;
  --band: #0e0e10;
  --band-ink: #f2f2f5;
  --band-dim: #6c6c77;
  --frame: #121318;
  --shadow: 0 1px 2px rgba(18, 19, 24, 0.06), 0 18px 40px -22px rgba(18, 19, 24, 0.28);

  --ember: #ff6a00;  --ember2: #ff9e2c;
  --amber: #e39400;  --amber2: #f6b93b;
  --mint: #00a85a;   --mint2: #2ed18a;
  --sky: #0a84ff;    --sky2: #4fb3ff;
  --rose: #ff3b7b;   --rose2: #ff7fa8;
  --orchid: #8e5bff; --orchid2: #b98cff;

  --font: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --num: "Anton", Impact, "Arial Narrow", sans-serif;
  --gutter: 16px;
  --max: 1200px;
  --ease: cubic-bezier(0.2, 0.8, 0.2, 1);
  --grain: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #000000;
    --surface: #0e0e10;
    --elev: #161618;
    --raised: #1f1f22;
    --line: #2a2a2e;
    --ink: #f2f2f5;
    --ink2: #a3a3ac;
    --ink3: #80808b;
    --on-ink: #000000;
    --band: #0e0e10;
    --frame: #1f1f22;
    --shadow: 0 0 0 1px #2a2a2e;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 17px/1.55 var(--font);
  font-feature-settings: "cv11", "ss03";
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: clip;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; border-radius: 6px; }
::selection { background: var(--ink); color: var(--bg); }

.wrap { width: 100%; max-width: calc(var(--max) + 2 * var(--gutter)); margin: 0 auto; padding: 0 var(--gutter); }
@media (min-width: 768px) { :root { --gutter: 32px; } }
@media (min-width: 1280px) { :root { --gutter: 40px; } }

.sr-only {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip { position: absolute; left: 12px; top: -60px; z-index: 10; background: var(--ink); color: var(--on-ink);
  padding: 10px 14px; border-radius: 10px; font-weight: 700; text-decoration: none; }
.skip:focus { top: 12px; }

/* ---------- type ---------- */
.kicker {
  margin: 0 0 14px;
  font-size: 12px; font-weight: 800; letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--ink3);
}
.h2 {
  margin: 0;
  font-size: clamp(32px, 5.2vw, 60px);
  font-weight: 900; line-height: 1.02; letter-spacing: -0.04em;
  text-wrap: balance;
}
.body { color: var(--ink2); font-size: 18px; max-width: 34em; margin: 18px 0 0; text-wrap: pretty; }

/* ---------- brand files (referenced, never inlined; the kit is refined under the same names) ----------
   The files are ink (#0E0E10) on transparent. Inverted they read as the brand's silver on dark. */
.wordmark { display: block; height: 22px; width: auto; }
.lockup { display: block; height: 60px; width: auto; }
.mark { display: block; height: 22px; width: auto; }
@media (min-width: 768px) { .wordmark { height: 26px; } }
@media (prefers-color-scheme: dark) { .wordmark, .lockup { filter: invert(1); } }

/* ---------- header ---------- */
.top { padding: 18px 0; }
.top .wrap { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.brandlink { display: block; padding: 8px 0; border-radius: 6px; }
.top-actions { display: flex; align-items: center; gap: 10px; }
.top-link {
  font-size: 14px; font-weight: 700; text-decoration: none; color: var(--ink);
  padding: 9px 14px; border-radius: 999px; background: var(--surface); box-shadow: var(--shadow);
  white-space: nowrap;
}
.top-link:hover { background: var(--elev); }
@media (max-width: 559px) { .top-link { display: none; } }

.lang {
  display: inline-flex; padding: 3px; border-radius: 999px; background: var(--elev);
}
.lang button {
  appearance: none; border: 0; background: transparent; cursor: pointer;
  font-size: 12px; font-weight: 800; letter-spacing: 0.08em;
  min-width: 40px; min-height: 32px; padding: 0 10px; border-radius: 999px; color: var(--ink2);
}
.lang button[aria-pressed="true"] { background: var(--surface); color: var(--ink); box-shadow: 0 1px 2px rgba(0,0,0,.08); }

html:not(.js) .lang, html:not(.js) .hint { display: none; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 54px; padding: 0 26px; border-radius: 16px;
  background: var(--ink); color: var(--on-ink);
  font-size: 17px; font-weight: 800; letter-spacing: -0.01em; text-decoration: none;
  transition: transform 0.2s var(--ease), opacity 0.2s;
}
.btn:hover { opacity: 0.9; }
.btn:active { transform: scale(0.97); }
.btn svg { width: 18px; height: 18px; flex: none; }
.soon {
  display: inline-flex; flex-direction: column; justify-content: center;
  min-height: 54px; padding: 6px 18px; border-radius: 16px;
  border: 1.5px solid var(--raised); color: var(--ink); line-height: 1.1;
}
.soon .s1 { font-size: 11px; font-weight: 700; letter-spacing: 0.02em; color: var(--ink3); }
.soon .s2 { font-size: 19px; font-weight: 800; letter-spacing: -0.02em; }
.cta-row { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 28px; }
@media (max-width: 419px) {
  .cta-row .btn { min-height: 52px; padding: 0 18px; font-size: 16px; gap: 8px; }
  .cta-row .soon { min-height: 52px; padding: 5px 14px; }
  .soon .s2 { font-size: 17px; }
  .hero .body { font-size: 16px; }
  .lede { font-size: 19px; }
}

/* ---------- hero ---------- */
.hero { padding: 20px 0 72px; }
.hero .wrap { display: grid; gap: 40px; align-items: center; }
.hero h1 {
  margin: 0;
  font-size: clamp(38px, 9.6vw, 50px);
  font-weight: 900; line-height: 0.98; letter-spacing: -0.045em;
}
.hero h1 .l { display: block; }
.hero h1 .dim { color: var(--ink3); }
.lede { margin: 22px 0 0; font-size: 20px; font-weight: 700; letter-spacing: -0.02em; }
.lede + .body { margin-top: 8px; }
@media (min-width: 700px) {
  .hero h1 { font-size: clamp(50px, 7.4vw, 76px); }
}
@media (min-width: 1000px) {
  .hero { padding: 48px 0 110px; }
  .hero .wrap { grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr); gap: 56px; }
  .hero h1 { font-size: clamp(52px, 4.9vw, 74px); }
  .hero h1 .l { white-space: nowrap; }
  .lede { font-size: 22px; }
}

/* ---------- habit cards (the showpiece) ---------- */
.cards {
  position: relative;
  display: grid; grid-template-columns: 1fr 1fr; gap: 12px;
  width: 100%; max-width: 520px; justify-self: center;
}
.card {
  --c1: var(--ember); --c2: var(--ember2);
  position: relative; isolation: isolate; overflow: hidden;
  border-radius: 24px; padding: 16px 16px 14px;
  color: rgba(255, 255, 255, 0.94);
  background:
    radial-gradient(120% 90% at 100% 0%, rgba(255, 255, 255, 0.2), transparent 55%),
    linear-gradient(20deg, var(--c1) 0%, var(--c2) 100%);
  box-shadow: 0 22px 44px -26px var(--c1), 0 2px 6px -2px color-mix(in srgb, var(--c1) 50%, transparent);
  text-shadow: 0 1px 1px rgba(0, 0, 0, 0.08);
  display: flex; flex-direction: column;
}
.card::after {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: var(--grain); mix-blend-mode: overlay; opacity: 0.42;
}
.card.quit { grid-column: 1 / -1; min-height: 232px; }
.card.keep { min-height: 204px; }
.card.sky { --c1: var(--sky); --c2: var(--sky2); }
.card.mint { --c1: var(--mint); --c2: var(--mint2); }

.c-label { font-size: 11px; font-weight: 800; letter-spacing: 0.16em; opacity: 0.85; }
.c-title { margin-top: 2px; font-size: 17px; font-weight: 800; letter-spacing: -0.02em; line-height: 1.15; }
.c-since { position: absolute; top: 16px; right: 16px; font-size: 12px; font-weight: 700; opacity: 0.85; }
.c-foot { margin-top: auto; display: flex; align-items: flex-end; justify-content: space-between; gap: 10px; }
.c-num { font-family: var(--num); font-weight: 400; line-height: 1; letter-spacing: 0; font-variant-numeric: tabular-nums; }
.quit .c-num.big { font-size: 112px; margin-top: 6px; }
.keep .c-num.big { font-size: 80px; }
.c-unit { margin-top: 6px; font-size: 11px; font-weight: 800; letter-spacing: 0.16em; }
.clock { display: flex; gap: 10px; text-align: center; }
.clock .c-num { font-size: 30px; }
.clock .c-unit { margin-top: 4px; font-size: 10px; letter-spacing: 0.14em; opacity: 0.85; }
@media (max-width: 559px) {
  .keep .tap { position: absolute; right: 14px; bottom: 36px; width: 44px; height: 44px; }
  .keep .c-unit { white-space: nowrap; }
}
.keep .c-unit .on { display: none; }
.keep.is-kept .c-unit .on { display: inline; }
.keep.is-kept .c-unit .off { display: none; }

@media (min-width: 560px) {
  .cards { gap: 14px; }
  .card { padding: 20px 20px 18px; border-radius: 28px; }
  .card.quit { min-height: 290px; }
  .card.keep { min-height: 244px; }
  .c-title { font-size: 20px; }
  .c-since { top: 20px; right: 20px; }
  .quit .c-num.big { font-size: 150px; }
  .keep .c-num.big { font-size: 104px; }
  .clock { gap: 14px; }
  .clock .c-num { font-size: 40px; }
}

/* rolling digits: each digit is a reel of 0-9 twice (the second run lets 9 -> 0 roll forward) */
.roll { display: inline-flex; }
.roll .d { display: inline-block; height: 1em; overflow: hidden; }
.roll .reel { display: flex; flex-direction: column; transition: transform 0.45s var(--ease); will-change: transform; }
.roll .reel > span { display: block; height: 1em; line-height: 1; text-align: center; }
.roll .reel.snap { transition: none; }

/* the one-tap control: ring -> disc */
.tap {
  position: relative; flex: none; appearance: none; cursor: pointer;
  width: 48px; height: 48px; border-radius: 50%; padding: 0;
  border: 2.5px solid rgba(255, 255, 255, 0.9); background: transparent;
  display: grid; place-items: center;
  transition: background-color 0.35s var(--ease), transform 0.2s var(--ease);
}
.tap:active { transform: scale(0.9); }
.tap:focus-visible { outline: 3px solid #fff; outline-offset: 3px; }
.tap svg { width: 22px; height: 22px; overflow: visible; }
.tap .plus { transform-box: fill-box; transform-origin: center; stroke: #fff; transition: opacity 0.2s, transform 0.35s var(--ease); }
.tap .check { stroke: var(--c1); stroke-dasharray: 30; stroke-dashoffset: 30; transition: stroke-dashoffset 0.4s 0.12s var(--ease); }
.keep.is-kept .tap { background: #fff; }
.keep.is-kept .tap .plus { opacity: 0; transform: rotate(90deg) scale(0.4); }
.keep.is-kept .tap .check { stroke-dashoffset: 0; }
.tap::before { /* bigger hit area */
  content: ""; position: absolute; inset: -8px; border-radius: 50%;
}
.sliver {
  position: absolute; left: 50%; top: 50%; width: 3px; height: 12px; margin: -6px 0 0 -1.5px;
  border-radius: 2px; background: #fff; pointer-events: none;
  animation: sliver 0.7s var(--ease) forwards;
}
@keyframes sliver {
  from { opacity: 1; transform: rotate(var(--a)) translateY(-14px) scaleY(0.4); }
  to { opacity: 0; transform: rotate(var(--a)) translateY(-44px) scaleY(1); }
}

.hint {
  grid-column: 1 / -1; margin: 6px 0 0; text-align: center;
  font-size: 13px; font-weight: 600; color: var(--ink3);
}
.hint svg { width: 14px; height: 14px; vertical-align: -2px; margin-right: 4px; }

/* friend quick-message toast */
.toast {
  position: absolute; left: 50%; bottom: 30px; z-index: 2;
  display: flex; align-items: center; gap: 10px;
  width: max-content; max-width: calc(100% - 24px);
  padding: 10px 16px 10px 10px; border-radius: 18px;
  background: var(--surface); color: var(--ink); box-shadow: 0 18px 40px -12px rgba(18, 19, 24, 0.35), 0 0 0 1px var(--line);
  opacity: 0; transform: translate(-50%, 16px) scale(0.96); pointer-events: none;
  transition: opacity 0.3s var(--ease), transform 0.45s var(--ease);
}
.toast.show { opacity: 1; transform: translate(-50%, 0) scale(1); }
.toast .av {
  width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; flex: none;
  font-weight: 900; font-size: 14px; color: #fff; background: linear-gradient(20deg, var(--rose), var(--rose2));
}
.toast[data-v="sky"] .av { background: linear-gradient(20deg, var(--orchid), var(--orchid2)); }
.toast .who { display: block; font-size: 13px; font-weight: 800; }
.toast .who .t { font-weight: 600; color: var(--ink3); margin-left: 6px; }
.toast .msg { display: block; font-size: 15px; font-weight: 700; letter-spacing: -0.01em; }
.toast [data-v] { display: none; }
.toast[data-v="mint"] [data-v="mint"], .toast[data-v="sky"] [data-v="sky"] { display: inline; }

/* entrance */
@keyframes rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
.hero-copy > *, .cards > .card { animation: rise 0.8s var(--ease) both; }
.hero-copy > :nth-child(2) { animation-delay: 0.06s; }
.hero-copy > :nth-child(3) { animation-delay: 0.12s; }
.hero-copy > :nth-child(4) { animation-delay: 0.18s; }
.cards > .card:nth-child(1) { animation-delay: 0.15s; }
.cards > .card:nth-child(2) { animation-delay: 0.27s; }
.cards > .card:nth-child(3) { animation-delay: 0.36s; }

/* ---------- manifesto ---------- */
.manifesto {
  position: relative; isolation: isolate; color: var(--band-ink); padding: 88px 0 96px;
  background: radial-gradient(90% 70% at 30% 20%, #1c1c20 0%, var(--band) 60%, #070708 100%);
}
.manifesto::after {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: var(--grain); opacity: 0.09; mix-blend-mode: screen;
}
.manifesto .kicker { color: #9a9aa3; display: flex; align-items: center; gap: 12px; }
.manifesto .mark { filter: invert(1); height: 20px; }
.manifesto ol { list-style: none; margin: 28px 0 0; padding: 0; counter-reset: none; }
.manifesto li {
  font-size: clamp(28px, 6vw, 60px); font-weight: 800; letter-spacing: -0.035em; line-height: 1.08;
  margin: 0 0 0.32em; text-wrap: balance; max-width: 19em;
  transition: color 0.6s var(--ease);
}
.manifesto li:last-child { margin: 0.9em 0 0; font-weight: 900; }
.js .manifesto li { color: var(--band-dim); }
.js .manifesto li.lit { color: var(--band-ink); }
@media (prefers-color-scheme: dark) {
  .manifesto { border-block: 1px solid var(--line); }
}
@media (min-width: 1000px) { .manifesto { padding: 128px 0 136px; } }

/* ---------- screenshots ---------- */
.section { padding: 88px 0; }
@media (min-width: 1000px) { .section { padding: 120px 0; } }
.phone {
  position: relative; border-radius: 42px; padding: 7px; background: var(--frame);
  box-shadow: 0 30px 60px -30px rgba(18, 19, 24, 0.45);
}
.phone img { border-radius: 35px; width: 100%; aspect-ratio: 600 / 1298; background: #000; }
@media (prefers-color-scheme: dark) { .phone { box-shadow: 0 0 0 1px var(--line); } }

.shots {
  list-style: none; margin: 44px calc(-1 * var(--gutter)) 0; padding: 4px var(--gutter) 24px;
  display: grid; grid-auto-flow: column; grid-auto-columns: min(74%, 300px); gap: 18px;
  overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding-inline: var(--gutter);
  scrollbar-width: none;
}
.shots::-webkit-scrollbar { display: none; }
.shots li { scroll-snap-align: start; }
.shots figure { margin: 0; }
.shots figcaption { margin-top: 22px; }
.shots .tag {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 12px; font-weight: 800; letter-spacing: 0.16em; color: var(--ink);
}
.shots .tag::before {
  content: ""; width: 10px; height: 10px; border-radius: 50%;
  background: linear-gradient(20deg, var(--c1), var(--c2));
}
.shots .t-keep { --c1: var(--mint); --c2: var(--mint2); }
.shots .t-quit { --c1: var(--ember); --c2: var(--ember2); }
.shots .t-share { --c1: var(--sky); --c2: var(--sky2); }
.shots p { margin: 12px 0 0; font-size: 17px; font-weight: 600; line-height: 1.4; color: var(--ink2); text-wrap: pretty; }
.shots p strong { color: var(--ink); font-weight: 800; }
@media (min-width: 900px) {
  .shots { grid-auto-flow: row; grid-template-columns: repeat(3, 1fr); gap: 40px; overflow: visible;
    margin-inline: 0; padding-inline: 0; }
  .shots li:nth-child(2) { margin-top: 56px; }
  .shots li:nth-child(3) { margin-top: 112px; }
}
@media (min-width: 1200px) { .shots { gap: 64px; padding-inline: 40px; } }

/* ---------- friends ---------- */
.friends { background: var(--surface); }
@media (prefers-color-scheme: dark) { .friends { border-block: 1px solid var(--line); } }
.friends .wrap { display: grid; gap: 56px; align-items: center; }
.friends .phone { width: min(78%, 320px); justify-self: center; }
@media (min-width: 1000px) {
  .friends .wrap { grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); gap: 80px; }
}
.feed { margin: 36px 0 0; padding: 0; list-style: none; display: grid; gap: 14px; max-width: 520px; }
.ev { border-radius: 22px; background: var(--bg); padding: 16px; }
.ev-head { display: flex; align-items: center; gap: 12px; }
.ev .badge {
  width: 44px; height: 44px; border-radius: 12px; flex: none; display: grid; place-items: center;
  color: #fff; font-family: var(--num); font-size: 24px; line-height: 1;
  background: linear-gradient(20deg, var(--ember), var(--ember2));
}
.ev .badge.av { border-radius: 50%; font-family: var(--font); font-weight: 900; font-size: 17px;
  background: transparent; color: var(--ink); box-shadow: inset 0 0 0 2px var(--ember); }
.ev .what { font-size: 16px; font-weight: 800; letter-spacing: -0.01em; line-height: 1.3; }
.ev .sub { font-size: 13px; font-weight: 600; color: var(--ink3); }
.ev .sub::before { content: ""; display: inline-block; width: 7px; height: 7px; border-radius: 50%;
  background: var(--ember); margin-right: 6px; vertical-align: 1px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.chip {
  appearance: none; cursor: pointer; border: 0;
  min-height: 40px; padding: 0 15px; border-radius: 12px;
  background: var(--surface); color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--line);
  font-size: 15px; font-weight: 700; letter-spacing: -0.01em;
  transition: background-color 0.2s, color 0.2s, transform 0.2s var(--ease), opacity 0.2s;
}
.chip:hover { box-shadow: inset 0 0 0 1.5px var(--raised); }
.chip:active { transform: scale(0.95); }
.chip[aria-pressed="true"] { background: var(--ink); color: var(--on-ink); box-shadow: none; }
.ev.sent .chip[aria-pressed="false"] { opacity: 0.45; }
.sent-note { min-height: 20px; margin: 10px 2px 0; font-size: 13px; font-weight: 700; color: var(--ink3); }
.sent-note .ok { display: inline-block; width: 16px; height: 16px; vertical-align: -3px; margin-right: 4px; color: var(--mint); }
.fine { margin: 22px 0 0; font-size: 14px; font-weight: 600; color: var(--ink3); }

/* ---------- early access ---------- */
.early { text-align: left; }
.early .panel {
  border-radius: 32px; padding: 40px 24px; background: var(--surface); box-shadow: var(--shadow);
  display: grid; gap: 28px; align-items: end;
}
@media (min-width: 900px) {
  .early .panel { padding: 64px; grid-template-columns: 1.2fr auto; }
  .early .cta-row { margin-top: 0; justify-content: flex-end; }
}
.early .mail { display: block; margin-top: 14px; font-size: 15px; font-weight: 600; color: var(--ink3); }
.early .mail a { color: var(--ink2); }

/* ---------- footer ---------- */
.foot { padding: 40px 0 56px; border-top: 1px solid var(--line); margin-top: 40px; }
.foot .wrap { display: grid; gap: 20px; }
.foot p { margin: 0; font-size: 14px; color: var(--ink3); }
.foot nav { display: flex; flex-wrap: wrap; gap: 6px 22px; }
.foot nav a { font-size: 14px; font-weight: 700; color: var(--ink2); text-decoration: none; padding: 6px 0; }
.foot nav a:hover { color: var(--ink); text-decoration: underline; }
@media (min-width: 768px) {
  .foot .wrap { grid-template-columns: auto 1fr auto; align-items: center; gap: 32px; }
}

/* ---------- document pages (privacy, terms) ---------- */
.doc { padding: 24px 0 40px; }
.doc article { max-width: 680px; }
.doc h1 { font-size: clamp(36px, 7vw, 56px); font-weight: 900; letter-spacing: -0.04em; line-height: 1.02; margin: 12px 0 10px; }
.doc .updated { color: var(--ink3); font-size: 15px; margin: 0 0 32px; }
.doc h2 { font-size: 22px; font-weight: 800; letter-spacing: -0.02em; margin: 40px 0 10px; }
.doc p, .doc li { color: var(--ink2); font-size: 17px; }
.doc li { margin: 6px 0; }
.doc strong { color: var(--ink); }
.doc a { color: var(--ink); font-weight: 600; }

/* ---------- link pages (join, u, 404) ---------- */
.linkpage { padding: 12px 0 40px; }
.linkpage .wrap { max-width: 640px; }
.ticket {
  --c1: var(--sky); --c2: var(--sky2);
  position: relative; isolation: isolate; overflow: hidden;
  border-radius: 28px; padding: 22px; min-height: 210px; color: rgba(255,255,255,.94);
  display: flex; flex-direction: column;
  background:
    radial-gradient(120% 90% at 100% 0%, rgba(255, 255, 255, 0.2), transparent 55%),
    linear-gradient(20deg, var(--c1), var(--c2));
  box-shadow: 0 22px 44px -26px var(--c1);
  animation: rise 0.7s var(--ease) both;
}
.ticket::after { content: ""; position: absolute; inset: 0; z-index: -1; background: var(--grain); mix-blend-mode: overlay; opacity: 0.42; }
[data-mode="u"] .ticket { --c1: var(--rose); --c2: var(--rose2); }
[data-mode="missing"] .ticket { --c1: var(--ember); --c2: var(--ember2); }
.ticket .big { margin-top: auto; font-size: clamp(40px, 11vw, 64px); font-weight: 900; letter-spacing: -0.03em; line-height: 1; word-break: break-all; }
.ticket .big.c-num { font-family: var(--num); font-weight: 400; font-size: clamp(96px, 26vw, 150px); letter-spacing: 0; }
.linkpage h1 { font-size: clamp(34px, 8vw, 52px); font-weight: 900; letter-spacing: -0.04em; line-height: 1.02; margin: 36px 0 12px; text-wrap: balance; }
.linkpage .lead { color: var(--ink2); font-size: 18px; margin: 0; }
.linkpage .btn { margin-top: 26px; }
.get { margin-top: 44px; padding-top: 28px; border-top: 1px solid var(--line); }
.get h2 { font-size: 20px; font-weight: 800; letter-spacing: -0.02em; margin: 0 0 8px; }
.get ol { margin: 14px 0 0; padding-left: 1.3em; color: var(--ink2); }
.get li { margin: 6px 0; }
.get a { color: var(--ink); font-weight: 700; }
html:not([data-mode]) [data-show],
[data-mode="join"] [data-show]:not([data-show~="join"]),
[data-mode="u"] [data-show]:not([data-show~="u"]),
[data-mode="missing"] [data-show]:not([data-show~="missing"]) { display: none; }
.ticket .code-label { margin-top: 4px; font-size: 13px; font-weight: 700; opacity: .85; }
.linkpage .tag { font-size: 11px; font-weight: 800; letter-spacing: 0.16em; opacity: .85; }

/* ---------- motion preferences ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
