/* Secretariat — product site. One file, system fonts, light + dark. */

:root {
  --bg: #f7f7f5;
  --surface: #ffffff;
  --surface-2: #f0f0ec;
  --text: #1b1d1f;
  --muted: #565b61;
  --border: #dcdcd6;
  --accent: #0b6e69;
  --accent-strong: #08524e;
  --accent-soft: #e2f1ef;
  --on-accent: #ffffff;
  --term-bg: #15181b;
  --term-text: #d9dee3;
  --term-dim: #8b949e;
  --term-mask: #5fd4c8;
  --term-prompt: #9ad1ff;
  --focus: #0b6e69;
  --radius: 12px;
  --max: 1120px;
  --gutter: 24px;
  --shadow: 0 1px 2px rgb(0 0 0 / 0.04), 0 8px 24px rgb(0 0 0 / 0.06);
  --mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, Consolas, monospace;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, Roboto, "Helvetica Neue", Arial, sans-serif;
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #111315;
    --surface: #181b1e;
    --surface-2: #1f2327;
    --text: #e8eaec;
    --muted: #a3a9b0;
    --border: #2d3237;
    --accent: #4cc2b8;
    --accent-strong: #79d6ce;
    --accent-soft: #15302e;
    --on-accent: #06201e;
    --term-bg: #0b0d0f;
    --focus: #79d6ce;
    --shadow: 0 1px 2px rgb(0 0 0 / 0.3), 0 8px 24px rgb(0 0 0 / 0.35);
  }
}

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

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.6;
  overflow-wrap: break-word;
}

img { max-width: 100%; height: auto; display: block; }

a { color: var(--accent); text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:hover { color: var(--accent-strong); }

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

code, kbd, pre { font-family: var(--mono); font-size: 0.88em; }
:not(pre) > code {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 0.08em 0.38em;
  overflow-wrap: anywhere;
}

h1, h2, h3 { line-height: 1.2; letter-spacing: -0.015em; margin: 0 0 0.5em; }
h1 { font-size: clamp(2.1rem, 4.6vw, 3.4rem); letter-spacing: -0.03em; }
h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); }
h3 { font-size: 1.12rem; }
p { margin: 0 0 1em; }

.skip {
  position: absolute; left: -9999px; top: 8px;
  background: var(--surface); color: var(--text); padding: 8px 12px; border-radius: 8px; z-index: 10;
}
.skip:focus { left: 8px; }

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

/* Header */
.site-header {
  border-bottom: 1px solid var(--border);
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  position: sticky; top: 0; z-index: 5;
  backdrop-filter: saturate(1.4) blur(10px);
  -webkit-backdrop-filter: saturate(1.4) blur(10px);
}
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 60px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 650; color: var(--text); text-decoration: none; font-size: 1.05rem; }
.brand svg { width: 28px; height: 28px; flex: none; }
.nav { display: flex; align-items: center; gap: 22px; font-size: 0.94rem; }
.nav a { color: var(--muted); text-decoration: none; }
.nav a:hover { color: var(--text); }
.nav .btn { color: var(--on-accent); }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  background: var(--accent); color: var(--on-accent);
  border: 1px solid transparent; border-radius: 10px;
  padding: 0.62em 1.15em; font-weight: 600; text-decoration: none; font-size: 0.98rem;
}
.btn:hover { background: var(--accent-strong); color: var(--on-accent); }
.btn.secondary { background: transparent; color: var(--text); border-color: var(--border); }
.btn.secondary:hover { background: var(--surface-2); color: var(--text); }
.btn.small { padding: 0.42em 0.9em; font-size: 0.9rem; }
.btn.block { width: 100%; }

/* Sections */
section { padding: 88px 0; }
section + section { border-top: 1px solid var(--border); }
.eyebrow { font-size: 0.8rem; font-weight: 650; letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent); margin-bottom: 0.7em; }
.lead { font-size: 1.15rem; color: var(--muted); max-width: 62ch; }
.section-head { max-width: 720px; margin-bottom: 40px; }

/* Hero */
.hero { padding: 72px 0 80px; }
.hero-grid { display: grid; grid-template-columns: 1.02fr 1fr; gap: 56px; align-items: center; }
.hero-grid > *, .pricing-grid > *, .compare > *, .split > * { min-width: 0; }
.hero h1 { margin-bottom: 0.4em; }
.hero .lead { margin-bottom: 1.6em; }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.fineprint { font-size: 0.88rem; color: var(--muted); margin-top: 1.1em; }

