/* ──────────────────────────────────────────────────────────
   Receipt Flow — public site styles
   Brand: blue family from the Flutter app's AppColors palette.
   ────────────────────────────────────────────────────────── */

:root {
  /* Brand palette (mirrors lib/app/theme/app_colors.dart) */
  --brand-600: #1968B3;
  --brand-500: #2782D0;
  --brand-400: #4E9EE2;
  --brand-300: #8CC0ED;
  --brand-200: #C2DDF5;
  --brand-100: #E3EDFB;
  --accent-purple: #6960EC;
  --accent-orange: #FFA880;

  /* Neutrals */
  --text: #1A1A1A;
  --text-muted: #5B6271;
  --text-soft: #8B92A1;
  --bg: #FFFFFF;
  --bg-soft: #F7F9FC;
  --bg-band: #F2F6FC;
  --border: #E5EAF2;

  /* Shapes */
  --radius-sm: 8px;
  --radius: 14px;
  --radius-lg: 22px;
  --max-width: 1080px;
  --content-width: 780px;

  /* Shadows */
  --shadow-sm: 0 1px 2px rgba(16, 24, 40, .06);
  --shadow-md: 0 8px 20px rgba(25, 104, 179, .08);
  --shadow-lg: 0 22px 60px rgba(25, 104, 179, .18);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: 'Poppins', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a { color: var(--brand-600); text-decoration: none; }
a:hover { color: var(--brand-500); text-decoration: underline; }

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

/* ── Header ─────────────────────────────────────────────── */

header.site-header {
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 10;
}

header.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 28px;
  max-width: var(--max-width);
  margin: 0 auto;
}

header.site-header .brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  color: var(--text);
  font-size: 17px;
  letter-spacing: -0.01em;
}

header.site-header .brand .logo-mark {
  width: 28px;
  height: 28px;
  border-radius: 7px;
  background: linear-gradient(135deg, var(--brand-500), var(--brand-600));
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-sm);
}

header.site-header .brand .logo-mark svg {
  width: 16px;
  height: 16px;
  fill: #fff;
}

header.site-header nav a {
  margin-left: 22px;
  color: var(--text-muted);
  font-size: 14px;
  font-weight: 500;
  transition: color .15s ease;
}

header.site-header nav a:hover { color: var(--brand-600); text-decoration: none; }

/* ── Generic content pages (privacy / terms / etc) ─────── */

main {
  max-width: var(--content-width);
  margin: 0 auto;
  padding: 56px 24px 96px;
}

main h1 {
  font-size: 36px;
  line-height: 1.2;
  letter-spacing: -0.02em;
  margin: 0 0 8px;
}

main h2 {
  font-size: 22px;
  line-height: 1.35;
  letter-spacing: -0.01em;
  margin: 40px 0 12px;
}

main h3 {
  font-size: 17px;
  margin: 24px 0 8px;
}

main p, main li { color: var(--text); }
main ul, main ol { padding-left: 22px; }
main ul li, main ol li { margin: 4px 0; }

main .lede {
  color: var(--text-muted);
  font-size: 18px;
  margin-bottom: 24px;
}

.effective {
  color: var(--text-soft);
  font-size: 14px;
  margin-bottom: 32px;
}

.callout {
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-left: 3px solid var(--brand-500);
  border-radius: var(--radius-sm);
  padding: 16px 20px;
  margin: 24px 0;
}

.callout strong { display: block; margin-bottom: 4px; color: var(--brand-600); }

/* ── Buttons ────────────────────────────────────────────── */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--brand-600);
  color: #fff;
  padding: 12px 22px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 15px;
  margin-top: 8px;
  box-shadow: var(--shadow-sm);
  transition: transform .15s ease, box-shadow .15s ease, background .15s ease;
}

