/*
 * [categorie] — WooCommerce archive met sidebar-filters, zoek/sort-bar
 * en product-grid. Alles namespaced onder .rodun-cat zodat Avada/Fusion
 * niet stoort.
 *
 * Inhoud:
 *   1. Container + design tokens
 *   2. Layout grid (sidebar | content)
 *   3. Sidebar / filter-blokken
 *   4. Dual-range slider
 *   5. Toolbar (search + sort)
 *   6. Product cards / grid / empty state
 *   7. Mobile drawer
 *   8. Loading state
 *   9. Responsive
 */


/* ============================================================
 * 1. Container + design tokens
 * ============================================================ */

.rodun-cat {
	/*
	 * Brand-kleuren komen uit style.css (:root) — zie de --rodun-* tokens.
	 * Truly-local: --rc-bg-softer (component-specifieke alpha) en de
	 * temperatuur-slider kleuren (alleen hier gebruikt).
	 */
	--rc-primary:    var(--rodun-primary);
	--rc-accent:     var(--rodun-accent);
	--rc-fg:         var(--rodun-fg);
	--rc-muted:      var(--rodun-muted);
	--rc-bg:         var(--rodun-bg);
	--rc-bg-soft:    var(--rodun-bg-soft);
	--rc-bg-softer:  rgba(240, 240, 240, 0.5);
	--rc-border:     var(--rodun-border);
	--rc-temp-min:   #16a34a;
	--rc-temp-max:   #dc2626;

	width: 100%;
	color: var(--rc-fg);
	font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
	line-height: 1.5;
}

.rodun-cat *,
.rodun-cat *::before,
.rodun-cat *::after {
	box-sizing: border-box;
}


/* ============================================================
 * 1b. Hero met breadcrumb
 * ============================================================ */

.rodun-cat__hero {
	--rch-max-width: var(--rodun-site-max-width, 1200px);
	--rch-padding-x: var(--rodun-site-padding-x, 30px);

	position: relative;
	background: var(--rc-primary);
	color: #fff;
	overflow: hidden;

	/* Full-bleed: trek de banner edge-to-edge ongeacht de parent-breedte.
	 * 50% verwijst naar de halve breedte van de parent, 50vw naar de halve
	 * viewport. Het verschil is exact de marge die nodig is om door de
	 * container heen te breken. */
	width: auto;
	margin-top: -64px;
	margin-left: calc(50% - 50vw);
	margin-right: calc(50% - 50vw);
	margin-bottom: 40px;
}

.rodun-cat__hero-inner {
	position: relative;
	max-width: var(--rch-max-width);
	margin: 0 auto;
	padding: 56px var(--rch-padding-x);
}

@media (min-width: 1024px) {
	.rodun-cat__hero-inner {
		padding-top: 80px;
		padding-bottom: 80px;
	}
}

.rodun-cat__hero-crumbs {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 8px;
	font-size: 14px;
	color: rgba(255, 255, 255, 0.7);
	margin-bottom: 24px;
}

.rodun-cat__hero-crumb {
	color: inherit;
	text-decoration: none;
	transition: color 0.15s ease;
}

a.rodun-cat__hero-crumb:hover,
a.rodun-cat__hero-crumb:focus-visible {
	color: var(--rc-accent);
}

.rodun-cat__hero-crumb--current {
	color: var(--rc-accent);
	font-weight: 500;
}

.rodun-cat__hero-crumb-sep {
	display: inline-flex;
	color: rgba(255, 255, 255, 0.5);
}

.rodun-cat__hero-crumb-sep svg {
	width: 16px;
	height: 16px;
}

.rodun-cat__hero-label {
	margin: 0 0 16px;
	font-size: 13px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.2em;
	color: var(--rc-accent);
	line-height: 1.2;
}

.rodun-cat__hero-title {
	margin: 0 0 24px !important;
	font-size: 32px !important;
	font-weight: 900 !important;
	line-height: 1.15 !important;
	color: #fff !important;
	max-width: 760px;
	letter-spacing: -0.01em;
}

