/* =============================================================
   DecideWorth — design system
   Black + White + Gray + Indigo. Functional colors only for results.
   ============================================================= */

/* =============================================================
   1. Tokens
   ============================================================= */
:root {
  /* Brand */
  --charcoal: #0B0D10;
  --bg: #F8F9FB;
  --surface: #FFFFFF;
  --text: #111318;
  --text-secondary: #6B7280;
  --border: #E5E7EB;

  --accent: #5B5FEF;
  --accent-hover: #4A4FE0;
  --accent-light: #EEF0FF;

  --success: #16A34A;
  --success-bg: #EFFBF3;
  --warning: #D97706;
  --warning-bg: #FFF8ED;
  --danger: #DC2626;
  --danger-bg: #FDF0F0;

  --charcoal-text: #FFFFFF;

  /* Elevation */
  --shadow-xs: 0 1px 2px rgba(11, 13, 16, 0.04);
  --shadow-sm: 0 2px 8px rgba(11, 13, 16, 0.06);
  --shadow-md: 0 8px 24px rgba(11, 13, 16, 0.08);
  --shadow-lg: 0 16px 48px rgba(11, 13, 16, 0.12);
  --shadow-focus: 0 0 0 4px rgba(91, 95, 239, 0.16);

  /* Radius */
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-pill: 999px;

  /* Type */
  --font-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-display: "Inter Tight", var(--font-sans);
  --font-mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;

  /* Layout */
  --container: 1140px;
  --container-narrow: 760px;
  --gutter: clamp(1.25rem, 4vw, 2.5rem);
  --nav-height: 72px;

  /* Motion */
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-soft: cubic-bezier(0.25, 0.46, 0.45, 0.94);
  --dur-fast: 0.15s;
  --dur-base: 0.25s;
  --dur-slow: 0.5s;
}

/* =============================================================
   2. Reset & base
   ============================================================= */
*, *::before, *::after { box-sizing: border-box; margin: 0; }

/* Guard the native `hidden` attribute against being overridden by any class
   that sets its own `display` (e.g. .stat-grid { display: grid }) — without
   this, hidden elements sharing such a class render visibly, empty. */
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; tab-size: 2; scroll-behavior: smooth; overflow-x: clip; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
  overscroll-behavior-y: none;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
}

img, svg, video { display: block; max-width: 100%; }
img { height: auto; }
button { font: inherit; color: inherit; cursor: pointer; border: 0; background: none; }
a { color: inherit; text-decoration: none; }
input, select, textarea { font: inherit; color: inherit; }
p { text-wrap: pretty; }
h1, h2, h3, h4 { text-wrap: balance; line-height: 1.1; letter-spacing: -0.02em; font-family: var(--font-display); font-weight: 700; }
ul, ol { list-style: none; padding: 0; }
::selection { background: var(--accent); color: #fff; }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 4px;
}

main { flex: 1; }

/* =============================================================
   3. Utilities
   ============================================================= */
.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: var(--gutter); }
.container-narrow { width: 100%; max-width: var(--container-narrow); margin-inline: auto; padding-inline: var(--gutter); }
.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;
}
.skip-link {
  position: fixed; top: -100px; left: 1rem; z-index: 9999;
  padding: .7rem 1.1rem; background: var(--charcoal); color: #fff;
  border-radius: var(--radius-sm); font-weight: 600; transition: top var(--dur-base) var(--ease-out);
}
.skip-link:focus { top: 1rem; }
.text-secondary { color: var(--text-secondary); }
.tabular { font-variant-numeric: tabular-nums; }
.section { padding-block: clamp(3rem, 7vw, 6rem); }
.section-tight { padding-block: clamp(2rem, 5vw, 3.5rem); }
.eyebrow {
  display: inline-flex; align-items: center; gap: .4rem;
  font-size: 0.8125rem; font-weight: 600; letter-spacing: 0.02em;
  color: var(--accent); text-transform: uppercase;
}
.divider { border: 0; border-top: 1px solid var(--border); margin-block: 2rem; }
.stack { display: flex; flex-direction: column; gap: 1rem; }
.hidden { display: none !important; }

/* =============================================================
   4. Typography
   ============================================================= */
h1 { font-size: clamp(2.25rem, 5.2vw, 4rem); }
h2 { font-size: clamp(1.75rem, 3.4vw, 2.5rem); }
h3 { font-size: clamp(1.25rem, 2vw, 1.5rem); }
.lede { font-size: clamp(1.05rem, 1.6vw, 1.25rem); color: var(--text-secondary); line-height: 1.55; }

.num-display {
  font-family: var(--font-display);
  font-weight: 800;
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}
.num-xl { font-size: clamp(2.5rem, 7vw, 4.25rem); }
.num-lg { font-size: clamp(1.75rem, 4vw, 2.5rem); }
.num-md { font-size: clamp(1.25rem, 2.4vw, 1.6rem); }

article.prose { max-width: 68ch; }
article.prose h2 { margin-top: 2.5rem; margin-bottom: 0.75rem; }
article.prose h3 { margin-top: 1.75rem; margin-bottom: 0.5rem; }
article.prose p { margin-bottom: 1rem; color: var(--text); }
article.prose p + p { margin-top: 0; }
article.prose a { color: var(--accent); text-decoration: underline; text-underline-offset: 2px; }
article.prose ul, article.prose ol { list-style: disc; padding-left: 1.4rem; margin-bottom: 1rem; }
article.prose ol { list-style: decimal; }
article.prose li { margin-bottom: .35rem; }
article.prose strong { font-weight: 600; }

