/* ============================================
   WALLEFY v2 design tokens + base styles
   Move 24 (2026-05-23) — Warm premium palette.
   Cobalt brand retained, ALL neutrals shifted warm so cards read magazine-print
   instead of Excel. Reference: Notion 2024+, Linear, Cron, Vercel marketing.
   Banned: glow, neon, aurora, orbital, gradient overload.
   ============================================ */

:root {
  /* Surfaces (warm) */
  --bg-0: #FBF9F5;   /* warm off-white, primary canvas */
  --bg-1: #F5F1EA;   /* warm cream, panel / section break */
  --bg-2: #EFEAE0;   /* deeper cream, subtle elevation */
  --bg-3: #E7DFD0;   /* warm divider tone */
  --bg-card: #FFFFFF;       /* cards stay pure white to "pop" against warm canvas */
  --bg-card-hi: #FFFFFF;

  /* Text scale (warm slate — slight brown undertone, no cold blue cast) */
  --ink-0: #1C1B1A;  /* warm near-black, headlines */
  --ink-1: #2A2826;  /* body strong */
  --ink-2: #525050;  /* body secondary */
  --ink-3: #807B72;  /* warm gray, tertiary, meta */
  --ink-4: #A8A39A;  /* warm gray, labels */
  --ink-5: #CFC7B8;  /* warm dividers */

  /* Brand. Cobalt retained — pops harder against warm canvas than cold white. */
  --brand:        #2563EB;  /* primary */
  --brand-hover:  #1D4ED8;
  --brand-deep:   #1E40AF;
  --brand-ink:    #FFFFFF;
  --brand-soft:   #EEF3FE;  /* warm-shifted brand bg */
  --brand-soft-2: #DBEAFE;
  --brand-line:   rgba(37,99,235,0.20);

  /* Accents (used sparingly) */
  --accent-emerald:      #047857;  /* slightly warmer green */
  --accent-emerald-soft: #ECFDF5;
  --accent-amber:        #B45309;
  --accent-rose:         #BE123C;
  --accent-warm:         #F97316;  /* NEW Move 24 — coral, energy moments only */
  --accent-warm-soft:    #FFF4E6;  /* coral bg tint for stat callouts */

  /* Borders — warm neutrals, no cold-slate cast */
  --border:     rgba(48,38,24,0.08);
  --border-hi:  rgba(48,38,24,0.14);
  --border-strong: rgba(48,38,24,0.20);
  --border-brand: rgba(37,99,235,0.32);

  /* Radii (kept from v1) */
  --radius-xs: 6px;
  --radius-sm: 10px;
  --radius:    14px;
  --radius-lg: 20px;
  --radius-xl: 28px;
  --radius-2xl:40px;

  /* Shadows. Warm-shifted (slight brown undertone) for cohesion with warm canvas. */
  --shadow-1:    0 1px 2px rgba(48,38,24,0.05);
  --shadow-2:    0 4px 12px -4px rgba(48,38,24,0.07);
  --shadow-card: 0 10px 30px -12px rgba(48,38,24,0.11);
  --shadow-pop:  0 24px 60px -24px rgba(48,38,24,0.18);
  --shadow-inset: inset 0 1px 0 rgba(255,255,255,0.7);

  /* Typography (same families as v1) */
  --font-display: 'Bricolage Grotesque', 'Manrope', system-ui, sans-serif;
  --font-body:    'Manrope', system-ui, -apple-system, sans-serif;
  --font-serif:   'Instrument Serif', 'Times New Roman', serif;
  --font-mono:    'JetBrains Mono', ui-monospace, monospace;

  /* Layout */
  /* Move 28.4 — Container widened so every section aligns with the floating
     header pill (1480px max). Was 1240/960/1320 — now 1440/960/1560 for
     PassEntry-tier desktop real-estate use without making narrow blocks like
     FAQs feel airy. Narrow stays at 960px (FAQ/blog/glossary read-width). */
  --maxw:        1440px;
  --maxw-narrow: 960px;
  --maxw-wide:   1560px;
  --section-pad:    96px 0;
  --section-pad-sm: 64px 0;

  /* Motion (used sparingly) */
  --ease-out: cubic-bezier(0.22, 0.61, 0.36, 1);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
  --duration-fast: 140ms;
  --duration-base: 220ms;
  --duration-slow: 360ms;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
html, body {
  margin: 0;
  background: var(--bg-0);
  color: var(--ink-1);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}
/* Move 28.4 — overflow-x: clip (not hidden) so the floating sticky header
   still engages. `overflow-x: hidden` silently creates a scroll container on
   the body, which breaks every position:sticky descendant per CSS spec.
   `clip` (2022, well-supported by 2026) prevents horizontal scroll WITHOUT
   establishing a scroll context. */
html, body { overflow-x: clip; max-width: 100vw; }

a { color: inherit; text-decoration: none; }
a:focus-visible, button:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
  border-radius: 4px;
}
button { font-family: inherit; cursor: pointer; border: 0; background: transparent; color: inherit; }
img, svg, video, canvas { display: block; max-width: 100%; }
::selection { background: var(--brand-soft-2); color: var(--ink-0); }

