/*
 * happybaby Fotoaktionen – Frontend
 * Übernimmt die Farben der Startseite (--hb-*), mit eigenen Ersatzwerten.
 * Optik: Familienjournal – ruhige Flächen, Serifenüberschriften, feine Linien.
 */

.hbfa {
	--hbfa-ink: var(--hb-ink, #2F2A33);
	--hbfa-text: var(--hb-text, #4A4350);
	--hbfa-muted: var(--hb-muted, #6B6270);
	--hbfa-line: var(--hb-line, #E7DED5);
	--hbfa-accent: var(--hb-accent, #A8475E);
	--hbfa-accent-dark: var(--hb-accent-dark, #8E3A4F);
	--hbfa-green: var(--hb-green, #4E7766);
	--hbfa-green-tint: var(--hb-green-tint, #E8F0EC);
	--hbfa-panel: var(--hb-panel, #F3EAE1);
	--hbfa-card: #fff;
	--hbfa-radius: 6px;
	--hbfa-ratio: 16/10;

	display: block;
	width: 100%;
	max-width: 1150px;
	margin: 0 auto;
	color: var(--hbfa-text);
	font-family: inherit;
	-webkit-font-smoothing: antialiased;
}

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

.hbfa .hbfa__head h2,
.hbfa .hbfa__head p,
.hbfa .hbfa__list,
.hbfa .hbfa__list li,
.hbfa .hbfa__text p,
.hbfa .hbfa__text h3 { margin: 0; padding: 0; }
.hbfa .hbfa__list { list-style: none; }
.hbfa .hbfa__list li::before { content: none; }

/* Kopf ---------------------------------------------------------------- */
.hbfa__head {
	display: flex;
	justify-content: space-between;
	align-items: flex-end;
	gap: 32px;
	padding-bottom: 18px;
	margin-bottom: 28px;
	border-bottom: 1px solid var(--hbfa-ink);
}
.hbfa__headtext { display: flex; flex-direction: column; gap: 10px; max-width: 700px; }

.hbfa__kicker {
	display: block;
	font-size: 13px;
	font-weight: 600;
	letter-spacing: .12em;
	line-height: 1.3;
	text-transform: uppercase;
	color: var(--hbfa-accent);
}
.hbfa .hbfa__title {
	font-family: 'Fraunces', Georgia, serif;
	font-weight: 400;
	font-size: clamp(26px, 2.6vw, 34px);
	line-height: 1.12;
	letter-spacing: -.01em;
	color: var(--hbfa-ink);
}
.hbfa .hbfa__lead { font-size: 16px; line-height: 1.55; color: var(--hbfa-text); }

.hbfa .hbfa__all {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	min-height: 44px;
	font-size: 15px;
	font-weight: 500;
	white-space: nowrap;
	color: var(--hbfa-ink);
	text-decoration: none;
}
.hbfa .hbfa__all:hover { color: var(--hbfa-accent); }

/* Raster -------------------------------------------------------------- */
.hbfa .hbfa__list {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr));
	gap: 24px;
}

.hbfa__card {
	display: flex;
	flex-direction: column;
	height: 100%;
	overflow: hidden;
	background: var(--hbfa-card);
	border: 1px solid var(--hbfa-line);
	border-radius: var(--hbfa-radius);
	transition: border-color .15s ease, transform .15s ease;
}
.hbfa__card:hover { border-color: var(--hbfa-accent); transform: translateY(-2px); }

/* Bild ---------------------------------------------------------------- */
.hbfa__media {
	display: flex;
	align-items: center;
	justify-content: center;
	aspect-ratio: var(--hbfa-ratio);
	background: var(--hbfa-panel);
	color: #C9B8AC;
	overflow: hidden;
}
.hbfa .hbfa__img {
	display: block;
	width: 100%;
	height: 100%;
	max-width: none;
	object-fit: cover;
	margin: 0;
	border-radius: 0;
}
.hbfa__ph { width: 44px; height: 44px; }

/* Körper -------------------------------------------------------------- */
.hbfa__body {
	display: flex;
	gap: 18px;
	flex: 1 1 auto;
	padding: 20px 22px 22px;
}

.hbfa__stamp {
	flex: 0 0 auto;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: flex-start;
	min-width: 64px;
	padding-right: 18px;
	border-right: 1px solid var(--hbfa-line);
	text-align: center;
}
.hbfa__days {
	font-family: 'Fraunces', Georgia, serif;
	font-size: 26px;
	line-height: 1.05;
	letter-spacing: -.01em;
	color: var(--hbfa-ink);
	white-space: nowrap;
}
.hbfa__month {
	margin-top: 6px;
	font-size: 12px;
	font-weight: 600;
	letter-spacing: .12em;
	text-transform: uppercase;
	color: var(--hbfa-accent);
	white-space: nowrap;
}

.hbfa__text { display: flex; flex-direction: column; gap: 6px; min-width: 0; flex: 1 1 auto; }

.hbfa__tag {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px;
	font-size: 12px;
	font-weight: 600;
	letter-spacing: .12em;
	text-transform: uppercase;
	color: var(--hbfa-muted);
}
.hbfa__now {
	padding: 2px 8px;
	border-radius: 999px;
	background: var(--hbfa-green-tint);
	color: var(--hbfa-green);
	letter-spacing: .04em;
	text-transform: none;
	font-size: 12px;
}

.hbfa .hbfa__city {
	font-family: 'Fraunces', Georgia, serif;
	font-weight: 400;
	font-size: clamp(20px, 1.8vw, 23px);
	line-height: 1.2;
	letter-spacing: -.01em;
	color: var(--hbfa-ink);
	overflow-wrap: anywhere;
}
.hbfa .hbfa__date { font-size: 15px; line-height: 1.45; color: var(--hbfa-text); }
.hbfa .hbfa__partner { font-size: 14px; color: var(--hbfa-muted); }

.hbfa__actions {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 10px 18px;
	margin-top: auto;
	padding-top: 14px;
}

.hbfa .hbfa__btn,
.hbfa .hbfa__btn:visited {
	display: inline-flex;
	align-items: center;
	min-height: 44px;
	padding: 10px 20px;
	border: 1px solid var(--hbfa-accent);
	border-radius: 999px;
	background: var(--hbfa-accent);
	color: #fff;
	font-size: 15px;
	font-weight: 500;
	line-height: 1.2;
	text-decoration: none;
	box-shadow: none;
	transition: background-color .15s ease, border-color .15s ease;
}
.hbfa .hbfa__btn:hover {
	background: var(--hbfa-accent-dark);
	border-color: var(--hbfa-accent-dark);
	color: #fff;
}

.hbfa .hbfa__link,
.hbfa .hbfa__link:visited {
	display: inline-flex;
	align-items: center;
	min-height: 44px;
	font-size: 15px;
	font-weight: 500;
	color: var(--hbfa-ink);
	text-decoration: underline;
	text-decoration-color: var(--hbfa-line);
	text-underline-offset: 4px;
}
.hbfa .hbfa__link:hover { color: var(--hbfa-accent); text-decoration-color: var(--hbfa-accent); }

.hbfa a:focus-visible {
	outline: 2px solid var(--hbfa-accent);
	outline-offset: 3px;
}

.hbfa__sr {
	position: absolute;
	width: 1px;
	height: 1px;
	margin: -1px;
	padding: 0;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

/* Schmale Bildschirme --------------------------------------------------- */
@media (max-width: 640px) {
	.hbfa__head { flex-direction: column; align-items: flex-start; gap: 14px; margin-bottom: 22px; }
	.hbfa .hbfa__list { gap: 18px; }
	.hbfa__body { padding: 18px 18px 20px; gap: 14px; }
	.hbfa__stamp { min-width: 56px; padding-right: 14px; }
	.hbfa__days { font-size: 22px; }
}

/* Aufmacher und Terminliste (ab Version 1.1.0) ---------------------------- */
.hbfa .hbfa__rows,
.hbfa .hbfa__rows li,
.hbfa .hbfa__introtext p,
.hbfa .hbfa__monthhead,
.hbfa .hbfa__rowtext p,
.hbfa .hbfa__rowtext h3,
.hbfa .hbfa__rowtext h4 { margin: 0; padding: 0; }
.hbfa .hbfa__rows { list-style: none; display: flex; flex-direction: column; gap: 14px; }
.hbfa .hbfa__rows li::before { content: none; }

.hbfa--feature {
	display: grid;
	grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
	gap: 32px;
	align-items: stretch;
}

.hbfa__intro {
	display: flex;
	flex-direction: column;
	overflow: hidden;
	background: var(--hbfa-panel);
	border-radius: 8px;
}
.hbfa__photo {
	display: flex;
	align-items: center;
	justify-content: center;
	aspect-ratio: 4 / 3;
	background: var(--hbfa-green-tint);
	color: #9DB5A9;
	overflow: hidden;
}
.hbfa .hbfa__photo .hbfa__img { width: 100%; height: 100%; object-fit: cover; }
.hbfa__introtext {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 12px;
	flex: 1 1 auto;
	padding: 26px 28px 30px;
}
.hbfa .hbfa__note { font-size: 15px; line-height: 1.55; color: var(--hbfa-muted); }
.hbfa__introtext .hbfa__btn { margin-top: auto; }

.hbfa .hbfa__btn--ghost,
.hbfa .hbfa__btn--ghost:visited {
	background: transparent;
	color: var(--hbfa-ink);
	border-color: var(--hbfa-ink);
	gap: 8px;
}
.hbfa .hbfa__btn--ghost:hover { background: var(--hbfa-ink); border-color: var(--hbfa-ink); color: #fff; }

.hbfa .hbfa__rows .hbfa__row {
	flex: 1 1 0;
	display: grid;
	grid-template-columns: 96px minmax(0, 1fr) auto;
	align-items: center;
	gap: 22px;
	padding: 18px 22px 18px 18px;
	background: var(--hbfa-card);
	border: 1px solid var(--hbfa-line);
	border-radius: 8px;
	transition: border-color .15s ease;
}
.hbfa .hbfa__rows .hbfa__row:hover { border-color: var(--hbfa-accent); }

.hbfa__stamp--tile {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	min-width: 0;
	min-height: 84px;
	padding: 10px 6px;
	border: 0;
	border-radius: 6px;
	background: var(--hb-rose-tint, #F6E8EB);
}
.hbfa__stamp--tile .hbfa__days { font-size: 22px; }
.hbfa__rowtext { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.hbfa__rowtext .hbfa__city { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; }
.hbfa__rowactions { display: flex; flex-direction: column; align-items: flex-end; gap: 0; }

.hbfa .hbfa__rows .hbfa__row--img { grid-template-columns: 96px 88px minmax(0, 1fr) auto; }
.hbfa__thumb--row { flex: 0 0 88px; width: 88px; height: 88px; }
@media (max-width: 640px) {
	.hbfa .hbfa__rows .hbfa__row--img { grid-template-columns: 76px 64px minmax(0, 1fr); }
	.hbfa__thumb--row { flex: 0 0 64px; width: 64px; height: 64px; }
}

/* Terminliste nach Monaten */
.hbfa--rows .hbfa__month-group + .hbfa__month-group { margin-top: 36px; }
.hbfa .hbfa__monthhead {
	margin-bottom: 14px;
	padding-bottom: 10px;
	border-bottom: 1px solid var(--hbfa-ink);
	font-family: 'Fraunces', Georgia, serif;
	font-weight: 400;
	font-size: clamp(20px, 2vw, 26px);
	line-height: 1.2;
	color: var(--hbfa-ink);
}
.hbfa .hbfa__empty {
	margin: 0;
	padding: 28px;
	background: var(--hbfa-panel);
	border-radius: 8px;
	font-size: 16px;
	line-height: 1.55;
}

@media (max-width: 900px) {
	.hbfa--feature { grid-template-columns: 1fr; gap: 24px; }
	.hbfa__photo { aspect-ratio: 16 / 9; }
}
@media (max-width: 640px) {
	.hbfa .hbfa__rows .hbfa__row { flex: 0 0 auto; grid-template-columns: 76px minmax(0, 1fr); gap: 14px; padding: 14px; }
	.hbfa__rowactions { grid-column: 1 / -1; flex-direction: row; flex-wrap: wrap; align-items: center; gap: 6px 18px; }
	.hbfa__stamp--tile { min-height: 72px; }
	.hbfa__introtext { padding: 20px 20px 24px; }
}

/* Kompakte Leiste (ab Version 1.2.0) ------------------------------------- */
.hbfa__bar {
	display: flex;
	justify-content: space-between;
	align-items: baseline;
	gap: 16px 28px;
	flex-wrap: wrap;
	padding-bottom: 12px;
	margin-bottom: 16px;
	border-bottom: 1px solid var(--hbfa-ink);
}
.hbfa__bartext { display: flex; align-items: baseline; flex-wrap: wrap; gap: 6px 14px; }
.hbfa--compact .hbfa__title { font-size: clamp(22px, 2.2vw, 28px); }
.hbfa .hbfa__lead--bar { margin: -4px 0 18px; max-width: 700px; font-size: 15px; }

.hbfa .hbfa__strip {
	list-style: none;
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 14px;
	margin: 0;
	padding: 0;
}
.hbfa .hbfa__strip li { margin: 0; padding: 0; }
.hbfa .hbfa__strip li::before { content: none; }

.hbfa .hbfa__tile {
	display: flex;
	align-items: center;
	gap: 14px;
	height: 100%;
	padding: 10px 16px 10px 10px;
	background: var(--hbfa-card);
	border: 1px solid var(--hbfa-line);
	border-radius: 8px;
	color: inherit;
	text-decoration: none;
	transition: border-color .15s ease;
}
.hbfa .hbfa__tile:hover { border-color: var(--hbfa-accent); }

.hbfa__thumb {
	flex: 0 0 88px;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 88px;
	height: 88px;
	overflow: hidden;
	background: var(--hbfa-panel);
	border-radius: 6px;
	color: #C9B8AC;
}
.hbfa .hbfa__thumb .hbfa__img { width: 100%; height: 100%; object-fit: cover; border-radius: 0; }
.hbfa__ph--sm { width: 28px; height: 28px; }

.hbfa__tiletext { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.hbfa__tiledate {
	font-size: 12px;
	font-weight: 600;
	letter-spacing: .1em;
	line-height: 1.3;
	text-transform: uppercase;
	color: var(--hbfa-accent);
}
.hbfa__tilecity {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 4px 8px;
	font-family: 'Fraunces', Georgia, serif;
	font-size: 20px;
	line-height: 1.2;
	letter-spacing: -.01em;
	color: var(--hbfa-ink);
	overflow-wrap: anywhere;
}
.hbfa__tilelink {
	margin-top: 2px;
	font-size: 14px;
	line-height: 1.3;
	color: var(--hbfa-text);
	text-decoration: underline;
	text-decoration-color: var(--hbfa-line);
	text-underline-offset: 3px;
}
.hbfa .hbfa__tile:hover .hbfa__tilelink { color: var(--hbfa-accent); text-decoration-color: var(--hbfa-accent); }

@media (max-width: 900px) {
	.hbfa .hbfa__strip { grid-template-columns: 1fr; }
	.hbfa .hbfa__tile { padding: 10px 14px 10px 10px; }
}

@media (prefers-reduced-motion: reduce) {
	.hbfa__card, .hbfa__row, .hbfa .hbfa__tile, .hbfa .hbfa__btn { transition: none; }
	.hbfa__card:hover { transform: none; }
}
