/*
Theme Name:   CW Bird Atlas
Description:  A modern theme for Birds in Cheshire and Wirral, the breeding and wintering atlas. Pages are built from ACF Flexible Content blocks under the Classic Editor; species accounts, photos and maps come from the Cheshire & Wirral Bird Atlas plugin. Includes an importer for the original site's pages. Needs ACF PRO.
Version:      1.10.0
Requires at least: 6.3
Tested up to: 7.1
Requires PHP: 7.4
Author:       Plinkfizz
License:      GNU General Public License v2 or later
License URI:  https://www.gnu.org/licenses/gpl-2.0.html
Text Domain:  cw-atlas
Tags:         classic-editor, custom-menu, custom-logo, featured-images, translation-ready
*/

/* ---------- Fonts ----------
   Source Sans 3 and Source Serif 4 (SIL Open Font License), served from the theme:
   no requests to Google, and nothing sent to third parties. Latin only. */
@font-face { font-family: "Source Sans 3"; font-style: normal; font-weight: 200 900; font-display: swap; src: url("assets/fonts/source-sans-3-latin-wght-normal.woff2") format("woff2-variations"), url("assets/fonts/source-sans-3-latin-wght-normal.woff2") format("woff2"); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: "Source Sans 3"; font-style: italic; font-weight: 200 900; font-display: swap; src: url("assets/fonts/source-sans-3-latin-wght-italic.woff2") format("woff2-variations"), url("assets/fonts/source-sans-3-latin-wght-italic.woff2") format("woff2"); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: "Source Serif 4"; font-style: normal; font-weight: 200 900; font-display: swap; src: url("assets/fonts/source-serif-4-latin-opsz-normal.woff2") format("woff2-variations"), url("assets/fonts/source-serif-4-latin-opsz-normal.woff2") format("woff2"); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: "Source Serif 4"; font-style: italic; font-weight: 200 900; font-display: swap; src: url("assets/fonts/source-serif-4-latin-opsz-italic.woff2") format("woff2-variations"), url("assets/fonts/source-serif-4-latin-opsz-italic.woff2") format("woff2"); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }

@font-face { font-family: "Atkinson Hyperlegible"; font-style: normal; font-weight: 400; font-display: swap; src: url("assets/fonts/atkinson-hyperlegible-latin-400-normal.woff2") format("woff2"); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: "Atkinson Hyperlegible"; font-style: italic; font-weight: 400; font-display: swap; src: url("assets/fonts/atkinson-hyperlegible-latin-400-italic.woff2") format("woff2"); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: "Atkinson Hyperlegible"; font-style: normal; font-weight: 700; font-display: swap; src: url("assets/fonts/atkinson-hyperlegible-latin-700-normal.woff2") format("woff2"); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: "Atkinson Hyperlegible"; font-style: italic; font-weight: 700; font-display: swap; src: url("assets/fonts/atkinson-hyperlegible-latin-700-italic.woff2") format("woff2"); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }

/* ---------- Tokens ---------- */
:root {
	--ink: #16242f;
	--ink-soft: #33434f;
	--muted: #5b6b76;
	--bg: #ffffff;
	--surface: #f3f6f5;
	--sand: #f8f3e3;
	--sand-deep: #efe6c8;
	--navy: #1b3040;
	--navy-2: #24425a;
	--breeding: #3f7f2f;
	--breeding-soft: #edf5e8;
	--winter: #24719f;
	--winter-soft: #e6f1f8;
	--accent: #e7b22d;
	--accent-ink: #2a2005;
	--border: #dbe2e5;
	--link: #1f6a95;
	--link-hover: #13486a;
	--focus: #e7b22d;

	--radius: 12px;
	--radius-sm: 8px;
	--shadow: 0 1px 2px rgba(22, 36, 47, .06), 0 8px 24px -12px rgba(22, 36, 47, .22);
	--shadow-lg: 0 2px 4px rgba(22, 36, 47, .06), 0 22px 48px -20px rgba(22, 36, 47, .35);

	--max: 1200px;
	--narrow: 780px;
	--gutter: clamp(1rem, 4vw, 2rem);
	--section: clamp(2.5rem, 6vw, 4.5rem);

	--font: "Source Sans 3", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
	--font-serif: "Source Serif 4", Georgia, "Times New Roman", serif;

	--header-h: 52px;
	--sf-sticky-h: var(--header-h);

	/* Tokens read by the Cheshire & Wirral Bird Atlas plugin. */
	--sc-text: var(--ink);
	--sc-muted: var(--muted);
	--sc-bg: var(--bg);
	--sc-surface: var(--surface);
	--sc-border: var(--border);
	--sc-accent: var(--breeding);
	--sc-accent-text: #fff;
	--sc-radius: var(--radius);
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--header-h) + 1rem); }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body {
	margin: 0;
	font-family: var(--font);
	font-size: 1.125rem;
	line-height: 1.65;
	color: var(--ink);
	background: var(--bg);
	-webkit-font-smoothing: antialiased;
	text-rendering: optimizeLegibility;
}
img, svg, video, iframe { max-width: 100%; }
img { height: auto; vertical-align: middle; }
a { color: var(--link); text-decoration-thickness: 1px; text-underline-offset: .18em; }
a:hover { color: var(--link-hover); text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 3px; }
h1, h2, h3, h4, h5, h6 {
	font-family: var(--font-serif);
	font-weight: 600;
	line-height: 1.2;
	color: var(--navy);
	margin: 1.6em 0 .55em;
	letter-spacing: -.005em;
}
h1 { font-size: clamp(2rem, 4.2vw, 3rem); }
h2 { font-size: clamp(1.55rem, 3vw, 2.1rem); }
h3 { font-size: clamp(1.25rem, 2.2vw, 1.45rem); }
h4 { font-size: 1.15rem; }
p, ul, ol, dl, table, figure, blockquote { margin: 0 0 1.1em; }
ul, ol { padding-left: 1.3em; }
li + li { margin-top: .25em; }
hr { border: 0; border-top: 1px solid var(--border); margin: 2rem 0; }
sup, sub { line-height: 0; }
.screen-reader-text {
	position: absolute !important;
	width: 1px; height: 1px;
	margin: -1px; padding: 0;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}
.skip-link:focus {
	position: fixed !important;
	top: .75rem; left: .75rem;
	z-index: 1000;
	width: auto; height: auto;
	clip: auto;
	padding: .75rem 1.25rem;
	background: var(--accent);
	color: var(--accent-ink);
	font-weight: 700;
	border-radius: var(--radius-sm);
}
.icon { width: 1.25em; height: 1.25em; flex: none; }

/* ---------- Layout ---------- */
.container {
	width: 100%;
	max-width: calc(var(--max) + var(--gutter) * 2);
	margin: 0 auto;
	padding: 0 var(--gutter);
}
.container--narrow { max-width: calc(var(--narrow) + var(--gutter) * 2); }
.section { padding-top: var(--section); padding-bottom: var(--section); }