@media (min-width: 768px) {
	.rodun-cat__hero-title {
		font-size: 40px !important;
	}
}

@media (min-width: 1024px) {
	.rodun-cat__hero-title {
		font-size: 48px !important;
	}
}

.rodun-cat__hero-desc {
	margin: 0;
	font-size: 17px;
	line-height: 1.6;
	color: rgba(255, 255, 255, 0.8);
	max-width: 640px;
}


/* ============================================================
 * 2. Layout grid (sidebar | content)
 * ============================================================ */

.rodun-cat__layout {
	display: grid;
	grid-template-columns: 280px 1fr;
	gap: 48px;
	align-items: start;
	position: relative;
}


/* ============================================================
 * 3. Sidebar / filter-blokken
 * ============================================================ */

.rodun-cat__sidebar {
	background: var(--rc-bg);
	border: 1px solid var(--rc-border);
	border-radius: 2px;
	padding: 24px;
	position: sticky;
	top: 80px;
	max-height: calc(100vh - 100px);
	overflow-y: auto;
}

/* Sidebar-kop: "Filters" + icoon (desktop + mobiele drawer). */
.rodun-cat__sidebar-top {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	margin-bottom: 20px;
	padding-bottom: 16px;
	border-bottom: 1px solid var(--rc-border);
}

.rodun-cat__sidebar-head {
	display: flex;
	align-items: center;
	gap: 8px;
	min-width: 0;
}

.rodun-cat__sidebar-head-title {
	font-size: 13px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.06em;
	color: var(--rc-fg);
	line-height: 1.2;
}

.rodun-cat__drawer-close {
	width: 32px;
	height: 32px;
	border: 0;
	background: transparent;
	color: var(--rc-fg);
	cursor: pointer;
	display: none;
	align-items: center;
	justify-content: center;
	border-radius: 2px;
	padding: 0;
	flex: 0 0 auto;
}

.rodun-cat__drawer-close svg {
	width: 20px;
	height: 20px;
}

.rodun-cat__drawer-close:hover,
.rodun-cat__drawer-close:focus-visible {
	background: var(--rc-bg-soft);
}

.rodun-cat__filter-block {
	padding-bottom: 20px;
	margin-bottom: 20px;
	border-bottom: 1px solid var(--rc-border);
}

.rodun-cat__filter-block:last-of-type {
	border-bottom: 0;
	margin-bottom: 16px;
	padding-bottom: 0;
}

.rodun-cat__filter-header {
	display: flex;
	align-items: center;
	gap: 8px;
	margin-bottom: 14px;
}

.rodun-cat__filter-header h4 {
	margin: 0;
	font-size: 13px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.06em;
	color: var(--rc-fg);
	line-height: 1.2;
}

.rodun-cat__icon-accent {
	color: var(--rc-accent);
	display: inline-flex;
}

.rodun-cat__icon-accent svg {
	width: 16px;
	height: 16px;
}

/* --- Filter checkbox lijst --- */
.rodun-cat__filter-list {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-direction: column;
	gap: 2px;
}

.rodun-cat__filter-list--scroll {
	max-height: 240px;
	overflow-y: auto;
	padding-right: 4px;
}

.rodun-cat__filter-item {
	margin: 0;
}

.rodun-cat__filter-item--overflow {
	display: none;
}

.rodun-cat__filter-block.is-expanded .rodun-cat__filter-item--overflow {
	display: block;
}

.rodun-cat__filter-more {
	display: block;
	width: 100%;
	margin-top: 8px;
	padding: 0;
	border: 0;
	background: none;
	color: #000;
	font-size: 12px;
	font-weight: 600;
	text-align: center;
	cursor: pointer;
	text-decoration: underline;
	text-underline-offset: 2px;
}

.rodun-cat__filter-more:hover {
	color: #000;
	opacity: 0.7;
}

.rodun-cat__filter-label {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 6px 0;
	cursor: pointer;
	font-size: 14px;
	color: var(--rc-fg);
	transition: color 0.15s ease;
	user-select: none;
}

