/* blergai.com — marketing page styles.
   Palette, status chips, and the type-voice tokens come from brand/tokens.css
   (kept byte-identical to blerg/brand/tokens.css). Only the two web faces are
   overridden here, in front of the brand's system fallbacks. */

:root {
  --display: "Barlow Condensed", "Avenir Next Condensed", "Bahnschrift", "Arial Narrow", sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, "SF Mono", "Cascadia Mono", monospace;
  --measure: 62ch;
  --wrap: 1120px;
  --gutter: clamp(18px, 4vw, 40px);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
html, body { margin: 0; }
body {
  background: var(--basalt);
  color: var(--fog);
  font-family: var(--body);
  font-size: var(--text-base);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  min-height: 100dvh;
}

a { color: var(--blaze); text-decoration-thickness: 1px; text-underline-offset: 0.15em; }
a:hover { color: var(--chalk); }
:focus-visible { outline: 2px solid var(--blaze); outline-offset: 3px; border-radius: 2px; }
code {
  font-family: var(--mono);
  font-size: 0.92em;
  color: var(--chalk);
  background: var(--scree-2);
  padding: 0.05em 0.35em;
  border-radius: 3px;
}
h1, h2, h3 {
  font-family: var(--display);
  color: var(--chalk);
  font-weight: 600;
  line-height: 1.02;
  letter-spacing: -0.005em;
  margin: 0;
  text-wrap: balance;
}
h1 { font-size: clamp(42px, 6.4vw, 78px); font-weight: 700; }
h2 { font-size: clamp(32px, 4.6vw, 52px); }
h3 { font-size: clamp(22px, 2.4vw, 28px); }
p { margin: 0; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding-inline: var(--gutter); }

.skip {
  position: absolute; left: 8px; top: -60px;
  background: var(--blaze); color: var(--basalt);
  padding: 8px 12px; font-family: var(--display); text-decoration: none; z-index: 10;
}
.skip:focus { top: 8px; }

/* ── wordmark ─────────────────────────────────────────────────────────── */
.wordmark {
  display: inline-flex; align-items: baseline; gap: 2px;
  font-family: var(--mono); font-weight: 500; font-size: 26px;
  color: var(--chalk); text-decoration: none; letter-spacing: 0.01em; line-height: 1;
}
.wordmark:hover { color: var(--chalk); }
.wordmark .cursor {
  display: inline-block; width: 0.42em; height: 0.66em;
  background: var(--blaze); transform: translateY(0.04em);
}
.wordmark.small { font-size: 18px; }
@media (prefers-reduced-motion: no-preference) {
  .wordmark .cursor { animation: blink 1.1s steps(1) infinite; }
}
@keyframes blink { 50% { opacity: 0; } }

/* ── top bar ──────────────────────────────────────────────────────────── */
.top { border-bottom: 1px solid var(--stone); }
.top-row { display: flex; align-items: center; justify-content: space-between; height: 64px; gap: 16px; }
.top-nav { display: flex; align-items: center; gap: clamp(14px, 3vw, 28px); }
.top-nav a {
  font-family: var(--display); font-size: 17px; font-weight: 500;
  color: var(--fog); text-decoration: none; letter-spacing: 0.01em;
}
.top-nav a:hover { color: var(--chalk); }
.top-nav .gh { display: inline-flex; align-items: center; gap: 7px; color: var(--chalk); }
@media (max-width: 560px) { .top-nav a:not(.gh) { display: none; } }

/* ── hero ─────────────────────────────────────────────────────────────── */
.hero { padding-block: clamp(48px, 8vw, 104px) clamp(48px, 7vw, 88px); border-bottom: 1px solid var(--stone); }
.hero-grid {
  display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  gap: clamp(28px, 5vw, 64px); align-items: start;
}
.hero-copy { max-width: 40rem; }
.lede { font-size: clamp(16px, 1.6vw, 19px); max-width: var(--measure); margin-top: 22px; color: var(--fog); }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.fineprint { margin-top: 16px; font-size: var(--text-sm); color: var(--fog-dim); }

.btn {
  display: inline-flex; align-items: center;
  font-family: var(--display); font-size: 18px; font-weight: 600; letter-spacing: 0.01em;
  padding: 11px 18px; border: 1px solid var(--stone); border-radius: 4px;
  color: var(--chalk); text-decoration: none; background: var(--scree);
}
.btn:hover { border-color: var(--fog-dim); color: var(--chalk); }
.btn.primary { background: var(--blaze); border-color: var(--blaze); color: #0d1117; }
.btn.primary:hover { filter: brightness(1.08); color: #0d1117; }

/* the session list — the page's one moving part */
.sessions {
  margin: 0; border: 1px solid var(--stone); border-radius: 6px;
  background: var(--scree); overflow: hidden; align-self: start;
}
.sessions-head {
  display: flex; align-items: baseline; justify-content: space-between; gap: 12px;
  padding: 10px 14px; border-bottom: 1px solid var(--stone); background: var(--scree-2);
}
.sessions-title { font-family: var(--mono); font-size: var(--text-sm); color: var(--chalk); font-weight: 500; }
.sessions-count { font-family: var(--mono); font-size: var(--text-xs); color: var(--fog-dim); }
.session-rows { list-style: none; margin: 0; padding: 6px 0; font-family: var(--mono); font-size: 13px; }
.row {
  display: grid; grid-template-columns: 14px 1fr auto; grid-template-areas: "st name state" ". meta state";
  column-gap: 12px; row-gap: 2px; align-items: center;
  padding: 10px 14px; border-left: 3px solid transparent;
  transition: background .3s ease, border-color .3s ease;
}
.row + .row { border-top: 1px solid var(--scree-2); }
.row .st { grid-area: st; width: 8px; height: 8px; border-radius: 50%; background: var(--fog-dim); justify-self: center; }
.row[data-status="running"] .st { background: var(--lichen); }
.row[data-status="waiting"] .st { background: var(--amber); }
.row[data-status="idle"] .st { background: var(--fog-dim); }
.row .name { grid-area: name; color: var(--chalk); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.row .meta { grid-area: meta; color: var(--fog-dim); font-size: var(--text-xs); white-space: nowrap; }
.row .meta .where::before { content: "on "; }
.row .state { grid-area: state; color: var(--fog); font-size: var(--text-xs); text-align: right; white-space: nowrap; }
.row .state small { display: block; font-size: 11px; color: var(--fog-dim); }
.row[data-status="waiting"] { border-left-color: var(--amber); background: color-mix(in srgb, var(--amber) 8%, var(--scree)); }
.row[data-status="waiting"] .state { color: var(--amber); }
.row.unread .name::after {
  content: ""; display: inline-block; width: 6px; height: 6px; border-radius: 50%;
  background: var(--blaze); margin-left: 8px; vertical-align: middle;
}
@media (prefers-reduced-motion: no-preference) {
  .row[data-status="running"] .st { animation: pulse 1.8s ease-in-out infinite; }
}
@keyframes pulse { 50% { opacity: 0.35; } }
.sessions-foot { padding: 10px 14px; border-top: 1px solid var(--stone); font-size: var(--text-xs); color: var(--fog-dim); }

@media (max-width: 860px) {
  .hero-grid { grid-template-columns: 1fr; }
  .sessions { max-width: 640px; }
}

/* ── supported today: a quiet logo strip, monochrome so no brand shouts ── */
.works { padding-block: clamp(36px, 5vw, 56px); }
.works-h { font-family: var(--display); font-size: 22px; font-weight: 600; color: var(--fog); }
.works-grid { display: grid; grid-template-columns: 3fr 4fr 2fr; gap: clamp(20px, 3vw, 48px); margin-top: 20px; }
.works-label { font-size: var(--text-sm); color: var(--fog-dim); margin-bottom: 12px; }
.logos { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 14px 28px; }
.logos li { display: inline-flex; align-items: center; gap: 10px; color: var(--chalk); }
.lg { width: 26px; height: 26px; fill: currentColor; color: var(--fog); flex: 0 0 auto; }
.lg-name { font-family: var(--display); font-size: 19px; font-weight: 600; line-height: 1.05; display: block; }
.lg-note { display: block; font-size: var(--text-xs); color: var(--fog-dim); margin-top: 2px; }
.works-note { margin-top: 24px; font-size: var(--text-sm); color: var(--fog-dim); max-width: var(--measure); }
@media (max-width: 860px) { .works-grid { grid-template-columns: 1fr; gap: 22px; } }

/* ── sections ─────────────────────────────────────────────────────────── */
section { padding-block: clamp(56px, 8vw, 104px); }
section + section { border-top: 1px solid var(--stone); }
.section-lede { margin-top: 16px; max-width: var(--measure); font-size: clamp(16px, 1.4vw, 18px); }

/* the path: one terminal, many, tmux, then blerg */
.path { padding-block: clamp(48px, 7vw, 88px); }
.steps { list-style: none; margin: 36px 0 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(16px, 2.5vw, 32px); }
.step { position: relative; padding: 18px 16px 20px; border: 1px solid transparent; border-radius: 6px; }
.step:not(:last-child)::after {
  /* the "then" arrow between steps */
  content: ""; position: absolute; right: calc(-1 * clamp(16px, 2.5vw, 32px) / 2 - 5px); top: 58px;
  width: 8px; height: 8px; border-top: 1.5px solid var(--fog-dim); border-right: 1.5px solid var(--fog-dim); transform: rotate(45deg);
}
.step.is-blerg { border-color: var(--blaze); background: color-mix(in srgb, var(--blaze) 6%, var(--scree)); }
.step-art { display: block; width: 100%; height: auto; max-width: 200px; margin-bottom: 14px; }
.step-art .ln { fill: none; stroke: var(--fog-dim); stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.step-art .soft { fill: var(--scree); }
.step.is-blerg .step-art .soft { fill: var(--scree-2); }
.step-art .bar { fill: var(--stone); }
.step-art .dot { fill: var(--blaze); }
.step-art .amber { fill: var(--amber); }
.step-art .lichen { fill: var(--lichen); }
.step-art .mono { font-family: var(--mono); font-size: 9px; fill: var(--chalk); }
.step h3 { font-size: 22px; }
.step p { margin-top: 6px; font-size: var(--text-sm); color: var(--fog); }
@media (max-width: 960px) {
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .step:not(:last-child)::after { display: none; }
}
@media (max-width: 520px) { .steps { grid-template-columns: 1fr; } }

/* two ways to work, then the three parts as a compact ruled row */
.ways-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(24px, 4vw, 56px); margin-top: 40px; }
.way-art { display: block; width: 100%; height: auto; max-width: 420px; margin-bottom: 18px; }
.way-art .ln { fill: none; stroke: var(--fog-dim); stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.way-art .soft { fill: var(--scree); }
.way-art .bar { fill: var(--stone); stroke: var(--stone); }
.way-art .dot { fill: var(--blaze); }
.way-art .card { fill: var(--scree-2); stroke: var(--stone); stroke-width: 1; }
.way-art .card.hot { stroke: var(--blaze); }
.way-art .mono { font-family: var(--mono); font-size: 11px; fill: var(--chalk); }
.way-art .dim { fill: var(--fog-dim); }
.way h3 { font-size: 26px; }
.way-tag { font-family: var(--display); font-size: 19px; color: var(--fog); margin: 6px 0 12px; font-weight: 500; }
.way ul { margin: 0; padding-left: 1.1em; color: var(--fog); }
.way li + li { margin-top: 6px; }

.parts-grid {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 48px; border-top: 1px solid var(--stone);
}
.part { display: grid; grid-template-columns: 48px 1fr; column-gap: 16px; align-items: start; padding: 28px clamp(0px, 2vw, 28px) 8px 0; }
.part + .part { border-left: 1px solid var(--stone); padding-left: clamp(18px, 2.5vw, 32px); }
.part-art { width: 48px; height: 48px; }
.part-art .ln { fill: none; stroke: var(--fog-dim); stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.part-art .soft { fill: var(--scree); }
.part-art .bar { fill: var(--stone); }
.part-art .dot { fill: var(--blaze); }
.part h3 { font-size: 24px; }
.part p { margin-top: 6px; font-size: var(--text-sm); }
@media (max-width: 860px) {
  .ways-grid { grid-template-columns: 1fr; }
  .parts-grid { grid-template-columns: 1fr; }
  .part + .part { border-left: 0; border-top: 1px solid var(--stone); padding-left: 0; }
}

/* tiers: four illustrations on one scale line */
.tiers {
  list-style: none; margin: 44px 0 0; padding: 0; position: relative;
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(16px, 2.5vw, 36px);
}
.tiers::before {
  /* the scale line: one runner, board, and core across every tier */
  content: ""; position: absolute; left: 0; right: 0; top: 62px; height: 1px;
  background: linear-gradient(90deg, var(--stone), var(--blaze) 50%, var(--stone));
  opacity: .7;
}
.tier { position: relative; }
.tier-art { display: block; width: 100%; max-width: 220px; height: auto; margin: 0 0 14px; }
.tier-art .ln { fill: none; stroke: var(--fog-dim); stroke-width: 1.5; }
.tier-art .fill-soft { fill: var(--scree); }
.tier-art .bar { fill: var(--stone); stroke: var(--stone); }
.tier-art .dot { fill: var(--blaze); }
.tier-scale { font-family: var(--mono); font-size: var(--text-xs); color: var(--fog-dim); }
.tier h3 { font-size: 24px; margin-top: 4px; }
.tier p:not(.tier-scale) { margin-top: 8px; }
.os { list-style: none; margin: 12px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px 16px; }
.os li { display: inline-flex; align-items: center; gap: 6px; font-family: var(--display); font-size: 16px; color: var(--fog); }
.os svg { width: 15px; height: 15px; fill: currentColor; color: var(--fog-dim); }
@media (max-width: 960px) {
  .tiers { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px 28px; }
  .tiers::before { display: none; }
}
@media (max-width: 480px) { .tiers { grid-template-columns: 1fr; } }

/* why: six tiles, a mark each, copy kept to two lines */
.why-list {
  margin: 40px 0 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 36px clamp(20px, 3vw, 44px);
}
.why-tile { display: grid; grid-template-columns: 48px 1fr; grid-template-rows: auto auto; column-gap: 16px; align-items: start; }
.why-art { grid-row: 1 / span 2; width: 48px; height: 48px; }
.why-art .ln { fill: none; stroke: var(--fog-dim); stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.why-art .soft { fill: var(--scree); }
.why-art .bar { fill: var(--stone); stroke: var(--stone); }
.why-art .dot { fill: var(--blaze); }
.why-list dt { font-family: var(--display); font-size: 22px; font-weight: 600; color: var(--chalk); line-height: 1.1; }
.why-list dd { margin: 6px 0 0; color: var(--fog); font-size: var(--text-sm); line-height: 1.5; }
@media (max-width: 960px) { .why-list { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .why-list { grid-template-columns: 1fr; gap: 28px; } }

/* install */
.code {
  margin: 28px 0 0; padding: 20px 22px; overflow-x: auto;
  background: var(--scree); border: 1px solid var(--stone); border-radius: 6px;
  font-family: var(--mono); font-size: 14px; line-height: 1.6; color: var(--chalk);
  max-width: 720px;
}
.code .c { color: var(--fog-dim); }
.install-note { margin-top: 20px; max-width: var(--measure); }
.install .cta-row { margin-top: 24px; }

/* footer */
.foot { border-top: 1px solid var(--stone); padding-block: 28px; }
.foot-row { display: flex; flex-wrap: wrap; align-items: center; gap: 16px 24px; }
.foot-text { color: var(--fog-dim); font-size: var(--text-sm); flex: 1; }
.tt {
  font-family: var(--display); font-size: 15px; color: var(--fog);
  background: transparent; border: 1px solid var(--stone); border-radius: 4px; padding: 6px 12px; cursor: pointer;
}
.tt:hover { color: var(--chalk); border-color: var(--fog-dim); }
