/* Dumb Ways to Ship — a white, editorial take on the Linear / Raycast / Vercel playbook:
   hairline borders, soft layered shadows, one lime highlighter accent, a single dark focal point. */
:root {
  color-scheme: light;
  --bg: #ffffff;
  --bg-2: #fafafa;
  --surface: #ffffff;
  --surface-2: #f5f5f4;
  --inset: #fafafa;
  --line: rgba(0,0,0,.08);
  --line-2: rgba(0,0,0,.14);
  --text: #0a0a0a;
  --text-2: #2b2b2b;
  --muted: #6b6b6b;
  --faint: #a3a3a3;
  --accent: #c6f432;
  --accent-2: #84cc16;
  --accent-ink: #3f6212;
  --accent-soft: rgba(198,244,50,.28);
  --on-accent: #0a0a0a;
  --ok: #15803d;
  --err: #dc2626;
  --warn: #b45309;
  --btn-bg: #0a0a0a;
  --btn-text: #ffffff;
  --glow: rgba(163,230,53,.45);
  --shadow-sm: 0 1px 2px rgba(0,0,0,.05);
  --shadow-card: 0 1px 2px rgba(0,0,0,.04), 0 6px 20px -10px rgba(0,0,0,.10);
  --shadow-hover: 0 2px 4px rgba(0,0,0,.04), 0 18px 40px -16px rgba(0,0,0,.18);
  --shadow-lg: 0 0 0 1px rgba(0,0,0,.08), 0 50px 100px -40px rgba(0,0,0,.45), 0 16px 32px -16px rgba(0,0,0,.2);
  --ease: cubic-bezier(.16,1,.3,1);
  --sans: "Geist", "Inter", system-ui, sans-serif;
  --mono: "Geist Mono", ui-monospace, monospace;
  --r: 16px;

  --c-auth: #6366f1;
  --c-secrets: #d97706;
  --c-payments: #16a34a;
  --c-access: #0284c7;
  --c-injection: #e11d48;
  --c-business-logic: #c026d3;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 96px; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font: 15px/1.6 var(--sans); letter-spacing: -.005em;
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
::selection { background: var(--accent); color: var(--on-accent); }
a { color: inherit; }

.wrap { max-width: 1200px; margin: 0 auto; padding: 0 16px; }
.hidden { display: none !important; }
.dim { color: var(--muted); }
.mono, code, pre, textarea, .urlbar { font-family: var(--mono); }
code { font-size: .85em; background: var(--surface-2); border: 1px solid var(--line); padding: .05em .35em; border-radius: 5px; }
.dot { display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--ok); }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 8px; height: 44px; padding: 0 20px;
  border-radius: 99px; font: 500 15px var(--sans); text-decoration: none; white-space: nowrap;
  transition: transform .3s var(--ease), box-shadow .3s var(--ease), background .2s, border-color .2s;
}
.btn-sm { height: 34px; padding: 0 14px; font-size: 13px; }
.btn-primary { background: var(--btn-bg); color: var(--btn-text); box-shadow: 0 0 0 1px var(--line-2), 0 8px 24px -8px rgba(0,0,0,.5); }
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 0 0 1px var(--line-2), 0 12px 30px -8px var(--glow); }
.btn-glow {
  color: var(--text); border: 1px solid color-mix(in srgb, var(--accent) 45%, var(--line));
  background: radial-gradient(120% 140% at 50% 120%, var(--accent-soft), transparent 70%);
  box-shadow: 0 0 24px -8px var(--glow);
}
.btn-glow:hover { border-color: var(--accent); }

