/* ═══════════════════════════════════════════════════════════════════
   Daybook marketing site — design tokens mirrored from the product app.
   Dark matte navy, orange primary, Inter, soft geometry, fast motion.
   ═══════════════════════════════════════════════════════════════════ */

:root {
  /* Themed colors (HSL channels, from the app's dark theme) */
  --background: 222 30% 9%;
  --foreground: 218 20% 92%;
  --card: 222 26% 13%;
  --card-2: 222 24% 16%;
  --primary: 25 95% 55%;
  --primary-fg: 0 0% 100%;
  --muted-fg: 218 14% 58%;
  --border: 222 20% 22%;
  --status-active: 213 58% 52%;
  --status-complete: 152 45% 42%;
  --status-attention: 38 88% 55%;

  /* Constant geometry */
  --radius-card: 24px;
  --radius-button: 16px;
  --radius-input: 18px;

  /* Motion */
  --duration-fast: 150ms;
  --duration-base: 200ms;
  --duration-slow: 250ms;
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);

  --blur-glass: 12px;

  --shadow-1: 0 1px 3px hsl(222 40% 4% / 0.4);
  --shadow-2: 0 4px 12px hsl(222 40% 4% / 0.45);
  --shadow-3: 0 8px 24px hsl(222 40% 4% / 0.5);

  --max-w: 1120px;
}

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

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  background: hsl(var(--background));
  color: hsl(var(--foreground));
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img, svg { max-width: 100%; display: block; }

a { color: hsl(var(--primary)); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3, h4 {
  font-weight: 700;
  line-height: 1.15;
  margin: 0 0 0.5em;
  letter-spacing: -0.02em;
}

h1 { font-size: clamp(2.1rem, 5vw, 3.4rem); }
h2 { font-size: clamp(1.6rem, 3.5vw, 2.3rem); }
h3 { font-size: 1.25rem; }

p { margin: 0 0 1em; }

.muted { color: hsl(var(--muted-fg)); }

.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 24px;
}

/* Accessible focus */
:focus-visible {
  outline: 2px solid hsl(var(--primary));
  outline-offset: 3px;
  border-radius: 4px;
}

/* ── Buttons ─────────────────────────────────────────────────────── */
.btn {
  display: inline-block;
  padding: 14px 26px;
  border-radius: var(--radius-button);
  font-weight: 600;
  font-size: 1rem;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform var(--duration-fast) var(--ease-out),
              background-color var(--duration-base) var(--ease-out),
              border-color var(--duration-base) var(--ease-out),
              box-shadow var(--duration-base) var(--ease-out);
}
.btn:active { transform: scale(0.97); }
.btn:hover { text-decoration: none; }

.btn-primary {
  background: hsl(var(--primary));
  color: hsl(var(--primary-fg));
  box-shadow: 0 0 20px hsl(var(--primary) / 0.25);
}
.btn-primary:hover {
  background: hsl(25 95% 60%);
  box-shadow: 0 0 20px hsl(var(--primary) / 0.4);
}

.btn-ghost {
  background: transparent;
  color: hsl(var(--foreground));
  border-color: hsl(var(--border));
}
.btn-ghost:hover { border-color: hsl(var(--muted-fg)); }

.btn-lg { padding: 16px 32px; font-size: 1.06rem; }

/* ── Sticky glass nav ────────────────────────────────────────────── */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: hsl(var(--background) / 0.75);
  backdrop-filter: blur(var(--blur-glass));
  -webkit-backdrop-filter: blur(var(--blur-glass));
  border-bottom: 1px solid hsl(var(--border) / 0.6);
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  height: 68px;
}
.wordmark {
  font-size: 1.35rem;
  font-weight: 700;
  color: hsl(var(--foreground));
  letter-spacing: -0.02em;
}
.wordmark:hover { text-decoration: none; }
.wordmark .dot { color: hsl(var(--primary)); }

.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.nav-links a {
  color: hsl(var(--muted-fg));
  font-weight: 500;
  font-size: 0.95rem;
  transition: color var(--duration-base) var(--ease-out);
}
.nav-links a:hover { color: hsl(var(--foreground)); text-decoration: none; }

