/* Stack'd Development Studio — site styles.
   Palette and type are the app's own (src/styles/variables.css in the Stackd
   repo): ink on paper, Manrope display, Inter body, sky accent in the dark. */

/* ── Fonts (self-hosted, same files the app ships) ─────────────────────── */
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 400 700; font-display: swap; src: url('fonts/inter-latin-ext.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 400 700; font-display: swap; src: url('fonts/inter-latin.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Manrope'; font-style: normal; font-weight: 400 800; font-display: swap; src: url('fonts/manrope-latin-ext.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Manrope'; font-style: normal; font-weight: 400 800; font-display: swap; src: url('fonts/manrope-latin.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

/* ── Tokens ─────────────────────────────────────────────────────────────── */
:root {
  color-scheme: light dark;
  --ink: #111111;
  --ink-2: #3b4452;
  --muted: #5b6675;
  --paper: #f4f7f9;
  --card: #ffffff;
  --sunken: #eef2f5;
  --rule: #dfe6ed;
  --rule-strong: #c9d3dc;
  --accent: #0284c7;      /* sky, darkened to hold contrast on paper */
  --accent-ink: #ffffff;
  --income: #059669;
  --expense: #dc2626;
  --btn: #111111;
  --btn-ink: #f8fafc;
  --shadow: 0 24px 60px rgba(15, 23, 42, 0.14), 0 2px 6px rgba(15, 23, 42, 0.06);
  --phone-bezel: #0b0f19;
  --font-display: 'Manrope', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-body: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --max: 1120px;
  --gutter: clamp(20px, 5vw, 48px);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --ink: #f8fafc;
    --ink-2: #cbd5e1;
    --muted: #94a3b8;
    --paper: #0b0f19;
    --card: #161e2e;
    --sunken: #111827;
    --rule: rgba(51, 65, 85, 0.6);
    --rule-strong: #334155;
    --accent: #38bdf8;
    --accent-ink: #0b0f19;
    --income: #34d399;
    --expense: #f87171;
    --btn: #f8fafc;
    --btn-ink: #111111;
    --shadow: 0 24px 60px rgba(0, 0, 0, 0.55), 0 2px 6px rgba(0, 0, 0, 0.4);
    --phone-bezel: #1f293d;
  }
}
:root[data-theme="dark"] {
  --ink: #f8fafc;
  --ink-2: #cbd5e1;
  --muted: #94a3b8;
  --paper: #0b0f19;
  --card: #161e2e;
  --sunken: #111827;
  --rule: rgba(51, 65, 85, 0.6);
  --rule-strong: #334155;
  --accent: #38bdf8;
  --accent-ink: #0b0f19;
  --income: #34d399;
  --expense: #f87171;
  --btn: #f8fafc;
  --btn-ink: #111111;
  --shadow: 0 24px 60px rgba(0, 0, 0, 0.55), 0 2px 6px rgba(0, 0, 0, 0.4);
  --phone-bezel: #1f293d;
}

/* ── Base ───────────────────────────────────────────────────────────────── */
*, *::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(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 0.18em; }
a:hover { text-decoration-color: var(--accent); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 2px; }
h1, h2, h3, h4 { font-family: var(--font-display); font-weight: 800; letter-spacing: -0.025em; line-height: 1.1; margin: 0; text-wrap: balance; }
p { margin: 0; }
strong { font-weight: 600; }
.num { font-variant-numeric: tabular-nums; }

.wrap { width: min(var(--max), 100% - 2 * var(--gutter)); margin-inline: auto; }
.eyebrow { font-family: var(--font-body); font-size: 12px; font-weight: 600; letter-spacing: 0.09em; text-transform: uppercase; color: var(--muted); }
.lede { font-size: clamp(18px, 2vw, 21px); line-height: 1.5; color: var(--ink-2); max-width: 34em; text-wrap: pretty; }
.measure { max-width: 65ch; }

