/* Sonora website. Grayscale brand: black, white and grays only.
   Colour comes from the product screenshots, not from the chrome. The one exception is amber, used only for
   the alpha status so it can't be missed. */

:root {
    color-scheme: dark;
    --bg: #0b0b0c;
    --bg-raised: #141416;
    --bg-sunken: #070708;
    --line: #26262a;
    --line-strong: #3a3a40;
    --text: #f2f2f3;
    --text-muted: #a4a4ab;
    --text-faint: #6f6f77;
    --ink: #ffffff;
    --radius: 14px;
    --radius-small: 8px;
    --gutter: clamp(16px, 4vw, 40px);
    --max: 1180px;
    --font: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Inter, "Helvetica Neue", Arial, sans-serif;
    --font-display: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", Inter, "Helvetica Neue", Arial, sans-serif;
    --font-mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
    --alpha: #f5b942;
    --alpha-ink: #ffe2a6;
    --alpha-bg: #1d1707;
    --alpha-line: #5c4714;
}

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

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

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font: 17px/1.6 var(--font);
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--ink); text-decoration-color: var(--line-strong); text-underline-offset: 3px; }
a:hover { text-decoration-color: var(--ink); }
code, pre { font-family: var(--font-mono); font-size: 0.88em; }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; border-radius: 4px; }

.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: #000; padding: 8px 12px; z-index: 100; }
.skip:focus { left: 8px; }

