/* BackupLatte landing — palette and type match the app UI (packages/web). */

:root {
  --text: #151515;
  --text-2: #3c4640;
  --muted: #5a675e;
  --bg: #f5f6f4;
  --card: #ffffff;
  --border: #d8ded8;
  --border-2: #dce2dc;
  --btn-border: #b9c4bb;
  --accent: #17834f;
  --accent-border: #147a48;
  --accent-hover: #126b41;
  --brown: #5b3a29;
  --latte: #c69365;
  --cream: #f4e4d0;
  --font: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, "DejaVu Sans Mono", monospace;
}

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

body {
  margin: 0;
  min-width: 320px;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, p, ul, ol { margin: 0; }
a { color: var(--accent); }
a:hover { color: var(--accent-hover); }
img, svg { display: block; }

.container { width: 100%; max-width: 1120px; margin: 0 auto; padding: 0 16px; }
.visually-hidden { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

h1 { font-size: clamp(36px, 4.6vw, 56px); line-height: 1.08; font-weight: 800; letter-spacing: -0.03em; }
h2 { font-size: clamp(28px, 3vw, 36px); line-height: 1.15; font-weight: 800; letter-spacing: -0.02em; }
h3 { font-size: 18px; font-weight: 700; letter-spacing: -0.01em; }
.eyebrow { font-family: var(--mono); font-size: 13px; color: var(--brown); letter-spacing: 0.02em; margin-bottom: 8px; }
.muted { color: var(--muted); }
.small { font-size: 13.5px; }
.mono-note { font-family: var(--mono); font-size: 13px; color: var(--muted); }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  height: 40px; padding: 0 16px; border-radius: 8px;
  font-size: 15px; font-weight: 600; text-decoration: none; white-space: nowrap;
  border: 1px solid var(--btn-border); background: var(--card); color: var(--text);
  transition: background-color .15s ease, border-color .15s ease;
}
.btn:hover { background: #f0f3f0; color: var(--text); }
.btn-primary { background: var(--accent); border-color: var(--accent-border); color: #fff; }
.btn-primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); color: #fff; }
.btn-lg { height: 52px; padding: 0 26px; font-size: 17px; border-radius: 10px; }
.btn-sm { height: 34px; padding: 0 14px; font-size: 14px; }
.btn:focus-visible, .nav-link:focus-visible, .text-link:focus-visible, summary:focus-visible, a:focus-visible {
  outline: 2px solid var(--accent); outline-offset: 3px;
}
.text-link { color: var(--text); font-weight: 500; text-decoration: none; }
.text-link:hover { color: var(--accent-hover); text-decoration: underline; }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 10;
  background: rgba(245, 246, 244, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 64px; gap: 16px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--text); text-decoration: none; font-weight: 700; font-size: 18px; letter-spacing: -0.01em; }
.nav { display: flex; align-items: center; gap: 24px; }
.nav-link { color: var(--text); text-decoration: none; font-size: 15px; font-weight: 500; }
.nav-link:hover { color: var(--accent-hover); }
.label-short { display: none; }

/* Hero */
.hero { padding: 72px 0 48px; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 55fr) minmax(0, 45fr); gap: 48px; align-items: center; }
.hero-copy { display: flex; flex-direction: column; gap: 22px; }
.hero-copy .eyebrow { margin-bottom: 0; }
.lede { font-size: 19px; line-height: 1.55; color: var(--text-2); max-width: 540px; }
.hero-cta { display: flex; align-items: center; gap: 24px; flex-wrap: wrap; margin-top: 6px; }
.micro { font-size: 13.5px; color: var(--muted); }
.hero-visual { display: flex; flex-direction: column; align-items: center; gap: 8px; container-type: inline-size; }

/* ASCII latte cup: 60 columns x 25 rows, two overlaid text layers.
   Width is in ch so it tracks the actual monospace advance; height is
   rows x line-height. Fixed box = no reflow when a frame is redrawn.
   The font size is derived from the *column* width (container query units),
   so the cup shrinks with its grid cell on tablet widths instead of pushing
   the page wider; 38 (not 36) leaves a 2ch margin for wider mono glyphs. */
