@font-face { font-family: "JetBrains Mono"; src: url("/fonts/jbmono-regular.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "JetBrains Mono"; src: url("/fonts/jbmono-bold.woff2") format("woff2"); font-weight: 700; font-display: swap; }

:root {
  color-scheme: dark;
  --bg: #07090b;
  --panel: #0b0e11;
  --ink: #ebe4d1;
  --dim: #9c9682;
  --faint: #5f5c51;
  --rule: #24282c;
  --red: #ec3a43;
  --gold: #f0b23a;
  --teal: #55c4b3;
  --on-red: #0b0507;
  --dots: #14181c;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
}
html.light {
  color-scheme: light;
  --bg: #ece3cb;
  --panel: #e3d9be;
  --ink: #1d1a14;
  --dim: #5d5644;
  --faint: #91886f;
  --rule: #c8bc9b;
  --red: #b3141f;
  --gold: #855600;
  --teal: #0d6b60;
  --on-red: #fff6e6;
  --dots: #dccfb0;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 72px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 15px/1.65 var(--mono);
  font-variant-ligatures: none;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  /* A faint halftone, as the scenes are drawn. */
  background-image: radial-gradient(circle, var(--dots) 1px, transparent 1.4px);
  background-size: 16px 16px;
}
a { color: inherit; text-decoration-color: var(--faint); text-underline-offset: 3px; }
a:hover { text-decoration-color: currentColor; }
::selection { background: var(--ink); color: var(--bg); }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.wrap { width: min(1120px, 100% - 40px); margin-inline: auto; }
.grow { flex: 1; }
kbd { font: inherit; }

/* ---- the bar ---- */
.bar { position: sticky; top: 0; z-index: 10; background: color-mix(in srgb, var(--bg) 82%, transparent); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-bottom: 1px solid var(--rule); }
.bar-in { display: flex; align-items: center; gap: 28px; height: 56px; font-size: 13px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 700; letter-spacing: 0.01em; }
.brand svg { width: 22px; height: 22px; flex: none; }
.bar nav { display: flex; gap: 22px; }
.bar nav a { color: var(--dim); text-decoration: none; }
.bar nav a:hover, .bar nav a.here { color: var(--ink); }
.bar nav a.here::before { content: "▸ "; color: var(--red); }
.bar-end { margin-left: auto; display: flex; align-items: center; gap: 14px; }

.key { font: inherit; font-size: 12px; color: var(--dim); background: none; border: 0; padding: 4px 2px; cursor: pointer; display: inline-flex; align-items: center; gap: 8px; }
.key:hover { color: var(--ink); }
kbd { display: inline-block; min-width: 1.7em; padding: 0 5px; text-align: center; border: 1px solid var(--rule); border-bottom-width: 2px; color: var(--ink); font-size: 12px; line-height: 1.5; }

/* ---- buttons ---- */
.btn { display: inline-block; font: 700 14px/1 var(--mono); padding: 14px 20px; background: var(--red); color: var(--on-red); border: 1px solid var(--red); text-decoration: none; cursor: pointer; transition: background 0.12s, color 0.12s, border-color 0.12s; }
.btn::before { content: "▸ "; }
.btn:hover { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.btn.ghost { background: transparent; color: var(--ink); border-color: var(--faint); }
.btn.ghost:hover { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.btn.small { padding: 9px 13px; font-size: 12px; }
.btn.full { display: block; text-align: center; }
.btn.soon { color: var(--dim); border-style: dashed; cursor: default; }
.btn.soon::before { content: ""; }
.btn.soon:hover { background: transparent; color: var(--dim); border-color: var(--faint); }

/* ---- hero: always night, whatever the theme ---- */
.hero {
  --bg: #040508; --ink: #ebe4d1; --dim: #a9a492; --faint: #6a675c; --red: #ec3a43; --on-red: #0b0507; --rule: #24282c;
  position: relative; isolation: isolate; overflow: hidden;
  background: var(--bg); color: var(--ink);
  min-height: min(880px, calc(100svh - 57px));
  display: flex; align-items: flex-end;
}
#hero-art { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 30%; z-index: -2; }
.hero-fade { position: absolute; inset: 0; z-index: -1; background:
  linear-gradient(to bottom, transparent 45%, rgb(4 5 8 / 0.5) 78%, #040508 100%),
  linear-gradient(to right, rgb(4 5 8 / 0.5), rgb(4 5 8 / 0.15) 45%, transparent 70%); }
.hero-in { padding: 120px 0 72px; }
.kicker { margin: 0 0 22px; font-size: 13px; color: var(--ink); letter-spacing: 0.04em; text-shadow: 0 0 12px #03050c, 0 0 4px #03050c; }
.tag { text-shadow: none; display: inline-block; margin-right: 10px; padding: 1px 8px; background: var(--ink); color: var(--bg); font-weight: 700; }
.title { margin: 0 0 30px; max-width: 880px; }
.title svg { display: block; width: 100%; height: auto; overflow: visible; }
.title .ink { fill: var(--ink); }
.title .shade { fill: none; stroke: var(--ink); stroke-width: 1.1; opacity: 0.5; shape-rendering: geometricPrecision; }
.title .blood .ink { fill: var(--red); }
.title .blood .shade { stroke: var(--red); opacity: 0.75; }
.title .narrow { display: none; }
.lede { max-width: 62ch; margin: 0 0 30px; font-size: 17px; line-height: 1.6; color: var(--ink); text-wrap: pretty; text-shadow: 0 0 14px #040508, 0 0 5px #040508, 0 1px 2px #040508; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin: 0; }
.hero-note { position: absolute; right: 20px; bottom: 16px; margin: 0; font-size: 12px; color: var(--faint); display: flex; align-items: center; gap: 6px; }
.hero-note button { font: inherit; font-size: 16px; line-height: 1; color: var(--dim); background: none; border: 0; padding: 4px 8px; cursor: pointer; }
.hero-note button:hover { color: var(--ink); }
html.light .hero { border-bottom: 1px solid var(--rule); }

/* ---- sections ---- */
.block { padding: 112px 0 0; }
.prompt { margin: 0 0 14px; font-size: 13px; color: var(--dim); }
.prompt::before { content: "$ "; color: var(--red); font-weight: 700; }
h2 { margin: 0 0 14px; font-size: clamp(28px, 4.2vw, 44px); line-height: 1.12; letter-spacing: -0.02em; font-weight: 700; text-wrap: balance; }
.sub { max-width: 64ch; margin: 0 0 44px; color: var(--dim); font-size: 16px; text-wrap: pretty; }
.sub a, .aside a { color: var(--ink); }
.aside { margin: 18px 0 0; font-size: 13px; color: var(--dim); max-width: 78ch; }
code { font: inherit; color: var(--ink); }

.panel { position: relative; margin: 0; border: 1px solid var(--rule); background: var(--panel); }
.panel > .label { position: absolute; top: -0.8em; left: 14px; padding: 0 8px; background: var(--bg); color: var(--dim); font-size: 12px; line-height: 1.6; letter-spacing: 0.04em; }

/* ---- tiers ---- */
.tiers { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.tier { --hue: var(--ink); position: relative; display: flex; flex-direction: column; padding: 26px 22px 22px; border: 1px solid var(--rule); background: var(--panel); transition: border-color 0.12s; }
.tier.gold { --hue: var(--gold); }
.tier.red { --hue: var(--red); }
.tier.gold, .tier.red { border-color: color-mix(in srgb, var(--hue) 45%, var(--rule)); }
.tier:hover { border-color: var(--ink); }
.tier h3 { margin: 0; font-size: 13px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--hue); }
.tier h3 .n { color: var(--faint); margin-right: 6px; font-weight: 400; }
.price { margin: 18px 0 20px; font-size: 64px; font-weight: 700; line-height: 1; letter-spacing: -0.04em; }
.price sup { font-size: 24px; vertical-align: top; position: relative; top: 6px; margin-right: 3px; color: var(--dim); font-weight: 400; letter-spacing: 0; }
.gets { list-style: none; margin: 0 0 22px; padding: 18px 0 0; border-top: 1px dashed var(--rule); font-size: 13.5px; line-height: 1.5; flex: 1; }
.gets li { position: relative; padding: 4px 0 4px 20px; }
.gets li::before { content: "+"; position: absolute; left: 0; color: var(--teal); font-weight: 700; }
.gets li.new { color: var(--hue); font-weight: 700; }
.gets li.new::before { color: var(--hue); }
.gets li.no { color: var(--faint); }
.gets li.no::before { content: "·"; color: var(--faint); }
.stock { margin: 0 0 14px; font-size: 12px; color: var(--hue); display: flex; align-items: center; gap: 10px; min-height: 20px; }
.pips { display: inline-flex; gap: 3px; }
.pips b, .pips s { width: 9px; height: 9px; background: var(--hue); }
.pips s { background: none; outline: 1px solid var(--faint); outline-offset: -1px; }

/* ---- designs ---- */
.designs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.designs .panel { background: #000; display: flex; flex-direction: column; }
.designs canvas { display: block; width: calc(100% - 44px); height: auto; margin: auto 22px; padding: 26px 0 18px; box-sizing: content-box; }
.designs figcaption { margin-top: auto; padding: 14px 18px 16px; border-top: 1px solid var(--rule); background: var(--panel); font-size: 13px; display: flex; flex-direction: column; gap: 2px; }
.designs figcaption b { font-size: 14px; }
.designs figcaption span { color: var(--dim); }

/* ---- the picker ---- */
.picker { display: grid; grid-template-columns: 250px 1fr; grid-template-rows: 1fr auto; }
.list { grid-row: 1; height: 0; min-height: 100%; overflow-y: auto; padding: 16px 0 12px; border-right: 1px solid var(--rule); font-size: 13px; scrollbar-width: thin; scrollbar-color: var(--rule) transparent; outline-offset: -2px; }
.list h4 { margin: 14px 0 4px; padding: 0 18px; font-size: 11px; font-weight: 400; letter-spacing: 0.12em; text-transform: uppercase; color: var(--faint); }
.list h4:first-child { margin-top: 0; }
.list div { padding: 2px 18px 2px 32px; cursor: pointer; color: var(--dim); white-space: nowrap; position: relative; }
.list div:hover { color: var(--ink); }
.list div[aria-selected="true"] { background: var(--ink); color: var(--bg); font-weight: 700; }
.list div[aria-selected="true"]::before { content: "▸"; position: absolute; left: 16px; }
.stage { min-width: 0; display: flex; flex-direction: column; background: #000; }
.screen { aspect-ratio: 16 / 9.4; padding: 14px; cursor: pointer; overflow: hidden; }
.screen { min-height: 0; }
.screen canvas { width: 100%; height: 100%; object-fit: contain; min-height: 0; min-width: 0; }
.about { margin: 0; padding: 12px 18px; border-top: 1px solid var(--rule); background: var(--panel); font-size: 13px; display: flex; gap: 14px; align-items: baseline; }
.about b { white-space: nowrap; }
.about span { color: var(--dim); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.keys { grid-column: 1 / -1; margin: 0; padding: 9px 18px; border-top: 1px solid var(--rule); display: flex; gap: 22px; font-size: 12px; color: var(--dim); align-items: center; }
.keys kbd { margin-right: 4px; }
.keys #p-cmd { color: var(--ink); }
.keys #p-cmd::before { content: "$ "; color: var(--red); font-weight: 700; }

.install { margin-top: 34px; }
.term { display: flex; align-items: center; gap: 12px; padding: 20px 16px 18px 20px; }
.term pre { margin: 0; flex: 1; overflow-x: auto; font: inherit; font-size: 14px; scrollbar-width: none; }
.term pre::before { content: "$ "; color: var(--red); font-weight: 700; }
.term .key { border: 1px solid var(--rule); padding: 5px 12px; color: var(--ink); }
.term .key:hover { background: var(--ink); color: var(--bg); border-color: var(--ink); }

/* ---- the dogs ---- */
.dogs { display: grid; grid-template-columns: 1fr 340px; gap: 56px; align-items: center; }
.dogs .sub { margin-bottom: 30px; }
.articles { margin: 0; padding: 0; list-style: none; counter-reset: art; font-size: 14px; border-top: 1px dashed var(--rule); }
.articles li { counter-increment: art; display: flex; gap: 16px; padding: 10px 0; border-bottom: 1px dashed var(--rule); }
.articles li::before { content: counter(art, upper-roman) "."; flex: none; width: 3.2ch; color: var(--red); font-weight: 700; }
.dog { background: #000; display: grid; place-items: center; aspect-ratio: 1; }
.dog canvas { width: 88%; height: auto; }

/* ---- the sea, and the status line ---- */
.sea { margin: 128px 0 0; overflow: hidden; white-space: nowrap; color: var(--faint); font-size: 13px; line-height: 1.5; user-select: none; }
.sea span { display: inline-block; animation: drift 60s linear infinite; }
.sea span + span { animation-duration: 90s; color: var(--rule); }
@keyframes drift { to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) { .sea span { animation: none; } }

/* ---- the status line ---- */
.status { border-top: 1px solid var(--rule); font-size: 12px; color: var(--dim); padding-bottom: 28px; }
.status-in { display: flex; flex-wrap: wrap; gap: 6px 22px; align-items: center; padding: 14px 0; }
.status .mode { background: var(--red); color: var(--on-red); font-weight: 700; padding: 1px 9px; }
.small-print { margin: 0 auto; color: var(--faint); font-size: 11.5px; }

@media (max-width: 980px) {
  .tiers { grid-template-columns: repeat(2, 1fr); }
  .dogs { grid-template-columns: 1fr; gap: 40px; }
  .dog { max-width: 340px; }
  .bar nav { display: none; }
}
@media (max-width: 720px) {
  body { font-size: 14px; }
  .block { padding-top: 84px; }
  .designs { grid-template-columns: 1fr; gap: 26px; }
  .picker { grid-template-columns: 1fr; grid-template-rows: auto auto auto; }
  .list { grid-row: auto; height: 190px; min-height: 0; border-right: 0; border-bottom: 1px solid var(--rule); }
  .title .wide { display: none; }
  .title .narrow { display: block; }
  .hero-in { padding: 96px 0 64px; }
  #hero-art { object-position: 30% 20%; }
  .lede { font-size: 15.5px; }
  .about { flex-direction: column; gap: 2px; }
  .about span { white-space: normal; }
  .keys span:not(#p-cmd) { display: none; }
  .brand span { display: none; }
  #theme span { display: none; }
  .sea { margin-top: 96px; }
}
@media (max-width: 520px) {
  .tiers { grid-template-columns: 1fr; }
  .price { font-size: 56px; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
