/**
 * Rood Cycle Center — header & mega menu
 * Tokens: assets/css/root.css (--background, --primary, --rc-*)
 */

.rc-header {
	position: relative;
	z-index: var(--z-header);
	font-family: var(--font-family);
	color: var(--foreground);
}

.rc-header .screen-reader-text {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

.rc-header__spacer {
	display: block;
	width: 100%;
	margin: 0;
	padding: 0;
	border: none;
}

/* Shortcode-slot in Avada-header: geen dubbele hoogte na portal */
.rc-header--portaled {
	display: none !important;
}

.fusion-tb-header:has(.rc-header--portaled),
.fusion-header-wrapper:has(.rc-header--portaled),
#fusion-header-wrapper:has(.rc-header--portaled) {
	display: none !important;
	height: 0 !important;
	min-height: 0 !important;
	margin: 0 !important;
	padding: 0 !important;
	border: none !important;
	overflow: hidden !important;
}

.fusion-fullwidth:has(.rc-header--portaled),
.fusion-builder-row:has(.rc-header--portaled),
.fusion-layout-column:has(.rc-header--portaled),
.fusion-column-wrapper:has(.rc-header--portaled),
.fusion-builder-column:has(.rc-header--portaled) {
	min-height: 0 !important;
	margin: 0 !important;
	padding: 0 !important;
}

.rc-header__sticky {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	z-index: var(--z-header) !important;
	background: var(--background);
}

body.admin-bar .rc-header__sticky {
	top: 32px;
}

@media screen and (max-width: 782px) {
	body.admin-bar .rc-header__sticky {
		top: 46px;
	}
}

.rc-header__container {
	max-width: var(--rc-container);
	margin: 0 auto;
	padding-left: var(--rc-container-px);
	padding-right: var(--rc-container-px);
}

/* ── Top row ───────────────────────────────────────────────── */

.rc-header__top {
	height: var(--rc-top-height);
	border-bottom: 1px solid var(--rc-border);
	background: var(--rc-background);
}

.rc-header__top-inner {
	display: flex;
	align-items: center;
	gap: 24px;
	height: 100%;
}

.rc-header__toggle {
	display: inline-flex;
	flex-direction: column;
	justify-content: center;
	gap: 5px;
	width: 40px;
	height: 40px;
	padding: 0;
	border: 0;
	background: transparent;
	cursor: pointer;
}

.rc-header__toggle-bar {
	display: block;
	width: 20px;
	height: 2px;
	margin: 0 auto;
	background: var(--rc-foreground-80);
	border-radius: 1px;
}

@media (min-width: 1024px) {
	.rc-header__toggle {
		display: none;
	}
}

.rc-header__logo {
	display: inline-flex;
	align-items: center;
	flex-shrink: 0;
	text-decoration: none;
	color: var(--rc-foreground);
}

.rc-header__logo-img {
	display: block;
	height: 48px;
	width: auto;
	aspect-ratio: 192 / 48;
}

.rc-header__logo-text {
	font-size: 1.125rem;
	font-weight: 600;
}

.rc-header__search {
	position: relative;
	display: none;
	flex: 1;
	max-width: 576px;
	margin: 0 auto;
}

@media (min-width: 768px) {
	.rc-header__search {
		display: block;
	}
}

.rc-header__search-icon {
	position: absolute;
	left: 16px;
	top: 50%;
	transform: translateY(-50%);
	color: var(--rc-muted-foreground);
	pointer-events: none;
}

.rc-header__search-input {
	width: 100%;
	height: 44px;
	padding: 0 16px 0 44px;
	border: 1px solid var(--rc-border);
	border-radius: var(--rc-radius-pill);
	background: var(--rc-secondary-60);
	color: var(--rc-foreground);
	font-size: 14px;
	font-weight: 500;
	outline: none;
	transition: border-color var(--rc-transition), background var(--rc-transition), box-shadow var(--rc-transition);
}

.rc-header__search-input::placeholder {
	color: var(--rc-muted-foreground);
}

