/* Currents Managed Bookkeeping — Portal Theme */
/* Brand: navy (#1a2a4a) / teal (#2bb5a0) / white / light gray */

:root {
  --navy: #1a2a4a;
  --navy-dark: #0f1a30;
  --teal: #2bb5a0;
  --teal-light: #3dd4bd;
  --teal-ink: #0f766e;
  --white: #ffffff;
  --gray-50: #f8f9fa;
  --gray-100: #f1f3f5;
  --gray-200: #e9ecef;
  --gray-400: #ced4da;
  --gray-600: #5c6670;
  --gray-800: #343a40;
  --danger: #e03131;
  --danger-ink: #c92a2a;
  --success: #2b8a3e;
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --radius: 8px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --shadow: 0 2px 8px rgba(0,0,0,.08);
  --shadow-lg: 0 4px 24px rgba(0,0,0,.12);
  --shadow-xl: 0 24px 80px rgba(0,0,0,.14);
  --text-on-navy: #ffffff;
  color-scheme: light dark;

  /* Fluid type scale (mobile-first: 375px base → 1440px cap) */
  --font-size-xs: clamp(0.75rem, 0.7rem + 0.25vw, 0.875rem);
  --font-size-sm: clamp(0.875rem, 0.8rem + 0.375vw, 1rem);
  --font-size-base: clamp(1rem, 0.9rem + 0.5vw, 1.125rem);
  --font-size-lg: clamp(1.125rem, 1rem + 0.625vw, 1.25rem);
  --font-size-xl: clamp(1.25rem, 1.1rem + 0.75vw, 1.5rem);
  --font-size-2xl: clamp(1.5rem, 1.3rem + 1vw, 2rem);
  --font-size-3xl: clamp(2rem, 1.7rem + 1.5vw, 2.5rem);

  /* Fluid spacing scale */
  --space-xs: clamp(0.25rem, 0.2rem + 0.25vw, 0.5rem);
  --space-sm: clamp(0.5rem, 0.4rem + 0.5vw, 0.75rem);
  --space-md: clamp(0.75rem, 0.6rem + 0.75vw, 1rem);
  --space-lg: clamp(1rem, 0.8rem + 1vw, 1.5rem);
  --space-xl: clamp(1.5rem, 1.2rem + 1.5vw, 2rem);
  --space-2xl: clamp(2rem, 1.6rem + 2vw, 3rem);

  /* Fluid container */
  --container-max: clamp(320px, 90vw, 1200px);
  --container-narrow: clamp(280px, 90vw, 480px);
}

html[data-theme="dark"] {
  --navy: #0d1424;
  --navy-dark: #060a14;
  --white: #1a1f2e;
  --gray-50: #1a1f2e;
  --gray-100: #232938;
  --gray-200: #2d3447;
  --gray-400: #4a5168;
  --gray-600: #8892a8;
  --gray-800: #c4cad8;
  --danger: #ff5b5b;
  --success: #51cf66;
  --teal-ink: #3dd4bd;
  --shadow: 0 2px 8px rgba(0,0,0,.3);
  --shadow-lg: 0 4px 24px rgba(0,0,0,.4);
  --shadow-xl: 0 24px 80px rgba(0,0,0,.5);
  --text-on-navy: #e0e4ec;
  color-scheme: light dark;
}