/* =============================================================
   5. Components
   ============================================================= */

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  padding: .85rem 1.5rem; border-radius: var(--radius-pill);
  font-weight: 600; font-size: 0.95rem; white-space: nowrap;
  transition: transform var(--dur-fast) var(--ease-out), box-shadow var(--dur-fast) var(--ease-out), background var(--dur-fast) var(--ease-out);
}
.btn:active { transform: scale(0.97); }
.btn-primary { background: var(--charcoal); color: #fff; }
.btn-primary:hover { background: #1a1d22; box-shadow: var(--shadow-md); }
.btn-accent { background: var(--accent); color: #fff; }
.btn-accent:hover { background: var(--accent-hover); box-shadow: var(--shadow-md); }
.btn.is-revealing { opacity: 0.85; cursor: default; }
.btn-ghost { background: transparent; color: var(--text); border: 1px solid var(--border); }
.btn-ghost:hover { border-color: var(--charcoal); }
.btn-lg { padding: 1.05rem 2rem; font-size: 1.05rem; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: 0.5; cursor: not-allowed; pointer-events: none; }

/* Cards */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}
.card-pad { padding: clamp(1.25rem, 3vw, 2rem); }

/* Badge */
.badge {
  display: inline-flex; align-items: center; gap: .4rem;
  padding: .35rem .75rem; border-radius: var(--radius-pill);
  font-size: 0.8125rem; font-weight: 600;
  background: var(--accent-light); color: var(--accent);
}
.badge-neutral { background: var(--border); color: var(--text-secondary); }

/* Header / Nav */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(248, 249, 251, 0.85);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--border);
}
@supports not (backdrop-filter: blur(1px)) {
  .site-header { background: var(--bg); }
}
.nav {
  height: var(--nav-height);
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
}
.brand { display: inline-flex; align-items: center; gap: .6rem; font-family: var(--font-display); font-weight: 800; font-size: 1.15rem; color: var(--charcoal); }
.brand img { width: 32px; height: 32px; }
.nav-links { display: none; align-items: center; gap: 1.75rem; }
.nav-links a { font-weight: 500; font-size: 0.95rem; color: var(--text); transition: color var(--dur-fast) var(--ease-out); }
.nav-links a:hover { color: var(--accent); }
.nav-right { display: flex; align-items: center; gap: .75rem; }
.nav-cta { display: none; }
@media (min-width: 960px) {
  .nav-links { display: flex; }
  .nav-cta { display: inline-flex; }
}

.lang-switch { display: inline-flex; align-items: center; gap: 2px; font-size: 0.85rem; font-weight: 600; }
.lang-switch a { padding: .55rem .6rem; min-height: 44px; display: inline-flex; align-items: center; border-radius: var(--radius-sm); color: var(--text-secondary); }
.lang-switch a[aria-current="true"] { color: var(--charcoal); background: var(--border); }
.lang-switch a:hover { color: var(--accent); }

.menu-toggle {
  display: inline-flex; width: 40px; height: 40px; align-items: center; justify-content: center;
  border-radius: var(--radius-sm);
}
.menu-toggle:hover { background: var(--border); }
@media (min-width: 960px) { .menu-toggle { display: none; } }

.mobile-menu {
  position: fixed; inset: var(--nav-height) 0 0 0; z-index: 99;
  background: var(--bg); border-top: 1px solid var(--border);
  padding: 1.5rem var(--gutter); display: none; overflow-y: auto;
}
.mobile-menu.is-open { display: block; }
.mobile-menu a { display: block; padding: .9rem 0; font-size: 1.1rem; font-weight: 600; border-bottom: 1px solid var(--border); }
@media (min-width: 960px) { .mobile-menu { display: none !important; } }

/* Footer */
.site-footer { background: var(--charcoal); color: rgba(255,255,255,0.7); margin-top: auto; }
.footer-top { padding-block: clamp(2.5rem, 6vw, 4rem); display: grid; gap: 2.5rem; grid-template-columns: 1fr; }
@media (min-width: 720px) { .footer-top { grid-template-columns: 1.3fr 1fr 1fr 1fr; } }
.footer-brand { display: flex; align-items: center; gap: .6rem; font-family: var(--font-display); font-weight: 800; font-size: 1.1rem; color: #fff; margin-bottom: .75rem; }
.footer-brand img { width: 28px; height: 28px; }
.footer-tagline { font-size: 0.9rem; color: rgba(255,255,255,0.5); max-width: 32ch; }
.footer-col h4 { font-family: var(--font-sans); font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.04em; color: rgba(255,255,255,0.4); margin-bottom: .9rem; font-weight: 600; }
.footer-col ul { display: flex; flex-direction: column; gap: .6rem; }
.footer-col a { font-size: 0.9rem; color: rgba(255,255,255,0.75); transition: color var(--dur-fast) var(--ease-out); }
.footer-col a:hover { color: var(--accent); }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-block: 1.5rem;
  display: flex; flex-wrap: wrap; gap: 1rem; align-items: center; justify-content: space-between;
  font-size: 0.8125rem; color: rgba(255,255,255,0.4);
}
.footer-bottom a { color: rgba(255,255,255,0.55); }
.footer-bottom a:hover { color: var(--accent); }
.footer-legal { display: flex; flex-wrap: wrap; gap: 1rem; }
.footer-cookie-settings {
  font-size: 0.8125rem; color: rgba(255,255,255,0.55); text-decoration: underline;
  text-underline-offset: 2px; transition: color var(--dur-fast) var(--ease-out);
  padding: .6rem .2rem; min-height: 44px; display: inline-flex; align-items: center;
}
.footer-cookie-settings:hover { color: var(--accent); }

/* =============================================================
   Consent banner + preference modal
   ============================================================= */