.rodun-cat__filter-label:hover .rodun-cat__filter-name {
	color: var(--rc-primary);
}

/*
 * Native checkbox onzichtbaar, vervangen door eigen vierkant met checkmark
 * — zo werkt screen-reader & keyboard nog volledig (focus-ring op de echte
 * input zichtbaar via :focus-visible op de visuele box).
 */
.rodun-cat__filter-label input[type="checkbox"] {
	position: absolute;
	opacity: 0;
	pointer-events: none;
	width: 0;
	height: 0;
}

.rodun-cat__filter-checkbox {
	width: 16px;
	height: 16px;
	flex-shrink: 0;
	border: 1.5px solid var(--rc-border);
	border-radius: 2px;
	background: #fff;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	transition: border-color 0.15s ease, background 0.15s ease;
	position: relative;
}

.rodun-cat__filter-checkbox::after {
	content: "";
	width: 8px;
	height: 4px;
	border-left: 2px solid #fff;
	border-bottom: 2px solid #fff;
	transform: rotate(-45deg) translate(1px, -1px);
	opacity: 0;
	transition: opacity 0.15s ease;
}

.rodun-cat__filter-label input:checked ~ .rodun-cat__filter-checkbox {
	background: var(--rc-primary);
	border-color: var(--rc-primary);
}

.rodun-cat__filter-label input:checked ~ .rodun-cat__filter-checkbox::after {
	opacity: 1;
}

.rodun-cat__filter-label input:focus-visible ~ .rodun-cat__filter-checkbox {
	outline: 2px solid var(--rc-primary);
	outline-offset: 2px;
}

.rodun-cat__filter-name {
	flex: 1;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
	transition: color 0.15s ease;
}

.rodun-cat__filter-count {
	color: var(--rc-muted);
	font-size: 12px;
	font-variant-numeric: tabular-nums;
}


/* ============================================================
 * 4. Dual-range slider — temperatuurbereik
 *
 * Twee gestapelde <input type="range"> bovenop een eigen gradient-track.
 * De track laat continu het groen → geel → oranje → rood verloop zien;
 * de "selected range" tussen de twee thumbs blijft transparant zodat
 * het verloop nooit afgedekt wordt door een progress-fill.
 *
 * Native runnable-track / moz-range-track is op transparent gezet —
 * alleen onze .rodun-cat__slider-track is visueel zichtbaar.
 *
 * Pointer-events truc: container/track passeren clicks door
 * (pointer-events: none op de inputs) zodat enkel de thumbs zelf
 * grijpbaar zijn (::-webkit-slider-thumb { pointer-events: auto }).
 * Firefox negeert die hint; daar wisselt categorie.js de z-index van
 * de actieve input op pointerdown zodat beide thumbs altijd bereikbaar
 * blijven, ook bij overlap aan de uiteinden.
 * ============================================================ */

.rodun-cat__slider {
	position: relative;
	height: 40px;
	padding-top: 15px;
	margin: 4px 10px 0;
}

