/*
Theme Name: Platform KSG
Template: autive-starter-theme
Description: Child theme for platform-ksg.nl - Platform Kleinschalige Schapen- en Geitenhouders
Version: 1.2.0
Author: Autive
Author URI: https://autive.nl
Text Domain: ksg
*/

/* ------------------------------------------------------------------ *\
 * KSG child theme - vanilla CSS for what theme.json cannot express.
 * Senior-friendly UX baseline + KSG-specific micro-styles.
 *
 * Tokens (from child theme.json):
 *   primary         #4E7D1F   pasture green - buttons, links
 *   primary-bright  #80C03A   leaf green - accents, hover backgrounds
 *   secondary       #1F3A6B   KSG blue - headings
 *   accent          #C97B3A   clay - rural decorative
 *   earth           #7A5A3A   warm brown
 *   surface         #F5F1E8   wool/cream
 *   background      #FFFFFF
 *   foreground      #1A2030
\* ------------------------------------------------------------------ */

:root {
	--ksg-tap: 48px;
	--ksg-ring: 3px;
	--ksg-radius-card: 14px;
	--ksg-radius-pill: 999px;

	--ksg-topo-svg: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 800 200' fill='none' stroke='%2380C03A' stroke-width='1.2' opacity='0.18'%3E%3Cpath d='M0 50 Q200 10 400 50 T800 50'/%3E%3Cpath d='M0 90 Q200 50 400 90 T800 90'/%3E%3Cpath d='M0 130 Q200 90 400 130 T800 130'/%3E%3Cpath d='M0 170 Q200 130 400 170 T800 170'/%3E%3C/svg%3E");

	/* Hill cutout — fill matches surface (#F5F1E8) so the next section reads as one continuous wool field. */
	--ksg-hill-svg: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1440 120' preserveAspectRatio='none'%3E%3Cpath d='M0 60 C 240 10, 480 100, 720 55 C 960 15, 1200 95, 1440 50 L 1440 120 L 0 120 Z' fill='%23F5F1E8'/%3E%3C/svg%3E");
}

/* === Senior-friendly baseline =============================== */

*:focus-visible {
	outline: var(--ksg-ring) solid var(--wp--preset--color--accent);
	outline-offset: 2px;
	border-radius: 2px;
}

.wp-block-button .wp-block-button__link,
.wp-block-search__button,
input[type="submit"],
button:not(.ksg-members-arrow) {
	min-height: var(--ksg-tap);
}

a, .wp-block-post-title a {
	text-underline-offset: 0.18em;
	text-decoration-thickness: 1.5px;
}

/* === Header ================================================== */

.ksg-header {
	border-bottom: 1px solid color-mix(in srgb, var(--wp--preset--color--earth) 18%, transparent) !important;
}
.ksg-header .wp-block-navigation a {
	padding: 0.65rem 1rem;
	border-radius: 6px;
	text-decoration: none;
	color: var(--wp--preset--color--foreground);
	font-weight: 500;
}
.ksg-header .wp-block-navigation a:hover,
.ksg-header .wp-block-navigation a:focus-visible {
	background: var(--wp--preset--color--surface);
	color: var(--wp--preset--color--secondary);
}
.ksg-header .wp-block-navigation .current-menu-item > a {
	color: var(--wp--preset--color--primary);
	font-weight: 600;
}

/* --- Submenu (desktop dropdown) ------------------------------ */

/* Trigger: subtle chevron next to the label. */
.ksg-header .wp-block-navigation .wp-block-navigation__submenu-icon {
	display: inline-flex !important;
	align-items: center;
	justify-content: center;
	width: 1rem;
	height: 1rem;
	margin: 0 0 0 0.05rem;
	padding: 0 !important;
	color: currentColor;
	background: transparent !important;
	border: 0 !important;
	cursor: pointer;
	opacity: 0.55;
	transition: transform 0.2s ease, opacity 0.2s ease;
}
.ksg-header .wp-block-navigation .wp-block-navigation__submenu-icon svg {
	width: 0.7rem;
	height: 0.7rem;
	display: block;
	fill: none;
}
.ksg-header .wp-block-navigation .wp-block-navigation__submenu-icon svg path {
	stroke: currentColor;
	stroke-width: 2;
	fill: none;
}
.ksg-header .wp-block-navigation .has-child:hover > .wp-block-navigation__submenu-icon,
.ksg-header .wp-block-navigation .has-child:focus-within > .wp-block-navigation__submenu-icon,
.ksg-header .wp-block-navigation .wp-block-navigation__submenu-icon[aria-expanded="true"] {
	opacity: 1;
	color: var(--wp--preset--color--primary);
	transform: rotate(180deg);
}

