/* Tokens lifted from Simple Recorder (renderer/app.css and overlay.css) so the
   site and the app read as one product. */
:root {
  --canvas: oklch(0.97 0.006 250);
  --surface: oklch(0.995 0.002 250);
  --ink: oklch(0.28 0.02 255);
  --ink-strong: oklch(0.2 0.02 255);
  --muted: oklch(0.5 0.015 255);
  --line: oklch(0.9 0.01 250);
  --line-strong: oklch(0.82 0.012 250);
  --well: oklch(0.94 0.008 250);
  --accent: oklch(0.55 0.18 255);
  --accent-strong: oklch(0.48 0.17 255);
  --accent-ink: oklch(0.99 0 0);
  --accent-soft: oklch(0.55 0.18 255 / 0.1);
  --record: oklch(0.62 0.21 25);
  --stage: oklch(0.16 0.012 255);
  --on-stage: oklch(0.96 0.005 250);
  --stage-muted: oklch(0.72 0.02 255);
  --stage-line: oklch(0.3 0.02 255);
  --stage-well: oklch(0.22 0.015 255);
  --radius: 8px;
  --radius-panel: 12px;
  --control-h: 36px;
  --shadow-pop: 0 12px 32px oklch(0.2 0.02 255 / 0.12), 0 2px 6px oklch(0.2 0.02 255 / 0.06);
  --shadow-lift: 0 1px 2px oklch(0.2 0.02 255 / 0.1);
  --page: 1120px;
  --font: system-ui, "Segoe UI", sans-serif;
  --mono: ui-monospace, "Cascadia Mono", Consolas, monospace;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 0;
}

body {
  margin: 0;
  font: 16px/1.55 var(--font);
  background: var(--canvas);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

a {
  color: var(--accent-strong);
}

h1,
h2,
h3 {
  color: var(--ink-strong);
  line-height: 1.2;
  margin: 0;
  text-wrap: balance;
}

h1 {
  font-size: clamp(2rem, 4.2vw, 2.85rem);
  letter-spacing: -0.02em;
}

h2 {
  font-size: clamp(1.5rem, 2.8vw, 1.9rem);
  letter-spacing: -0.01em;
}

h3 {
  font-size: 1.05rem;
}

p {
  margin: 0;
}

code,
kbd {
  font-family: var(--mono);
  font-size: 0.88em;
}

kbd {
  padding: 1px 6px;
  border: 1px solid var(--line-strong);
  border-bottom-width: 2px;
  border-radius: 5px;
  background: var(--surface);
  white-space: nowrap;
}

[hidden] {
  display: none !important;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.wrap {
  width: min(var(--page), 100% - 48px);
  margin-inline: auto;
}

.skip {
  position: absolute;
  left: -999px;
}
.skip:focus {
  left: 12px;
  top: 12px;
  z-index: 20;
  background: var(--surface);
  padding: 8px 12px;
  border-radius: var(--radius);
}

/* Header */

.site-head {
  position: sticky;
  top: 0;
  z-index: 10;
  background: var(--surface);
  border-bottom: 1px solid var(--line);
}

.site-head .wrap {
  display: flex;
  align-items: center;
  gap: 24px;
  min-height: 60px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink-strong);
  font-weight: 700;
  font-size: 1.05rem;
  text-decoration: none;
  letter-spacing: -0.01em;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 7px;
  background: var(--ink-strong);
  color: var(--surface);
  font-size: 0.95rem;
  font-weight: 800;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
}

.site-nav a {
  padding: 6px 10px;
  border-radius: var(--radius);
  color: var(--muted);
  text-decoration: none;
  font-size: 0.94rem;
  font-weight: 500;
}

.site-nav a:hover {
  color: var(--ink-strong);
  background: var(--well);
}

.site-nav a[aria-current="page"] {
  color: var(--ink-strong);
}

.site-nav .nav-gh {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

/* Buttons */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 18px;
  border-radius: var(--radius);
  border: 1px solid var(--line-strong);
  background: var(--surface);
  color: var(--ink-strong);
  font: 600 0.96rem/1 var(--font);
  white-space: nowrap;
  text-decoration: none;
  cursor: pointer;
  box-shadow: var(--shadow-lift);
  transition: background 0.12s, border-color 0.12s;
}

.btn:hover {
  border-color: var(--muted);
}

.btn-primary {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--accent-ink);
}