/* Visuele track — altijd zichtbaar gradient (geen overlay). */
.rodun-cat__slider-track {
	position: absolute;
	left: 0;
	right: 0;
	top: 19px;
	height: 10px;
	border-radius: 9999px;
	background: linear-gradient(to right, #22c55e, #eab308, #f97316, #ef4444);
	pointer-events: none;
}

/*
 * Range-fill bewust onzichtbaar: spec eist dat het kleurverloop óók
 * binnen de geselecteerde range volledig zichtbaar blijft. Het element
 * blijft in de DOM (en wordt door categorie.js gepositioneerd) zodat
 * eventuele toekomstige overlay-styles makkelijk terug aan te zetten zijn.
 */
.rodun-cat__slider-fill {
	display: none;
}

.rodun-cat__slider-input {
	position: absolute;
	left: 0;
	right: 0;
	top: 14px;
	width: 100%;
	height: 20px;
	margin: 0;
	background: transparent;
	pointer-events: none;
	-webkit-appearance: none;
	appearance: none;
	z-index: 2;
}

/*
 * Max-thumb default boven min-thumb: aan de rechterzijde van het bereik
 * overlappen ze elkaar; door max default hoger te leggen blijft hij
 * altijd vindbaar. Bij pointerdown swapt categorie.js dit dynamisch.
 */
.rodun-cat__slider-input--max {
	z-index: 3;
}

.rodun-cat__slider-input:focus {
	outline: none;
}

/* Verberg de native tracks volledig — onze eigen .__slider-track doet 't werk. */
.rodun-cat__slider-input::-webkit-slider-runnable-track {
	background: transparent;
	border: none;
	height: 20px;
}

.rodun-cat__slider-input::-moz-range-track {
	background: transparent;
	border: none;
	height: 20px;
}

/* WebKit thumb — 20px wit, gekleurde rand per min/max. */
.rodun-cat__slider-input::-webkit-slider-thumb {
	-webkit-appearance: none;
	appearance: none;
	width: 20px;
	height: 20px;
	border-radius: 50%;
	background: var(--background, #fff);
	cursor: grab;
	pointer-events: auto;
	box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
	transition: transform 0.1s ease, box-shadow 0.15s ease;
	/*
	 * Webkit centreert de thumb op de runnable-track-baseline. Met
	 * een 20px runnable-track moet margin-top expliciet 0 zijn, anders
	 * zakt de thumb onder de visuele track door.
	 */
	margin-top: 0;
}

.rodun-cat__slider-input--min::-webkit-slider-thumb {
	border: 2px solid #22c55e;
}

.rodun-cat__slider-input--max::-webkit-slider-thumb {
	border: 2px solid #ef4444;
}

.rodun-cat__slider-input::-webkit-slider-thumb:active {
	cursor: grabbing;
	transform: scale(1.1);
}

/* Firefox thumb — zelfde stijl. */
.rodun-cat__slider-input::-moz-range-thumb {
	width: 20px;
	height: 20px;
	border-radius: 50%;
	background: var(--background, #fff);
	cursor: grab;
	pointer-events: auto;
	box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
	transition: transform 0.1s ease;
	box-sizing: border-box;
}

.rodun-cat__slider-input--min::-moz-range-thumb {
	border: 2px solid #22c55e;
}

.rodun-cat__slider-input--max::-moz-range-thumb {
	border: 2px solid #ef4444;
}

.rodun-cat__slider-input::-moz-range-thumb:active {
	cursor: grabbing;
	transform: scale(1.1);
}

/* Focus rings — kleur volgt de thumb-kleur. */
.rodun-cat__slider-input--min:focus-visible::-webkit-slider-thumb {
	box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15), 0 0 0 3px rgba(34, 197, 94, 0.3);
}

.rodun-cat__slider-input--max:focus-visible::-webkit-slider-thumb {
	box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15), 0 0 0 3px rgba(239, 68, 68, 0.3);
}

.rodun-cat__slider-input--min:focus-visible::-moz-range-thumb {
	box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15), 0 0 0 3px rgba(34, 197, 94, 0.3);
}

.rodun-cat__slider-input--max:focus-visible::-moz-range-thumb {
	box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15), 0 0 0 3px rgba(239, 68, 68, 0.3);
}

.rodun-cat__slider-labels {
	display: flex;
	justify-content: space-between;
	margin-top: 12px;
	font-size: 12px;
	font-weight: 700;
}

.rodun-cat__slider-label--min {
	color: #22c55e;
}

.rodun-cat__slider-label--max {
	color: #ef4444;
}


/* ============================================================
 * 5. Toolbar (search + sort) — boven de grid
 * ============================================================ */

.rodun-cat__toolbar {
	display: flex;
	gap: 12px;
	margin-bottom: 24px;
}

.rodun-cat__search {
	flex: 1;
	position: relative;
	display: flex;
	align-items: center;
}

.rodun-cat__search-icon {
	position: absolute;
	left: 14px;
	color: var(--rc-muted);
	display: inline-flex;
	pointer-events: none;
}

.rodun-cat__search-icon svg {
	width: 16px;
	height: 16px;
}