/* Submenu panel — desktop only. Mobile uses the responsive overlay. */
@media (min-width: 600px) {
	/* Hover bridge: covers the gap between the trigger LI and the panel
	   (header has 0.5rem padding-bottom + 1px border) so the cursor never
	   leaves a hoverable area on its way down to the panel. */
	.ksg-header .wp-block-navigation .has-child::after {
		content: "";
		position: absolute;
		top: 100%;
		left: 0;
		right: 0;
		height: calc(0.5rem + 1px);
		pointer-events: auto;
	}

	.ksg-header .wp-block-navigation .has-child > .wp-block-navigation__submenu-container {
		--ksg-sub-pad: 0.4rem;
		position: absolute;
		/* Drop from the bottom edge of the header bar, not the trigger label.
		   Offset = header padding-bottom (0.5rem) + header border-bottom (1px). */
		top: calc(100% + 0.5rem + 1px);
		left: 0 !important;
		right: auto !important;
		width: max-content;
		max-width: min(22rem, calc(100vw - 2rem));
		height: auto;
		min-width: 0;
		margin: 0;
		gap: 0;
		row-gap: 0;
		padding: var(--ksg-sub-pad);
		overflow: visible;
		background: var(--wp--preset--color--background);
		border: 1px solid color-mix(in srgb, var(--wp--preset--color--earth) 14%, transparent);
		border-top: 3px solid var(--wp--preset--color--primary-bright);
		border-radius: 0 0 var(--ksg-radius-card) var(--ksg-radius-card);
		box-shadow: 0 24px 48px -24px rgba(31, 58, 107, 0.30),
		            0 6px 14px -10px rgba(31, 58, 107, 0.18);
		list-style: none;
		opacity: 0;
		transform: translateY(4px);
		visibility: hidden;
		pointer-events: none;
		transition: opacity 0.18s ease, transform 0.18s ease, visibility 0s linear 0.18s;
		z-index: 30;
	}

	.ksg-header .wp-block-navigation .has-child:hover > .wp-block-navigation__submenu-container,
	.ksg-header .wp-block-navigation .has-child:focus-within > .wp-block-navigation__submenu-container,
	.ksg-header .wp-block-navigation .wp-block-navigation__submenu-icon[aria-expanded="true"] ~ .wp-block-navigation__submenu-container {
		opacity: 1;
		transform: translateY(0);
		visibility: visible;
		pointer-events: auto;
		transition: opacity 0.18s ease, transform 0.18s ease, visibility 0s;
	}

	.ksg-header .wp-block-navigation .wp-block-navigation__submenu-container li {
		display: block;
		margin: 0;
	}
	.ksg-header .wp-block-navigation .wp-block-navigation__submenu-container li + li {
		margin-top: 2px;
	}

	.ksg-header .wp-block-navigation .wp-block-navigation__submenu-container a {
		display: flex;
		align-items: center;
		min-height: var(--ksg-tap);
		padding: 0.55rem 0.85rem;
		border-radius: 8px;
		font-weight: 500;
		color: var(--wp--preset--color--foreground);
		line-height: 1.25;
		white-space: nowrap;
	}
	.ksg-header .wp-block-navigation .wp-block-navigation__submenu-container a:hover,
	.ksg-header .wp-block-navigation .wp-block-navigation__submenu-container a:focus-visible {
		background: var(--wp--preset--color--surface);
		color: var(--wp--preset--color--primary);
	}
	.ksg-header .wp-block-navigation .wp-block-navigation__submenu-container .current-menu-item > a {
		color: var(--wp--preset--color--primary);
		background: color-mix(in srgb, var(--wp--preset--color--primary-bright) 14%, var(--wp--preset--color--background));
	}
}

