/* ============================================================
   OMARCHY — opinionated landing page
   Font: Cascadia Code · Palette: live-driven by theme engine
   ============================================================ */

@font-face {
  font-family: 'Cascadia Code';
  font-style: normal;
  font-weight: 300;
  font-display: swap;
  src: url('../fonts/CascadiaCode-SemiLight.woff2') format('woff2');
}
@font-face {
  font-family: 'Cascadia Code';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/CascadiaCode-Regular.woff2') format('woff2');
}
@font-face {
  font-family: 'Cascadia Code';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('../fonts/CascadiaCode-SemiBold.woff2') format('woff2');
}
@font-face {
  font-family: 'Cascadia Code';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('../fonts/CascadiaCode-Bold.woff2') format('woff2');
}

/* ---- Theme variables (defaults = tokyo-night; JS swaps per theme) ---- */
:root {
  --bg: #1a1b26;
  --bg-soft: #20222f;
  --bg-softer: #24283b;
  --fg: #a9b1d6;
  --fg-strong: #c0caf5;
  --muted: #6d7290;
  --border: #2f3346;
  --accent: #7aa2f7;
  --on-accent: #1a1b26;
  --green: #9ece6a;
  --red: #f7768e;
  --yellow: #e0af68;
  --purple: #ad8ee6;
  --cyan: #449dab;
  --sel-bg: #7aa2f7;
  --sel-fg: #c0caf5;
  --glow: rgba(122, 162, 247, .35);
  --shadow: rgba(0, 0, 0, .5);
  --bar-h: 44px;
  --font: 'Cascadia Code', Menlo, Monaco, Consolas, 'Courier New', monospace;
  --ease: cubic-bezier(.33, 1, .68, 1);
  color-scheme: dark;
}
html[data-light] { color-scheme: light; --shadow: rgba(30, 30, 30, .18); --glow: rgba(0,0,0,.12); }

/* ---- Reset-ish ---- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
html, body { height: 100%; }
body {
  font-family: var(--font);
  font-weight: 400;
  background: var(--bg);
  color: var(--fg);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  transition: background-color .45s var(--ease), color .45s var(--ease);
}
::selection { background: var(--sel-bg); color: var(--sel-fg); }
img { max-width: 100%; display: block; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }
strong { color: var(--fg-strong); font-weight: 600; }
code {
  font-family: var(--font);
  background: var(--bg-softer);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: .05em .4em;
  font-size: .88em;
  color: var(--fg-strong);
}
main { display: block; }

.kbd {
  display: inline-block;
  font-family: var(--font);
  font-size: .78em;
  font-weight: 600;
  color: var(--fg-strong);
  background: var(--bg-softer);
  border: 1px solid var(--border);
  border-bottom-width: 2px;
  border-radius: 5px;
  padding: .1em .5em;
  margin: 0 .12em;
  white-space: nowrap;
}

/* ============ THE BAR (top) ============ */
.bar {
  position: fixed;
  inset: 0 0 auto 0;
  height: var(--bar-h);
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0 .9rem;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
  font-size: .82rem;
  transition: background-color .45s var(--ease), border-color .45s var(--ease);
}
.bar__left, .bar__right { display: flex; align-items: center; gap: .7rem; min-width: 0; }
.bar__logo {
  display: flex; align-items: baseline; gap: .5rem;
  color: var(--fg-strong); font-weight: 700; letter-spacing: .02em;
}
.bar__logo:hover { text-decoration: none; color: var(--accent); }
.bar__glyph { color: var(--accent); font-size: .7em; transform: translateY(1px); }
.bar__workspaces { display: flex; gap: .2rem; }
.bar__workspaces a {
  display: grid; place-items: center;
  width: 1.7rem; height: 1.7rem;
  border-radius: 6px;
  color: var(--muted);
  font-weight: 600;
  transition: all .18s var(--ease);
}
.bar__workspaces a:hover { color: var(--fg-strong); background: var(--bg-softer); text-decoration: none; }
.bar__workspaces a.active {
  color: var(--on-accent);
  background: var(--accent);
  box-shadow: 0 0 14px var(--glow);
}
.bar__clock {
  font-family: var(--font);
  font-weight: 600;
  font-size: .85rem;
  color: var(--fg-strong);
  background: none; border: 0; cursor: pointer;
  padding: .2rem .7rem; border-radius: 6px;
  font-variant-numeric: tabular-nums;
  position: absolute; left: 50%; transform: translateX(-50%);
}
.bar__clock:hover { background: var(--bg-softer); }
.bar__theme {
  display: flex; align-items: center; gap: .45rem;
  font-family: var(--font); font-size: .8rem;
  color: var(--fg);
  background: none; border: 1px solid var(--border);
  border-radius: 999px; padding: .28rem .8rem; cursor: pointer;
  transition: all .18s var(--ease);
  max-width: 12rem; overflow: hidden; white-space: nowrap;
}
.bar__theme:hover { border-color: var(--accent); color: var(--fg-strong); }
.bar__theme-dot {
  width: .6rem; height: .6rem; border-radius: 50%;
  background: var(--accent); box-shadow: 0 0 8px var(--glow);
  flex: none;
}
.bar__icon { color: var(--muted); font-size: .95rem; }
.bar__cta {
  background: var(--accent); color: var(--on-accent);
  font-weight: 700; padding: .32rem .9rem; border-radius: 6px;
  transition: all .18s var(--ease);
}
.bar__cta:hover { text-decoration: none; box-shadow: 0 0 18px var(--glow); transform: translateY(-1px); }