.rodun-cat__search-input {
	width: 100%;
	height: 44px;
	padding: 0 16px 0 40px;
	border: 1px solid var(--rc-border);
	border-radius: 4px;
	background: #fff;
	font-size: 14px;
	color: var(--rc-fg);
	font-family: inherit;
	transition: border-color 0.15s ease, box-shadow 0.15s ease;
	-webkit-appearance: none;
	appearance: none;
}

.rodun-cat__search-input:focus {
	outline: none;
	border-color: var(--rc-primary);
	box-shadow: 0 0 0 3px rgba(15, 30, 92, 0.12);
}

.rodun-cat__search-input::-webkit-search-cancel-button {
	-webkit-appearance: none;
	appearance: none;
}

.rodun-cat__sort {
	position: relative;
	width: 224px;
	flex-shrink: 0;
}

.rodun-cat__sort-select {
	width: 100%;
	height: 44px;
	padding: 0 36px 0 14px;
	border: 1px solid var(--rc-border);
	border-radius: 4px;
	background: #fff;
	font-size: 14px;
	color: var(--rc-fg);
	font-family: inherit;
	cursor: pointer;
	-webkit-appearance: none;
	appearance: none;
	transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.rodun-cat__sort-select:focus {
	outline: none;
	border-color: var(--rc-primary);
	box-shadow: 0 0 0 3px rgba(15, 30, 92, 0.12);
}

.rodun-cat__sort-chev {
	position: absolute;
	right: 12px;
	top: 50%;
	transform: translateY(-50%);
	color: var(--rc-muted);
	pointer-events: none;
	display: inline-flex;
}

.rodun-cat__sort-chev svg {
	width: 16px;
	height: 16px;
}


/* ============================================================
 * 6. Product cards / grid / empty state
 * ============================================================ */

.rodun-cat__results {
	position: relative;
	min-height: 200px;
}

.rodun-cat__grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 24px;
}

.rodun-cat__card {
	display: flex;
	flex-direction: column;
	background: #fff;
	border: 1px solid var(--rc-border);
	border-radius: 2px;
	overflow: hidden;
	text-decoration: none;
	color: inherit;
	transition: box-shadow 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
}

.rodun-cat__card:hover,
.rodun-cat__card:focus-visible {
	box-shadow: 0 10px 25px -10px rgba(15, 30, 92, 0.18);
	border-color: rgba(15, 30, 92, 0.2);
	transform: translateY(-2px);
}

.rodun-cat__card-image {
	background: var(--rc-bg-soft);
	height: 176px;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 24px;
	overflow: hidden;
}

.rodun-cat__card-img,
.rodun-cat__card-image img {
	max-height: 112px;
	max-width: 100%;
	width: auto;
	height: auto;
	object-fit: contain;
	display: block;
	transition: transform 0.3s ease;
}

.rodun-cat__card:hover .rodun-cat__card-img,
.rodun-cat__card:hover .rodun-cat__card-image img {
	transform: scale(1.05);
}

.rodun-cat__card-placeholder {
	color: var(--rc-muted);
	opacity: 0.4;
	display: inline-flex;
}

.rodun-cat__card-placeholder svg {
	width: 56px;
	height: 56px;
}

.rodun-cat__card-body {
	padding: 20px;
	display: flex;
	flex-direction: column;
	gap: 8px;
	flex: 1;
}

.rodun-cat__card-sub {
	font-size: 11px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.08em;
	color: var(--rc-accent);
	line-height: 1.2;
}

.rodun-cat__card-title {
	margin: 0;
	font-size: 20px !important;
	font-weight: 700;
	line-height: 1.3 !important;
	color: var(--rc-fg);
	transition: color 0.15s ease;
	letter-spacing: -0.005em;
}

.rodun-cat__card:hover .rodun-cat__card-title {
	color: var(--rc-primary);
}

