/* Recoverly — shared styles. Light theme, indigo accent. Mobile-first responsive. */
:root {
  --accent: #4F46E5;
  --accent-dark: #4338CA;
  --accent-soft: #EEF2FF;
  --ink: #111827;
  --muted: #6B7280;
  --faint: #9CA3AF;
  --bg: #FFFFFF;
  --bg-soft: #F9FAFB;
  --border: #E5E7EB;
  --success: #059669;
  --success-soft: #ECFDF5;
  --warning: #D97706;
  --warning-soft: #FFFBEB;
  --danger: #DC2626;
  --danger-soft: #FEF2F2;
  --radius: 12px;
  --shadow: 0 1px 3px rgba(17, 24, 39, 0.08), 0 4px 16px rgba(17, 24, 39, 0.06);
  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

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

.container { max-width: 1100px; margin: 0 auto; padding: 0 20px; }

/* ---------- Nav ---------- */
.site-nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
.nav-inner {
  max-width: 1100px; margin: 0 auto; padding: 14px 20px;
  display: flex; align-items: center; justify-content: space-between;
}
.logo { font-weight: 800; font-size: 1.35rem; color: var(--ink); letter-spacing: -0.02em; }
.logo span { color: var(--accent); }
.logo:hover { text-decoration: none; }
.nav-links { display: flex; gap: 28px; align-items: center; }
.nav-links a { color: var(--muted); font-weight: 500; font-size: 0.95rem; }
.nav-links a:hover { color: var(--ink); text-decoration: none; }
.nav-toggle { display: none; background: none; border: 0; font-size: 1.5rem; cursor: pointer; color: var(--ink); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block; font-weight: 600; font-size: 1rem;
  padding: 13px 26px; border-radius: 10px; border: 1px solid transparent;
  cursor: pointer; transition: transform 0.06s ease, box-shadow 0.15s ease;
  text-align: center;
}
.btn:hover { text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--accent); color: #fff; box-shadow: 0 4px 14px rgba(79, 70, 229, 0.35); }
.btn-primary:hover { background: var(--accent-dark); color: #fff; }
.btn-ghost { background: #fff; color: var(--ink); border-color: var(--border); }
.btn-ghost:hover { border-color: var(--faint); }
.btn-sm { padding: 9px 18px; font-size: 0.9rem; }
.btn-block { display: block; width: 100%; }

/* ---------- Hero ---------- */
.hero { padding: 84px 0 60px; text-align: center; background: linear-gradient(180deg, var(--accent-soft) 0%, #fff 70%); }
.hero h1 { font-size: clamp(2.1rem, 5vw, 3.4rem); font-weight: 800; letter-spacing: -0.03em; line-height: 1.12; max-width: 780px; margin: 0 auto 18px; }
.hero h1 .hl { color: var(--accent); }
.hero p.sub { font-size: 1.15rem; color: var(--muted); max-width: 640px; margin: 0 auto 32px; }
.hero-ctas { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }
.hero-note { margin-top: 18px; font-size: 0.88rem; color: var(--faint); }

/* ---------- Stat band ---------- */
.stat-band { background: var(--ink); color: #fff; padding: 44px 0; }
.stat-band .row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; text-align: center; }
.stat-band .num { font-size: clamp(1.8rem, 4vw, 2.6rem); font-weight: 800; color: #fff; letter-spacing: -0.02em; }
.stat-band .num em { font-style: normal; color: #A5B4FC; }
.stat-band .lbl { color: #9CA3AF; font-size: 0.92rem; margin-top: 6px; }

/* ---------- Sections ---------- */
.section { padding: 72px 0; }
.section.alt { background: var(--bg-soft); }
.section h2 { font-size: clamp(1.5rem, 3.4vw, 2.1rem); font-weight: 800; letter-spacing: -0.02em; text-align: center; margin-bottom: 12px; }
.section .lede { text-align: center; color: var(--muted); max-width: 640px; margin: 0 auto 40px; }

/* ---------- Calculator ---------- */
.calc {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 32px; max-width: 720px; margin: 0 auto;
  display: grid; grid-template-columns: 1fr 1fr; gap: 28px;
}
.calc label { display: block; font-weight: 600; font-size: 0.9rem; margin-bottom: 8px; }
.calc input[type="number"], .calc input[type="range"] { width: 100%; }
.calc input[type="number"] {
  padding: 12px 14px; border: 1px solid var(--border); border-radius: 8px;
  font-size: 1.05rem; font-family: var(--font);
}
.calc input[type="number"]:focus { outline: 2px solid var(--accent); border-color: var(--accent); }
.calc .hint { font-size: 0.82rem; color: var(--faint); margin-top: 6px; }
.calc-output { background: var(--accent-soft); border-radius: 10px; padding: 24px; display: flex; flex-direction: column; justify-content: center; gap: 16px; }
.calc-row .k { font-size: 0.85rem; color: var(--muted); font-weight: 500; }
.calc-row .v { font-size: 1.7rem; font-weight: 800; letter-spacing: -0.02em; }
.calc-row .v.accent { color: var(--accent); }

/* ---------- Steps ---------- */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.step { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 28px; box-shadow: var(--shadow); }
.step .n {
  width: 40px; height: 40px; border-radius: 50%; background: var(--accent-soft);
  color: var(--accent); font-weight: 800; display: flex; align-items: center; justify-content: center;
  margin-bottom: 16px; font-size: 1.1rem;
}
.step h3 { font-size: 1.1rem; margin-bottom: 8px; }
.step p { color: var(--muted); font-size: 0.95rem; }

/* ---------- Honest note ---------- */
.honest {
  border: 1px dashed var(--border); border-radius: var(--radius);
  padding: 24px 28px; max-width: 720px; margin: 0 auto; background: #fff;
  color: var(--muted); font-size: 0.95rem;
}
.honest strong { color: var(--ink); }

/* ---------- Pricing teaser / cards ---------- */
.pricing-grid { display: grid; grid-template-columns: 1fr; gap: 24px; max-width: 460px; margin: 0 auto; }
.price-card { background: #fff; border: 2px solid var(--accent); border-radius: 16px; padding: 36px; box-shadow: var(--shadow); text-align: center; position: relative; }
.price-card .badge {
  position: absolute; top: -14px; left: 50%; transform: translateX(-50%);
  background: var(--accent); color: #fff; font-size: 0.78rem; font-weight: 700;
  padding: 4px 14px; border-radius: 999px; letter-spacing: 0.04em; text-transform: uppercase;
}
.price-card .amount { font-size: 3rem; font-weight: 800; letter-spacing: -0.03em; }
.price-card .amount small { font-size: 1rem; font-weight: 500; color: var(--muted); }
.price-card ul { list-style: none; text-align: left; margin: 24px 0; }
.price-card li { padding: 8px 0; border-bottom: 1px solid var(--bg-soft); font-size: 0.95rem; }
.price-card li:last-child { border-bottom: 0; }
.price-card li::before { content: "✓"; color: var(--success); font-weight: 800; margin-right: 10px; }

/* ---------- Comparison table ---------- */
.table-wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: var(--radius); background: #fff; box-shadow: var(--shadow); }
table.cmp { width: 100%; border-collapse: collapse; min-width: 640px; }
table.cmp th, table.cmp td { padding: 14px 18px; text-align: left; font-size: 0.93rem; border-bottom: 1px solid var(--border); }
table.cmp thead th { background: var(--bg-soft); font-weight: 700; }
table.cmp tbody tr:last-child td { border-bottom: 0; }
table.cmp td.us { background: var(--accent-soft); font-weight: 700; }
table.cmp th.us { background: var(--accent-soft); }

/* ---------- Footer ---------- */
footer { border-top: 1px solid var(--border); padding: 40px 0; color: var(--muted); font-size: 0.9rem; }
footer .container { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 16px; }
footer nav { display: flex; gap: 20px; }
footer nav a { color: var(--muted); }

/* ---------- App shell ---------- */
.app-shell { display: flex; min-height: 100vh; }
.sidebar {
  width: 240px; flex-shrink: 0; background: var(--ink); color: #D1D5DB;
  padding: 24px 16px; position: sticky; top: 0; height: 100vh;
  display: flex; flex-direction: column; gap: 4px;
}
.sidebar .logo { color: #fff; margin-bottom: 28px; padding: 0 8px; }
.sidebar a.nav-item {
  display: block; padding: 10px 12px; border-radius: 8px; color: #D1D5DB;
  font-size: 0.93rem; font-weight: 500;
}
.sidebar a.nav-item:hover { background: rgba(255,255,255,0.08); text-decoration: none; color: #fff; }
.sidebar a.nav-item.active { background: var(--accent); color: #fff; }
.sidebar .side-foot { margin-top: auto; padding: 12px 8px 0; font-size: 0.8rem; color: #6B7280; border-top: 1px solid rgba(255,255,255,0.1); }
.main { flex: 1; padding: 32px; max-width: 1080px; min-width: 0; }
.main h1.page { font-size: 1.7rem; font-weight: 800; letter-spacing: -0.02em; margin-bottom: 6px; }
.main p.page-sub { color: var(--muted); margin-bottom: 28px; }
.demo-pill {
  display: inline-block; font-size: 0.75rem; font-weight: 700; letter-spacing: 0.05em; text-transform: uppercase;
  background: var(--warning-soft); color: var(--warning); border: 1px solid #FDE68A;
  padding: 4px 12px; border-radius: 999px; margin-bottom: 16px;
}

/* ---------- Dashboard stat cards ---------- */
.stat-cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 28px; }
.stat-card { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); }
.stat-card .k { font-size: 0.82rem; color: var(--muted); font-weight: 500; margin-bottom: 6px; }
.stat-card .v { font-size: 1.6rem; font-weight: 800; letter-spacing: -0.02em; }
.stat-card .d { font-size: 0.8rem; margin-top: 4px; }
.stat-card .d.up { color: var(--success); }

.panel { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); padding: 24px; margin-bottom: 28px; }
.panel h2 { font-size: 1.1rem; font-weight: 700; margin-bottom: 16px; text-align: left; }

.pill { display: inline-block; font-size: 0.78rem; font-weight: 600; padding: 3px 10px; border-radius: 999px; }
.pill.ok { background: var(--success-soft); color: var(--success); }
.pill.warn { background: var(--warning-soft); color: var(--warning); }
.pill.bad { background: var(--danger-soft); color: var(--danger); }
.pill.info { background: var(--accent-soft); color: var(--accent); }

.feed { list-style: none; }
.feed li { padding: 12px 0; border-bottom: 1px solid var(--bg-soft); font-size: 0.93rem; display: flex; gap: 12px; align-items: flex-start; }
.feed li:last-child { border-bottom: 0; }
.feed .dot { width: 9px; height: 9px; border-radius: 50%; margin-top: 7px; flex-shrink: 0; }
.feed .dot.g { background: var(--success); } .feed .dot.a { background: var(--warning); } .feed .dot.b { background: var(--accent); }
.feed time { color: var(--faint); font-size: 0.82rem; margin-left: auto; white-space: nowrap; }

/* ---------- Sequence builder ---------- */
.timeline { display: flex; flex-direction: column; gap: 20px; }
.email-card { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.email-head { display: flex; align-items: center; gap: 14px; padding: 16px 20px; background: var(--bg-soft); border-bottom: 1px solid var(--border); flex-wrap: wrap; }
.email-head .day { font-weight: 800; font-size: 0.85rem; background: var(--ink); color: #fff; border-radius: 8px; padding: 4px 10px; }
.email-head .title { font-weight: 700; flex: 1; min-width: 140px; }
.email-body { padding: 20px; display: grid; gap: 14px; }
.field label { display: block; font-weight: 600; font-size: 0.88rem; margin-bottom: 6px; }
.field input[type="text"], .field textarea, .field input[type="email"], .field input[type="number"],
.field input[type="date"], .field select {
  width: 100%; padding: 11px 13px; border: 1px solid var(--border); border-radius: 8px;
  font-family: var(--font); font-size: 0.94rem; color: var(--ink); background: #fff;
}
.field textarea { min-height: 130px; resize: vertical; line-height: 1.55; }
.field input:focus, .field textarea:focus, .field select:focus { outline: 2px solid var(--accent); border-color: var(--accent); }
.form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 14px; }
.sub-row { display: flex; align-items: center; gap: 12px; padding: 14px 4px; border-bottom: 1px solid var(--border); }
.sub-row:last-child { border-bottom: none; }
.sub-row .grow { flex: 1; min-width: 0; }
.sub-row .nm { font-weight: 700; }
.sub-row .meta { font-size: 0.85rem; color: var(--muted); }
.sub-row .amt { font-weight: 700; white-space: nowrap; }
.renew-soon { color: #B45309; font-weight: 600; }
.empty-note { color: var(--muted); padding: 24px 4px; text-align: center; }
.vars { font-size: 0.8rem; color: var(--faint); }
.vars code { background: var(--bg-soft); border: 1px solid var(--border); border-radius: 4px; padding: 1px 6px; font-size: 0.78rem; color: var(--muted); }

.switch { position: relative; display: inline-block; width: 46px; height: 26px; flex-shrink: 0; }
.switch input { opacity: 0; width: 0; height: 0; }
.slider { position: absolute; inset: 0; cursor: pointer; background: #D1D5DB; border-radius: 999px; transition: 0.2s; }
.slider::before { content: ""; position: absolute; height: 20px; width: 20px; left: 3px; bottom: 3px; background: #fff; border-radius: 50%; transition: 0.2s; }
.switch input:checked + .slider { background: var(--accent); }
.switch input:checked + .slider::before { transform: translateX(20px); }
.email-card.off { opacity: 0.55; }

/* ---------- Card update page ---------- */
.card-page { min-height: 100vh; display: flex; align-items: center; justify-content: center; background: var(--bg-soft); padding: 24px; }
.card-box { background: #fff; border-radius: 16px; box-shadow: var(--shadow); padding: 40px; max-width: 440px; width: 100%; }
.card-box .brand { display: flex; align-items: center; gap: 10px; margin-bottom: 24px; }
.card-box .brand .mark { width: 36px; height: 36px; border-radius: 10px; background: var(--accent); color: #fff; font-weight: 800; display: flex; align-items: center; justify-content: center; }
.card-box h1 { font-size: 1.4rem; font-weight: 800; letter-spacing: -0.02em; margin-bottom: 8px; }
.card-box p.lede { color: var(--muted); font-size: 0.94rem; margin-bottom: 24px; }
.card-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.secure-note { display: flex; gap: 8px; align-items: center; justify-content: center; margin-top: 18px; font-size: 0.82rem; color: var(--faint); }
.success-box { text-align: center; padding: 20px 0; }
.success-box .check {
  width: 64px; height: 64px; border-radius: 50%; background: var(--success-soft); color: var(--success);
  font-size: 2rem; font-weight: 800; display: flex; align-items: center; justify-content: center; margin: 0 auto 18px;
}

/* ---------- Modal ---------- */
.modal-backdrop {
  position: fixed; inset: 0; background: rgba(17, 24, 39, 0.55); z-index: 100;
  display: none; align-items: center; justify-content: center; padding: 20px;
}
.modal-backdrop.open { display: flex; }
.modal { background: #fff; border-radius: 16px; padding: 36px; max-width: 440px; width: 100%; box-shadow: var(--shadow); position: relative; }
.modal h3 { font-size: 1.3rem; font-weight: 800; margin-bottom: 10px; letter-spacing: -0.02em; }
.modal p { color: var(--muted); font-size: 0.94rem; margin-bottom: 20px; }
.modal .close { position: absolute; top: 14px; right: 16px; background: none; border: 0; font-size: 1.4rem; cursor: pointer; color: var(--faint); }

/* ---------- Articles ---------- */
.article { max-width: 720px; margin: 0 auto; }
.article h1 { font-size: clamp(1.7rem, 4vw, 2.4rem); font-weight: 800; letter-spacing: -0.03em; line-height: 1.15; margin-bottom: 12px; }
.article .meta { color: var(--faint); font-size: 0.88rem; margin-bottom: 28px; }
.article h2 { font-size: 1.35rem; font-weight: 700; margin: 36px 0 12px; text-align: left; letter-spacing: -0.01em; }
.article p { margin-bottom: 16px; color: #374151; }
.article ul, .article ol { margin: 0 0 16px 22px; color: #374151; }
.article li { margin-bottom: 8px; }
.article blockquote { border-left: 3px solid var(--accent); padding: 4px 0 4px 18px; margin: 24px 0; color: var(--muted); font-style: italic; }
.article-cta { background: var(--accent-soft); border-radius: var(--radius); padding: 28px; margin: 40px 0; text-align: center; }
.article-cta h3 { margin-bottom: 8px; }
.article-cta p { color: var(--muted); margin-bottom: 18px; }
.resource-list { display: grid; gap: 20px; max-width: 760px; margin: 0 auto; }
.resource-card { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 26px; box-shadow: var(--shadow); }
.resource-card h3 { font-size: 1.2rem; margin-bottom: 6px; }
.resource-card p { color: var(--muted); font-size: 0.94rem; margin-bottom: 14px; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .stat-cards { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: 1fr; }
  .stat-band .row { grid-template-columns: 1fr; gap: 20px; }
  .calc { grid-template-columns: 1fr; }
}
@media (max-width: 768px) {
  .nav-links {
    display: none; position: absolute; top: 100%; left: 0; right: 0;
    background: #fff; flex-direction: column; align-items: stretch;
    padding: 12px 20px 20px; border-bottom: 1px solid var(--border); gap: 4px;
  }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 10px 0; }
  .nav-toggle { display: block; }
  .app-shell { flex-direction: column; }
  .sidebar { width: 100%; height: auto; position: static; flex-direction: row; flex-wrap: wrap; align-items: center; padding: 12px 16px; gap: 6px; }
  .sidebar .logo { margin-bottom: 0; margin-right: auto; }
  .sidebar a.nav-item { padding: 8px 10px; font-size: 0.85rem; }
  .sidebar .side-foot { display: none; }
  .main { padding: 20px 16px; }
  .stat-cards { grid-template-columns: 1fr 1fr; }
  .hero { padding: 56px 0 44px; }
  .section { padding: 52px 0; }
}
@media (max-width: 480px) {
  .stat-cards { grid-template-columns: 1fr; }
  .card-row { grid-template-columns: 1fr; }
  .card-box { padding: 28px 22px; }
  .calc { padding: 22px; }
}

/* ---------- Support page ---------- */
.hero-slim { padding: 64px 0 48px; }
.search-wrap { position: relative; max-width: 620px; margin: 30px auto 0; }
.search-wrap .search-icon { position: absolute; left: 18px; top: 50%; transform: translateY(-50%); color: var(--faint); font-size: 1.2rem; pointer-events: none; }
#faqSearch { width: 100%; padding: 15px 20px 15px 50px; font-size: 1rem; font-family: var(--font); border: 1.5px solid var(--border); border-radius: 999px; box-shadow: var(--shadow); }
#faqSearch:focus { outline: 2px solid var(--accent); border-color: var(--accent); }
.faq-cat-block { margin-bottom: 44px; }
.faq-cat-label { text-align: left !important; margin-bottom: 18px !important; font-size: 1.3rem !important; }
.faq-item { border: 1px solid var(--border); border-radius: var(--radius); margin-bottom: 12px; background: #fff; overflow: hidden; }
.faq-item summary { padding: 17px 20px; cursor: pointer; font-weight: 600; font-size: 1rem; list-style: none; display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: "+"; flex: none; width: 28px; height: 28px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); font-weight: 700; display: flex; align-items: center; justify-content: center; }
.faq-item[open] summary::after { content: "\2212"; }
.faq-item summary:hover { color: var(--accent); }
.faq-item .faq-a { padding: 2px 20px 20px; color: var(--muted); line-height: 1.7; font-size: 0.96rem; }
.faq-item .faq-a p { margin: 0 0 10px; }
.faq-item .faq-a p:last-child { margin-bottom: 0; }
.faq-item .faq-a strong { color: var(--ink); }
.faq-item .faq-a code { background: var(--bg-soft); border: 1px solid var(--border); border-radius: 6px; padding: 1px 6px; font-size: 0.85em; }
.faq-item .faq-a a { color: var(--accent); }

/* ---------- Slim topbar (update-card.html) ---------- */
.slim-topbar { display: flex; justify-content: space-between; align-items: center; max-width: 1100px; margin: 0 auto; padding: 18px 20px; }
.slim-link { font-size: 0.9rem; font-weight: 600; color: var(--muted); text-decoration: none; }
.slim-link:hover { color: var(--accent); }