/* ============ HERO ============ */
.hero {
  min-height: 100svh;
  display: flex; flex-direction: column;
  padding: calc(var(--bar-h) + 2.5rem) 4vw 2rem;
  position: relative;
  background:
    radial-gradient(60% 50% at 75% 20%, color-mix(in srgb, var(--accent) 9%, transparent), transparent 70%),
    radial-gradient(45% 40% at 15% 85%, color-mix(in srgb, var(--green) 6%, transparent), transparent 70%),
    var(--bg);
  transition: background-color .45s var(--ease);
}
.hero__inner {
  flex: 1;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr);
  gap: clamp(2rem, 4vw, 4.5rem);
  align-items: center;
  max-width: 1500px;
  width: 100%;
  margin: 0 auto;
}
.pill {
  display: inline-flex; align-items: center; gap: .55rem;
  font-size: .78rem; font-weight: 600;
  color: var(--fg-strong);
  border: 1px solid var(--border);
  background: var(--bg-soft);
  padding: .4rem .95rem; border-radius: 999px;
  margin-bottom: 1.4rem;
  transition: all .2s var(--ease);
}
.pill:hover { text-decoration: none; border-color: var(--accent); box-shadow: 0 0 16px var(--glow); }
.pill__pulse {
  width: .5rem; height: .5rem; border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 0 0 color-mix(in srgb, var(--green) 60%, transparent);
  animation: pulse 2.2s infinite;
}
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--green) 55%, transparent); }
  70% { box-shadow: 0 0 0 9px transparent; }
  100% { box-shadow: 0 0 0 0 transparent; }
}
.pill__arrow { transition: transform .2s var(--ease); }
.pill:hover .pill__arrow { transform: translateX(3px); }

