/* Brand theming for the vendored CookieConsent library (public/cookieconsent.js /
   cookieconsent.css). Kept as a separate override file rather than editing the vendored
   CSS directly, so the pinned upstream file stays byte-diffable against the npm release
   (Ei-HB scratch-sites-standards §6: "self-host a pinned version... re-review before
   bumping" — that review is only meaningful if the vendored file is untouched).

   Values pulled directly from src/styles/site.css's own tokens — this file has no
   palette of its own, it just maps EI's existing --ink/--crimson/etc. onto the
   library's documented --cc-* theming API (the full list of which lives in
   cookieconsent.css's own :root block). */
:root {
  --cc-font-family: var(--font-body);

  --cc-bg: var(--paper);
  --cc-primary-color: var(--ink);
  --cc-secondary-color: var(--muted);

  --cc-modal-border-radius: var(--radius-lg);
  --cc-btn-border-radius: 999px; /* match .btn's pill shape in site.css */

  --cc-btn-primary-bg: var(--crimson);
  --cc-btn-primary-color: #fff;
  --cc-btn-primary-hover-bg: var(--crimson-deep);
  --cc-btn-primary-hover-color: #fff;

  /* Mirrors .btn--ghost: transparent fill, ink border/text, solid ink on hover. */
  --cc-btn-secondary-bg: transparent;
  --cc-btn-secondary-color: var(--ink);
  --cc-btn-secondary-border-color: var(--ink);
  --cc-btn-secondary-hover-bg: var(--ink);
  --cc-btn-secondary-hover-color: var(--cream);
  --cc-btn-secondary-hover-border-color: var(--ink);

  --cc-toggle-on-bg: var(--blue);
  --cc-toggle-off-bg: var(--hairline-dk);
  --cc-link-color: var(--blue);

  --cc-cookie-category-block-bg: var(--cream);
  --cc-cookie-category-block-border: var(--hairline);
  --cc-cookie-category-block-hover-bg: var(--hairline);
  --cc-cookie-category-block-hover-border: var(--hairline);

  --cc-footer-bg: var(--cream);
  --cc-footer-color: var(--muted);
  --cc-footer-border-color: var(--hairline);

  --cc-overlay-bg: rgba(0, 0, 63, 0.55); /* ink-tinted, not the library's flat black */
}

/* The library resets font-weight to 400 on everything (#cc-main * { all: unset }), so
   button label weight needs restoring explicitly to match site.css's .btn (weight 700) —
   a --cc-* variable does not cover this, there is no themeable font-weight token. */
#cc-main button.cm__btn,
#cc-main button.pm__btn {
  font-weight: 700;
}

/* The library reuses --cc-btn-border-radius for the preferences accordion containers,
   not just for buttons — see cookieconsent.css:
     #cc-main .pm__section,#cc-main .pm__section--toggle{border-radius:var(--cc-btn-border-radius)}
   The 999px pill above is right for buttons and wrong here. Once a section expands, the
   pill resolves to a large ellipse on a tall box, and because .pm__section-desc-wrapper
   is overflow:hidden it carves the bottom corners off the content — clipping the cookie
   table's first column and the right edge of the description. Give the accordion its own
   radius from the same token set instead of unsetting the button pill. */
#cc-main .pm__section,
#cc-main .pm__section--toggle { border-radius: var(--radius); }
#cc-main .pm__section-title { border-radius: var(--radius); }
#cc-main .pm__section--toggle .pm__section-desc-wrapper {
  border-bottom-left-radius: var(--radius);
  border-bottom-right-radius: var(--radius);
}

/* Give the disclosure table room to breathe now that it is no longer clipped: the cell
   padding the library ships is tuned for two short columns, not four. */
#cc-main .pm__section-table th,
#cc-main .pm__section-table td { padding: .5em .6em; vertical-align: top; }
