/* memfill.app — single stylesheet (CSP default-src 'self' bans inline styles).
   Brand (branding.md, locked 2026-08-05): Ink #143642 · Fill green #2FA36B ·
   Flag amber #F5A524 · Paper #F7F5F0 · Inter only · voice: calm competence.

   Layout map:
     header.site-header ─ nav
     main
       ├─ .hero (product) / .family-hero (root)  2-col grid → 1-col mobile
       ├─ .steps          Learn → Fill → Review strip
       ├─ .proof-band     ink background, text-only Queen's proof
       ├─ .privacy-block  "Your data. Your browser."
       └─ .pricing        variant-A table + buy CTA
     legal pages: bare markdown elements, styled via `main > *` prose rules
     footer.site-footer
*/

@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/inter-latin-400-normal.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('/fonts/inter-latin-600-normal.woff2') format('woff2');
}

:root {
  --ink: #143642;
  --green: #2FA36B;
  --green-dark: #268a5a;
  --amber: #F5A524;
  --paper: #F7F5F0;
  --white: #ffffff;
  --line: #e3ded4;
  --ink-60: #4d6672;
  --radius: 10px;
  --col: 72rem;
  --prose: 46rem;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  font-weight: 400;
  line-height: 1.6;
  color: var(--ink);
  background: var(--paper);
}

img { max-width: 100%; display: block; }
a { color: var(--green-dark); }
a:focus-visible, button:focus-visible {
  outline: 3px solid var(--amber);
  outline-offset: 2px;
}
h1, h2, h3 { font-weight: 600; line-height: 1.2; text-wrap: balance; }

/* ---------- header ---------- */

.site-header {
  background: var(--paper);
  border-bottom: 1px solid var(--line);
}
.nav {
  max-width: var(--col);
  margin: 0 auto;
  padding: 1rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}
.brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  text-decoration: none;
  color: var(--ink);
}
.brand-name { font-weight: 600; font-size: 1.15rem; letter-spacing: -0.01em; }
.nav-links { display: flex; align-items: center; gap: 1.4rem; flex-wrap: wrap; }
.nav-links a {
  color: var(--ink);
  text-decoration: none;
  font-size: 0.95rem;
}
.nav-links a:hover { color: var(--green-dark); }
.nav-cta {
  background: var(--ink);
  color: var(--white) !important;
  padding: 0.5rem 1rem;
  border-radius: var(--radius);
  font-weight: 600;
}
.nav-cta:hover { background: #1d4a5a; }

/* ---------- product hero ---------- */

.hero {
  max-width: var(--col);
  margin: 0 auto;
  padding: 3.5rem 1.5rem 3rem;
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: 3rem;
  align-items: center;
}
.hero-copy h1 {
  font-size: clamp(2.2rem, 5vw, 3.4rem);
  letter-spacing: -0.02em;
}
.hero-sub {
  font-size: clamp(1.4rem, 3vw, 2rem);
  font-weight: 600;
  line-height: 1.25;
  margin-top: 0.35rem;
}
.hero-sub em { font-style: normal; color: var(--green); }
.hero-lede {
  margin-top: 1.2rem;
  font-size: 1.05rem;
  color: var(--ink-60);
  max-width: 34rem;
}
.trust-chips {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, max-content));
  gap: 1.2rem 1.8rem;
  margin-top: 1.8rem;
}
@media (max-width: 560px) {
  .trust-chips { grid-template-columns: 1fr; }
}
.trust-chips li { display: grid; gap: 0.1rem; }
.chip-title { font-weight: 600; font-size: 0.95rem; }
.chip-sub { font-size: 0.85rem; color: var(--ink-60); }

/* ---------- simulated extension panel (mock data only) ---------- */