.hero__ascii {
  color: var(--accent);
  font-size: clamp(3.4px, .82vw, 11px);
  line-height: 1.12;
  letter-spacing: 0;
  margin: 0 0 1.6rem;
  text-shadow: 0 0 22px var(--glow);
  user-select: none;
  overflow: hidden;
  transition: color .45s var(--ease), text-shadow .45s var(--ease);
}
.hero__title {
  font-size: clamp(1.65rem, 3.1vw, 3rem);
  font-weight: 700;
  line-height: 1.14;
  letter-spacing: -.01em;
  color: var(--fg-strong);
  margin-bottom: 1.2rem;
}
.hero__title em { font-style: normal; color: var(--accent); }
.hero__sub {
  font-size: clamp(.92rem, 1.15vw, 1.05rem);
  max-width: 56ch;
  color: var(--fg);
  margin-bottom: 1.8rem;
}
.hero__ctas { display: flex; flex-wrap: wrap; gap: .7rem; margin-bottom: 1.1rem; }
.btn {
  display: inline-flex; align-items: center; gap: .55rem;
  font-family: var(--font); font-weight: 600; font-size: .92rem;
  padding: .75rem 1.35rem; border-radius: 8px;
  border: 1px solid transparent;
  transition: all .18s var(--ease);
  cursor: pointer;
}
.btn:hover { text-decoration: none; transform: translateY(-2px); }
.btn--primary {
  background: var(--accent); color: var(--on-accent);
  box-shadow: 0 6px 24px -6px var(--glow);
}
.btn--primary:hover { box-shadow: 0 10px 32px -6px var(--glow); }
.btn--ghost {
  border-color: var(--border); color: var(--fg-strong);
  background: var(--bg-soft);
}
.btn--ghost:hover { border-color: var(--accent); }
.btn__key { font-weight: 700; }
.hero__hint { font-size: .8rem; color: var(--muted); }