@media (prefers-reduced-motion: reduce) {
	.ksg-header .wp-block-navigation .wp-block-navigation__submenu-icon,
	.ksg-header .wp-block-navigation .has-child > .wp-block-navigation__submenu-container {
		transition: none;
	}
}

/* === Hero ==================================================== */

.ksg-hero {
	position: relative;
	overflow: hidden;
	padding-bottom: clamp(9rem, 10vw, 12rem) !important; /* room for stats + hill cutout */
	background: var(--wp--preset--color--background) !important;
}
.ksg-hero::before {
	content: "";
	position: absolute;
	inset: -2rem -2rem auto auto;
	width: 38rem;
	height: 24rem;
	background: var(--ksg-topo-svg) right top / cover no-repeat;
	pointer-events: none;
	z-index: 0;
	mask-image: linear-gradient(225deg, black 30%, transparent 80%);
}
.ksg-hero::after {
	content: "";
	position: absolute;
	left: 0;
	right: 0;
	bottom: -1px; /* avoid hairline gap between cutout and next section */
	height: 90px;
	background: var(--ksg-hill-svg) center bottom / 100% 100% no-repeat;
	pointer-events: none;
	z-index: 1;
}
.ksg-hero > .wp-block-columns {
	position: relative;
	z-index: 2;
}
.ksg-hero-photo {
	position: relative;
	border-radius: 18px;
	overflow: hidden;
	aspect-ratio: 4 / 5;
	box-shadow: 0 30px 60px -28px rgba(31, 58, 107, 0.35);
}
.ksg-hero-photo img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}
.ksg-hero-photo::after {
	content: "";
	position: absolute;
	inset: 0;
	background: linear-gradient(190deg, transparent 50%, rgba(31, 58, 107, 0.45));
	pointer-events: none;
}
.ksg-stats {
	display: flex;
	flex-wrap: wrap;
	gap: clamp(1.5rem, 4vw, 3rem);
	justify-content: space-between;
	position: relative;
	z-index: 2;
}
.ksg-stats h3 {
	font-feature-settings: "tnum";
	font-variant-numeric: tabular-nums;
	color: var(--wp--preset--color--primary);
}

/* === Thema grid - the centerpiece ============================ */

/* Themas continues the wool surface from the hero hill cutout — visually one
   continuous land. Bottom edge of section flows into news section (also wool). */
.ksg-themas {
	background: var(--wp--preset--color--surface) !important;
	padding-top: 4rem !important;
}
.ksg-thema-grid {
	display: grid;
	grid-template-columns: 1fr;
	grid-auto-rows: 1fr;
	gap: 1.5rem;
	margin-top: 3rem;
}
@media (min-width: 720px)  { .ksg-thema-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .ksg-thema-grid { grid-template-columns: repeat(4, 1fr); } }

.ksg-thema-card {
	display: flex;
	flex-direction: column;
	gap: 1rem;
	padding: 2rem 1.75rem;
	min-height: 280px;
	background: var(--wp--preset--color--background);
	border: 1px solid color-mix(in srgb, var(--wp--preset--color--earth) 14%, transparent);
	border-top: 4px solid var(--wp--preset--color--primary-bright);
	border-radius: var(--ksg-radius-card);
	color: var(--wp--preset--color--foreground);
	text-decoration: none;
	transition: transform 0.25s ease, background 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}