.panel-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 14px 40px rgba(20, 54, 66, 0.12);
  overflow: hidden;
}
.panel-head {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--ink);
  color: var(--white);
  padding: 0.7rem 1rem;
}
.panel-icon { filter: brightness(0) invert(1); }
.panel-title { font-weight: 600; font-size: 0.95rem; flex: 1; }
.panel-badge {
  background: var(--green);
  color: var(--white);
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.2rem 0.6rem;
  border-radius: 999px;
  white-space: nowrap;
}
.panel-table { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
.panel-caption {
  text-align: left;
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--ink-60);
  padding: 0.8rem 1rem 0.2rem;
}
.panel-table th, .panel-table td {
  padding: 0.55rem 1rem;
  border-top: 1px solid var(--line);
  text-align: left;
}
.panel-table th { font-weight: 400; color: var(--ink-60); width: 45%; }
.cell-ok { color: var(--green); font-weight: 600; text-align: right; }
.cell-pending { color: var(--ink-60); text-align: right; }
.panel-foot {
  font-size: 0.8rem;
  color: var(--ink-60);
  padding: 0.7rem 1rem;
  border-top: 1px solid var(--line);
  background: var(--paper);
}

/* ---------- steps strip ---------- */

.steps { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); background: var(--white); }
.steps-list {
  list-style: none;
  max-width: var(--col);
  margin: 0 auto;
  padding: 2rem 1.5rem;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}
.steps-list li { display: flex; gap: 0.9rem; align-items: flex-start; }
.step-num {
  flex: none;
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  background: var(--ink);
  color: var(--white);
  font-weight: 600;
  display: grid;
  place-items: center;
}
.step-body h2 { font-size: 1.05rem; }
.step-body p { font-size: 0.9rem; color: var(--ink-60); margin-top: 0.2rem; }

/* ---------- Queen's proof band (text only — no crest, ever) ---------- */