/* --- terminal --- */
.hero__term { min-width: 0; }
.term {
  position: relative;
  background: color-mix(in srgb, var(--bg) 65%, #000 12%);
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: 0 30px 70px -20px var(--shadow), 0 0 0 1px color-mix(in srgb, var(--accent) 8%, transparent), 0 0 60px -20px var(--glow);
  overflow: hidden;
}
.term__chrome {
  display: flex; align-items: center; gap: .45rem;
  padding: .65rem .9rem;
  background: var(--bg-softer);
  border-bottom: 1px solid var(--border);
}
.term__dot { width: .65rem; height: .65rem; border-radius: 50%; background: var(--border); }
.term__dot:nth-child(1) { background: var(--red); }
.term__dot:nth-child(2) { background: var(--yellow); }
.term__dot:nth-child(3) { background: var(--green); }
.term__title { margin-left: .5rem; font-size: .75rem; color: var(--muted); flex: 1; }
.term__replay {
  font-family: var(--font); font-size: .72rem; font-weight: 600;
  color: var(--muted); background: none; border: 1px solid var(--border);
  border-radius: 5px; padding: .2rem .6rem; cursor: pointer;
  transition: all .15s var(--ease); opacity: 0; pointer-events: none;
}
.term__replay.visible { opacity: 1; pointer-events: auto; }
.term__replay:hover { color: var(--fg-strong); border-color: var(--accent); }
.term__screen {
  height: clamp(300px, 38vh, 400px);
  padding: 1rem 1.1rem;
  font-size: clamp(.62rem, .95vw, .82rem);
  line-height: 1.5;
  overflow: hidden;
  white-space: pre-wrap;
  word-break: break-word;
  color: var(--fg);
}
.term__screen .t-dim { color: var(--muted); }
.term__screen .t-accent { color: var(--accent); }
.term__screen .t-green { color: var(--green); }
.term__screen .t-yellow { color: var(--yellow); }
.term__screen .t-red { color: var(--red); }
.term__screen .t-strong { color: var(--fg-strong); font-weight: 600; }
.term__cursor {
  display: inline-block; width: .58em; height: 1.1em;
  background: var(--accent); vertical-align: text-bottom;
  animation: blink 1s steps(1) infinite;
}
@keyframes blink { 50% { opacity: 0; } }
.term__scanlines {
  position: absolute; inset: 0; pointer-events: none;
  background: repeating-linear-gradient(to bottom, transparent 0 2px, rgba(0,0,0,.09) 2px 3px);
  mix-blend-mode: multiply;
}
html[data-light] .term__scanlines { opacity: .25; }
.hero__term-caption { margin-top: .8rem; font-size: .76rem; color: var(--muted); text-align: center; }

.hero__scrollcue {
  display: flex; flex-direction: column; align-items: center; gap: .5rem;
  margin: 2rem auto 0;
  color: var(--muted); font-size: .72rem; letter-spacing: .25em; text-transform: uppercase;
}
.hero__scrollcue:hover { text-decoration: none; color: var(--fg-strong); }
.hero__scrollcue-line {
  width: 1px; height: 3rem;
  background: linear-gradient(var(--accent), transparent);
  animation: cue 2s var(--ease) infinite;
}
@keyframes cue { 0% { transform: scaleY(0); transform-origin: top; } 45% { transform: scaleY(1); transform-origin: top; } 55% { transform: scaleY(1); transform-origin: bottom; } 100% { transform: scaleY(0); transform-origin: bottom; } }

/* ============ TICKER ============ */
.ticker {
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  background: var(--bg-soft);
  overflow: hidden;
  padding: .85rem 0;
  transition: background-color .45s var(--ease);
}
.ticker__track {
  display: flex; gap: 2.2rem; align-items: center;
  width: max-content;
  animation: ticker 36s linear infinite;
  font-size: .85rem; font-weight: 600;
  color: var(--muted);
  text-transform: uppercase; letter-spacing: .18em;
  white-space: nowrap;
}
.ticker__track i { color: var(--accent); font-style: normal; }
@keyframes ticker { to { transform: translateX(-50%); } }

/* ============ SECTIONS ============ */
.section { padding: clamp(4.5rem, 9vw, 8.5rem) 4vw; max-width: 1500px; margin: 0 auto; }
.section__head { margin-bottom: clamp(2.2rem, 4vw, 3.6rem); max-width: 62rem; }
.section__index {
  display: flex; align-items: center; gap: .6rem;
  font-size: .8rem; letter-spacing: .3em; text-transform: uppercase;
  color: var(--muted); margin-bottom: 1.1rem;
}
.ws-tag {
  display: inline-grid; place-items: center;
  width: 1.6rem; height: 1.6rem;
  background: var(--accent); color: var(--on-accent);
  border-radius: 6px; font-weight: 700; letter-spacing: 0;
  box-shadow: 0 0 14px var(--glow);
}
.section__title {
  font-size: clamp(1.9rem, 4.2vw, 3.6rem);
  font-weight: 700; line-height: 1.08; letter-spacing: -.015em;
  color: var(--fg-strong);
}
.section__lede { margin-top: 1.2rem; font-size: clamp(.95rem, 1.2vw, 1.08rem); color: var(--fg); max-width: 62ch; }

/* ============ PHILOSOPHY ============ */
.philosophy__grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(2rem, 4vw, 4rem);
  margin-bottom: clamp(3rem, 6vw, 5rem);
  align-items: start;
}
.philosophy__quote {
  border-left: 3px solid var(--accent);
  padding: .4rem 0 .4rem 1.6rem;
}
.philosophy__quote p {
  font-size: clamp(1.25rem, 2.1vw, 1.85rem);
  font-weight: 600; line-height: 1.35;
  color: var(--fg-strong);
}
.philosophy__quote cite { display: block; margin-top: 1rem; font-style: normal; font-size: .82rem; color: var(--muted); }
.philosophy__body p { margin-bottom: 1.1rem; max-width: 62ch; }
.philosophy__punch { color: var(--accent); font-weight: 600; font-size: 1.05em; }

.creed {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: 14px;
  overflow: hidden;
}
.creed__item {
  background: var(--bg-soft);
  padding: 1.8rem 1.5rem;
  transition: background-color .25s var(--ease), transform .25s var(--ease);
}
.creed__item:hover { background: var(--bg-softer); }
.creed__num {
  display: block;
  font-size: .8rem; font-weight: 700;
  color: var(--accent);
  margin-bottom: 1.6rem;
}
.creed__item h3 { color: var(--fg-strong); font-size: 1.02rem; margin-bottom: .6rem; }
.creed__item p { font-size: .87rem; color: var(--fg); }