.ksg-thema-card:hover,
.ksg-thema-card:focus-visible {
	transform: translateY(-3px);
	background: color-mix(in srgb, var(--wp--preset--color--primary-bright) 8%, var(--wp--preset--color--background));
	border-top-color: var(--wp--preset--color--primary);
	box-shadow: 0 22px 40px -22px rgba(78, 125, 31, 0.32);
}
.ksg-thema-icon {
	width: 2.75rem;
	height: 2.75rem;
	color: var(--wp--preset--color--primary);
	flex-shrink: 0;
}
.ksg-thema-title {
	margin: auto 0 0;
	font-family: var(--wp--preset--font-family--display);
	font-weight: 700;
	font-size: 1.5rem;
	color: var(--wp--preset--color--secondary);
	line-height: 1.15;
}
.ksg-thema-desc {
	margin: 0;
	color: var(--wp--preset--color--foreground);
	opacity: 0.8;
	line-height: 1.45;
}
.ksg-thema-count {
	display: inline-block;
	align-self: flex-start;
	padding: 0.3rem 0.85rem;
	border-radius: var(--ksg-radius-pill);
	background: var(--wp--preset--color--primary-bright);
	color: var(--wp--preset--color--secondary);
	font-size: 0.85rem;
	font-weight: 700;
}

/* === News three-up ===========================================
   News section continues the wool surface from themas with no gap. */

.ksg-news {
	background: var(--wp--preset--color--surface) !important;
	padding-top: 1rem !important;     /* themas already has bottom padding */
	padding-bottom: var(--wp--custom--section--y) !important;
}
.ksg-news-card {
	overflow: hidden;
	background: var(--wp--preset--color--background) !important;
	transition: transform 0.25s ease, box-shadow 0.25s ease;
	display: flex;
	flex-direction: column;
	border: 1px solid color-mix(in srgb, var(--wp--preset--color--earth) 12%, transparent) !important;
}
.ksg-news-card:hover,
.ksg-news-card:focus-within {
	transform: translateY(-4px);
	box-shadow: 0 28px 48px -28px rgba(31, 58, 107, 0.35);
}
.ksg-news-card .wp-block-post-featured-image { margin: 0 !important; }
.ksg-news-card .wp-block-post-featured-image img {
	width: 100%;
	aspect-ratio: 16 / 10;
	object-fit: cover;
	display: block;
}
.ksg-news-card .wp-block-post-title a {
	text-decoration: none;
	color: var(--wp--preset--color--secondary);
}
.ksg-news-card .wp-block-post-title a:hover {
	color: var(--wp--preset--color--primary);
	text-decoration: underline;
}
.ksg-news-card .wp-block-post-excerpt__more-link {
	color: var(--wp--preset--color--primary);
	font-weight: 700;
	margin-top: 0.5rem;
	display: inline-block;
}

/* === Newsletter CTA ========================================== */