.btn-primary:hover {
  background: var(--accent-strong);
  border-color: var(--accent-strong);
}

.btn-quiet {
  background: transparent;
  box-shadow: none;
}

.btn-sm {
  min-height: var(--control-h);
  padding: 0 12px;
  font-size: 0.88rem;
}

.btn svg {
  flex: none;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 16px;
  color: var(--muted);
  font-size: 0.9rem;
}

.meta span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.rec-dot {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--record);
  flex: none;
}

/* Sections */

.section {
  padding: 88px 0;
}

.section-tight {
  padding: 56px 0;
}

.section-head {
  display: grid;
  gap: 10px;
  max-width: 640px;
  margin-bottom: 36px;
}

.section-head p {
  color: var(--muted);
  font-size: 1.05rem;
}

.eyebrow {
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.band {
  background: var(--surface);
  border-block: 1px solid var(--line);
}

/* Hero */

.hero {
  padding: 72px 0 64px;
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
  gap: 56px;
  align-items: center;
}

.hero-copy {
  display: grid;
  gap: 22px;
  justify-items: start;
}

.hero-copy .lead {
  font-size: 1.15rem;
  color: var(--muted);
  max-width: 34em;
}

.shot {
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-panel);
  overflow: hidden;
  background: var(--surface);
  box-shadow: var(--shadow-pop);
}

.shot img {
  width: 100%;
}

figure {
  margin: 0;
}

figcaption {
  margin-top: 10px;
  color: var(--muted);
  font-size: 0.88rem;
}

/* Product cards (home) */

.section-head .os-note {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  justify-self: start;
  padding: 6px 12px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: var(--canvas);
  color: var(--ink);
  font-size: 0.92rem;
  font-weight: 600;
}

.os-note svg {
  color: var(--accent);
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 16px;
}

.product-card {
  display: grid;
  grid-template-rows: auto 1fr auto auto;
  gap: 18px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: var(--radius-panel);
  background: var(--surface);
  color: inherit;
  text-decoration: none;
  box-shadow: var(--shadow-lift);
  transition: border-color 0.12s, box-shadow 0.12s;
}

a.product-card:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow-pop);
}

.card-summary {
  color: var(--muted);
  font-size: 0.94rem;
}

.card-soon {
  padding: 2px 10px;
  border-radius: 999px;
  background: var(--well);
  color: var(--ink-strong);
  font-size: 0.84rem;
  font-weight: 600;
}

.plugin-mark {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2px;
  width: 20px;
  height: 20px;
}

.plugin-mark span {
  border-radius: 3px;
  background: oklch(0.96 0 0);
}

.plugin-mark span:nth-child(2) {
  background: var(--accent);
}

.card-head {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 12px;
  align-items: center;
}

.card-foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}

.app-icon {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--stage);
}

.card-name {
  display: grid;
}

.card-name strong {
  color: var(--ink-strong);
  font-size: 1.08rem;
}

.card-name span {
  color: var(--muted);
  font-size: 0.9rem;
}

.card-version {
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--well);
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 600;
}

.checks {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 14px 0;
  list-style: none;
  border-block: 1px solid var(--line);
}

.checks li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 500;
  color: var(--ink-strong);
}

.checks svg circle {
  fill: var(--accent);
}

.checks svg path {
  fill: none;
  stroke: var(--accent-ink);
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.checks li[data-on="false"] {
  color: var(--muted);
  font-weight: 400;
}

.checks li[data-on="false"] svg circle {
  fill: none;
  stroke: var(--line-strong);
  stroke-width: 1.5;
}

.checks li[data-on="false"] svg path {
  stroke: var(--line-strong);
}

.card-go {
  color: var(--accent-strong);
  font-weight: 600;
  font-size: 0.94rem;
}

.soon-card {
  display: grid;
  place-items: center;
  min-height: 220px;
  padding: 22px;
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius-panel);
  color: var(--muted);
  text-align: center;
}

.catalog-error {
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius-panel);
  background: var(--surface);
  color: var(--muted);
}

/* Stage: the dark recorder bar showcase */

.stage {
  background: var(--stage);
  color: var(--on-stage);
}