/* ============ STACK / BENTO ============ */
.bento {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1rem;
}
.bento__card {
  position: relative;
  grid-column: span 1;
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 1.6rem 1.5rem;
  overflow: hidden;
  transition: transform .25s var(--ease), border-color .25s var(--ease), box-shadow .25s var(--ease), background-color .45s var(--ease);
}
.bento__card--wide { grid-column: span 2; grid-row: span 2; }
.bento__card:hover {
  transform: translateY(-4px);
  border-color: color-mix(in srgb, var(--accent) 55%, var(--border));
  box-shadow: 0 18px 44px -18px var(--shadow), 0 0 30px -12px var(--glow);
}
.bento__tag {
  display: inline-block;
  font-size: .68rem; font-weight: 700;
  letter-spacing: .22em; text-transform: uppercase;
  color: var(--accent);
  border: 1px solid color-mix(in srgb, var(--accent) 40%, var(--border));
  border-radius: 999px;
  padding: .2rem .7rem;
  margin-bottom: 1rem;
}
.bento__card h3 { color: var(--fg-strong); font-size: 1.12rem; margin-bottom: .55rem; }
.bento__card p { font-size: .88rem; color: var(--fg); }
.bento__card--accent { background: color-mix(in srgb, var(--accent) 10%, var(--bg-soft)); border-color: color-mix(in srgb, var(--accent) 45%, var(--border)); }
.bento__windows {
  position: relative;
  height: 9.5rem;
  margin-top: 1.4rem;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--bg);
  overflow: hidden;
}
.bento__win { position: absolute; border-radius: 6px; border: 1px solid var(--border); transition: all .5s var(--ease); }
.bento__win--a { inset: 8% 51% 8% 5%; background: color-mix(in srgb, var(--accent) 16%, var(--bg-softer)); }
.bento__win--b { inset: 8% 5% 51% 51%; background: color-mix(in srgb, var(--green) 14%, var(--bg-softer)); }
.bento__win--c { inset: 51% 5% 8% 51%; background: color-mix(in srgb, var(--purple) 14%, var(--bg-softer)); }
.bento__card:hover .bento__win--a { inset: 8% 5% 51% 5%; }
.bento__card:hover .bento__win--b { inset: 51% 51% 8% 5%; }
.bento__card:hover .bento__win--c { inset: 8% 5% 8% 51%; }

/* ============ THEMES ============ */
.themes__showcase {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr);
  gap: clamp(1.5rem, 3vw, 3rem);
  align-items: stretch;
  margin-bottom: 1.6rem;
}
.themes__frame {
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  background: var(--bg-soft);
  box-shadow: 0 30px 70px -25px var(--shadow);
  transition: box-shadow .3s var(--ease);
}
.themes__frame-bar {
  display: flex; align-items: center; gap: .45rem;
  padding: .6rem .9rem;
  background: var(--bg-softer);
  border-bottom: 1px solid var(--border);
}
.themes__frame-title { margin-left: .5rem; font-size: .75rem; color: var(--muted); }
.themes__viewport { aspect-ratio: 16 / 10; overflow: hidden; background: var(--bg); }
.themes__viewport img {
  width: 100%; height: 100%; object-fit: cover;
  transition: opacity .3s var(--ease), transform .6s var(--ease);
}
.themes__viewport img.fading { opacity: 0; transform: scale(1.015); }
.themes__side {
  display: flex; flex-direction: column; justify-content: center; gap: 1.1rem;
  min-width: 0;
}
.themes__meta h3 { font-size: clamp(1.4rem, 2.2vw, 2rem); color: var(--fg-strong); font-weight: 700; }
.themes__meta p { color: var(--fg); font-size: .92rem; margin-top: .4rem; min-height: 3.2em; }
.themes__swatches { list-style: none; display: flex; flex-wrap: wrap; gap: .45rem; }
.themes__swatches li {
  width: 1.9rem; height: 1.9rem; border-radius: 7px;
  border: 1px solid var(--border);
  transition: transform .18s var(--ease);
}
.themes__swatches li:hover { transform: scale(1.15); }
.themes__status {
  font-size: .82rem;
  color: var(--green);
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: .65rem .9rem;
  overflow-wrap: anywhere;
}
.themes__status .prompt { color: var(--accent); font-weight: 700; }
.themes__keys { font-size: .78rem; color: var(--muted); }