.btn:hover {
  background: var(--brand-500);
  color: #fff;
  text-decoration: none;
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.btn.btn-ghost {
  background: transparent;
  color: var(--brand-600);
  border: 1.5px solid var(--brand-200);
}

.btn.btn-ghost:hover {
  background: var(--brand-100);
  color: var(--brand-600);
  border-color: var(--brand-300);
}

.btn.btn-light {
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
  border: 1.5px solid rgba(255, 255, 255, 0.4);
  backdrop-filter: blur(8px);
}

.btn.btn-light:hover {
  background: rgba(255, 255, 255, 0.28);
  color: #fff;
}

/* ── Landing page ───────────────────────────────────────── */

.hero {
  position: relative;
  background:
    radial-gradient(1200px 600px at 90% -10%, rgba(105, 96, 236, 0.35), transparent 60%),
    radial-gradient(900px 500px at -10% 110%, rgba(255, 168, 128, 0.25), transparent 60%),
    linear-gradient(140deg, var(--brand-600) 0%, var(--brand-500) 55%, var(--brand-400) 100%);
  color: #fff;
  overflow: hidden;
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.05) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(circle at 50% 30%, #000 30%, transparent 75%);
  -webkit-mask-image: radial-gradient(circle at 50% 30%, #000 30%, transparent 75%);
  pointer-events: none;
}

.hero .container {
  position: relative;
  z-index: 1;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 90px 28px 110px;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 56px;
  align-items: center;
}

.hero .eyebrow {
  display: inline-block;
  padding: 6px 14px;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: #fff;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.02em;
  margin-bottom: 18px;
  backdrop-filter: blur(6px);
}

.hero h1 {
  font-size: 54px;
  line-height: 1.05;
  letter-spacing: -0.03em;
  font-weight: 700;
  margin: 0 0 18px;
  color: #fff;
}

.hero p.sub {
  font-size: 19px;
  line-height: 1.55;
  margin: 0 0 28px;
  color: rgba(255, 255, 255, 0.92);
  max-width: 520px;
}

.hero .cta-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.hero .logo-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero .logo-wrap img {
  width: 100%;
  max-width: 380px;
  height: auto;
  filter: drop-shadow(0 20px 60px rgba(0, 0, 0, 0.25));
  opacity: 0.95;
}

/* ── Sections ───────────────────────────────────────────── */

section.band {
  padding: 80px 28px;
  max-width: var(--max-width);
  margin: 0 auto;
}

section.band.alt {
  background: var(--bg-band);
  max-width: none;
  padding-left: 0;
  padding-right: 0;
}

section.band.alt .band-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 28px;
}

.section-header {
  text-align: center;
  max-width: 640px;
  margin: 0 auto 48px;
}

.section-header .kicker {
  color: var(--brand-600);
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 10px;
}

.section-header h2 {
  font-size: 34px;
  line-height: 1.2;
  letter-spacing: -0.02em;
  margin: 0 0 12px;
}

.section-header p {
  color: var(--text-muted);
  font-size: 17px;
  margin: 0;
}

/* ── Feature grid ───────────────────────────────────────── */

.features {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}

.feature-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 24px;
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}

.feature-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: var(--brand-200);
}

.feature-card .icon {
  width: 44px;
  height: 44px;
  border-radius: 11px;
  background: var(--brand-100);
  color: var(--brand-600);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
}

.feature-card .icon svg {
  width: 22px;
  height: 22px;
  stroke: currentColor;
  stroke-width: 1.8;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.feature-card.accent-purple .icon { background: rgba(105, 96, 236, 0.12); color: var(--accent-purple); }
.feature-card.accent-orange .icon { background: rgba(255, 168, 128, 0.18); color: #E07A4F; }

.feature-card h3 {
  font-size: 17px;
  font-weight: 600;
  margin: 0 0 8px;
  color: var(--text);
  letter-spacing: -0.01em;
}

.feature-card p {
  font-size: 14.5px;
  color: var(--text-muted);
  margin: 0;
  line-height: 1.6;
}

/* ── How-it-works steps ─────────────────────────────────── */

.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.step {
  text-align: center;
  padding: 12px;
}

.step .num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--brand-500), var(--brand-600));
  color: #fff;
  font-weight: 700;
  font-size: 16px;
  margin-bottom: 16px;
  box-shadow: var(--shadow-sm);
}