/* ---------- Buttons ---------- */
.button,
.wpcf7-submit,
button.button,
input[type="submit"] {
	display: inline-flex;
	align-items: center;
	gap: .5em;
	padding: .72em 1.35em;
	border: 2px solid var(--navy);
	border-radius: 999px;
	background: var(--navy);
	color: #fff;
	font: inherit;
	font-size: 1rem;
	font-weight: 600;
	line-height: 1.2;
	text-decoration: none;
	cursor: pointer;
	transition: background-color .15s, color .15s, border-color .15s, transform .15s;
}
.button:hover,
.wpcf7-submit:hover,
input[type="submit"]:hover { background: var(--navy-2); border-color: var(--navy-2); color: #fff; transform: translateY(-1px); }
.button--accent { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.button--accent:hover { background: #f0c24d; border-color: #f0c24d; color: var(--accent-ink); }
.button--ghost { background: transparent; color: var(--navy); }
.button--ghost:hover { background: var(--navy); color: #fff; }
.button--small { padding: .5em 1em; font-size: .92rem; }
.link-arrow { display: inline-flex; align-items: center; gap: .4em; font-weight: 600; text-decoration: none; }
.link-arrow .icon { transition: transform .15s; }
.link-arrow:hover .icon { transform: translateX(3px); }
.icon-button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: .4rem;
	min-width: 44px;
	height: 44px;
	padding: 0 .65rem;
	border: 1px solid transparent;
	border-radius: 999px;
	background: transparent;
	color: var(--navy);
	font: inherit;
	font-weight: 600;
	cursor: pointer;
}
.icon-button:hover { background: var(--surface); }
.menu-toggle .icon-close,
.menu-toggle[aria-expanded="true"] .icon-menu { display: none; }
.menu-toggle[aria-expanded="true"] .icon-close { display: inline; }

/* ---------- Pills ---------- */
.pills { display: flex; flex-wrap: wrap; gap: .4rem; list-style: none; padding: 0; margin: 0 0 1rem; }
.pills li + li { margin-top: 0; }
.pill {
	display: inline-flex;
	align-items: center;
	gap: .4em;
	padding: .25em .8em;
	border-radius: 999px;
	font-size: .85rem;
	font-weight: 600;
	background: var(--surface);
	color: var(--ink-soft);
}
.pill::before { content: ""; width: .6em; height: .6em; border-radius: 50%; background: currentColor; }
.pill--breeding { background: var(--breeding-soft); color: var(--breeding); }
.pill--wintering { background: var(--winter-soft); color: var(--winter); }
.pills--small .pill { font-size: .78rem; padding: .18em .65em; }

/* ---------- Header ---------- */
/* Banner band: the atlas banner on its own background colour, which carries
   on across wide screens. Scrolls away; only the menu bar below sticks. */
.site-banner {
	--banner-bg: #f7f5cf;
	background: var(--banner-bg);
	border-bottom: 1px solid rgba(66, 87, 106, .18);
	overflow: hidden;
}
.site-banner__inner { display: flex; align-items: center; }
.site-banner__link { display: block; line-height: 0; border-radius: 2px; }
.site-banner__link:focus-visible { outline-offset: -3px; }
.site-banner__image { display: block; width: 960px; max-width: 100%; height: auto; }
/* Wide screens: soften the painting's left edge into the background. */
@media (min-width: 961px) {
	.site-banner__image {
		-webkit-mask-image: linear-gradient(to right, transparent 0, #000 48px);
		mask-image: linear-gradient(to right, transparent 0, #000 48px);
	}
}
.site-banner .custom-logo-link { display: block; padding: .75rem 0; line-height: 0; }
.site-banner .custom-logo { height: auto; max-height: 120px; width: auto; max-width: 100%; }
/* Phones and tablets: drop the empty right-hand end of the banner so the title stays large. */
@media (max-width: 960px) {
	.site-banner__inner { padding-left: 0; padding-right: 0; }
	.site-banner__link { width: 100%; overflow: hidden; }
	.site-banner__image { width: 120%; max-width: none; }
}

/* Menu bar: slate from the banner lettering, cream text from its background. */
.site-header {
	--bar: #42576a;
	--bar-ink: #f7f5cf;
	--bar-hover: rgba(247, 245, 207, .12);
	position: sticky;
	top: 0;
	z-index: 100;
	background: var(--bar);
	color: var(--bar-ink);
	transition: box-shadow .2s;
}
.admin-bar .site-header { top: 32px; }
@media (max-width: 782px) { .admin-bar .site-header { top: 46px; } }
@media (max-width: 600px) { .admin-bar .site-header { top: 0; } }
.site-header.is-stuck { box-shadow: 0 6px 20px -12px rgba(22, 36, 47, .55); }
.site-header__inner {
	display: flex;
	align-items: center;
	gap: .75rem;
	min-height: 52px;
}
.site-header .icon-button { color: var(--bar-ink); }
.site-header .icon-button:hover,
.site-header .icon-button[aria-expanded="true"] { background: var(--bar-hover); }
.site-header :focus-visible { outline-color: var(--accent); }

/* Phones and tablets: the site title appears in the bar once the banner has scrolled away. */
.site-header__title {
	flex: 0 1 auto;
	min-width: 0;
	overflow: hidden;
	white-space: nowrap;
	text-overflow: ellipsis;
	font-family: var(--font-serif);
	font-weight: 600;
	font-size: 1.05rem;
	color: var(--bar-ink);
	text-decoration: none;
	max-width: 0;
	opacity: 0;
	transition: max-width .25s ease, opacity .2s ease;
}
.site-header__title:hover { color: #fff; }
.site-header.is-stuck .site-header__title { max-width: 22rem; opacity: 1; }
.site-header__actions { display: flex; align-items: center; gap: .25rem; margin-left: auto; }

.site-nav ul { list-style: none; margin: 0; padding: 0; }
.site-nav li { margin: 0; }
.site-nav a { text-decoration: none; }

@media (min-width: 1180px) {
	.menu-toggle { display: none; }
	.site-nav { display: flex; align-items: stretch; align-self: stretch; gap: .75rem; }
	.site-nav > ul { display: flex; align-items: stretch; gap: .1rem; margin-left: -.75rem; }
	.site-nav > ul > li { position: relative; display: flex; align-items: center; }
	.site-nav > ul > li > a {
		display: flex;
		align-items: center;
		align-self: stretch;
		padding: 0 .75rem;
		color: var(--bar-ink);
		font-weight: 600;
		font-size: .98rem;
		white-space: nowrap;
		box-shadow: inset 0 -3px 0 transparent;
		transition: background .15s, box-shadow .15s;
	}
	.site-nav > ul > li.menu-item-has-children > a { padding-right: .35rem; }
	.site-nav > ul > li > a:hover,
	.site-nav > ul > li:hover > a { color: #fff; background: var(--bar-hover); }
	.site-nav > ul > .current-menu-item > a,
	.site-nav > ul > .current-menu-ancestor > a,
	.site-nav > ul > .current-page-ancestor > a,
	.site-nav > ul > .current_page_item > a { color: #fff; box-shadow: inset 0 -3px 0 var(--accent); }
	.site-nav .submenu-toggle {
		display: inline-flex;
		align-items: center;
		align-self: stretch;
		padding: 0 .5rem 0 .2rem;
		border: 0;
		background: none;
		color: var(--bar-ink);
		cursor: pointer;
	}
	.site-nav > ul > li:hover > .submenu-toggle { background: var(--bar-hover); }
	.site-nav .submenu-toggle .icon { width: 1rem; height: 1rem; transition: transform .15s; }
	.site-nav .sub-menu {
		position: absolute;
		top: 100%;
		left: 0;
		min-width: 17rem;
		padding: .5rem;
		background: #fff;
		border: 1px solid var(--border);
		border-top: 3px solid var(--accent);
		border-radius: 0 0 var(--radius) var(--radius);
		box-shadow: var(--shadow-lg);
		opacity: 0;
		visibility: hidden;
		transform: translateY(-4px);
		transition: opacity .15s, transform .15s, visibility 0s .15s;
	}
	.site-nav li:hover > .sub-menu,
	.site-nav li:focus-within > .sub-menu,
	.site-nav li.is-open > .sub-menu { opacity: 1; visibility: visible; transform: none; transition-delay: 0s; }
	.site-nav li.is-open > .submenu-toggle .icon { transform: rotate(180deg); }
	.site-nav .sub-menu a { display: block; padding: .5rem .75rem; border-radius: var(--radius-sm); color: var(--ink); font-size: .98rem; line-height: 1.35; }
	.site-nav .sub-menu a:hover,
	.site-nav .sub-menu .current-menu-item > a { background: var(--surface); color: var(--navy); }
	.site-nav .sub-menu:has(> li:nth-child(9)) { columns: 2; column-gap: .5rem; min-width: 34rem; }
	.site-nav > ul > li:nth-last-child(-n+2) > .sub-menu { left: auto; right: 0; }
	.site-nav .sub-menu li { break-inside: avoid; }
	.site-nav__button { align-self: center; margin-left: .25rem; }
}
/* Wide screens have the full menu in the bar, so no title there. */
@media (min-width: 1180px) {
	.site-header__title { display: none; }
}

@media (max-width: 1179.98px) {
	.site-header__title { max-width: none; }
	.menu-toggle__label { font-size: .95rem; }
	.site-nav {
		position: fixed;
		inset: var(--header-top, var(--header-h)) 0 0 0;
		z-index: 99;
		display: none;
		overflow-y: auto;
		padding: 1rem var(--gutter) 3rem;
		background: #fff;
		color: var(--ink);
		border-top: 3px solid var(--accent);
	}
	.site-nav.is-open { display: block; }
	.site-nav > ul > li { position: relative; border-bottom: 1px solid var(--border); }
	.site-nav > ul > li > a { display: block; padding: .9rem 3rem .9rem 0; font-weight: 600; font-size: 1.1rem; color: var(--navy); }
	.site-nav .submenu-toggle {
		position: absolute;
		top: .35rem;
		right: 0;
		width: 44px;
		height: 44px;
		display: inline-flex;
		align-items: center;
		justify-content: center;
		border: 0;
		border-radius: 50%;
		background: var(--surface);
		color: var(--navy);
	}
	.site-nav .submenu-toggle .icon { transition: transform .15s; }
	.site-nav li.is-open > .submenu-toggle .icon { transform: rotate(180deg); }
	.site-nav .sub-menu { display: none; padding: 0 0 .75rem .75rem; }
	.site-nav li.is-open > .sub-menu { display: block; }
	.site-nav .sub-menu a { display: block; padding: .5rem 0; color: var(--ink-soft); }
	.site-nav__button { margin-top: 1.25rem; }
	html.nav-open { overflow: hidden; }
}
@media (max-width: 560px) {
	.site-header__title { font-size: 1rem; }
	.menu-toggle__label { display: none; }
}
@media (prefers-reduced-motion: reduce) {
	.site-header__title { transition: none; }
}

.site-search { padding: 1rem 0 1.25rem; border-top: 1px solid var(--border); background: #fff; }
.site-search .search-form { max-width: 640px; margin: 0 auto; }

/* ---------- Search form ---------- */
.search-form { position: relative; display: flex; }
.search-form__input {
	flex: 1;
	width: 100%;
	min-height: 48px;
	padding: .7rem 3.25rem .7rem 1.1rem;
	border: 1px solid var(--border);
	border-radius: 999px;
	background: #fff;
	color: var(--ink);
	font: inherit;
	font-size: 1rem;
}
.search-form__input:focus { outline: none; border-color: var(--winter); box-shadow: 0 0 0 3px rgba(36, 113, 159, .2); }
.search-form__submit {
	position: absolute;
	top: 4px; right: 4px; bottom: 4px;
	width: 40px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	border: 0;
	border-radius: 50%;
	background: var(--navy);
	color: #fff;
	cursor: pointer;
}
.search-form__submit .icon { width: 1.1rem; height: 1.1rem; }

/* ---------- Page header ---------- */
.page-header {
	position: relative;
	background: linear-gradient(180deg, var(--sand) 0%, #fbf8ee 100%);
	border-bottom: 1px solid var(--sand-deep);
	overflow: hidden;
}
.page-header::before {
	content: "";
	position: absolute;
	top: 0; right: 0; bottom: 0;
	width: min(48%, 680px);
	background-image:
		radial-gradient(circle, rgba(63, 127, 47, .55) 0 3px, transparent 3.6px),
		radial-gradient(circle, rgba(231, 178, 45, .7) 0 3px, transparent 3.6px),
		radial-gradient(circle, rgba(36, 113, 159, .45) 0 2px, transparent 2.6px);
	background-size: 26px 26px, 78px 52px, 52px 78px;
	background-position: 0 0, 13px 13px, 39px 0;
	-webkit-mask-image: linear-gradient(90deg, transparent 0%, rgba(0, 0, 0, .55) 45%, #000 100%);
	mask-image: linear-gradient(90deg, transparent 0%, rgba(0, 0, 0, .55) 45%, #000 100%);
	opacity: .45;
	pointer-events: none;
}
@media (max-width: 700px) { .page-header::before { width: 60%; opacity: .25; } }
.page-header--image::before { display: none; }
.page-header::after {
	content: "";
	position: absolute;
	right: -120px; top: -140px;
	width: 420px; height: 420px;
	border-radius: 50%;
	background: radial-gradient(circle, rgba(231, 178, 45, .18), rgba(231, 178, 45, 0) 70%);
	pointer-events: none;
}
.page-header__inner {
	position: relative;
	z-index: 1;
	display: grid;
	gap: 2rem;
	align-items: center;
	padding-top: clamp(1.75rem, 4vw, 3rem);
	padding-bottom: clamp(1.75rem, 4vw, 3rem);
}
.page-header--image .page-header__inner { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); }
@media (max-width: 800px) { .page-header--image .page-header__inner { grid-template-columns: 1fr; } }
.page-header__title { margin: .35rem 0 0; max-width: 24ch; }
.page-header__kicker { display: inline-flex; align-items: center; gap: .5rem; margin: .9rem 0 0; font-size: .8rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--breeding); }
.page-header__subtitle { margin: .4rem 0 0; font-family: var(--font-serif); font-style: italic; font-size: 1.25rem; color: var(--muted); }
.page-header__kicker::before { content: ""; width: 1.75rem; height: 2px; background: var(--accent); }
.page-header__intro { margin-top: .9rem; max-width: 62ch; font-size: 1.2rem; color: var(--ink-soft); }
.page-header__intro p:last-child { margin-bottom: 0; }
.page-header .pills { margin: 1rem 0 0; }
.page-header__media { margin: 0; }
.page-header__media img { width: 100%; border-radius: var(--radius); box-shadow: var(--shadow-lg); }

.breadcrumbs ol { display: flex; flex-wrap: wrap; gap: .25rem .5rem; list-style: none; margin: 0; padding: 0; font-size: .9rem; color: var(--muted); }
.breadcrumbs li { margin: 0; }
.breadcrumbs li + li::before { content: "›"; margin-right: .5rem; color: #a3adb4; }
.breadcrumbs a { color: var(--muted); text-decoration: none; }
.breadcrumbs a:hover { color: var(--navy); text-decoration: underline; }

/* ---------- Page body and section menu ---------- */
.page-body { padding-bottom: var(--section); }
.page-body > .entry-content:first-child { padding-top: var(--section); }
.page-body__grid {
	display: grid;
	grid-template-columns: 17.5rem minmax(0, 1fr);
	gap: clamp(1.5rem, 4vw, 3.5rem);
	align-items: start;
	padding-top: clamp(1.5rem, 4vw, 3rem);
}
.page-body__main { min-width: 0; }
.page-body__main > .entry-content { max-width: none; }
.page-body--with-nav .cb .container { max-width: none; padding: 0; }
.page-body--with-nav .cb { padding-top: 0; padding-bottom: 2rem; }
.page-body--with-nav .cb--bg-light,
.page-body--with-nav .cb--bg-sand,
.page-body--with-nav .cb--bg-breeding,
.page-body--with-nav .cb--bg-winter,
.page-body--with-nav .cb--bg-dark,
.page-body--with-nav .cb--bg-custom,
.page-body--with-nav .cb--has-image { padding: clamp(1.25rem, 3vw, 2rem); border-radius: var(--radius); margin-bottom: 2rem; }
.page-body--with-nav .cb--w-narrow .container > * { max-width: var(--narrow); }

.page-body__nav { position: sticky; top: calc(var(--header-h) + 1.5rem); max-height: calc(100vh - var(--header-h) - 3rem); overflow-y: auto; }
.section-nav { font-size: .98rem; }
.section-nav__details { border: 1px solid var(--border); border-radius: var(--radius); background: #fff; }
.section-nav__toggle { display: none; }
.section-nav__root {
	display: block;
	padding: 1rem 1.1rem .8rem;
	border-bottom: 1px solid var(--border);
	font-family: var(--font-serif);
	font-weight: 600;
	font-size: 1.1rem;
	color: var(--navy);
	text-decoration: none;
}
.section-nav ul { list-style: none; margin: 0; padding: .4rem; }
.section-nav ul ul { padding: 0 0 .25rem .9rem; border-left: 2px solid var(--border); margin: .1rem 0 .35rem .85rem; }
.section-nav li { margin: 0; }
.section-nav li a {
	display: block;
	padding: .42rem .7rem;
	border-radius: var(--radius-sm);
	color: var(--ink-soft);
	line-height: 1.35;
	text-decoration: none;
}
.section-nav li a:hover { background: var(--surface); color: var(--navy); }
.section-nav .is-current > a,
.section-nav__root.is-current { background: var(--breeding-soft); color: var(--breeding); font-weight: 600; }
.section-nav__root.is-current { background: var(--breeding-soft); }

@media (max-width: 900px) {
	.page-body__grid { grid-template-columns: 1fr; gap: 1.5rem; }
	.page-body__nav { position: static; max-height: none; overflow: visible; }
	.section-nav__toggle {
		display: flex;
		align-items: center;
		justify-content: space-between;
		padding: .9rem 1.1rem;
		font-weight: 700;
		color: var(--navy);
		cursor: pointer;
		list-style: none;
	}
	.section-nav__toggle::-webkit-details-marker { display: none; }
	.section-nav__details[open] .section-nav__toggle .icon { transform: rotate(180deg); }
	.section-nav__details:not([open]) .section-nav__root { display: none; }
	.section-nav__root { border-top: 1px solid var(--border); }
}

/* ---------- Entry content ---------- */
.entry-content > :first-child { margin-top: 0; }
.entry-content > :last-child { margin-bottom: 0; }
.entry-content h2 {
	position: relative;
	margin: 2em 0 .8em;
	padding-bottom: .45em;
	border-bottom: 1px solid var(--border);
	font-size: clamp(1.4rem, 2.4vw, 1.75rem);
}
.entry-content h2::after { content: ""; position: absolute; left: 0; bottom: -2px; width: 3rem; height: 3px; border-radius: 3px; background: var(--accent); }
.entry-content h3 { margin: 1.6em 0 .5em; font-size: 1.25rem; color: var(--navy); }
.entry-content h4 { margin: 1.4em 0 .4em; font-family: var(--font-sans, inherit); font-size: .9rem; letter-spacing: .08em; text-transform: uppercase; color: var(--breeding); }
.entry-content ul { list-style: none; padding-left: 1.4em; }
.entry-content ul > li { position: relative; margin-bottom: .45em; }
.entry-content ul > li::before { content: ""; position: absolute; left: -1.1em; top: .62em; width: .45em; height: .45em; border-radius: 50%; background: var(--breeding); box-shadow: 0 0 0 3px var(--breeding-soft); }
.entry-content ol { padding-left: 1.6em; }
.entry-content ol > li { margin-bottom: .45em; padding-left: .2em; }
.entry-content ol > li::marker { font-weight: 700; color: var(--navy); }
.entry-content hr { height: 0; margin: 2.5em auto; border: 0; border-top: 1px solid var(--border); overflow: visible; text-align: center; }
.entry-content hr::after { content: "• • •"; position: relative; top: -.8em; padding: 0 1rem; background: #fff; color: var(--accent); letter-spacing: .3em; }

/* The first paragraph of a content page reads as an introduction, with a drop cap. */
.page-body--with-nav .content-blocks > .cb-text:first-child .entry-content > p:first-child { font-size: 1.18rem; line-height: 1.7; color: var(--ink); }
.page-body--with-nav .content-blocks > .cb-text:first-child .entry-content > p:first-child::first-letter {
	float: left;
	margin: .06em .06em 0 -.02em;
	font-family: var(--font-serif);
	font-size: 3.6em;
	font-weight: 600;
	line-height: .82;
	color: var(--navy);
}
.entry-content::after { content: ""; display: table; clear: both; }
.entry-content .lead, .lead { font-size: 1.25rem; color: var(--ink-soft); }
.entry-content .small, .small { font-size: .92rem; color: var(--muted); }
.note {
	padding: 1rem 1.25rem;
	border-left: 4px solid var(--accent);
	background: var(--sand);
	border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}
.green-text { color: var(--breeding); font-weight: 600; }
.red-text { color: #b3261e; font-weight: 600; }
.entry-content blockquote {
	position: relative;
	margin: 2em 0;
	padding: 1.1em 1.5em 1.1em 3.25em;
	background: var(--sand);
	border-radius: 0 var(--radius) var(--radius) 0;
	border-left: 4px solid var(--accent);
	font-family: var(--font-serif);
	font-size: 1.2rem;
	color: var(--ink-soft);
}
.entry-content figure,
.atlas-figure,
.wp-caption { margin: 1.75rem 0; max-width: 100%; }
.entry-content figure:not(.wp-block-embed),
.atlas-figure,
.wp-caption { padding: .55rem; background: #fff; border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); }
.entry-content figure img,
.wp-caption img { display: block; margin: 0 auto; border-radius: calc(var(--radius) - 4px); }
.entry-content figcaption,
.wp-caption-text,
.caption,
.entry-content .wp-caption-text { margin: .6rem .35rem .2rem; font-size: .9rem; line-height: 1.45; color: var(--muted); }
.alignleft, .atlas-figure.alignleft { float: left; margin: .35rem 1.75rem 1rem 0; max-width: min(46%, 380px); }
.alignright, .atlas-figure.alignright { float: right; margin: .35rem 0 1rem 1.75rem; max-width: min(46%, 380px); }
.aligncenter { display: block; margin-left: auto; margin-right: auto; }
/* Each floated figure starts below the one before, so figures never stack into a staircase. */
.entry-content .alignleft, .entry-content .alignright { clear: both; }
@media (max-width: 640px) {
	.alignleft, .alignright, .atlas-figure.alignleft, .atlas-figure.alignright { float: none; margin: 1.25rem 0; max-width: 100%; }
}
.anchor { display: block; position: relative; top: -1rem; }

/* Tables */
.entry-content blockquote::before { content: "\201C"; position: absolute; left: .9rem; top: .35rem; font-family: var(--font-serif); font-size: 3.2rem; line-height: 1; color: var(--accent); }
.table-wrap { overflow-x: auto; margin: 1.75rem 0; border: 1px solid var(--border); border-radius: var(--radius); background: #fff; box-shadow: var(--shadow); -webkit-overflow-scrolling: touch; }
.table-wrap table { margin: 0; border: 0; }
.entry-content table,
.atlas-table { width: 100%; border-collapse: collapse; font-size: .96rem; line-height: 1.45; background: #fff; }
.entry-content th,
.entry-content td { padding: .7rem .9rem; border-bottom: 1px solid var(--border); text-align: left; vertical-align: top; }
.entry-content tr:last-child td { border-bottom: 0; }
.entry-content th,
.entry-content .toprow { background: #eaf1f5; color: var(--navy); font-weight: 700; border-bottom: 2px solid #c5d6e1; }
.entry-content .toprow strong { color: var(--navy); }
.entry-content tbody tr:nth-child(even) td:not(.toprow) { background: #f8fafb; }
.entry-content tbody tr:hover td:not(.toprow) { background: #f1f7ee; }
.entry-content td + td, .entry-content th + th { border-left: 1px solid #edf1f3; }
.entry-content .stan-tab td:first-child:not(.toprow) { font-weight: 600; color: var(--navy); }

/* Table titles from the old site sit just above their table. */
.entry-content p.caption:has(+ .table-wrap) { margin: 2.25rem 0 -.9rem; max-width: 70ch; font-size: .98rem; font-weight: 600; line-height: 1.5; color: var(--navy); }
.entry-content p.caption:has(+ .table-wrap) br { display: none; }

/* Gallery shown as cards: photo, title, description, credit. */
ul.photo-cards { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(var(--cols, 3), minmax(0, 1fr)); gap: clamp(1rem, 2vw, 1.5rem); }
.photo-cards--2 { --cols: 2; } .photo-cards--4 { --cols: 4; } .photo-cards--5 { --cols: 5; }
@media (max-width: 1100px) { .photo-cards--4, .photo-cards--5 { --cols: 3; } }
@media (max-width: 860px) { .photo-cards { --cols: 2 !important; } }
@media (max-width: 540px) { .photo-cards { --cols: 1 !important; } }
.photo-card { display: flex; flex-direction: column; margin: 0; overflow: hidden; background: #fff; border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); transition: box-shadow .2s, transform .2s; }
.photo-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg, var(--shadow)); }
.photo-card__media { display: block; aspect-ratio: 3 / 2; overflow: hidden; background: var(--surface); cursor: zoom-in; }
.photo-card__media img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.photo-card:hover .photo-card__media img { transform: scale(1.04); }
.photo-card__body { display: flex; flex-direction: column; gap: .45rem; flex: 1; padding: 1rem 1.15rem 1.15rem; }
.photo-card__title { margin: 0; font-size: 1.12rem; line-height: 1.3; color: var(--navy); }
.photo-card__text { margin: 0; font-size: .97rem; line-height: 1.55; color: var(--ink-soft); }
.photo-card__credit { margin: auto 0 0; padding-top: .5rem; font-size: .82rem; color: var(--muted); }

/* Code lists (e.g. habitat codes): one card per group. */
.code-groups { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 17rem), 1fr)); gap: 1.1rem; margin: 2rem 0; }
.code-groups--single { grid-template-columns: 1fr; }
.code-group { --g: var(--breeding); --g-soft: var(--breeding-soft); padding: 1.15rem 1.25rem 1.25rem; background: #fff; border: 1px solid var(--border); border-top: 4px solid var(--g); border-radius: var(--radius); box-shadow: var(--shadow); }
.code-group:nth-child(9n+2) { --g: #7a8b2c; --g-soft: #f2f5e3; }
.code-group:nth-child(9n+3) { --g: #9a7b1c; --g-soft: #fbf4dc; }
.code-group:nth-child(9n+4) { --g: #7d4e86; --g-soft: #f5eef7; }
.code-group:nth-child(9n+5) { --g: #c08a12; --g-soft: #fdf3d8; }
.code-group:nth-child(9n+6) { --g: #5b6b76; --g-soft: #eef2f4; }
.code-group:nth-child(9n+7) { --g: var(--winter); --g-soft: var(--winter-soft); }
.code-group:nth-child(9n+8) { --g: #1d8a8a; --g-soft: #e4f4f3; }
.code-group:nth-child(9n+9) { --g: #8a5a3c; --g-soft: #f6ede7; }
.entry-content .code-group__title { display: flex; align-items: center; gap: .7rem; margin: 0 0 .9rem; padding: 0; border: 0; font-size: 1.15rem; color: var(--ink); }
.entry-content .code-group__title::after { display: none; }
.code-badge { display: inline-grid; place-items: center; flex: none; width: 2.3rem; height: 2.3rem; border-radius: 50%; background: var(--g); color: #fff; font-family: var(--font-serif); font-size: 1.15rem; font-weight: 700; }
.code-list { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: .1rem .75rem; margin: 0; }
.code-list dt { align-self: start; min-width: 2.4rem; margin: .3rem 0; padding: .1rem .45rem; border-radius: 6px; background: var(--g-soft, var(--breeding-soft)); color: var(--g, var(--breeding)); font-weight: 700; font-size: .9rem; text-align: center; font-variant-numeric: tabular-nums; }
.code-list dd { margin: 0; padding: .3rem 0; border-bottom: 1px dashed var(--border); line-height: 1.45; }
.code-list dd:last-of-type { border-bottom: 0; }

/* On this page (built by theme.js on long pages) */
.page-toc { margin: 0 0 2rem; padding: 1rem 1.25rem; border: 1px solid var(--border); border-left: 4px solid var(--accent); border-radius: var(--radius); background: var(--surface); }
.page-toc__title { margin: 0 0 .5rem; font-size: .8rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.page-toc ol { columns: 2 14rem; column-gap: 2rem; margin: 0; padding-left: 1.3em; }
.page-toc li { break-inside: avoid; margin: .2rem 0; }
.page-toc li::marker { color: var(--muted); font-size: .9em; }
.page-toc a { text-decoration: none; font-weight: 600; }
.page-toc a:hover { text-decoration: underline; }

/* Previous / next page in a section */
.page-pager { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin: 2.5rem 0 1rem; padding-top: 2rem; border-top: 1px solid var(--border); }
.page-pager__link { display: flex; flex-direction: column; gap: .2rem; padding: 1rem 1.25rem; border: 1px solid var(--border); border-radius: var(--radius); background: #fff; color: var(--ink); text-decoration: none; transition: border-color .15s, box-shadow .15s, transform .15s; }
.page-pager__link:hover { border-color: #c8d3d8; box-shadow: var(--shadow); transform: translateY(-2px); color: var(--ink); }
.page-pager__label { display: inline-flex; align-items: center; gap: .35rem; font-size: .8rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.page-pager__label .icon { width: 1em; height: 1em; }
.page-pager__title { font-family: var(--font-serif); font-size: 1.15rem; font-weight: 600; color: var(--navy); }
.page-pager__link--next { grid-column: 2; text-align: right; align-items: flex-end; }
@media (max-width: 600px) { .page-pager { grid-template-columns: 1fr; } .page-pager__link--next { grid-column: 1; } }

.pills .pill--time { background: #fff; border-color: var(--border); color: var(--muted); }

/* ---------- Content blocks ---------- */
.content-blocks { display: flow-root; }
.cb { padding-top: var(--section); padding-bottom: var(--section); }
.cb:not([class*="cb--bg-"]):not(.cb--has-image) + .cb:not([class*="cb--bg-"]):not(.cb--has-image) { padding-top: 0; }
.cb--bg-light + .cb--bg-light, .cb--bg-sand + .cb--bg-sand { padding-top: 0; }
.cb__title { margin: 0 0 1rem; }
.cb__intro { max-width: 62ch; margin-bottom: 2rem; font-size: 1.15rem; color: var(--ink-soft); }
.cb__intro p:last-child { margin-bottom: 0; }
.cb__more { margin: 2rem 0 0; }
.cb--bg-light { background: var(--surface); }
.cb--bg-sand { background: var(--sand); }
.cb--bg-breeding { background: var(--breeding-soft); }
.cb--bg-winter { background: var(--winter-soft); }
.cb--bg-dark { background: var(--navy); }
.cb--light-text { color: #e8eef2; }
.cb--light-text :is(h2, h3, h4, .cb__title, .hero__heading) { color: #fff; }
.cb--light-text a:not(.button) { color: #ffd36b; }
.cb--light-text .cb__intro { color: #c9d6de; }
.cb--line { border-top: 1px solid var(--border); padding-top: var(--section) !important; }

/* Colours tab: values arrive as CSS variables on the block (see cwat_block_colours()). */
.cb.cb--bg-custom { background: var(--cb-bg); }
.cb.cb--has-image {
	position: relative;
	isolation: isolate;
	background-image: var(--cb-image);
	background-size: cover;
	background-position: var(--cb-image-pos, center);
}
.cb--has-image::before {
	content: "";
	position: absolute;
	inset: 0;
	z-index: -1;
	background: var(--cb-overlay, #000);
	opacity: var(--cb-overlay-alpha, .4);
	border-radius: inherit;
}
.cb--text-colour { color: var(--cb-text); }
.cb--text-colour :is(.cb__intro, .hero__lead, .stats__label, .quote__text) { color: inherit; }
.cb--heading-colour :is(h1, h2, h3, h4, h5, h6, .cb__title, .hero__heading) { color: var(--cb-heading); }
.cb--link-colour a:not(.button) { color: var(--cb-link); }
.cb--button-colour { --accent: var(--cb-button); --accent-ink: var(--cb-button-ink); }
.cb--button-colour :is(.button, .wpcf7-submit, input[type="submit"]):not(.button--ghost) { background: var(--cb-button); border-color: var(--cb-button); color: var(--cb-button-ink); }
.cb--button-colour :is(.button, .wpcf7-submit, input[type="submit"]):not(.button--ghost):hover { background: var(--cb-button); border-color: var(--cb-button); color: var(--cb-button-ink); filter: brightness(.92); }
.cb--button-colour .button--ghost { border-color: var(--cb-button); color: var(--cb-button); }
.cb--button-colour .button--ghost:hover { background: var(--cb-button); color: var(--cb-button-ink); }
.cb--line.cb--line-colour { border-top-color: var(--cb-line); }
.cb--pt-none { padding-top: 0 !important; }
.cb--pt-small { padding-top: 1.5rem !important; }
.cb--pt-medium { padding-top: 3rem !important; }
.cb--pt-large { padding-top: 5rem !important; }
.cb--pt-xlarge { padding-top: 7rem !important; }
.cb--pb-none { padding-bottom: 0 !important; }
.cb--pb-small { padding-bottom: 1.5rem !important; }
.cb--pb-medium { padding-bottom: 3rem !important; }
.cb--pb-large { padding-bottom: 5rem !important; }
.cb--pb-xlarge { padding-bottom: 7rem !important; }
.cb--align-center { text-align: center; }
.cb--align-center .cb__intro { margin-left: auto; margin-right: auto; }
.cb--align-right { text-align: right; }
.cb--w-narrow > .container { max-width: calc(var(--narrow) + var(--gutter) * 2); }
.cb--w-wide > .container { max-width: calc(1440px + var(--gutter) * 2); }
.cb--w-full > .container { max-width: none; }
@media (max-width: 767px) { .cb--only-desktop { display: none !important; } }
@media (min-width: 768px) { .cb--only-mobile { display: none !important; } }
.cb-text .entry-content { max-width: none; }
.cb-text.cb--align-center .entry-content { margin: 0 auto; }

/* Hero */
.cb-hero { padding-top: clamp(1.5rem, 4vw, 3rem); padding-bottom: clamp(2rem, 5vw, 4rem); background: linear-gradient(180deg, var(--sand) 0%, #fbf8ee 70%, #fff 100%); }
.cb-hero.cb--bg-dark { background: var(--navy); }
.hero { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: clamp(1.5rem, 5vw, 4rem); align-items: center; }
.hero__heading { margin: 0 0 1rem; font-size: clamp(2.1rem, 5vw, 3.6rem); line-height: 1.08; }
.hero__lead { font-size: clamp(1.1rem, 1.8vw, 1.3rem); color: var(--ink-soft); max-width: 56ch; }
.cb--light-text .hero__lead { color: #d3dee5; }
.hero__buttons { display: flex; flex-wrap: wrap; gap: .75rem; margin: 1.75rem 0 0; }
.hero__media { position: relative; aspect-ratio: 16 / 10; border-radius: calc(var(--radius) + 6px); overflow: hidden; box-shadow: var(--shadow-lg); background: var(--sand-deep); }
.cb-hero--large .hero__media { aspect-ratio: 4 / 3; }
@media (max-width: 860px) {
	.hero { grid-template-columns: 1fr; }
	.hero__media { order: -1; }
}
.cb-hero--cover { padding: 0; background: var(--navy); }
.cb-hero--cover > .container { max-width: none; padding: 0; }
.cb-hero--cover .hero { position: relative; display: block; min-height: clamp(420px, 62vh, 640px); }
.cb-hero--cover.cb-hero--large .hero { min-height: clamp(520px, 82vh, 820px); }
.cb-hero--cover .hero__media { position: absolute; inset: 0; aspect-ratio: auto; border-radius: 0; box-shadow: none; }
.cb-hero--cover .hero__media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(16, 29, 39, .85) 0%, rgba(16, 29, 39, .45) 55%, rgba(16, 29, 39, .1) 100%); pointer-events: none; }
.cb-hero--cover .hero__text {
	position: relative;
	z-index: 2;
	max-width: calc(var(--max) + var(--gutter) * 2);
	margin: 0 auto;
	padding: clamp(3rem, 10vw, 7rem) var(--gutter);
	color: #fff;
}
.cb-hero--cover .hero__heading { color: #fff; max-width: 18ch; }
.cb-hero--cover .hero__lead { color: #e4ecf1; }
.cb-hero--cover .button--ghost { color: #fff; border-color: #fff; }
.cb-hero--cover .button--ghost:hover { background: #fff; color: var(--navy); }
.cb-hero--cover .slideshow__caption { z-index: 3; }

/* Slideshow (hero) */
.slideshow__slide { position: absolute; inset: 0; margin: 0; opacity: 0; transition: opacity 1.2s ease; }
.slideshow__slide.is-active { opacity: 1; }
.slideshow__slide img { width: 100%; height: 100%; object-fit: cover; }
.slideshow__caption {
	position: absolute;
	left: .75rem; bottom: .75rem;
	display: flex;
	flex-direction: column;
	padding: .45rem .8rem;
	border-radius: var(--radius-sm);
	background: rgba(16, 29, 39, .72);
	color: #fff;
	font-size: .9rem;
	line-height: 1.3;
}
.slideshow__caption span { color: #cdd8df; font-size: .82rem; }
.slideshow__dots { position: absolute; right: .9rem; bottom: .9rem; z-index: 3; display: flex; gap: .35rem; }
.slideshow__dots button { width: 10px; height: 10px; padding: 0; border: 0; border-radius: 50%; background: rgba(255, 255, 255, .55); cursor: pointer; }
.slideshow__dots button[aria-current="true"] { background: #fff; transform: scale(1.25); }
.slideshow__counter { position: absolute; right: .9rem; bottom: .9rem; z-index: 3; margin: 0; padding: .1rem .6rem; border-radius: 999px; background: rgba(16, 29, 39, .7); color: #fff; font-size: .85rem; font-variant-numeric: tabular-nums; }
.slideshow__pause { position: absolute; right: .75rem; top: .75rem; z-index: 3; width: 36px; height: 36px; border: 0; border-radius: 50%; background: rgba(16, 29, 39, .6); color: #fff; cursor: pointer; font-size: .8rem; }

/* Image and text */
.image-text { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(1.5rem, 5vw, 4rem); align-items: center; }
.cb-image-text--right .image-text__media { order: 2; }
.image-text__media { margin: 0; }
.image-text__media img { width: 100%; border-radius: var(--radius); box-shadow: var(--shadow); }
.image-text__media figcaption { margin-top: .5rem; font-size: .9rem; color: var(--muted); }
@media (max-width: 800px) { .image-text { grid-template-columns: 1fr; } .cb-image-text--right .image-text__media { order: 0; } }

/* Cards */
.card-grid { display: grid; gap: clamp(1rem, 2.5vw, 1.75rem); grid-template-columns: repeat(var(--cols, 3), minmax(0, 1fr)); }
.card-grid--2 { --cols: 2; }
.card-grid--3 { --cols: 3; }
.card-grid--4 { --cols: 4; }
@media (max-width: 1000px) { .card-grid--4 { --cols: 2; } .card-grid--3 { --cols: 2; } }
@media (max-width: 600px) { .card-grid { --cols: 1 !important; } }
.card { position: relative; display: flex; flex-direction: column; min-width: 0; text-align: left; }
.card--panel { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; transition: transform .18s, box-shadow .18s, border-color .18s; }
.card--link:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); border-color: #c8d3d8; }
.card__media { display: block; margin: 0; aspect-ratio: 3 / 2; overflow: hidden; background: var(--sand); }
.card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.card--link:hover .card__media img { transform: scale(1.04); }
.card--plain .card__media { border-radius: var(--radius); }
.card__body { display: flex; flex-direction: column; flex: 1; padding: 1.15rem 1.25rem 1.35rem; }
.card--plain .card__body { padding: 1rem 0 0; }
.card__title { margin: 0 0 .45rem; font-size: 1.25rem; }
.card__title a { color: var(--navy); text-decoration: none; }
.card__title a::after { content: ""; position: absolute; inset: 0; z-index: 1; }
.card__title a:hover { text-decoration: underline; }
.card__text { margin: 0; color: var(--ink-soft); font-size: 1rem; line-height: 1.55; }
.card__more { margin-top: auto; padding-top: .9rem; color: var(--breeding); }
.card__more .icon { transition: transform .18s; }
.card--link:hover .card__more .icon { transform: translateX(4px); }
.card--page { border-top: 4px solid var(--breeding); }
.entry-meta { margin: 0 0 .35rem; font-size: .88rem; color: var(--muted); }
.cb--light-text .card--panel { color: var(--ink); }

/* Species cards */
.species-card__media { position: relative; aspect-ratio: 5 / 4; }
.species-card__media figcaption { position: absolute; right: .5rem; bottom: .5rem; padding: .15rem .5rem; border-radius: 4px; background: rgba(16, 29, 39, .7); color: #fff; font-size: .75rem; }
.species-card__sci { margin: 0 0 .75rem; font-family: var(--font-serif); font-style: italic; color: var(--muted); font-size: .98rem; }
.species-card .pills { margin: auto 0 0; }

/* Species list (search results) */
.species-list { list-style: none; margin: 0 0 2.5rem; padding: 0; display: grid; gap: .6rem; }
.species-list li { margin: 0; }
.species-row__link {
	display: grid;
	grid-template-columns: 64px minmax(0, 1fr) auto;
	gap: 1rem;
	align-items: center;
	padding: .6rem 1rem .6rem .6rem;
	border: 1px solid var(--border);
	border-radius: var(--radius);
	background: #fff;
	color: var(--ink);
	text-decoration: none;
	transition: border-color .15s, box-shadow .15s;
}
.species-row__link:hover { border-color: #c2cfd5; box-shadow: var(--shadow); color: var(--ink); }
.species-row__photo { width: 64px; height: 64px; border-radius: var(--radius-sm); overflow: hidden; background: var(--sand); }
.species-row__photo img { width: 100%; height: 100%; object-fit: cover; }
.species-row__names { display: flex; flex-direction: column; min-width: 0; }
.species-row__name { font-weight: 700; color: var(--navy); }
.species-row__sci { font-family: var(--font-serif); font-style: italic; color: var(--muted); font-size: .95rem; }
.species-row__seasons { display: flex; gap: .3rem; flex-wrap: wrap; justify-content: flex-end; }
@media (max-width: 520px) { .species-row__link { grid-template-columns: 52px minmax(0, 1fr); } .species-row__photo { width: 52px; height: 52px; } .species-row__seasons { grid-column: 2; justify-content: flex-start; } }

/* Stats */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 1rem; margin: 0; }
.stats__item { display: flex; flex-direction: column-reverse; justify-content: flex-end; padding: 1.4rem 1.5rem; border-radius: var(--radius); background: #fff; border: 1px solid var(--border); box-shadow: var(--shadow); }
.stats__value { margin: 0 0 .3rem; font-family: var(--font-serif); font-weight: 600; font-size: clamp(2.1rem, 4vw, 2.9rem); line-height: 1; color: var(--breeding); font-variant-numeric: tabular-nums; }
.stats__item:nth-child(even) .stats__value { color: var(--winter); }
.stats__label { color: var(--ink-soft); font-size: 1rem; line-height: 1.4; }
.cb--light-text .stats__item { background: rgba(255, 255, 255, .06); border-color: rgba(255, 255, 255, .12); box-shadow: none; }
.cb--light-text .stats__value { color: var(--accent); }
.cb--light-text .stats__label { color: #d3dee5; }

/* Gallery */
.gallery-slider { max-width: 900px; }
.cb--align-center .gallery-slider { margin: 0 auto; }
.gallery-slider__stage { position: relative; border-radius: var(--radius); overflow: hidden; background: var(--navy); }
.gallery-slider__slide { margin: 0; }
.gallery-slider__slide a { display: block; }
.gallery-slider__slide img { display: block; width: 100%; aspect-ratio: 16 / 9.2; object-fit: cover; }
.gallery-slider__slide figcaption {
	position: absolute;
	left: 0; right: 0; bottom: 0;
	padding: 2.5rem 5rem .9rem 1.1rem;
	background: linear-gradient(0deg, rgba(16, 29, 39, .85), rgba(16, 29, 39, 0));
	color: #fff;
	font-size: 1rem;
	margin: 0;
}
.gallery-slider__arrow {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	width: 46px; height: 46px;
	display: inline-flex; align-items: center; justify-content: center;
	border: 0;
	border-radius: 50%;
	background: rgba(255, 255, 255, .92);
	color: var(--navy);
	box-shadow: var(--shadow);
	cursor: pointer;
}
.gallery-slider__arrow:hover { background: #fff; }
.gallery-slider__arrow--prev { left: .75rem; }
.gallery-slider__arrow--next { right: .75rem; }
.gallery-slider__count { position: absolute; right: .9rem; bottom: .9rem; margin: 0; padding: .1rem .6rem; border-radius: 999px; background: rgba(16, 29, 39, .7); color: #fff; font-size: .85rem; font-variant-numeric: tabular-nums; }
.gallery-slider__thumbs { display: flex; gap: .45rem; list-style: none; margin: .75rem 0 0; padding: 0 0 .4rem; overflow-x: auto; scrollbar-width: thin; }
.gallery-slider__thumbs li { margin: 0; flex: none; }
.gallery-slider__thumbs button { position: relative; display: block; padding: 0; border: 2px solid transparent; border-radius: 6px; background: none; overflow: hidden; cursor: pointer; opacity: .65; transition: opacity .15s, border-color .15s; }
.gallery-slider__thumbs button:hover { opacity: 1; }
.gallery-slider__thumbs button[aria-current="true"] { border-color: var(--accent); opacity: 1; }
.gallery-slider__thumbs img { display: block; width: 84px; height: 56px; object-fit: cover; }
.gallery-grid { display: grid; grid-template-columns: repeat(var(--cols, 4), minmax(0, 1fr)); gap: .75rem; list-style: none; margin: 0; padding: 0; }
.gallery-grid li { margin: 0; }
.gallery-grid--2 { --cols: 2; } .gallery-grid--3 { --cols: 3; } .gallery-grid--4 { --cols: 4; } .gallery-grid--5 { --cols: 5; }
@media (max-width: 800px) { .gallery-grid { --cols: 2 !important; } }
.gallery-grid figure { margin: 0; }
.gallery-grid a { display: block; border-radius: var(--radius-sm); overflow: hidden; }
.gallery-grid img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; transition: transform .35s; }
.gallery-grid a:hover img { transform: scale(1.05); }
.gallery-grid figcaption { margin-top: .35rem; font-size: .88rem; color: var(--muted); line-height: 1.35; }

/* Lightbox */
.lightbox {
	width: min(96vw, 1200px);
	max-width: none;
	max-height: 96vh;
	padding: 0;
	border: 0;
	background: transparent;
	overflow: visible;
}
.lightbox::backdrop { background: rgba(10, 18, 25, .9); }
.lightbox__figure { margin: 0; text-align: center; }
.lightbox__figure img { max-width: 100%; max-height: 84vh; width: auto; border-radius: var(--radius-sm); background: #fff; }
.lightbox__figure figcaption { margin-top: .75rem; color: #e4ecf1; font-size: 1rem; }
.lightbox__close, .lightbox__prev, .lightbox__next {
	position: fixed;
	width: 48px; height: 48px;
	display: inline-flex; align-items: center; justify-content: center;
	border: 0; border-radius: 50%;
	background: rgba(255, 255, 255, .14);
	color: #fff;
	cursor: pointer;
}
.lightbox__close:hover, .lightbox__prev:hover, .lightbox__next:hover { background: rgba(255, 255, 255, .28); }
.lightbox__close { top: 1rem; right: 1rem; }
.lightbox__prev { left: 1rem; top: 50%; transform: translateY(-50%); }
.lightbox__next { right: 1rem; top: 50%; transform: translateY(-50%); }
html.lightbox-open { overflow: hidden; }

/* Content images, maps and graphs that open in the lightbox */
a.zoomable { position: relative; display: inline-block; max-width: 100%; cursor: zoom-in; line-height: 0; vertical-align: top; }
figure > a.zoomable { display: block; width: fit-content; margin-inline: auto; }
.image-text__media > a.zoomable { display: block; width: 100%; height: 100%; }
a.zoomable img { transition: filter .2s ease; }
a.zoomable::after {
	content: ""; position: absolute; right: .6rem; bottom: .6rem; width: 2.1rem; height: 2.1rem; border-radius: 50%;
	background: rgba(17, 33, 46, .78) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='6'/%3E%3Cpath d='m20 20-4.5-4.5M11 8.5v5M8.5 11h5'/%3E%3C/svg%3E") center / 1.15rem no-repeat;
	opacity: .85; transition: opacity .2s ease, transform .2s ease; pointer-events: none;
}
a.zoomable:hover img, a.zoomable:focus-visible img { filter: brightness(.94); }
a.zoomable:hover::after, a.zoomable:focus-visible::after { opacity: 1; transform: scale(1.08); }

/* CTA */
.cta { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 2rem; align-items: center; padding: clamp(1.75rem, 4vw, 3rem); border-radius: calc(var(--radius) + 4px); background: var(--navy); color: #e4ecf1; box-shadow: var(--shadow-lg); }
.cb-cta:not(.cb-cta--image) .cta { grid-template-columns: 1fr; }
.cta__title { margin: 0 0 .75rem; color: #fff; }
.cta__text { font-size: 1.15rem; color: #d3dee5; }
.cta__text p:last-child { margin-bottom: 0; }
.cta__buttons { display: flex; flex-wrap: wrap; gap: .75rem; margin: 1.5rem 0 0; }
.cta .button--ghost { color: #fff; border-color: rgba(255, 255, 255, .7); }
.cta .button--ghost:hover { background: #fff; color: var(--navy); }
.cta__media img { width: 100%; border-radius: var(--radius); }
.cb--bg-dark .cta { background: var(--navy-2); }
@media (max-width: 760px) { .cta { grid-template-columns: 1fr; } }

/* Quote */
.quote { max-width: 860px; margin: 0 auto; text-align: center; }
.quote__image { width: 88px; height: 88px; border-radius: 50%; object-fit: cover; margin-bottom: 1.25rem; box-shadow: var(--shadow); }
.quote__text { margin: 0; font-family: var(--font-serif); font-size: clamp(1.35rem, 2.6vw, 1.85rem); line-height: 1.4; color: var(--navy); }
.quote__text::before { content: "“"; display: block; height: .6em; font-size: 3.5em; line-height: 1; color: var(--accent); }
.quote__cite { margin-top: 1.25rem; display: flex; flex-direction: column; color: var(--muted); }
.quote__cite strong { color: var(--ink); }
.cb--light-text .quote__text { color: #fff; }

/* Columns */
.columns { display: grid; gap: clamp(1.5rem, 4vw, 3rem); grid-template-columns: repeat(var(--cols), minmax(0, 1fr)); }
.columns--1 { --cols: 1; } .columns--2 { --cols: 2; } .columns--3 { --cols: 3; } .columns--4 { --cols: 4; }
@media (max-width: 900px) { .columns--3, .columns--4 { --cols: 2; } }
@media (max-width: 640px) { .columns { --cols: 1 !important; } }

/* Accordion */
.accordion { max-width: var(--narrow); border-top: 1px solid var(--border); }
.cb--align-center .accordion { margin: 0 auto; text-align: left; }
.accordion__item { border-bottom: 1px solid var(--border); }
.accordion__title {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
	padding: 1.05rem 0;
	font-family: var(--font-serif);
	font-weight: 600;
	font-size: 1.2rem;
	color: var(--navy);
	cursor: pointer;
	list-style: none;
}
.accordion__title::-webkit-details-marker { display: none; }
.accordion__title .icon { color: var(--breeding); transition: transform .2s; }
.accordion__item[open] .accordion__title .icon { transform: rotate(180deg); }
.accordion__content { padding: 0 0 1.25rem; }

/* Logos */
.logos { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 1rem 2rem; list-style: none; margin: 0; padding: 0; }
.logos li { margin: 0; }
.logos a, .logos li > img, .logos__name { display: flex; align-items: center; justify-content: center; min-height: 64px; }
.logos img { max-height: 64px; width: auto; max-width: 150px; object-fit: contain; }
.logos__name { padding: .5rem 1rem; border: 1px solid var(--border); border-radius: var(--radius-sm); font-weight: 600; font-size: .95rem; color: var(--ink-soft); }
.logos--grey img { filter: grayscale(1); opacity: .75; transition: filter .2s, opacity .2s; }
.logos--grey a:hover img { filter: none; opacity: 1; }

/* Contact */
.contact { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); gap: clamp(1.5rem, 5vw, 4rem); align-items: start; }
.contact--no-form { grid-template-columns: 1fr; max-width: var(--narrow); }
@media (max-width: 860px) { .contact { grid-template-columns: 1fr; } }
.contact__details { list-style: none; margin: 1.5rem 0 0; padding: 0; display: grid; gap: .75rem; }
.contact__details li { display: flex; gap: .75rem; align-items: flex-start; margin: 0; }
.contact__details .icon { margin-top: .2em; color: var(--breeding); }
.contact__form { padding: clamp(1.25rem, 3vw, 2rem); border-radius: var(--radius); background: #fff; border: 1px solid var(--border); box-shadow: var(--shadow); }

/* Contact Form 7 */
.contact__form-title { margin: 0 0 1.25rem; font-size: 1.45rem; }
.contact__form-note { margin: 1rem 0 0; font-size: .9rem; color: var(--ink-soft); }
.contact-cards { list-style: none; margin: 2rem 0 0; padding: 0; display: grid; gap: .9rem; }
.contact-card { display: grid; grid-template-columns: 2.75rem minmax(0, 1fr); gap: 1rem; align-items: start; margin: 0; padding: 1.1rem 1.25rem; border: 1px solid var(--border); border-radius: var(--radius); background: #fff; }
.contact-card__icon { display: grid; place-items: center; width: 2.75rem; height: 2.75rem; border-radius: 50%; background: var(--breeding-soft); color: var(--breeding); }
.contact-card__icon .icon { width: 1.3rem; height: 1.3rem; }
.contact-card__title { margin: 0 0 .2rem; font-size: 1.1rem; color: var(--ink); }
.contact-card__text { margin: 0 0 .35rem; font-size: .98rem; color: var(--ink-soft); }
.contact-card__link { display: inline-flex; align-items: center; gap: .35em; margin-right: 1rem; font-weight: 600; overflow-wrap: anywhere; }
.contact-card__link .icon { width: 1em; height: 1em; }
.cb--light-text .contact-card, .cb--light-text .contact__form { color: var(--ink); }
.wpcf7 .wpcf7-acceptance label { font-weight: 400; font-size: .95rem; }
.wpcf7 .cwat-form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 0 1rem; }
@media (max-width: 560px) { .wpcf7 .cwat-form-row { grid-template-columns: 1fr; } }

/* Links */
ul.link-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(var(--cols, 2), minmax(0, 1fr)); gap: 1rem; }
.link-list--1 { --cols: 1; } .link-list--3 { --cols: 3; }
@media (max-width: 900px) { .link-list--3 { --cols: 2; } }
@media (max-width: 640px) { .link-list { --cols: 1 !important; } }
.link-list__item { margin: 0; }
.link-list__link { display: flex; flex-direction: column; gap: .3rem; height: 100%; padding: 1.1rem 1.25rem; border: 1px solid var(--border); border-radius: var(--radius); background: #fff; color: var(--ink); text-decoration: none; transition: border-color .15s, box-shadow .15s, transform .15s; }
.link-list__link:hover { border-color: #c8d3d8; box-shadow: var(--shadow); transform: translateY(-2px); color: var(--ink); }
.link-list__title { display: inline-flex; align-items: center; gap: .4em; font-weight: 700; font-size: 1.08rem; color: var(--link); }
.link-list__title .icon { width: 1em; height: 1em; flex: none; }
.link-list__text { color: var(--ink-soft); font-size: .98rem; }
.link-list__host { margin-top: auto; padding-top: .25rem; font-size: .85rem; color: var(--ink-soft); }

.wpcf7 form p { margin-bottom: 1.1rem; }
.wpcf7 label { display: block; font-weight: 600; font-size: .98rem; color: var(--ink); }
.wpcf7 input[type="text"],
.wpcf7 input[type="email"],
.wpcf7 input[type="tel"],
.wpcf7 input[type="url"],
.wpcf7 input[type="number"],
.wpcf7 input[type="date"],
.wpcf7 select,
.wpcf7 textarea {
	display: block;
	width: 100%;
	margin-top: .35rem;
	padding: .7rem .9rem;
	border: 1px solid #c8d2d7;
	border-radius: var(--radius-sm);
	background: #fff;
	color: var(--ink);
	font: inherit;
	font-size: 1rem;
	font-weight: 400;
}
.wpcf7 textarea { min-height: 9rem; resize: vertical; }
.wpcf7 input:focus, .wpcf7 select:focus, .wpcf7 textarea:focus { outline: none; border-color: var(--winter); box-shadow: 0 0 0 3px rgba(36, 113, 159, .2); }
.wpcf7 .wpcf7-list-item { margin: 0 1rem 0 0; font-weight: 400; }
.wpcf7-not-valid-tip { margin-top: .3rem; font-size: .9rem; color: #b3261e; }
.wpcf7 form .wpcf7-response-output { margin: 1rem 0 0; padding: .8rem 1rem; border-radius: var(--radius-sm); font-size: .98rem; }
.wpcf7 .wpcf7-spinner { vertical-align: middle; }

/* Downloads */
.downloads { list-style: none; margin: 0; padding: 0; display: grid; gap: .6rem; max-width: var(--narrow); }
.downloads li { margin: 0; }
.downloads a { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 1rem; align-items: center; padding: .9rem 1.1rem; border: 1px solid var(--border); border-radius: var(--radius); background: #fff; color: var(--ink); text-decoration: none; transition: border-color .15s, box-shadow .15s; }
.downloads a:hover { border-color: #c2cfd5; box-shadow: var(--shadow); color: var(--ink); }
.downloads__icon { display: inline-flex; width: 42px; height: 42px; align-items: center; justify-content: center; border-radius: 50%; background: var(--breeding-soft); color: var(--breeding); }
.downloads__text { display: flex; flex-direction: column; }
.downloads__title { font-weight: 700; color: var(--navy); }
.downloads__desc { font-size: .95rem; color: var(--muted); }
.downloads__meta { font-size: .85rem; font-weight: 600; color: var(--muted); white-space: nowrap; }

/* Embed */
.embed { margin: 0; max-width: 960px; }
.cb--align-center .embed { margin: 0 auto; }
.embed__frame { position: relative; aspect-ratio: 16 / 9; border-radius: var(--radius); overflow: hidden; background: #000; }
.embed__frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.embed figcaption { margin-top: .5rem; color: var(--muted); font-size: .92rem; }

/* ---------- Bird atlas plugin, matched to the theme ---------- */
.cwba {
	--cwba-winter: var(--winter);
	--cwba-breeding: var(--breeding);
	--cwba-radius: var(--radius);
	--cwba-shadow: var(--shadow);
	font-size: 1.06rem;
}
.cwba__title, .cwba__kicker, .cwba__group-letter, .cwba__panel-title { font-family: var(--font-serif); }
.cwba__sci, .cwba__index-sci { font-family: var(--font-serif); font-style: italic; }
.is-atlas-species .cwba__head .cwba__title,
.is-atlas-species .cwba__back { display: none; }
.is-atlas-species .cwba__head:not(:has(.cwba__tabs:not([hidden]))) { display: none; }
.is-atlas-page .page-body > .content-blocks .cb-bird-atlas { padding-top: clamp(1.5rem, 4vw, 2.5rem); }
.cwba__maps img { background: #fff; }
.cwba__search label { font-weight: 700; color: var(--navy); }
.cwba__search input[type="search"] {
	min-height: 46px;
	padding: .6rem 1rem;
	border: 1px solid var(--border);
	border-radius: 999px;
	background: #fff;
	color: var(--ink);
	font: inherit;
	font-size: 1rem;
}
.cwba__search input[type="search"]:focus { outline: none; border-color: var(--winter); box-shadow: 0 0 0 3px rgba(36, 113, 159, .2); }
.cwba-lightbox::backdrop { background: rgba(10, 18, 25, .9); }
.atlas-back { margin: 0 0 1rem; }

/* ---------- Search results ---------- */
.search-again { margin-bottom: 2.5rem; }
.search-section-title { margin: 0 0 1rem; font-size: 1.1rem; font-family: var(--font); font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.search-results { list-style: none; margin: 0; padding: 0; }
.search-result { margin: 0; padding: 1.25rem 0; border-bottom: 1px solid var(--border); }
.search-result__path { margin: 0 0 .2rem; font-size: .88rem; color: var(--muted); }
.search-result__title { margin: 0 0 .35rem; font-size: 1.3rem; }
.search-result__title a { text-decoration: none; }
.search-result__title a:hover { text-decoration: underline; }
.search-result__text { margin: 0; color: var(--ink-soft); }
.link-list { padding-left: 1.2em; }

/* ---------- Pagination, post nav ---------- */
.pagination, .page-links { margin-top: 2.5rem; }
.nav-links { display: flex; flex-wrap: wrap; gap: .4rem; align-items: center; }
.page-numbers { display: inline-flex; min-width: 42px; height: 42px; align-items: center; justify-content: center; padding: 0 .75rem; border: 1px solid var(--border); border-radius: 999px; text-decoration: none; color: var(--ink); }
.page-numbers.current { background: var(--navy); border-color: var(--navy); color: #fff; }
.post-navigation .nav-links { justify-content: space-between; margin-top: 3rem; padding-top: 1.5rem; border-top: 1px solid var(--border); }
.post-navigation .nav-label { display: block; font-size: .85rem; color: var(--muted); }

/* ---------- Comments ---------- */
.comments { margin-top: 3rem; }
.comment-list { list-style: none; padding: 0; }
.comment-body { padding: 1rem 0; border-bottom: 1px solid var(--border); }
.comment-form input[type="text"], .comment-form input[type="email"], .comment-form input[type="url"], .comment-form textarea { width: 100%; padding: .6rem .8rem; border: 1px solid #c8d2d7; border-radius: var(--radius-sm); font: inherit; }

/* ---------- Footer ---------- */
.site-footer { margin-top: 0; color: #c9d6de; background: var(--navy); }
.site-footer a { color: #fff; }
.site-footer a:hover { color: var(--accent); }
.site-footer__sponsors { padding: 2.25rem 0; background: #fff; border-top: 1px solid var(--border); color: var(--ink); }
.site-footer__label { margin: 0 0 1.25rem; text-align: center; font-family: var(--font); font-size: .82rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.site-footer__sponsors .logos { gap: 1.25rem 2.25rem; }
.site-footer__sponsors .logos img { max-height: 56px; max-width: 130px; }
.site-footer__sponsors a { color: var(--ink); }
.site-footer__sponsors .logo-slider .logos img { max-height: var(--logo-h, 56px); }

/* Logo strips that move: a scrolling marquee or a step slider */
.logo-slider { position: relative; --logo-h: 56px; --visible: 5; }
.logo-slider .logos img { max-height: var(--logo-h); max-width: calc(var(--logo-h) * 2.4); }
.logo-slider .logos a, .logo-slider .logos li > img, .logo-slider .logos__name { min-height: var(--logo-h); }
.logo-slider__viewport { overflow: hidden; }
.logo-slider.is-running .logo-slider__track { flex-wrap: nowrap; justify-content: flex-start; }
.logo-slider--scroll.is-running .logo-slider__track > li { flex: 0 0 auto; }
.logo-slider--scroll.is-running .logo-slider__viewport {
	-webkit-mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent);
	mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent);
}
.logo-slider--scroll.is-running .logo-slider__track { width: max-content; animation: cwat-marquee 30s linear infinite; }
.logo-slider--scroll[data-direction="right"] .logo-slider__track { animation-direction: reverse; }
.logo-slider--pause:hover .logo-slider__track, .logo-slider:focus-within .logo-slider__track { animation-play-state: paused; }
@keyframes cwat-marquee { from { transform: translateX(0); } to { transform: translateX(calc(-1 * var(--shift, 50%))); } }

.logo-slider--slider .logo-slider__viewport { overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; overscroll-behavior-x: contain; }
.logo-slider--slider .logo-slider__viewport::-webkit-scrollbar { display: none; }
.logo-slider--slider .logo-slider__track { --cols: var(--visible); flex-wrap: nowrap; justify-content: flex-start; gap: 0 !important; }
.logo-slider--slider .logo-slider__track > li { flex: 0 0 calc(100% / var(--cols)); min-width: 0; display: flex; justify-content: center; padding: 0 .75rem; scroll-snap-align: start; }
.logo-slider--slider .logos a, .logo-slider--slider .logos img { max-width: 100%; }
@media (max-width: 860px) { .logo-slider--slider .logo-slider__track { --cols: min(var(--visible), 3); } }
@media (max-width: 540px) { .logo-slider--slider .logo-slider__track { --cols: min(var(--visible), 2); } }
.logo-slider--slider:has(.logo-slider__btn) { padding: 0 2.75rem; }
.logo-slider__btn {
	position: absolute; top: 50%; transform: translateY(-50%); display: grid; place-items: center; width: 2.25rem; height: 2.25rem; padding: 0;
	border: 1px solid var(--border); border-radius: 50%; background: #fff; color: var(--ink); cursor: pointer; box-shadow: 0 1px 3px rgba(17, 33, 46, .12);
	transition: background .2s, color .2s, border-color .2s;
}
.logo-slider__btn:hover, .logo-slider__btn:focus-visible { background: var(--navy); border-color: var(--navy); color: #fff; }
.logo-slider__btn svg { width: 18px; height: 18px; }
.logo-slider__btn--prev { left: 0; }
.logo-slider__btn--next { right: 0; }
@media (prefers-reduced-motion: reduce) { .logo-slider__track { animation: none !important; } }
.site-footer { border-top: 4px solid var(--accent); }
.site-footer__sponsors + .site-footer__main { border-top: 4px solid var(--accent); }
.site-footer:has(.site-footer__sponsors) { border-top: 0; }
.site-footer__main { padding: clamp(2.5rem, 6vw, 3.5rem) 0 clamp(2rem, 5vw, 2.75rem); }
.site-footer__grid { display: flex; flex-wrap: wrap; gap: 2.5rem 4rem; }

/* Emblem, name and about */
.footer-brand { flex: 1 1 380px; max-width: 30rem; display: flex; flex-direction: column; gap: 1.25rem; }
.footer-brand__home { display: flex; align-items: center; gap: 1rem; text-decoration: none; }
.footer-brand__home:hover .footer-brand__name { text-decoration: underline; text-underline-offset: .15em; }
.footer-brand__emblem { flex: none; width: 84px; height: 84px; border-radius: 50%; object-fit: cover; border: 3px solid #f7f5cf; background: #f7f5cf; }
.footer-brand__text { display: flex; flex-direction: column; gap: .1rem; }
.footer-brand__name { font-family: var(--font-serif); font-size: 1.5rem; font-weight: 600; line-height: 1.15; color: #f7f5cf; }
.footer-brand__tagline { font-family: var(--font-serif); font-style: italic; font-size: 1.05rem; color: #c9d6de; }
.footer-brand__about { margin: 0; font-size: 1rem; line-height: 1.6; }

/* Link columns */
.footer-cols { flex: 999 1 520px; display: grid; grid-template-columns: repeat(auto-fit, minmax(9.5rem, 1fr)); gap: 2rem 1.5rem; align-content: start; }
.footer-col__title { margin: 0 0 .85rem; padding-bottom: .55rem; border-bottom: 1px solid rgba(255, 255, 255, .16); font-family: var(--font-serif); font-size: 1.2rem; font-weight: 600; color: #fff; }
.footer-col__title a { color: inherit; text-decoration: none; }
.footer-col__list { list-style: none; margin: 0; padding: 0; display: grid; gap: .15rem; }
.footer-col__list li { margin: 0; }
.footer-col__list a,
.footer-col__button {
	display: inline-block;
	padding: .3rem 0;
	border: 0;
	background: none;
	color: #fff;
	font: inherit;
	font-size: 1rem;
	line-height: 1.4;
	text-align: left;
	text-decoration: none;
	cursor: pointer;
}
.footer-col__list a:hover,
.footer-col__button:hover { color: var(--accent); text-decoration: underline; text-underline-offset: .18em; }
.footer-col__list a[aria-current="page"] { color: var(--accent); }
/* An "Explore" column from an older, flat footer menu */
.footer-cols:has(> .footer-col:only-child) .footer-col__list { display: block; columns: 2; column-gap: 2rem; }
.footer-cols:has(> .footer-col:only-child) .footer-col__list li { break-inside: avoid; }

/* Bottom bar: room on the right for the back to top button */
.site-footer__bottom { padding: 1.1rem 0 1.25rem; border-top: 1px solid rgba(255, 255, 255, .12); font-size: .9rem; color: #a9bac5; }
.site-footer__bottom-inner { display: flex; flex-wrap: wrap; gap: .75rem 2rem; justify-content: space-between; align-items: center; padding-right: 4.5rem; }
@media (max-width: 560px) { .site-footer__bottom-inner { padding-right: 0; padding-bottom: 3.5rem; } }
.site-footer__copyright { flex: 1 1 28rem; }
.site-footer__copyright p { margin: 0; line-height: 1.55; }
.site-footer__copyright a { color: #fff; }
.site-footer__legal ul { display: flex; flex-wrap: wrap; gap: .5rem 1.25rem; list-style: none; margin: 0; padding: 0; }
.site-footer__legal li { margin: 0; }

/* ---------- Notice bar (Site settings > Header) ---------- */
.notice-bar { --notice-bg: #f3dc86; --notice-ink: #2a2005; background: var(--notice-bg); color: var(--notice-ink); font-size: .98rem; line-height: 1.45; }
.notice-bar--info { --notice-bg: var(--navy-2); --notice-ink: #fff; }
.notice-bar--alert { --notice-bg: #a4262c; --notice-ink: #fff; }
.notice-bar[hidden] { display: none; }
.notice-bar__inner { display: flex; align-items: center; justify-content: center; gap: .75rem; min-height: 2.75rem; padding-top: .45rem; padding-bottom: .45rem; }
.notice-bar__text { margin: 0; text-align: center; flex: 1 1 auto; }
.notice-bar a { color: inherit; font-weight: 600; text-decoration: underline; text-underline-offset: .15em; }
.notice-bar a:hover { text-decoration-thickness: 2px; }
.notice-bar :focus-visible { outline: 3px solid currentColor; outline-offset: 2px; }
.notice-bar__close { flex: none; display: inline-grid; place-items: center; width: 2.25rem; height: 2.25rem; margin-right: -.5rem; padding: 0; border: 0; border-radius: 50%; background: transparent; color: inherit; cursor: pointer; }
.notice-bar__close:hover { background: rgba(0, 0, 0, .1); }
.notice-bar__close svg { width: 18px; height: 18px; }

/* Menu bar that scrolls away with the page (Site settings > Header). */
.cwat-static-header { --sf-sticky-h: 0px; }
.cwat-static-header .site-header,
.admin-bar.cwat-static-header .site-header { position: relative; top: 0; }

/* ---------- Footer: email and social links ---------- */
.footer-brand__email { display: flex; align-items: center; gap: .5rem; margin: 0; }
.footer-brand__email svg { width: 18px; height: 18px; flex: none; opacity: .8; }
.footer-brand__email a { color: #fff; }
.footer-social { display: flex; flex-wrap: wrap; gap: .5rem; list-style: none; margin: 0; padding: 0; }
.footer-social li { margin: 0; }
.site-footer .footer-social__link { display: inline-block; padding: .3rem .85rem; border: 1px solid rgba(247, 245, 207, .4); border-radius: 999px; color: #f7f5cf; font-size: .92rem; font-weight: 600; text-decoration: none; }
.site-footer .footer-social__link:hover,
.site-footer .footer-social__link:focus-visible { border-color: #f7f5cf; background: rgba(247, 245, 207, .1); color: #fff; }

/* ---------- Accessibility options ---------- */
/* The button in the menu bar, with a count of options switched on. */
.a11y-toggle { position: relative; }
.a11y-toggle[hidden] { display: none; }
.a11y-toggle__count {
	position: absolute;
	top: 2px;
	right: 0;
	min-width: 1.25rem;
	height: 1.25rem;
	padding: 0 .3rem;
	border-radius: 999px;
	background: var(--accent);
	color: var(--accent-ink);
	font-size: .75rem;
	font-weight: 800;
	line-height: 1.25rem;
	text-align: center;
	box-shadow: 0 0 0 2px var(--bar, #42576a);
}
.a11y-toggle__count[hidden] { display: none; }
.site-header .a11y-toggle.is-active { box-shadow: inset 0 0 0 2px var(--accent); }

/* The panel */
.a11y-panel {
	position: absolute;
	top: 100%;
	right: max(var(--gutter), calc((100vw - var(--max)) / 2));
	z-index: 120;
	width: min(26rem, calc(100vw - 2 * var(--gutter)));
	max-height: calc(100vh - var(--header-h) - 1.5rem);
	overflow-y: auto;
	overscroll-behavior: contain;
	padding: 1rem 1.15rem 1.15rem;
	background: #fff;
	color: var(--ink);
	border: 1px solid var(--border);
	border-top: 3px solid var(--accent);
	border-radius: 0 0 var(--radius) var(--radius);
	box-shadow: var(--shadow-lg);
	font-size: 1rem;
	line-height: 1.45;
}
.a11y-panel[hidden] { display: none; }
@media (max-width: 560px) { .a11y-panel { left: 0; right: 0; width: auto; border-radius: 0 0 var(--radius) var(--radius); } }
.a11y-panel__head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: .25rem; }
.a11y-panel__title { margin: 0; font-size: 1.2rem; }
.a11y-panel .icon-button { color: var(--navy); }
.a11y-panel .icon-button:hover { background: var(--surface); }
.a11y-panel__status { margin: 0 0 1rem; padding: .5rem .75rem; border-radius: var(--radius-sm); background: var(--surface); color: var(--ink-soft); font-size: .92rem; }
.a11y-panel__status.is-on { background: #fdf3d6; color: var(--accent-ink); font-weight: 600; }
.a11y-panel__label { margin: 0 0 .5rem; font-weight: 700; }
.a11y-sizes { display: grid; grid-template-columns: repeat(4, 1fr); gap: .4rem; margin-bottom: 1rem; }
.a11y-size {
	display: grid;
	justify-items: center;
	gap: .1rem;
	padding: .45rem .25rem;
	border: 2px solid var(--border);
	border-radius: var(--radius-sm);
	background: #fff;
	color: var(--ink);
	font: inherit;
	font-size: .82rem;
	cursor: pointer;
}
.a11y-size:hover { border-color: var(--navy); }
.a11y-size[aria-pressed="true"] { border-color: var(--navy); background: var(--navy); color: #fff; }
.a11y-size__sample { font-family: var(--font-serif); font-weight: 600; line-height: 1; }
.a11y-size--0 .a11y-size__sample { font-size: 1rem; }
.a11y-size--1 .a11y-size__sample { font-size: 1.2rem; }
.a11y-size--2 .a11y-size__sample { font-size: 1.4rem; }
.a11y-size--3 .a11y-size__sample { font-size: 1.65rem; }
.a11y-switches { list-style: none; margin: 0 0 1rem; padding: 0; border-top: 1px solid var(--border); }
.a11y-switches li { margin: 0; border-bottom: 1px solid var(--border); }
.a11y-switch {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
	width: 100%;
	padding: .7rem 0;
	border: 0;
	background: none;
	color: inherit;
	font: inherit;
	text-align: left;
	cursor: pointer;
}
.a11y-switch__text { display: grid; gap: .1rem; }
.a11y-switch__label { font-weight: 600; }
.a11y-switch__hint { color: var(--muted); font-size: .88rem; }
.a11y-switch__track { position: relative; flex: none; width: 2.75rem; height: 1.5rem; border-radius: 999px; background: #c3ccd1; transition: background .15s; }
.a11y-switch__thumb { position: absolute; top: 3px; left: 3px; width: calc(1.5rem - 6px); height: calc(1.5rem - 6px); border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgba(0, 0, 0, .3); transition: transform .15s; }
.a11y-switch[aria-checked="true"] .a11y-switch__track { background: var(--breeding); }
.a11y-switch[aria-checked="true"] .a11y-switch__thumb { transform: translateX(1.25rem); }
.a11y-switch[aria-checked="true"] .a11y-switch__label::after { content: " ✓"; color: var(--breeding); }
.a11y-panel__foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .5rem 1rem; }
.a11y-panel__reset[disabled] { opacity: .45; cursor: not-allowed; transform: none; }
.a11y-panel__note { margin: 0; color: var(--muted); font-size: .85rem; }

/* The options themselves */
html.a11y-text-1 { font-size: 115%; }
html.a11y-text-2 { font-size: 130%; }
html.a11y-text-3 { font-size: 150%; }

/* With bigger text the full menu may not fit on one line: let it wrap. */
@media (min-width: 1180px) {
	html:is(.a11y-text-2, .a11y-text-3) .site-nav { flex: 1 1 auto; min-width: 0; }
	html:is(.a11y-text-2, .a11y-text-3) .site-nav > ul { flex-wrap: wrap; }
	html:is(.a11y-text-2, .a11y-text-3) .site-nav > ul > li { min-height: 52px; }
}

html.a11y-spacing body { line-height: 1.9; letter-spacing: .04em; word-spacing: .16em; }
html.a11y-spacing :is(.entry-content, .cb) :is(p, li, dd) { margin-bottom: 1.4em; }

html.a11y-font {
	--font: "Atkinson Hyperlegible", Verdana, Tahoma, sans-serif;
	--font-serif: "Atkinson Hyperlegible", Verdana, Tahoma, sans-serif;
}

html.a11y-contrast {
	--ink: #000;
	--ink-soft: #000;
	--muted: #1f1f1f;
	--bg: #fff;
	--surface: #fff;
	--sand: #fff;
	--sand-deep: #fff;
	--navy: #000;
	--navy-2: #262626;
	--breeding: #1a5a0d;
	--breeding-soft: #fff;
	--winter: #004d7a;
	--winter-soft: #fff;
	--border: #000;
	--link: #0000c4;
	--link-hover: #000;
	--focus: #ffbf00;
	--shadow: 0 0 0 1px #000;
	--shadow-lg: 0 0 0 2px #000;
}
html.a11y-contrast .site-header { --bar: #000; --bar-ink: #fff; --bar-hover: rgba(255, 255, 255, .22); }
html.a11y-contrast .cb {
	--cb-bg: #fff !important;
	--cb-text: #000 !important;
	--cb-heading: #000 !important;
	--cb-link: #0000c4 !important;
	--cb-line: #000 !important;
	--cb-overlay: #000 !important;
	--cb-overlay-alpha: .8 !important;
}
html.a11y-contrast .cb-hero { background: #fff; }
html.a11y-contrast .site-footer,
html.a11y-contrast .site-footer__bottom { background: #000; color: #fff; }
html.a11y-contrast main a:not(.button) { text-decoration: underline; }
html.a11y-contrast :is(.button, button.button) { border-color: #000; }

html.a11y-links a:not(.button):not(.site-banner__link):not(.custom-logo-link) { text-decoration: underline !important; text-underline-offset: .18em; text-decoration-thickness: max(1px, .08em); }

html.a11y-motion { scroll-behavior: auto !important; }
html.a11y-motion *,
html.a11y-motion *::before,
html.a11y-motion *::after { animation-play-state: paused !important; transition: none !important; }

html.a11y-focus :focus-visible {
	outline: 4px solid #000 !important;
	outline-offset: 2px !important;
	box-shadow: 0 0 0 7px #ffbf00 !important;
}

/* ---------- Cookie choices ---------- */
.consent {
	position: fixed;
	left: max(1rem, env(safe-area-inset-left));
	bottom: max(1rem, env(safe-area-inset-bottom));
	z-index: 200;
	width: min(32rem, calc(100vw - 2rem));
	max-height: calc(100vh - 2rem);
	overflow-y: auto;
	padding: 1.25rem 1.35rem 1.1rem;
	background: #f7f5cf;
	color: var(--ink);
	border: 1px solid rgba(66, 87, 106, .25);
	border-top: 4px solid #42576a;
	border-radius: var(--radius);
	box-shadow: var(--shadow-lg);
	font-size: .95rem;
	line-height: 1.5;
}
.consent[hidden] { display: none; }
.consent__title { margin: 0 0 .4rem; font-family: var(--font-serif); font-size: 1.2rem; font-weight: 600; color: #42576a; }
.consent__text { margin: 0 0 .9rem; }
.consent__text a { color: var(--link-hover); font-weight: 600; }
.consent__choices { display: grid; gap: .6rem; margin: 0 0 1rem; padding: .85rem; background: rgba(255, 255, 255, .7); border-radius: var(--radius-sm); }
.consent__choices[hidden] { display: none; }
.consent__option { display: flex; gap: .6rem; align-items: flex-start; cursor: pointer; }
.consent__option input { flex: none; width: 1.15rem; height: 1.15rem; margin: .2rem 0 0; accent-color: #42576a; }
.consent__option input:disabled { cursor: not-allowed; }
.consent__buttons { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; }
.consent__buttons .button { flex: 1 1 auto; justify-content: center; }
.consent__buttons .button[hidden] { display: none; }
.consent__more {
	padding: .4rem .25rem;
	border: 0;
	background: none;
	color: #42576a;
	font: inherit;
	font-weight: 600;
	text-decoration: underline;
	text-underline-offset: .2em;
	cursor: pointer;
}
.consent__more[aria-expanded="true"] { display: none; }
@media (max-width: 560px) {
	.consent { left: 0; right: 0; bottom: 0; width: auto; border-radius: var(--radius) var(--radius) 0 0; }
}
@media print { .consent, .consent-open { display: none !important; } }

/* Footer "Cookie settings" */
.site-footer__legal-wrap { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem 1.25rem; }
.consent-open { padding: 0; border: 0; background: none; color: #fff; font: inherit; text-decoration: underline; text-underline-offset: .2em; cursor: pointer; }
.consent-open:hover { color: var(--accent); }
.consent-open[hidden] { display: none; }

/* Content from other websites, waiting for permission */
.consent-embed {
	--consent-ratio: 16 / 9;
	position: relative;
	display: grid;
	place-items: center;
	width: 100%;
	max-width: 100%;
	aspect-ratio: var(--consent-ratio);
	min-height: 14rem;
	margin: 0 0 1.25em;
	padding: 1.25rem;
	background: #42576a;
	color: #f7f5cf;
	border-radius: var(--radius);
	text-align: center;
}
.consent-embed__notice { max-width: 34rem; }
.consent-embed__notice p { margin: 0 0 .75rem; }
.consent-embed__buttons { display: flex; flex-wrap: wrap; justify-content: center; gap: .5rem; }
.consent-embed .button { background: #f7f5cf; border-color: #f7f5cf; color: #1b3040; }
.consent-embed .button:hover { background: #fff; border-color: #fff; color: #1b3040; }
.consent-embed .button--ghost { background: transparent; color: #f7f5cf; border-color: rgba(247, 245, 207, .7); }
.consent-embed .button--ghost:hover { background: #f7f5cf; color: #1b3040; }
.consent-embed__link { margin: 0 !important; font-size: .9rem; }
.consent-embed__link a { color: #f7f5cf; }
.consent-embed.is-loaded { display: block; padding: 0; background: none; min-height: 0; }
.consent-embed.is-loaded iframe { display: block; width: 100%; height: 100%; border: 0; }
.embed__frame .consent-embed { position: absolute; inset: 0; margin: 0; aspect-ratio: auto; border-radius: 0; }
.cookie-table td:first-child code { white-space: normal; word-break: break-word; }

/* Back to top */
.back-to-top {
	position: fixed;
	right: 1.25rem; bottom: 1.25rem;
	z-index: 90;
	width: 48px; height: 48px;
	display: inline-flex; align-items: center; justify-content: center;
	border-radius: 50%;
	background: var(--navy);
	color: #fff;
	box-shadow: var(--shadow-lg);
	opacity: 0;
	transform: translateY(8px);
	transition: opacity .2s, transform .2s;
}
.back-to-top.is-visible { opacity: 1; transform: none; }
.back-to-top:hover { background: var(--navy-2); color: #fff; }

/* Widgets */
.widget { margin-bottom: 2rem; }
.widget-title { font-size: 1.2rem; margin: 0 0 .75rem; }

@media (prefers-reduced-motion: reduce) {
	*, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; }
}

@media print {
	.site-header, .site-footer, .page-body__nav, .back-to-top, .site-search { display: none !important; }
	.site-banner { background: none !important; border: 0; }
	.page-body__grid { display: block; }
	body { font-size: 11pt; }
	a { color: inherit; }
}