.themes__strip-wrap { margin: 0 -4vw; padding: 0 4vw; overflow-x: auto; scrollbar-width: thin; scrollbar-color: var(--border) transparent; }
.themes__strip {
  display: flex; gap: .7rem;
  padding: .4rem .1rem 1rem;
  width: max-content;
}
.theme-chip {
  display: flex; flex-direction: column; gap: .5rem;
  font-family: var(--font);
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: .55rem;
  cursor: pointer;
  transition: all .2s var(--ease);
  text-align: left;
  scroll-snap-align: start;
}
.theme-chip:hover { border-color: color-mix(in srgb, var(--accent) 60%, var(--border)); transform: translateY(-3px); }
.theme-chip.active {
  border-color: var(--accent);
  box-shadow: 0 0 0 1px var(--accent), 0 8px 26px -10px var(--glow);
}
.theme-chip__thumb {
  width: 9.2rem; aspect-ratio: 16/10;
  border-radius: 6px; overflow: hidden;
  background: var(--bg);
}
.theme-chip__thumb img { width: 100%; height: 100%; object-fit: cover; }
.theme-chip__label {
  display: flex; align-items: center; gap: .45rem;
  font-size: .75rem; font-weight: 600; color: var(--fg-strong);
  white-space: nowrap;
}
.theme-chip__dot { width: .55rem; height: .55rem; border-radius: 50%; flex: none; }

/* ============ INSTALL ============ */
.steps { list-style: none; position: relative; max-width: 56rem; }
.steps::before {
  content: '';
  position: absolute; left: 1.55rem; top: 1rem; bottom: 1rem;
  width: 1px;
  background: linear-gradient(var(--accent), color-mix(in srgb, var(--accent) 15%, transparent));
  opacity: .5;
}
.step {
  position: relative;
  display: grid;
  grid-template-columns: 3.1rem minmax(0, 1fr);
  gap: 1.4rem;
  padding-bottom: 2.6rem;
}
.step:last-child { padding-bottom: 0; }
.step__num {
  width: 3.1rem; height: 3.1rem;
  display: grid; place-items: center;
  background: var(--bg-soft);
  border: 1px solid var(--accent);
  color: var(--accent);
  font-weight: 700; font-size: 1.05rem;
  border-radius: 10px;
  box-shadow: 0 0 22px -6px var(--glow);
  position: relative; z-index: 1;
  transition: all .2s var(--ease);
}
.step:hover .step__num { background: var(--accent); color: var(--on-accent); }
.step__body h3 { color: var(--fg-strong); font-size: 1.2rem; margin-bottom: .45rem; padding-top: .55rem; }
.step__body p { color: var(--fg); font-size: .93rem; max-width: 58ch; margin-bottom: .5rem; }
.step__aside {
  font-size: .84rem !important;
  color: var(--muted) !important;
  border-left: 2px solid var(--yellow);
  padding-left: .9rem;
}
.cmdline {
  display: flex; align-items: center; gap: .6rem;
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: .6rem .8rem;
  margin-top: .7rem;
  max-width: 40rem;
  overflow-x: auto;
}
.cmdline code { background: none; border: 0; padding: 0; flex: 1; white-space: nowrap; font-size: .85rem; }
.cmdline--dim code { color: var(--muted); }
.c-green { color: var(--green); }
.copy {
  font-family: var(--font); font-size: .72rem; font-weight: 600;
  color: var(--muted); background: var(--bg-softer);
  border: 1px solid var(--border); border-radius: 5px;
  padding: .25rem .7rem; cursor: pointer;
  transition: all .15s var(--ease);
  flex: none;
}
.copy:hover { color: var(--fg-strong); border-color: var(--accent); }
.copy.done { color: var(--green); border-color: var(--green); }

.install__notes {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
  margin-top: 3.2rem;
}
.install__note {
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.4rem 1.4rem;
  transition: border-color .2s var(--ease), background-color .45s var(--ease);
}
.install__note:hover { border-color: color-mix(in srgb, var(--accent) 50%, var(--border)); }
.install__note h4 { color: var(--fg-strong); font-size: .95rem; margin-bottom: .5rem; }
.install__note p { font-size: .85rem; color: var(--fg); }