/* Header */
.site-header {
    position: sticky; top: 0; z-index: 50;
    background: rgba(11, 11, 12, 0.82);
    backdrop-filter: saturate(140%) blur(14px);
    -webkit-backdrop-filter: saturate(140%) blur(14px);
    border-bottom: 1px solid var(--line);
}
.site-header .wrap { display: flex; align-items: center; gap: 24px; height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; flex: none; }
.brand img.mark { width: 30px; height: 30px; border-radius: 7px; }
.brand img.word { height: 17px; width: auto; }
.nav { display: flex; align-items: center; gap: 4px; margin-left: auto; }
.nav a {
    color: var(--text-muted); text-decoration: none; font-size: 15px; white-space: nowrap;
    padding: 8px 12px; border-radius: 999px;
}
.nav a:hover, .nav a[aria-current="page"] { color: var(--ink); background: var(--bg-raised); }
.nav .btn { margin-left: 8px; }
.nav .btn-primary, .nav .btn-primary:hover { color: #000; background: var(--ink); }
.nav .btn-primary:hover { background: #d9d9dc; }
.nav-toggle {
    display: none; margin-left: auto; background: none; border: 1px solid var(--line-strong);
    color: var(--text); border-radius: 999px; padding: 7px 14px; font: inherit; font-size: 15px; cursor: pointer;
}

@media (max-width: 980px) {
    .nav-toggle { display: block; }
    .nav {
        display: none; position: absolute; left: 0; right: 0; top: 64px;
        flex-direction: column; align-items: stretch; gap: 0;
        background: var(--bg); border-bottom: 1px solid var(--line); padding: 8px var(--gutter) 16px;
    }
    .nav.open { display: flex; }
    .nav a { padding: 12px 4px; border-radius: 0; border-bottom: 1px solid var(--line); }
    .nav a:hover, .nav a[aria-current="page"] { background: none; }
    .nav .btn { margin: 12px 0 0; text-align: center; border-bottom: 0; border-radius: 999px; }
}

/* Buttons */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    padding: 12px 22px; border-radius: 999px; font-weight: 600; font-size: 16px;
    text-decoration: none; border: 1px solid transparent; cursor: pointer; line-height: 1.2;
}
.btn-primary { background: var(--ink); color: #000; }
.btn-primary:hover { background: #d9d9dc; }
.btn-ghost { border-color: var(--line-strong); color: var(--ink); background: transparent; }
.btn-ghost:hover { border-color: var(--ink); }
.btn-small { padding: 8px 16px; font-size: 14px; }
.btn[aria-disabled="true"] { background: var(--bg-raised); color: var(--text-faint); border-color: var(--line); cursor: default; }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }

/* Type */
h1, h2, h3 { font-family: var(--font-display); color: var(--ink); line-height: 1.1; letter-spacing: -0.02em; margin: 0 0 16px; }
h1 { font-size: clamp(40px, 7vw, 76px); font-weight: 700; letter-spacing: -0.035em; }
h2 { font-size: clamp(30px, 4.4vw, 48px); font-weight: 700; letter-spacing: -0.03em; }
h3 { font-size: 21px; font-weight: 650; letter-spacing: -0.01em; }
p { margin: 0 0 16px; }
.lede { font-size: clamp(18px, 2.2vw, 22px); color: var(--text-muted); max-width: 46em; }
.eyebrow {
    display: inline-block; font-size: 13px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase;
    color: var(--text-muted); margin-bottom: 18px;
}
.muted { color: var(--text-muted); }
.faint { color: var(--text-faint); }
.small { font-size: 14px; }

/* Sections */
section { padding: clamp(64px, 10vw, 120px) 0; }
section + section { border-top: 1px solid var(--line); }
.section-head { max-width: 760px; margin-bottom: clamp(32px, 5vw, 56px); }

/* Hero */
.hero { padding-top: clamp(48px, 9vw, 104px); padding-bottom: 0; position: relative; overflow: hidden; }
.hero::before {
    content: ""; position: absolute; right: -6%; top: -4%; width: min(46vw, 560px); aspect-ratio: 76 / 100;
    background: url("brand/mark.svg") no-repeat center / contain;
    opacity: 0.045; filter: invert(1); pointer-events: none;
}
.hero.no-mark::before { display: none; } /* the splash screenshot already shows the mark */
.hero .lede { margin-bottom: 32px; }
.hero-shot { margin-top: clamp(40px, 6vw, 72px); }
.page-hero { padding-bottom: clamp(40px, 6vw, 72px); }

/* Screenshots */
.shot {
    margin: 0; border-radius: var(--radius); overflow: hidden; background: var(--bg-raised);
    border: 1px solid var(--line-strong);
    box-shadow: 0 30px 80px -30px rgba(0, 0, 0, 0.9), 0 0 0 1px rgba(255, 255, 255, 0.02);
}
.shot img { width: 100%; cursor: zoom-in; }
.shot-caption { font-size: 14px; color: var(--text-faint); margin-top: 12px; }
.shot.tall { max-width: 420px; }
.feature > .shot.tall { justify-self: center; width: 100%; }

/* Fact strip */
.facts { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; margin-top: clamp(40px, 6vw, 64px); }
.fact { background: var(--bg); padding: 22px 20px; }
.fact strong { display: block; color: var(--ink); font-size: 17px; margin-bottom: 4px; }
.fact span { color: var(--text-muted); font-size: 14px; line-height: 1.45; display: block; }
@media (max-width: 820px) { .facts { grid-template-columns: 1fr 1fr; } }
@media (max-width: 420px) { .facts { grid-template-columns: 1fr; } }

/* Feature rows */
.feature { display: grid; grid-template-columns: 5fr 7fr; gap: clamp(28px, 5vw, 64px); align-items: center; }
.feature > * { min-width: 0; } /* lets code blocks and tables scroll instead of widening the column */
.feature + .feature { margin-top: clamp(64px, 9vw, 112px); }
.feature.flip { grid-template-columns: 7fr 5fr; }
.feature.flip > :first-child { order: 2; }
.feature.stack { grid-template-columns: 1fr; }
/* Wide screenshots: intro and list side by side, the picture full width underneath, large enough to read. */
.feature.wide { align-items: end; row-gap: 32px; }
.feature.wide > figure { grid-column: 1 / -1; }
.feature.wide > div:first-child > :last-child { margin-bottom: 0; }
.feature ul { padding-left: 0; list-style: none; margin: 0 0 16px; }
.feature li { padding: 8px 0 8px 22px; position: relative; border-top: 1px solid var(--line); color: var(--text-muted); }
.feature li strong { color: var(--text); font-weight: 600; }
.feature li::before { content: ""; position: absolute; left: 2px; top: 18px; width: 8px; height: 2px; background: var(--text-faint); }
@media (max-width: 900px) {
    .feature, .feature.flip { grid-template-columns: 1fr; }
    .feature.flip > :first-child { order: 0; }
    .feature.wide { row-gap: 8px; }
}
.pair { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; align-items: start; }
@media (max-width: 640px) { .pair { grid-template-columns: 1fr; } .shot.tall { max-width: none; } }

/* Cards */
.grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); }
.grid.grid-3 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); }
.card { background: var(--bg-raised); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.card h3 { font-size: 18px; margin-bottom: 8px; }
.card p, .card li { color: var(--text-muted); font-size: 15px; }
.card p:last-child { margin-bottom: 0; }
.card ul { padding-left: 18px; margin: 0; }
.card .tag { display: inline-block; font-size: 12px; font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase; color: var(--text-faint); margin-bottom: 10px; }

/* Tables */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); -webkit-overflow-scrolling: touch; }
table { width: 100%; border-collapse: collapse; font-size: 15px; min-width: 560px; }
th, td { text-align: left; padding: 14px 18px; border-bottom: 1px solid var(--line); vertical-align: top; }
thead th { font-size: 13px; letter-spacing: 0.04em; text-transform: uppercase; color: var(--text-faint); font-weight: 600; background: var(--bg-sunken); }
tbody tr:last-child > * { border-bottom: 0; }
tbody th { font-weight: 600; color: var(--text); width: 34%; }
td { color: var(--text-muted); }
td.yes { color: var(--ink); }
td.yes::before { content: "● "; font-size: 11px; vertical-align: 2px; }
td.part::before { content: "◐ "; font-size: 12px; color: var(--text-muted); vertical-align: 1px; }
td.no::before { content: "○ "; font-size: 11px; color: var(--text-faint); vertical-align: 2px; }
.table-note { font-size: 14px; color: var(--text-faint); margin-top: 14px; }