/* ---------- floating nav (Raycast) ---------- */
.nav-wrap { position: sticky; top: 12px; z-index: 40; padding: 0 16px; }
.nav {
  max-width: 1200px; margin: 0 auto; height: 60px; padding: 0 12px 0 20px;
  display: flex; align-items: center; gap: 24px;
  border: 1px solid var(--line); border-radius: 16px;
  background: color-mix(in srgb, var(--bg) 72%, transparent);
  backdrop-filter: blur(16px) saturate(1.5); -webkit-backdrop-filter: blur(16px) saturate(1.5);
}
.logo { display: inline-flex; align-items: center; gap: 10px; font-weight: 600; text-decoration: none; letter-spacing: -.02em; font-size: 16px; }
.logo-mark {
  width: 22px; height: 22px; border-radius: 6px; position: relative;
  background: conic-gradient(from 200deg, var(--accent), var(--accent-2), var(--accent));
}
.logo-mark::after { content: ""; position: absolute; inset: 5px; border-radius: 50%; background: var(--bg); clip-path: inset(0 0 50% 0); }
.nav-links { display: flex; gap: 22px; margin-left: 12px; }
.nav-links a { text-decoration: none; color: var(--muted); font-size: 14px; transition: color .2s; }
.nav-links a:hover { color: var(--text); }
.nav-right { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.nav-progress {
  display: inline-flex; align-items: center; gap: 7px; font: 12px var(--mono); color: var(--muted);
  padding: 6px 10px; border-radius: 99px; border: 1px solid var(--line); background: var(--surface);
}
.nav-progress b { color: var(--text); font-weight: 500; }

/* ---------- hero ---------- */
.hero { position: relative; margin-top: -72px; padding-top: 72px; overflow: hidden; }
.hero::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(900px 500px at 50% -10%, var(--accent-soft), transparent 70%),
    linear-gradient(var(--line) 1px, transparent 1px) 0 0 / 64px 64px,
    linear-gradient(90deg, var(--line) 1px, transparent 1px) 0 0 / 64px 64px;
  mask-image: radial-gradient(ellipse 70% 55% at 50% 30%, #000 30%, transparent 75%);
  opacity: .9;
}
.hero-inner { position: relative; text-align: center; padding-top: 120px; padding-bottom: 64px; display: flex; flex-direction: column; align-items: center; }
.announce {
  display: inline-flex; align-items: center; gap: 10px; text-decoration: none;
  font-size: 13px; color: var(--text-2); padding: 4px 14px 4px 4px; border-radius: 99px;
  border: 1px solid var(--line); background: color-mix(in srgb, var(--surface) 70%, transparent);
  margin-bottom: 32px; transition: border-color .2s;
}
.announce:hover { border-color: var(--line-2); }
.announce-tag { background: var(--accent); color: var(--on-accent); font-weight: 600; font-size: 11px; padding: 3px 9px; border-radius: 99px; letter-spacing: .02em; }
h1 {
  margin: 0 0 24px; font-weight: 600; font-size: clamp(44px, 8.4vw, 96px); line-height: 1;
  letter-spacing: -.045em; max-width: 14ch; text-wrap: balance;
}
h1 .dim {
  background: linear-gradient(180deg, var(--muted), color-mix(in srgb, var(--muted) 45%, transparent));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.lede { max-width: 580px; font-size: clamp(16px, 1.8vw, 19px); color: var(--muted); margin: 0 0 36px; text-wrap: pretty; }
.hero-ctas { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; }
.hero-note { margin: 20px 0 0; font: 12px var(--mono); color: var(--faint); }

/* the stage: a big app window like Linear's hero screenshot */
.stage { position: relative; padding-bottom: 32px; }
.stage::before {
  content: ""; position: absolute; left: 10%; right: 10%; top: 30%; bottom: 0; z-index: 0;
  background: radial-gradient(closest-side, var(--glow), transparent); filter: blur(40px); opacity: .7;
}
.term {
  position: relative; z-index: 1; max-width: 920px; margin: 0 auto; border-radius: 16px; overflow: hidden;
  background: var(--surface); box-shadow: var(--shadow-lg);
  animation: rise 1s .15s both var(--ease);
}
.term-bar { display: flex; align-items: center; gap: 12px; padding: 12px 16px; border-bottom: 1px solid var(--line); background: var(--bg-2); }
.term-title { font: 12px var(--mono); color: var(--muted); flex: 1; text-align: center; }
.term-status { display: inline-flex; align-items: center; gap: 6px; font: 11px var(--mono); color: var(--muted); margin-left: auto; }
.term-status .dot { animation: blink 1.4s infinite; }
.term-body {
  margin: 0; padding: 22px 24px; min-height: 340px; font: 13px/1.75 var(--mono); color: var(--text-2);
  white-space: pre-wrap; word-break: break-word; text-align: left;
}
.term-body .p { color: var(--accent); }
.term-body .ai { color: var(--text); }
.term-body .ok { color: var(--ok); }
.term-body .warn { color: var(--warn); }
.term-body .c { color: var(--faint); }
.term-body .cursor { display: inline-block; width: 8px; height: 1.1em; vertical-align: -2px; background: var(--text); animation: blink 1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }
@keyframes rise { from { opacity: 0; transform: translateY(24px); } }

.lights { display: inline-flex; gap: 6px; }
.lights i { width: 10px; height: 10px; border-radius: 50%; background: var(--line-2); }

/* ---------- stats strip (Vercel grid cells) ---------- */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); border: 1px solid var(--line); border-radius: var(--r); margin-top: 48px; overflow: hidden; padding: 0; }
.stats > div { padding: 28px 24px; display: flex; flex-direction: column; gap: 4px; border-left: 1px solid var(--line); }
.stats > div:first-child { border-left: 0; }
.stats b { font-size: 40px; font-weight: 600; letter-spacing: -.04em; line-height: 1; }
.stats span { font: 12px var(--mono); color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }

/* ---------- section heads ---------- */
.section-head { padding-top: 120px; padding-bottom: 32px; }
.eyebrow { font: 12px var(--mono); text-transform: uppercase; letter-spacing: .12em; color: var(--accent); margin: 0 0 16px; }
.display { margin: 0; font-weight: 600; font-size: clamp(30px, 4.4vw, 52px); line-height: 1.08; letter-spacing: -.035em; max-width: 22ch; text-wrap: balance; }