/* ── Header ─────────────────────────────────────────────────────────────── */
.site-header { position: sticky; top: 0; z-index: 10; background: color-mix(in srgb, var(--paper) 85%, transparent); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); border-bottom: 1px solid var(--rule); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 24px; height: 64px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-family: var(--font-display); font-weight: 800; font-size: 18px; letter-spacing: -0.02em; text-decoration: none; }
.brand .mark { width: 28px; height: 28px; color: var(--ink); }
.brand small { font-family: var(--font-body); font-weight: 500; font-size: 12px; color: var(--muted); letter-spacing: 0.02em; margin-left: 2px; }
.nav { display: flex; align-items: center; gap: 4px; }
.nav a { font-size: 14px; font-weight: 500; text-decoration: none; padding: 8px 12px; border-radius: 6px; color: var(--ink-2); }
.nav a:hover { background: var(--sunken); color: var(--ink); }
.nav a[aria-current="page"] { color: var(--ink); }
.nav .btn { margin-left: 8px; }
/* .nav a outranks .btn-primary; restate the button colours at the higher specificity */
.nav a.btn-primary { color: var(--btn-ink); background: var(--btn); }
.nav a.btn-primary:hover { color: var(--btn-ink); background: color-mix(in srgb, var(--btn) 88%, var(--paper)); }
@media (max-width: 640px) { .brand small { display: none; } .nav a:not(.btn) { display: none; } }

/* ── Buttons ─────────────────────────────────────────────────────────────── */
.btn { display: inline-flex; align-items: center; gap: 10px; height: 44px; padding: 0 18px; border-radius: 10px; border: 1px solid transparent; font: 600 15px/1 var(--font-body); text-decoration: none; cursor: pointer; transition: transform 150ms cubic-bezier(0.16, 1, 0.3, 1), background-color 150ms; white-space: nowrap; }
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--btn); color: var(--btn-ink); }
.btn-primary:hover { background: color-mix(in srgb, var(--btn) 88%, var(--paper)); }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--rule-strong); }
.btn-ghost:hover { background: var(--sunken); }
.btn svg { width: 18px; height: 18px; flex: none; }
.btn-sm { height: 36px; padding: 0 14px; font-size: 14px; }
.btn[aria-disabled="true"] { opacity: 0.6; cursor: default; }
.btn[aria-disabled="true"]:active { transform: none; }

/* ── Hero ───────────────────────────────────────────────────────────────── */
.hero { padding: clamp(48px, 8vw, 96px) 0 clamp(32px, 6vw, 72px); }
.hero .wrap { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(32px, 6vw, 80px); align-items: center; }
.hero h1 { font-size: clamp(38px, 5.6vw, 66px); letter-spacing: -0.035em; margin: 18px 0 22px; }
.hero h1 em { font-style: normal; color: var(--accent); }
.hero .cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.hero .facts { display: flex; flex-wrap: wrap; gap: 6px 22px; margin-top: 28px; padding-top: 22px; border-top: 1px solid var(--rule); font-size: 14px; color: var(--muted); }
.hero .facts b { font-weight: 600; color: var(--ink); }
@media (max-width: 860px) { .hero .wrap { grid-template-columns: 1fr; } .hero .phone-col { order: -1; } }

