/* ============================================================
   Caller ID Faker — Design System
   Ported verbatim from design bundle caller-id-faker-renewal.
   Scoped by being loaded only under home/landing-layout.jade;
   all legacy pages keep their own stylesheets untouched.
   ============================================================ */

:root {
  /* Light mode */
  --bg: #ffffff;
  --bg-soft: #f8fafc;
  --bg-muted: #f1f5f9;
  --surface: #ffffff;
  --border: #e2e8f0;
  --border-strong: #cbd5e1;
  --fg: #0f172a;
  --fg-muted: #475569;
  --fg-subtle: #64748b;

  /* Accent — sky by default (matches the inline pre-paint script and the
     Alpine state default). Keeps the rendered accent coherent if the
     pre-paint script can't write `data-accent` (e.g. `localStorage` throws
     in Safari private mode); the [data-accent="..."] overrides below still
     win when the attribute is set. */
  --accent: #0ea5e9;
  --accent-hover: #0284c7;
  --accent-soft: #e0f2fe;
  --accent-soft-2: #f0f9ff;
  --accent-ink: #075985;

  /* Status */
  --success: #10b981;
  --danger: #dc2626;
  --warning: #f59e0b;

  /* Radii */
  --r-sm: 8px;
  --r-md: 12px;
  --r-lg: 16px;
  --r-xl: 24px;
  --r-pill: 999px;

  /* Shadows */
  --shadow-xs: 0 1px 2px rgba(15, 23, 42, 0.04);
  --shadow-sm: 0 1px 3px rgba(15, 23, 42, 0.06), 0 1px 2px rgba(15, 23, 42, 0.04);
  --shadow-md: 0 6px 16px -4px rgba(15, 23, 42, 0.08), 0 3px 6px -2px rgba(15, 23, 42, 0.04);
  --shadow-lg: 0 20px 40px -12px rgba(15, 23, 42, 0.12), 0 8px 16px -8px rgba(15, 23, 42, 0.06);

  /* Type */
  --font-sans: 'Geist', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --font-mono: 'Geist Mono', 'SF Mono', Menlo, Consolas, monospace;
}

[data-theme="dark"] {
  --bg: #0b0f14;
  --bg-soft: #0f1520;
  --bg-muted: #141b28;
  --surface: #111826;
  --border: #1f2a3d;
  --border-strong: #2f3a50;
  --fg: #f1f5f9;
  --fg-muted: #94a3b8;
  --fg-subtle: #64748b;

  --accent-soft: rgba(14, 165, 233, 0.2);
  --accent-soft-2: rgba(14, 165, 233, 0.1);
  --accent-ink: #7dd3fc;

  --shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.3);
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.3), 0 1px 2px rgba(0, 0, 0, 0.2);
  --shadow-md: 0 6px 16px -4px rgba(0, 0, 0, 0.4), 0 3px 6px -2px rgba(0, 0, 0, 0.3);
  --shadow-lg: 0 20px 40px -12px rgba(0, 0, 0, 0.5), 0 8px 16px -8px rgba(0, 0, 0, 0.3);
}