/* ---------- toolbar + segmented filter ---------- */
.toolbar { position: sticky; top: 84px; z-index: 30; margin-bottom: 8px; pointer-events: none; }
.toolbar-inner { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.filters, .progress { pointer-events: auto; }
.filters {
  position: relative; display: flex; gap: 2px; padding: 4px; border-radius: 99px; overflow-x: auto; scrollbar-width: none; max-width: 100%;
  border: 1px solid var(--line); background: color-mix(in srgb, var(--surface) 80%, transparent);
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
}
.filters::-webkit-scrollbar { display: none; }
.chip {
  position: relative; z-index: 1; display: inline-flex; align-items: center; gap: 7px; white-space: nowrap;
  font: 500 13px var(--sans); color: var(--muted); background: transparent; border: 0; border-radius: 99px;
  padding: 7px 14px; cursor: pointer; transition: color .2s, background .2s;
}
.chip i { width: 6px; height: 6px; border-radius: 50%; background: var(--cat, var(--muted)); }
.chip:hover { color: var(--text); }
.chip[aria-pressed="true"] { color: var(--text); background: var(--surface-2); box-shadow: 0 0 0 1px var(--line-2); }
.progress {
  display: flex; align-items: center; gap: 12px; font: 12px var(--mono); color: var(--muted);
  padding: 8px 14px; border-radius: 99px; border: 1px solid var(--line);
  background: color-mix(in srgb, var(--surface) 80%, transparent); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
}
.progress b { color: var(--text); font-weight: 500; }
.bar { width: 120px; height: 4px; background: var(--line); border-radius: 99px; overflow: hidden; }
.bar i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--accent-2), var(--accent)); transition: width .8s var(--ease); }
button.link { background: none; border: 0; color: var(--muted); padding: 0; font: 12px var(--mono); cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
button.link:hover { color: var(--text); }

.victory {
  margin-top: 16px; padding: 18px 22px; border-radius: var(--r); display: flex; gap: 14px; align-items: center;
  border: 1px solid color-mix(in srgb, var(--ok) 40%, var(--line));
  background: radial-gradient(120% 200% at 0% 0%, color-mix(in srgb, var(--ok) 14%, transparent), transparent 60%), var(--surface);
}
.trophy { font-size: 28px; }

/* ---------- cards ---------- */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 360px), 1fr)); gap: 16px; padding-top: 16px; padding-bottom: 40px; }
.card {
  --cat: var(--accent);
  position: relative; isolation: isolate; min-width: 0;
  display: flex; flex-direction: column; gap: 12px; padding: 24px;
  border-radius: 16px; background: var(--surface); border: 1px solid var(--line);
  transition: border-color .3s;
  animation: rise .7s both var(--ease);
}
/* cursor spotlight (Linear/Vercel) */
.card::before {
  content: ""; position: absolute; inset: 0; border-radius: inherit; z-index: -1; pointer-events: none;
  background: radial-gradient(420px circle at var(--mx, 50%) var(--my, -20%), color-mix(in srgb, var(--cat) 9%, transparent), transparent 45%);
  opacity: 0; transition: opacity .4s;
}
.card:hover { border-color: var(--line-2); }
.card:hover::before { opacity: 1; }
.card[data-cat="auth"] { --cat: var(--c-auth); }
.card[data-cat="secrets"] { --cat: var(--c-secrets); }
.card[data-cat="payments"] { --cat: var(--c-payments); }
.card[data-cat="access"] { --cat: var(--c-access); }
.card[data-cat="injection"] { --cat: var(--c-injection); }
.card[data-cat="business-logic"] { --cat: var(--c-business-logic); }

.card-head { display: flex; align-items: center; gap: 10px; font: 12px var(--mono); color: var(--muted); min-height: 22px; }
.num { color: var(--faint); }
.tag { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); }
.tag::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--cat); box-shadow: 0 0 8px var(--cat); }
.badge {
  margin-left: auto; display: none; align-items: center; gap: 6px; font: 500 11px var(--mono); text-transform: uppercase; letter-spacing: .06em;
  color: var(--ok); padding: 3px 9px; border-radius: 99px; border: 1px solid color-mix(in srgb, var(--ok) 35%, transparent);
  background: color-mix(in srgb, var(--ok) 10%, transparent);
}
.badge::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 6px var(--ok); }
.card.found { border-color: color-mix(in srgb, var(--ok) 35%, var(--line)); }
.card.found .badge { display: inline-flex; animation: pop .5s var(--ease); }
@keyframes pop { from { transform: scale(.6); opacity: 0; } }

.card h2 { margin: 2px 0 0; font-size: 20px; font-weight: 600; letter-spacing: -.025em; line-height: 1.25; }
.blurb { margin: 0; color: var(--muted); font-size: 14.5px; }