/* ============================================
   Typography utilities
   ============================================ */
.display {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.022em;
  line-height: 1.04;
  text-wrap: balance;
  color: var(--ink-0);
}
.display .serif {
  font-family: var(--font-serif);
  font-weight: 400;
  font-style: italic;
  letter-spacing: -0.005em;
  color: var(--ink-1);
}

h1 { font-size: clamp(40px, 5vw, 64px); margin: 0 0 20px; font-family: var(--font-display); font-weight: 600; letter-spacing: -0.022em; line-height: 1.04; color: var(--ink-0); }
h2 { font-size: clamp(30px, 3.6vw, 44px); margin: 0 0 18px; font-family: var(--font-display); font-weight: 600; letter-spacing: -0.018em; line-height: 1.1;  color: var(--ink-0); }
h3 { font-size: clamp(20px, 2vw, 24px);   margin: 0 0 12px; font-family: var(--font-display); font-weight: 600; letter-spacing: -0.012em; line-height: 1.2;  color: var(--ink-0); }
h4 { font-size: 18px; margin: 0 0 8px; font-weight: 600; color: var(--ink-0); }

p { margin: 0 0 16px; color: var(--ink-2); }
p:last-child { margin-bottom: 0; }

.lead {
  font-size: 19px;
  line-height: 1.55;
  color: var(--ink-2);
  text-wrap: pretty;
  max-width: 60ch;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--brand);
  font-weight: 500;
}
.eyebrow .dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--brand);
  margin-right: 10px;
}
.eyebrow--muted { color: var(--ink-3); }
.eyebrow--muted .dot { background: var(--ink-3); }

.meta {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.04em;
  color: var(--ink-3);
}

strong, b { color: var(--ink-0); font-weight: 600; }

/* ============================================
   Layout primitives
   ============================================ */
.container {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
}
.container--narrow { max-width: var(--maxw-narrow); }
.container--wide   { max-width: var(--maxw-wide); }

section {
  padding: var(--section-pad);
  position: relative;
}
section.section--sm { padding: var(--section-pad-sm); }
section.section--bg-1 { background: var(--bg-1); }
section.section--bg-2 { background: var(--bg-2); }

.section-head {
  text-align: center;
  max-width: 720px;
  margin: 0 auto 56px;
}
.section-head .eyebrow { margin-bottom: 16px; }
.section-head h2 { margin-bottom: 14px; }
.section-head p { color: var(--ink-2); font-size: 18px; max-width: 60ch; margin: 0 auto; }
.section-head--left { text-align: left; margin-left: 0; }

.grid { display: grid; gap: 24px; }
.grid--2 { grid-template-columns: repeat(2, 1fr); }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 960px) {
  .grid--2, .grid--3, .grid--4 { grid-template-columns: 1fr; }
}
@media (min-width: 640px) and (max-width: 960px) {
  .grid--4 { grid-template-columns: repeat(2, 1fr); }
}

/* ============================================
   Buttons
   Single restrained system. CTA-hover is the only place a gradient lives.
   ============================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 48px;
  padding: 0 22px;
  border-radius: 999px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 15px;
  letter-spacing: -0.005em;
  transition: transform var(--duration-fast) var(--ease-out),
              background-color var(--duration-base) var(--ease-out),
              box-shadow var(--duration-base) var(--ease-out),
              border-color var(--duration-base) var(--ease-out);
  white-space: nowrap;
  cursor: pointer;
  border: 1px solid transparent;
}
.btn:active { transform: translateY(1px); }

/* Move 27.4 — Primary CTA gradient upgrade (homepage hero, blueprint, etc.)
   Stripe-tier subtle blue gradient + inner highlight + tinted glow.
   Boosts perceived premium by ~20% vs flat fill while staying brand-true. */