.rc-header__search-input:focus {
	border-color: var(--rc-primary);
	background: var(--rc-background);
	box-shadow: 0 0 0 2px var(--rc-primary-20);
}

.rc-header__actions {
	display: flex;
	align-items: center;
	gap: 8px;
	margin-left: auto;
}

.rc-header__icon-btn {
	position: relative;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 40px;
	height: 40px;
	padding: 0;
	border: 0;
	border-radius: var(--rc-radius-pill);
	background: transparent;
	color: var(--rc-foreground-80);
	font: inherit;
	text-decoration: none;
	cursor: pointer;
	transition: background var(--rc-transition), color var(--rc-transition);
}

.rc-header__icon-btn:hover,
.rc-header__icon-btn:focus-visible {
	background: var(--rc-secondary);
	color: var(--rc-primary);
}

.rc-header__icon-btn--account {
	display: none;
}

@media (min-width: 640px) {
	.rc-header__icon-btn--account {
		display: inline-flex;
	}
}

/* ── Account dropdown ────────────────────────────────────────── */

.rc-header__account {
	position: relative;
	flex-shrink: 0;
}

.rc-header__account-menu {
	position: absolute;
	top: calc(100% + 8px);
	right: 0;
	z-index: calc(var(--z-header) + 2);
	min-width: 220px;
	background: var(--background);
	border: 1px solid var(--border);
	border-radius: var(--radius-md);
	box-shadow: var(--shadow-mega);
	padding: 8px 0;
}

.rc-header__account-menu--portaled {
	position: fixed;
	top: 0;
	left: auto;
	right: 0;
	z-index: calc(var(--z-header) + 2) !important;
}

.rc-header__account-menu[hidden] {
	display: none !important;
}

.rc-header__account.is-open .rc-header__icon-btn--account {
	background: var(--secondary);
	color: var(--primary);
}

.rc-header__account-greeting {
	margin: 0;
	padding: 8px 16px 4px;
	font-size: 12px;
	font-weight: 600;
	color: var(--muted-foreground);
	border-bottom: 1px solid var(--border-60);
}

.rc-header__account-menu-list {
	margin: 0;
	padding: 4px 0;
	list-style: none;
}

.rc-header__account-menu-item {
	margin: 0;
	padding: 0;
}

.rc-header__account-menu-link {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 10px 16px;
	font-size: 14px;
	font-weight: 500;
	color: var(--foreground-80);
	text-decoration: none;
	transition: background var(--transition), color var(--transition);
}

.rc-header__account-menu-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 24px;
	height: 24px;
	border-radius: var(--radius-md);
	background: var(--primary-08);
	color: var(--primary);
	flex-shrink: 0;
}

.rc-header__account-menu-link:hover,
.rc-header__account-menu-link:focus-visible {
	background: var(--secondary);
	color: var(--primary);
	outline: none;
}

.rc-header__account-menu-link--logout {
	margin-top: 4px;
	border-top: 1px solid var(--border-60);
	color: var(--foreground-75);
}

.rc-header__account-menu-link--logout .rc-header__account-menu-icon {
	background: color-mix(in srgb, var(--foreground) 8%, transparent);
	color: var(--foreground-60);
}

.rc-header__account-menu-link--logout:hover,
.rc-header__account-menu-link--logout:focus-visible {
	color: var(--primary);
}

.rc-header__account-menu-link--logout:hover .rc-header__account-menu-icon,
.rc-header__account-menu-link--logout:focus-visible .rc-header__account-menu-icon {
	background: var(--primary-08);
	color: var(--primary);
}

.rc-header__cart-badge {
	position: absolute;
	top: -4px;
	right: -4px;
	min-width: 20px;
	height: 20px;
	padding: 0 5px;
	border-radius: var(--rc-radius-pill);
	background: var(--rc-primary);
	color: var(--rc-primary-foreground);
	font-size: 10px;
	font-weight: 700;
	line-height: 20px;
	text-align: center;
}

