/* ==========================================================================
   Aromababy – Messen: front-end styles (banner, album cards, lightbox)
   Colors/sizes come from the theme tokens (--ab-*); fallbacks are defined here.
   ========================================================================== */

/* --- Config: edit colors/sizes here --- */
.abm-banner,
.abm-albums,
.abm-lb {
	--abm-green:   var(--ab-green, #3F5245);
	--abm-accent:  var(--ab-accent, #C2410C);
	--abm-accent-hover: var(--ab-accent-hover, #A5370A);
	--abm-ink:     var(--ab-ink, #2E3A30);
	--abm-muted:   var(--ab-muted, #5A6459);
	--abm-paper:   var(--ab-paper, #FBF9F6);
	--abm-sand:    var(--ab-sand, #F1ECE0);
	--abm-peach:   var(--ab-peach, #FBE6D6);
	--abm-line:    var(--ab-line, #D9D1C4);
	--abm-radius:  28px;      /* corner radius of banner and cards */
	--abm-cols-min: 280px;    /* minimum width of one album card */
	--abm-gap:     28px;      /* gap between album cards */
}

.abm-sr-only {
	position: absolute !important;
	width: 1px; height: 1px;
	overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap;
}

.abm-eyebrow {
	display: block;
	font-size: 14px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase;
}

/* --- Thin bar above/below the menu --- */
.abm-bar {
	/* Config: colors and size of the bar */
	--abm-bar-bg:   var(--ab-green, #3F5245);
	--abm-bar-fg:   #FFFFFF;
	--abm-bar-hi:   var(--ab-peach, #FBE6D6);
	--abm-bar-size: 14px;
	background: var(--abm-bar-bg); color: var(--abm-bar-fg);
	font-size: var(--abm-bar-size); line-height: 1.4; text-align: center;
	padding: 8px var(--ab-gutter, 24px);
}
.abm-bar[hidden] { display: none; }
.abm-bar__inner { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 2px 10px; max-width: var(--ab-max, 1240px); margin: 0 auto; }
.abm-bar__label { color: var(--abm-bar-hi); font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase; font-size: 0.85em; }
.abm-bar__sep { opacity: 0.6; }
body .abm-bar a.abm-bar__link { color: var(--abm-bar-fg); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }
body .abm-bar a.abm-bar__link:hover, body .abm-bar a.abm-bar__link:focus-visible { color: var(--abm-bar-hi); }
@media (max-width: 767px) {
	.abm-bar { font-size: 13px; padding: 7px 16px; }
}

/* --- Banner --- */
.abm-banner { width: 100%; }
.abm-banner__box {
	position: relative; overflow: hidden;
	display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr);
	gap: 40px; align-items: center;
	padding: 56px 56px;
	border-radius: var(--abm-radius);
	background: var(--abm-green); color: #FFFFFF;
}
/* soft decorative circle */
.abm-banner__box::before {
	content: ""; position: absolute; right: -90px; top: -110px;
	width: 340px; height: 340px; border-radius: 50%;
	background: var(--abm-accent); opacity: 0.35; pointer-events: none;
}
.abm-banner__main, .abm-banner__date { position: relative; z-index: 1; }
.abm-banner .abm-eyebrow { color: var(--abm-peach); margin-bottom: 14px; }
body .abm-banner h2.abm-banner__name {
	margin: 0 0 24px; padding: 0;
	font-size: 44px; line-height: 1.12; font-weight: 600; letter-spacing: -0.02em;
	color: #FFFFFF;
}
.abm-banner__meta { list-style: none; margin: 0 0 24px; padding: 0; display: grid; gap: 14px; }
.abm-banner__meta li {
	display: flex; gap: 14px; align-items: flex-start;
	margin: 0; padding: 0; font-size: 18px; line-height: 1.5;
}
.abm-banner__meta .abm-icon { flex: 0 0 22px; margin-top: 3px; color: var(--abm-peach); }
.abm-banner__note { margin: 0 0 24px; font-size: 17px; color: rgba(255, 255, 255, 0.85); }
body .abm-btn {
	display: inline-flex; align-items: center; text-decoration: none;
	padding: 16px 28px; border-radius: 999px;
	background: var(--abm-accent); color: #FFFFFF; font-weight: 600;
	transition: background-color .2s ease;
}
body .abm-btn:hover, body .abm-btn:focus-visible { background: var(--abm-accent-hover); color: #FFFFFF; }

/* date tile on the right */
.abm-banner__date {
	justify-self: center; text-align: center;
	display: flex; flex-direction: column; gap: 4px; align-items: center;
	padding: 28px 32px; min-width: 220px; max-width: 100%;
	border-radius: 24px; background: var(--abm-paper); color: var(--abm-ink);
	box-shadow: 0 18px 40px rgba(0, 0, 0, 0.18);
}
.abm-date__top { font-size: 15px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--abm-accent); }
.abm-date__big { font-size: 56px; line-height: 1.05; font-weight: 300; letter-spacing: -0.03em; overflow-wrap: anywhere; }
.abm-date__bottom { font-size: 18px; font-weight: 600; color: var(--abm-green); }

/* empty state (no fair planned / fair is over) */
.abm-banner__empty { display: none; padding: 48px 56px; border-radius: var(--abm-radius); background: var(--abm-sand); }
.abm-banner__empty .abm-eyebrow { color: var(--abm-accent); margin-bottom: 10px; }
.abm-banner__empty p { margin: 0; font-size: 20px; max-width: 640px; }
.abm-banner.is-expired .abm-banner__box { display: none; }
.abm-banner.is-expired .abm-banner__empty { display: block; }

/* --- Album cards --- */
.abm-albums {
	display: grid; gap: var(--abm-gap);
	grid-template-columns: repeat(auto-fill, minmax(min(100%, var(--abm-cols-min)), 1fr));
}
body .abm-card {
	display: flex; flex-direction: column; width: 100%; padding: 0; margin: 0;
	text-align: left; cursor: pointer; font: inherit; color: var(--abm-ink);
	background: var(--abm-paper); border: 1px solid var(--abm-line); border-radius: 22px;
	overflow: hidden; transition: transform .2s ease, box-shadow .2s ease;
}
body .abm-card:hover, body .abm-card:focus-visible { transform: translateY(-4px); box-shadow: 0 16px 34px rgba(46, 58, 48, 0.14); }
.abm-card:focus-visible { outline: 3px solid var(--abm-accent); outline-offset: 3px; }
.abm-card__media { position: relative; display: block; aspect-ratio: 4 / 3; background: var(--abm-sand); overflow: hidden; }
.abm-card__img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.abm-card:hover .abm-card__img { transform: scale(1.05); }
.abm-card__count {
	position: absolute; left: 14px; bottom: 14px; padding: 6px 14px; border-radius: 999px;
	background: rgba(255, 255, 255, 0.92); color: var(--abm-ink); font-size: 14px; font-weight: 600;
}
.abm-card__body { display: flex; flex-direction: column; gap: 4px; padding: 20px 22px 24px; }
.abm-card__title { font-size: 21px; line-height: 1.3; font-weight: 600; letter-spacing: -0.01em; }
.abm-card__date { font-size: 16px; color: var(--abm-muted); }
.abm-empty { color: var(--abm-muted); font-size: 18px; }

/* --- Lightbox --- */
html.abm-lock { overflow: hidden; }
.abm-lb {
	position: fixed; inset: 0; z-index: 100000;
	display: flex; flex-direction: column;
	background: rgba(24, 30, 26, 0.96); color: #FFFFFF;
}
.abm-lb[hidden] { display: none; }
.abm-lb__head { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 16px 24px; }
.abm-lb__title { margin: 0; font-size: 20px; font-weight: 600; line-height: 1.3; }
.abm-lb__date { display: block; font-size: 15px; font-weight: 400; opacity: 0.75; }
.abm-lb__btn {
	display: inline-flex; align-items: center; justify-content: center;
	width: 48px; height: 48px; padding: 0; flex: 0 0 48px;
	border: 0; border-radius: 50%; cursor: pointer;
	background: rgba(255, 255, 255, 0.14); color: #FFFFFF; font-size: 26px; line-height: 1;
	transition: background-color .2s ease;
}
.abm-lb__btn:hover, .abm-lb__btn:focus-visible { background: rgba(255, 255, 255, 0.3); }
.abm-lb__btn:focus-visible { outline: 3px solid #FFFFFF; outline-offset: 2px; }
.abm-lb__stage { position: relative; flex: 1 1 auto; min-height: 0; display: flex; align-items: center; justify-content: center; gap: 12px; padding: 0 16px; }
.abm-lb__fig { flex: 1 1 auto; min-width: 0; height: 100%; margin: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; }
.abm-lb__img { max-width: 100%; max-height: calc(100% - 40px); object-fit: contain; border-radius: 10px; background: #1B221D; }
.abm-lb__cap { min-height: 24px; font-size: 15px; opacity: 0.85; text-align: center; }
.abm-lb__foot { padding: 12px 16px 18px; }
.abm-lb__count { text-align: center; font-size: 14px; opacity: 0.75; margin-bottom: 10px; }
.abm-lb__strip { display: flex; gap: 8px; overflow-x: auto; padding: 4px; justify-content: safe center; scrollbar-width: thin; }
.abm-lb__thumb {
	flex: 0 0 auto; width: 72px; height: 72px; padding: 0; border: 2px solid transparent; border-radius: 10px;
	overflow: hidden; cursor: pointer; background: #1B221D; opacity: 0.6; transition: opacity .2s ease, border-color .2s ease;
}
.abm-lb__thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.abm-lb__thumb:hover, .abm-lb__thumb:focus-visible { opacity: 1; }
.abm-lb__thumb[aria-current="true"] { opacity: 1; border-color: #FFFFFF; }

/* --- Page layout (Divi sections of the page "Messen"): tighter spacing than the 96px default --- */
.abm-sec-banner .ab-row { padding-top: 56px; padding-bottom: 24px; }
.abm-sec-albums .ab-row { padding-top: 48px; padding-bottom: 96px; gap: 32px; }
.abm-sec-albums .ab-lead { margin: 12px 0 0; }

/* --- Responsive --- */
@media (max-width: 980px) {
	.abm-banner__box { grid-template-columns: 1fr; padding: 40px 32px; gap: 28px; }
	.abm-banner__date { justify-self: start; }
	body .abm-banner h2.abm-banner__name { font-size: 36px; }
}
@media (max-width: 767px) {
	.abm-banner__box { padding: 32px 24px; }
	.abm-banner__empty { padding: 32px 24px; }
	body .abm-banner h2.abm-banner__name { font-size: 30px; }
	.abm-banner__meta li { font-size: 17px; }
	.abm-date__big { font-size: 44px; }
	.abm-banner__date { width: 100%; min-width: 0; }
	.abm-lb__stage { padding: 0 8px; gap: 4px; }
	.abm-lb__btn { width: 42px; height: 42px; flex-basis: 42px; }
	.abm-lb__thumb { width: 56px; height: 56px; }
}
@media (prefers-reduced-motion: reduce) {
	.abm-card, .abm-card__img, .abm-lb__btn, .abm-lb__thumb, .abm-btn { transition: none; }
	.abm-card:hover, .abm-card:hover .abm-card__img { transform: none; }
}