html[data-theme="dark"] body {
  color: var(--gray-800);
}
html[data-theme="dark"] .nav,
html[data-theme="dark"] .nav__brand,
html[data-theme="dark"] .hero {
  color: var(--text-on-navy);
}
html[data-theme="dark"] .btn--primary,
html[data-theme="dark"] .btn--navy,
html[data-theme="dark"] .btn--danger,
html[data-theme="dark"] .step__item--active .step__link,
html[data-theme="dark"] .step__item--done .step__marker,
html[data-theme="dark"] .step__item--active .step__marker {
  color: #ffffff;
}
html[data-theme="dark"] .btn--outline {
  color: var(--gray-200);
  border-color: var(--gray-400);
}
html[data-theme="dark"] .alert--error { background: #2e1515; border-color: #5c2020; color: var(--danger); }
html[data-theme="dark"] .alert--success { background: #152e1a; border-color: #1e5c2d; color: var(--success); }
html[data-theme="dark"] .alert--info { background: #152030; border-color: #1e3d5c; color: #74b3e8; }
html[data-theme="dark"] .badge--teal { background: #0f2924; border-color: var(--teal); color: var(--teal-light); }
html[data-theme="dark"] .form-group input[type="email"],
html[data-theme="dark"] .form-group input[type="password"],
html[data-theme="dark"] .form-group input[type="text"] {
  background: var(--gray-100);
  color: var(--gray-800);
  border-color: var(--gray-400);
}
html[data-theme="dark"] .footer { border-top-color: var(--gray-200); }

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

body {
  font-family: var(--font-sans);
  color: var(--navy-dark);
  background: var(--gray-50);
  line-height: 1.6;
  min-height: 100vh;
  font-size: var(--font-size-base);
}

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

/* ── Accessibility (m7-2) ── */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 2000;
  background: var(--navy);
  color: var(--white);
  padding: 12px 20px;
  border-radius: 0 0 var(--radius) 0;
  font-weight: 600;
  text-decoration: none;
}
.skip-link:focus {
  left: 0;
  color: var(--white);
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
:focus-visible {
  outline: 3px solid var(--teal);
  outline-offset: 2px;
  border-radius: 2px;
}
html[data-theme="dark"] .skip-link:focus { color: var(--white); }

/* ── Layout ── */
.container { max-width: var(--container-max); margin: 0 auto; padding: 0 clamp(12px, 4vw, 24px); }
.container--narrow { max-width: var(--container-narrow); }

/* ── Nav ── */
.nav {
  background: var(--navy);
  color: var(--white);
  padding: 12px 0;
  position: sticky;
  top: 0;
  z-index: 100;
}
.nav__inner { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.nav__brand { font-size: var(--font-size-lg); font-weight: 700; color: var(--white); }
.nav__brand:hover { text-decoration: none; }
.nav__logo { display: block; height: 32px; width: auto; }
.nav__links { display: flex; gap: 16px; }
.nav__links a { color: var(--white); font-size: var(--font-size-sm); font-weight: 600; }
.nav__links a:hover { color: var(--teal); text-decoration: none; }
.nav__cta { display: inline-block; background: var(--teal); color: var(--navy); padding: 6px 14px; border-radius: 999px; }
.nav__links a.nav__cta { color: var(--navy); }
.nav__cta:hover { background: var(--teal-light); color: var(--navy); text-decoration: none; }
.nav__link--disabled { color: var(--gray-600) !important; cursor: default; opacity: .6; }
.nav__link--disabled:hover { color: var(--gray-600) !important; text-decoration: none; }

.theme-toggle {
  background: transparent;
  border: none;
  cursor: pointer;
  color: inherit;
  font-size: 1.2rem;
  padding: 4px 8px;
  line-height: 1;
}
.theme-toggle:hover { opacity: .8; }

/* ── Attention cards ── */
.attention-link { display: block; text-decoration: none; color: inherit; }
.attention-link:hover { text-decoration: none; }
.attention-link .card__value { margin-bottom: 4px; }
.attention-link .card__label { font-size: .85rem; color: var(--gray-600); }
.attention-link:hover .card__value { color: var(--teal-light); }

/* ── Subscription card ── */
#subscription-status { font-size: .9rem; color: var(--gray-800); margin-bottom: 12px; }

/* ── Step indicator ── */
.step {
  display: flex;
  flex-direction: column;
  list-style: none;
  gap: 0;
  margin-bottom: 24px;
  padding: 0;
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--white);
}
.step__item {
  flex: 1;
  text-align: center;
  border-bottom: 1px solid var(--gray-200);
}
.step__item:last-child { border-bottom: none; }
.step__link {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 8px;
  font-size: var(--font-size-xs);
  color: var(--gray-600);
  text-decoration: none;
  transition: background .2s;
}
.step__link:hover { text-decoration: none; }
.step__item--active .step__link { background: var(--teal); color: var(--navy); }
.step__item--active .step__marker { background: rgba(26,42,74,.15); color: var(--navy); }
.step__item--disabled { opacity: .5; }
.step__item--disabled .step__link { cursor: default; }
.step__marker {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--gray-100);
  color: var(--gray-600);
  font-weight: 700;
  font-size: .75rem;
}
.step__label { font-weight: 500; line-height: 1.3; }

/* ── Hero ── */
.hero {
  position: relative;
  text-align: center;
  padding: 120px 0 100px;
  background: linear-gradient(135deg, var(--navy-dark) 0%, var(--navy) 60%, #0f2a3a 100%);
  color: var(--white);
  overflow: hidden;
}
.hero__backdrop {
  position: absolute;
  inset: -20% 0 auto auto;
  width: 70%;
  height: 140%;
  background: radial-gradient(circle at 70% 30%, rgba(43,181,160,.22), transparent 55%),
              radial-gradient(circle at 30% 80%, rgba(61,212,189,.12), transparent 45%);
  pointer-events: none;
  z-index: 0;
}
.hero__inner {
  position: relative;
  z-index: 1;
}
.hero__eyebrow {
  display: inline-block;
  background: rgba(43,181,160,.15);
  border: 1px solid rgba(43,181,160,.35);
  border-radius: 999px;
  padding: 6px 16px;
  font-size: .85rem;
  font-weight: 600;
  color: var(--teal-light);
  margin-bottom: 24px;
  letter-spacing: .01em;
}
.hero__headline {
  font-size: clamp(2.4rem, 6vw, 4.2rem);
  font-weight: 800;
  max-width: 840px;
  margin: 0 auto 24px;
  line-height: 1.05;
  letter-spacing: -0.03em;
}
.hero__sub { font-size: var(--font-size-lg);
  color: var(--gray-200);
  max-width: 620px;
  margin: 0 auto 36px;
  line-height: 1.6;
}
.hero__ctas { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }
.hero__trust {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 12px 28px;
  margin-top: 40px;
  font-size: .9rem;
  color: var(--gray-200);
}
.hero__trust-item { display: inline-flex; align-items: center; gap: 8px; }
.hero__trust-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--teal);
  box-shadow: 0 0 0 4px rgba(43,181,160,.2);
}

/* ── Buttons ── */
.btn { display: inline-block; padding: 12px 28px; border-radius: var(--radius); font-size: var(--font-size-sm);
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: transform .15s, background .2s, opacity .2s, box-shadow .2s;
}
.btn:hover { transform: translateY(-1px); }
.btn--primary { background: var(--teal); color: var(--navy); }
.btn--primary:hover { background: var(--teal-light); color: var(--navy); text-decoration: none; }
.btn--primary:disabled { background: var(--gray-400); color: var(--navy-dark); cursor: not-allowed; }
.btn--outline { background: transparent; color: var(--white); border: 2px solid var(--gray-200); }
.btn--outline:hover { border-color: var(--white); text-decoration: none; }
.btn--navy { background: var(--navy); color: var(--white); }
.btn--navy:hover { background: var(--navy-dark); text-decoration: none; }
.btn--danger { background: var(--danger); color: var(--white); }
.btn--secondary { background: var(--gray-100); color: var(--navy-dark); border: 1px solid var(--gray-200); }
.btn--secondary:hover { background: var(--gray-200); text-decoration: none; }
.btn--small { padding: 6px 12px; font-size: var(--font-size-xs); }
.btn--lg { padding: 16px 36px; font-size: var(--font-size-lg); }
.btn--glow {
  border-radius: 999px;
  background: linear-gradient(135deg, var(--teal) 0%, var(--teal-light) 100%);
  color: var(--navy);
  box-shadow: 0 8px 28px rgba(43,181,160,.4);
}
.btn--glow:hover { box-shadow: 0 10px 36px rgba(43,181,160,.5); text-decoration: none; }
html[data-theme="dark"] .btn--primary,
html[data-theme="dark"] .btn--glow { color: var(--navy); }
.btn--light {
  border-radius: 999px;
  border-color: rgba(255,255,255,.35);
  color: var(--white);
}
.btn--light:hover { background: rgba(255,255,255,.08); border-color: var(--white); }

/* ── Sections ── */
.page-section { padding: 96px 0; }
.page-section--how { background: var(--white); }
.page-section--cta { padding-top: 48px; padding-bottom: 120px; }
.page-section__head { margin-bottom: 56px; }
.page-section__head--center { text-align: center; }
.page-section__eyebrow {
  display: inline-block;
  font-size: .85rem;
  font-weight: 700;
  color: var(--teal-ink);
  text-transform: uppercase;
  letter-spacing: .08em;
  margin-bottom: 12px;
}
.page-section__title {
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  font-weight: 800;
  color: var(--navy);
  letter-spacing: -0.02em;
  line-height: 1.15;
}

/* ── Steps ── */
.steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 32px;
}
.step-card {
  position: relative;
  padding: 36px 32px;
  background: var(--gray-50);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg);
}
.step-card__number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--teal);
  color: var(--white);
  font-weight: 800;
  margin-bottom: 20px;
}
.step-card__title { font-size: var(--font-size-xl); font-weight: 700; color: var(--navy); margin-bottom: 10px; }
.step-card__desc { color: var(--gray-600); font-size: 1rem; line-height: 1.6; }