.stage h2,
.stage h3 {
  color: var(--on-stage);
}

.stage .section-head p,
.stage .eyebrow {
  color: var(--stage-muted);
}

.bar-states {
  display: grid;
  gap: 28px;
}

.bar-state {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 28px;
  align-items: center;
  padding-top: 28px;
  border-top: 1px solid var(--stage-line);
}

.bar-state:first-child {
  border-top: 0;
  padding-top: 0;
}

.bar-state p {
  color: var(--stage-muted);
  font-size: 0.94rem;
  margin-top: 6px;
}

.bar-state img {
  border-radius: 10px;
}

.bar-state .img-ready {
  width: min(100%, 720px);
}
.bar-state .img-area {
  width: min(100%, 800px);
}
.bar-state .img-recording {
  width: min(100%, 288px);
}

.stage kbd {
  background: var(--stage-well);
  border-color: var(--stage-line);
  color: var(--on-stage);
}

/* Use cases */

.cases {
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  gap: 28px;
  align-items: start;
}

.case-list {
  display: grid;
  gap: 4px;
}

.case-tab {
  display: grid;
  gap: 2px;
  width: 100%;
  padding: 12px 14px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  background: transparent;
  color: var(--ink);
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.case-tab span {
  color: var(--muted);
  font-size: 0.88rem;
}

.case-tab strong {
  font-weight: 600;
}

.case-tab:hover {
  background: var(--well);
}

.case-tab[aria-selected="true"] {
  background: var(--surface);
  border-color: var(--line-strong);
  box-shadow: var(--shadow-lift);
}

.case-tab[aria-selected="true"] strong {
  color: var(--accent-strong);
}

.case-panel {
  display: grid;
  gap: 22px;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: var(--radius-panel);
  background: var(--surface);
}

.case-panel > p {
  color: var(--muted);
  font-size: 1.02rem;
  max-width: 40em;
}

.setup-label {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 10px;
}

.setup {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 8px;
  margin: 0;
}

.setup div {
  padding: 10px 12px;
  border-radius: var(--radius);
  background: var(--well);
}

.setup dt {
  font-size: 0.78rem;
  color: var(--muted);
}

.setup dd {
  margin: 0;
  font-weight: 700;
  color: var(--ink-strong);
}

.steps-inline {
  margin: 0;
  padding-left: 20px;
  display: grid;
  gap: 6px;
}

/* Features */

.feature-groups {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 40px 56px;
}

.feature-group h3 {
  display: flex;
  align-items: center;
  gap: 10px;
  padding-bottom: 12px;
  margin-bottom: 4px;
  border-bottom: 1px solid var(--line);
}

.feature-group h3 svg {
  color: var(--accent);
}

.feature-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.feature-list li {
  display: grid;
  gap: 2px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}

.feature-list li:last-child {
  border-bottom: 0;
}

.feature-list strong {
  color: var(--ink-strong);
  font-weight: 600;
}

.feature-list span {
  color: var(--muted);
  font-size: 0.94rem;
}

.update-callout {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 28px;
  align-items: center;
  margin-top: 48px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius-panel);
  background: var(--canvas);
}

.update-callout img {
  width: 220px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
}

.update-callout p {
  color: var(--muted);
  margin-top: 6px;
}

/* Install stepper */

.install {
  display: grid;
  grid-template-columns: 320px minmax(0, 1fr);
  gap: 32px;
  align-items: start;
}

.install-steps {
  display: grid;
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: step;
}

.install-step {
  counter-increment: step;
}

.install-step button {
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr);
  gap: 4px 12px;
  width: 100%;
  padding: 14px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  background: transparent;
  color: var(--ink);
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.install-step button::before {
  content: counter(step);
  grid-row: span 2;
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  background: var(--surface);
  font-weight: 700;
  color: var(--muted);
}

.install-step button strong {
  font-weight: 600;
  color: var(--ink-strong);
}

.install-step button span {
  font-size: 0.9rem;
  color: var(--muted);
}

.install-step button:hover {
  background: var(--well);
}

.install-step button[aria-selected="true"] {
  background: var(--surface);
  border-color: var(--line-strong);
  box-shadow: var(--shadow-lift);
}

.install-step button[aria-selected="true"]::before {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--accent-ink);
}

