/* Deck's site is one terminal window: a title bar with tabs, a sidebar,
   panes of output, and a status line. Monospace throughout, dark only,
   with Deck's orange as the prompt and the cursor. */

@font-face { font-family: "Geist Mono"; src: url("/fonts/geist-mono.woff2") format("woff2"); font-weight: 400 600; font-display: swap; }

:root {
  --bg: #0d0e10;
  --bg-2: #121316;
  --pane: #15161a;
  --pane-2: #1b1c21;
  --line: #24262c;
  --line-2: #30333a;
  --text: #dfe1e6;
  --text-2: #a9adb5;
  --dim: #767b85;
  --faint: #4b4f58;
  --orange: #ff6a1f;
  --orange-2: #ff8a4c;
  --green: #86d696;
  --blue: #7fb0ff;
  --yellow: #e8c27a;
  --red: #f38b84;
  --violet: #c4a3f2;
  --mono: "Geist Mono", ui-monospace, "SF Mono", "JetBrains Mono", Menlo, Consolas, monospace;
  --box: "SF Mono", Menlo, Consolas, "DejaVu Sans Mono", monospace;
  --app: -apple-system, BlinkMacSystemFont, "SF Pro Text", sans-serif;
  --plane: min(1440px, 100%);
  --content: min(980px, 100% - 64px);
  color-scheme: dark;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }

html { background: #08090a; scroll-behavior: smooth; scroll-padding-top: 72px; }

body {
  margin: 0;
  color: var(--text-2);
  font: 400 15px/1.75 var(--mono);
  -webkit-font-smoothing: antialiased;
  font-variant-ligatures: none;
}

a { color: var(--blue); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }
code { font-family: var(--mono); color: var(--text); background: var(--pane-2); padding: 1px 6px; border-radius: 4px; font-size: 0.92em; }
kbd { font-family: var(--mono); font-size: 0.88em; color: var(--text); padding: 0 6px; border: 1px solid var(--line-2); border-radius: 4px; background: var(--pane); white-space: nowrap; }
strong, b { color: var(--text); font-weight: 600; }
::selection { background: var(--orange); color: #111; }
:focus-visible { outline: 1px solid var(--orange); outline-offset: 2px; }
img { display: block; }

.skip { position: absolute; left: -9999px; }
.skip:focus { left: 12px; top: 10px; z-index: 100; padding: 6px 10px; background: var(--orange); color: #111; }

/* -- the window ------------------------------------------------------------------- */

.plane { width: var(--plane); margin: 0 auto; min-height: 100vh; background: var(--bg); border-left: 1px solid var(--line); border-right: 1px solid var(--line); padding-bottom: 30px; }

.titlebar { position: sticky; top: 0; z-index: 40; display: flex; align-items: center; gap: 22px; height: 48px; padding: 0 18px; background: rgba(13, 14, 16, 0.92); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.lights { display: flex; gap: 7px; }
.lights i { width: 11px; height: 11px; border-radius: 50%; background: #ff5f57; }
.lights i:nth-child(2) { background: #febc2e; } .lights i:nth-child(3) { background: #28c840; }
.brand { display: flex; align-items: center; gap: 8px; color: var(--text); font-weight: 600; }
.brand img { border-radius: 4px; }
.brand:hover { text-decoration: none; }
.tabs { display: flex; height: 100%; margin-left: 6px; }
.tabs a { display: flex; align-items: center; padding: 0 16px; color: var(--dim); border-left: 1px solid transparent; border-right: 1px solid transparent; font-size: 14px; }
.tabs a:hover { color: var(--text); text-decoration: none; background: var(--bg-2); }
.tabs a[aria-current] { color: var(--text); background: var(--bg-2); border-color: var(--line); box-shadow: inset 0 2px 0 var(--orange); }
.title-actions { margin-left: auto; display: flex; align-items: center; gap: 16px; font-size: 14px; }
.title-actions > a:not(.tbtn) { color: var(--dim); }
.title-actions > a:not(.tbtn):hover, .title-actions > a[aria-current] { color: var(--text); text-decoration: none; }
.kbd-btn { font: 500 12.5px var(--mono); color: var(--dim); background: var(--pane); border: 1px solid var(--line-2); border-radius: 5px; padding: 2px 8px; cursor: pointer; }
.kbd-btn:hover { color: var(--text); border-color: var(--dim); }
.menu-btn { display: none; }

.statusbar { position: fixed; left: 50%; bottom: 0; transform: translateX(-50%); width: var(--plane); z-index: 40; display: flex; align-items: center; height: 28px; background: #101114; border-top: 1px solid var(--line); font-size: 12.5px; color: var(--text-2); }
.statusbar .mode { height: 100%; display: flex; align-items: center; padding: 0 12px; background: var(--orange); color: #111; font-weight: 600; letter-spacing: 0.04em; }
.statusbar .seg { padding: 0 14px; border-right: 1px solid var(--line); }
.statusbar .dim { color: var(--dim); }
.statusbar .grow { flex: 1; }
.statusbar .seg:last-child { border-right: 0; border-left: 1px solid var(--line); }

/* -- terminal parts ---------------------------------------------------------------- */

.cmd { color: var(--text); font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ps1 { color: var(--blue); }
.prompt { color: var(--orange); }
.caret { display: inline-block; width: 9px; height: 18px; margin-left: 2px; background: var(--orange); vertical-align: -3px; animation: blink 1.1s steps(1) infinite; }
.out { margin-top: 18px; }
.comment { color: var(--dim); }
.ok { color: var(--green); } .warn { color: var(--yellow); } .err { color: var(--red); } .info { color: var(--blue); } .hot { color: var(--orange); } .vio { color: var(--violet); }

/* A pane: a box with its name set into the top border. */
.box { position: relative; border: 1px solid var(--line-2); border-radius: 6px; background: var(--pane); padding: 22px 22px 20px; }
.box > .box-label { position: absolute; top: -10px; left: 14px; padding: 0 8px; background: var(--bg); color: var(--text-2); font-size: 13px; line-height: 18px; }
.box > .box-label b { color: var(--orange); font-weight: 500; }
.box > .box-tag { position: absolute; top: -10px; right: 14px; padding: 0 8px; background: var(--bg); color: var(--dim); font-size: 12.5px; line-height: 18px; }

/* Buttons are bracketed, and invert when you point at them. */
.tbtn { display: inline-flex; align-items: center; gap: 2px; padding: 9px 16px; border: 1px solid var(--line-2); border-radius: 4px; background: var(--pane); color: var(--text); font: 500 14.5px var(--mono); cursor: pointer; transition: background 100ms, color 100ms, border-color 100ms; }
.tbtn::before { content: "["; color: var(--dim); margin-right: 6px; }
.tbtn::after { content: "]"; color: var(--dim); margin-left: 6px; }
.tbtn:hover { background: var(--text); color: #111; border-color: var(--text); text-decoration: none; }
.tbtn:hover::before, .tbtn:hover::after { color: #111; }
.tbtn.primary { background: var(--orange); border-color: var(--orange); color: #111; }
.tbtn.primary::before, .tbtn.primary::after { color: rgba(17, 17, 17, 0.55); }
.tbtn.primary:hover { background: var(--orange-2); border-color: var(--orange-2); }
.tbtn-small { padding: 3px 10px; font-size: 13px; }
.tbtn-small::before, .tbtn-small::after { margin: 0 4px; }
.tbtn[aria-disabled="true"] { opacity: 0.5; pointer-events: none; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; }

/* -- the home page: a session, then commands and their output ------------------------- */

.home-grid { display: grid; grid-template-columns: 220px minmax(0, 1fr); }
.side { position: sticky; top: 48px; align-self: start; height: calc(100vh - 48px - 28px); overflow: auto; padding: 28px 0 28px 18px; border-right: 1px solid var(--line); font-size: 13.5px; }
.side h2 { margin: 0 0 8px; font-size: 12.5px; font-weight: 500; color: var(--faint); }
.side a { display: flex; gap: 8px; padding: 3px 10px 3px 0; color: var(--dim); }
.side a::before { content: "▸"; color: var(--faint); }
.side a:hover, .side a.on { color: var(--text); text-decoration: none; }
.side a.on::before { content: "▸"; color: var(--orange); }
.side .group + .group { margin-top: 26px; }
.side .live { display: flex; align-items: center; gap: 8px; padding: 3px 0; color: var(--dim); }

.stream { padding: 56px 0 40px; }
.block { width: var(--content); margin: 0 auto; padding: 0 0 96px; }
.block > h2 { margin: 18px 0 0; color: var(--text); font: 600 clamp(22px, 2.3vw, 28px)/1.3 var(--mono); letter-spacing: -0.02em; }
.block > p, .block .para { max-width: 74ch; margin: 14px 0 0; }

.ascii { margin: 28px 0 0; font: 400 clamp(8px, 1.7vw, 21px)/1 var(--box); color: var(--orange); white-space: pre; overflow: hidden; text-shadow: 0 0 22px rgba(255, 106, 31, 0.35); }
.tagline { margin: 26px 0 0; color: var(--text); font: 600 clamp(26px, 3.4vw, 42px)/1.15 var(--mono); letter-spacing: -0.035em; max-width: 24ch; }
.lead { margin: 18px 0 0; max-width: 70ch; font-size: 16px; color: var(--text-2); }
.hero .actions { margin-top: 28px; }
.kv { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 4px 28px; margin: 30px 0 0; font-size: 14px; }
.kv dt { color: var(--dim); }
.kv dd { margin: 0; color: var(--text); }

/* the session: three panes of Deck at work */
.session { margin-top: 56px; display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); grid-template-rows: auto auto; gap: 18px 16px; font-size: 13px; line-height: 1.7; }
.session .box { padding: 22px 18px 16px; min-height: 0; }
.session .chat { grid-row: span 2; }
.you { color: var(--text); }
.you::before { content: "you  "; color: var(--blue); }
.steps-log { list-style: none; margin: 12px 0 0; padding: 0; }
.steps-log li { display: flex; gap: 10px; color: var(--text-2); }
.steps-log li::before { content: "·"; width: 12px; flex: none; color: var(--faint); }
.steps-log li.shown::before { content: "✓"; color: var(--green); }
.steps-log li.now::before { content: "◐"; color: var(--orange); animation: spin-glyph 0.9s steps(4) infinite; }
.steps-log code { background: none; padding: 0; }
.steps-log em { font-style: normal; color: var(--dim); }
.steps-log em.plus { color: var(--green); }
.worked { margin-top: 12px; color: var(--dim); }
.worked .hot { animation: pulse 1.6s ease-in-out infinite; }
.done-working .worked .hot { animation: none; color: var(--dim); }
.reply { margin-top: 12px; color: var(--text); }
.reply::before { content: "claude  "; color: var(--orange); }
.term-out { margin: 0; font: 13px/1.7 var(--mono); color: var(--text-2); white-space: pre; overflow: hidden; }
.pass { background: var(--green); color: #0b120c; padding: 0 4px; }
.page { border-radius: 4px; padding: 14px 16px; background: #f2f3f5; color: #1a1b1e; font: 13px/1.5 var(--app); transition: background 500ms ease, color 500ms ease; }
.page b { color: inherit; font-size: 15px; }
.page-row { display: flex; justify-content: space-between; align-items: center; padding: 8px 0; border-bottom: 1px solid rgba(0, 0, 0, 0.08); transition: border-color 500ms ease; }
.switch { width: 34px; height: 20px; border-radius: 99px; background: #c9ccd1; position: relative; transition: background 350ms ease; }
.switch::after { content: ""; position: absolute; top: 3px; left: 3px; width: 14px; height: 14px; border-radius: 50%; background: #fff; transition: transform 350ms cubic-bezier(0.3, 0.9, 0.3, 1.2); }
.is-dark .page { background: #1a1b1f; color: #e7e8eb; }
.is-dark .page-row { border-color: rgba(255, 255, 255, 0.08); }
.is-dark .switch.dm { background: var(--orange); }
.is-dark .switch.dm::after { transform: translateX(14px); }

.js [data-step] { opacity: 0.25; }
.js [data-step].shown, .js [data-step].now { opacity: 1; }
.js [data-answer], .js [data-term] { opacity: 0; transition: opacity 400ms ease; }
.js [data-answer].shown, .js [data-term].shown { opacity: 1; }

/* what: the parts of the window */
.parts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px 18px; margin-top: 30px; }
.parts .box h3 { margin: 0; color: var(--text); font: 600 15px var(--mono); }
.parts .box p { margin: 8px 0 0; font-size: 14.5px; }

/* who, when: lists in the shape of output */
.list { list-style: none; margin: 26px 0 0; padding: 0; }
.list > li { display: grid; grid-template-columns: 24px minmax(0, 1fr); padding: 14px 0; border-bottom: 1px dashed var(--line-2); }
.list > li::before { content: "▸"; color: var(--orange); }
.list > li:first-child { border-top: 1px dashed var(--line-2); }
.list b { display: block; }
.list p { margin: 4px 0 0; }

.table { width: 100%; margin-top: 26px; border-collapse: collapse; font-size: 14.5px; }
.table th { text-align: left; color: var(--dim); font-weight: 500; padding: 8px 18px 8px 0; border-bottom: 1px solid var(--line-2); }
.table td { padding: 12px 18px 12px 0; border-bottom: 1px dashed var(--line); vertical-align: top; }
.table td:first-child { color: var(--text); white-space: nowrap; }
.table .them { color: var(--dim); }
.table .them::before { content: "✗ "; color: var(--red); }
.table .us { color: var(--text); }
.table .us::before { content: "✓ "; color: var(--green); }
.table td.you-did::before { content: "you   "; color: var(--blue); }
.table td.deck-did::before { content: "deck  "; color: var(--orange); }

.how { counter-reset: n; list-style: none; margin: 26px 0 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px 16px; }
.how li { counter-increment: n; }
.how .box { height: 100%; }
.how .box-label::before { content: "0" counter(n) " "; color: var(--orange); }
.how p { margin: 0; font-size: 14px; }

.agents { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0 18px; margin-top: 22px; }
.agents span { display: flex; align-items: center; gap: 10px; padding: 9px 0; border-bottom: 1px dashed var(--line); color: var(--text); }
.agents .mark { width: 15px; height: 15px; color: var(--text-2); }
.agents small { margin-left: auto; color: var(--dim); font-size: 12.5px; }
.mark { display: inline-block; flex: none; background: currentColor; -webkit-mask: var(--m) center / contain no-repeat; mask: var(--m) center / contain no-repeat; }

.feat-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 32px; margin-top: 22px; }
.feat-grid div { padding: 14px 0; border-bottom: 1px dashed var(--line); }
.feat-grid b { display: block; }
.feat-grid span { font-size: 14px; }

/* -- inner pages: manual pages ---------------------------------------------------------- */

.manhead { display: flex; justify-content: space-between; width: var(--content); margin: 0 auto; padding: 28px 0 0; color: var(--dim); font-size: 13px; }
.page-head, .hero:not(.block), .section, .section-narrow { width: var(--content); margin: 0 auto; padding: 48px 0 0; }
.page-head h1, .hero:not(.block) h1, .section-head h1, .prose h1, .title { margin: 0; color: var(--text); font: 600 clamp(26px, 3vw, 36px)/1.2 var(--mono); letter-spacing: -0.03em; }
.title::before, .prose h1::before { content: "❯ "; color: var(--orange); }
.section-head { margin-bottom: 40px; }
.section-head .lead, .hero:not(.block) .lead { margin-top: 14px; }
.hero-note, .muted, .small { color: var(--dim); font-size: 14px; }
.subtitle { margin: 40px 0 0; color: var(--text); font: 600 18px var(--mono); }

.with-toc { width: var(--content); margin: 0 auto; padding-top: 36px; display: grid; grid-template-columns: 196px minmax(0, 1fr); gap: 48px; }
.toc { position: sticky; top: 80px; align-self: start; font-size: 13.5px; }
.toc h2 { margin: 0 0 8px; font-size: 12.5px; font-weight: 500; color: var(--faint); }
.toc a { display: flex; gap: 8px; padding: 3px 0; color: var(--dim); }
.toc a::before { content: "▸"; color: var(--faint); }
.toc a:hover { color: var(--text); text-decoration: none; }

/* features: NAME / DESCRIPTION, options as man pages print them */
.feature-group { padding: 8px 0 44px; }
.feature-group + .feature-group { border-top: 1px dashed var(--line-2); padding-top: 40px; }
.feature-group > h2 { margin: 0; color: var(--orange); font: 600 16px var(--mono); letter-spacing: 0.06em; text-transform: uppercase; }
.feature-group > p { margin: 10px 0 0; max-width: 74ch; }
.feature { padding: 18px 0 0 28px; max-width: 80ch; }
.feature h3 { margin: 0 0 0 -28px; color: var(--text); font: 600 15px var(--mono); }
.feature p { margin: 6px 0 0; }
.feature .how { margin-top: 8px; display: block; font-size: 14px; color: var(--dim); }
.feature .how b { color: var(--yellow); font-weight: 500; }

.prose { max-width: 80ch; }
.prose .meta { margin: 8px 0 0; color: var(--dim); font-size: 14px; }
.prose h2 { margin: 44px 0 0; color: var(--orange); font: 600 16px var(--mono); letter-spacing: 0.06em; text-transform: uppercase; }
.prose h3 { margin: 26px 0 0; color: var(--text); font: 600 15px var(--mono); }
.prose p, .prose ul, .prose ol { margin: 12px 0 0; }
.prose ul, .prose ol { padding-left: 24px; }
.prose li { margin: 5px 0; }
.prose li::marker { color: var(--orange); }
.prose pre { margin: 16px 0 0; padding: 16px 18px; border: 1px solid var(--line-2); border-radius: 6px; background: var(--pane); overflow-x: auto; font: 13.5px/1.75 var(--mono); color: var(--text); }
.prose pre .c { color: var(--dim); }
.prose table { width: 100%; margin: 16px 0 0; border-collapse: collapse; font-size: 14.5px; }
.prose th, .prose td { text-align: left; padding: 9px 16px 9px 0; border-bottom: 1px dashed var(--line); vertical-align: top; }
.prose th { color: var(--dim); font-weight: 500; }
.callout { margin: 20px 0 0; padding: 14px 18px; border: 1px solid var(--line-2); border-left: 3px solid var(--orange); border-radius: 4px; background: var(--pane); font-size: 14.5px; }

/* changelog: the version lines read like git log */
.log .version { margin-top: 36px; color: var(--yellow); }

/* pricing */
.plan-wrap { display: grid; grid-template-columns: minmax(0, 440px) minmax(0, 1fr); gap: 48px; align-items: start; }
.plan { position: relative; border: 1px solid var(--orange); border-radius: 6px; background: var(--pane); padding: 28px 26px 24px; }
.plan::before { content: "deck pro"; position: absolute; top: -10px; left: 14px; padding: 0 8px; background: var(--bg); color: var(--orange); font-size: 13px; line-height: 18px; }
.plan h2 { margin: 0; color: var(--text); font: 600 16px var(--mono); }
.plan-price { margin: 14px 0 0; display: flex; align-items: baseline; gap: 10px; min-height: 44px; }
.plan-price strong { color: var(--text); font: 600 40px var(--mono); letter-spacing: -0.04em; }
.plan-price span { color: var(--dim); }
.plan-note { margin: 4px 0 0; min-height: 22px; font-size: 14px; }
.plan ul { list-style: none; margin: 20px 0 0; padding: 0; }
.plan li { padding: 6px 0; border-bottom: 1px dashed var(--line); font-size: 14.5px; }
.plan li::before { content: "✓ "; color: var(--green); }
.plan .buttons { display: flex; margin-top: 24px; }
.plan .btn { flex: 1; }
.plan-fine { margin: 14px 0 0; color: var(--dim); font-size: 13px; }

/* the shared .btn names from the old site, drawn as terminal buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 9px 16px; border: 1px solid var(--line-2); border-radius: 4px; background: var(--pane); color: var(--text); font: 500 14.5px var(--mono); cursor: pointer; }
.btn:hover { background: var(--text); color: #111; text-decoration: none; }
.btn svg { width: 14px; height: 14px; fill: currentColor; }
.btn-light, .btn-solid { background: var(--orange); border-color: var(--orange); color: #111; }
.btn-light:hover, .btn-solid:hover { background: var(--orange-2); border-color: var(--orange-2); }
.btn[aria-disabled="true"] { opacity: 0.5; pointer-events: none; }
.buttons { display: flex; flex-wrap: wrap; gap: 12px; }

.faq details { border-bottom: 1px dashed var(--line-2); }
.faq details:first-child { border-top: 1px dashed var(--line-2); }
.faq summary { cursor: pointer; list-style: none; padding: 13px 0; color: var(--text); }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::before { content: "? "; color: var(--orange); }
.faq details[open] summary::before { content: "› "; }
.faq details p { margin: 0 0 16px 18px; max-width: 72ch; }

.steps { counter-reset: s; list-style: none; margin: 32px 0 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px 16px; }
.steps li { counter-increment: s; position: relative; border: 1px solid var(--line-2); border-radius: 6px; background: var(--pane); padding: 22px 18px 18px; font-size: 14px; }
.steps li::before { content: "0" counter(s); position: absolute; top: -10px; left: 14px; padding: 0 8px; background: var(--bg); color: var(--orange); font-size: 13px; line-height: 18px; }
.steps b { display: block; margin-bottom: 6px; }

/* account */
.account { min-height: 300px; }
.account-card { position: relative; max-width: 620px; border: 1px solid var(--line-2); border-radius: 6px; background: var(--pane); padding: 28px 24px 22px; }
.account-card::before { content: "deck account"; position: absolute; top: -10px; left: 14px; padding: 0 8px; background: var(--bg); color: var(--text-2); font-size: 13px; line-height: 18px; }
.account-card .subtitle { margin: 0; }
.who { display: flex; align-items: center; gap: 14px; }
.avatar { width: 44px; height: 44px; border-radius: 6px; background: var(--orange); color: #111; display: grid; place-items: center; font-weight: 600; font-size: 18px; overflow: hidden; }
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.account-rows { margin: 20px 0 0; }
.account-rows div { display: flex; justify-content: space-between; gap: 16px; padding: 8px 0; border-bottom: 1px dashed var(--line); font-size: 14.5px; }
.account-rows dt { color: var(--dim); }
.account-rows dd { margin: 0; color: var(--text); }
.account .buttons { margin-top: 22px; }
.status-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 8px; background: var(--dim); }
.status-dot.on { background: var(--green); }
.error { color: var(--red); font-size: 14px; margin-top: 12px; }

.band { width: var(--content); margin: 72px auto 0; border: 1px solid var(--line-2); border-radius: 6px; padding: 28px 24px; background: var(--pane); }
.band .title { font-size: 22px; }
.band .lead { margin-top: 10px; }
.band .buttons { margin-top: 20px; }

/* -- footer, palette ------------------------------------------------------------------- */

.footer { width: var(--content); margin: 96px auto 0; padding: 32px 0 40px; border-top: 1px dashed var(--line-2); }
.footer-cols { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; margin-top: 18px; font-size: 14px; }
.footer nav { display: flex; flex-direction: column; gap: 2px; }
.footer .dir { color: var(--blue); margin-bottom: 4px; }
.footer nav a { color: var(--text-2); padding-left: 18px; }
.footer nav a:hover { color: var(--text); }
.footer-base { margin: 28px 0 0; color: var(--dim); font-size: 13px; }

.palette { position: fixed; inset: 0; z-index: 80; display: flex; justify-content: center; align-items: flex-start; padding-top: 14vh; background: rgba(5, 5, 6, 0.6); }
.palette-box { width: min(620px, 100% - 32px); border: 1px solid var(--line-2); border-radius: 8px; background: var(--pane); box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6); overflow: hidden; }
.palette-input { display: flex; align-items: center; gap: 10px; padding: 14px 16px; border-bottom: 1px solid var(--line); }
.palette-input input { flex: 1; border: 0; outline: 0; background: none; color: var(--text); font: 15px var(--mono); }
.palette-list { list-style: none; margin: 0; padding: 6px; max-height: 50vh; overflow: auto; }
.palette-list li { display: flex; justify-content: space-between; gap: 12px; padding: 7px 10px; border-radius: 4px; color: var(--text-2); cursor: pointer; }
.palette-list li small { color: var(--dim); }
.palette-list li.on { background: var(--orange); color: #111; }
.palette-list li.on small { color: rgba(17, 17, 17, 0.6); }
.palette-foot { display: flex; gap: 18px; padding: 8px 16px; border-top: 1px solid var(--line); color: var(--dim); font-size: 12.5px; }

@keyframes blink { 50% { opacity: 0; } }
@keyframes pulse { 50% { opacity: 0.35; } }
@keyframes spin-glyph { 25% { content: "◓"; } 50% { content: "◑"; } 75% { content: "◒"; } }

/* -- small screens ---------------------------------------------------------------------- */

@media (max-width: 960px) {
  :root { --content: calc(100% - 36px); }
  .plane { border: 0; }
  .tabs, .title-actions, .lights { display: none; }
  .menu-btn { display: block; margin-left: auto; font: 22px var(--mono); color: var(--text); background: none; border: 0; cursor: pointer; }
  .nav-open .tabs, .nav-open .title-actions { display: flex; position: absolute; left: 0; right: 0; flex-direction: column; align-items: flex-start; background: var(--bg); padding: 8px 18px; border-bottom: 1px solid var(--line); }
  .nav-open .tabs { top: 48px; height: auto; margin: 0; }
  .nav-open .tabs a { padding: 8px 0; border: 0; box-shadow: none; background: none; }
  .nav-open .title-actions { top: 268px; gap: 12px; margin: 0; }
  .home-grid { grid-template-columns: minmax(0, 1fr); }
  .side { display: none; }
  .stream { padding-top: 32px; }
  .session { grid-template-columns: minmax(0, 1fr); }
  .session .chat { grid-row: auto; }
  .parts, .feat-grid { grid-template-columns: minmax(0, 1fr); }
  .how, .steps { grid-template-columns: minmax(0, 1fr); }
  .agents { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .table, .table tbody, .table tr, .table td { display: block; }
  .table thead { display: none; }
  .table tr { padding: 10px 0; border-bottom: 1px dashed var(--line-2); }
  .table td { border: 0; padding: 2px 0; white-space: normal !important; }
  .with-toc { grid-template-columns: minmax(0, 1fr); width: var(--content); }
  .toc { display: none; }
  .plan-wrap { grid-template-columns: minmax(0, 1fr); }
  .footer-cols { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hide-sm { display: none; }
  .manhead span:nth-child(2) { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .caret, .worked .hot, .steps-log li.now::before { animation: none; }
  .js [data-step], .js [data-answer], .js [data-term] { opacity: 1; transition: none; }
}