.rc-header__cta {
	display: none;
	align-items: center;
	justify-content: center;
	height: 40px;
	padding: 0 16px;
	border-radius: var(--rc-radius);
	background: var(--rc-primary);
	color: var(--rc-primary-foreground);
	font-size: 14px;
	font-weight: 500;
	text-decoration: none;
	white-space: nowrap;
	transition: background var(--rc-transition);
}

.rc-header__cta:hover,
.rc-header__cta:focus-visible {
	background: var(--rc-primary-90);
	color: var(--rc-primary-foreground);
}

@media (min-width: 1024px) {
	.rc-header__cta {
		display: inline-flex;
	}
}

.rc-icon {
	display: block;
	flex-shrink: 0;
}

.rc-icon--xs {
	width: 12px;
	height: 12px;
}

.rc-icon--sm {
	width: 14px;
	height: 14px;
}

.rc-icon--md {
	width: 20px;
	height: 20px;
}

/* ── Nav row ───────────────────────────────────────────────── */

.rc-header__nav {
	display: none;
	position: relative;
	height: var(--rc-nav-height);
	border-bottom: 1px solid var(--rc-border-60);
	background: var(--rc-background);
}

@media (min-width: 1024px) {
	.rc-header__nav {
		display: block;
	}
}

.rc-header__nav-list {
	display: flex;
	align-items: center;
	height: 100%;
	margin: 0;
	padding: 0;
	list-style: none;
}

.rc-header__nav-item {
	position: static;
}

.rc-header__nav-link {
	position: relative;
	display: inline-flex;
	align-items: center;
	padding: 12px 16px;
	color: var(--rc-foreground-75);
	font-size: 14px;
	font-weight: 500;
	letter-spacing: 0.02em;
	text-decoration: none;
	transition: color var(--rc-transition-slow);
}

.rc-header__nav-link:hover,
.rc-header__nav-link:focus-visible,
.rc-header__nav-item:focus-within > .rc-header__nav-link {
	color: var(--rc-foreground);
}

.rc-header__nav-item.is-highlight > .rc-header__nav-link {
	color: var(--rc-primary);
}

.rc-header__nav-underline {
	position: absolute;
	left: 16px;
	right: 16px;
	bottom: 6px;
	height: 1px;
	background: var(--rc-primary);
	transform: scaleX(0);
	transform-origin: center;
	transition: transform var(--rc-transition-slow);
}

.rc-header__nav-item.is-highlight > .rc-header__nav-link .rc-header__nav-underline,
.rc-header__nav-item:hover > .rc-header__nav-link .rc-header__nav-underline,
.rc-header__nav-item:focus-within > .rc-header__nav-link .rc-header__nav-underline {
	transform: scaleX(1);
}

/* ── Mega panel ─────────────────────────────────────────────── */

.mega-panel {
	position: absolute;
	left: 0;
	right: 0;
	top: 100%;
	z-index: 40;
	visibility: hidden;
	opacity: 0;
	transform: translateY(8px);
	background: rgba(255, 255, 255, 0.95);
	backdrop-filter: blur(12px);
	border-bottom: 1px solid var(--rc-border-60);
	box-shadow: var(--rc-shadow-mega);
	transition: visibility var(--rc-transition), opacity var(--rc-transition), transform var(--rc-transition);
}

.rc-header__nav-item--mega:hover .mega-panel,
.rc-header__nav-item--mega:focus-within .mega-panel {
	visibility: visible;
	opacity: 1;
	transform: translateY(0);
}

.mega-inner {
	display: grid;
	grid-template-columns: repeat(12, 1fr);
	gap: 24px 40px;
	max-width: var(--rc-container);
	margin: 0 auto;
	padding: 24px var(--rc-container-px) 32px;
}

.mega-columns {
	grid-column: 1 / -1;
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	column-gap: 40px;
	row-gap: 24px;
}

