/* ============================================================================
   Oven — landing page
   Hand-written CSS. No framework, no build step, no runtime.

   The palette is deliberately monochrome. Orange is an accent, not a theme: a
   status dot, a link arrow, one keyword class in the code, the focus ring.
   A page washed in a brand colour reads as decoration; a page that is mostly
   ink reads as a tool.
   ========================================================================= */

:root {
  --bg:        #08080a;
  --bg-2:      #0b0b0e;
  --surface:   #0e0e12;
  --surface-2: #131318;

  --line:      rgba(255, 255, 255, 0.09);
  --line-2:    rgba(255, 255, 255, 0.055);

  --text:      #ededf0;
  --text-2:    #a3a3ad;
  --text-3:    #6c6c78;

  /* Ember. Used sparingly and never as a wash. */
  --ember:     #f2650a;
  --ember-lit: #ff8b3d;
  --ember-dim: rgba(242, 101, 10, 0.10);

  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;

  --wrap: 1120px;
  --r:    10px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: 88px;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
  font-feature-settings: 'cv02' 1, 'cv03' 1, 'cv04' 1;
}

img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
code, pre { font-family: var(--mono); }
::selection { background: rgba(242, 101, 10, 0.28); }

:focus-visible {
  outline: 2px solid var(--ember-lit);
  outline-offset: 3px;
  border-radius: 4px;
}

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

.skip {
  position: absolute; left: -9999px; top: 12px; z-index: 200;
  background: var(--ember); color: #fff; padding: 10px 18px; border-radius: 8px;
}
.skip:focus { left: 24px; }

/* --- nav ---------------------------------------------------------------- */

.nav {
  position: sticky; top: 0; z-index: 100;
  height: 56px;
  border-bottom: 1px solid transparent;
  background: rgba(8, 8, 10, 0.72);
  backdrop-filter: saturate(180%) blur(14px);
  transition: border-color 0.2s linear;
}
.nav.scrolled { border-bottom-color: var(--line); }

.nav-inner { display: flex; align-items: center; gap: 28px; height: 100%; }

.brand { display: flex; align-items: center; gap: 9px; font-weight: 600; font-size: 15px; letter-spacing: -0.01em; }
.brand svg { width: 19px; height: 19px; color: var(--ember); }

.nav-links { display: flex; gap: 22px; margin-left: 6px; }
.nav-links a { font-size: 14px; color: var(--text-2); transition: color 0.15s linear; }
.nav-links a:hover { color: var(--text); }

.nav-right { display: flex; align-items: center; gap: 14px; margin-left: auto; }
.nav-right .ghost { font-size: 14px; color: var(--text-2); transition: color 0.15s linear; }
.nav-right .ghost:hover { color: var(--text); }

/* --- buttons ------------------------------------------------------------ */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  height: 38px; padding: 0 16px;
  border-radius: 7px; border: 1px solid transparent;
  font-size: 14px; font-weight: 500; letter-spacing: -0.005em;
  cursor: pointer; white-space: nowrap;
  transition: background 0.15s linear, border-color 0.15s linear, color 0.15s linear;
}
.btn svg { width: 14px; height: 14px; }

/* White primary, like the best developer sites: the accent colour is not spent on a button
   the reader has already decided to click. */