/* Callouts and code */
.callout { border: 1px solid var(--line-strong); border-radius: var(--radius); padding: 24px; background: var(--bg-raised); }
.callout h3 { margin-bottom: 8px; }
.callout p:last-child, .callout ul:last-child { margin-bottom: 0; }
.callout ul { color: var(--text-muted); padding-left: 20px; }
pre {
    background: var(--bg-sunken); border: 1px solid var(--line); border-radius: var(--radius-small);
    padding: 16px 18px; overflow-x: auto; color: var(--text); line-height: 1.55; margin: 0 0 16px;
}
:not(pre) > code { background: var(--bg-raised); border: 1px solid var(--line); border-radius: 5px; padding: 1px 6px; }

/* CTA band */
.cta { text-align: center; }
.cta .lede { margin: 0 auto 28px; }
.cta .btn-row { justify-content: center; }
.cta-icon { width: 112px; height: 112px; margin: 0 auto 28px; border-radius: 26px; box-shadow: 0 24px 60px -20px rgba(0, 0, 0, 0.9); }

/* FAQ */
details { border-top: 1px solid var(--line); padding: 4px 0; }
details:last-of-type { border-bottom: 1px solid var(--line); }
summary { cursor: pointer; list-style: none; padding: 18px 36px 18px 0; position: relative; font-weight: 600; color: var(--ink); font-size: 18px; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; position: absolute; right: 4px; top: 14px; font-size: 24px; font-weight: 400; color: var(--text-muted); }
details[open] summary::after { content: "–"; }
details > div { padding: 0 0 18px; color: var(--text-muted); max-width: 48em; }
.faq-group + .faq-group { margin-top: 48px; }