/* ============ HOTKEYS ============ */
.hotkeys__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.2rem;
  margin-bottom: 3rem;
}
.hotkeys__group {
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 1.5rem;
  transition: background-color .45s var(--ease);
}
.hotkeys__group h3 {
  color: var(--accent); font-size: .78rem;
  letter-spacing: .25em; text-transform: uppercase;
  margin-bottom: 1.1rem;
}
.hk { list-style: none; }
.hk li {
  display: flex; align-items: baseline; gap: .8rem;
  padding: .5rem .4rem;
  border-radius: 7px;
  font-size: .84rem;
  color: var(--fg);
  transition: background-color .15s var(--ease);
}
.hk li:hover { background: var(--bg-softer); }
.hk__keys { flex: none; min-width: 9.5rem; }

.numbers {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: 14px;
  overflow: hidden;
}
.numbers__item {
  background: var(--bg-soft);
  padding: 1.6rem 1rem;
  text-align: center;
  transition: background-color .25s var(--ease);
}
.numbers__item:hover { background: var(--bg-softer); }
.numbers__item strong {
  display: block;
  font-size: clamp(1.5rem, 2.6vw, 2.3rem);
  font-weight: 700;
  color: var(--accent);
  line-height: 1.1;
}
.numbers__item strong em { font-style: normal; font-size: .55em; color: var(--fg); }
.numbers__item span { display: block; margin-top: .4rem; font-size: .74rem; color: var(--muted); }

/* ============ COMMUNITY ============ */
.paths {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}
.path {
  display: block;
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 1.7rem 1.6rem;
  color: var(--fg);
  transition: transform .22s var(--ease), border-color .22s var(--ease), box-shadow .22s var(--ease), background-color .45s var(--ease);
}
.path:hover {
  text-decoration: none;
  transform: translateY(-4px);
  border-color: var(--accent);
  box-shadow: 0 18px 44px -18px var(--shadow), 0 0 30px -12px var(--glow);
}
.path--primary { background: color-mix(in srgb, var(--accent) 12%, var(--bg-soft)); border-color: color-mix(in srgb, var(--accent) 50%, var(--border)); }
.path__key {
  display: inline-grid; place-items: center;
  width: 2.2rem; height: 2.2rem;
  background: var(--bg-softer);
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--accent);
  font-size: 1.05rem;
  margin-bottom: 1.2rem;
}
.path h3 { color: var(--fg-strong); font-size: 1.08rem; margin-bottom: .45rem; }
.path p { font-size: .87rem; margin-bottom: 1rem; }
.path__go { font-size: .8rem; font-weight: 600; color: var(--accent); }

/* ============ FOOTER ============ */
.footer {
  border-top: 1px solid var(--border);
  padding: clamp(3rem, 6vw, 5rem) 4vw 3rem;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: clamp(2rem, 5vw, 5rem);
  max-width: 1500px;
  margin: 0 auto;
  align-items: start;
}
.footer__ascii {
  color: var(--accent);
  font-size: clamp(4px, .7vw, 8px);
  line-height: 1.15;
  opacity: .85;
  user-select: none;
}
.footer__line { font-size: .88rem; margin-bottom: .8rem; max-width: 70ch; }
.footer__line--dim { color: var(--muted); font-size: .8rem; }