/* ── Phone frame ────────────────────────────────────────────────────────── */
.phone { position: relative; width: min(300px, 100%); margin-inline: auto; aspect-ratio: 390 / 844; border-radius: 40px; background: var(--phone-bezel); padding: 10px; box-shadow: var(--shadow); isolation: isolate; }
.phone::before { content: ""; position: absolute; top: 20px; left: 50%; transform: translateX(-50%); width: 92px; height: 26px; border-radius: 14px; background: #0b0f19; z-index: 2; }
.phone img { width: 100%; height: 100%; object-fit: cover; object-position: top; border-radius: 32px; }
.phone-col { display: flex; justify-content: center; }
.phone.small { width: min(240px, 100%); border-radius: 34px; padding: 8px; }
.phone.small::before { top: 16px; width: 72px; height: 20px; }
.phone.small img { border-radius: 28px; }

/* ── Sections ───────────────────────────────────────────────────────────── */
.section { padding: clamp(56px, 8vw, 104px) 0; border-top: 1px solid var(--rule); }
.section-head { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 24px 48px; align-items: end; margin-bottom: clamp(32px, 5vw, 56px); }
.section-head h2 { font-size: clamp(28px, 3.6vw, 42px); margin-top: 12px; }
.section-head p { color: var(--ink-2); font-size: 17px; max-width: 42em; text-wrap: pretty; }
@media (max-width: 760px) { .section-head { grid-template-columns: 1fr; } }

/* Feature ledger: a two-column list with a hairline between rows, no cards */
.ledger { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 clamp(32px, 5vw, 72px); border-top: 1px solid var(--rule); }
.ledger > div { display: grid; grid-template-columns: 40px 1fr; gap: 0 18px; padding: 26px 0; border-bottom: 1px solid var(--rule); }
.ledger .ic { width: 40px; height: 40px; border-radius: 10px; background: var(--sunken); display: grid; place-items: center; color: var(--ink); }
.ledger .ic svg { width: 20px; height: 20px; }
.ledger h3 { font-size: 19px; letter-spacing: -0.015em; margin-bottom: 6px; }
.ledger p { color: var(--ink-2); font-size: 15.5px; line-height: 1.55; text-wrap: pretty; }
.ledger p code { font-family: ui-monospace, 'Cascadia Mono', Consolas, monospace; font-size: 13px; background: var(--sunken); padding: 1px 5px; border-radius: 4px; }
@media (max-width: 760px) { .ledger { grid-template-columns: 1fr; } }

/* Screens strip */
.screens { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(20px, 3vw, 40px); align-items: start; }
.screens figure { margin: 0; }
.screens figcaption { margin-top: 18px; text-align: center; }
.screens figcaption b { display: block; font-family: var(--font-display); font-weight: 800; font-size: 17px; letter-spacing: -0.01em; }
.screens figcaption span { font-size: 14px; color: var(--muted); }
@media (max-width: 760px) { .screens { grid-template-columns: 1fr; } .screens figure + figure { margin-top: 8px; } }

/* Privacy block: the "does not do" list is the product's own wording */
.privacy-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(28px, 5vw, 72px); align-items: start; }
.nots { list-style: none; padding: 0; margin: 0; border-top: 1px solid var(--rule); }
.nots li { display: flex; align-items: baseline; gap: 14px; padding: 14px 0; border-bottom: 1px solid var(--rule); font-family: var(--font-display); font-weight: 700; font-size: clamp(18px, 2.2vw, 22px); letter-spacing: -0.015em; }
.nots li::before { content: "—"; color: var(--muted); font-weight: 400; flex: none; }
.rights { display: grid; gap: 18px; }
.rights > div { padding: 22px; border-radius: 14px; background: var(--card); border: 1px solid var(--rule); }
.rights .eyebrow { margin-bottom: 8px; }
.rights h3 { font-size: 18px; margin-bottom: 6px; }
.rights p { font-size: 15px; color: var(--ink-2); }
@media (max-width: 760px) { .privacy-grid { grid-template-columns: 1fr; } }

/* Studio */
.studio { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(28px, 5vw, 72px); }
.studio .body { display: grid; gap: 18px; font-size: 17px; color: var(--ink-2); max-width: 60ch; }
.studio .body p { text-wrap: pretty; }
.principles { display: grid; gap: 0; margin-top: 8px; border-top: 1px solid var(--rule); }
.principles div { padding: 18px 0; border-bottom: 1px solid var(--rule); display: grid; grid-template-columns: 11em 1fr; gap: 12px; align-items: baseline; }
.principles b { font-family: var(--font-display); font-weight: 800; color: var(--ink); font-size: 16px; letter-spacing: -0.01em; }
.principles span { font-size: 15.5px; color: var(--ink-2); }
@media (max-width: 760px) { .studio { grid-template-columns: 1fr; } .principles div { grid-template-columns: 1fr; gap: 4px; } }

