/* Design tokens shared by every page: civic palette (navy, teal, slate), type, space, radius, shadow.
   This is the only first-party file that may hold literal colors (scripts/report/quality.sh enforces it).
   Contrast on white: navy 15.6:1, teal-700 5.5:1, slate-600 7.6:1, slate-500 4.8:1, error 6.5:1, success 5.0:1, warning 5.0:1. */
:root {
  /* Brand */
  --wdmtpf-navy-900: #0b2545;
  --wdmtpf-navy-700: #13386b;
  --wdmtpf-teal-700: #0f766e;
  --wdmtpf-teal-100: #ccfbf1;
  --wdmtpf-color-primary: var(--wdmtpf-navy-900);
  --wdmtpf-color-primary-hover: var(--wdmtpf-navy-700);
  --wdmtpf-color-accent: var(--wdmtpf-teal-700);
  --wdmtpf-color-accent-soft: var(--wdmtpf-teal-100);

  /* Slate scale */
  --wdmtpf-slate-50: #f8fafc;
  --wdmtpf-slate-100: #f1f5f9;
  --wdmtpf-slate-200: #e2e8f0;
  --wdmtpf-slate-300: #cbd5e1;
  --wdmtpf-slate-400: #94a3b8;
  --wdmtpf-slate-500: #64748b;
  --wdmtpf-slate-600: #475569;
  --wdmtpf-slate-900: #0f172a;
  --wdmtpf-color-text: var(--wdmtpf-slate-900);
  --wdmtpf-color-muted: var(--wdmtpf-slate-600);
  --wdmtpf-color-surface: var(--wdmtpf-slate-50);
  --wdmtpf-color-border: var(--wdmtpf-slate-200);
  --wdmtpf-color-bg: #fff;
  --wdmtpf-color-black: #000;

  /* Semantic */
  --wdmtpf-color-success: #15803d;
  --wdmtpf-color-warning: #a16207;
  --wdmtpf-color-error: #b91c1c;

  /* Chart series (distinguishable, civic-toned) */
  --wdmtpf-chart-1: #13386b;
  --wdmtpf-chart-2: #0f766e;
  --wdmtpf-chart-3: #b45309;
  --wdmtpf-chart-4: #7c3aed;
  --wdmtpf-chart-5: #be123c;
  --wdmtpf-chart-6: #64748b;

  /* Type: system stack, no web-font download */
  --wdmtpf-font-body: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --wdmtpf-text-xs: 0.875rem;
  --wdmtpf-text-base: 1rem;
  --wdmtpf-text-lg: 1.25rem;
  --wdmtpf-text-xl: 1.5rem;
  --wdmtpf-text-2xl: 2rem;
  --wdmtpf-text-3xl: 2.5rem;

  /* 8px spacing scale */
  --wdmtpf-space-1: 0.5rem;
  --wdmtpf-space-2: 1rem;
  --wdmtpf-space-3: 1.5rem;
  --wdmtpf-space-4: 2rem;
  --wdmtpf-space-5: 3rem;
  --wdmtpf-radius: 0.5rem;
  --wdmtpf-shadow: 0 2px 4px rgba(15, 23, 42, 0.1);
  --wdmtpf-shadow-rgb: 15, 23, 42;

  /* Bootstrap 5 mapping so stock components pick the palette up */
  --bs-primary: var(--wdmtpf-color-primary);
  --bs-primary-rgb: 11, 37, 69;
  --bs-body-color: var(--wdmtpf-color-text);
  --bs-body-bg: var(--wdmtpf-color-bg);
  --bs-body-font-family: var(--wdmtpf-font-body);
  --bs-link-color: var(--wdmtpf-color-accent);
  --bs-link-color-rgb: 15, 118, 110;
  --bs-link-hover-color: var(--wdmtpf-navy-700);
  --bs-link-hover-color-rgb: 19, 56, 107;
  --bs-secondary-color: var(--wdmtpf-color-muted);
  --bs-border-color: var(--wdmtpf-color-border);
  --bs-border-radius: var(--wdmtpf-radius);
  --bs-success: var(--wdmtpf-color-success);
  --bs-warning: var(--wdmtpf-color-warning);
  --bs-danger: var(--wdmtpf-color-error);
  --bs-focus-ring-color: rgba(15, 118, 110, 0.35);
  --bs-info-bg-subtle: var(--wdmtpf-color-accent-soft);
  --bs-info-border-subtle: var(--wdmtpf-teal-700);
  --bs-info-text-emphasis: var(--wdmtpf-navy-900);
}