.nav-cta { display: flex; align-items: center; gap: 12px; }
.nav-cta .btn { padding: 10px 20px; font-size: 0.95rem; white-space: nowrap; }

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid hsl(var(--border));
  border-radius: 12px;
  color: hsl(var(--foreground));
  padding: 8px 10px;
  cursor: pointer;
}

/* Mobile drawer */
.mobile-menu {
  display: none;
  border-top: 1px solid hsl(var(--border) / 0.6);
  background: hsl(var(--card));
  padding: 16px 24px 24px;
}
.mobile-menu.open { display: block; }
.mobile-menu a {
  display: block;
  padding: 12px 0;
  color: hsl(var(--foreground));
  font-weight: 500;
  border-bottom: 1px solid hsl(var(--border) / 0.4);
}
.mobile-menu a:hover { text-decoration: none; color: hsl(var(--primary)); }
.mobile-menu .btn { margin-top: 16px; text-align: center; display: block; }

/* ── Hero ────────────────────────────────────────────────────────── */
.hero {
  padding: 88px 0 72px;
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 56px;
  align-items: center;
}
.hero .lede {
  font-size: 1.15rem;
  color: hsl(var(--muted-fg));
  max-width: 34rem;
}
.hero-ctas { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 28px; }
.hero-note { margin-top: 14px; font-size: 0.88rem; color: hsl(var(--muted-fg)); }

/* ── Cards & sections ────────────────────────────────────────────── */
.card {
  background: hsl(var(--card));
  border: 1px solid hsl(var(--border) / 0.7);
  border-radius: var(--radius-card);
  padding: 28px;
  box-shadow: var(--shadow-1);
  transition: transform var(--duration-base) var(--ease-out),
              box-shadow var(--duration-base) var(--ease-out);
}
.card-lift:hover { transform: translateY(-2px); box-shadow: var(--shadow-2); }

.section { padding: 72px 0; }
.section-tight { padding: 48px 0; }
.section-head { max-width: 44rem; margin-bottom: 40px; }
.kicker {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: hsl(var(--primary));
  margin-bottom: 10px;
}

/* Problem strip */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }

/* Feature rows */
.feature-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: center;
  padding: 44px 0;
}
.feature-row.flip .feature-copy { order: 2; }
.feature-copy h3 { font-size: 1.5rem; }
.feature-copy ul { padding-left: 1.2em; color: hsl(var(--muted-fg)); margin: 0; }
.feature-copy li { margin-bottom: 6px; }

/* ── Stylized product mockups (pure CSS, generic data) ───────────── */
.mock {
  background: hsl(var(--card));
  border: 1px solid hsl(var(--border));
  border-radius: var(--radius-card);
  padding: 20px;
  box-shadow: var(--shadow-3);
  font-size: 0.82rem;
}
.mock-titlebar {
  display: flex; align-items: center; gap: 8px;
  margin-bottom: 16px;
}
.mock-titlebar .t { font-weight: 600; font-size: 0.95rem; }
.mock-chip {
  margin-left: auto;
  background: hsl(var(--primary) / 0.15);
  color: hsl(var(--primary));
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 0.72rem;
}
.mock-row {
  display: flex; align-items: center; gap: 10px;
  background: hsl(var(--card-2));
  border: 1px solid hsl(var(--border) / 0.6);
  border-radius: var(--radius-input);
  padding: 12px 14px;
  margin-bottom: 10px;
}
.mock-row:last-child { margin-bottom: 0; }
.mock-row .grow { flex: 1; min-width: 0; }
.mock-row .name { font-weight: 600; color: hsl(var(--foreground)); }
.mock-row .sub { color: hsl(var(--muted-fg)); font-size: 0.75rem; }
.mock-row .amt { font-weight: 700; color: hsl(var(--foreground)); }
.pill {
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 600;
  white-space: nowrap;
}
.pill-active    { background: hsl(var(--status-active) / 0.18);    color: hsl(var(--status-active)); }
.pill-complete  { background: hsl(var(--status-complete) / 0.18);  color: hsl(var(--status-complete)); }
.pill-attention { background: hsl(var(--status-attention) / 0.16); color: hsl(var(--status-attention)); }
.pill-primary   { background: hsl(var(--primary) / 0.16);          color: hsl(var(--primary)); }
.dot { width: 8px; height: 8px; border-radius: 50%; flex: none; }
.dot-active { background: hsl(var(--status-active)); }
.dot-complete { background: hsl(var(--status-complete)); }
.dot-attention { background: hsl(var(--status-attention)); }