.install-view {
  display: grid;
  gap: 18px;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: var(--radius-panel);
  background: var(--surface);
}

.install-view .step-img {
  display: grid;
  place-items: center;
  min-height: 300px;
  padding: 24px;
  border-radius: var(--radius);
  background: var(--well);
}

.install-view .step-img img {
  max-height: 420px;
  width: auto;
}

.install-view .step-text {
  display: grid;
  gap: 8px;
}

.install-view .step-text p {
  color: var(--muted);
}

.install-nav {
  display: flex;
  justify-content: space-between;
  gap: 10px;
}

.install-note {
  margin-top: 16px;
  color: var(--muted);
  font-size: 0.92rem;
}

/* Get it */

.get-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.get-grid.is-single {
  grid-template-columns: minmax(0, 560px);
}

.get-card {
  display: grid;
  grid-template-rows: auto auto 1fr auto;
  gap: 12px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius-panel);
  background: var(--surface);
}

.get-card.is-main {
  border-color: var(--accent);
  box-shadow: 0 0 0 1px var(--accent);
}

.get-card p {
  color: var(--muted);
  font-size: 0.94rem;
}

.get-card .status {
  font-size: 0.86rem;
  color: var(--muted);
}

.get-card .status[data-state="ready"]::before,
.get-card .status[data-state="preparing"]::before {
  content: "";
  display: inline-block;
  width: 8px;
  height: 8px;
  margin-right: 6px;
  border-radius: 50%;
  background: oklch(0.62 0.15 150);
}

.get-card .status[data-state="preparing"]::before {
  background: oklch(0.72 0.15 80);
}

.code {
  display: grid;
  gap: 2px;
  padding: 12px 14px;
  border-radius: var(--radius);
  background: var(--stage);
  color: var(--on-stage);
  font-family: var(--mono);
  font-size: 0.84rem;
  overflow-x: auto;
}

.code code {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.code .c {
  color: var(--stage-muted);
}

.copy-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

/* Files table */

.files {
  width: 100%;
  border-collapse: collapse;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-panel);
  overflow: hidden;
  font-size: 0.95rem;
}

.files th,
.files td {
  padding: 12px 16px;
  text-align: left;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}

.files tr:last-child td {
  border-bottom: 0;
}

.files th {
  font-size: 0.8rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  background: var(--canvas);
}

.two-col {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
  gap: 48px;
  align-items: start;
}

.two-col .prose {
  display: grid;
  gap: 12px;
  color: var(--muted);
}

.two-col .prose h3 {
  margin-top: 8px;
}

/* Footer */

.site-foot {
  padding: 40px 0;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.9rem;
}

.site-foot .wrap {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 16px;
}

.site-foot nav {
  display: flex;
  gap: 18px;
}

.site-foot a {
  color: var(--muted);
}

/* Narrow screens */

@media (max-width: 960px) {
  .hero-grid,
  .two-col {
    grid-template-columns: 1fr;
    gap: 36px;
  }
  .cases,
  .install,
  .bar-state {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  .get-grid {
    grid-template-columns: 1fr;
  }
  .feature-groups {
    grid-template-columns: 1fr;
  }
  .case-list,
  .install-steps {
    grid-auto-flow: column;
    grid-auto-columns: minmax(200px, 1fr);
    overflow-x: auto;
    padding-bottom: 4px;
  }
  .section {
    padding: 64px 0;
  }
}

@media (max-width: 640px) {
  .wrap {
    width: calc(100% - 32px);
  }
  .site-nav .nav-text {
    display: none;
  }
  .site-head .wrap {
    gap: 12px;
  }
  .site-nav {
    gap: 0;
  }
  .site-nav a {
    padding: 6px 7px;
    font-size: 0.88rem;
  }
  .hero {
    padding: 44px 0 40px;
  }
  .update-callout {
    grid-template-columns: 1fr;
  }
  .case-panel,
  .install-view {
    padding: 18px;
  }
  .product-grid {
    grid-template-columns: 1fr;
  }
  .soon-card {
    min-height: 96px;
  }
  .install-view .step-img {
    min-height: 200px;
    padding: 12px;
  }
  .files th,
  .files td {
    padding: 10px;
  }
  .files td code {
    word-break: break-all;
  }
}