/* Terminal */
.terminal {
  background: var(--term-bg); color: var(--term-text);
  border-radius: var(--radius); box-shadow: var(--shadow);
  border: 1px solid rgb(255 255 255 / 0.06);
  overflow: hidden; min-width: 0; margin: 0;
}
.terminal-bar { display: flex; align-items: center; gap: 7px; padding: 11px 14px; border-bottom: 1px solid rgb(255 255 255 / 0.07); }
.terminal-bar span { width: 11px; height: 11px; border-radius: 50%; background: #3a3f45; }
.terminal-bar em { font-style: normal; color: var(--term-dim); font-size: 0.78rem; margin-left: 8px; font-family: var(--mono); }
.terminal pre { margin: 0; padding: 18px 18px 20px; overflow-x: auto; line-height: 1.65; font-size: 0.82rem; }
.terminal .c { color: var(--term-dim); }
.terminal .p { color: var(--term-prompt); }
.terminal .m { color: var(--term-mask); }
.terminal-caption { font-size: 0.85rem; color: var(--muted); margin-top: 12px; }

/* Evidence list */
.evidence { list-style: none; padding: 0; margin: 0; display: grid; gap: 16px; grid-template-columns: repeat(3, 1fr); }
.evidence li { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 22px; }
.evidence blockquote { margin: 0 0 0.7em; font-size: 1.02rem; font-weight: 550; }
.evidence p { color: var(--muted); font-size: 0.94rem; margin: 0; }
.source { display: inline-block; margin-top: 10px; font-size: 0.88rem; }

/* Steps */
.steps { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; counter-reset: step; }
.steps li { counter-increment: step; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; min-width: 0; }
.steps li::before {
  content: counter(step); display: inline-grid; place-items: center;
  width: 30px; height: 30px; border-radius: 50%; margin-bottom: 14px;
  background: var(--accent-soft); color: var(--accent-strong); font-weight: 700; font-size: 0.92rem;
}
.steps p { color: var(--muted); font-size: 0.95rem; }
.cmd {
  display: block; background: var(--surface-2); border: 1px solid var(--border); border-radius: 8px;
  padding: 10px 12px; font-family: var(--mono); font-size: 0.8rem; overflow-x: auto; white-space: pre; margin: 0;
}

/* Cards */
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 26px; min-width: 0; }
.card p { color: var(--muted); font-size: 0.96rem; }
.card p:last-child { margin-bottom: 0; }
.card .icon { width: 40px; height: 40px; border-radius: 10px; background: var(--accent-soft); color: var(--accent-strong); display: grid; place-items: center; margin-bottom: 16px; }
.card .icon svg { width: 22px; height: 22px; }
.tag { display: inline-block; font-size: 0.75rem; font-weight: 650; color: var(--accent-strong); background: var(--accent-soft); border-radius: 999px; padding: 2px 10px; margin-bottom: 10px; }

.features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; background: var(--surface); }
.feature { padding: 24px 26px; border-right: 1px solid var(--border); border-bottom: 1px solid var(--border); min-width: 0; }
.feature:nth-child(3n) { border-right: 0; }
.feature:nth-last-child(-n+3) { border-bottom: 0; }
.feature h3 { font-size: 1.02rem; margin-bottom: 0.35em; }
.feature p { color: var(--muted); font-size: 0.94rem; margin: 0; }

/* Screenshot */
.shot { margin: 48px 0 0; }
.shot img { border-radius: 10px; border: 1px solid var(--border); box-shadow: var(--shadow); }
.shot figcaption { font-size: 0.86rem; color: var(--muted); margin-top: 12px; text-align: center; }

