/* PollCheck US shell tokens: the UK chrome colours (style.css .header / .footer),
   named once here so site.css never carries a raw hex. Page colours stay in pc-tokens.css,
   apart from the WCAG AA overrides below (scoped to body.ps-site, so the UK copy of
   pc-tokens.css is unchanged). */
:root {
    --us-nav-bg: #1e3a5f;
    --us-nav-border: #152843;
    --us-nav-text: #ffffff;
    --us-nav-hover-bg: rgba(255, 255, 255, 0.1);
    --us-nav-rule: rgba(255, 255, 255, 0.15);
    --us-nav-accent: #fbbf24;
    --us-nav-accent-hover: #f59e0b;
    --us-footer-bg: #1e3a8a;
    --us-footer-text: #e2e8f0;      /* 10.6:1 on the footer navy */
    --us-footer-muted: #cbd5e1;     /* credits and "Built" line: 8.3:1 (was #94a3b8, 4.3:1) */
    --us-footer-rule: #3b5bb0;
    --us-nav-h: 60px;
    --us-gutter: 32px;
}

/* Contrast (WCAG AA, 4.5:1 for small text) on the white ground.
   Meta text #999 (2.8:1) -> #6b6b6b (5.3:1); muted #AAA -> #767676 (4.5:1);
   positive green #2A9D2A (3.4:1) -> #1f7a1f (5.4:1). */
body.ps-site:not(.dark-mode) {
    --pc-text-meta: #6b6b6b;
    --pc-text-muted: #767676;
    --pc-positive: #1f7a1f;
}
/* Dark slate ground (#1e293b): muted #64748b (2.9:1) -> #94a3b8 (5.7:1); the
   accent fill behind white button text #EA580C (3.6:1) -> #C2410C (5.2:1). */
body.ps-site.dark-mode {
    --pc-text-muted: #94a3b8;
    --pc-accent: #C2410C;
}

/* Party colour for text (names, figures, labels) at 4.5:1 or better on the
   page ground in both themes. Use these, not --pc-party-*, whenever party
   colour sits on text; fills and swatches keep --pc-party-*.
   Light: dem 6.9:1, rep 4.6:1, ind 5.7:1. Dark (#1e293b): dem 5.1:1, rep 5.0:1, ind 5.5:1. */
body.ps-site {
    --us-dem-text: var(--pc-party-dem);
    --us-rep-text: var(--pc-party-rep);
    --us-ind-text: color-mix(in srgb, var(--pc-party-usind) 80%, var(--pc-text));
}
body.ps-site.dark-mode {
    --us-dem-text: color-mix(in srgb, var(--pc-party-dem) 55%, var(--pc-text));
    --us-rep-text: color-mix(in srgb, var(--pc-party-rep) 62%, var(--pc-text));
    --us-ind-text: color-mix(in srgb, var(--pc-party-usind) 72%, var(--pc-text));
}