.step h3 {
  font-size: 17px;
  font-weight: 600;
  margin: 0 0 6px;
}

.step p {
  font-size: 14.5px;
  color: var(--text-muted);
  margin: 0;
}

/* ── CTA band ───────────────────────────────────────────── */

.cta-band {
  margin: 40px 28px 96px;
  max-width: var(--max-width);
  margin-left: auto;
  margin-right: auto;
  border-radius: var(--radius-lg);
  background:
    radial-gradient(600px 200px at 0% 0%, rgba(255, 168, 128, 0.25), transparent 60%),
    linear-gradient(135deg, var(--brand-600), var(--brand-500));
  color: #fff;
  padding: 56px 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 40px;
  flex-wrap: wrap;
  box-shadow: var(--shadow-lg);
}

.cta-band h2 {
  font-size: 28px;
  margin: 0 0 6px;
  letter-spacing: -0.01em;
  color: #fff;
}

.cta-band p {
  margin: 0;
  color: rgba(255, 255, 255, 0.88);
  font-size: 16px;
}

/* ── Page hero (privacy / terms / contact / delete) ────── */

.page-hero {
  background:
    radial-gradient(800px 300px at 10% -20%, rgba(78, 158, 226, 0.18), transparent 60%),
    radial-gradient(700px 300px at 95% 110%, rgba(105, 96, 236, 0.14), transparent 60%),
    var(--bg-band);
  border-bottom: 1px solid var(--border);
  text-align: center;
  padding: 64px 24px 56px;
}

.page-hero .inner {
  max-width: var(--content-width);
  margin: 0 auto;
}

.page-hero h1 {
  font-size: 42px;
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0 0 12px;
}

.page-hero .lede {
  color: var(--text-muted);
  font-size: 18px;
  max-width: 600px;
  margin: 0 auto 18px;
}

.page-hero .meta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--text-muted);
  font-size: 13px;
  font-weight: 500;
}

.page-hero .meta::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--brand-500);
}

/* Legal-content typography tuning (privacy / terms) */

.legal-content h2 {
  padding-top: 4px;
  border-top: 1px solid var(--border);
  margin-top: 48px;
}

.legal-content > h2:first-of-type {
  border-top: none;
  margin-top: 36px;
}

/* TL;DR-style summary at top of privacy */

.summary {
  background: linear-gradient(180deg, #fff 0%, var(--bg-soft) 100%);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px 28px;
  margin: 0 0 36px;
  box-shadow: var(--shadow-sm);
}

.summary h2 {
  font-size: 14px;
  font-weight: 700;
  color: var(--brand-600);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin: 0 0 12px;
  border: none;
  padding: 0;
}

.summary ul {
  margin: 0;
  padding-left: 20px;
}

.summary ul li {
  color: var(--text);
  font-size: 15px;
  margin: 6px 0;
}

/* Card grids — used on contact + delete-account */

.card-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 22px;
  margin: 8px 0 32px;
}

.card-grid.single { grid-template-columns: 1fr; }

.info-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 26px;
  display: flex;
  flex-direction: column;
  transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}

.info-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--brand-200);
}

.info-card .icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--brand-100);
  color: var(--brand-600);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
}