.btn-primary { background: #fafafa; color: #0a0a0c; }
.btn-primary:hover { background: #fff; }

.btn-secondary { background: transparent; border-color: var(--line); color: var(--text); }
.btn-secondary:hover { border-color: rgba(255, 255, 255, 0.22); background: rgba(255, 255, 255, 0.03); }

.btn-sm { height: 32px; padding: 0 12px; font-size: 13.5px; }

/* --- hero --------------------------------------------------------------- */

.hero { position: relative; padding: 76px 0 0; overflow: hidden; }

/*
 * A ruled grid rather than a glow. Two hairline gradients, faded out at the edges with a mask
 * so it reads as graph paper the content sits on — not as a background image competing with it.
 */
.hero-grid {
  position: absolute; inset: 0; pointer-events: none;
  background-image:
    linear-gradient(to right, var(--line-2) 1px, transparent 1px),
    linear-gradient(to bottom, var(--line-2) 1px, transparent 1px);
  background-size: 64px 64px;
  opacity: 0.7;
  mask-image: radial-gradient(ellipse 72% 58% at 50% 16%, #000 20%, transparent 72%);
  -webkit-mask-image: radial-gradient(ellipse 72% 58% at 50% 16%, #000 20%, transparent 72%);
}

.hero-inner { position: relative; display: flex; flex-direction: column; align-items: center; text-align: center; }

.pill {
  display: inline-flex; align-items: center; gap: 8px;
  height: 28px; padding: 0 12px 0 10px;
  border: 1px solid var(--line); border-radius: 999px;
  background: rgba(255, 255, 255, 0.02);
  font-size: 13px; color: var(--text-2);
  transition: border-color 0.15s linear, color 0.15s linear;
}
.pill:hover { border-color: rgba(255, 255, 255, 0.2); color: var(--text); }
.pill .dot { width: 5px; height: 5px; border-radius: 50%; background: var(--ember); }
.pill svg { width: 12px; height: 12px; opacity: 0.5; }

h1 {
  margin-top: 24px;
  font-size: clamp(36px, 5.2vw, 60px);
  line-height: 1.05;
  letter-spacing: -0.035em;
  font-weight: 600;
  max-width: 20ch;
  /* Stops "batteries-included" being hyphen-broken across lines, which reads as a typo. */
  text-wrap: balance;
}

.lede {
  margin-top: 22px;
  max-width: 56ch;
  font-size: clamp(16px, 1.6vw, 18.5px);
  line-height: 1.6;
  color: var(--text-2);
}
.lede strong { color: var(--text); font-weight: 500; }

.hero-cta { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin-top: 32px; }

/* The install line, as small mono text rather than a button. It is a thing to copy, not a
   destination — presenting it as a third CTA would compete with the two that matter. */
.install {
  display: inline-flex; align-items: center; gap: 10px;
  margin-top: 24px; padding: 7px 12px;
  border: 1px solid var(--line-2); border-radius: 7px;
  background: rgba(255, 255, 255, 0.015);
  font-family: var(--mono); font-size: 13px; color: var(--text-2);
  cursor: pointer;
  transition: border-color 0.15s linear, color 0.15s linear;
}
.install:hover { border-color: var(--line); color: var(--text); }
.install .prompt { color: var(--text-3); }
.install svg { width: 13px; height: 13px; opacity: 0.55; }
.install .ic-done { display: none; color: var(--ember-lit); opacity: 1; }
.install.done .ic-copy { display: none; }
.install.done .ic-done { display: block; }

.stats { display: flex; gap: 40px; margin-top: 40px; justify-content: center; flex-wrap: wrap; }
.stats div { text-align: center; }
.stats dt { font-size: 21px; font-weight: 600; letter-spacing: -0.02em; }
.stats dd { margin: 2px 0 0; font-size: 13px; color: var(--text-3); }

/* --- hero code showcase -------------------------------------------------- */

.showcase { position: relative; margin-top: 56px; padding-bottom: 92px; }

.tabs { display: flex; gap: 4px; justify-content: center; margin-bottom: 14px; }
.tab {
  height: 30px; padding: 0 13px;
  border: 1px solid transparent; border-radius: 7px;
  background: transparent; color: var(--text-3);
  font-family: var(--mono); font-size: 12.5px; cursor: pointer;
  transition: color 0.15s linear, background 0.15s linear, border-color 0.15s linear;
}
.tab:hover { color: var(--text-2); }
.tab[aria-selected='true'] { color: var(--text); background: var(--surface-2); border-color: var(--line); }

.panel[hidden] { display: none; }

/* --- code --------------------------------------------------------------- */

.code {
  border: 1px solid var(--line); border-radius: 12px;
  background: linear-gradient(180deg, var(--surface) 0%, #0b0b0f 100%);
  overflow: hidden;
}
.code-head {
  display: flex; align-items: center; gap: 9px;
  padding: 10px 14px; border-bottom: 1px solid var(--line-2);
  font-family: var(--mono); font-size: 12px; color: var(--text-3);
}
.code-head .dots { display: flex; gap: 5px; }
.code-head .dots i { width: 8px; height: 8px; border-radius: 50%; background: rgba(255,255,255,0.11); }
.code pre { padding: 18px 20px 20px; overflow-x: auto; }
.code code { font-size: 13px; line-height: 1.72; color: #c6c8d2; white-space: pre; display: block; }

/* Syntax. Muted and few — highlighting that shouts is highlighting that stops helping. */
.c-key { color: #ff9a5a; }
.c-str { color: #86d99b; }
.c-fn  { color: #7cb3f2; }
.c-com { color: #55555f; font-style: italic; }
.c-num { color: #c9a6f0; }
.c-typ { color: #6fd8c8; }

.code-note {
  margin-top: 16px; text-align: center;
  font-size: 14px; color: var(--text-3); max-width: 62ch; margin-inline: auto;
}
.code-note code { color: var(--text-2); font-size: 0.92em; }

/* --- sections ------------------------------------------------------------ */

.section { padding: 96px 0; border-top: 1px solid var(--line-2); }
.section.alt { background: var(--bg-2); }

.section-head { max-width: 62ch; margin-bottom: 44px; }
.section-head.center { margin-inline: auto; text-align: center; }

.eyebrow {
  font-size: 12px; font-weight: 500; letter-spacing: 0.09em; text-transform: uppercase;
  color: var(--ember-lit); margin-bottom: 14px;
}
h2 { font-size: clamp(26px, 3.4vw, 38px); line-height: 1.12; letter-spacing: -0.028em; font-weight: 600; }
.sub { margin-top: 14px; color: var(--text-2); font-size: 16.5px; }
.sub code, .caption code { color: var(--text); font-size: 0.9em; }

.split { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; align-items: start; }

.caption { margin-top: 26px; color: var(--text-3); font-size: 14.5px; max-width: 68ch; }
.caption strong { color: var(--text-2); font-weight: 500; }

.link-arrow { color: var(--ember-lit); font-size: 14px; font-weight: 500; }
.link-arrow:hover { text-decoration: underline; text-underline-offset: 3px; }

/* --- card grids ---------------------------------------------------------- */

.grid { display: grid; gap: 12px; grid-template-columns: repeat(3, 1fr); }
.grid.two { grid-template-columns: repeat(2, 1fr); }

.card {
  padding: 20px; border: 1px solid var(--line); border-radius: var(--r);
  background: var(--surface);
  transition: border-color 0.16s linear, background 0.16s linear;
}
.card:hover { border-color: rgba(255, 255, 255, 0.16); background: var(--surface-2); }
.card h3 { font-size: 15px; font-weight: 600; letter-spacing: -0.012em; margin-bottom: 7px; }
.card p { font-size: 14px; color: var(--text-2); line-height: 1.55; }
.card code { font-size: 0.88em; color: var(--text); background: rgba(255,255,255,0.05); padding: 1px 5px; border-radius: 4px; }
.card .replaces {
  display: block; margin-top: 12px; padding-top: 11px; border-top: 1px solid var(--line-2);
  font-size: 12.5px; color: var(--text-3);
}
.card .replaces b { color: var(--text-2); font-weight: 500; }
.card .link-arrow { display: inline-block; margin-top: 12px; font-size: 13px; }

/* A count under a card title — "5 chapters · one idea each". Sits between the heading and the
   description, so it reads as a label rather than as the first sentence. */
.card-meta {
  font-size: 12.5px; color: var(--text-3); margin-bottom: 9px;
  font-variant-numeric: tabular-nums;
}

/* The status ticks carry the only other ember on the page, and only at 14px. */
.card .tick { color: var(--ember); margin-right: 7px; font-size: 13px; }

/* --- benchmarks ---------------------------------------------------------- */

.bars { display: flex; flex-direction: column; gap: 11px; }
.bar-row { display: grid; grid-template-columns: 132px 1fr 86px; align-items: center; gap: 14px; }
.bar-name { font-size: 14px; color: var(--text-2); }
.bar-name em { font-style: normal; font-family: var(--mono); font-size: 11.5px; color: var(--text-3); margin-left: 5px; }
.bar { height: 26px; background: rgba(255, 255, 255, 0.035); border-radius: 5px; overflow: hidden; }
.bar span {
  display: block; height: 100%; width: 0;
  background: rgba(255, 255, 255, 0.13);
  border-radius: 5px;
  transition: width 1s var(--ease);
}
.bars.run .bar span { width: calc(var(--pct) * 1%); }
.bar-row.is-us .bar span { background: linear-gradient(90deg, var(--ember) 0%, var(--ember-lit) 100%); }
.bar-row.is-us .bar-name { color: var(--text); font-weight: 500; }
.bar-val { font-family: var(--mono); font-size: 12.5px; color: var(--text-2); text-align: right; }
.bars-note { margin-top: 16px; font-size: 13px; color: var(--text-3); }

.note {
  margin-top: 26px; padding: 16px 18px;
  border: 1px solid var(--line); border-left: 2px solid var(--ember); border-radius: var(--r);
  background: var(--surface);
  font-size: 14.5px; color: var(--text-2);
}
.note strong { color: var(--text); font-weight: 600; }
.note a { color: var(--ember-lit); }
.note a:hover { text-decoration: underline; text-underline-offset: 3px; }

/* --- comparison ---------------------------------------------------------- */

.table-scroll { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r); }
.compare { width: 100%; border-collapse: collapse; font-size: 14px; min-width: 660px; }
.compare th, .compare td { padding: 13px 16px; text-align: center; border-bottom: 1px solid var(--line-2); }
.compare thead th { font-size: 12.5px; font-weight: 500; color: var(--text-3); background: rgba(255,255,255,0.015); }
.compare tbody th { text-align: left; font-weight: 400; color: var(--text-2); }
.compare tbody tr:last-child th, .compare tbody tr:last-child td { border-bottom: 0; }
.compare .no { color: var(--text-3); }
.compare .part { color: var(--text-2); font-size: 13px; }
.compare .yes { color: var(--text); }
.compare th.us, .compare td.us { background: rgba(242, 101, 10, 0.045); }
.compare thead th.us { color: var(--ember-lit); font-weight: 600; }
.compare td.us.yes { color: var(--ember-lit); }

/* --- philosophy ----------------------------------------------------------
 * A statement rather than an illustration. The generated render that used to sit here read as
 * decoration, and decoration is exactly what a page like this cannot afford.
 */

.manifesto { max-width: 78ch; margin-inline: auto; text-align: center; }
.manifesto blockquote {
  margin: 0 0 26px;
  font-size: clamp(23px, 3vw, 34px);
  line-height: 1.28;
  letter-spacing: -0.024em;
  font-weight: 500;
}
.manifesto blockquote em { font-style: normal; color: var(--ember-lit); }
.manifesto > p { max-width: 62ch; margin: 0 auto 22px; color: var(--text-2); font-size: 16.5px; }
.manifesto code { color: var(--text); font-size: 0.9em; }

/* --- cta ----------------------------------------------------------------- */

.cta { padding: 104px 0; border-top: 1px solid var(--line-2); text-align: center; }
.cta h2 { margin-bottom: 14px; }
.cta p { max-width: 54ch; margin: 0 auto 30px; color: var(--text-2); }

/* --- footer -------------------------------------------------------------- */

.footer { border-top: 1px solid var(--line-2); padding: 52px 0 40px; }
.footer-inner { display: grid; grid-template-columns: 1.6fr repeat(3, 1fr); gap: 32px; }
.footer .brand { margin-bottom: 12px; }
.foot-note { font-size: 13.5px; color: var(--text-3); line-height: 1.6; }
.footer h4 { font-size: 12px; font-weight: 500; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-3); margin-bottom: 12px; }
.footer nav a { display: block; font-size: 14px; color: var(--text-2); padding: 4px 0; transition: color 0.15s linear; }
.footer nav a:hover { color: var(--text); }

/* --- reveal --------------------------------------------------------------
 * threshold 0 with a negative bottom margin, rather than a ratio: a section taller than the
 * viewport can never reach a ratio of 0.08, and would stay invisible forever.
 */
.reveal { opacity: 0; transform: translateY(14px); transition: opacity 0.55s var(--ease), transform 0.55s var(--ease); }
.reveal.in { opacity: 1; transform: none; }

/* --- responsive ----------------------------------------------------------- */

@media (max-width: 900px) {
  .split { grid-template-columns: 1fr; }
  .grid { grid-template-columns: repeat(2, 1fr); }
  .footer-inner { grid-template-columns: 1fr 1fr; }
  /* Docs survives to the narrowest width — a nav that drops every link is a dead end, and a
     hamburger for four links is a menu to open in order to find a menu. */
  .nav-links { gap: 16px; }
  .nav-links a:nth-child(n + 3) { display: none; }
}

@media (max-width: 620px) {
  .section { padding: 68px 0; }
  .nav-inner { gap: 14px; }
  .nav-links a:nth-child(n + 2) { display: none; }
  .nav-right .ghost { display: none; }
  .hero { padding-top: 64px; }
  .grid, .grid.two { grid-template-columns: 1fr; }
  .stats { gap: 26px; }
  .bar-row { grid-template-columns: 96px 1fr 68px; gap: 10px; }
  .footer-inner { grid-template-columns: 1fr; gap: 26px; }
  .showcase { padding-bottom: 64px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .bar span { transition: none; }
  * { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}