/* ============ OVERLAY ============ */
.overlay[hidden] { display: none; }
.overlay {
  position: fixed; inset: 0; z-index: 200;
  display: grid; place-items: center;
  background: color-mix(in srgb, var(--bg) 70%, transparent);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  animation: overlay-in .18s var(--ease);
  padding: 1rem;
}
@keyframes overlay-in { from { opacity: 0; } }
.overlay__panel {
  width: min(30rem, 100%);
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: 0 40px 90px -20px var(--shadow), 0 0 50px -18px var(--glow);
  overflow: hidden;
  animation: panel-in .22s var(--ease);
}
@keyframes panel-in { from { transform: translateY(10px) scale(.98); opacity: 0; } }
.overlay__head {
  display: flex; justify-content: space-between; align-items: center;
  padding: .9rem 1.2rem;
  border-bottom: 1px solid var(--border);
  background: var(--bg-softer);
  font-size: .78rem; letter-spacing: .25em; text-transform: uppercase;
  color: var(--muted);
}
.overlay__close {
  font-family: var(--font); font-size: .72rem; font-weight: 600;
  color: var(--muted); background: var(--bg);
  border: 1px solid var(--border); border-radius: 5px;
  padding: .2rem .6rem; cursor: pointer;
}
.overlay__close:hover { color: var(--fg-strong); border-color: var(--accent); }
.overlay__list { list-style: none; padding: 1rem 1.2rem; }
.overlay__list li {
  display: flex; justify-content: space-between; align-items: center; gap: 1rem;
  padding: .55rem 0;
  font-size: .88rem; color: var(--fg);
  border-bottom: 1px dashed color-mix(in srgb, var(--border) 60%, transparent);
}
.overlay__list li:last-child { border-bottom: 0; }
.overlay__foot {
  padding: .9rem 1.2rem 1.1rem;
  font-size: .78rem; color: var(--muted);
  border-top: 1px solid var(--border);
}

/* ============ TOAST ============ */
.toast {
  position: fixed;
  bottom: 1.4rem; left: 50%;
  transform: translate(-50%, 150%);
  z-index: 300;
  background: var(--bg-softer);
  border: 1px solid var(--accent);
  color: var(--fg-strong);
  font-size: .82rem; font-weight: 600;
  padding: .6rem 1.1rem;
  border-radius: 8px;
  box-shadow: 0 12px 40px -10px var(--shadow), 0 0 24px -8px var(--glow);
  transition: transform .25s var(--ease);
  pointer-events: none;
  max-width: 90vw;
  overflow-wrap: anywhere;
}
.toast.show { transform: translate(-50%, 0); }

/* ============ REVEAL (only when JS on) ============ */
html.js .reveal { opacity: 0; transform: translateY(26px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
html.js .reveal.in { opacity: 1; transform: none; }

/* ============ RESPONSIVE ============ */
@media (max-width: 1100px) {
  .hero__inner { grid-template-columns: 1fr; align-items: start; }
  .hero__ascii { font-size: clamp(3.2px, 1.35vw, 11px); }
  .term__screen { height: 320px; }
  .bento { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .creed { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hotkeys__grid { grid-template-columns: 1fr; }
  .numbers { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .paths { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .philosophy__grid { grid-template-columns: 1fr; }
  .themes__showcase { grid-template-columns: 1fr; }
  .install__notes { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .bar__workspaces a { width: 1.5rem; height: 1.5rem; font-size: .76rem; }
  .cmdline code { white-space: normal; overflow-wrap: anywhere; }
  .bar__word, .bar__icon, .bar__theme span:last-child { display: none; }
  .bar__theme { padding: .3rem .55rem; }
  .bar__clock { font-size: .78rem; }
  .bar__cta { padding: .3rem .65rem; font-size: .78rem; }
  .hero { padding-top: calc(var(--bar-h) + 1.6rem); }
  .hero__ascii { font-size: clamp(2.4px, 1.5vw, 6px); }
  .bento { grid-template-columns: 1fr; }
  .bento__card--wide { grid-column: span 1; grid-row: span 1; }
  .creed { grid-template-columns: 1fr; }
  .numbers { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .paths { grid-template-columns: 1fr; }
  .footer { grid-template-columns: 1fr; }
  .bar__clock { display: none; }
  .hk__keys { min-width: 7.2rem; }
  .step { grid-template-columns: 2.6rem minmax(0, 1fr); gap: 1rem; }
  .step__num { width: 2.6rem; height: 2.6rem; }
  .steps::before { left: 1.3rem; }
  .hero__scrollcue { display: none; }
}

/* ============ REDUCED MOTION ============ */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  html.js .reveal { opacity: 1; transform: none; }
  .ticker__track { animation: none; }
}