.rodun-cat__card-cas {
	align-self: flex-start;
	padding: 4px 8px;
	background: rgba(255, 190, 0, 0.10);
	border-radius: 2px;
	font-family: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
	font-size: 11px;
	color: var(--rc-accent);
	line-height: 1.2;
	white-space: nowrap;
}

.rodun-cat__card-desc {
	margin: 0;
	font-size: 13px;
	color: var(--rc-muted);
	line-height: 1.5;
	/* 2 regels clamp. */
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	line-clamp: 2;
	overflow: hidden;
}

.rodun-cat__card-temp {
	margin-top: auto;
	padding-top: 8px;
	display: inline-flex;
	align-items: center;
	gap: 6px;
	font-size: 13px;
	font-weight: 500;
	color: var(--rc-fg);
}

.rodun-cat__card-temp-icon {
	color: var(--rc-accent);
	display: inline-flex;
}

.rodun-cat__card-temp-icon svg {
	width: 14px;
	height: 14px;
}

/* --- Empty state --- */
.rodun-cat__empty {
	text-align: center;
	padding: 80px 16px;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 16px;
}

.rodun-cat__empty-text {
	color: var(--rc-muted);
	margin: 0;
	font-size: 15px;
}

/* --- Reset / outline button --- */
.rodun-cat__btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	padding: 10px 20px;
	font-size: 14px;
	font-weight: 600;
	font-family: inherit;
	border-radius: 4px;
	border: 0;
	cursor: pointer;
	text-decoration: none;
	line-height: 1.2;
	transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.rodun-cat__btn--outline {
	background: transparent;
	color: var(--rc-fg);
	border: 1px solid var(--rc-border);
}

.rodun-cat__btn--outline:hover,
.rodun-cat__btn--outline:focus-visible {
	background: var(--rc-bg-soft);
	border-color: var(--rc-primary);
	color: var(--rc-primary);
}

.rodun-cat__reset {
	width: 100%;
	margin-top: 8px;
}


/* ============================================================
 * 7. Mobile drawer (sidebar wordt rechter-drawer < 1024px)
 * ============================================================ */

.rodun-cat__filter-toggle {
	display: none;
	align-items: center;
	gap: 8px;
	padding: 10px 16px;
	border: 1px solid var(--rc-border);
	border-radius: 4px;
	background: #fff;
	color: var(--rc-fg);
	font-size: 14px;
	font-weight: 600;
	font-family: inherit;
	cursor: pointer;
	margin-bottom: 16px;
	transition: border-color 0.15s ease, color 0.15s ease;
}

.rodun-cat__filter-toggle:hover,
.rodun-cat__filter-toggle:focus-visible {
	border-color: var(--rc-primary);
	color: var(--rc-primary);
}

.rodun-cat__filter-toggle-icon {
	display: inline-flex;
}

.rodun-cat__filter-toggle-icon svg {
	width: 16px;
	height: 16px;
}

.rodun-cat__filter-toggle-badge {
	background: var(--rc-primary);
	color: #fff;
	font-size: 11px;
	font-weight: 700;
	padding: 2px 7px;
	border-radius: 999px;
	line-height: 1.2;
	min-width: 20px;
	text-align: center;
}

.rodun-cat__drawer-overlay {
	position: fixed;
	inset: 0;
	background: rgba(15, 23, 42, 0.5);
	/* Onder de topheader-bar (z 9999) zodat de search-dropdown bovenop blijft. */
	z-index: 9000;
	cursor: pointer;
	opacity: 0;
	pointer-events: none;
	transition: opacity 0.2s ease;
}

.rodun-cat.is-drawer-open .rodun-cat__drawer-overlay {
	display: block;
	opacity: 1;
	pointer-events: auto;
}


/* ============================================================
 * 8. Loading state
 * ============================================================ */

.rodun-cat__loading {
	position: absolute;
	inset: 0;
	display: flex;
	align-items: flex-start;
	justify-content: center;
	padding-top: 80px;
	background: rgba(255, 255, 255, 0.7);
	z-index: 5;
	pointer-events: none;
	opacity: 0;
	transition: opacity 0.15s ease;
}

.rodun-cat__loading:not([hidden]) {
	opacity: 1;
}