/* demo window */
.window { flex: 1; display: flex; flex-direction: column; margin-top: 4px; border-radius: 12px; overflow: hidden; border: 1px solid var(--line); background: var(--inset); }
.window-bar { display: flex; align-items: center; gap: 10px; padding: 8px 12px; border-bottom: 1px solid var(--line); }
.window-bar .lights i { width: 8px; height: 8px; transition: background .3s; }
.card:hover .lights i:nth-child(1) { background: #ff5f57; }
.card:hover .lights i:nth-child(2) { background: #febc2e; }
.card:hover .lights i:nth-child(3) { background: #28c840; }
.host { flex: 1; min-width: 0; font: 11px var(--mono); color: var(--faint); text-align: center; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; padding-right: 44px; }

.demo { display: flex; flex-direction: column; gap: 10px; padding: 16px; flex: 1; min-width: 0; }
.demo p { margin: 0; }
label { display: flex; flex-direction: column; gap: 6px; font-size: 12.5px; color: var(--muted); font-weight: 500; }
input, textarea {
  font: inherit; font-size: 14px; color: var(--text); background: var(--surface);
  border: 1px solid var(--line); border-radius: 9px; padding: 9px 12px; width: 100%; min-width: 0;
  transition: border-color .2s, box-shadow .2s;
}
input::placeholder, textarea::placeholder { color: var(--faint); }
textarea { font-family: var(--mono); font-size: 12.5px; resize: vertical; line-height: 1.5; }
input:focus, textarea:focus { outline: none; border-color: color-mix(in srgb, var(--cat, var(--accent)) 60%, transparent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--cat, var(--accent)) 16%, transparent); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
input:focus-visible, textarea:focus-visible { outline: none; }
input[readonly] { color: var(--muted); }

.demo button {
  align-self: flex-start; height: 36px; padding: 0 16px; border-radius: 99px; cursor: pointer;
  font: 500 13.5px var(--sans); color: var(--btn-text); background: var(--btn-bg); border: 0;
  transition: transform .2s var(--ease), opacity .2s;
}
.demo button:hover { opacity: .88; }
.demo button:active { transform: scale(.97); }
.demo button.ghost { color: var(--text); background: transparent; border: 1px solid var(--line-2); }
.demo button.ghost:hover { background: var(--surface-2); opacity: 1; }
.row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.row input { flex: 1 1 140px; }
.row button { flex-shrink: 0; }

.urlbar {
  flex-direction: row; align-items: center; flex-wrap: wrap; gap: 0; font-size: 12px; color: var(--faint); font-weight: 400;
  background: var(--surface); border: 1px solid var(--line); border-radius: 9px; padding: 7px 10px; word-break: break-all;
}
.urlbar:focus-within { border-color: color-mix(in srgb, var(--cat) 60%, transparent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--cat) 16%, transparent); }
.urlbar input { width: auto; flex: 1 1 80px; border: 0; padding: 2px 4px; font: 13px var(--mono); color: var(--cat); background: transparent; box-shadow: none !important; }

pre.code { margin: 0; padding: 12px 14px; border-radius: 9px; background: var(--surface); border: 1px solid var(--line); font-size: 12px; line-height: 1.65; white-space: pre-wrap; word-break: break-word; overflow-x: auto; color: var(--text-2); }
pre.err { color: var(--err); border-color: color-mix(in srgb, var(--err) 30%, var(--line)); }
.debug { font: 12px var(--mono); color: var(--warn); padding: 8px 10px; border-radius: 8px; background: color-mix(in srgb, var(--warn) 8%, transparent); border: 1px dashed color-mix(in srgb, var(--warn) 35%, transparent); }
.muted { color: var(--muted); }
.ok { color: var(--ok); }
.result:empty { display: none; }
.result { font-size: 13.5px; padding: 9px 12px; border-radius: 9px; background: var(--surface); border: 1px solid var(--line); color: var(--text-2); }
.result.good { color: var(--ok); border-color: color-mix(in srgb, var(--ok) 30%, var(--line)); background: color-mix(in srgb, var(--ok) 7%, var(--surface)); }
.result.bad { color: var(--err); border-color: color-mix(in srgb, var(--err) 30%, var(--line)); background: color-mix(in srgb, var(--err) 7%, var(--surface)); }
.good { color: var(--ok); }
.bad { color: var(--err); }
.product { font-size: 14px; display: flex; justify-content: space-between; gap: 8px; padding: 9px 12px; border-radius: 9px; background: var(--surface); border: 1px solid var(--line); }
.product b { font-weight: 600; }

.chat { display: flex; flex-direction: column; gap: 6px; max-height: 170px; overflow-y: auto; font-size: 13.5px; }
.chat p { padding: 7px 12px; border-radius: 14px; max-width: 85%; }
.chat .bot { background: var(--surface-2); border: 1px solid var(--line); align-self: flex-start; border-bottom-left-radius: 4px; }
.chat .me { background: var(--accent); color: var(--on-accent); align-self: flex-end; border-bottom-right-radius: 4px; }

.receipt, .panel, .table, .comments { font-size: 13.5px; }
.receipt:empty, .panel:empty, .table:empty { display: none; }
.receipt, .panel { padding: 12px 14px; border-radius: 9px; background: var(--surface); border: 1px dashed var(--line-2); display: flex; flex-direction: column; gap: 2px; }
.panel.locked { color: var(--muted); }
.table { display: grid; gap: 3px; font: 12px var(--mono); }
.table div { display: grid; grid-template-columns: 1fr 1.6fr 1fr; gap: 8px; padding: 6px 10px; background: var(--surface); border: 1px solid var(--line); border-radius: 7px; overflow-wrap: anywhere; }
.comments { display: flex; flex-direction: column; gap: 6px; }
.comments p { padding: 8px 12px; background: var(--surface); border: 1px solid var(--line); border-radius: 9px; overflow-wrap: anywhere; }

details { font-size: 14px; color: var(--muted); padding-top: 4px; }
summary { cursor: pointer; font-weight: 500; font-size: 13.5px; color: var(--text-2); list-style: none; display: inline-flex; align-items: center; gap: 8px; transition: color .2s; }
summary:hover { color: var(--text); }
summary::-webkit-details-marker { display: none; }
summary::after { content: "↓"; font: 12px var(--mono); color: var(--faint); transition: transform .3s var(--ease); }
details[open] summary::after { transform: rotate(180deg); }
details p { margin: 10px 0 0; line-height: 1.65; padding-left: 12px; border-left: 2px solid var(--cat); }

/* ---------- how it works ---------- */
.how { padding-top: 120px; padding-bottom: 40px; }
.how-grid { display: grid; grid-template-columns: repeat(3, 1fr); margin-top: 48px; border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; }
.how-grid > div { padding: 32px 28px; border-left: 1px solid var(--line); background: var(--surface); }
.how-grid > div:first-child { border-left: 0; }
.step { font: 12px var(--mono); color: var(--accent); }
.how h3 { margin: 16px 0 8px; font-size: 22px; font-weight: 600; letter-spacing: -.025em; }
.how p { margin: 0; color: var(--muted); }

/* ---------- toast ---------- */
.toast {
  position: fixed; left: 50%; bottom: 24px; z-index: 60; transform: translate(-50%, 20px) scale(.96);
  display: flex; align-items: center; gap: 8px; max-width: calc(100% - 32px);
  padding: 10px 16px; border-radius: 99px; font-size: 14px;
  background: var(--surface-2); color: var(--text); box-shadow: 0 0 0 1px var(--line-2), 0 20px 50px -10px rgba(0,0,0,.6);
  opacity: 0; visibility: hidden; pointer-events: none;
  transition: transform .5s var(--ease), opacity .3s, visibility .5s;
}
.toast.show { transform: translate(-50%, 0) scale(1); opacity: 1; visibility: visible; }
.toast b { color: var(--ok); font-weight: 500; }

/* ---------- footer ---------- */
.foot { margin-top: 80px; border-top: 1px solid var(--line); overflow: hidden; }
.foot-inner { display: flex; justify-content: space-between; gap: 24px; flex-wrap: wrap; padding-top: 32px; padding-bottom: 16px; color: var(--muted); font-size: 14px; }
.foot-inner p { margin: 0; max-width: 560px; }
.foot-inner .mono { font-size: 12px; color: var(--faint); }
.wordmark {
  font-weight: 700; letter-spacing: -.06em; line-height: .8; text-align: center; white-space: nowrap;
  font-size: clamp(64px, 19vw, 260px); margin-bottom: -.12em; user-select: none;
  background: linear-gradient(180deg, var(--line-2), transparent 85%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}

/* ---------- responsive ---------- */
@media (max-width: 760px) {
  .nav-links { display: none; }
  .nav { padding: 0 8px 0 14px; gap: 12px; height: 54px; }
  .hero-inner { padding-top: 72px; padding-bottom: 40px; }
  .term-body { min-height: 300px; padding: 16px; font-size: 12px; }
  .term-title { display: none; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .stats > div:nth-child(3) { border-left: 0; }
  .stats > div:nth-child(n+3) { border-top: 1px solid var(--line); }
  .stats b { font-size: 32px; }
  .section-head, .how { padding-top: 80px; }
  .toolbar { top: 74px; }
  .toolbar-inner { flex-direction: column; align-items: stretch; }
  .progress { justify-content: space-between; }
  .bar { flex: 1; width: auto; }
  .how-grid { grid-template-columns: 1fr; }
  .how-grid > div { border-left: 0; border-top: 1px solid var(--line); }
  .how-grid > div:first-child { border-top: 0; }
  .card { padding: 18px; }
}
@media (max-width: 420px) {
  .nav-progress { display: none; }
}

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

/* ================= white theme polish ================= */
mark {
  color: inherit; padding: 0 .1em; margin: 0 -.02em; border-radius: .12em;
  background: linear-gradient(104deg, transparent .9%, var(--accent) 2.4%, #d9ff5c 50%, var(--accent) 94%, transparent 97%);
  box-decoration-break: clone; -webkit-box-decoration-break: clone;
}
:focus-visible { outline-color: var(--accent-ink); }
.eyebrow, .step { color: var(--accent-ink); }
.eyebrow { display: inline-flex; align-items: center; gap: 8px; }
.eyebrow::before { content: ""; width: 8px; height: 8px; border-radius: 2px; background: var(--accent); box-shadow: 0 0 0 1px rgba(63,98,18,.25); }

/* nav */
.nav { background: rgba(255,255,255,.78); box-shadow: var(--shadow-card); }
.nav-progress { background: var(--bg-2); }

/* hero: dot grid + lime haze */
.hero::before {
  background:
    radial-gradient(700px 360px at 50% 0%, var(--accent-soft), transparent 70%),
    radial-gradient(rgba(0,0,0,.13) 1px, transparent 1.2px) 0 0 / 22px 22px;
  mask-image: radial-gradient(ellipse 75% 60% at 50% 25%, #000 25%, transparent 75%);
  opacity: 1;
}
.announce { background: #fff; box-shadow: var(--shadow-sm); }
h1 .dim { background: linear-gradient(180deg, #8a8a8a, #c4c4c4); -webkit-background-clip: text; background-clip: text; }
.btn-primary { box-shadow: 0 1px 0 rgba(255,255,255,.15) inset, 0 8px 20px -8px rgba(0,0,0,.45); }
.btn-primary:hover { box-shadow: 0 1px 0 rgba(255,255,255,.15) inset, 0 14px 28px -10px rgba(0,0,0,.5); }
.btn-glow { background: #fff; border: 1px solid var(--line-2); box-shadow: var(--shadow-sm); }
.btn-glow:hover { border-color: var(--text); transform: translateY(-1px); }

/* the terminal stays dark: the page's one high-contrast focal point */
.term {
  --surface: #0c0d0c; --bg-2: #111311; --line: rgba(255,255,255,.08); --line-2: rgba(255,255,255,.16);
  --text: #f5f5f5; --text-2: #d4d4d4; --muted: #8a8a8a; --faint: #5c5c5c;
  --ok: #4ade80; --warn: #facc15; --accent: #c6f432;
  color: var(--text-2);
}
.stage::before { top: 40%; opacity: .9; }

/* stats + how: bordered white cells with a soft lift */
.stats, .how-grid { box-shadow: var(--shadow-card); background: #fff; }
.stats b { letter-spacing: -.05em; }

/* toolbar */
.filters, .progress { background: rgba(255,255,255,.85); box-shadow: var(--shadow-card); }
.chip[aria-pressed="true"] { background: var(--text); color: #fff; box-shadow: none; }
.chip[aria-pressed="true"] i { box-shadow: 0 0 0 2px rgba(255,255,255,.25); }
.bar { background: var(--surface-2); }
.bar i { background: linear-gradient(90deg, var(--accent-2), var(--accent)); }

/* cards: white, layered shadow, lift on hover */
.card { box-shadow: var(--shadow-card); transition: border-color .3s, box-shadow .4s var(--ease), transform .4s var(--ease); }
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow-hover); border-color: var(--line-2); }
.card::before { background: radial-gradient(380px circle at var(--mx, 50%) var(--my, -20%), color-mix(in srgb, var(--cat) 7%, transparent), transparent 50%); }
.card.found { border-color: rgba(21,128,61,.35); box-shadow: 0 0 0 3px rgba(21,128,61,.08), var(--shadow-card); }
.tag::before { box-shadow: 0 0 0 3px color-mix(in srgb, var(--cat) 18%, transparent); }
.badge { background: #ecfccb; border-color: #bef264; color: var(--accent-ink); }
.badge::before { background: var(--accent-2); box-shadow: none; }

.window { background: var(--bg-2); }
.window-bar { background: #fff; }
input, textarea, .urlbar, .product, .result, pre.code, .receipt, .panel, .comments p, .table div { background: #fff; }
input, textarea, .urlbar { box-shadow: var(--shadow-sm); }
input:focus, textarea:focus, .urlbar:focus-within { border-color: var(--text); box-shadow: 0 0 0 3px var(--accent-soft); }
.urlbar input { color: var(--cat); font-weight: 500; }
.demo button { box-shadow: 0 1px 2px rgba(0,0,0,.15), 0 4px 10px -4px rgba(0,0,0,.3); }
.demo button.ghost { background: #fff; box-shadow: var(--shadow-sm); }
.result.good { background: #f0fdf4; }
.result.bad { background: #fef2f2; }
.chat .bot { background: #fff; }
.debug { background: #fffbeb; }
details p { border-left-color: var(--accent); }

/* toast: dark pill on a white page */
.toast { background: #0a0a0a; color: #fff; box-shadow: 0 20px 50px -12px rgba(0,0,0,.45); }
.toast b { color: var(--accent); }

.victory { background: linear-gradient(110deg, #f7fee7, #fff 60%); border-color: #bef264; box-shadow: var(--shadow-card); }

.foot { background: var(--bg-2); }
.wordmark { background: linear-gradient(180deg, rgba(0,0,0,.09), transparent 85%); -webkit-background-clip: text; background-clip: text; }

/* layout fixes */
.stats { width: calc(100% - 32px); max-width: 1168px; margin: 8px auto 0; }
.stage { padding-bottom: 96px; }

/* ================= motion & visual features ================= */

/* scroll progress line */
.scroll-progress {
  position: fixed; inset: 0 0 auto 0; height: 2px; z-index: 100; pointer-events: none;
  background: linear-gradient(90deg, var(--accent-2), var(--accent));
  transform-origin: 0 50%; transform: scaleX(var(--p, 0));
  box-shadow: 0 0 10px var(--glow);
}

/* confetti canvas */
.confetti { position: fixed; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 90; }

/* hero entrance: staggered blur-in */
@keyframes blurIn { from { opacity: 0; filter: blur(10px); transform: translateY(12px); } }
.hero-inner > * { animation: blurIn .9s both var(--ease); }
.hero-inner > :nth-child(1) { animation-delay: .05s; }
.hero-inner > :nth-child(2) { animation-delay: .15s; }
.hero-inner > :nth-child(3) { animation-delay: .3s; }
.hero-inner > :nth-child(4) { animation-delay: .42s; }
.hero-inner > :nth-child(5) { animation-delay: .54s; }
.term { animation: rise 1.1s .6s both var(--ease); }

/* highlighter draws across like a marker */
mark { background-size: 0% 100%; background-repeat: no-repeat; animation: draw .8s .75s var(--ease) forwards; }
@keyframes draw { to { background-size: 100% 100%; } }
.reveal:not(.in) mark { animation-play-state: paused; }
.section-head mark, .how mark { animation-delay: .35s; }

/* scroll reveal */
.reveal { opacity: 0; transform: translateY(18px); filter: blur(6px); transition: opacity .8s var(--ease), transform .8s var(--ease), filter .8s var(--ease); transition-delay: var(--d, 0s); }
.reveal.in { opacity: 1; transform: none; filter: none; }
.card { animation: none; }
.card.reveal.in { transition: opacity .8s var(--ease) var(--d, 0s), transform .4s var(--ease), filter .8s var(--ease) var(--d, 0s), box-shadow .4s var(--ease), border-color .3s; }
.card.reveal.in:hover { transform: translateY(-3px); }
.card.pop { animation: popIn .5s var(--ease) both; }
@keyframes popIn { from { opacity: 0; transform: scale(.97) translateY(8px); } }

/* commit marquee with faded edges */
.marquee {
  margin: 56px 0 0; padding: 4px 0; overflow: hidden;
  mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
}
.marquee-track { display: flex; gap: 12px; width: max-content; animation: marquee 45s linear infinite; }
.marquee:hover .marquee-track { animation-play-state: paused; }
.marquee span {
  font: 13px var(--mono); color: var(--muted); white-space: nowrap;
  padding: 8px 14px; border-radius: 99px; border: 1px solid var(--line); background: #fff; box-shadow: var(--shadow-sm);
}
.marquee span::before { content: "✕"; color: var(--err); margin-right: 8px; font-size: 11px; }
@keyframes marquee { to { transform: translateX(calc(-50% - 6px)); } }

/* sliding pill behind the active filter */
.chip-indicator {
  position: absolute; top: 4px; bottom: 4px; left: 0; width: 0; z-index: 0; border-radius: 99px;
  background: var(--text); box-shadow: 0 4px 12px -4px rgba(0,0,0,.4);
  transition: transform .45s var(--ease), width .45s var(--ease);
}
.filters.has-indicator .chip[aria-pressed="true"] { background: transparent; color: #fff; }

/* sheen sweep on primary buttons */
.btn-primary { position: relative; overflow: hidden; isolation: isolate; }
.btn-primary::after {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: linear-gradient(110deg, transparent 30%, rgba(255,255,255,.28) 50%, transparent 70%);
  transform: translateX(-120%); transition: transform .8s var(--ease);
}
.btn-primary:hover::after { transform: translateX(120%); }

/* nav arrow nudge */
.btn-glow span, .announce span { display: inline-block; transition: transform .3s var(--ease); }
.btn-glow:hover span, .announce:hover span { transform: translateX(3px); }

/* stats: numbers tick, subtle hover */
.stats > div { transition: background .3s; }
.stats > div:hover { background: var(--bg-2); }
.stats b { font-variant-numeric: tabular-nums; }

/* how-it-works cells */
.how-grid > div { position: relative; transition: background .3s; }
.how-grid > div:hover { background: var(--bg-2); }
.how-grid > div::after {
  content: ""; position: absolute; left: 28px; right: 28px; top: 0; height: 2px; border-radius: 2px;
  background: linear-gradient(90deg, var(--accent-2), var(--accent)); transform: scaleX(0); transform-origin: 0;
  transition: transform .6s var(--ease);
}
.how-grid > div:hover::after { transform: scaleX(1); }

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; filter: none; }
  mark { background-size: 100% 100%; }
  .marquee-track { animation: none; }
}

/* ================= bounty game ================= */
:root { --sev-low: #64748b; --sev-medium: #ca8a04; --sev-high: #ea580c; --sev-critical: #dc2626; }

/* severity pill in each card head */
.sev {
  font: 500 11px var(--mono); padding: 2px 8px; border-radius: 99px; white-space: nowrap;
  color: var(--s); background: color-mix(in srgb, var(--s) 9%, #fff); border: 1px solid color-mix(in srgb, var(--s) 25%, transparent);
}
.sev-low { --s: var(--sev-low); }
.sev-medium { --s: var(--sev-medium); }
.sev-high { --s: var(--sev-high); }
.sev-critical { --s: var(--sev-critical); }
.card-head { flex-wrap: wrap; row-gap: 6px; }

/* hints */
.hintbar { display: flex; flex-direction: column; gap: 8px; }
.hint-btn {
  align-self: flex-start; display: inline-flex; align-items: center; gap: 6px; cursor: pointer;
  font: 500 12.5px var(--sans); color: var(--muted); background: transparent;
  border: 1px dashed var(--line-2); border-radius: 99px; padding: 5px 12px; transition: color .2s, border-color .2s, background .2s;
}
.hint-btn:hover:not(:disabled) { color: var(--text); border-color: var(--text); background: #fefce8; }
.hint-btn:disabled { cursor: default; opacity: .6; }
.hint-list { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 6px; counter-reset: h; }
.hint-list:empty { display: none; }
.hint-list li {
  counter-increment: h; position: relative; font-size: 13.5px; color: var(--text-2);
  padding: 9px 12px 9px 36px; border-radius: 10px; background: #fefce8; border: 1px solid #fde68a;
  animation: popIn .4s var(--ease) both; white-space: pre-wrap;
}
.hint-list li::before {
  content: counter(h); position: absolute; left: 10px; top: 9px; width: 18px; height: 18px; border-radius: 50%;
  display: grid; place-items: center; font: 600 11px var(--mono); background: #fde68a; color: #713f12;
}
.hint-list li.spoiler { background: #fff7ed; border-color: #fdba74; font-family: var(--mono); font-size: 12.5px; }
.hint-list li.spoiler::before { content: "!"; background: #fdba74; color: #7c2d12; }

/* nav bounty button */
.nav-progress { cursor: pointer; font-family: var(--mono); transition: border-color .2s, box-shadow .2s, transform .2s var(--ease); }
.nav-progress:hover { border-color: var(--line-2); box-shadow: var(--shadow-card); transform: translateY(-1px); }
.nav-bounty { color: var(--text); font-weight: 600; }
.nav-progress .sep { width: 1px; height: 12px; background: var(--line-2); }
@media (max-width: 420px) { .nav-progress { display: inline-flex; } .nav-progress .sep, .nav-progress .dot, .nav-progress b, #navTotal { display: none; } }

/* drawer */
.scrim { position: fixed; inset: 0; z-index: 70; background: rgba(10,10,10,.25); backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px); animation: fadeIn .3s both; }
@keyframes fadeIn { from { opacity: 0; } }
.board {
  position: fixed; z-index: 80; top: 12px; right: 12px; bottom: 12px; width: min(420px, calc(100% - 24px));
  display: flex; flex-direction: column; gap: 16px; padding: 22px;
  background: #fff; border: 1px solid var(--line); border-radius: 20px;
  box-shadow: 0 40px 80px -20px rgba(0,0,0,.35), 0 0 0 1px rgba(0,0,0,.02);
  transform: translateX(calc(100% + 24px)); transition: transform .55s var(--ease); visibility: hidden;
}
.board.open { transform: none; visibility: visible; }
.board:not(.open) { transition: transform .45s var(--ease), visibility 0s .45s; }
.board-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.board-head .eyebrow { margin-bottom: 8px; }
.board-total { margin: 0; font-size: 44px; font-weight: 600; letter-spacing: -.05em; line-height: 1; font-variant-numeric: tabular-nums; }
.board-sub { margin: 8px 0 0; font: 13px var(--mono); color: var(--muted); }
#boardRank { color: var(--text); background: var(--accent); padding: 1px 6px; border-radius: 4px; }
.board-close { width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--line); background: #fff; cursor: pointer; font-size: 13px; color: var(--muted); transition: background .2s, color .2s; }
.board-close:hover { background: var(--surface-2); color: var(--text); }
.board-meter { height: 6px; border-radius: 99px; background: var(--surface-2); overflow: hidden; }
.board-meter i { display: block; height: 100%; width: 0; border-radius: inherit; background: linear-gradient(90deg, var(--accent-2), var(--accent)); transition: width .8s var(--ease); }
.board-stats { display: grid; grid-template-columns: repeat(3, 1fr); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.board-stats > div { padding: 12px; display: flex; flex-direction: column; gap: 2px; border-left: 1px solid var(--line); }
.board-stats > div:first-child { border-left: 0; }
.board-stats b { font-size: 18px; font-weight: 600; letter-spacing: -.02em; }
.board-stats span { font: 11px var(--mono); color: var(--muted); text-transform: uppercase; letter-spacing: .05em; }
.board-list { list-style: none; margin: 0 -8px; padding: 0; overflow-y: auto; flex: 1; display: flex; flex-direction: column; gap: 2px; }
.board-item {
  width: 100%; display: grid; grid-template-columns: 34px 1fr 10px 64px; align-items: center; gap: 10px;
  padding: 9px 8px; border: 0; border-radius: 10px; background: transparent; cursor: pointer; text-align: left;
  font: 13.5px var(--sans); color: var(--text-2); transition: background .2s;
}
.board-item:hover { background: var(--surface-2); }
.bi-num { font: 11px var(--mono); color: var(--faint); }
.bi-name { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bi-sev { width: 8px; height: 8px; border-radius: 50%; }
.sev-dot-low { background: var(--sev-low); } .sev-dot-medium { background: var(--sev-medium); }
.sev-dot-high { background: var(--sev-high); } .sev-dot-critical { background: var(--sev-critical); }
.bi-pay { font: 12px var(--mono); color: var(--faint); text-align: right; }
.board-list li.done .bi-name { color: var(--text); }
.board-list li.done .bi-pay { color: var(--ok); font-weight: 500; }
.board-list li.done .bi-num::before { content: "✓ "; color: var(--ok); }
.board-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-top: 4px; border-top: 1px solid var(--line); padding-top: 16px; }

/* card flash when jumped to from the board */
.card.flash { animation: flash 1.4s var(--ease); }
@keyframes flash { 0%, 40% { box-shadow: 0 0 0 4px var(--accent), var(--shadow-hover); } }

/* ================= X / follow ================= */
.x-btn {
  display: inline-flex; align-items: center; gap: 7px; height: 34px; padding: 0 12px; border-radius: 99px;
  font: 500 13px var(--sans); text-decoration: none; color: var(--text);
  border: 1px solid var(--line); background: #fff; transition: border-color .2s, box-shadow .2s, transform .2s var(--ease);
}
.x-btn svg { width: 13px; height: 13px; }
.x-btn:hover { border-color: var(--text); box-shadow: var(--shadow-card); transform: translateY(-1px); }
.foot-right { display: flex; flex-direction: column; align-items: flex-end; gap: 10px; }
.x-follow {
  display: inline-flex; align-items: center; gap: 10px; padding: 10px 16px; border-radius: 99px; text-decoration: none;
  background: var(--text); color: #fff; font-size: 14px; box-shadow: 0 8px 20px -8px rgba(0,0,0,.45);
  transition: transform .3s var(--ease), box-shadow .3s var(--ease);
}
.x-follow svg { width: 15px; height: 15px; }
.x-follow b { color: var(--accent); font-weight: 600; }
.x-follow .arrow { transition: transform .3s var(--ease); }
.x-follow:hover { transform: translateY(-2px); box-shadow: 0 14px 28px -10px rgba(0,0,0,.5); }
.x-follow:hover .arrow { transform: translateX(3px); }
@media (max-width: 760px) {
  .x-btn span { display: none; }
  .x-btn { width: 34px; padding: 0; justify-content: center; }
  .foot-right { align-items: flex-start; }
}
