/* ==========================================================================
   BKA 2026 v5 · pages/overview – Rólunk · Hogyan segítünk? · Hogyan segíthet?
   Statement (the approved lead) → photographic chapter grid: 7+5 / 4+4+4 /
   5+7 rows, title and number on the photograph, neutral scrim (no red
   overlay), round arrow. No empty boxes: a destination without a photo gets
   the red brand placeholder.
   ========================================================================== */

.v5-overview__intro {
	padding-block: clamp(3.5rem, 2.5rem + 4vw, 7rem);
	background: var(--v5-white);
}
.v5-overview__statement .v5-statement__text {
	max-width: 31ch;
	font-size: clamp(1.75rem, 1.1rem + 2.3vw, 3.25rem);
	line-height: 1.18;
}
/* Rólunk: the home-page mission sentence, set like on the home page. */
.v5-page--rolunk .v5-overview__intro { padding-block: clamp(2.25rem, 1.75rem + 2vw, 3.75rem); }
.v5-page--rolunk .v5-overview__statement .v5-statement__text {
	max-width: 76rem;
	color: var(--v5-red);
	font-size: clamp(1.625rem, 1.05rem + 2.1vw, 2.875rem);
	line-height: 1.16;
	text-wrap: balance;
}

/* Chapter grid ------------------------------------------------------------- */
.v5-overview__chapters { padding-block: var(--v5-section-y-tight) var(--v5-section-y); }
.v5-chapters {
	display: grid;
	grid-template-columns: repeat(12, minmax(0, 1fr));
	gap: var(--v5-gap);
	margin: 0;
	padding: 0;
	list-style: none;
	counter-reset: v5-chapter;
}
.v5-chapters__item { grid-column: span var(--v5-span, 4); min-width: 0; margin: 0; counter-increment: v5-chapter; }
.v5-chapters__item + .v5-chapters__item { margin-top: 0; }

.v5-chapter {
	position: relative;
	display: flex;
	align-items: flex-end;
	height: 100%;
	min-height: clamp(20rem, 12rem + 15vw, 30rem);
	overflow: hidden;
	border-radius: var(--v5-radius-lg);
	background: #1d171b;
	color: #fff;
	text-decoration: none;
	isolation: isolate;
	box-shadow: var(--v5-shadow-card);
	transition: transform var(--v5-dur) var(--v5-ease), box-shadow var(--v5-dur) var(--v5-ease);
}
.v5-chapters__item--third .v5-chapter { min-height: clamp(17rem, 11rem + 10vw, 23rem); }
.v5-chapter::before {
	content: "";
	position: absolute;
	z-index: -1;
	inset: 0;
	background: linear-gradient(0deg, rgba(var(--v5-scrim), .74) 0%, rgba(var(--v5-scrim), .32) 36%, rgba(var(--v5-scrim), 0) 64%);
	transition: opacity var(--v5-dur) var(--v5-ease);
}
.v5-chapter__media { position: absolute; z-index: -2; inset: 0; display: block; }
.v5-chapter__media img { width: 100%; height: 100%; object-fit: cover; transition: transform var(--v5-dur-slow) var(--v5-ease); }
.v5-chapter__media .v5-placeholder { min-height: 100%; }
.v5-chapter__body {
	display: flex;
	align-items: flex-end;
	justify-content: space-between;
	gap: 1.25rem;
	width: 100%;
	padding: clamp(1.5rem, 1rem + 1.4vw, 2.5rem);
}
.v5-chapter__title {
	display: grid;
	gap: .65rem;
	color: #fff;
	font-family: var(--v5-font-display);
	font-size: clamp(1.75rem, 1.25rem + 1.5vw, 2.75rem);
	line-height: 1.04;
	text-wrap: balance;
	text-shadow: 0 1px 18px rgba(var(--v5-scrim), .35);
}
.v5-chapters__item--third .v5-chapter__title { font-size: clamp(1.5rem, 1.15rem + 1vw, 2.125rem); }
.v5-chapter__title::before {
	content: counter(v5-chapter, decimal-leading-zero);
	display: flex;
	align-items: center;
	gap: .7rem;
	color: rgba(255, 255, 255, .9);
	font-family: var(--v5-font-text);
	font-size: .8125rem;
	font-weight: var(--v5-w-bold);
	letter-spacing: .18em;
}
/* Rólunk, Hogyan segítünk? and Hogyan segíthet?: the chapters carry no numbers. */
.v5-page--rolunk .v5-chapter__title::before,
.v5-page--hogyan-segitunk .v5-chapter__title::before,
.v5-page--hogyan-segithet .v5-chapter__title::before { display: none; }
.v5-chapter__arrow {
	display: grid;
	place-items: center;
	flex: none;
	width: 3.25rem;
	height: 3.25rem;
	border-radius: 50%;
	background: #fff;
	color: var(--v5-red);
	box-shadow: var(--v5-shadow-button);
	transition: background-color var(--v5-dur) var(--v5-ease), color var(--v5-dur) var(--v5-ease), transform var(--v5-dur) var(--v5-ease);
}
.v5-chapter:hover { transform: translateY(-4px); box-shadow: var(--v5-shadow-lift); color: #fff; text-decoration: none; }
.v5-chapter:hover .v5-chapter__media img { transform: scale(1.05); }
.v5-chapter:hover .v5-chapter__arrow { background: var(--v5-red); color: #fff; transform: translateX(3px); }
.v5-chapter:focus-visible { box-shadow: var(--v5-focus); border-radius: var(--v5-radius-lg); }
.v5-chapter--brand::before { opacity: .45; }

@media (max-width: 56rem) {
	.v5-chapters__item,
	.v5-chapters__item--third { grid-column: span 6; }
	.v5-chapters__item:last-child:nth-child(odd) { grid-column: 1 / -1; }
	.v5-chapter,
	.v5-chapters__item--third .v5-chapter { min-height: clamp(16rem, 10rem + 18vw, 22rem); }
}

@media (max-width: 40rem) {
	.v5-chapters { gap: 1rem; }
	.v5-chapters__item,
	.v5-chapters__item--third,
	.v5-chapters__item:last-child:nth-child(odd) { grid-column: 1 / -1; }
	.v5-chapter,
	.v5-chapters__item--third .v5-chapter { min-height: 0; aspect-ratio: 4 / 3; }
	.v5-chapter__title,
	.v5-chapters__item--third .v5-chapter__title { font-size: 1.75rem; }
	.v5-chapter__arrow { width: 2.75rem; height: 2.75rem; }
}