.mega-columns--with-feature {
	grid-column: span 8;
	grid-template-columns: repeat(2, minmax(0, 1fr));
}

.mega-feature {
	grid-column: span 4;
	display: flex;
	flex-direction: column;
	border: 1px solid var(--rc-border-60);
	border-radius: var(--rc-radius-2xl);
	background: var(--rc-secondary-40);
	overflow: hidden;
	text-decoration: none;
	color: inherit;
}

.mega-col__heading {
	display: flex;
	align-items: center;
	gap: 8px;
	margin-bottom: 12px;
}

.mega-col__icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 24px;
	height: 24px;
	border-radius: var(--rc-radius-md);
	background: var(--rc-primary-08);
	color: var(--rc-primary);
}

.mega-col__heading h3 {
	margin: 0;
	font-size: 11px;
	font-weight: 600;
	letter-spacing: 0.16em;
	text-transform: uppercase;
	color: var(--rc-foreground-60);
}

.mega-col__heading h3 a {
	color: inherit;
	text-decoration: none;
}

.mega-col__heading h3 a:hover {
	color: var(--rc-primary);
}

.mega-col__links {
	margin: 0;
	padding: 0;
	list-style: none;
	display: flex;
	flex-direction: column;
	gap: 6px;
}

.mega-col__links a {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 8px;
	color: var(--rc-foreground-80);
	font-size: 14px;
	font-weight: 500;
	text-decoration: none;
	transition: color var(--rc-transition);
}

.mega-col__links a:hover,
.mega-col__links a:focus-visible {
	color: var(--rc-primary);
}

.mega-col__arrow {
	opacity: 0;
	transform: translateX(-4px);
	transition: opacity var(--rc-transition), transform var(--rc-transition);
}

.mega-col__links a:hover .mega-col__arrow,
.mega-col__links a:focus-visible .mega-col__arrow {
	opacity: 1;
	transform: translateX(0);
}

.mega-feature__media {
	position: relative;
	height: 128px;
	aspect-ratio: 16 / 9;
	overflow: hidden;
}

.mega-feature__media img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 700ms ease;
}

.mega-feature:hover .mega-feature__media img {
	transform: scale(1.05);
}

.mega-feature__media::after {
	content: "";
	position: absolute;
	inset: 0;
	background: var(--gradient-feature-overlay);
	pointer-events: none;
}

.mega-feature__eyebrow {
	position: absolute;
	top: 12px;
	left: 12px;
	padding: 4px 10px;
	border-radius: var(--rc-radius-pill);
	background: rgba(255, 255, 255, 0.9);
	backdrop-filter: blur(8px);
	color: var(--rc-primary);
	font-size: 10px;
	font-weight: 600;
	letter-spacing: 0.05em;
	text-transform: uppercase;
}

.mega-feature__body {
	display: flex;
	flex: 1;
	flex-direction: column;
	justify-content: space-between;
	gap: 12px;
	padding: 16px;
}

.mega-feature__title {
	margin: 0;
	font-size: 14px;
	font-weight: 600;
	line-height: 1.35;
	color: var(--rc-foreground);
}

.mega-feature__desc {
	margin: 0;
	font-size: 12px;
	line-height: 1.55;
	color: var(--rc-muted-foreground);
}

.mega-feature__cta {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	color: var(--rc-primary);
	font-size: 12px;
	font-weight: 600;
}

.mega-feature__cta .rc-icon {
	transition: transform var(--rc-transition);
}

.mega-feature:hover .mega-feature__cta .rc-icon {
	transform: translateX(2px);
}

/* ── Mobile drawer ───────────────────────────────────────────── */

.rc-header__overlay {
	position: fixed;
	inset: 0;
	z-index: calc(var(--z-header) - 1);
	background: rgba(35, 29, 23, 0.45);
	opacity: 0;
	transition: opacity var(--rc-transition);
}

.rc-header__overlay.is-visible {
	opacity: 1;
}