.rodun-cat__spinner {
	width: 32px;
	height: 32px;
	border: 3px solid var(--rc-border);
	border-top-color: var(--rc-primary);
	border-radius: 50%;
	animation: rodun-cat-spin 0.8s linear infinite;
}

@keyframes rodun-cat-spin {
	to { transform: rotate(360deg); }
}

/* Subtiel fade-effect op de results-container tijdens AJAX. */
.rodun-cat.is-loading .rodun-cat__results > * {
	opacity: 0.5;
	transition: opacity 0.15s ease;
}


/* ============================================================
 * 9. Responsive
 * ============================================================ */

@media (max-width: 1280px) {
	.rodun-cat__grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

@media (max-width: 1024px) {
	.rodun-cat__layout {
		grid-template-columns: 1fr;
		gap: 0;
	}

	.rodun-cat__filter-toggle {
		display: inline-flex;
	}

	.rodun-cat__drawer-close {
		display: inline-flex;
	}

	/*
	 * Drawer = sidebar slide-in vanaf rechts. Transform i.p.v. right om
	 * compositor-frames te krijgen (geen layout-thrash). Op desktop is
	 * de sticky-top + max-height irrelevant; op mobiel resetten we 'm.
	 */
	.rodun-cat__sidebar {
		position: fixed;
		top: 0;
		right: 0;
		bottom: 0;
		width: 320px;
		max-width: 100vw;
		max-height: none;
		border: 0;
		border-left: 1px solid var(--rc-border);
		border-radius: 0;
		transform: translateX(100%);
		transition: transform 0.25s ease;
		/* Onder de topheader-bar (z 9999) zodat de search-dropdown bovenop blijft.
		 * De mobile drawer overlay (z 9000) zorgt dat alles erachter wel afdekt. */
		z-index: 9001;
		overflow-y: auto;
		padding: 20px;
	}

	.rodun-cat.is-drawer-open .rodun-cat__sidebar {
		transform: translateX(0);
	}
}

@media (max-width: 640px) {
	.rodun-cat__toolbar {
		flex-direction: column;
	}

	.rodun-cat__sort {
		width: 100%;
	}

	.rodun-cat__grid {
		grid-template-columns: 1fr;
	}

	.rodun-cat__hero-inner {
		padding: 40px 20px;
	}

	.rodun-cat__hero-crumbs {
		font-size: 13px;
		margin-bottom: 20px;
	}

	.rodun-cat__hero-title {
		font-size: 28px !important;
	}

	.rodun-cat__hero-desc {
		font-size: 15px;
	}

	.rodun-cat__pagination {
		gap: 4px;
	}

	.rodun-cat__page {
		min-width: 36px;
		height: 36px;
		font-size: 13px;
	}
}

/* COUNT
   ----------------------------------------------------------------------- */
.rodun-cat__count {
	font-size: 14px;
	color: var(--rc-muted);
	margin: 0 0 16px;
}

/* PAGINATION
   ----------------------------------------------------------------------- */
.rodun-cat__pagination {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	margin-top: 40px;
	flex-wrap: wrap;
}

.rodun-cat__page {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 40px;
	height: 40px;
	padding: 0 10px;
	border: 1px solid var(--rc-border);
	border-radius: 8px;
	background: transparent;
	color: var(--rc-fg);
	font-size: 14px;
	font-weight: 500;
	cursor: pointer;
	transition: background .15s, border-color .15s, color .15s;
	line-height: 1;
}

.rodun-cat__page:hover,
.rodun-cat__page:focus-visible {
	background: var(--rc-bg-soft);
	border-color: var(--rc-primary);
}

.rodun-cat__page--current {
	background: var(--rc-primary);
	border-color: var(--rc-primary);
	color: #fff;
	cursor: default;
}

.rodun-cat__page--dots {
	border-color: transparent;
	cursor: default;
	pointer-events: none;
}

.rodun-cat__page--prev svg,
.rodun-cat__page--next svg {
	width: 16px;
	height: 16px;
}