.ksg-newsletter {
	position: relative;
	background: linear-gradient(135deg, var(--wp--preset--color--secondary) 0%, #16294B 100%) !important;
}
.ksg-newsletter::before {
	content: "";
	position: absolute;
	inset: 0;
	background: var(--ksg-topo-svg) center / 1200px no-repeat;
	opacity: 0.2;
	pointer-events: none;
}
.ksg-newsletter > * { position: relative; z-index: 1; }
.ksg-newsletter h2,
.ksg-newsletter .ksg-newsletter-bullets {
	color: #fff;
}
.ksg-newsletter-bullets {
	list-style: none !important;
	padding-left: 0 !important;
	display: flex;
	flex-direction: column;
	gap: 0.5rem;
}
.ksg-newsletter-bullets li {
	display: flex;
	align-items: flex-start;
	gap: 0.75rem;
	color: rgba(255, 255, 255, 0.92);
	font-size: 1.05rem;
}
.ksg-newsletter-bullets li > span[aria-hidden="true"] {
	color: var(--wp--preset--color--primary-bright);
	font-size: 1.2em;
	flex-shrink: 0;
	font-weight: 700;
}

/* Form: every field stays inside the white card on every breakpoint. */
.ksg-newsletter-form {
	background: var(--wp--preset--color--background);
	color: var(--wp--preset--color--foreground);
	border-radius: 16px;
	padding: 1.75rem;
	box-shadow: 0 30px 60px -30px rgba(0, 0, 0, 0.4);
	box-sizing: border-box;
	max-width: 100%;
}
.ksg-newsletter-form *,
.ksg-newsletter-form *::before,
.ksg-newsletter-form *::after {
	box-sizing: border-box;
}
.ksg-newsletter-label {
	display: block;
	font-weight: 600;
	margin-bottom: 0.5rem;
	font-size: 1rem;
}
.ksg-newsletter-input {
	display: block;
	width: 100%;
	min-height: var(--ksg-tap);
	padding: 0.85rem 1rem;
	border-radius: 6px;
	border: 1.5px solid color-mix(in srgb, var(--wp--preset--color--secondary) 20%, transparent);
	background: var(--wp--preset--color--background);
	color: var(--wp--preset--color--foreground);
	font-size: 1.125rem;
	font-family: inherit;
	margin-bottom: 1.25rem;
	box-sizing: border-box;
}
.ksg-newsletter-input:focus-visible {
	outline: 3px solid var(--wp--preset--color--accent);
	outline-offset: 0;
	border-color: var(--wp--preset--color--primary);
}
.ksg-newsletter-submit {
	display: block;
	width: 100%;
	min-height: 56px;
	padding: 1rem 1.5rem;
	border-radius: 8px;
	background: var(--wp--preset--color--primary);
	color: #fff;
	border: 0;
	font-family: inherit;
	font-weight: 700;
	font-size: 1.125rem;
	cursor: pointer;
	box-sizing: border-box;
	transition: background 0.25s ease;
}
.ksg-newsletter-submit:hover,
.ksg-newsletter-submit:focus-visible {
	background: var(--wp--preset--color--primary-bright);
	color: var(--wp--preset--color--secondary);
}
.ksg-newsletter-fineprint {
	margin: 1rem 0 0;
	font-size: 0.9rem;
	color: color-mix(in srgb, var(--wp--preset--color--foreground) 60%, transparent);
}
.ksg-newsletter-fineprint a {
	color: var(--wp--preset--color--primary);
}

/* === Members marquee (auto-scrolling logo strip) =============
   Continuously scrolls left. Pauses on hover & focus-within.
   Reduced motion → static row, scrollable manually. */

.ksg-members {
	background: var(--wp--preset--color--background) !important;
}
@keyframes ksg-marquee {
	from { transform: translateX(0); }
	to   { transform: translateX(-50%); } /* exactly half — second copy slides into the same position */
}
.ksg-marquee {
	width: 100%;
	max-width: var(--wp--style--global--wide-size);
	margin-left: auto;
	margin-right: auto;
	overflow: hidden;
	position: relative;
	padding: 1.5rem 0;
	mask-image: linear-gradient(90deg, transparent 0, black 6%, black 94%, transparent 100%);
}
.ksg-marquee-track {
	display: flex;
	gap: 2.5rem;
	width: max-content;
	animation: ksg-marquee 60s linear infinite;
	will-change: transform;
}
.ksg-marquee:hover .ksg-marquee-track,
.ksg-marquee:focus-within .ksg-marquee-track {
	animation-play-state: paused;
}
.ksg-marquee-item {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 0.85rem;
	width: 11rem;
	flex-shrink: 0;
	padding: 1rem 0.75rem;
	border-radius: 14px;
	text-decoration: none;
	color: var(--wp--preset--color--foreground);
	transition: background 0.25s ease, transform 0.25s ease;
}
.ksg-marquee-item:hover,
.ksg-marquee-item:focus-visible {
	background: var(--wp--preset--color--surface);
	transform: translateY(-2px);
}
.ksg-marquee-mark {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 5rem;
	height: 5rem;
	border-radius: 14px;
	background: var(--wp--preset--color--background);
	border: 1px solid color-mix(in srgb, var(--wp--preset--color--earth) 14%, transparent);
	box-shadow: 0 6px 14px -10px rgba(31, 58, 107, 0.25);
	overflow: hidden;
}
.ksg-marquee-mark img {
	max-width: 70%;
	max-height: 70%;
	width: auto;
	height: auto;
	object-fit: contain;
}
.ksg-marquee-initial {
	font-family: var(--wp--preset--font-family--display);
	font-weight: 700;
	font-size: 1.65rem;
	color: var(--wp--preset--color--primary);
}
.ksg-marquee-name {
	font-size: 0.875rem;
	font-weight: 600;
	line-height: 1.25;
	color: var(--wp--preset--color--secondary);
	text-align: center;
	max-width: 11rem;
	text-wrap: balance;
}

@media (prefers-reduced-motion: reduce) {
	.ksg-marquee-track {
		animation: none;
		flex-wrap: wrap;
		justify-content: center;
		width: 100%;
		gap: 1.5rem;
	}
	.ksg-marquee {
		mask-image: none;
		overflow-x: auto;
	}
}

/* === Members overview page (archive) ========================== */

.ksg-leden-page {
	padding: clamp(2rem, 4vw, 3.5rem) 0;
}
.ksg-leden-hero {
	position: relative;
	border-radius: 22px;
	overflow: hidden;
	min-height: 320px;
	display: flex;
	align-items: flex-end;
	padding: 2.5rem;
	color: #fff;
	margin-bottom: 3rem;
}
.ksg-leden-hero img {
	position: absolute; inset: 0;
	width: 100%; height: 100%;
	object-fit: cover;
	z-index: 0;
}
.ksg-leden-hero::after {
	content: "";
	position: absolute; inset: 0;
	background: linear-gradient(180deg, rgba(31, 58, 107, 0.05) 0%, rgba(31, 58, 107, 0.85) 100%);
	z-index: 1;
}
.ksg-leden-hero > .ksg-leden-hero-text {
	position: relative;
	z-index: 2;
	max-width: 60ch;
}
.ksg-leden-hero h1 {
	color: #fff !important;
	font-size: clamp(2.5rem, 4vw + 1rem, 4rem);
	margin: 0 0 0.5rem 0;
	line-height: 1.05;
}
.ksg-leden-hero p {
	color: rgba(255, 255, 255, 0.92);
	font-size: 1.25rem;
	margin: 0;
}
.ksg-leden-search {
	display: flex;
	gap: 0.75rem;
	flex-wrap: wrap;
	margin-bottom: 2rem;
	align-items: center;
}
.ksg-leden-search input {
	flex: 1 1 18rem;
	min-height: var(--ksg-tap);
	padding: 0.85rem 1rem 0.85rem 3rem;
	border-radius: 12px;
	border: 1.5px solid color-mix(in srgb, var(--wp--preset--color--earth) 18%, transparent);
	background: var(--wp--preset--color--background) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231F3A6B' stroke-width='2'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='M21 21l-4.35-4.35' stroke-linecap='round'/%3E%3C/svg%3E") 0.85rem center / 1.25rem no-repeat;
	font-size: 1.125rem;
	font-family: inherit;
	color: var(--wp--preset--color--foreground);
}
.ksg-leden-search input:focus-visible {
	outline: 3px solid var(--wp--preset--color--accent);
	outline-offset: 1px;
	border-color: var(--wp--preset--color--primary);
}
.ksg-leden-count {
	font-size: 1.125rem;
	color: var(--wp--preset--color--foreground);
	font-weight: 600;
}
.ksg-leden-count strong {
	color: var(--wp--preset--color--primary);
}
.ksg-leden-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
	gap: 1.25rem;
}
.ksg-leden-grid article {
	display: flex;
	flex-direction: column;
	gap: 1rem;
	background: var(--wp--preset--color--background);
	border: 1px solid color-mix(in srgb, var(--wp--preset--color--earth) 14%, transparent);
	border-radius: var(--ksg-radius-card);
	padding: 1.75rem;
	transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}