.mock-kpis { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 12px; }
.mock-kpi {
  background: hsl(var(--card-2));
  border: 1px solid hsl(var(--border) / 0.6);
  border-radius: var(--radius-input);
  padding: 12px;
}
.mock-kpi .label { font-size: 0.65rem; letter-spacing: 0.06em; text-transform: uppercase; color: hsl(var(--muted-fg)); }
.mock-kpi .value { font-size: 1.25rem; font-weight: 700; margin-top: 2px; }
.mock-kpi .value.orange { color: hsl(var(--primary)); }

.mock-offline {
  display: flex; align-items: center; gap: 8px;
  background: hsl(var(--status-attention) / 0.12);
  border: 1px solid hsl(var(--status-attention) / 0.3);
  color: hsl(var(--status-attention));
  border-radius: var(--radius-input);
  padding: 10px 14px;
  font-weight: 600;
  font-size: 0.78rem;
  margin-bottom: 12px;
}

/* Trades */
.trade-tile { text-align: center; padding: 32px 20px; }
.trade-tile .icon { font-size: 1.8rem; margin-bottom: 10px; }
.trade-tile h3 { margin-bottom: 4px; font-size: 1.05rem; }
.trade-tile p { font-size: 0.85rem; margin: 0; }

/* Steps */
.step-num {
  width: 40px; height: 40px;
  display: flex; align-items: center; justify-content: center;
  background: hsl(var(--primary) / 0.15);
  color: hsl(var(--primary));
  font-weight: 700;
  border-radius: 12px;
  margin-bottom: 14px;
}

/* Trust strip */
.trust {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px;
  background: hsl(var(--card));
  border: 1px solid hsl(var(--border) / 0.7);
  border-radius: var(--radius-card);
  padding: 32px;
}
.trust h3 { font-size: 1rem; margin-bottom: 6px; }
.trust p { font-size: 0.88rem; margin: 0; }

/* ── Pricing ─────────────────────────────────────────────────────── */
.price-card {
  max-width: 460px;
  margin: 0 auto;
  text-align: center;
  padding: 40px 36px;
  border: 1px solid hsl(var(--primary) / 0.4);
  box-shadow: 0 0 20px hsl(var(--primary) / 0.12);
}
.price-amount { font-size: 3rem; font-weight: 700; letter-spacing: -0.03em; }
.price-amount .per { font-size: 1rem; font-weight: 500; color: hsl(var(--muted-fg)); }
.price-card ul {
  list-style: none; padding: 0; margin: 24px 0;
  text-align: left;
}
.price-card li {
  padding: 9px 0 9px 30px;
  position: relative;
  color: hsl(var(--muted-fg));
  border-bottom: 1px solid hsl(var(--border) / 0.4);
}
.price-card li::before {
  content: "✓";
  position: absolute; left: 4px;
  color: hsl(var(--primary));
  font-weight: 700;
}

/* ── FAQ accordion ───────────────────────────────────────────────── */
.faq-item {
  border: 1px solid hsl(var(--border) / 0.7);
  border-radius: var(--radius-input);
  background: hsl(var(--card));
  margin-bottom: 12px;
  overflow: hidden;
}
.faq-q {
  width: 100%;
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
  background: none; border: none;
  color: hsl(var(--foreground));
  font: inherit; font-weight: 600;
  text-align: left;
  padding: 18px 22px;
  cursor: pointer;
}
.faq-q .chev { transition: transform var(--duration-base) var(--ease-out); color: hsl(var(--muted-fg)); flex: none; }
.faq-item.open .chev { transform: rotate(180deg); }
.faq-a {
  display: none;
  padding: 0 22px 18px;
  color: hsl(var(--muted-fg));
}
.faq-item.open .faq-a { display: block; }

