/* Cookie consent banner + preferences — uses theme RF tokens when present. */
.rf-consent[hidden],
.rf-consent__modal[hidden],
.rf-consent__reopen[hidden] {
	display: none !important;
}

.rf-consent {
	position: fixed;
	inset: auto 0 0 0;
	z-index: 100000;
	font-family: var(--rf-font-body, system-ui, sans-serif);
	color: var(--rf-color-ink, #1a1a1a);
}

.rf-consent__banner {
	background: var(--rf-color-white, #fff);
	border-top: 1px solid rgba(3, 35, 86, 0.12);
	box-shadow: 0 -8px 32px rgba(3, 35, 86, 0.12);
}

.rf-consent__banner-inner {
	max-width: var(--rf-container, 1200px);
	margin: 0 auto;
	padding: 1.25rem 1.25rem 1.5rem;
	display: flex;
	flex-wrap: wrap;
	gap: 1rem 1.5rem;
	align-items: flex-end;
	justify-content: space-between;
}

.rf-consent__copy {
	flex: 1 1 280px;
	max-width: 46rem;
}

.rf-consent__title {
	display: block;
	font-family: var(--rf-font-heading, inherit);
	font-size: 1.125rem;
	color: var(--rf-color-primary, #032356);
	margin-bottom: 0.35rem;
}

.rf-consent__intro {
	margin: 0 0 0.5rem;
	font-size: 0.95rem;
	line-height: 1.45;
	color: var(--rf-color-ink-soft, #333);
}

.rf-consent__links {
	margin: 0;
	font-size: 0.875rem;
}

.rf-consent__links a {
	color: var(--rf-color-secondary, #1c75bc);
	text-decoration: underline;
}

.rf-consent__actions {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	align-items: center;
}

.rf-consent__actions--end {
	justify-content: flex-end;
	margin-top: 1rem;
}

.rf-consent__btn {
	appearance: none;
	border: 1px solid transparent;
	border-radius: 4px;
	padding: 0.65rem 1rem;
	font: inherit;
	font-size: 0.9rem;
	font-weight: 600;
	cursor: pointer;
	line-height: 1.2;
}

.rf-consent__btn--primary {
	background: var(--rf-color-secondary, #1c75bc);
	color: #fff;
}

.rf-consent__btn--secondary {
	background: var(--rf-color-primary, #032356);
	color: #fff;
}

.rf-consent__btn--ghost {
	background: transparent;
	border-color: rgba(3, 35, 86, 0.35);
	color: var(--rf-color-primary, #032356);
}

.rf-consent__btn:focus-visible {
	outline: 2px solid var(--rf-color-secondary, #1c75bc);
	outline-offset: 2px;
}

.rf-consent__modal {
	position: fixed;
	inset: 0;
	z-index: 100001;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 1rem;
}

.rf-consent__modal-backdrop {
	position: absolute;
	inset: 0;
	background: rgba(3, 35, 86, 0.45);
}

.rf-consent__panel {
	position: relative;
	z-index: 1;
	width: min(100%, 32rem);
	background: #fff;
	border-radius: 8px;
	padding: 1.25rem 1.25rem 1.5rem;
	box-shadow: 0 16px 48px rgba(0, 0, 0, 0.2);
	max-height: min(90vh, 36rem);
	overflow: auto;
}

.rf-consent__panel-head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
	margin-bottom: 1rem;
	font-family: var(--rf-font-heading, inherit);
	color: var(--rf-color-primary, #032356);
	font-size: 1.15rem;
}

.rf-consent__icon-btn {
	appearance: none;
	border: 0;
	background: transparent;
	font-size: 1.5rem;
	line-height: 1;
	cursor: pointer;
	color: inherit;
	padding: 0.15rem 0.35rem;
}

.rf-consent__prefs {
	display: grid;
	gap: 0.75rem;
}

.rf-consent__pref {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 1rem;
	padding: 0.75rem;
	border: 1px solid rgba(3, 35, 86, 0.12);
	border-radius: 6px;
	cursor: pointer;
}

.rf-consent__pref-text {
	display: grid;
	gap: 0.25rem;
}

.rf-consent__pref-text small {
	color: var(--rf-color-ink-soft, #555);
	line-height: 1.4;
}

.rf-consent__pref input {
	margin-top: 0.2rem;
	width: 1.1rem;
	height: 1.1rem;
	flex-shrink: 0;
}

.rf-consent__reopen {
	position: fixed;
	left: 1rem;
	bottom: 1rem;
	z-index: 99990;
	appearance: none;
	border: 0;
	border-radius: 999px;
	padding: 0.55rem 0.9rem;
	font: inherit;
	font-size: 0.8rem;
	font-weight: 600;
	cursor: pointer;
	background: var(--rf-color-primary, #032356);
	color: #fff;
	box-shadow: 0 4px 16px rgba(3, 35, 86, 0.25);
}

.rf-consent__reopen:focus-visible {
	outline: 2px solid var(--rf-color-secondary, #1c75bc);
	outline-offset: 2px;
}

html.rf-consent-open {
	overflow: hidden;
}

@media (max-width: 640px) {
	.rf-consent__actions {
		width: 100%;
	}
	.rf-consent__btn {
		flex: 1 1 auto;
	}
	.rf-consent__reopen {
		left: 0.75rem;
		bottom: 0.75rem;
	}
}