.proof-band { background: var(--ink); color: var(--white); }
.proof-inner { max-width: var(--col); margin: 0 auto; padding: 2.5rem 1.5rem; }
.proof-inner h2 { font-size: 1.5rem; }
.proof-inner p { margin-top: 0.7rem; max-width: 52rem; color: #d7e2e7; }
.proof-disclaimer { font-size: 0.8rem; color: #9fb4bd; }

/* ---------- privacy block ---------- */

.privacy-block { background: var(--paper); }
.privacy-inner { max-width: var(--col); margin: 0 auto; padding: 3rem 1.5rem; }
.privacy-inner h2 { font-size: 1.6rem; }
.privacy-lede { color: var(--green-dark); font-weight: 600; margin-top: 0.3rem; }
.privacy-list { list-style: none; margin-top: 1.2rem; display: grid; gap: 0.6rem; max-width: 40rem; }
.privacy-list li { padding-left: 1.6rem; position: relative; }
.privacy-list li::before { content: '✓'; position: absolute; left: 0; color: var(--green); font-weight: 600; }
.privacy-more { margin-top: 1.2rem; font-weight: 600; }

/* ---------- pricing (variant-A table) ---------- */

.pricing { background: var(--white); border-top: 1px solid var(--line); }
.pricing-inner { max-width: 46rem; margin: 0 auto; padding: 3rem 1.5rem 3.5rem; }
.pricing-inner > h2 {
  background: var(--ink);
  color: var(--white);
  text-align: center;
  font-size: 1.2rem;
  padding: 0.8rem;
  border-radius: var(--radius) var(--radius) 0 0;
}
.pricing-table {
  width: 100%;
  border-collapse: collapse;
  border: 1px solid var(--line);
  border-top: none;
  background: var(--white);
}
.pricing-table th, .pricing-table td {
  padding: 1rem 1.2rem;
  border-top: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}
.pricing-table tr:first-child th, .pricing-table tr:first-child td { border-top: none; }
.plan-name { display: block; font-weight: 600; }
.plan-sub { display: block; font-size: 0.85rem; color: var(--ink-60); font-weight: 400; margin-top: 0.15rem; max-width: 26rem; }
.price { text-align: right; white-space: nowrap; }
.price-num { font-size: 1.6rem; font-weight: 600; color: var(--green-dark); }
.price-per { color: var(--ink-60); font-size: 0.9rem; }

.buy-cta { margin-top: 1.4rem; text-align: center; }
.btn {
  display: inline-block;
  text-decoration: none;
  font-weight: 600;
  border-radius: var(--radius);
  padding: 0.85rem 2.2rem;
}
.btn-buy { background: var(--green); color: var(--white); font-size: 1.05rem; }
.btn-buy:hover { background: var(--green-dark); }
.buy-note { font-size: 0.85rem; color: var(--ink-60); margin-top: 0.6rem; }
.pricing-fine { font-size: 0.8rem; color: var(--ink-60); margin-top: 1.6rem; }

/* ---------- family root ---------- */

.family-hero { text-align: center; }
.family-inner { max-width: var(--prose); margin: 0 auto; padding: 4rem 1.5rem 2rem; }
.family-mark { margin: 0 auto 1.2rem; }
.family-hero h1 { font-size: clamp(2.4rem, 6vw, 3.2rem); letter-spacing: -0.02em; }
.family-line { margin-top: 0.8rem; font-size: 1.1rem; color: var(--ink-60); }

.family-featured .family-inner { padding: 1rem 1.5rem 4rem; }
.product-card {
  display: grid;
  gap: 0.4rem;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.6rem;
  text-decoration: none;
  color: var(--ink);
  text-align: left;
  box-shadow: 0 8px 24px rgba(20, 54, 66, 0.08);
}
.product-card:hover { border-color: var(--green); }
.product-kicker {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--amber);
}
.product-name { font-size: 1.3rem; font-weight: 600; }
.product-desc { color: var(--ink-60); font-size: 0.95rem; }
.product-link { color: var(--green-dark); font-weight: 600; margin-top: 0.4rem; }

/* ---------- legal / EULA prose (bare markdown elements) ----------
   Legal pages arrive as bare h1/h2/p/ul from marked with no wrapper (sync is
   a pure copy), so bare children of <main> get prose styling. Product pages
   are built from <section> blocks, which these rules don't touch. */

main > h1, main > h2, main > h3, main > p, main > ul, main > ol,
main > table, main > blockquote, main > hr {
  max-width: var(--prose);
  margin-left: auto;
  margin-right: auto;
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}
main > h1 { margin-top: 3rem; font-size: 2rem; }
main > h2 { margin-top: 2.2rem; font-size: 1.35rem; }
main > h3 { margin-top: 1.6rem; font-size: 1.1rem; }
main > p, main > ul, main > ol { margin-top: 0.9rem; }
main > ul, main > ol { padding-left: 3rem; }
main > blockquote {
  margin-top: 1rem;
  border-left: 4px solid var(--amber);
  color: var(--ink-60);
}
main > hr { border: none; border-top: 1px solid var(--line); margin-top: 2rem; }
main > p:last-child { margin-bottom: 3rem; }

/* ---------- 404 ---------- */

.notfound { text-align: center; padding: 5rem 1.5rem; }
.notfound h1 { font-size: 2.2rem; }
.notfound p { margin-top: 0.8rem; color: var(--ink-60); }
.notfound a { font-weight: 600; }

/* ---------- footer ---------- */

.site-footer { background: var(--ink); color: #d7e2e7; margin-top: 0; }
.footer-inner {
  max-width: var(--col);
  margin: 0 auto;
  padding: 2.5rem 1.5rem 1rem;
  display: flex;
  justify-content: space-between;
  gap: 2rem;
  flex-wrap: wrap;
}
.footer-brand .brand-name { color: var(--white); }
.footer-tag { font-size: 0.85rem; color: #9fb4bd; margin-top: 0.3rem; }
.footer-links { display: flex; gap: 1.4rem; flex-wrap: wrap; align-items: center; }
.footer-links a { color: #d7e2e7; text-decoration: none; font-size: 0.9rem; }
.footer-links a:hover { color: var(--white); text-decoration: underline; }
.footer-fine {
  max-width: var(--col);
  margin: 0 auto;
  padding: 0 1.5rem 2rem;
  font-size: 0.78rem;
  color: #9fb4bd;
}

/* ---------- responsive ---------- */

@media (max-width: 860px) {
  .hero { grid-template-columns: 1fr; gap: 2rem; padding-top: 2.5rem; }
  .steps-list { grid-template-columns: 1fr; gap: 1.2rem; }
}

/* ---------- draft-not-reviewed banner (legal pages only) ---------- */
main > blockquote.draft-notice {
  background: #fdf3e2;
  padding: 0.9rem 1.5rem;
  margin-top: 2rem;
  font-size: 0.95rem;
  color: var(--ink);
}