/* ── CTA band & footer ───────────────────────────────────────────── */
.cta-band {
  text-align: center;
  padding: 80px 24px;
  background: linear-gradient(180deg, hsl(var(--card)) 0%, hsl(var(--background)) 100%);
  border-top: 1px solid hsl(var(--border) / 0.5);
}

.footer {
  border-top: 1px solid hsl(var(--border) / 0.5);
  padding: 48px 0 40px;
  font-size: 0.88rem;
  color: hsl(var(--muted-fg));
}
.footer-grid {
  display: flex; justify-content: space-between; gap: 32px; flex-wrap: wrap;
}
.footer a { color: hsl(var(--muted-fg)); }
.footer a:hover { color: hsl(var(--foreground)); text-decoration: none; }
.footer-links { display: flex; gap: 22px; flex-wrap: wrap; }

/* ── Scroll entrance (JS adds .in via IntersectionObserver) ──────── */
.reveal {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity var(--duration-slow) var(--ease-out),
              transform var(--duration-slow) var(--ease-out);
}
.reveal.in { opacity: 1; transform: none; }
/* Stagger: cap at 8 children, +30ms each */
.stagger > *:nth-child(1) { transition-delay: 0ms; }
.stagger > *:nth-child(2) { transition-delay: 30ms; }
.stagger > *:nth-child(3) { transition-delay: 60ms; }
.stagger > *:nth-child(4) { transition-delay: 90ms; }
.stagger > *:nth-child(5) { transition-delay: 120ms; }
.stagger > *:nth-child(6) { transition-delay: 150ms; }
.stagger > *:nth-child(7) { transition-delay: 180ms; }
.stagger > *:nth-child(n+8) { transition-delay: 210ms; }

/* No-JS / reduced motion: never hide content */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
  .reveal { opacity: 1; transform: none; }
}

/* Legal pages */
.legal { max-width: 46rem; padding: 64px 0; }
.legal h1 { font-size: 2rem; }
.legal h2 { font-size: 1.25rem; margin-top: 2em; }
.legal p, .legal li { color: hsl(var(--muted-fg)); font-size: 0.95rem; }
.draft-banner {
  background: hsl(var(--status-attention) / 0.12);
  border: 1px solid hsl(var(--status-attention) / 0.35);
  color: hsl(var(--status-attention));
  border-radius: var(--radius-input);
  padding: 12px 18px;
  font-weight: 600;
  font-size: 0.88rem;
  margin-bottom: 32px;
}

/* 404 */
.notfound {
  min-height: 60vh;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  text-align: center;
  padding: 48px 24px;
}
.notfound .code {
  font-size: 5rem; font-weight: 700;
  color: hsl(var(--primary));
  letter-spacing: -0.04em;
  line-height: 1;
}

/* ── Responsive: tablet 768 / phone 375 ──────────────────────────── */
@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; gap: 40px; padding: 56px 0 48px; }
  .feature-row { grid-template-columns: 1fr; gap: 28px; padding: 32px 0; }
  .feature-row.flip .feature-copy { order: 0; }
  .grid-3, .trust { grid-template-columns: 1fr 1fr; }
  .grid-4 { grid-template-columns: 1fr 1fr; }
  .nav-links, .nav-cta .btn-ghost { display: none; }
  .nav-toggle { display: block; }
}

@media (max-width: 560px) {
  .grid-3, .grid-4, .trust { grid-template-columns: 1fr; }
  .section { padding: 52px 0; }
  .hero-ctas .btn { width: 100%; text-align: center; }
  .nav-cta .btn-primary { padding: 9px 14px; font-size: 0.85rem; }
  .mock-kpis { grid-template-columns: repeat(3, 1fr); gap: 6px; }
  .mock-kpi { padding: 8px; }
  .mock-kpi .value { font-size: 1rem; }
}