.dw-consent-banner {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 900;
  display: none; gap: 1rem; flex-wrap: wrap; align-items: center; justify-content: space-between;
  background: var(--charcoal); color: #fff;
  padding: 1.25rem var(--gutter);
  box-shadow: 0 -8px 32px rgba(11,13,16,0.24);
}
.dw-consent-banner.is-open { display: flex; }
.dw-consent-copy { max-width: 640px; }
.dw-consent-copy strong { display: block; font-family: var(--font-display); font-size: 1rem; margin-bottom: .35rem; }
.dw-consent-copy p { font-size: 0.85rem; line-height: 1.5; color: rgba(255,255,255,0.7); }
.dw-consent-actions { display: flex; flex-wrap: wrap; gap: .6rem; }
.dw-consent-btn { white-space: nowrap; }
.dw-consent-banner .btn-ghost { color: #fff; border: 1px solid rgba(255,255,255,0.25); padding: .55rem 1.1rem; border-radius: var(--radius-pill); font-size: 0.875rem; }
.dw-consent-banner .btn-ghost:hover { border-color: rgba(255,255,255,0.5); }
.dw-consent-banner .btn-primary { padding: .55rem 1.1rem; border-radius: var(--radius-pill); font-size: 0.875rem; background: var(--accent); color: #fff; }
.dw-consent-banner .btn-primary:hover { background: var(--accent-hover); }

.dw-consent-overlay {
  position: fixed; inset: 0; z-index: 950;
  display: none; align-items: center; justify-content: center;
  background: rgba(11,13,16,0.55); padding: var(--gutter);
}
.dw-consent-overlay.is-open { display: flex; }
.dw-consent-modal {
  width: min(560px, 100%); max-height: min(640px, 85vh); overflow-y: auto;
  background: var(--surface); border-radius: var(--radius-lg); box-shadow: var(--shadow-lg);
}
.dw-consent-modal-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 1.25rem 1.5rem; border-bottom: 1px solid var(--border);
  position: sticky; top: 0; background: var(--surface); z-index: 1;
}
.dw-consent-modal-header h3 { font-size: 1.1rem; }
.dw-consent-close { font-size: 1.4rem; line-height: 1; color: var(--text-secondary); padding: .25rem; border-radius: var(--radius-sm); }
.dw-consent-close:hover { color: var(--text); background: var(--accent-light); }
.dw-consent-modal-body { padding: 1.25rem 1.5rem; }
.dw-consent-modal-body > p { color: var(--text-secondary); font-size: 0.9rem; margin-bottom: 1.1rem; }
.dw-consent-row {
  display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem;
  padding: 1rem 0; border-top: 1px solid var(--border);
}
.dw-consent-row:first-of-type { border-top: none; }
.dw-consent-row-text strong { font-size: 0.95rem; }
.dw-consent-row-text p { font-size: 0.825rem; color: var(--text-secondary); margin-top: .25rem; line-height: 1.5; }
.dw-consent-policy-link { display: inline-block; margin-top: .5rem; font-size: 0.875rem; color: var(--accent); text-decoration: underline; text-underline-offset: 2px; }
.dw-consent-modal-footer { padding: 1.1rem 1.5rem 1.4rem; border-top: 1px solid var(--border); position: sticky; bottom: 0; background: var(--surface); }
.dw-consent-modal-footer .btn-primary { width: 100%; justify-content: center; padding: .8rem 1rem; border-radius: var(--radius-md); background: var(--accent); color: #fff; text-align: center; font-weight: 700; }
.dw-consent-modal-footer .btn-primary:hover { background: var(--accent-hover); }

.dw-toggle { position: relative; display: inline-flex; flex: none; width: 44px; height: 26px; cursor: pointer; }
.dw-toggle.is-disabled { cursor: not-allowed; opacity: .5; }
.dw-toggle input { position: absolute; inset: 0; opacity: 0; margin: 0; cursor: inherit; }
.dw-toggle-track {
  position: absolute; inset: 0; border-radius: var(--radius-pill); background: var(--border);
  transition: background var(--dur-fast) var(--ease-out);
}
.dw-toggle-track::before {
  content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px;
  border-radius: 50%; background: #fff; box-shadow: var(--shadow-xs);
  transition: transform var(--dur-fast) var(--ease-out);
}
.dw-toggle input:checked + .dw-toggle-track { background: var(--accent); }
.dw-toggle input:checked + .dw-toggle-track::before { transform: translateX(18px); }
.dw-toggle input:focus-visible + .dw-toggle-track { box-shadow: var(--shadow-focus); }

@media (max-width: 640px) {
  .dw-consent-banner { flex-direction: column; align-items: stretch; }
  .dw-consent-actions { justify-content: stretch; }
  .dw-consent-btn { flex: 1; text-align: center; }
}

/* =============================================================
   6. Sections — Home
   ============================================================= */
.hero {
  padding-block: clamp(3.5rem, 9vw, 7rem) clamp(2.5rem, 6vw, 4rem);
  text-align: center;
}
.hero h1 { max-width: 16ch; margin-inline: auto; }
.hero .lede { max-width: 46ch; margin: 1.25rem auto 0; }
.hero-cta { margin-top: 2.25rem; display: flex; gap: .9rem; justify-content: center; flex-wrap: wrap; }
.hero-privacy-note {
  margin-top: 1rem; display: flex; align-items: center; justify-content: center; gap: .5rem;
  font-size: 0.825rem; color: var(--text-secondary);
}
.hero-privacy-note svg { flex-shrink: 0; color: var(--success); }
.hero-visual { margin-top: clamp(2.5rem, 6vw, 4rem); }

.decision-strip {
  display: flex; align-items: flex-start; justify-content: center; gap: .25rem;
  max-width: 480px; margin-inline: auto;
}
.decision-strip .step {
  display: flex; flex-direction: column; align-items: center; gap: .5rem;
  width: 92px; text-align: center;
}
.decision-strip .step-icon {
  width: 52px; height: 52px; border-radius: 50%; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  background: var(--surface); border: 1px solid var(--border); color: var(--accent);
}
.decision-strip .step.is-accent .step-icon { background: var(--charcoal); color: #fff; border-color: var(--charcoal); }
.decision-strip .step-label { font-family: var(--font-display); font-weight: 700; font-size: 0.85rem; }
.decision-strip .arrow {
  color: var(--border); font-size: 1.3rem; flex-shrink: 0; align-self: center;
  margin-top: 26px; /* vertically centers with the icon circles, not the labels below */
}
.decision-strip .arrow { color: var(--text-secondary); font-size: 1.1rem; display: none; }
@media (min-width: 720px) { .decision-strip .arrow { display: inline; } }

/* One-time reveal, in sequence: Calculate -> Understand -> Decide.
   This strip is DecideWorth's core narrative, so it's the one place that
   earns a deliberate animated moment; everywhere else stays quiet. */
@keyframes dwChipIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
@keyframes dwChipInAccent { from { opacity: 0; transform: translateY(8px) scale(0.92); } 70% { transform: translateY(0) scale(1.05); } to { opacity: 1; transform: translateY(0) scale(1); } }
.decision-strip .step, .decision-strip .arrow { opacity: 0; animation: dwChipIn 0.5s var(--ease-out) forwards; }
.decision-strip .step.is-accent { animation-name: dwChipInAccent; animation-duration: 0.6s; }
.decision-strip > :nth-child(1) { animation-delay: 0s; }
.decision-strip > :nth-child(2) { animation-delay: 0.2s; }
.decision-strip > :nth-child(3) { animation-delay: 0.34s; }
.decision-strip > :nth-child(4) { animation-delay: 0.54s; }
.decision-strip > :nth-child(5) { animation-delay: 0.68s; }
@media (prefers-reduced-motion: reduce) {
  .decision-strip .step, .decision-strip .arrow { animation: none; opacity: 1; transform: none; }
}

.tool-grid { display: grid; gap: 1.25rem; grid-template-columns: 1fr; margin-top: 2rem; }
@media (min-width: 720px) { .tool-grid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 980px) { .tool-grid { grid-template-columns: repeat(3, 1fr); } }

.tool-card-link {
  display: block; padding: clamp(1.5rem, 3vw, 2.25rem);
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg);
  transition: transform var(--dur-base) var(--ease-out), box-shadow var(--dur-base) var(--ease-out), border-color var(--dur-base) var(--ease-out);
}
.tool-card-link:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: var(--accent); }
.tool-card-link .tool-icon {
  width: 48px; height: 48px; border-radius: var(--radius-md);
  background: var(--accent-light); color: var(--accent);
  display: flex; align-items: center; justify-content: center; margin-bottom: 1.25rem;
}
.tool-card-link h3 { margin-bottom: .5rem; }
.tool-card-link p { color: var(--text-secondary); font-size: 0.95rem; margin-bottom: 1rem; }
.tool-card-link .link-arrow { color: var(--accent); font-weight: 600; font-size: 0.9rem; display: inline-flex; align-items: center; gap: .3rem; }

.how-grid { display: grid; gap: 2rem; grid-template-columns: 1fr; margin-top: 2.5rem; }
@media (min-width: 720px) { .how-grid { grid-template-columns: repeat(4, 1fr); } }
.how-step { text-align: left; }
.how-step .step-num {
  width: 36px; height: 36px; border-radius: 50%; background: var(--charcoal); color: #fff;
  display: flex; align-items: center; justify-content: center; font-weight: 700; font-family: var(--font-display);
  margin-bottom: 1rem; font-size: 0.95rem;
}
.how-step h3 { font-size: 1.05rem; margin-bottom: .4rem; }
.how-step p { font-size: 0.9rem; color: var(--text-secondary); }

/* =============================================================
   7. Tool page shell
   ============================================================= */
.breadcrumb {
  padding-top: 1.25rem; font-size: 0.8rem; color: var(--text-secondary);
  display: flex; align-items: center; gap: .45rem; flex-wrap: wrap;
}
.breadcrumb a { color: var(--text-secondary); }
.breadcrumb a:hover { color: var(--accent); }
.breadcrumb [aria-current="page"] { color: var(--text); font-weight: 600; }
.breadcrumb-sep { color: var(--border); }

.tool-header { padding-block: clamp(2rem, 5vw, 3rem) 1.5rem; text-align: center; }
.tool-header h1 { max-width: 22ch; margin-inline: auto; }
.tool-header .lede { margin: .85rem auto 0; max-width: 48ch; }

.tool-layout {
  display: grid; gap: 1.5rem; grid-template-columns: 1fr;
  align-items: start;
}
@media (min-width: 1024px) {
  .tool-layout.has-rail { grid-template-columns: 1fr 300px; }
}

.tool-card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md); padding: clamp(1.25rem, 3.5vw, 2.25rem);
}