body { font-family: var(--wdmtpf-font-body); font-size: var(--wdmtpf-text-base); color: var(--wdmtpf-color-text); background: var(--wdmtpf-color-bg); }
a { text-decoration: underline; }
.navbar a, .btn, .nav-link, .navbar-brand { text-decoration: none; }
.btn-primary {
  --bs-btn-bg: var(--wdmtpf-color-primary);
  --bs-btn-border-color: var(--wdmtpf-color-primary);
  --bs-btn-hover-bg: var(--wdmtpf-color-primary-hover);
  --bs-btn-hover-border-color: var(--wdmtpf-color-primary-hover);
  --bs-btn-active-bg: var(--wdmtpf-color-primary-hover);
  --bs-btn-active-border-color: var(--wdmtpf-color-primary-hover);
  --bs-btn-disabled-bg: var(--wdmtpf-color-primary);
  --bs-btn-disabled-border-color: var(--wdmtpf-color-primary);
}
.btn-outline-primary {
  --bs-btn-color: var(--wdmtpf-color-primary);
  --bs-btn-border-color: var(--wdmtpf-color-primary);
  --bs-btn-hover-bg: var(--wdmtpf-color-primary);
  --bs-btn-hover-border-color: var(--wdmtpf-color-primary);
  --bs-btn-active-bg: var(--wdmtpf-color-primary);
  --bs-btn-active-border-color: var(--wdmtpf-color-primary);
}
.text-primary { color: var(--wdmtpf-color-primary) !important; }
.text-muted { color: var(--wdmtpf-color-muted) !important; }
.bg-primary { background-color: var(--wdmtpf-color-primary) !important; }
.site-header { background: var(--wdmtpf-color-surface); border-bottom: 1px solid var(--wdmtpf-color-border); }
.site-header .navbar-brand { font-weight: 600; color: var(--wdmtpf-color-primary); }
.site-footer { background: var(--wdmtpf-color-surface); border-top: 1px solid var(--wdmtpf-color-border); }
.card { border-radius: var(--wdmtpf-radius); box-shadow: var(--wdmtpf-shadow); }
.price, .tabular, .table td, .table th, #results, .display-4, .display-5, .display-6 { font-variant-numeric: tabular-nums; }
.tooltip-icon { cursor: help; color: var(--wdmtpf-color-muted); }
.how-to-use { background-color: var(--wdmtpf-color-accent-soft); border-left: 4px solid var(--wdmtpf-color-accent); }
@media print {
  .card { border: 1px solid var(--wdmtpf-slate-300); }
}

/* Header menu: 44px tap targets, visible focus, no sideways scroll when the menu opens */
.site-header .navbar-toggler { min-width: 44px; min-height: 44px; }
.site-header .navbar-toggler:focus-visible,
.site-header .nav-link:focus-visible { outline: 3px solid var(--wdmtpf-color-primary); outline-offset: 2px; }
.site-header .nav-link { min-height: 44px; display: flex; align-items: center; }
.site-header .nav-link.active { font-weight: 600; }
.site-header { overflow-x: clip; }
@media (max-width: 767.98px) {
  .site-header .navbar { padding-left: var(--wdmtpf-space-2); padding-right: var(--wdmtpf-space-2); }
}

/* Pricing plans */
.plan-list { list-style: none; padding: 0; margin: 0 0 var(--wdmtpf-space-3); }
.plan-list li { padding-left: 1.5rem; margin-bottom: var(--wdmtpf-space-1); position: relative; }
.plan-list li::before { content: "\2713"; position: absolute; left: 0; color: var(--wdmtpf-color-accent); font-weight: 700; }
.plan-premium { border: 2px solid var(--wdmtpf-color-primary); }