/* Contact strip */
.contact { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 20px; padding: 32px; border-radius: 18px; background: var(--card); border: 1px solid var(--rule); }
.contact h3 { font-size: 22px; margin-bottom: 6px; }
.contact p { color: var(--ink-2); font-size: 15.5px; }
.contact a.mail { font-family: var(--font-display); font-weight: 800; font-size: clamp(18px, 2.2vw, 22px); letter-spacing: -0.02em; text-decoration: none; border-bottom: 2px solid var(--accent); }

/* ── Footer ─────────────────────────────────────────────────────────────── */
.site-footer { border-top: 1px solid var(--rule); padding: 36px 0 48px; font-size: 14px; color: var(--muted); }
.site-footer .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px 32px; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 6px 22px; }
.site-footer a { text-decoration: none; color: var(--ink-2); }
.site-footer a:hover { color: var(--ink); text-decoration: underline; }
.site-footer .legal { width: 100%; font-size: 13px; }

/* ── Documents (privacy, terms, support) ────────────────────────────────── */
.doc { padding: clamp(40px, 7vw, 80px) 0 clamp(56px, 8vw, 104px); }
.doc-head { max-width: 65ch; margin-bottom: clamp(32px, 5vw, 56px); }
.doc-head h1 { font-size: clamp(34px, 4.6vw, 54px); margin: 14px 0 18px; }
.doc-head .meta { font-size: 14px; color: var(--muted); margin-top: 16px; }
.doc-body { max-width: 65ch; }
.doc-body h2 { font-size: clamp(22px, 2.6vw, 28px); margin: 56px 0 20px; padding-top: 28px; border-top: 1px solid var(--rule); }
.doc-body h2:first-child { margin-top: 0; padding-top: 0; border-top: 0; }
.doc-body ol.clauses { list-style: none; padding: 0; margin: 0; counter-reset: clause; }
.doc-body ol.clauses > li { counter-increment: clause; display: grid; grid-template-columns: 3.2em 1fr; gap: 6px 0; padding: 20px 0; border-top: 1px solid var(--rule); }
.doc-body ol.clauses > li::before { content: counter(clause, decimal-leading-zero); font-family: var(--font-display); font-weight: 800; color: var(--muted); font-variant-numeric: tabular-nums; padding-top: 3px; }
.doc-body ol.clauses h3 { grid-column: 2; font-size: 18px; letter-spacing: -0.01em; }
.doc-body ol.clauses p { grid-column: 2; color: var(--ink-2); font-size: 16px; text-wrap: pretty; }
.doc-body p.note { color: var(--ink-2); }
.doc-nav { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 24px; }
.doc-nav a { font-size: 14px; font-weight: 500; text-decoration: none; padding: 6px 12px; border-radius: 999px; border: 1px solid var(--rule-strong); color: var(--ink-2); }
.doc-nav a:hover { background: var(--sunken); color: var(--ink); }

/* FAQ (support) — native disclosure, no script */
.faq { border-top: 1px solid var(--rule); }
.faq details { border-bottom: 1px solid var(--rule); }
.faq summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 20px; padding: 20px 0; font-family: var(--font-display); font-weight: 800; font-size: 18px; letter-spacing: -0.015em; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-weight: 400; color: var(--muted); font-size: 24px; line-height: 1; flex: none; transition: transform 150ms; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details > p { padding: 0 0 22px; color: var(--ink-2); max-width: 60ch; }
.faq details > p b { font-weight: 600; color: var(--ink); }
.help-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; margin-top: 8px; }
.help-grid > div { padding: 22px; border-radius: 14px; background: var(--card); border: 1px solid var(--rule); }
.help-grid h3 { font-size: 17px; margin-bottom: 8px; }
.help-grid p { font-size: 15px; color: var(--ink-2); }
@media (max-width: 760px) { .help-grid { grid-template-columns: 1fr; } }

/* 404 */
.notfound { min-height: 60vh; display: grid; place-content: center; text-align: left; gap: 16px; padding: 48px 0; }
.notfound h1 { font-size: clamp(36px, 6vw, 72px); }