.info-card .icon svg {
  width: 20px;
  height: 20px;
  stroke: currentColor;
  stroke-width: 1.8;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.info-card.accent-purple .icon { background: rgba(105, 96, 236, 0.12); color: var(--accent-purple); }
.info-card.accent-orange .icon { background: rgba(255, 168, 128, 0.18); color: #E07A4F; }

.info-card h3 {
  font-size: 17px;
  font-weight: 600;
  margin: 0 0 8px;
  letter-spacing: -0.01em;
}

.info-card p {
  font-size: 15px;
  color: var(--text-muted);
  margin: 0 0 14px;
  line-height: 1.6;
}

.info-card .spacer { flex: 1; }

/* Numbered method card for delete-account */

.method-card .step-row {
  display: flex;
  gap: 14px;
  margin-bottom: 12px;
}

.method-card .step-row:last-child { margin-bottom: 0; }

.method-card .step-num {
  flex: 0 0 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--brand-100);
  color: var(--brand-600);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 13px;
}

.method-card .step-row .step-text {
  color: var(--text);
  font-size: 15px;
  line-height: 1.55;
  padding-top: 3px;
}

/* Warning callout (red-tinted) for destructive actions */

.warning {
  background: #FFF4F5;
  border: 1px solid #FBDADE;
  border-left: 3px solid #DA011E;
  border-radius: var(--radius-sm);
  padding: 16px 20px;
  margin: 24px 0;
}

.warning strong { display: block; margin-bottom: 4px; color: #B30016; }
.warning p { margin: 0; color: #6B0010; font-size: 14.5px; }

/* Two-column "kept / deleted" lists for delete-account */

.kept-deleted {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
  margin: 8px 0 24px;
}

.kept-deleted .col {
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px 24px;
}

.kept-deleted .col h3 {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 15px;
  margin: 0 0 12px;
  font-weight: 600;
}

.kept-deleted .col.deleted h3 { color: #B30016; }
.kept-deleted .col.kept h3 { color: var(--brand-600); }

.kept-deleted .col h3 .pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 999px;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.kept-deleted .col.deleted h3 .pill { background: #FFE4E8; color: #B30016; }
.kept-deleted .col.kept h3 .pill { background: var(--brand-100); color: var(--brand-600); }

.kept-deleted ul {
  margin: 0;
  padding-left: 18px;
}

.kept-deleted li {
  font-size: 14.5px;
  color: var(--text-muted);
  margin: 6px 0;
  line-height: 1.55;
}

/* Tighten legal pages on mobile */

@media (max-width: 700px) {
  .page-hero { padding: 48px 20px 40px; }
  .page-hero h1 { font-size: 30px; }
  .page-hero .lede { font-size: 16px; }
  .card-grid { grid-template-columns: 1fr; }
  .kept-deleted { grid-template-columns: 1fr; }
}

/* ── Footer ─────────────────────────────────────────────── */

footer.site-footer {
  border-top: 1px solid var(--border);
  padding: 40px 28px;
  text-align: center;
  color: var(--text-soft);
  font-size: 13px;
  background: var(--bg-soft);
}

footer.site-footer nav {
  margin-bottom: 12px;
}

footer.site-footer nav a {
  margin: 0 12px;
  color: var(--text-muted);
  font-weight: 500;
}

footer.site-footer nav a:hover { color: var(--brand-600); text-decoration: none; }

/* ── Responsive ─────────────────────────────────────────── */

@media (max-width: 900px) {
  .hero .container {
    grid-template-columns: 1fr;
    padding: 70px 24px 80px;
    gap: 36px;
    text-align: center;
  }
  .hero p.sub { margin-left: auto; margin-right: auto; }
  .hero .cta-row { justify-content: center; }
  .hero .logo-wrap img { max-width: 280px; margin: 0 auto; }
  .features { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: 1fr; }
  .cta-band { padding: 40px 28px; text-align: center; justify-content: center; }
}

@media (max-width: 560px) {
  header.site-header .container { padding: 12px 18px; }
  header.site-header nav a { margin-left: 14px; font-size: 13px; }
  .hero h1 { font-size: 38px; }
  .hero p.sub { font-size: 16px; }
  .features { grid-template-columns: 1fr; }
  main h1 { font-size: 28px; }
  main h2 { font-size: 19px; }
  section.band { padding: 56px 20px; }
  .section-header h2 { font-size: 26px; }
  .cta-band { margin: 24px 20px 64px; padding: 32px 24px; }
  .cta-band h2 { font-size: 22px; }
}