/* ── Feature Cards ── */
.features { padding: 96px 0; }
.features__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}
.feature-card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg);
  padding: 36px 32px;
  box-shadow: var(--shadow);
  transition: transform .2s, box-shadow .2s;
}
.feature-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.feature-card__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  height: 52px;
  border-radius: var(--radius);
  background: rgba(43,181,160,.12);
  color: var(--navy);
  font-size: 1.6rem;
  margin-bottom: 20px;
}
.feature-card__title { font-size: var(--font-size-lg); font-weight: 700; margin-bottom: 10px; color: var(--navy); }
.feature-card__desc { color: var(--gray-600); font-size: .98rem; line-height: 1.6; }

/* ── Pricing ── */
.pricing {
  text-align: center;
  padding: 48px 0 96px;
  background: var(--gray-50);
}
.pricing__card {
  display: inline-block;
  width: 100%;
  max-width: 420px;
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-xl);
  padding: 44px 40px;
  box-shadow: var(--shadow-xl);
}
.pricing__eyebrow {
  display: inline-block;
  font-size: .85rem;
  font-weight: 700;
  color: var(--teal-ink);
  text-transform: uppercase;
  letter-spacing: .08em;
  margin-bottom: 16px;
}
.pricing__amount { font-size: 3.4rem; font-weight: 800; color: var(--navy); letter-spacing: -0.03em; }
.pricing__period { font-size: 1.1rem; color: var(--gray-600); font-weight: 500; }
.pricing__trial { font-size: 1rem; color: var(--teal-ink); font-weight: 600; margin: 8px 0 28px; }
.pricing__perks {
  list-style: none;
  text-align: left;
  margin: 0 0 32px;
  padding: 0;
  color: var(--gray-800);
}
.pricing__perks li {
  padding: 8px 0 8px 28px;
  position: relative;
}
.pricing__perks li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--teal);
  font-weight: 700;
}

