/*
 * CouncilWare Gateway — section schemes.
 *
 * The plugin decides which pages carry which scheme (_councilware_scheme meta,
 * resolved up the page tree) and emits cw-scheme-{slug} on <body>. This file
 * decides what each one looks like. That split is the portability contract in
 * miniature: swap the theme and every page keeps its scheme assignment and
 * simply renders in whatever the new theme says "camp" means.
 *
 * The header stays navy in every scheme. A scheme changes accent, buttons,
 * section fills, patch ring and link colour — nothing else.
 *
 * Every ratio below is measured with the WCAG 2.x relative-luminance formula,
 * not estimated, and re-measured whenever a value changes. No selection
 * available to staff may produce unreadable text.
 *
 * "on white" is against #FFFFFF; "body on fill" is #232528 on that scheme's
 * --cw-surface-alt. AA for normal text is 4.5:1.
 */

/* --- Default — Council Navy --------------------------------------------- */

/* Tokens are already navy in custom.css; this block exists so the default is
   visible alongside the others rather than implied. */
.cw-scheme-default {
	--cw-accent: #003f87;        /* 10.19:1 on white */
	--cw-accent-hover: #003366;  /* 12.61:1 on white */

	/*
	 * NOT the brand accent-blue #067EEB. That measures 4.04:1 on white, which
	 * is below AA 4.5 for body text, and 3.32:1 on the section fill -- it was
	 * the default link colour here until it was actually measured. #067EEB
	 * stays in the palette for display type and UI, not for links.
	 */
	--cw-link: #0061bf;          /* 6.07:1 on white, 4.98:1 on fill */
	--cw-surface: #fff;
	--cw-surface-alt: #e9e9e4;   /* body #232528 on this: 13.35:1 */
}

/* --- Order of the Arrow ------------------------------------------------- */

.cw-scheme-oa {
	--cw-accent: #ce1126;        /* 5.63:1 on white  */
	--cw-accent-hover: #860d1a;  /* 10.07:1 on white */
	--cw-link: #a50e1e;          /* 7.83:1 on white  */
	--cw-surface: #fff;
	--cw-surface-alt: #f5e9ea;   /* white text never sits on this; body #232528 is 12.97:1 */
}

/* --- Camp — green and brown --------------------------------------------- */

/*
 * The brand green #039B03 measures 3.69:1 on white and fails AA for text, so
 * it is not used here. #1F6B2C is the compliant substitute.
 */
.cw-scheme-camp {
	--cw-accent: #1f6b2c;        /* 6.57:1 on white  */
	--cw-accent-hover: #14491d;  /* 10.50:1 on white */
	--cw-link: #1f6b2c;          /* 6.57:1 on white  */
	--cw-surface: #fff;
	--cw-surface-alt: #f1efe7;   /* body #232528 on this: 13.35:1 */
}

/* --- Partner microsite -------------------------------------------------- */

.cw-scheme-partner {
	--cw-accent: #003f87;        /* 10.19:1 on white */
	--cw-accent-hover: #003366;  /* 12.61:1 on white */
	--cw-link: #0059bf;          /* 6.60:1 on white  */
	--cw-surface: #fff;
	--cw-surface-alt: #f4f6f9;
}

/* --- What a scheme actually repaints ------------------------------------ */

[class*="cw-scheme-"] .cw-section__heading {
	color: var(--cw-accent);
}

[class*="cw-scheme-"] .entry-content a:not([class]) {
	color: var(--cw-link);
}

[class*="cw-scheme-"] .cw-section--tint {
	background: var(--cw-surface-alt);
}

/*
 * The header is exempt by design — Drate's call on the kickoff. If a per-scheme
 * header tint is ever wanted it goes in as an explicit opt-in token, off by
 * default, not by widening this selector.
 */