.form-section + .form-section { margin-top: 1.75rem; padding-top: 1.75rem; border-top: 1px solid var(--border); }
.form-section-title { font-size: 0.8rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; color: var(--text-secondary); margin-bottom: 1rem; }

.field-row { display: grid; gap: 1rem; grid-template-columns: 1fr; }
@media (min-width: 620px) { .field-row.cols-2 { grid-template-columns: 1fr 1fr; } .field-row.cols-3 { grid-template-columns: 1fr 1fr 1fr; } }
.compare-option-fields { border: 1px solid var(--border); border-radius: var(--radius-md); padding: 1rem 1.1rem 1.1rem; display: flex; flex-direction: column; gap: .9rem; }
.compare-option-fields legend { padding: 0 .4rem; font-family: var(--font-display); font-weight: 700; font-size: 0.9rem; color: var(--accent); }

.field { display: flex; flex-direction: column; gap: .4rem; }
.field label { font-size: 0.875rem; font-weight: 600; color: var(--text); }
.field .hint { font-size: 0.8rem; color: var(--text-secondary); }
.field .error-msg { font-size: 0.8125rem; color: var(--danger); display: none; }
.field.has-error .error-msg { display: block; }
.field.has-error input { border-color: var(--danger); }

.input, select.input {
  width: 100%; padding: .8rem 1rem; border: 1.5px solid var(--border); border-radius: var(--radius-sm);
  background: var(--surface); font-size: 1rem; transition: border-color var(--dur-fast) var(--ease-out), box-shadow var(--dur-fast) var(--ease-out);
}
.input:focus { outline: none; border-color: var(--accent); box-shadow: var(--shadow-focus); }
select.input { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%236B7280' stroke-width='1.6' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 1rem center; padding-right: 2.5rem; }

.currency-input { position: relative; }
.currency-input .symbol {
  position: absolute; left: 1rem; top: 50%; transform: translateY(-50%);
  color: var(--text-secondary); font-weight: 600; pointer-events: none;
}
.currency-input input { padding-left: 2.25rem; }
.currency-input.sym-wide .symbol { font-size: 0.85rem; }

.segmented { display: inline-flex; background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius-pill); padding: 3px; gap: 2px; }
.segmented button {
  padding: .55rem 1.1rem; border-radius: var(--radius-pill); font-size: 0.875rem; font-weight: 600; color: var(--text-secondary);
  transition: background var(--dur-fast) var(--ease-out), color var(--dur-fast) var(--ease-out);
}
.segmented button[aria-pressed="true"] { background: var(--charcoal); color: #fff; }

.details-toggle { margin-top: 1.75rem; }
.details-toggle > summary {
  cursor: pointer; list-style: none; display: flex; align-items: center; justify-content: space-between;
  padding: .9rem 0; font-weight: 600; font-size: 0.95rem; border-top: 1px solid var(--border);
}
.details-toggle > summary::-webkit-details-marker { display: none; }
.details-toggle > summary .chev { transition: transform var(--dur-base) var(--ease-out); color: var(--text-secondary); }
.details-toggle[open] > summary .chev { transform: rotate(180deg); }
.details-toggle .details-body { padding-top: .5rem; }

.finance-fields { display: none; margin-top: 1.75rem; padding-top: 1.75rem; border-top: 1px solid var(--border); }
.finance-fields.is-visible { display: block; }

.tool-submit { margin-top: 2rem; }

/* Result */
.result-panel { margin-top: 2rem; padding-top: 2rem; border-top: 1px solid var(--border); display: none; }
.result-panel.is-visible { display: block; }

.risk-banner {
  display: flex; align-items: flex-start; gap: 1rem;
  padding: 1.25rem 1.4rem; border-radius: var(--radius-md); margin-bottom: 1.75rem;
  border: 1px solid transparent;
}
.risk-banner[data-risk="comfortable"] { background: var(--success-bg); border-color: rgba(22,163,74,0.25); }
.risk-banner[data-risk="tight"] { background: var(--warning-bg); border-color: rgba(217,119,6,0.25); }
.risk-banner[data-risk="high"] { background: var(--danger-bg); border-color: rgba(220,38,38,0.25); }
.risk-banner .dot { width: 12px; height: 12px; border-radius: 50%; margin-top: 6px; flex-shrink: 0; }
.risk-banner[data-risk="comfortable"] .dot { background: var(--success); }
.risk-banner[data-risk="tight"] .dot { background: var(--warning); }
.risk-banner[data-risk="high"] .dot { background: var(--danger); }
.risk-banner .risk-label { font-family: var(--font-display); font-weight: 800; font-size: 1.05rem; margin-bottom: .3rem; }
.risk-banner[data-risk="comfortable"] .risk-label { color: var(--success); }
.risk-banner[data-risk="tight"] .risk-label { color: var(--warning); }
.risk-banner[data-risk="high"] .risk-label { color: var(--danger); }
.risk-banner .risk-copy { font-size: 0.925rem; color: var(--text); }
.risk-banner .risk-copy[data-savings-note] { color: var(--text-secondary); font-size: 0.85rem; margin-top: .35rem; }
.risk-banner .risk-disclaimer { font-size: 0.8rem; color: var(--text-secondary); margin-top: .5rem; }

/* Afford-it signature visual: a semicircle "financial health" gauge that
   fills toward the risk color. Purely additive to the risk banner below —
   the banner alone remains fully readable if this doesn't render. */
.gauge-wrap { display: flex; justify-content: center; margin-bottom: -.5rem; color: var(--accent); }
.gauge-svg { width: min(220px, 60vw); height: auto; }
.gauge-fill { transition: stroke-dashoffset 0.9s cubic-bezier(0.16, 1, 0.3, 1), color 0.3s var(--ease-out); }
.gauge-wrap[data-risk="comfortable"] { color: var(--success); }
.gauge-wrap[data-risk="tight"] { color: var(--warning); }
.gauge-wrap[data-risk="high"] { color: var(--danger); }
@media (prefers-reduced-motion: reduce) { .gauge-fill { transition: none; } }

.stat-grid { display: grid; gap: 1rem; grid-template-columns: repeat(2, 1fr); margin-bottom: 1.75rem; }
@media (min-width: 620px) { .stat-grid.cols-3 { grid-template-columns: repeat(3, 1fr); } .stat-grid.cols-4 { grid-template-columns: repeat(4, 1fr); } }
.stat-grid.secondary { margin-bottom: 1.25rem; }
.stat-grid.secondary .stat-value { font-size: clamp(0.95rem, 2vw, 1.15rem); }
.impact-sentence {
  font-family: var(--font-display); font-weight: 700; font-size: clamp(1.05rem, 2.6vw, 1.3rem);
  line-height: 1.4; margin-bottom: 1.5rem; color: var(--text);
}
.impact-sentence .em { color: var(--accent); font-family: var(--font-mono); font-weight: 700; }
.stat-grid.hero-stats .stat-card { padding: 1.25rem 1.35rem; }
.stat-grid.hero-stats .stat-value { font-size: clamp(1.3rem, 3vw, 1.7rem); }
.stat-card {
  background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius-md);
  padding: 1.1rem 1.25rem;
}
.stat-card .stat-label { font-size: 0.8rem; color: var(--text-secondary); font-weight: 600; margin-bottom: .35rem; }
.stat-card .stat-value { font-family: var(--font-mono); font-weight: 700; font-size: clamp(1.1rem, 2.4vw, 1.4rem); letter-spacing: -0.01em; font-feature-settings: "tnum" 1, "zero" 1; }
.stat-card .stat-sub { font-size: 0.78rem; color: var(--text-secondary); margin-top: .25rem; }