.ksg-leden-grid article:hover {
	transform: translateY(-3px);
	border-color: var(--wp--preset--color--primary);
	box-shadow: 0 22px 40px -28px rgba(78, 125, 31, 0.30);
}
.ksg-leden-grid h3 {
	font-size: 1.25rem;
	line-height: 1.2;
	margin: 0;
	color: var(--wp--preset--color--secondary);
	font-weight: 700;
}
.ksg-leden-grid h3 a { color: inherit; text-decoration: none; }
.ksg-leden-grid h3 a:hover { text-decoration: underline; color: var(--wp--preset--color--primary); }
.ksg-leden-grid .ksg-member-link {
	font-weight: 700;
	color: var(--wp--preset--color--primary);
	text-decoration: underline;
	margin-top: auto;
}
.ksg-leden-grid article[hidden] { display: none; }
.ksg-leden-grid .ksg-member-mark,
.ksg-leden-grid .ksg-member-logo {
	width: 4rem;
	height: 4rem;
}
.ksg-leden-grid .ksg-member-mark {
	border-radius: 50%;
	background: linear-gradient(135deg, var(--wp--preset--color--primary), var(--wp--preset--color--primary-bright));
	color: #fff;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	font-family: var(--wp--preset--font-family--display);
	font-weight: 700;
	font-size: 1.5rem;
}
.ksg-leden-grid .ksg-member-logo {
	border-radius: 12px;
	background: var(--wp--preset--color--background);
	padding: 0.4rem;
	border: 1px solid color-mix(in srgb, var(--wp--preset--color--earth) 14%, transparent);
	object-fit: contain;
}

