/* ============================================================
   jterm landing site
   Design: soft-modern dev tool. Near-black, cyan/teal accent
   (from the logo), monospace numerics, bento features.
   ============================================================ */

:root {
  --bg: #0b0d11;
  --bg-subtle: #0f1218;
  --bg-elevated: #141821;
  --bg-tint: #0e1117;

  --fg: #e7eaf0;
  --fg-muted: #9aa6b6;
  --fg-subtle: #6b7686;

  --border: rgba(255, 255, 255, 0.08);
  --border-strong: rgba(255, 255, 255, 0.15);

  --accent: #5ac8fa;
  --accent-2: #2dd4bf;
  --accent-3: #4ade80;
  --accent-soft: rgba(90, 200, 250, 0.14);
  --grad: linear-gradient(135deg, #5ac8fa 0%, #3f9fe6 100%);

  --font-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;

  --radius: 16px;
  --radius-sm: 10px;

  --container: 1200px;
  --shadow: 0 24px 60px -20px rgba(0, 0, 0, 0.7);
  --ease: cubic-bezier(0.4, 0, 0.2, 1);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

/* Ambient backdrop glow */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(60% 50% at 75% -5%, rgba(90, 200, 250, 0.06), transparent 70%),
    radial-gradient(45% 40% at 10% 5%, rgba(90, 200, 250, 0.035), transparent 70%);
  pointer-events: none;
}

h1, h2, h3, h4 { margin: 0; font-weight: 700; letter-spacing: -0.02em; line-height: 1.12; }
p { margin: 0; }
a { color: inherit; text-decoration: none; }
code, kbd, pre { font-family: var(--font-mono); }
code {
  font-size: 0.88em;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 0.08em 0.36em;
  color: #cfe9ff;
}
.muted { color: var(--fg-subtle); }
.grad {
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 24px; }

.skip-link {
  position: absolute;
  left: -999px;
  top: 8px;
  background: var(--accent);
  color: #04121b;
  padding: 8px 14px;
  border-radius: 8px;
  z-index: 200;
  font-weight: 600;
}
.skip-link:focus { left: 16px; }

/* ---------------- Buttons ---------------- */
.btn {
  --h: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  height: var(--h);
  padding: 0 18px;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: transform 0.12s var(--ease), background 0.15s var(--ease),
    border-color 0.15s var(--ease), box-shadow 0.15s var(--ease), color 0.15s var(--ease);
}
.btn-sm { --h: 34px; padding: 0 14px; font-size: 13px; }
.btn-lg { --h: 50px; padding: 0 26px; font-size: 15.5px; }
.btn-primary {
  background: var(--accent);
  color: #04121b;
  box-shadow: 0 2px 8px -3px rgba(0, 0, 0, 0.45);
}
.btn-primary:hover { transform: translateY(-1px); background: #6fd0fb; box-shadow: 0 8px 18px -6px rgba(0, 0, 0, 0.55); }
.btn-secondary {
  background: rgba(255, 255, 255, 0.04);
  border-color: var(--border-strong);
  color: var(--fg);
}
.btn-secondary:hover { background: rgba(255, 255, 255, 0.09); border-color: var(--fg-subtle); }
.btn-ghost { background: transparent; color: var(--fg-muted); }
.btn-ghost:hover { color: var(--fg); background: rgba(255, 255, 255, 0.05); }
.btn:focus-visible,
a:focus-visible,
button:focus-visible {
  outline: none;
  box-shadow: 0 0 0 2px var(--bg), 0 0 0 4px var(--accent);
}
.ico { flex: 0 0 auto; }

/* ---------------- Nav ---------------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(11, 13, 17, 0.72);
  backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid var(--border);
}
.nav-inner { display: flex; align-items: center; gap: 24px; height: 64px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 700; }
.brand-mark { border-radius: 7px; }
.brand-name { font-size: 18px; letter-spacing: -0.03em; }
.nav-links { display: flex; gap: 26px; margin-left: 14px; flex: 1; }
.nav-links a {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--fg-muted);
  font-size: 14.5px;
  font-weight: 500;
  transition: color 0.15s;
}
.nav-links a:hover { color: var(--fg); }
.nav-links a.active,
.nav-links a[aria-current="page"] { color: var(--fg); }
.nav-links a.active::after,
.nav-links a[aria-current="page"]::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -21px;
  height: 2px;
  border-radius: 2px;
  background: var(--grad);
}
.nav-links a .ico { width: 15px; height: 15px; }
.nav-actions { display: flex; align-items: center; gap: 10px; }
.gh-star { gap: 7px; }

.nav-toggle { display: none; }
.mobile-menu { display: none; }

/* ---------------- Hero ---------------- */
.hero { padding: clamp(56px, 9vw, 104px) 0 56px; overflow-x: clip; }
.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: 56px;
  align-items: center;
}
.hero-copy { min-width: 0; }
.hero-title { font-size: clamp(2rem, 5.6vw, 4.1rem); font-weight: 800; overflow-wrap: break-word; }
.hero-sub {
  margin-top: 22px;
  max-width: 30em;
  font-size: clamp(1rem, 1.6vw, 1.18rem);
  color: var(--fg-muted);
}
.hero-cta { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 34px; }
.hero-meta { margin-top: 18px; font-size: 13.5px; color: var(--fg-muted); font-family: var(--font-mono); }
.hero-meta #version-badge { color: var(--accent-3); }

/* Terminal mockup */
.hero-term { position: relative; min-width: 0; }
.term-window {
  position: relative;
  z-index: 1;
  max-width: 100%;
  background: linear-gradient(180deg, #0d1016, #0a0c10);
  border: 1px solid var(--border-strong);
  border-radius: 14px;
  box-shadow: var(--shadow);
  overflow: hidden;
}
.term-glow {
  position: absolute;
  inset: -10% -6% -22%;
  z-index: 0;
  background: var(--grad);
  filter: blur(70px);
  opacity: 0.12;
}

/* Title bar + window tabs */
.term-bar {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 11px 14px;
  background: rgba(255, 255, 255, 0.025);
  border-bottom: 1px solid var(--border);
}
.term-dot { width: 11px; height: 11px; border-radius: 50%; }
.term-dot.r { background: #ff5f57; }
.term-dot.y { background: #febc2e; }
.term-dot.g { background: #28c840; }
.term-tabs { display: flex; gap: 6px; margin-left: 14px; font-family: var(--font-mono); font-size: 11.5px; }
.term-tab { padding: 3px 10px; border-radius: 6px 6px 0 0; color: var(--fg-subtle); white-space: nowrap; }
.term-tab.active { background: rgba(255, 255, 255, 0.06); color: var(--fg); }
.term-tab.plus { color: var(--fg-subtle); }

/* Body: explorer | editor | terminal */
.term-body {
  display: grid;
  grid-template-columns: 0.6fr 1fr 1.2fr;
  min-height: 214px;
  font-family: var(--font-mono);
  font-size: 11.5px;
  line-height: 1.65;
}

/* Explorer + git status */
.term-explorer {
  padding: 13px 9px;
  border-right: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.02);
  font-size: 11px;
  min-width: 0;
}
.term-side-head {
  color: var(--fg-subtle);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 9.5px;
  margin-bottom: 10px;
}
.tree-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  padding: 2px 7px;
  border-radius: 5px;
  color: var(--fg-muted);
  white-space: nowrap;
}
.tree-row.indent { padding-left: 17px; }
.tree-row .tree-name { overflow: hidden; text-overflow: ellipsis; }
.tree-dir { color: var(--fg-subtle); }
.git-mark { flex: 0 0 auto; font-size: 9px; font-weight: 600; padding: 0 4px; border-radius: 4px; }
.git-mod { color: #e8c170; }
.git-mod .git-mark { background: rgba(232, 193, 112, 0.16); }
.git-add { color: var(--accent-3); }
.git-add .git-mark { background: rgba(74, 222, 128, 0.16); }
.git-unt { color: var(--accent); }
.git-unt .git-mark { background: rgba(90, 200, 250, 0.16); }

/* Editor: tabbed buffers, gutter, syntax */
.term-editor {
  display: flex;
  flex-direction: column;
  border-right: 1px solid var(--border);
  min-width: 0;
}
.term-edit-tabs {
  display: flex;
  background: rgba(255, 255, 255, 0.015);
  border-bottom: 1px solid var(--border);
}
.term-edit-tab {
  padding: 6px 10px;
  font-size: 10.5px;
  color: var(--fg-subtle);
  border-right: 1px solid var(--border);
  white-space: nowrap;
}
.term-edit-tab.active { color: var(--fg); background: rgba(255, 255, 255, 0.04); }
.term-code { padding: 8px 0; overflow: hidden; }
.code-lines { margin: 0; padding: 0; list-style: none; counter-reset: ln; }
.code-lines li {
  counter-increment: ln;
  position: relative;
  min-height: 1.65em;
  padding: 0 12px 0 38px;
  white-space: nowrap;
  color: var(--fg-muted);
}
.code-lines li::before {
  content: counter(ln);
  position: absolute;
  left: 0;
  width: 26px;
  text-align: right;
  color: var(--fg-subtle);
  opacity: 0.5;
}
.code-lines li.is-active { background: rgba(90, 200, 250, 0.07); }
.t-kw { color: #c792ea; }
.t-fn { color: var(--accent); }
.t-ty { color: var(--accent-2); }
.t-str { color: var(--accent-3); }
.t-at { color: #e8c170; }
.t-op { color: var(--fg-subtle); }
.edit-caret {
  display: inline-block;
  width: 1px;
  height: 1em;
  background: var(--accent);
  margin-left: 1px;
  vertical-align: text-bottom;
  animation: blink 1.05s step-end infinite;
}

/* Terminal pane: real PTY, looping commands */
.term-pane-main { padding: 13px 15px; min-width: 0; overflow: hidden; }
.term-run { transition: opacity 0.35s var(--ease); }
.term-run.clearing { opacity: 0; }
.term-run .fade { opacity: 0; transform: translateY(4px); transition: opacity 0.3s var(--ease), transform 0.3s var(--ease); }
.term-run .fade.in { opacity: 1; transform: none; }
.term-line { white-space: nowrap; }
.term-line .p { color: var(--accent-2); }
.term-line .c { color: var(--accent); }
.term-out { color: var(--fg-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.term-out.dim { color: var(--fg-subtle); }
.term-out .ok { color: var(--accent-3); }
.caret {
  display: inline-block;
  width: 7px;
  height: 1.05em;
  background: var(--accent);
  vertical-align: text-bottom;
  margin-left: 1px;
  animation: blink 1.05s step-end infinite;
}
.blink { color: var(--accent); animation: blink 1.05s step-end infinite; }
@keyframes blink { 50% { opacity: 0; } }

/* Bottom panel (⌘J): a second shell with live logs */
.term-panel {
  border-top: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.015);
  font-family: var(--font-mono);
  font-size: 11px;
}
.term-panel-tabs {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 7px 14px 0;
  border-bottom: 1px solid var(--border);
}
.term-panel-tab {
  padding-bottom: 7px;
  font-size: 10px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--fg-subtle);
}
.term-panel-tab.active { color: var(--fg); box-shadow: inset 0 -2px 0 var(--accent); }
.term-panel-hint { margin-left: auto; color: var(--fg-subtle); font-size: 10px; }
.term-panel-body { padding: 10px 14px 12px; }
.term-panel-body .p { color: var(--accent-2); }
.term-panel-body .c { color: var(--accent); }
.term-panel-body .ok { color: var(--accent-3); }
.term-spark { display: flex; align-items: flex-end; gap: 3px; height: 30px; margin-top: 9px; }
.term-spark i { flex: 1; background: linear-gradient(180deg, var(--accent), var(--accent-2)); border-radius: 2px; opacity: 0.8; transition: height 0.5s var(--ease); }

/* Status bar: source control + context */
.term-status {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 6px 14px;
  background: rgba(90, 200, 250, 0.06);
  border-top: 1px solid var(--border);
  font-family: var(--font-mono);
  font-size: 10.5px;
  color: var(--fg-muted);
  overflow: hidden;
}
.st-seg { display: inline-flex; align-items: center; gap: 4px; white-space: nowrap; }
.st-branch { color: var(--accent); }
.st-mod { color: #e8c170; }
.st-spacer { flex: 1; }
.st-key { color: var(--fg-subtle); }

/* IDE chrome entrance (plays once) */
[data-rise] { opacity: 0; transform: translateY(10px); animation: riseIn 0.6s var(--ease) forwards; }
[data-rise="1"] { animation-delay: 0.05s; }
[data-rise="2"] { animation-delay: 0.16s; }
[data-rise="3"] { animation-delay: 0.27s; }
[data-rise="4"] { animation-delay: 0.38s; }
[data-rise="5"] { animation-delay: 0.49s; }
@keyframes riseIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

/* ---------------- Stats ---------------- */
.stats {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  list-style: none;
  margin: 64px 0 0;
  padding: 22px 0 0;
  border-top: 1px solid var(--border);
}
.stats li {
  flex: 1 1 140px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.stats b {
  font-family: var(--font-mono);
  font-size: clamp(1.4rem, 3vw, 1.9rem);
  font-weight: 600;
  color: var(--fg);
  font-variant-numeric: tabular-nums;
}
.stats span { color: var(--fg-subtle); font-size: 13px; }

/* ---------------- Sections ---------------- */
.section { padding: clamp(64px, 10vw, 120px) 0; }
.section-tint { background: var(--bg-tint); border-block: 1px solid var(--border); }
.section-head { max-width: 40em; margin-bottom: 48px; }
.kicker {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 14px;
}
.section-head h2 { font-size: clamp(1.8rem, 4vw, 2.7rem); }
.section-sub { margin-top: 16px; font-size: 1.05rem; color: var(--fg-muted); }

/* ---------------- Bento features ---------------- */
.bento {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
.tile {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  transition: border-color 0.2s var(--ease), transform 0.2s var(--ease), background 0.2s var(--ease);
}
.tile:hover { border-color: var(--border-strong); transform: translateY(-3px); background: #161b25; }
.tile-wide { grid-column: span 2; }
.tile-ico {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: var(--accent-soft);
  margin-bottom: 18px;
}
.tile-ico svg { width: 23px; height: 23px; fill: none; stroke: var(--accent); stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.tile h3 { font-size: 1.18rem; margin-bottom: 9px; }
.tile p { color: var(--fg-muted); font-size: 0.97rem; }
.tile-wide p { max-width: 46em; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; margin: 18px 0 0; padding: 0; }
.chips li {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--accent);
  background: var(--accent-soft);
  border: 1px solid rgba(90, 200, 250, 0.2);
  border-radius: 999px;
  padding: 4px 12px;
}
kbd {
  font-family: var(--font-mono);
  font-size: 0.82em;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid var(--border-strong);
  border-bottom-width: 2px;
  border-radius: 6px;
  padding: 1px 6px;
  color: var(--fg);
}

/* ---------------- Under the hood ---------------- */
.hood { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
.hood-copy, .hood-card { min-width: 0; }
.hood-copy h2 { font-size: clamp(1.7rem, 3.6vw, 2.4rem); margin-bottom: 18px; }
.hood-copy p { color: var(--fg-muted); font-size: 1.05rem; }
.hood-copy a { color: var(--accent); }
.hood-copy a:hover { text-decoration: underline; }
.hood-tech { display: flex; flex-wrap: wrap; gap: 8px; margin: 24px 0; }
.hood-tech span {
  font-family: var(--font-mono);
  font-size: 12.5px;
  color: var(--fg-muted);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 6px 12px;
}
.link-arrow { display: inline-flex; align-items: center; gap: 7px; font-weight: 600; color: var(--accent); }
.link-arrow span { transition: transform 0.18s var(--ease); }
.link-arrow:hover span { transform: translateX(4px); }
.link-arrow.inline { font-size: 0.92rem; margin-left: 6px; }

.hood-card { position: relative; }
.code-block {
  margin: 0;
  background: #0a0c10;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  padding: 24px 22px;
  font-size: 13.5px;
  line-height: 1.85;
  color: #d6e4f0;
  overflow-x: auto;
  box-shadow: var(--shadow);
}
.code-block .dim { color: var(--fg-subtle); }
.copy-btn {
  position: absolute;
  top: 14px;
  right: 14px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  color: var(--fg-muted);
  font-family: var(--font-sans);
  font-size: 12px;
  padding: 5px 9px;
  cursor: pointer;
  transition: color 0.15s, background 0.15s;
}
.copy-btn svg { fill: none; stroke: currentColor; stroke-width: 1.5; }
.copy-btn:hover { color: var(--fg); background: rgba(255, 255, 255, 0.1); }
.copy-btn.copied { color: var(--accent-3); border-color: rgba(74, 222, 128, 0.4); }

/* ---------------- Shortcuts ---------------- */
.sc-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.sc {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 14px 16px;
  transition: border-color 0.18s var(--ease);
}
.sc:hover { border-color: var(--border-strong); }
.sc .keys { display: inline-flex; gap: 4px; flex: 0 0 auto; align-items: center; color: var(--fg-subtle); }
.sc span:last-child { color: var(--fg-muted); font-size: 0.92rem; }

/* ---------------- Download ---------------- */
.dl-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; max-width: 980px; margin: 0 auto; }
.dl-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 30px;
  text-align: center;
  transition: border-color 0.2s var(--ease), transform 0.2s var(--ease);
}
.dl-card.detected { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent), 0 20px 50px -24px rgba(90, 200, 250, 0.5); }
.dl-card:hover { transform: translateY(-3px); }
.dl-head { display: flex; align-items: center; gap: 14px; justify-content: center; margin-bottom: 22px; }
.dl-os { width: 30px; height: 30px; color: var(--fg); }
.dl-head h3 { font-size: 1.3rem; }
.dl-meta { color: var(--fg-subtle); font-size: 12.5px; margin-top: 2px; }
.dl-btn { width: 100%; }
.dl-note { margin-top: 14px; font-size: 12.5px; color: var(--fg-subtle); }
.dl-note a { color: var(--accent); }
.dl-note a:hover { text-decoration: underline; }
.dl-foot { text-align: center; margin-top: 36px; color: var(--fg-muted); font-size: 0.92rem; max-width: 46em; margin-inline: auto; }
.dl-foot a { color: var(--accent); }
.detected-badge {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 10px;
}

/* ---------------- Support / Buy me a coffee ---------------- */
.support .section-head { max-width: 34em; margin: 0 auto 36px; text-align: center; }
.coffee-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  margin: 0 auto 18px;
  border-radius: 16px;
  color: var(--accent);
  background: var(--accent-soft);
  border: 1px solid var(--border);
}
.pay-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; max-width: 720px; margin: 0 auto; }
.pay-email {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 12px;
  max-width: 720px;
  margin: 26px auto 0;
}
.pay-email-label { color: var(--fg-subtle); font-size: 13px; }
.pay-email code {
  font-family: var(--font-mono);
  font-size: 14px;
  color: var(--fg);
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 9px 14px;
}
.support-thanks { text-align: center; margin-top: 32px; color: var(--fg-muted); font-size: 0.95rem; }
.support-thanks .link-arrow { margin-left: 8px; }
.coffee-link { color: var(--accent); white-space: nowrap; }
.coffee-link:hover { text-decoration: underline; }
@media (max-width: 600px) {
  .pay-grid { grid-template-columns: 1fr; }
}

/* ---------------- Footer ---------------- */
.footer { border-top: 1px solid var(--border); padding: 64px 0 40px; background: var(--bg-subtle); }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 40px; }
.footer-brand p { color: var(--fg-subtle); font-size: 0.92rem; margin-top: 14px; max-width: 24em; }
.footer-col h4 { font-size: 13px; text-transform: uppercase; letter-spacing: 0.1em; color: var(--fg-subtle); margin-bottom: 14px; }
.footer-col a { display: block; color: var(--fg-muted); font-size: 0.95rem; padding: 5px 0; transition: color 0.15s; }
.footer-col a:hover { color: var(--fg); }
.footer .stats { margin: 0 0 44px; padding: 0 0 32px; border-top: none; border-bottom: 1px solid var(--border); }
.footer-base {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 48px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
  font-size: 13px;
  color: var(--fg-subtle);
  font-family: var(--font-mono);
}
.footer-base a { color: var(--fg-muted); transition: color 0.15s; }
.footer-base a:hover { color: var(--accent); }

/* ---------------- Scroll reveal ---------------- */
.section-head, .tile, .sc, .dl-card, .hood-copy, .hood-card { will-change: opacity, transform; }
.reveal-on-scroll { opacity: 0; transform: translateY(20px); transition: opacity 0.6s var(--ease), transform 0.6s var(--ease); }
.reveal-on-scroll.in { opacity: 1; transform: none; }

/* ---------------- Responsive ---------------- */
@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; gap: 40px; }
  .hero-term { order: 2; max-width: 540px; }
  .bento { grid-template-columns: repeat(2, 1fr); }
  .tile-wide { grid-column: span 2; }
  .hood { grid-template-columns: 1fr; gap: 32px; }
  .sc-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 28px; }
}
@media (max-width: 640px) {
  .nav-links { display: none; }
  .nav-actions .gh-star { display: none; }
  .nav-toggle {
    display: inline-flex;
    flex-direction: column;
    gap: 4px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    margin-left: auto;
  }
  .nav-toggle span { width: 20px; height: 2px; background: var(--fg); border-radius: 2px; transition: 0.2s; }
  .nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
  .nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
  .nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }
  .nav-inner { gap: 12px; }
  .hero-title { font-size: clamp(1.9rem, 9vw, 2.5rem); }
  .mobile-menu { display: flex; }
  .mobile-menu[hidden] { display: none; }
  .mobile-menu {
    flex-direction: column;
    padding: 8px 24px 18px;
    border-bottom: 1px solid var(--border);
    background: rgba(11, 13, 17, 0.96);
  }
  .mobile-menu a { padding: 12px 0; color: var(--fg-muted); border-top: 1px solid var(--border); }
  .bento { grid-template-columns: 1fr; }
  .tile-wide { grid-column: span 1; }
  .sc-grid { grid-template-columns: 1fr; }
  .dl-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .term-body { grid-template-columns: 1fr; }
  .term-editor { display: none; }
  .term-explorer { display: none; }
  .term-status .opt { display: none; }
}

/* ---------------- Reduced motion ---------------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; }
  .reveal-on-scroll { opacity: 1 !important; transform: none !important; }
  [data-rise] { opacity: 1 !important; transform: none !important; }
  .term-run .fade { opacity: 1 !important; transform: none !important; }
  .caret, .blink, .edit-caret { animation: none; }
}