/* Sub-navigation on long pages */
.toc { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.toc a { font-size: 14px; text-decoration: none; color: var(--text-muted); border: 1px solid var(--line); border-radius: 999px; padding: 6px 14px; }
.toc a:hover { color: var(--ink); border-color: var(--line-strong); }

/* Footer */
.site-footer { border-top: 1px solid var(--line); padding: 48px 0 56px; color: var(--text-faint); font-size: 14px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 32px; }
.footer-grid .footer-h { color: var(--text-muted); font-size: 13px; letter-spacing: 0.06em; text-transform: uppercase; margin: 0 0 12px; }
.footer-grid ul { list-style: none; padding: 0; margin: 0; }
.footer-grid li { margin-bottom: 8px; }
.footer-grid a { color: var(--text-muted); text-decoration: none; }
.footer-grid a:hover { color: var(--ink); }
.footer-brand img { height: 16px; width: auto; margin-bottom: 14px; }
.legal { margin-top: 40px; padding-top: 24px; border-top: 1px solid var(--line); max-width: 60em; }
@media (max-width: 820px) { .footer-grid { grid-template-columns: 1fr 1fr; } .footer-brand { grid-column: 1 / -1; } }

/* Alpha status: a strip on every page, a badge, and a larger notice where it matters */
.alpha-bar { background: var(--alpha-bg); border-bottom: 1px solid var(--alpha-line); color: var(--alpha-ink); font-size: 14px; line-height: 1.45; }
.alpha-bar .wrap { padding-top: 9px; padding-bottom: 9px; display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 4px 10px; text-align: center; }
.alpha-bar a { color: var(--alpha-ink); text-decoration-color: var(--alpha-line); }
.alpha-bar a:hover { text-decoration-color: var(--alpha-ink); }
.badge { display: inline-block; font-size: 12px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; line-height: 1; padding: 5px 9px; border-radius: 999px; vertical-align: 2px; }
.badge-alpha { background: var(--alpha); color: #1a1300; }
.badge-soft { border: 1px solid var(--line-strong); color: var(--text-muted); font-weight: 600; }
.notice { border: 1px solid var(--alpha-line); background: var(--alpha-bg); border-radius: var(--radius); padding: clamp(22px, 4vw, 36px); }
.notice h2, .notice h3 { color: var(--alpha-ink); }
.notice p, .notice li { color: #e9dcc0; }
.notice ul { padding-left: 20px; margin: 0 0 16px; }
.notice li { margin-bottom: 6px; }
.notice > :last-child { margin-bottom: 0; }
.notice a { color: var(--alpha-ink); }
.notice .btn-row { margin-top: 20px; }

/* Two-column lists such as "who it's for" */
.columns { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.columns > * { min-width: 0; }
@media (max-width: 760px) { .columns { grid-template-columns: 1fr; } }
.check-list, .cross-list { list-style: none; padding: 0; margin: 0; }
.check-list li, .cross-list li { position: relative; padding: 9px 0 9px 26px; border-top: 1px solid var(--line); color: var(--text-muted); font-size: 15px; }
.check-list li:first-child, .cross-list li:first-child { border-top: 0; }
.check-list li::before { content: "\2713"; position: absolute; left: 2px; top: 9px; color: var(--ink); font-weight: 700; }
.cross-list li::before { content: "\2013"; position: absolute; left: 4px; top: 9px; color: var(--text-faint); font-weight: 700; }

/* A personal note set apart from the product copy */
.note { border-left: 3px solid var(--line-strong); padding: 4px 0 4px clamp(18px, 3vw, 28px); margin: 0; }
.note p { font-size: clamp(18px, 2vw, 21px); color: var(--text); line-height: 1.55; }
.note footer { color: var(--text-faint); font-size: 15px; }

/* Download cards */
.dl-card { display: flex; flex-direction: column; }
.dl-card .btn { margin-top: auto; align-self: flex-start; }
.dl-card .file { font-family: var(--font-mono); font-size: 13px; color: var(--text-faint); margin-bottom: 14px; word-break: break-all; }
.dl-card.main { border-color: var(--line-strong); background: linear-gradient(180deg, #1a1a1d, var(--bg-raised)); }

.wrap.narrow { max-width: 860px; }
.mt { margin-top: clamp(28px, 4vw, 44px); }
.center { text-align: center; }
@media (max-width: 640px) { h1 br { display: none; } }
@media (max-width: 900px) { .hide-narrow { display: none; } }

/* Lightbox */
.lightbox {
    position: fixed; inset: 0; z-index: 200; background: rgba(0, 0, 0, 0.92);
    display: none; align-items: center; justify-content: center; padding: 24px; cursor: zoom-out;
}
.lightbox.open { display: flex; }
.lightbox img { max-width: 100%; max-height: 100%; border-radius: var(--radius-small); }

@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

/* GitHub link in the header, the home page's source button and open-source line */
.nav a.nav-gh { display: inline-flex; align-items: center; gap: 6px; }
.btn-gh { display: inline-flex; align-items: center; gap: 8px; }
.btn-gh svg, .nav-gh svg { flex: none; }
@media (min-width: 981px) and (max-width: 1180px) { .nav a.nav-gh span { display: none; } } /* icon only when tight */
.oss-line { margin-top: 18px; color: var(--text-muted); font-size: 15px; }
.oss-line .badge { margin-right: 8px; }

/* Download cards: the visitor's system first, marked */
.dl-yours { align-self: flex-start; margin-bottom: 12px; }
.dl-card .btn-row { margin-top: auto; gap: 8px; }
.dl-card .btn-row .btn { margin-top: 0; }