/* === About teaser =========================================== */

.ksg-about {
	background: var(--wp--preset--color--background) !important;
	padding-top: var(--wp--custom--section--y) !important;
	padding-bottom: var(--wp--custom--section--y) !important;
}
.ksg-werkgroep-card {
	box-shadow: 0 18px 40px -28px rgba(31, 58, 107, 0.20);
	border: 1px solid color-mix(in srgb, var(--wp--preset--color--earth) 12%, transparent);
}
.ksg-werkgroep-list {
	list-style: none;
	padding: 0;
	margin: 1.5rem 0 0;
	display: flex;
	flex-direction: column;
	gap: 1.25rem;
}
.ksg-werkgroep-item {
	display: flex;
	align-items: flex-start;
	gap: 1rem;
}
.ksg-werkgroep-mark {
	width: 3rem;
	height: 3rem;
	border-radius: 50%;
	background: linear-gradient(135deg, var(--wp--preset--color--secondary), #16294B);
	color: #fff;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	font-family: var(--wp--preset--font-family--display);
	font-weight: 700;
	font-size: 1.05rem;
	flex-shrink: 0;
	box-shadow: 0 6px 14px -8px rgba(31, 58, 107, 0.5);
}
.ksg-werkgroep-name {
	margin: 0;
	font-weight: 700;
	color: var(--wp--preset--color--foreground);
	font-size: 1.125rem;
	line-height: 1.2;
}
.ksg-werkgroep-role {
	margin: 0.15rem 0 0;
	color: color-mix(in srgb, var(--wp--preset--color--foreground) 70%, transparent);
}

/* === Footer =================================================
   Wider inner — pushes the wide constraint up. Uses the full visible width on
   typical desktops without losing the centered alignment. */

.ksg-footer {
	color: rgba(255, 255, 255, 0.85);
	background: linear-gradient(180deg, var(--wp--preset--color--secondary) 0%, #16294B 100%) !important;
	position: relative;
}
.ksg-footer::before {
	content: "";
	position: absolute;
	inset: 0;
	background: var(--ksg-topo-svg) center / 1200px no-repeat;
	opacity: 0.18;
	pointer-events: none;
}
.ksg-footer > * { position: relative; z-index: 1; }
.ksg-footer-inner {
	max-width: var(--wp--style--global--wide-size) !important;
}
.ksg-footer a {
	color: rgba(255, 255, 255, 0.92);
	text-decoration: underline;
	text-underline-offset: 0.18em;
}
.ksg-footer a:hover,
.ksg-footer a:focus-visible {
	color: var(--wp--preset--color--primary-bright);
}
.ksg-footer-list li {
	margin: 0 0 0.6rem 0;
	list-style: none;
}
.ksg-footer-list {
	padding-left: 0;
}
.ksg-footer-logo img {
	background: #fff;
	border-radius: 8px;
	padding: 0.5rem;
}

/* === Reduced motion =========================================== */

@media (prefers-reduced-motion: reduce) {
	.ksg-thema-card,
	.ksg-news-card,
	.ksg-marquee-item,
	.ksg-leden-grid article {
		transition: none;
	}
	.ksg-thema-card:hover,
	.ksg-news-card:hover,
	.ksg-news-card:focus-within,
	.ksg-marquee-item:hover,
	.ksg-leden-grid article:hover {
		transform: none;
	}
}