/* Accent variants */
[data-accent="emerald"] { --accent: #10b981; --accent-hover: #059669; --accent-soft: #d1fae5; --accent-soft-2: #ecfdf5; --accent-ink: #065f46; }
[data-accent="indigo"]  { --accent: #6366f1; --accent-hover: #4f46e5; --accent-soft: #e0e7ff; --accent-soft-2: #eef2ff; --accent-ink: #3730a3; }
[data-accent="amber"]   { --accent: #f59e0b; --accent-hover: #d97706; --accent-soft: #fef3c7; --accent-soft-2: #fffbeb; --accent-ink: #92400e; }
[data-accent="coral"]   { --accent: #f43f5e; --accent-hover: #e11d48; --accent-soft: #ffe4e6; --accent-soft-2: #fff1f2; --accent-ink: #9f1239; }
[data-accent="sky"]     { --accent: #0ea5e9; --accent-hover: #0284c7; --accent-soft: #e0f2fe; --accent-soft-2: #f0f9ff; --accent-ink: #075985; }

[data-theme="dark"][data-accent="emerald"] { --accent-soft: rgba(16,185,129,0.16); --accent-soft-2: rgba(16,185,129,0.08); --accent-ink: #6ee7b7; }
[data-theme="dark"][data-accent="indigo"]  { --accent-soft: rgba(99,102,241,0.2); --accent-soft-2: rgba(99,102,241,0.1); --accent-ink: #a5b4fc; }
[data-theme="dark"][data-accent="amber"]   { --accent-soft: rgba(245,158,11,0.2); --accent-soft-2: rgba(245,158,11,0.1); --accent-ink: #fcd34d; }
[data-theme="dark"][data-accent="coral"]   { --accent-soft: rgba(244,63,94,0.2); --accent-soft-2: rgba(244,63,94,0.1); --accent-ink: #fda4af; }
[data-theme="dark"][data-accent="sky"]     { --accent-soft: rgba(14,165,233,0.2); --accent-soft-2: rgba(14,165,233,0.1); --accent-ink: #7dd3fc; }

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
}

/* Keep section headings clear of the sticky nav when the browser jumps
   to a hash target. */
#how, #pricing, #faq { scroll-margin-top: 80px; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  min-height: 100vh;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
  color: inherit;
  font-size: inherit;
}

input, textarea, select {
  font-family: inherit;
  font-size: inherit;
  color: inherit;
}

/* ============================================================
   Common pieces
   ============================================================ */

.mono { font-family: var(--font-mono); font-feature-settings: "tnum"; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: var(--r-pill);
  font-weight: 500;
  font-size: 15px;
  transition: all 0.15s ease;
  border: 1px solid transparent;
  white-space: nowrap;
}
.btn-primary {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 1px 2px rgba(0,0,0,0.08);
}
.btn-primary:hover { background: var(--accent-hover); }
.btn-secondary {
  background: var(--surface);
  color: var(--fg);
  border-color: var(--border-strong);
}
.btn-secondary:hover { background: var(--bg-soft); }
.btn-ghost { color: var(--fg-muted); }
.btn-ghost:hover { color: var(--fg); background: var(--bg-muted); }
.btn-lg { padding: 14px 24px; font-size: 16px; }
.btn-block { width: 100%; }

.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: var(--r-pill);
  font-size: 12px;
  font-weight: 500;
  background: var(--accent-soft);
  color: var(--accent-ink);
  border: 1px solid transparent;
}
.pill-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-xs);
}

.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.field label {
  font-size: 13px;
  font-weight: 500;
  color: var(--fg-muted);
}
.field input, .field select, .field textarea {
  padding: 11px 14px;
  border: 1px solid var(--border-strong);
  border-radius: var(--r-md);
  background: var(--surface);
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.field input:focus, .field select:focus, .field textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

.bg-dots {
  background-image: radial-gradient(circle, var(--border) 1px, transparent 1px);
  background-size: 20px 20px;
}
.bg-grid {
  background-image:
    linear-gradient(var(--border) 1px, transparent 1px),
    linear-gradient(90deg, var(--border) 1px, transparent 1px);
  background-size: 40px 40px;
}

.divider {
  height: 1px;
  background: var(--border);
  width: 100%;
}

.ring-accent {
  box-shadow: 0 0 0 3px var(--accent-soft);
}

::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 5px; }
::-webkit-scrollbar-thumb:hover { background: var(--border-strong); }

/* ============================================================
   Landing-page layout
   Classes are prefixed `l-` or named after their section so they
   do not collide with legacy global styles if ever co-mounted.
   ============================================================ */

.l-page {
  background: var(--bg);
  min-height: 100vh;
}

.l-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 40px;
  border-bottom: 1px solid var(--border);
  background: color-mix(in srgb, var(--bg) 85%, transparent);
  backdrop-filter: blur(12px);
  position: sticky;
  top: 0;
  z-index: 10;
}
.l-nav__links {
  display: flex;
  align-items: center;
  gap: 28px;
}
.l-nav__links a {
  font-size: 14px;
  color: var(--fg-muted);
  font-weight: 500;
}
.l-nav__links a:hover { color: var(--fg); }
.l-nav__actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* Theme toggle button — icon-only, lives in the nav */
.l-theme-toggle {
  width: 36px;
  height: 36px;
  border-radius: var(--r-pill);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--fg-muted);
  transition: background 0.15s, color 0.15s;
}
.l-theme-toggle:hover {
  background: var(--bg-muted);
  color: var(--fg);
}
.l-theme-toggle .fa-solid { font-size: 18px; }

/* Logo */
.l-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.l-logo__mark {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}
.l-logo__mark img { width: 100%; height: 100%; display: block; }
.l-logo__name {
  font-weight: 600;
  font-size: 17px;
  letter-spacing: -0.01em;
}

/* Hero (split) */
.l-hero {
  padding: 80px 40px 100px;
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 60px;
  align-items: center;
}
.l-hero__copy h1 {
  font-size: 68px;
  line-height: 1.03;
  margin: 0;
  letter-spacing: -0.03em;
  font-weight: 600;
}
.l-hero__accent-text {
  background: linear-gradient(120deg, var(--accent), var(--accent-hover));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}
.l-hero__lede {
  font-size: 19px;
  line-height: 1.55;
  color: var(--fg-muted);
  margin-top: 24px;
  max-width: 520px;
}
.l-hero__ctas {
  display: flex;
  gap: 12px;
  margin-top: 32px;
}
.l-hero__trust {
  margin-top: 28px;
  display: flex;
  gap: 22px;
  font-size: 13px;
  color: var(--fg-subtle);
  flex-wrap: wrap;
}
.l-hero__visual {
  position: relative;
  display: flex;
  justify-content: center;
}
.l-hero__backdrop {
  position: absolute;
  inset: -40px -20px;
  background: radial-gradient(circle at 50% 40%, var(--accent-soft) 0%, transparent 60%);
  z-index: 0;
}
.l-hero__phone-wrap {
  position: relative;
  z-index: 1;
}
.l-hero__chip {
  position: absolute;
  top: 80px;
  left: -30px;
  z-index: 2;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 12px 14px;
  box-shadow: var(--shadow-md);
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
}
.l-hero__chip-avatar {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent-ink);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
}

/* Phone mockup */
.l-phone {
  width: 280px;
  height: 560px;
  background: #000;
  border-radius: 44px;
  padding: 10px;
  box-shadow: 0 30px 60px -20px rgba(0,0,0,0.3), 0 0 0 1px rgba(0,0,0,0.1);
  position: relative;
}
.l-phone__notch {
  position: absolute;
  top: 18px;
  left: 50%;
  transform: translateX(-50%);
  width: 110px;
  height: 28px;
  background: #000;
  border-radius: 20px;
  z-index: 2;
}
.l-phone__screen {
  width: 100%;
  height: 100%;
  border-radius: 36px;
  background: linear-gradient(180deg, #1e293b 0%, #0f172a 100%);
  overflow: hidden;
  position: relative;
  color: #fff;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 70px 20px 28px;
}
.l-phone__label {
  font-size: 13px;
  opacity: 0.7;
  letter-spacing: 0.5px;
}
.l-phone__avatar {
  width: 110px;
  height: 110px;
  border-radius: 50%;
  background: linear-gradient(135deg, #64748b, #334155);
  margin-top: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 42px;
  font-weight: 600;
  border: 3px solid rgba(255,255,255,0.1);
}
.l-phone__name {
  font-size: 26px;
  font-weight: 600;
  margin-top: 24px;
  letter-spacing: -0.01em;
}
.l-phone__number {
  font-size: 14px;
  opacity: 0.7;
  margin-top: 4px;
}
.l-phone__sub {
  font-size: 12px;
  opacity: 0.5;
  margin-top: 2px;
}
.l-phone__actions {
  margin-top: auto;
  display: flex;
  gap: 60px;
  align-items: center;
}
.l-phone__btn {
  width: 62px;
  height: 62px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}
.l-phone__btn--decline { background: #dc2626; }
.l-phone__btn--accept  {
  background: #10b981;
  box-shadow: 0 0 0 8px rgba(16,185,129,0.2), 0 0 0 16px rgba(16,185,129,0.08);
}
.l-phone__btn .fa-solid { font-size: 28px; color: #fff; }
.l-phone__btn--decline .fa-solid { transform: rotate(135deg); }

/* Shared section eyebrow */
.l-eyebrow {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--fg-subtle);
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-bottom: 12px;
}
.l-section-head {
  text-align: center;
  margin-bottom: 56px;
}
.l-section-head h2 {
  font-size: 44px;
  letter-spacing: -0.025em;
  margin: 0;
  font-weight: 600;
}
.l-section-head p {
  color: var(--fg-muted);
  font-size: 17px;
  margin-top: 16px;
}

/* How it works */
.l-how {
  padding: 96px 40px;
  max-width: 1200px;
  margin: 0 auto;
}
.l-how__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.l-step {
  padding: 32px;
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.l-step__num {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--fg-subtle);
  letter-spacing: 1px;
}
.l-step__icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: var(--accent-soft);
  color: var(--accent-ink);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  font-weight: 600;
}
.l-step__title {
  font-size: 22px;
  font-weight: 600;
  letter-spacing: -0.01em;
}
.l-step__desc {
  color: var(--fg-muted);
  font-size: 15px;
  line-height: 1.55;
}

/* Pricing */
.l-pricing {
  padding: 96px 40px;
  background: var(--bg-soft);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.l-pricing__inner {
  max-width: 1100px;
  margin: 0 auto;
}
.l-pricing__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.l-tier {
  padding: 32px;
  position: relative;
}
.l-tier--popular {
  border: 2px solid var(--accent);
  box-shadow: var(--shadow-md);
}
.l-tier__badge {
  position: absolute;
  top: -12px;
  left: 24px;
  background: var(--accent);
  color: #fff;
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
}
.l-tier__minutes {
  font-size: 38px;
  font-weight: 600;
  letter-spacing: -0.02em;
}
.l-tier__minutes-suffix {
  font-size: 18px;
  color: var(--fg-muted);
  font-weight: 500;
}
.l-tier__price {
  font-size: 32px;
  margin-top: 12px;
  font-weight: 500;
}
.l-tier__per {
  color: var(--fg-subtle);
  font-size: 13px;
  margin-top: 4px;
}
.l-tier__cta { margin-top: 24px; }
.l-tier__perks {
  margin-top: 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 14px;
  color: var(--fg-muted);
}
.l-pricing__footnote {
  text-align: center;
  margin-top: 32px;
  font-size: 13px;
  color: var(--fg-subtle);
}

/* FAQ */
.l-faq {
  padding: 96px 40px;
  max-width: 900px;
  margin: 0 auto;
}
.l-faq__list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.l-faq__item {
  transition: border-color 0.15s, background 0.15s;
  overflow: hidden;
}
.l-faq__item.is-open {
  border-color: var(--accent);
  background: var(--accent-soft-2);
}
/* The row is a real <button> so it handles Enter/Space natively and
   announces as a disclosure widget via aria-expanded/aria-controls. */
.l-faq__row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  width: 100%;
  padding: 20px 24px;
  background: transparent;
  border: 0;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
  border-radius: inherit;
}
.l-faq__row:focus { outline: none; }
.l-faq__row:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px var(--accent-soft);
}
.l-faq__q {
  font-size: 17px;
  font-weight: 500;
  letter-spacing: -0.005em;
}
.l-faq__indicator {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--bg-muted);
  color: var(--fg-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  flex-shrink: 0;
  transition: transform 0.2s, background 0.15s, color 0.15s;
}
.l-faq__item.is-open .l-faq__indicator {
  background: var(--accent);
  color: #fff;
  transform: rotate(45deg);
}
.l-faq__a {
  padding: 0 24px 20px;
  color: var(--fg-muted);
  font-size: 15px;
  line-height: 1.6;
}

/* Footer */
.l-footer {
  border-top: 1px solid var(--border);
  padding: 48px 40px 32px;
  background: var(--bg-soft);
}
.l-footer__grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 48px;
  max-width: 1200px;
  margin: 0 auto;
}
.l-footer__blurb {
  color: var(--fg-muted);
  font-size: 14px;
  margin-top: 16px;
  max-width: 280px;
}
.l-footer__platforms {
  margin-top: 16px;
  display: flex;
  gap: 10px;
}
.l-footer__platform {
  padding: 8px 12px;
  border: 1px solid var(--border);
  border-radius: 10px;
  font-size: 12px;
  color: var(--fg-muted);
  font-family: var(--font-mono);
}
.l-footer__col-title {
  font-weight: 600;
  font-size: 14px;
  margin-bottom: 14px;
}
.l-footer__col-items {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.l-footer__col-items a {
  font-size: 14px;
  color: var(--fg-muted);
}
.l-footer__col-items a:hover { color: var(--fg); }
.l-footer__bar {
  max-width: 1200px;
  margin: 48px auto 0;
  padding-top: 24px;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  font-size: 13px;
  color: var(--fg-subtle);
}
.l-footer__disclaimer {
  font-size: 12px;
}

/* Long-form legal/document content (terms, etc.) */
.l-legal {
  max-width: 820px;
  margin: 0 auto;
  padding: 64px 40px 96px;
}
.l-legal h1 {
  font-size: 44px;
  letter-spacing: -0.025em;
  font-weight: 600;
  margin: 8px 0 16px;
}
.l-legal h2 {
  font-size: 22px;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin: 40px 0 12px;
  color: var(--fg);
}
.l-legal p {
  color: var(--fg-muted);
  font-size: 16px;
  line-height: 1.7;
  margin: 0 0 16px;
}
.l-legal ul {
  color: var(--fg-muted);
  padding-left: 22px;
  margin: 0 0 16px;
  line-height: 1.7;
}
.l-legal li { margin-bottom: 8px; }
.l-legal b, .l-legal strong { color: var(--fg); font-weight: 600; }
.l-legal a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.l-legal a:hover { color: var(--accent-hover); }
.l-legal__meta {
  font-family: var(--font-mono);
  color: var(--fg-subtle);
  font-size: 13px;
  margin: 0 0 32px;
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
}
.l-legal__contact {
  margin-top: 48px;
  padding: 24px 28px;
}
.l-legal__contact-title {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--fg-subtle);
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-bottom: 12px;
}
.l-legal__address {
  font-style: normal;
  color: var(--fg-muted);
  line-height: 1.7;
}

/* ============================================================
   Responsive
   ============================================================ */

@media (max-width: 900px) {
  .l-nav { padding: 14px 20px; }
  .l-nav__links { display: none; }

  .l-hero {
    padding: 48px 20px 64px;
    grid-template-columns: 1fr;
    gap: 40px;
  }
  .l-hero__copy h1 { font-size: 44px; }
  .l-hero__chip { left: 0; top: 40px; }

  .l-how, .l-faq { padding: 64px 20px; }
  .l-how__grid { grid-template-columns: 1fr; }

  .l-pricing { padding: 64px 20px; }
  .l-pricing__grid { grid-template-columns: 1fr; }

  .l-section-head h2 { font-size: 32px; }

  .l-footer { padding: 40px 20px 24px; }
  .l-footer__grid { grid-template-columns: 1fr 1fr; gap: 32px; }
  .l-footer__bar { flex-direction: column; align-items: flex-start; }

  .l-legal { padding: 48px 20px 64px; }
  .l-legal h1 { font-size: 32px; }
  .l-legal h2 { font-size: 20px; margin-top: 32px; }
}

@media (max-width: 520px) {
  .l-hero__ctas { flex-direction: column; align-items: stretch; }
  .l-hero__ctas .btn { justify-content: center; }
  .l-footer__grid { grid-template-columns: 1fr; }
}

/* Alpine flicker guard — elements with `x-cloak` stay hidden
   until Alpine initialises them. */
[x-cloak] { display: none !important; }