/* ── CTA Card ── */
.cta-card {
  position: relative;
  overflow: hidden;
  text-align: center;
  padding: 72px 48px;
  border-radius: var(--radius-xl);
  background: linear-gradient(135deg, var(--navy) 0%, var(--navy-dark) 100%);
  color: var(--white);
}
.cta-card__title {
  font-size: clamp(1.6rem, 4vw, 2.6rem);
  font-weight: 800;
  max-width: 640px;
  margin: 0 auto 12px;
  letter-spacing: -0.02em;
}
.cta-card__desc {
  font-size: 1.15rem;
  color: var(--gray-200);
  max-width: 520px;
  margin: 0 auto 32px;
}

/* ── Badge ── */
.badge {
  display: inline-block;
  background: var(--gray-100);
  border: 1px solid var(--gray-200);
  border-radius: 20px;
  padding: 6px 16px;
  font-size: .8rem;
  font-weight: 600;
  color: var(--navy);
}
.badge--teal { background: #e6faf7; border-color: var(--teal); color: var(--teal-ink); }

/* ── Forms ── */
.form-group { margin-bottom: 20px; }
.form-group label { display: block; font-size: var(--font-size-sm);
  font-weight: 600;
  margin-bottom: 6px;
  color: var(--navy);
}
.form-group input[type="email"],
.form-group input[type="password"],
.form-group input[type="text"] {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid var(--gray-400);
  border-radius: var(--radius);
  font-size: 1rem;
  font-family: var(--font-sans);
  background: var(--white);
  transition: border-color .2s;
}
.form-group input:focus { outline: none; border-color: var(--teal); }

/* ── Auth pages ── */
.auth-page {
  min-height: calc(100vh - 56px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.auth-card {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  padding: 40px 36px;
  width: 100%;
  max-width: 420px;
}
.auth-card__title { font-size: var(--font-size-xl); font-weight: 700; margin-bottom: 8px; }
.auth-card__subtitle { color: var(--gray-600); font-size: .9rem; margin-bottom: 24px; }
.auth-card__footer { text-align: center; margin-top: 20px; font-size: .9rem; color: var(--gray-600); }
.auth-card__footer a { color: var(--teal-ink); text-decoration: underline; text-underline-offset: 2px; }

/* ── Consent ── */
.consent-box {
  background: var(--gray-50);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  padding: 16px;
  margin-bottom: 20px;
  font-size: .85rem;
  color: var(--gray-800);
  line-height: 1.7;
  max-height: 200px;
  overflow-y: auto;
}
.consent-box h4 { font-size: .9rem; margin-bottom: 8px; }
.consent-box p { margin-bottom: 8px; }

.consent-check { display: flex; align-items: flex-start; gap: 10px; margin-bottom: 24px; }
.consent-check input[type="checkbox"] {
  margin-top: 3px;
  width: 18px;
  height: 18px;
  accent-color: var(--teal);
  cursor: pointer;
}
.consent-check label { font-size: .9rem; cursor: pointer; }

/* ── Alerts ── */
.alert {
  padding: 12px 16px;
  border-radius: var(--radius);
  font-size: .9rem;
  margin-bottom: 16px;
}
.alert--error { background: #fff5f5; border: 1px solid #ffc9c9; color: var(--danger-ink); }
.alert--warning { background: #fff9db; border: 1px solid #ffe066; color: #b45309; }
.alert--success { background: #ebfbee; border: 1px solid #b2f2bb; color: var(--success); }
.alert--info { background: #e7f5ff; border: 1px solid #a5d8ff; color: #1864ab; }
html[data-theme="dark"] .alert--warning { background: #29220f; border-color: #5c4d20; color: #fcc419; }

/* ── Footer ── */
.footer {
  text-align: center;
  padding: 32px 0;
  color: var(--gray-600);
  font-size: .8rem;
  border-top: 1px solid var(--gray-200);
}
.footer a { color: var(--gray-600); text-decoration: underline; text-underline-offset: 2px; }

/* ── Loading spinner ── */
.spinner {
  display: inline-block;
  width: 18px;
  height: 18px;
  border: 2px solid var(--gray-200);
  border-top-color: var(--teal);
  border-radius: 50%;
  animation: spin .6s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ── Dark-mode support for marketing components ── */
html[data-theme="dark"] .page-section { background: var(--gray-50); }
html[data-theme="dark"] .page-section--how { background: var(--white); }
html[data-theme="dark"] .page-section__title,
html[data-theme="dark"] .feature-card__title,
html[data-theme="dark"] .step-card__title,
html[data-theme="dark"] .pricing__amount { color: var(--text-on-navy); }
html[data-theme="dark"] .feature-card,
html[data-theme="dark"] .step-card,
html[data-theme="dark"] .pricing__card { background: var(--gray-100); border-color: var(--gray-200); }
html[data-theme="dark"] .pricing__perks { color: var(--gray-800); }
html[data-theme="dark"] .hero__sub,
html[data-theme="dark"] .hero__trust { color: var(--text-on-navy); }
html[data-theme="dark"] .btn--light { color: var(--text-on-navy); border-color: rgba(255,255,255,.35); }
html[data-theme="dark"] .btn--light:hover { border-color: rgba(255,255,255,.85); }

/* ── Semantic match confidence bands (reconciliation) ── */
.recon__match-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 12px; }
.recon__semantic-line { padding: 8px 0; border-bottom: 1px solid var(--gray-100); }
.recon__semantic-candidate { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 6px 0 6px 16px; }
.recon__conf-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  position: relative;
  padding: 2px 10px;
  border-radius: 12px;
  font-size: .78rem;
  font-weight: 700;
  cursor: default;
}
.recon__conf--high { background: #ebfbee; color: var(--success); border: 1px solid #b2f2bb; }
.recon__conf--mid { background: #fff9db; color: #e67700; border: 1px solid #ffec99; }
.recon__conf--low { background: #fff5f5; color: var(--danger); border: 1px solid #ffc9c9; }
.recon__conf-tooltip {
  visibility: hidden;
  background: var(--gray-800);
  color: var(--white);
  font-size: .72rem;
  font-weight: 400;
  padding: 4px 8px;
  border-radius: var(--radius);
  position: absolute;
  bottom: 130%;
  left: 50%;
  transform: translateX(-50%);
  white-space: nowrap;
  z-index: 10;
}
.recon__conf-badge:hover .recon__conf-tooltip { visibility: visible; }
.recon__dismiss-btn { color: var(--gray-600); }

/* ── Journal entry feedback (resolution bookkeeping, csbk-partial-3) ── */
.recon__journal-entry {
  margin-top: 12px;
  padding: 12px 14px;
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  background: var(--gray-50);
}
.recon__journal-entry h4 { margin: 0 0 6px; font-size: .9rem; }
.recon__journal-entry p { margin: 4px 0; font-size: .85rem; }
.recon__je-status {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 12px;
  font-size: .75rem;
  font-weight: 700;
}
.recon__je-status--synced { background: #ebfbee; color: var(--success); border: 1px solid #b2f2bb; }
.recon__je-status--failed { background: #fff5f5; color: var(--danger); border: 1px solid #ffc9c9; }


/* ── Responsive (mobile-first) ──
   Base styles target 375px. Larger layouts are added with min-width media
   queries. Components that adapt to their container use container queries in
   _responsive.css. */

/* Small phones (≤479px) — tighten padding so nothing overflows */
@media (max-width: 479px) {
  .hero { padding: 64px 0 48px; }
  .hero__ctas { flex-direction: column; align-items: stretch; }
  .hero__ctas .btn { text-align: center; }
  .cta-card { padding: 40px 20px; }
  .pricing__card { padding: 28px 20px; }
  .auth-card { padding: 24px 16px; }
  .modal { padding: 20px 16px; }
}

/* tablet — 2-up summary cards, tighter dashboard grid */
@media (min-width: 768px) {
  .cards { grid-template-columns: repeat(2, 1fr); }
  .months { grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 12px; }
  .features__grid { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
  .step { flex-direction: row; }
  .step__item { border-bottom: none; border-right: 1px solid var(--gray-200); }
  .step__item:last-child { border-right: none; }
  .step__link { flex-direction: column; gap: 4px; padding: 12px 8px; }
}

/* desktop — roomier period/grid tables */
@media (min-width: 1024px) {
  .nav__steps { max-width: var(--container-max); }
  .period-grid-container table, .coverage-grid-container table { table-layout: auto; }
  .group-card__tx-table th, .group-card__tx-table td { padding: 10px 14px; }
  .upload-zone { padding: 20px 24px; }
  .page-section { padding: 96px 0; }
}

/* wide desktop — relax the container cap */
@media (min-width: 1440px) {
  .container { max-width: 1200px; }
}

/* ── Toast notifications (receipt-driven category inference surface) ─────── */
.toast-container {
  position: fixed;
  top: 16px;
  right: 16px;
  z-index: 2000;
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-width: 360px;
}
.toast {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px 14px;
  border-radius: var(--radius);
  background: var(--white);
  border: 1px solid var(--gray-200);
  box-shadow: var(--shadow-lg);
  font-size: .9rem;
  color: var(--gray-800);
  animation: toast-in .2s ease-out;
}
.toast--info { border-left: 4px solid var(--teal); }
.toast--error { border-left: 4px solid var(--danger); }
.toast--success { border-left: 4px solid var(--success); }
.toast__dismiss {
  margin-left: auto;
  border: none;
  background: transparent;
  color: var(--gray-600);
  font-size: 1.1rem;
  line-height: 1;
  cursor: pointer;
  padding: 0 2px;
}
.toast__dismiss:hover { color: var(--gray-800); }
@keyframes toast-in {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ── Receipt-inferred category badge + tooltip ───────────────────────────── */
.receipt-inferred-badge {
  position: relative;
  display: inline-block;
  margin-left: 6px;
  padding: 1px 8px;
  border-radius: 10px;
  font-size: .72rem;
  font-weight: 600;
  color: var(--navy);
  background: rgba(43, 181, 160, .15);
  border: 1px solid rgba(43, 181, 160, .4);
  cursor: help;
  vertical-align: middle;
}
.receipt-inferred-badge.is-loading { opacity: .6; }
.receipt-tooltip {
  position: absolute;
  bottom: calc(100% + 8px);
  left: 0;
  z-index: 500;
  display: none;
  min-width: 180px;
  max-width: 260px;
  padding: 10px 12px;
  border-radius: var(--radius);
  background: var(--navy);
  color: var(--white);
  font-size: .8rem;
  font-weight: 400;
  line-height: 1.5;
  box-shadow: var(--shadow-lg);
  pointer-events: none;
}
.receipt-tooltip.show { display: block; }
.receipt-tooltip__link { color: var(--teal-light); }
html[data-theme="dark"] .receipt-tooltip { background: var(--gray-800); color: var(--white); }