/* Comparison */
.compare { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
.compare .card h3 { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; align-items: baseline; }
.compare .card h3 small { font-weight: 500; font-size: 0.8rem; color: var(--muted); }
.compare dl { margin: 0; font-size: 0.94rem; }
.compare dt { font-weight: 600; margin-top: 10px; }
.compare dd { margin: 2px 0 0; color: var(--muted); }
.note { font-size: 0.88rem; color: var(--muted); margin-top: 20px; }

/* Callout */
.callout { display: grid; grid-template-columns: 1fr auto; gap: 24px; align-items: center; background: var(--accent-soft); border: 1px solid color-mix(in srgb, var(--accent) 30%, transparent); border-radius: var(--radius); padding: 28px 32px; }
.callout h2 { font-size: 1.45rem; margin-bottom: 0.3em; }
.callout p { margin: 0; color: var(--text); }

/* Pricing */
.pricing-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: start; }
.price-card { background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 32px; box-shadow: var(--shadow); }
.price { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; margin: 6px 0 4px; }
.price strong { font-size: 3rem; letter-spacing: -0.03em; line-height: 1; }
.price span { color: var(--muted); }
.launch { display: inline-block; background: var(--accent-soft); color: var(--accent-strong); border-radius: 8px; padding: 6px 10px; font-size: 0.9rem; font-weight: 600; margin: 10px 0 18px; }
.checklist { list-style: none; padding: 0; margin: 0 0 24px; }
.checklist li { padding-left: 28px; position: relative; margin-bottom: 8px; font-size: 0.97rem; }
.checklist li::before {
  content: ""; position: absolute; left: 2px; top: 0.42em; width: 14px; height: 8px;
  border-left: 2px solid var(--accent); border-bottom: 2px solid var(--accent); transform: rotate(-45deg);
}

/* FAQ */
.faq details { border-bottom: 1px solid var(--border); padding: 4px 0; }
.faq details:first-of-type { border-top: 1px solid var(--border); }
.faq summary { cursor: pointer; padding: 16px 32px 16px 0; font-weight: 600; list-style: none; position: relative; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 4px; top: 12px; font-size: 1.4rem; font-weight: 400; color: var(--muted); }
.faq details[open] summary::after { content: "–"; }
.faq details > div { padding: 0 0 18px; color: var(--muted); }
.faq details > div p:last-child { margin-bottom: 0; }

/* Prose pages */
.prose { padding: 64px 0 88px; }
.prose h1 { font-size: clamp(2rem, 4vw, 2.8rem); }
.prose h2 { font-size: 1.5rem; margin-top: 2em; }
.prose h3 { margin-top: 1.6em; }
.prose ul { padding-left: 1.3em; }
.prose li { margin-bottom: 0.45em; }
.prose address { font-style: normal; }
.updated { color: var(--muted); font-size: 0.92rem; }
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin: 28px 0; }
.split .card h2 { margin-top: 0; font-size: 1.2rem; }
.split .card ul { margin: 0; padding-left: 1.2em; color: var(--muted); font-size: 0.96rem; }
.card.yes { border-top: 3px solid var(--accent); }
.card.no { border-top: 3px solid var(--muted); }

/* Footer */
.site-footer { border-top: 1px solid var(--border); padding: 36px 0 48px; font-size: 0.9rem; color: var(--muted); }
.site-footer .wrap { display: flex; flex-wrap: wrap; gap: 16px 28px; justify-content: space-between; align-items: center; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 8px 22px; }
.site-footer a { color: var(--muted); }
.site-footer a:hover { color: var(--text); }

/* Responsive */
@media (max-width: 960px) {
  .hero-grid, .pricing-grid { grid-template-columns: 1fr; gap: 40px; }
  .evidence, .steps, .cards { grid-template-columns: 1fr; }
  .features { grid-template-columns: 1fr 1fr; }
  .feature:nth-child(3n) { border-right: 1px solid var(--border); }
  .feature:nth-child(2n) { border-right: 0; }
  .feature:nth-last-child(-n+3) { border-bottom: 1px solid var(--border); }
  .feature:nth-last-child(-n+2) { border-bottom: 0; }
}

@media (max-width: 720px) {
  :root { --gutter: 16px; }
  body { font-size: 16px; }
  section { padding: 60px 0; }
  .hero { padding: 44px 0 56px; }
  .nav a:not(.btn) { display: none; }
  .features, .compare, .split { grid-template-columns: 1fr; }
  .feature, .feature:nth-child(3n), .feature:nth-child(2n) { border-right: 0; border-bottom: 1px solid var(--border); }
  .feature:nth-last-child(-n+2) { border-bottom: 1px solid var(--border); }
  .feature:last-child { border-bottom: 0; }
  .callout { grid-template-columns: 1fr; padding: 24px; }
  .price-card { padding: 24px; }
  .terminal pre { font-size: 0.74rem; padding: 14px; }
}