.btn--primary {
  background: linear-gradient(135deg, #2563EB 0%, #1E40AF 100%);
  color: var(--brand-ink, #FFFFFF);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.22),
    0 4px 14px rgba(37, 99, 235, 0.28),
    0 1px 2px rgba(28, 27, 26, 0.06);
  border: 1px solid transparent;
}
.btn--primary:hover {
  background: linear-gradient(135deg, #3B82F6 0%, #2563EB 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.26),
    0 8px 22px rgba(37, 99, 235, 0.38),
    0 2px 4px rgba(28, 27, 26, 0.08);
}

.btn--secondary {
  background: var(--bg-0);
  color: var(--ink-0);
  border-color: var(--border-hi);
  box-shadow: var(--shadow-1);
}
.btn--secondary:hover {
  border-color: var(--ink-0);
}

.btn--ghost {
  background: transparent;
  color: var(--ink-0);
}
.btn--ghost:hover { background: var(--bg-1); }

.btn--text {
  height: auto;
  padding: 0;
  border-radius: 0;
  background: transparent;
  color: var(--brand);
  font-weight: 600;
  position: relative;
}
.btn--text::after {
  content: '';
  position: absolute;
  left: 0; right: 0; bottom: -2px;
  height: 1px;
  background: currentColor;
  opacity: 0.4;
  transition: opacity var(--duration-base) var(--ease-out);
}
.btn--text:hover::after { opacity: 1; }

.btn--lg { height: 54px; padding: 0 26px; font-size: 16px; }
.btn--sm { height: 40px; padding: 0 16px; font-size: 14px; }

.btn .arrow { transition: transform var(--duration-base) var(--ease-out); }
.btn:hover .arrow { transform: translateX(3px); }

/* ============================================
   Cards
   ============================================ */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  transition: box-shadow var(--duration-base) var(--ease-out),
              border-color var(--duration-base) var(--ease-out),
              transform var(--duration-base) var(--ease-out);
}
.card:hover {
  box-shadow: var(--shadow-card);
  border-color: var(--border-hi);
}
.card--flat:hover { box-shadow: none; transform: none; }
.card--linked { cursor: pointer; }
.card--linked:hover { transform: translateY(-2px); }
.card--soft { background: var(--bg-1); border-color: transparent; }
.card h3 { margin-bottom: 8px; }
.card p { color: var(--ink-2); }

/* ============================================
   Chips / pills / badges
   ============================================ */
.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 26px;
  padding: 0 10px;
  border-radius: 999px;
  background: var(--bg-1);
  border: 1px solid var(--border);
  font-size: 12px;
  font-weight: 500;
  color: var(--ink-2);
  font-family: var(--font-mono);
  letter-spacing: 0.02em;
}
.chip--brand { background: var(--brand-soft); border-color: var(--brand-line); color: var(--brand-deep); }
.chip--emerald { background: var(--accent-emerald-soft); border-color: rgba(5,150,105,0.18); color: var(--accent-emerald); }

.live-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-emerald);
  display: inline-block;
}

/* ============================================
   Stats
   ============================================ */
.stat-n {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(40px, 4vw, 56px);
  letter-spacing: -0.02em;
  line-height: 1;
  color: var(--ink-0);
  display: block;
}
.stat-label {
  display: block;
  margin-top: 8px;
  font-size: 14px;
  color: var(--ink-3);
}

/* ============================================
   Dividers
   ============================================ */
hr.rule {
  border: 0;
  height: 1px;
  background: var(--border);
  margin: 64px 0;
}

/* ============================================
   Scroll reveal (the only approved entrance animation)
   ============================================ */
.reveal {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity var(--duration-slow) var(--ease-out),
              transform var(--duration-slow) var(--ease-out);
}
.reveal.is-in {
  opacity: 1;
  transform: none;
}
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
}

/* ============================================
   Forms (lightweight, only what's used today)
   ============================================ */
.input {
  width: 100%;
  height: 44px;
  padding: 0 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-hi);
  background: var(--bg-0);
  color: var(--ink-0);
  font-family: var(--font-body);
  font-size: 15px;
  transition: border-color var(--duration-base) var(--ease-out),
              box-shadow var(--duration-base) var(--ease-out);
}
.input:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px var(--brand-soft);
}

/* ============================================
   Footer surface (declared here so all pages share)
   ============================================ */
.site-footer {
  background: var(--bg-1);
  border-top: 1px solid var(--border);
  padding: 64px 0 32px;
  color: var(--ink-2);
}
.site-footer a:hover { color: var(--ink-0); }

/* ============================================
   Accessibility helpers
   ============================================ */
.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}