/* Real-life impact block */
.impact-block {
  background: var(--charcoal); color: #fff; border-radius: var(--radius-lg);
  padding: clamp(1.5rem, 4vw, 2.5rem); margin-bottom: 1.75rem;
}
.impact-block .impact-eyebrow { font-size: 0.8rem; color: rgba(255,255,255,0.55); font-weight: 600; text-transform: uppercase; letter-spacing: 0.04em; margin-bottom: 1rem; }
.impact-block .impact-price { font-family: var(--font-mono); font-weight: 700; font-size: clamp(1.85rem, 4.6vw, 2.8rem); margin-bottom: 1.5rem; letter-spacing: -0.01em; font-feature-settings: "tnum" 1, "zero" 1; }
.impact-list { display: grid; gap: 1rem; grid-template-columns: 1fr; }
@media (min-width: 620px) { .impact-list { grid-template-columns: repeat(3, 1fr); } }
.impact-item { display: flex; align-items: center; gap: .75rem; }
.impact-item .impact-icon {
  width: 40px; height: 40px; border-radius: var(--radius-sm); background: rgba(91,95,239,0.25); color: #A5A8FF;
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.impact-item .impact-value { font-family: var(--font-mono); font-weight: 700; font-size: 1.15rem; line-height: 1.15; font-feature-settings: "tnum" 1, "zero" 1; }
.impact-item .impact-caption { font-size: 0.78rem; color: rgba(255,255,255,0.55); }

/* Opportunity cost */
.opportunity-card { background: var(--accent-light); border-radius: var(--radius-lg); padding: clamp(1.25rem, 3vw, 2rem); margin-bottom: 1.75rem; }
.opportunity-card h3 { font-size: 1.05rem; margin-bottom: .75rem; }
.opportunity-rows { display: flex; flex-direction: column; gap: .6rem; margin-bottom: .75rem; }
.opportunity-row { display: flex; align-items: center; justify-content: space-between; padding: .7rem .9rem; background: var(--surface); border-radius: var(--radius-sm); font-size: 0.9rem; }
.opportunity-row .opp-label { font-weight: 500; }
.opportunity-row .opp-value { font-family: var(--font-mono); font-weight: 700; font-feature-settings: "tnum" 1, "zero" 1; }
.opportunity-note { font-size: 0.78rem; color: var(--text-secondary); }

/* Breakdown table (real-cost tool) */
.breakdown-table { width: 100%; border-collapse: collapse; font-size: 0.9rem; margin-bottom: 1.75rem; }
.breakdown-table th { text-align: left; font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.03em; color: var(--text-secondary); padding-bottom: .6rem; border-bottom: 1px solid var(--border); font-weight: 600; }
.breakdown-table td { padding: .85rem 0; border-bottom: 1px solid var(--border); }

/* Real-cost signature visual: the total literally built from its parts —
   a stacked bar that fills segment by segment, plus a matching legend, so
   "what does this really cost" reads as a decomposition, not just a sum. */
.cost-stack-wrap { margin-bottom: 1.75rem; }
.cost-stack {
  display: flex; width: 100%; height: 30px; border-radius: var(--radius-sm); overflow: hidden;
  background: var(--border); margin-bottom: .85rem;
}
.cost-stack-segment {
  height: 100%; width: 0%; background: var(--accent); transition: width 0.7s cubic-bezier(0.16, 1, 0.3, 1);
  border-right: 2px solid var(--surface);
}
.cost-stack-segment:last-child { border-right: none; }
@media (prefers-reduced-motion: reduce) { .cost-stack-segment { transition: none; } }
.cost-legend { display: flex; flex-wrap: wrap; gap: .5rem .9rem; }
.cost-legend-item { display: flex; align-items: center; gap: .45rem; font-size: 0.8rem; color: var(--text-secondary); }
.cost-legend-swatch { width: 10px; height: 10px; border-radius: 2px; flex-shrink: 0; background: var(--accent); }
.cost-legend-amount { font-family: var(--font-mono); font-weight: 600; color: var(--text); }

/* Subscriptions signature visual: each subscription "drops in" as its own
   row and fills with color — an accumulation, distinct from real-cost's
   single decomposed bar. */
@keyframes dwSlideIn { from { opacity: 0; transform: translateX(-10px); } to { opacity: 1; transform: translateX(0); } }
.accumulation-wrap { margin-bottom: 1.75rem; display: flex; flex-direction: column; gap: .5rem; }
.accumulation-row {
  position: relative; display: flex; align-items: center; justify-content: space-between;
  padding: .65rem .9rem; border-radius: var(--radius-sm); background: var(--bg); border: 1px solid var(--border);
  overflow: hidden; opacity: 0; animation: dwSlideIn 0.4s var(--ease-out) forwards;
}
.accumulation-row::before {
  content: ""; position: absolute; inset: 0; background: var(--accent-light); width: 0%; z-index: 0;
  transition: width 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}
.accumulation-row.is-filled::before { width: var(--fill, 0%); }
.accumulation-row .acc-name { position: relative; z-index: 1; font-size: 0.85rem; font-weight: 600; }
.accumulation-row .acc-amount { position: relative; z-index: 1; font-size: 0.85rem; font-family: var(--font-mono); font-weight: 700; }
.accumulation-more { font-size: 0.8rem; color: var(--text-secondary); padding: .2rem .9rem; }
@media (prefers-reduced-motion: reduce) {
  .accumulation-row { animation: none; opacity: 1; }
  .accumulation-row::before { transition: none; }
}
.breakdown-table td:last-child, .breakdown-table th:last-child { text-align: right; font-family: var(--font-mono); font-weight: 700; font-feature-settings: "tnum" 1, "zero" 1; }
.breakdown-table tr:last-child td { border-bottom: 0; }
.breakdown-table .row-emphasis td { font-size: 1.05rem; }

.expense-list { display: flex; flex-direction: column; gap: 1rem; margin-bottom: 1rem; }
.expense-entry { display: flex; flex-direction: column; gap: .5rem; }
.expense-list-actions { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: .75rem; }
.persist-note { font-size: 0.8rem; color: var(--text-secondary); }

/* Time-cost percent bar (time-cost tool) */
.percent-bar-wrap { margin-bottom: 1.75rem; }
.percent-bar-track {
  width: 100%; height: 14px; border-radius: var(--radius-pill); background: var(--border);
  overflow: hidden; margin-bottom: .6rem;
}
.percent-bar-fill {
  height: 100%; border-radius: var(--radius-pill); background: var(--accent);
  transition: width var(--dur-slow) var(--ease-out); width: 0%;
}
.percent-bar-label { font-size: 0.85rem; color: var(--text-secondary); text-align: center; }

/* Time-cost signature visual: a circular ring (distinct from afford-it's
   semicircle gauge) filling toward the share of the year the habit costs. */
.time-ring-wrap { position: relative; width: 160px; height: 160px; margin: 0 auto 1.75rem; }
.time-ring-svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.time-ring-fill { transition: stroke-dashoffset 0.9s cubic-bezier(0.16, 1, 0.3, 1); }
@media (prefers-reduced-motion: reduce) { .time-ring-fill { transition: none; } }
.time-ring-center {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  text-align: center; font-family: var(--font-mono); font-weight: 700; font-size: 0.95rem;
  color: var(--text); padding: 0 1.5rem; line-height: 1.3;
}

/* Scenario cards (buy-vs-wait tool) */
.scenario-grid { display: grid; gap: 1rem; grid-template-columns: 1fr; margin-bottom: 1.75rem; position: relative; }
@media (min-width: 620px) {
  .scenario-grid { grid-template-columns: repeat(3, 1fr); }
  /* Buy-vs-wait signature visual: a connecting timeline through the three
     scenario cards (now / 3 months / 6 months), reinforcing "a decision
     over time" rather than three unrelated stat boxes. */
  .scenario-grid.timeline::before {
    content: ""; position: absolute; top: 28px; left: calc(16.66% - .5rem); right: calc(16.66% - .5rem);
    height: 2px; background: var(--border); z-index: 0;
  }
  .scenario-grid.timeline .scenario-card { position: relative; z-index: 1; }
  .scenario-grid.timeline .scenario-card::before {
    content: ""; position: absolute; top: -20px; left: 50%; transform: translateX(-50%);
    width: 10px; height: 10px; border-radius: 50%; background: var(--accent); border: 2px solid var(--surface);
  }
}
.scenario-grid.timeline .scenario-card {
  opacity: 0; transform: translateY(8px); animation: dwChipIn 0.5s var(--ease-out) forwards;
}
.scenario-grid.timeline .scenario-card:nth-child(1) { animation-delay: 0s; }
.scenario-grid.timeline .scenario-card:nth-child(2) { animation-delay: 0.15s; }
.scenario-grid.timeline .scenario-card:nth-child(3) { animation-delay: 0.3s; }

/* Compare signature visual: head-to-head layout with a VS badge, cards
   reveal left-then-right rather than both at once. */
.compare-vs-grid {
  display: grid; grid-template-columns: 1fr; gap: 1rem; align-items: center; margin-bottom: 1.75rem; position: relative;
}
@media (min-width: 560px) { .compare-vs-grid { grid-template-columns: 1fr auto 1fr; gap: 1.25rem; } }
.compare-vs-grid .scenario-card {
  opacity: 0; transform: translateY(8px); animation: dwChipIn 0.5s var(--ease-out) forwards;
}
.compare-vs-grid .scenario-card:nth-child(1) { animation-delay: 0s; }
.compare-vs-grid .scenario-card:nth-child(3) { animation-delay: 0.2s; }
@media (prefers-reduced-motion: reduce) { .compare-vs-grid .scenario-card { animation: none; opacity: 1; transform: none; } }
.vs-badge {
  justify-self: center; width: 42px; height: 42px; border-radius: 50%;
  background: var(--charcoal); color: #fff; display: flex; align-items: center; justify-content: center;
  font-family: var(--font-display); font-weight: 800; font-size: 0.8rem; flex-shrink: 0;
  opacity: 0; animation: dwChipInAccent 0.5s var(--ease-out) 0.35s forwards;
}
@media (prefers-reduced-motion: reduce) { .vs-badge { animation: none; opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .scenario-grid.timeline .scenario-card { animation: none; opacity: 1; transform: none; } }
.scenario-card {
  background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius-md);
  padding: 1.1rem 1.25rem;
}
.scenario-card .scenario-title { font-family: var(--font-display); font-weight: 700; font-size: 0.95rem; margin-bottom: .6rem; }
.scenario-card .scenario-savings { font-family: var(--font-mono); font-weight: 700; font-size: 1.25rem; margin-bottom: .3rem; font-feature-settings: "tnum" 1, "zero" 1; }
.scenario-card .scenario-savings-label { font-size: 0.75rem; color: var(--text-secondary); margin-bottom: .75rem; }
.scenario-card .scenario-status { display: inline-block; font-size: 0.8rem; font-weight: 600; padding: .3rem .65rem; border-radius: var(--radius-pill); margin-bottom: .5rem; }
.scenario-card .scenario-status[data-status="ok"] { background: var(--success-bg); color: var(--success); }
.scenario-card .scenario-status[data-status="short"] { background: var(--warning-bg); color: var(--warning); }
.scenario-card .scenario-percent-row { font-size: 0.8rem; color: var(--text-secondary); }
.buyvswait-summary { background: var(--accent-light); border-radius: var(--radius-lg); padding: 1.25rem 1.5rem; margin-bottom: 1.75rem; font-size: 0.9rem; }
.buyvswait-summary strong { font-family: var(--font-display); }
.custom-days-field { margin-top: .1rem; }
.custom-days-field[hidden] { display: none; }
.expense-row { display: grid; grid-template-columns: 1fr 120px 130px 36px; gap: .6rem; align-items: end; }
@media (max-width: 619px) { .expense-row { grid-template-columns: 1fr 1fr; } .expense-row .field:nth-child(4) { grid-column: 1 / -1; } }
.expense-row .remove-btn {
  width: 40px; height: 40px; border-radius: var(--radius-sm); display: flex; align-items: center; justify-content: center;
  color: var(--text-secondary); border: 1.5px solid var(--border);
}
.expense-row .remove-btn:hover { color: var(--danger); border-color: var(--danger); }
.add-expense-btn {
  display: inline-flex; align-items: center; gap: .5rem; font-weight: 600; font-size: 0.9rem; color: var(--accent);
  padding: .7rem .3rem; min-height: 44px;
}
.add-expense-btn:hover { color: var(--accent-hover); }

/* Share actions */
.share-actions { display: flex; gap: .75rem; flex-wrap: wrap; margin-top: 1.5rem; }
.copy-feedback { font-size: 0.825rem; color: var(--success); font-weight: 600; opacity: 0; transition: opacity var(--dur-base) var(--ease-out); }
.copy-feedback.is-visible { opacity: 1; }

/* Share card canvas preview */
.share-card-preview { display: flex; justify-content: center; margin-top: 1.5rem; }
.share-card-preview canvas { max-width: 100%; height: auto; border-radius: var(--radius-md); box-shadow: var(--shadow-lg); }

/* Reset link */
.reset-link {
  display: inline-flex; align-items: center; gap: .4rem; font-size: 0.875rem; color: var(--text-secondary);
  margin-top: 1.5rem; padding: .6rem .2rem; min-height: 44px;
}
.reset-link:hover { color: var(--accent); }

/* Privacy badge + limits */
.tool-meta { display: flex; flex-direction: column; gap: .6rem; margin-top: 1.25rem; }
.tool-meta-top { margin-top: 0; margin-bottom: 1.5rem; }
.privacy-badge { display: flex; align-items: center; gap: .5rem; font-size: 0.825rem; color: var(--text-secondary); }
.privacy-badge svg { flex-shrink: 0; color: var(--success); }
.tool-disclaimer { font-size: 0.78rem; color: var(--text-secondary); }

/* Currency / settings bar above tool */
.tool-settings-bar { display: flex; justify-content: flex-end; margin-bottom: 1rem; }
.currency-select-wrap select { width: auto; padding: .5rem .9rem; padding-right: 2.25rem; font-size: 0.85rem; border-radius: var(--radius-pill); }

/* =============================================================
   8. Ad slots
   ============================================================= */
.ad-slot {
  min-height: 100px; display: flex; align-items: center; justify-content: center;
  border: 1px dashed var(--border); border-radius: var(--radius-md);
  color: var(--text-secondary); font-size: 0.75rem; letter-spacing: 0.05em; text-transform: uppercase;
  background: rgba(107,114,128,0.03); margin-block: 2rem;
}
.ad-slot.ad-leaderboard { min-height: 90px; }
.ad-slot.ad-incontent { min-height: 250px; max-width: 728px; margin-inline: auto; }
.ad-slot.ad-rail { min-height: 600px; }

/* =============================================================
   9. FAQ
   ============================================================= */
.faq-list { display: flex; flex-direction: column; gap: .75rem; }
.faq-item { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-md); }
.faq-item summary {
  cursor: pointer; list-style: none; padding: 1.1rem 1.4rem; font-weight: 600; font-size: 0.98rem;
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary .chev { color: var(--text-secondary); transition: transform var(--dur-base) var(--ease-out); flex-shrink: 0; }
.faq-item[open] summary .chev { transform: rotate(180deg); }
.faq-item .faq-body { padding: 0 1.4rem 1.25rem; color: var(--text-secondary); font-size: 0.925rem; line-height: 1.6; }

/* More tools */
.more-tools-grid { display: grid; gap: 1rem; grid-template-columns: 1fr; margin-top: 1.5rem; }
@media (min-width: 720px) { .more-tools-grid { grid-template-columns: repeat(2, 1fr); } }
.tool-card-mini {
  display: flex; align-items: center; gap: 1rem; padding: 1.1rem 1.25rem;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-md);
  transition: border-color var(--dur-base) var(--ease-out), transform var(--dur-base) var(--ease-out);
}
.tool-card-mini:hover { border-color: var(--accent); transform: translateX(3px); }
.tool-card-mini .tool-icon { width: 40px; height: 40px; border-radius: var(--radius-sm); background: var(--accent-light); color: var(--accent); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.tool-card-mini .mini-title { font-weight: 600; font-size: 0.95rem; }
.tool-card-mini .mini-sub { font-size: 0.8rem; color: var(--text-secondary); }
.tool-card-mini.is-disabled { opacity: 0.5; pointer-events: none; }

/* Coming soon pill grid (future tools teaser) */
.soon-grid { display: flex; flex-wrap: wrap; gap: .6rem; margin-top: 1.5rem; }
.soon-pill { padding: .55rem 1rem; border-radius: var(--radius-pill); background: var(--surface); border: 1px dashed var(--border); font-size: 0.85rem; color: var(--text-secondary); }

/* Popular row — compact, lighter than the full category grid below it */
.popular-row { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 1.5rem; }
.popular-pill {
  display: inline-flex; align-items: center; gap: .5rem; padding: .7rem 1.1rem;
  border-radius: var(--radius-pill); background: var(--surface); border: 1px solid var(--border);
  font-size: 0.9rem; font-weight: 600; transition: border-color var(--dur-fast) var(--ease-out), transform var(--dur-fast) var(--ease-out);
}
.popular-pill:hover { border-color: var(--accent); transform: translateY(-1px); }
.popular-pill .tool-icon { width: 22px; height: 22px; color: var(--accent); display: inline-flex; }
.explore-all-link { display: inline-flex; align-items: center; gap: .4rem; margin-top: 1.25rem; font-weight: 600; color: var(--accent); font-size: 0.9rem; }

/* Category groups ("What do you want to know?") */
.category-groups { display: flex; flex-direction: column; gap: 2.5rem; margin-top: 2.5rem; }
.category-group-header { display: flex; align-items: baseline; gap: .6rem; margin-bottom: 1rem; }
.category-group-header .cat-icon { font-size: 1.3rem; line-height: 1; }
.category-group-header h3 { font-size: 1.05rem; }
.category-group .more-tools-grid { margin-top: 0; }

/* My DecideWorth — local decision history */
.my-decideworth-panel {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: 1.75rem clamp(1.25rem, 4vw, 2.25rem); margin-top: 2rem;
}
.my-decideworth-summary { font-size: 0.9rem; color: var(--text-secondary); margin-bottom: .25rem; }
.my-decideworth-month { font-size: 0.8rem; color: var(--accent); font-weight: 600; margin-bottom: 1.25rem; }
.decision-list { display: flex; flex-direction: column; gap: .6rem; }
.decision-item {
  display: flex; align-items: center; gap: .85rem; padding: .8rem 1rem;
  border-radius: var(--radius-md); background: var(--bg); border: 1px solid var(--border);
}
.decision-item .decision-status { font-size: 1.1rem; line-height: 1; flex-shrink: 0; }
.decision-item .decision-body { flex: 1; min-width: 0; }
.decision-item .decision-label { font-weight: 600; font-size: 0.9rem; }
.decision-item .decision-result { font-size: 0.8rem; color: var(--text-secondary); font-family: var(--font-mono); }
.decision-item .decision-date { font-size: 0.75rem; color: var(--text-secondary); white-space: nowrap; }
.decision-item .decision-view {
  font-size: 0.75rem; font-weight: 700; color: var(--accent); padding: .35rem .65rem;
  border-radius: var(--radius-pill); border: 1px solid var(--accent); flex-shrink: 0; white-space: nowrap;
  min-height: 36px; display: inline-flex; align-items: center;
}
.decision-item .decision-view:hover { background: var(--accent); color: #fff; }
.decision-item .decision-delete {
  color: var(--text-secondary); border-radius: var(--radius-sm); flex-shrink: 0;
  width: 40px; height: 40px; display: inline-flex; align-items: center; justify-content: center;
}
.decision-item .decision-delete:hover { color: var(--danger); background: var(--danger-bg, rgba(220,38,38,0.08)); }
.my-decideworth-empty { font-size: 0.9rem; color: var(--text-secondary); padding: .5rem 0; }
.my-decideworth-actions { margin-top: 1.25rem; display: flex; justify-content: flex-end; }
.clear-history-btn {
  font-size: 0.8rem; color: var(--text-secondary); text-decoration: underline; text-underline-offset: 2px;
  padding: .6rem .2rem; min-height: 44px; display: inline-flex; align-items: center;
}
.clear-history-btn:hover { color: var(--danger); }

/* "What if...?" exploration chips, shown right after a result */
.whatif-block { margin-top: 1.75rem; }
.whatif-block .whatif-label { font-size: 0.8rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; color: var(--text-secondary); margin-bottom: .65rem; }
.whatif-chips { display: flex; flex-wrap: wrap; gap: .6rem; }
.whatif-chip {
  display: inline-flex; align-items: center; gap: .4rem; padding: .75rem 1rem; min-height: 44px;
  border-radius: var(--radius-pill); background: var(--accent-light); color: var(--accent);
  font-size: 0.85rem; font-weight: 600; transition: background var(--dur-fast) var(--ease-out);
}
.whatif-chip:hover { background: var(--accent); color: #fff; }

/* Save-decision feedback (reuses copy-feedback pattern) */
.save-decision-btn[data-saved="1"] { pointer-events: none; }

/* Legal pages */
.legal-updated { font-size: 0.85rem; color: var(--text-secondary); margin-bottom: 2rem; }

/* Contact form */
.contact-form { max-width: 480px; }
.form-status { font-size: 0.875rem; margin-top: 1rem; padding: .8rem 1rem; border-radius: var(--radius-sm); display: none; }
.form-status.is-visible { display: block; }
.form-status.is-success { background: var(--success-bg); color: var(--success); }
.form-status.is-error { background: var(--danger-bg); color: var(--danger); }

/* =============================================================
   10. State: no-js fallback
   ============================================================= */
.js-only { display: none; }
html.has-js .js-only { display: block; }
html.has-js .no-js-notice { display: none; }
.no-js-notice {
  padding: 1rem 1.25rem; background: var(--warning-bg); color: var(--warning);
  border-radius: var(--radius-md); font-size: 0.9rem; font-weight: 600;
}

/* =============================================================
   11. Responsive helpers
   ============================================================= */
@media (min-width: 540px)  { }
@media (min-width: 720px)  { }
@media (min-width: 960px)  { }
@media (min-width: 1280px) { }

/* =============================================================
   12. Reduced motion — only intrusive effects
   ============================================================= */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

/* =============================================================
   13. View transitions
   ============================================================= */
@view-transition { navigation: auto; }
::view-transition-old(root), ::view-transition-new(root) {
  animation-duration: 0.35s;
  animation-timing-function: cubic-bezier(0.16, 1, 0.3, 1);
}