.rc-header__drawer {
	position: fixed;
	top: 0;
	right: 0;
	z-index: var(--z-header);
	display: flex;
	flex-direction: column;
	width: min(320px, 100vw);
	height: 100dvh;
	background: var(--rc-background);
	box-shadow: var(--rc-shadow-mega);
	transform: translateX(100%);
	transition: transform var(--rc-transition-slow);
}

.rc-header__drawer.is-open {
	transform: translateX(0);
}

.rc-header__drawer-head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 16px var(--rc-container-px);
	border-bottom: 1px solid var(--rc-border);
}

.rc-header__drawer-title {
	font-size: 14px;
	font-weight: 600;
}

.rc-header__drawer-close {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	border: 0;
	border-radius: var(--rc-radius-pill);
	background: transparent;
	font-size: 24px;
	line-height: 1;
	cursor: pointer;
}

.rc-header__drawer-search {
	padding: 16px var(--rc-container-px);
	border-bottom: 1px solid var(--rc-border);
}

.rc-header__drawer-search .rc-header__search {
	display: block;
	max-width: none;
}

.rc-header__drawer-nav {
	flex: 1;
	overflow-y: auto;
	padding: 8px 0;
}

.rc-header__drawer-list {
	margin: 0;
	padding: 0;
	list-style: none;
}

.rc-header__drawer-link,
.rc-header__drawer-trigger {
	display: flex;
	align-items: center;
	justify-content: space-between;
	width: 100%;
	padding: 14px var(--rc-container-px);
	border: 0;
	background: transparent;
	color: var(--rc-foreground-80);
	font-size: 14px;
	font-weight: 500;
	text-align: left;
	text-decoration: none;
	cursor: pointer;
}

.rc-header__drawer-item.is-highlight .rc-header__drawer-link,
.rc-header__drawer-item.is-highlight .rc-header__drawer-trigger {
	color: var(--rc-primary);
}

.rc-header__drawer-chevron {
	width: 8px;
	height: 8px;
	border-right: 2px solid currentColor;
	border-bottom: 2px solid currentColor;
	transform: rotate(45deg);
	transition: transform var(--rc-transition);
}

.rc-header__drawer-trigger[aria-expanded="true"] .rc-header__drawer-chevron {
	transform: rotate(-135deg);
}

.rc-header__drawer-panel {
	padding: 0 var(--rc-container-px) 12px;
}

.rc-header__drawer-parent-link {
	display: inline-block;
	margin-bottom: 12px;
	color: var(--rc-primary);
	font-size: 13px;
	font-weight: 600;
	text-decoration: none;
}

.rc-header__drawer-group + .rc-header__drawer-group {
	margin-top: 16px;
}

.rc-header__drawer-group-title {
	margin: 0 0 8px;
	font-size: 11px;
	font-weight: 600;
	letter-spacing: 0.16em;
	text-transform: uppercase;
	color: var(--rc-foreground-60);
}

.rc-header__drawer-sublinks {
	margin: 0;
	padding: 0;
	list-style: none;
}

.rc-header__drawer-sublinks a {
	display: block;
	padding: 8px 0;
	color: var(--rc-foreground-80);
	font-size: 14px;
	text-decoration: none;
}

.rc-header__drawer-sublinks a:hover {
	color: var(--rc-primary);
}

.rc-header__drawer-footer {
	padding: 16px var(--rc-container-px);
	border-top: 1px solid var(--rc-border);
}

.rc-header__drawer-cta {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 44px;
	border-radius: var(--rc-radius);
	background: var(--rc-primary);
	color: var(--rc-primary-foreground);
	font-size: 14px;
	font-weight: 500;
	text-decoration: none;
}

.rc-header__admin-hint {
	margin: 0;
	padding: 8px 0;
	font-size: 12px;
	font-style: italic;
	color: var(--rc-muted-foreground);
}

body.rc-header-drawer-open {
	overflow: hidden;
}

@media (min-width: 1024px) {
	.rc-header__drawer,
	.rc-header__overlay {
		display: none !important;
	}
}
