/*
 * Beoordelingsinstructies: one section per discipline. Text and downloads on the
 * left (sticky on desktop), a stack of cards on the right. The cards are Flexible
 * Content: tabel, lijst, stappen, afbeelding_tekst, uitgelicht and duo.
 */

.beo-section {
	scroll-margin-top: var(--rbnl-header-offset);
}

/* A sand discipline is a rounded panel; the gap above it comes from here. */
.beo-section--sand {
	margin-top: var(--rbnl-section-gap);
}

.beo-section__grid {
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	gap: 28px;
	align-items: start;
}

.beo-section__head {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 18px;
	min-width: 0;
}

.beo-section__head .btn-row {
	padding-top: 4px;
}

.beo-section__cards {
	display: flex;
	flex-direction: column;
	gap: 16px;
	min-width: 0;
}

/* ----------------------------------------------------------------- Cards */

.beo-card {
	--beo-line: var(--rbnl-line);
	display: flex;
	flex-direction: column;
	gap: 10px;
	min-width: 0;
	padding: 22px;
	border-radius: var(--rbnl-radius-card-lg);
	background: var(--rbnl-white);
}

.beo-card--lilac {
	--beo-line: #dad7ec;
	background: var(--rbnl-lilac);
}

.beo-card--sand {
	background: var(--rbnl-sand);
}

.beo-card--peach {
	--beo-line: #f3cfae;
	background: var(--rbnl-peach);
}

.beo-card__title {
	margin: 0;
	font-size: 22px;
	line-height: 1.2;
	letter-spacing: -0.01em;
}

.beo-card__sub,
.beo-card__example {
	margin: 0;
	color: var(--rbnl-orange-dark);
	font-size: 14px;
	font-weight: 600;
}

.beo-card__intro,
.beo-card__note,
.beo-card__text {
	color: var(--rbnl-text);
	font-size: 15px;
	line-height: 1.55;
}

.beo-card__intro > *,
.beo-card__note > *,
.beo-card__text > * {
	margin: 0 0 10px;
}

.beo-card__intro > :last-child,
.beo-card__note > :last-child,
.beo-card__text > :last-child {
	margin-bottom: 0;
}

.beo-card__note {
	margin-top: 4px;
}

.beo-card strong {
	color: var(--rbnl-ink);
}

/* tabel */
.beo-rows {
	display: flex;
	flex-direction: column;
	margin: 0;
}

.beo-rows__row {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: 16px;
	padding: 10px 0;
	border-bottom: 1px solid var(--beo-line);
}

.beo-rows dt {
	min-width: 0;
	color: var(--rbnl-text);
}

.beo-rows dd {
	flex: 0 0 auto;
	margin: 0;
	color: var(--rbnl-ink);
	font-family: var(--rbnl-font-heading);
	font-size: 19px;
	font-weight: 600;
	text-align: right;
}

/* lijst */
.beo-list {
	margin: 0;
	padding: 0;
	list-style: none;
}

.beo-list li {
	display: flex;
	align-items: flex-start;
	gap: 12px;
	padding: 9px 0;
	border-bottom: 1px solid var(--beo-line);
	color: var(--rbnl-ink);
	font-size: 16px;
	line-height: 1.45;
}

.beo-list li:last-child {
	border-bottom: 0;
}

.beo-list__dot {
	flex: 0 0 auto;
	width: 8px;
	height: 8px;
	margin-top: 8px;
	border-radius: 50%;
	background: var(--rbnl-orange);
}

.beo-list .beo-list__total {
	justify-content: space-between;
	align-items: baseline;
	padding-top: 14px;
	font-weight: 600;
}

.beo-list__total strong {
	font-family: var(--rbnl-font-heading);
	font-size: 19px;
}

/* stappen */
.beo-steps {
	display: flex;
	flex-direction: column;
	gap: 12px;
	margin: 4px 0 0;
	padding: 0;
	list-style: none;
}

.beo-steps li {
	display: flex;
	align-items: flex-start;
	gap: 14px;
}

.beo-steps__n {
	display: inline-flex;
	flex: 0 0 auto;
	align-items: center;
	justify-content: center;
	width: 32px;
	height: 32px;
	border-radius: 50%;
	background: var(--rbnl-orange-strong);
	color: var(--rbnl-white);
	font-size: 15px;
	font-weight: 700;
}

.beo-steps__text {
	padding-top: 4px;
	color: var(--rbnl-ink);
	font-size: 16px;
	line-height: 1.5;
}

/* afbeelding_tekst en uitgelicht */
.beo-card--afbeelding_tekst,
.beo-card--uitgelicht {
	gap: 20px;
}

.beo-card__body {
	display: flex;
	flex-direction: column;
	gap: 8px;
	min-width: 0;
}

.beo-card__round {
	flex: 0 0 auto;
	width: 140px;
	height: 140px;
	overflow: hidden;
	border-radius: 50%;
	background: var(--rbnl-white);
}

.beo-card__round img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.beo-card--uitgelicht .beo-card__text {
	font-size: 16px;
}

/* duo */
.beo-duo {
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	gap: 16px;
	align-items: start;
}

/* ------------------------------------------- Course map thumbnail + lightbox */

.mapthumb {
	position: relative;
	display: block;
	width: min(300px, 100%);
	padding: 0;
	overflow: hidden;
	border: 0;
	border-radius: 18px;
	background: var(--rbnl-sand);
	cursor: zoom-in;
}

.mapthumb img {
	display: block;
	width: 100%;
	height: auto;
	aspect-ratio: 1;
	object-fit: cover;
	transition: transform 0.6s var(--rbnl-ease);
}

.mapthumb:hover img {
	transform: scale(1.04);
}

.mapthumb__label {
	position: absolute;
	right: 12px;
	bottom: 12px;
	display: inline-flex;
	align-items: center;
	gap: 8px;
	min-height: 40px;
	padding: 0 16px;
	border-radius: var(--rbnl-radius-pill);
	background: var(--rbnl-ink);
	color: var(--rbnl-white);
	font-size: 14px;
	font-weight: 500;
}

.lightbox {
	position: fixed;
	inset: 0;
	z-index: 200;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 20px;
	background: rgba(33, 30, 100, 0.86);
	animation: rbnl-fade 0.3s var(--rbnl-ease);
}

.lightbox[hidden] {
	display: none;
}

.lightbox img {
	max-width: 100%;
	max-height: 100%;
	border-radius: 16px;
	background: var(--rbnl-white);
	object-fit: contain;
}

.lightbox__close {
	position: absolute;
	top: 16px;
	right: 16px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 48px;
	height: 48px;
	border: 0;
	border-radius: 50%;
	background: var(--rbnl-white);
	color: var(--rbnl-ink);
	cursor: pointer;
}

@keyframes rbnl-fade {
	from {
		opacity: 0;
	}
}

/* --------------------------------------------------------------- Desktop */

@media (min-width: 640px) {
	.beo-card {
		padding: 28px;
	}

	.beo-card--afbeelding_tekst,
	.beo-card--uitgelicht {
		flex-direction: row;
		align-items: center;
		gap: 28px;
	}

	.beo-card--afbeelding_tekst .mapthumb {
		flex: 0 0 min(300px, 42%);
	}
}

@media (min-width: 1024px) {
	.beo-section__grid {
		grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
		gap: 64px;
	}

	.beo-section__head {
		position: sticky;
		top: calc(var(--rbnl-header-offset) + 24px);
	}

	.beo-duo {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

@media (prefers-reduced-motion: reduce) {
	.mapthumb img,
	.lightbox {
		animation: none;
		transition: none;
	}
}