.latte {
  position: relative;
  font-size: clamp(7px, calc(100cqw / 38), 14px);
  width: 60ch;
  max-width: 100%;
  height: calc(25 * 1.154em);
  font-family: var(--mono);
  line-height: 1.154;
  overflow: hidden;
}
.latte-layer {
  position: absolute; inset: 0; margin: 0;
  font: inherit; line-height: inherit; white-space: pre;
  pointer-events: none; user-select: none;
}
.latte-body { color: var(--brown); }
.latte-milk { color: var(--latte); }
.latte-caption { font-family: var(--mono); font-size: 12.5px; color: #8a6a55; }

/* Cards */
.cards-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px; }
.card { display: flex; flex-direction: column; gap: 12px; padding: 28px; background: var(--card); border: 1px solid var(--border); border-radius: 12px; list-style: none; }
.card h3 { font-size: 20px; }
.card p { font-size: 15.5px; line-height: 1.55; color: var(--text-2); }
.icon { width: 28px; height: 28px; fill: none; stroke: var(--brown); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.icon-sm { width: 18px; height: 18px; fill: none; stroke: var(--brown); stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.icon-ok { stroke: var(--accent); stroke-width: 2.4; }
.icon-muted { stroke: #8a938d; stroke-width: 2.4; }

.why { padding: 24px 0 64px; }

/* Sections */
.band { background: var(--card); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.how { padding: 56px 0 72px; }
.steps { list-style: none; padding: 0; margin: 36px 0 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 28px; }
.steps li { display: flex; flex-direction: column; gap: 10px; }
.steps p { font-size: 15px; line-height: 1.55; color: var(--text-2); }
.step-head { display: flex; align-items: center; gap: 10px; }
.step-num { display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 30px; border-radius: 999px; background: var(--cream); color: var(--brown); font-family: var(--mono); font-size: 13px; }

/* Dashboard preview */
.dash { margin: 40px 0 0; padding: 24px; background: var(--bg); border: 1px solid var(--border); border-radius: 14px; display: flex; flex-direction: column; gap: 16px; }
.dash-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.dash-kicker { font-size: 12px; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: 0.06em; }
.dash-title { display: flex; align-items: center; gap: 10px; margin: 4px 0; }
.dash-title h3 { font-size: 20px; }
.dash-meta { font-size: 14px; color: var(--muted); }
.dash-fake-btn { cursor: default; }
.badge { display: inline-flex; align-items: center; height: 26px; padding: 0 8px; border-radius: 6px; font-size: 13px; font-weight: 800; }
.badge-ok { background: #ddf4e5; color: #16643d; }
.badge-run { background: #fff1b8; color: #6f5700; }
.dash-table { background: var(--card); border: 1px solid var(--border); border-radius: 10px; overflow: hidden; }
.dash-row { display: grid; grid-template-columns: 130px 120px 1fr 100px 210px; align-items: center; gap: 8px; padding: 10px 16px; font-size: 14px; border-bottom: 1px solid var(--border-2); }
.dash-row:last-child { border-bottom: 0; }
.dash-row-head { color: var(--muted); font-size: 13px; font-weight: 600; }
.dash-actions { display: flex; gap: 8px; }
.chip { display: inline-flex; align-items: center; height: 30px; padding: 0 10px; border: 1px solid var(--btn-border); border-radius: 6px; background: var(--card); font-size: 13px; font-weight: 600; }

/* Scope */
.scope { padding: 72px 0; }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 28px; }
.section-head-center { flex-direction: column; align-items: center; text-align: center; gap: 10px; }
.section-head-center .eyebrow { margin-bottom: 0; }
.lede-sm { font-size: 17px; color: var(--text-2); }
.scope-table { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); background: var(--card); border: 1px solid var(--border); border-radius: 12px; overflow: hidden; }
.scope-col { display: flex; flex-direction: column; gap: 14px; padding: 28px; border-right: 1px solid var(--border); }
.scope-col:last-child { border-right: 0; }
.scope-col h3 { display: flex; align-items: center; gap: 8px; font-size: 16px; }
.scope-col p { font-size: 15px; line-height: 1.7; color: var(--text-2); }
.scope-col-muted h3, .scope-col-muted p { color: var(--muted); }

/* Pricing */
.pricing { padding: 72px 0 80px; }
.plans { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; margin-top: 36px; }
.plan { position: relative; display: flex; flex-direction: column; gap: 18px; padding: 28px; background: var(--bg); border: 1px solid var(--border); border-radius: 12px; }
.plan-featured { background: var(--card); border: 2px solid var(--accent); }
.plan-tag { position: absolute; top: -13px; left: 24px; display: inline-flex; align-items: center; height: 26px; padding: 0 10px; border-radius: 999px; background: var(--accent); color: #fff; font-size: 12.5px; font-weight: 700; }
.plan-members { font-size: 14px; color: var(--muted); margin-top: -14px; }
.plan-price { font-size: 36px; font-weight: 800; letter-spacing: -0.02em; line-height: 1.1; }
.plan-price span { font-size: 15px; font-weight: 500; color: var(--muted); letter-spacing: 0; }
.plan-price-text { font-size: 28px; }
.plan-list { list-style: none; padding: 0; display: flex; flex-direction: column; gap: 8px; font-size: 14.5px; color: var(--text-2); }
.plan .btn { margin-top: auto; height: 44px; }
.pricing-note { margin-top: 32px; text-align: center; font-size: 14px; color: var(--muted); }

/* Trust */
.trust { padding: 72px 0 56px; }
.trust-list { list-style: none; padding: 0; margin-top: 28px; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px; }
.trust-list .card { padding: 24px; gap: 10px; }
.trust-list .icon { width: 24px; height: 24px; }
.trust-list p { font-size: 15px; }
.trust-list a { font-weight: 600; }

/* FAQ */
.faq { padding: 24px 0 80px; }
.faq-grid { display: grid; grid-template-columns: 320px minmax(0, 1fr); gap: 64px; align-items: start; }
.faq-intro p.muted { margin-top: 8px; font-size: 15px; }
.faq-intro a { font-weight: 600; }
.faq-list { background: var(--card); border: 1px solid var(--border); border-radius: 12px; overflow: hidden; }
.faq-list details { border-bottom: 1px solid var(--border-2); }
.faq-list details:last-child { border-bottom: 0; }
.faq-list summary {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  min-height: 64px; padding: 18px 24px; cursor: pointer; list-style: none;
  font-size: 17px; font-weight: 600;
}
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary::after { content: "+"; font-family: var(--mono); font-size: 18px; color: var(--brown); }
.faq-list details[open] summary::after { content: "−"; }
.faq-list summary:hover { background: #fafbfa; }
.faq-list details p { padding: 0 24px 20px; font-size: 15.5px; line-height: 1.6; color: var(--text-2); max-width: 640px; }

/* Final CTA */
.final { padding: 0 0 56px; }
.final-card { display: flex; flex-direction: column; align-items: center; gap: 22px; padding: 64px 32px; text-align: center; background: var(--brown); color: var(--cream); border-radius: 16px; }
.final-card h2 { font-size: clamp(26px, 3.2vw, 38px); max-width: 760px; }
.final-note { font-family: var(--mono); font-size: 12.5px; color: var(--latte); }

/* Footer */
.site-footer { border-top: 1px solid var(--border); padding: 28px 0 40px; font-size: 14px; color: var(--muted); }
.footer-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.footer-links { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; }
.footer-links a { color: var(--muted); text-decoration: none; }
.footer-links a:hover { color: var(--text); text-decoration: underline; }

/* Tablet */
@media (max-width: 1024px) {
  .cards-3, .scope-table, .plans { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .scope-col { border-right: 0; border-bottom: 1px solid var(--border); }
  .scope-col:last-child { border-bottom: 0; grid-column: 1 / -1; }
  .steps, .trust-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .faq-grid { grid-template-columns: 1fr; gap: 24px; }
}

/* Phone */
@media (max-width: 760px) {
  .header-inner { min-height: 60px; height: auto; gap: 8px; padding-block: 12px; flex-wrap: wrap; }
  .nav { gap: 8px; }
  .nav .nav-link { display: none; }
  .nav .btn { height: 36px; padding: 0 10px; font-size: 14px; }
  .nav .label-full { display: none; }
  .nav .label-short { display: inline; }
  .hero { padding: 40px 0 24px; }
  .hero-grid { grid-template-columns: 1fr; gap: 32px; }
  .hero-copy { gap: 18px; }
  .lede { font-size: 16.5px; }
  .hero-cta { flex-direction: column; align-items: stretch; gap: 14px; }
  .hero-cta .btn { width: 100%; }
  .hero-cta .text-link { text-align: center; }
  .micro { text-align: center; }
  .cards-3, .scope-table, .plans, .steps, .trust-list { grid-template-columns: 1fr; }
  .card, .scope-col, .plan { padding: 20px; }
  .why { padding: 8px 0 40px; }
  .how, .scope, .pricing, .trust { padding: 40px 0 48px; }
  .steps { gap: 20px; margin-top: 24px; }
  .section-head { flex-direction: column; align-items: flex-start; gap: 6px; }
  .dash { padding: 16px; }
  .dash-head { flex-direction: column; align-items: flex-start; }
  .dash-fake-btn { display: none; }
  .dash-row { grid-template-columns: 96px 1fr auto; font-size: 13px; padding: 10px 12px; }
  .dash-row > :nth-child(2), .dash-row > :nth-child(5) { display: none; }
  .plan-tag { top: -12px; left: 16px; }
  .final-card { padding: 36px 20px; gap: 18px; }
  .final-card .btn { width: 100%; }
  .footer-inner { flex-direction: column; align-items: flex-start; }
}
