/*
Theme Name: FVM
Theme URI: https://fischervereinmeilen.ch
Author: Fischerverein Meilen
Author URI: https://fischervereinmeilen.ch
Description: Eigenes, schlankes WordPress-Theme für den Fischerverein Meilen (FVM). Design und Struktur orientieren sich an der Design-Referenz fvm.didico.ch. Version 0.1 enthält die gemeinsame Grundstruktur (Header, Navigation, Footer) sowie die Startseitenvorlage. Keine Divi-/Elementor-Abhängigkeit, keine Bootsverwaltung (folgt als eigenständiges Plugin).
Version: 0.6.1
Requires at least: 6.4
Tested up to: 6.7
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: fvm
*/

/* =========================================================
   0. Lokal eingebundene Schriften (Poppins/Inter)
      Behobener Fehler aus dem v0.1-Review: zuvor extern von
      Google geladen (fonts.googleapis.com) – jetzt als eigene
      Dateien im Theme-Ordner "fonts/" selbst gehostet (DSGVO,
      kein externer Request, kein Google-Fonts-CDN).
      Alle benötigten Schnitte (Inter 400/500/700, Poppins
      700/800) liegen als Dateien im Ordner fonts/ vor.
   ========================================================= */
@font-face {
	font-family: "Inter";
	font-style: normal;
	font-weight: 400;
	font-display: swap;
	src: url("fonts/inter-v20-latin-400.woff2") format("woff2");
}
@font-face {
	font-family: "Inter";
	font-style: normal;
	font-weight: 500;
	font-display: swap;
	src: url("fonts/inter-v20-latin-500.woff2") format("woff2");
}
@font-face {
	font-family: "Inter";
	font-style: normal;
	font-weight: 700;
	font-display: swap;
	src: url("fonts/inter-v20-latin-700.woff2") format("woff2");
}
@font-face {
	font-family: "Poppins";
	font-style: normal;
	font-weight: 700;
	font-display: swap;
	src: url("fonts/poppins-v24-latin-700.woff2") format("woff2");
}
@font-face {
	font-family: "Poppins";
	font-style: normal;
	font-weight: 800;
	font-display: swap;
	src: url("fonts/poppins-v24-latin-800.woff2") format("woff2");
}

/* =========================================================
   1. Design-Tokens (aus fvm.didico.ch ermittelt, Punkt 2 der
      Bestandsaufnahme: Farben, Schriften, Formen)
   ========================================================= */
:root {
	--fvm-dark: #0d2129;
	--fvm-teal: #1a5878;
	--fvm-yellow: #f7c600;
	--fvm-bg-alt: #f2f3f4;
	--fvm-white: #ffffff;
	--fvm-text: #5f6368;
	--fvm-text-strong: #202124;
	--fvm-border: #e5e7e9;
	--fvm-radius-card: 14px;
	--fvm-radius-pill: 999px;
	--fvm-font-heading: "Poppins", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
	--fvm-font-body: "Inter", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
	--fvm-container: 1200px;
	--fvm-gap: 24px;
}

/* =========================================================
   2. Reset / Basis
   ========================================================= */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
	margin: 0;
	font-family: var(--fvm-font-body);
	font-size: 16px;
	line-height: 1.6;
	color: var(--fvm-text);
	background: var(--fvm-white);
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--fvm-teal); text-decoration: none; }
a:hover { text-decoration: underline; }
ul { margin: 0; padding: 0; list-style: none; }
h1, h2, h3, h4 {
	font-family: var(--fvm-font-heading);
	font-weight: 800;
	color: var(--fvm-dark);
	margin: 0 0 18px;
	line-height: 1.15;
}
h1 { font-size: 44px; }
h2 { font-size: 30px; }
h3 { font-size: 17px; }
p { margin: 0 0 1em; }
.fvm-container {
	max-width: var(--fvm-container);
	margin: 0 auto;
	padding: 0 24px;
}
.screen-reader-text {
	position: absolute !important;
	clip: rect(1px, 1px, 1px, 1px);
	width: 1px; height: 1px; overflow: hidden;
}
.fvm-btn {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	font-family: var(--fvm-font-body);
	font-weight: 700;
	font-size: 14.5px;
	padding: 14px 28px;
	border-radius: var(--fvm-radius-pill);
	border: none;
	cursor: pointer;
	text-decoration: none !important;
}
.fvm-btn--primary { background: var(--fvm-yellow); color: var(--fvm-dark); }
.fvm-btn--primary:hover { background: #e0b400; }
.fvm-btn--secondary { background: var(--fvm-dark); color: var(--fvm-white); }
.fvm-btn--secondary:hover { background: #122d38; }

/* =========================================================
   3. Header & Navigation
   ========================================================= */
.fvm-header {
	position: absolute;
	top: 0; left: 0; right: 0;
	z-index: 20;
	padding: 20px 0;
}
.fvm-header.fvm-header--solid {
	position: relative;
	background: var(--fvm-white);
	border-bottom: 1px solid var(--fvm-border);
}
.fvm-header__inner {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 24px;
}
.fvm-logo {
	display: flex;
	align-items: center;
	gap: 14px;
	color: inherit;
}
.fvm-logo:hover { text-decoration: none; }
.fvm-logo img { max-height: 56px; width: auto; }
.fvm-logo__text {
	font-family: var(--fvm-font-heading);
	font-weight: 700;
	font-size: 20px;
	color: #fff;
}
.fvm-header--solid .fvm-logo__text,
.fvm-header--solid .fvm-nav a { color: var(--fvm-text-strong); }
.fvm-header:not(.fvm-header--solid) .fvm-nav a { color: #fff; }

.fvm-nav { display: flex; }
.fvm-nav ul { display: flex; align-items: center; gap: 30px; }
/* Schmalere Desktop-Breiten (zwischen dem Hamburger-Breakpoint bei 900px
   und ~1024px): etwas kompaktere Navigation, damit alle Menüpunkte ohne
   Umbruch/horizontales Scrollen in einer Zeile Platz finden – ohne die
   grössere Desktop-Darstellung (ab 1024px) zu verändern. */
@media (min-width: 901px) and (max-width: 1024px) {
	.fvm-header__inner { gap: 16px; }
	.fvm-nav ul { gap: 16px; }
	.fvm-nav a { font-size: 14px; }
	.fvm-logo__text { font-size: 17px; }
}
.fvm-nav a {
	font-weight: 500;
	font-size: 16px;
	position: relative;
	white-space: nowrap;
}
.fvm-nav a:hover { text-decoration: none; opacity: 0.8; }
.fvm-nav li.menu-item-has-children > a::after {
	content: "";
	display: inline-block;
	width: 6px; height: 6px;
	border-right: 2px solid currentColor;
	border-bottom: 2px solid currentColor;
	transform: rotate(45deg);
	margin-left: 6px;
}
.fvm-nav .sub-menu {
	display: none;
	position: absolute;
	top: 100%; left: 0;
	background: var(--fvm-white);
	box-shadow: 0 12px 24px rgba(13, 33, 41, 0.12);
	border-radius: 10px;
	padding: 10px;
	min-width: 220px;
	z-index: 30;
}
.fvm-nav li { position: relative; }
.fvm-nav li:hover > .sub-menu,
.fvm-nav li:focus-within > .sub-menu { display: block; }
.fvm-nav .sub-menu a { color: var(--fvm-text-strong) !important; padding: 8px 12px; display: block; border-radius: 6px; }
.fvm-nav .sub-menu a:hover { background: var(--fvm-bg-alt); }

/* Separater Untermenü-Umschalt-Button (siehe inc/class-nav-walker.php).
   Auf Desktop-Breiten bleibt das Untermenü via Hover/Focus-Within am Link
   gesteuert (siehe oben); der Button ist dort unnötig und daher weder
   sichtbar noch per Tab erreichbar. Sichtbar wird er erst im
   Hamburger-Breakpoint weiter unten. */
.fvm-submenu-toggle {
	display: none;
	background: none;
	border: none;
	cursor: pointer;
	color: inherit;
	padding: 6px;
	line-height: 0;
}
.fvm-submenu-toggle__arrow {
	display: inline-block;
	width: 8px; height: 8px;
	border-right: 2px solid currentColor;
	border-bottom: 2px solid currentColor;
	transform: rotate(45deg);
	transition: transform .15s ease;
}
.fvm-submenu-toggle[aria-expanded="true"] .fvm-submenu-toggle__arrow {
	transform: rotate(-135deg);
}

.fvm-nav-toggle {
	display: none;
	background: none;
	border: none;
	cursor: pointer;
	width: 40px; height: 40px;
	position: relative;
}
.fvm-nav-toggle span, .fvm-nav-toggle::before, .fvm-nav-toggle::after {
	content: "";
	position: absolute;
	left: 8px; right: 8px;
	height: 2px;
	background: currentColor;
	color: inherit;
}
.fvm-nav-toggle span { top: 19px; }
.fvm-nav-toggle::before { top: 12px; }
.fvm-nav-toggle::after { top: 26px; }
.fvm-header:not(.fvm-header--solid) .fvm-nav-toggle { color: #fff; }
.fvm-header--solid .fvm-nav-toggle { color: var(--fvm-text-strong); }

/* =========================================================
   4. Hero (Startseite)
   ========================================================= */
.fvm-hero {
	position: relative;
	min-height: 640px;
	display: flex;
	align-items: flex-end;
	background-color: var(--fvm-dark);
	background-size: cover;
	background-position: center;
	color: #fff;
	overflow: hidden;
}
.fvm-hero::before {
	content: "";
	position: absolute; inset: 0;
	background: linear-gradient(0deg, rgba(13,33,41,0.55) 0%, rgba(13,33,41,0.05) 55%, rgba(13,33,41,0.35) 100%);
}
.fvm-hero__inner {
	position: relative;
	width: 100%;
	padding: 140px 0 70px;
	display: flex;
	align-items: flex-end;
	justify-content: space-between;
	gap: 24px;
	flex-wrap: wrap;
}
.fvm-hero__heading {
	color: #fff;
	font-size: 44px;
	max-width: 620px;
	margin: 0;
}
.fvm-hero__bar {
	height: 6px;
	background: linear-gradient(135deg, var(--fvm-dark) 0%, var(--fvm-teal) 100%);
}

/* =========================================================
   5. News-Sektion (Karten-Grid)
      Wird sowohl von der Startseiten-News-Sektion als auch vom
      allgemeinen Archiv-/Blog-Template (index.php) verwendet.
   ========================================================= */
.fvm-section { padding: 70px 0; }
.fvm-section--alt { background: var(--fvm-bg-alt); }
.fvm-kicker {
	display: block;
	font-size: 13px;
	font-weight: 700;
	letter-spacing: 0.08em;
	color: var(--fvm-teal);
	text-transform: uppercase;
	margin-bottom: 10px;
}
.fvm-card-grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: var(--fvm-gap);
	margin-top: 36px;
}
.fvm-card {
	background: var(--fvm-white);
	border-radius: var(--fvm-radius-card);
	overflow: hidden;
	box-shadow: 0 6px 18px rgba(13, 33, 41, 0.06);
	display: flex;
	flex-direction: column;
}
.fvm-card__bar { height: 5px; background: var(--fvm-card-accent, var(--fvm-teal)); }
.fvm-card__img { aspect-ratio: 16 / 10; overflow: hidden; background: var(--fvm-bg-alt); }
.fvm-card__img img { width: 100%; height: 100%; object-fit: cover; }
.fvm-card__body { padding: 20px 22px 26px; }
.fvm-card__meta {
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.05em;
	text-transform: uppercase;
	color: var(--fvm-card-accent, var(--fvm-teal));
	margin-bottom: 8px;
}
.fvm-card__title { font-size: 19px; margin-bottom: 10px; }
.fvm-card__title a { color: var(--fvm-dark); }
.fvm-card__excerpt { font-size: 14px; color: var(--fvm-text); margin-bottom: 14px; }
.fvm-card__more { font-weight: 700; color: var(--fvm-dark); font-size: 14px; }
.fvm-card__more::after { content: " →"; }
.fvm-section__footer { text-align: center; margin-top: 40px; }

/* =========================================================
   5b. Agenda-Karussell
      Eigenständiger Bereich (siehe front-page.php, Punkt 2):
      zeigt echte, kommende Veranstaltungen statt Blog-Beiträgen.
      Bewusst ohne Animations-/Slide-Bibliothek: Wechsel per
      Anzeigen/Verbergen einer Folie (siehe js/agenda-carousel.js),
      das reicht für "automatisch rotierend" und hält das Theme frei
      von zusätzlichem JavaScript-Gewicht.
   ========================================================= */
.fvm-agenda__carousel { margin-top: 36px; }
.fvm-agenda__track { position: relative; }
.fvm-agenda__slide {
	display: none;
	grid-template-columns: minmax(0, 420px) 1fr;
	gap: 32px;
	align-items: center;
	background: var(--fvm-white);
	border-radius: var(--fvm-radius-card);
	overflow: hidden;
	box-shadow: 0 6px 18px rgba(13, 33, 41, 0.06);
}
.fvm-agenda__slide.is-active { display: grid; }
.fvm-agenda__img { aspect-ratio: 16 / 10; overflow: hidden; background: var(--fvm-bg-alt); }
.fvm-agenda__img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.fvm-agenda__body { padding: 28px 30px 28px 0; }
.fvm-agenda__slide:not(:has(.fvm-agenda__img)) .fvm-agenda__body { padding-left: 30px; }
.fvm-agenda__date {
	display: block;
	font-size: 13px;
	font-weight: 700;
	letter-spacing: 0.05em;
	text-transform: uppercase;
	color: var(--fvm-teal);
	margin-bottom: 10px;
}
.fvm-agenda__title { font-size: 24px; margin-bottom: 8px; }
.fvm-agenda__title a { color: var(--fvm-dark); }
.fvm-agenda__venue { font-size: 14px; font-weight: 600; color: var(--fvm-text-strong); margin-bottom: 8px; }
.fvm-agenda__excerpt { font-size: 14px; color: var(--fvm-text); }
.fvm-agenda__empty { color: var(--fvm-text); margin-top: 24px; }

.fvm-agenda__controls { display: flex; align-items: center; justify-content: center; gap: 18px; margin-top: 24px; }
.fvm-agenda__prev, .fvm-agenda__next {
	background: var(--fvm-white);
	border: 1px solid var(--fvm-border);
	border-radius: 50%;
	width: 40px; height: 40px;
	cursor: pointer;
	color: var(--fvm-text-strong);
	font-size: 16px;
	line-height: 1;
}
.fvm-agenda__prev:hover, .fvm-agenda__next:hover { background: var(--fvm-bg-alt); }
.fvm-agenda__dots { display: flex; gap: 8px; }
.fvm-agenda__dot {
	width: 10px; height: 10px;
	border-radius: 50%;
	border: none;
	background: var(--fvm-border);
	cursor: pointer;
	padding: 0;
}
.fvm-agenda__dot.is-active { background: var(--fvm-teal); }

/* =========================================================
   5c. Promo-Bereich (Vereinsboot / Jugendgruppe)
      Ergänzt den in v0.1 fehlenden Startseitenbereich (siehe
      v0.2-Review). Rein darstellend – keine Bootsverwaltungslogik.
   ========================================================= */
.fvm-promo__grid {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: var(--fvm-gap);
}
.fvm-promo__item {
	background: var(--fvm-white);
	border-radius: var(--fvm-radius-card);
	overflow: hidden;
	box-shadow: 0 6px 18px rgba(13, 33, 41, 0.06);
	display: flex;
	flex-direction: column;
}
.fvm-promo__img { aspect-ratio: 16 / 9; overflow: hidden; background: var(--fvm-bg-alt); }
.fvm-promo__img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.fvm-promo__body { padding: 24px 26px 28px; }
.fvm-promo__heading { font-size: 20px; margin-bottom: 10px; }
.fvm-promo__text { font-size: 14px; color: var(--fvm-text); margin-bottom: 18px; }

/* =========================================================
   6. Partner-Sektion
   ========================================================= */
.fvm-partners { display: flex; align-items: flex-start; gap: 60px; flex-wrap: wrap; }
.fvm-partners__intro { max-width: 280px; }
.fvm-partner-grid {
	flex: 1;
	min-width: 260px;
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 16px;
}
.fvm-partner-logo {
	background: var(--fvm-white);
	border: 1px solid var(--fvm-border);
	border-radius: 10px;
	min-height: 70px;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 10px;
}
.fvm-partner-logo img { max-height: 40px; width: auto; }
.fvm-partner-logo--placeholder { color: var(--fvm-text); font-size: 12px; text-align: center; }

/* =========================================================
   7. Footer
   ========================================================= */
.fvm-footer {
	background-image: linear-gradient(135deg, var(--fvm-dark) 0%, var(--fvm-teal) 100%);
	color: rgba(255, 255, 255, 0.75);
	padding: 56px 0 26px;
}
.fvm-footer a { color: rgba(255, 255, 255, 0.9); }
.fvm-footer__inner {
	display: grid;
	grid-template-columns: 1.3fr 1fr 1fr 1fr;
	gap: var(--fvm-gap);
}
.fvm-footer__brand img { max-height: 56px; margin-bottom: 14px; }
.fvm-footer__brand strong { color: #fff; display: block; margin-bottom: 10px; font-size: 16px; }
.fvm-footer__col-title {
	color: #fff;
	font-size: 13px;
	font-weight: 700;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	margin-bottom: 16px;
}
.fvm-footer__col li { margin-bottom: 10px; }
.fvm-footer__social { display: flex; gap: 10px; margin-top: 24px; grid-column: 1 / -1; justify-content: flex-end; }
.fvm-footer__social a {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	background: rgba(255,255,255,0.08);
	padding: 10px 16px;
	border-radius: var(--fvm-radius-pill);
	font-size: 14px;
}
.fvm-footer__bottom {
	margin-top: 40px;
	padding-top: 20px;
	border-top: 1px solid rgba(255,255,255,0.15);
	display: flex;
	justify-content: space-between;
	font-size: 13px;
	flex-wrap: wrap;
	gap: 10px;
}

/* =========================================================
   8. Einfache Seiten-/Beitragsvorlage (page.php, single.php)
      -- stellt sicher, dass bestehende Inhalte lesbar bleiben
   ========================================================= */
.fvm-page-header {
	background: var(--fvm-bg-alt);
	padding: 60px 0 40px;
}
.fvm-page-header h1 { margin: 0; }
.fvm-page-content { padding: 50px 0 80px; }
.fvm-page-content .fvm-container { max-width: 820px; }
.fvm-page-content img { border-radius: 10px; }
.fvm-post-meta { font-size: 13px; color: var(--fvm-text); margin-bottom: 20px; }

/* Hinweis-Box für Divi-Builder-Seiten (siehe inc/divi-compat.php) –
   bewusst neutral/informativ gehalten, nicht wie eine Fehlermeldung. */
.fvm-divi-notice {
	background: var(--fvm-bg-alt);
	border: 1px solid var(--fvm-border);
	border-radius: var(--fvm-radius-card);
	padding: 24px 26px;
	color: var(--fvm-text-strong);
}
.fvm-divi-notice p:last-child { margin-bottom: 0; }
.fvm-divi-notice__admin {
	margin-top: 14px;
	padding-top: 14px;
	border-top: 1px dashed var(--fvm-border);
	font-size: 13px;
	color: var(--fvm-text);
}
.fvm-divi-notice__admin a { color: var(--fvm-teal); font-weight: 700; }

/* =========================================================
   9. Responsive
   ========================================================= */
/* Breakpoint bei max-width: 900px – gilt sowohl für das Karten-/Footer-
   Layout als auch für die Navigation (ein Block, ein Wert, siehe unten).
   Nav-Teil: wechselt hier auf das Hamburger-Menü – dieser Wert entspricht
   exakt dem Breakpoint der Designreferenz fvm.didico.ch (dort per
   @media (max-width: 900px) auf .fvm-nav-toggle/.fvm-nav-links
   verifiziert, Stand v0.3-Review; zuvor fälschlich 720px, siehe
   v0.3-Vergleich: bei 768px zeigte die Referenz noch das mobile Menü,
   unser Theme bereits die Desktop-Navigation). Separat getestet bei
   375/390/768/900/1024/1440px. */
@media (max-width: 900px) {
	.fvm-card-grid { grid-template-columns: repeat(2, 1fr); }
	.fvm-footer__inner { grid-template-columns: 1fr 1fr; }
	.fvm-partner-grid { grid-template-columns: repeat(3, 1fr); }

	.fvm-nav { position: fixed; inset: 0 0 0 auto; width: min(320px, 85%); height: 100vh; background: var(--fvm-white); box-shadow: -10px 0 30px rgba(0,0,0,0.15); transform: translateX(100%); transition: transform .25s ease; padding: 90px 28px 28px; z-index: 40; overflow-y: auto; }
	.fvm-nav.is-open { transform: translateX(0); }
	.fvm-nav ul { flex-direction: column; align-items: flex-start; gap: 4px; width: 100%; }
	.fvm-nav li { width: 100%; }
	.fvm-nav a { color: var(--fvm-text-strong) !important; display: block; padding: 10px 0; }
	.fvm-nav li.menu-item-has-children { display: flex; flex-wrap: wrap; align-items: center; }
	.fvm-nav li.menu-item-has-children > a { flex: 1 1 auto; }
	/* Die rein dekorative Pfeil-Markierung am Link (Desktop-Dropdown)
	   entfällt hier zugunsten des eigenständigen, bedienbaren Buttons. */
	.fvm-nav li.menu-item-has-children > a::after { display: none; }
	.fvm-submenu-toggle { display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px; flex: 0 0 auto; }
	.fvm-nav .sub-menu { position: static; box-shadow: none; display: none; padding-left: 14px; width: 100%; }
	.fvm-nav li.is-expanded > .sub-menu { display: block; }
	.fvm-nav-toggle { display: block; }
}
@media (max-width: 760px) {
	.fvm-hero__heading { font-size: 32px; }
	h2 { font-size: 24px; }
	.fvm-card-grid { grid-template-columns: 1fr; }
	.fvm-agenda__slide.is-active { grid-template-columns: 1fr; }
	.fvm-agenda__body, .fvm-agenda__slide:not(:has(.fvm-agenda__img)) .fvm-agenda__body { padding: 22px 22px 26px; }
	.fvm-promo__grid { grid-template-columns: 1fr; }
	.fvm-footer__inner { grid-template-columns: 1fr; }
	.fvm-footer__social { justify-content: flex-start; }
	.fvm-partner-grid { grid-template-columns: repeat(2, 1fr); }
}

/* =========================================================
   10. Basis-Unterstützung für Gutenberg-Blöcke
   ========================================================= */
.wp-block-image, .wp-block-gallery { margin-bottom: 1.5em; }
.alignwide { max-width: 1100px; }
.alignfull { max-width: none; width: 100vw; margin-left: calc(50% - 50vw); }


/* =========================================================
   v0.4 – Oberzeilen, Zurück-Link, Archiv-Link, Footer-Symbole
   (Werte gemäss Designvorlage fvm.didico.ch)
   ========================================================= */
.fvm-page-eyebrow {
	display: block;
	margin-bottom: 12px;
	font-family: "Inter", sans-serif;
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: #7fb3d9;
}

.fvm-promo__kicker {
	display: block;
	margin-bottom: 14px;
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: var(--fvm-teal);
}

.fvm-page-content .fvm-back-section--theme {
	margin-top: 48px;
	padding: 28px 0 0;
	border-top: 1px solid #e5e7e9;
}

.fvm-page-content .fvm-back-section--theme .fvm-back-link {
	max-width: 820px;
	margin: 0 auto;
	padding: 0 24px;
	box-sizing: border-box;
	font-weight: 600;
}

.fvm-page-content .fvm-back-section--theme .fvm-back-link a {
	color: var(--fvm-teal);
	text-decoration: none;
}

.fvm-page-content .fvm-back-section--theme .fvm-back-link a:hover {
	text-decoration: underline;
}

.fvm-footer__icon {
	flex: none;
	vertical-align: -2px;
}

.fvm-footer__email a {
	display: inline-flex;
	align-items: center;
	gap: 6px;
}

/* =========================================================
   v0.5 – Agenda je Kategorie, Jahresprogramm, Administration
   (Werte gemäss Designvorlage fvm.didico.ch)
   ========================================================= */
.fvm-agenda__card {
	position: relative;
	margin-top: 18px;
	background: linear-gradient(135deg, #0d2129 0%, #1a5878 100%);
	border-radius: 14px;
	padding: 22px 26px;
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 20px;
}
.fvm-agenda__card .fvm-agenda__track { flex: 1; min-width: 0; }
.fvm-agenda__card .fvm-agenda__slide {
	display: none;
	background: none;
	border-radius: 0;
	box-shadow: none;
	overflow: visible;
}
.fvm-agenda__card .fvm-agenda__slide.is-active { display: block; animation: fvm-agenda-fade .4s ease; }
.fvm-agenda__eyebrow {
	display: block;
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	margin-bottom: 6px;
}
.fvm-agenda__card .fvm-agenda__title {
	font-family: "Inter", sans-serif;
	font-size: 22px;
	font-weight: 700;
	margin: 0 0 4px;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}
.fvm-agenda__card .fvm-agenda__title a { color: #fff; text-decoration: none; }
.fvm-agenda__card .fvm-agenda__title a:hover { text-decoration: underline; }
.fvm-agenda__meta { color: #dce7ec; font-size: 15px; }
.fvm-agenda__card .fvm-agenda__dots { display: flex; gap: 6px; flex-shrink: 0; margin-top: 5px; }
.fvm-agenda__card .fvm-agenda__dot { width: 8px; height: 8px; background: rgba(255, 255, 255, 0.35); }
.fvm-agenda__card .fvm-agenda__dot.is-active { background: #fff; }
@keyframes fvm-agenda-fade { from { opacity: 0; } to { opacity: 1; } }
@media (prefers-reduced-motion: reduce) {
	.fvm-agenda__card .fvm-agenda__slide.is-active { animation: none; }
}
@media (max-width: 600px) {
	.fvm-agenda__card { padding: 18px 20px; }
	.fvm-agenda__card .fvm-agenda__title { white-space: normal; font-size: 19px; }
}

/* Jahresprogramm */
.fvm-jp { margin-top: 32px; }
.fvm-jp-next-card {
	background: linear-gradient(135deg, #0d2129, #1a5878);
	color: #fff;
	border-radius: 14px;
	padding: 24px 28px;
	margin: 0 0 22px;
	box-shadow: 0 18px 40px -18px rgba(13, 33, 41, 0.35);
}
.fvm-jp-next-eyebrow {
	display: block;
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: #f7c600;
	margin: 0 0 6px;
}
.fvm-jp-next-title { font-family: "Inter", sans-serif; font-size: 22px; font-weight: 700; margin: 0 0 4px; }
.fvm-jp-next-meta { font-size: 15px; color: #dce7ec; }
.fvm-jp-filters { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 18px; }
.fvm-jp-filters[hidden] { display: none; }
.fvm-jp-filter-btn {
	font-family: inherit;
	font-size: 14px;
	font-weight: 600;
	padding: 7px 16px;
	border-radius: 999px;
	border: 1.5px solid #c9d4da;
	background: #fff;
	color: #445560;
	cursor: pointer;
	transition: background 0.15s, color 0.15s, border-color 0.15s;
}
.fvm-jp-filter-btn:hover { border-color: #1a5878; color: #1a5878; }
.fvm-jp-filter-btn.fvm-jp-filter-active { background: #0d2129; border-color: #0d2129; color: #fff; }
.fvm-jp-ics { margin: 0 0 20px; }
.fvm-jp-subscribe { font-size: 14px; font-weight: 600; color: #1a5878; text-decoration: underline; }
.fvm-jp-subscribe:hover { color: #0d2129; }
.fvm-program-year { font-family: "Inter", sans-serif; color: #0d2129; font-size: 26px; font-weight: 600; margin: 36px 0 16px; }
.fvm-program-card { background: #fff; border-radius: 14px; overflow: hidden; box-shadow: 0 18px 40px -18px rgba(13, 33, 41, 0.25); }
.fvm-program-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.fvm-program-table { width: 100%; border-collapse: collapse; margin: 0; }
.fvm-program-table th {
	text-align: left;
	font-size: 12px;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	color: #9aa0a6;
	font-weight: 700;
	padding: 14px 20px;
	border-bottom: 1px solid rgba(13, 33, 41, 0.08);
}
.fvm-program-table td { padding: 14px 20px; font-size: 14.5px; color: #3c4043; border-bottom: 1px solid rgba(13, 33, 41, 0.06); vertical-align: middle; }
.fvm-program-table tr:last-child td { border-bottom: none; }
.fvm-program-table tbody tr:nth-child(even) td { background: #fafbfb; }
.fvm-program-date { color: #0d2129; font-weight: 600; white-space: nowrap; }
.fvm-jp-row-meta { font-size: 12.5px; color: #80868b; margin-top: 2px; }
.fvm-jp-cat-badge { display: inline-block; font-size: 12px; font-weight: 700; padding: 3px 10px; border-radius: 999px; white-space: nowrap; }
.fvm-status-badge { display: inline-block; padding: 5px 12px; border-radius: 999px; font-size: 12px; font-weight: 700; letter-spacing: 0.02em; white-space: nowrap; }
.fvm-status-done { background: #e6f4ea; color: #1e7e34; }
.fvm-status-upcoming { background: #eaf2f7; color: #1a5878; }
.fvm-status-pending { background: #fff3cd; color: #a5750a; }
.fvm-status-cancelled { background: #fbebeb; color: #c62828; }
.fvm-jp-star { color: #c62828; font-weight: 700; }
.fvm-program-legend { font-size: 13px; color: #c62828; font-weight: 600; margin-top: 14px; }
.fvm-jp-none { color: #80868b; font-style: italic; }
@media (max-width: 900px) {
	.fvm-jp-next-card { padding: 18px 20px; }
	.fvm-jp-filters { gap: 6px; }
	.fvm-jp-filter-btn { font-size: 13px; padding: 6px 12px; }
	.fvm-program-card { position: relative; }
	.fvm-program-card::after {
		content: "";
		position: absolute;
		top: 0;
		right: 0;
		bottom: 0;
		width: 26px;
		pointer-events: none;
		background: linear-gradient(to right, rgba(255, 255, 255, 0), rgba(255, 255, 255, 0.95));
	}
	.fvm-program-table { min-width: 560px; }
	.fvm-program-table th, .fvm-program-table td { padding: 12px 14px; font-size: 13.5px; }
}

/* Footer: Administration (nur für Administratoren) */
.fvm-footer__admin {
	margin-top: 36px;
	padding: 20px 22px;
	border: 1px dashed rgba(255, 255, 255, 0.3);
	border-radius: 12px;
}
.fvm-footer__admin ul { display: flex; flex-wrap: wrap; gap: 10px 28px; margin: 0; padding: 0; list-style: none; }
.fvm-footer__admin li { margin: 0; }
.fvm-footer__admin a { color: #7fb3d9; }
.fvm-footer__admin a:hover { color: #fff; }
.fvm-footer__admin-pending { color: rgba(255, 255, 255, 0.55); }
.fvm-footer__admin-pending small { font-size: 12px; }

/* v0.5.1 – gleiche Spaltenbreiten in allen Jahrestabellen, lange Titel auf Mobil umbrechen */
.fvm-program-table { table-layout: fixed; }
.fvm-program-table th:nth-child(1) { width: 17%; }
.fvm-program-table th:nth-child(3) { width: 20%; }
.fvm-program-table th:nth-child(4) { width: 20%; }
.fvm-program-table td:nth-child(2) { overflow-wrap: break-word; }
@media (max-width: 600px) {
	.fvm-agenda__card .fvm-agenda__title { overflow-wrap: break-word; hyphens: auto; }
}

/* v0.5.2 – mehrtägige Anlässe: Datumsbereich darf umbrechen */
.fvm-program-table th:nth-child(1) { width: 22%; }
.fvm-program-table th:nth-child(3) { width: 19%; }
.fvm-program-table th:nth-child(4) { width: 19%; }
.fvm-program-date { white-space: normal; }

/* =========================================================
   v0.6 Beitragsseite wie fvm.didico.ch (single.php, js/galerie.js)
   ========================================================= */
.fvm-post-hero .fvm-page-eyebrow {
	margin-bottom: 14px;
}

.fvm-page-content.fvm-post {
	padding: 56px 0;
}

.fvm-post__inner {
	color: #3c4043;
	font-size: 16px;
	line-height: 1.65;
}

.fvm-post__inner p {
	margin: 0 0 18px;
}

.fvm-post__inner a {
	color: var(--fvm-teal);
}

.fvm-post__meta {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 10px;
	margin: 0 0 22px !important;
}

.fvm-post__badge {
	display: inline-block;
	padding: 5px 12px;
	border-radius: var(--fvm-radius-pill);
	font-family: var(--fvm-font-body);
	font-size: 11.5px;
	font-weight: 700;
	letter-spacing: 0.04em;
	line-height: 1.4;
	text-transform: uppercase;
	background: #eceff1;
	color: #5f6368;
}

.fvm-post__badge--jugendgruppe {
	background: #fff3cd;
	color: #a88e00;
}

.fvm-post__badge--anlaesse {
	background: #e3f0f8;
	color: #1a5878;
}

.fvm-post__date {
	font-size: 13px;
	color: #9aa0a6;
}

.fvm-post__inner h2,
.fvm-post__inner h3 {
	margin: 28px 0 18px;
	font-family: var(--fvm-font-heading);
	font-size: 21px;
	font-weight: 800;
	line-height: 1.3;
	color: var(--fvm-dark);
}

/* Grosse Bilder im Text: volle Spaltenbreite. */
.fvm-post__inner .wp-block-image,
.fvm-post__inner figure.wp-block-image {
	margin: 0 0 22px;
}

.fvm-post__inner .wp-block-image img,
.fvm-post__inner img.fvm-post__startbild,
.fvm-post__inner p > img:only-child,
.fvm-post__inner p > a:only-child > img:only-child {
	display: block;
	width: 100%;
	height: auto;
	border-radius: var(--fvm-radius-card);
	box-shadow: 0 18px 40px -18px rgba(13, 33, 41, 0.25);
}

.fvm-post__inner img.fvm-post__startbild {
	margin: 0 0 22px;
}

/* Tabellen in alten Beiträgen lesbar halten (Inhalt unverändert). */
.fvm-post__inner table {
	width: 100%;
	border-collapse: collapse;
	margin: 0 0 22px;
	font-size: 15px;
}

.fvm-post__inner th,
.fvm-post__inner td {
	padding: 8px 10px;
	border-bottom: 1px solid var(--fvm-border);
	text-align: left;
	vertical-align: top;
}

/* PDF zum Herunterladen (einfacher Link am Beitragsende). */
.fvm-post__inner .fvm-download {
	margin-top: 8px;
}

.fvm-post__inner .fvm-download a {
	font-weight: 700;
	text-decoration: none;
}

.fvm-post__inner .fvm-download a::before {
	content: "↓ ";
}

.fvm-post__inner .fvm-download a:hover,
.fvm-post__inner .fvm-download a:focus {
	text-decoration: underline;
}

/* Galerie: grosses Bild, Pfeile, Zähler, Vorschaubilder. */
.fvm-post__inner .fvm-gallery-original[hidden] {
	display: none !important;
}

.fvm-gallery {
	margin: 8px 0 26px;
	outline: none;
}

.fvm-gallery:focus-visible {
	outline: 2px solid var(--fvm-teal);
	outline-offset: 4px;
}

.fvm-gallery__main {
	position: relative;
	overflow: hidden;
	border-radius: var(--fvm-radius-card);
	background: var(--fvm-dark);
	box-shadow: 0 18px 40px -18px rgba(13, 33, 41, 0.25);
	aspect-ratio: 4 / 3;
}

.fvm-post__inner .fvm-gallery__img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: contain;
	border-radius: 0;
	box-shadow: none;
}

.fvm-gallery__nav {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	width: 72px;
	height: 40px;
	border: 0;
	border-radius: 4px;
	background: rgba(255, 255, 255, 0.85);
	color: var(--fvm-dark);
	font-size: 22px;
	line-height: 1;
	cursor: pointer;
}

.fvm-gallery__nav:hover,
.fvm-gallery__nav:focus-visible {
	background: #fff;
}

.fvm-gallery__nav--prev {
	left: 12px;
}

.fvm-gallery__nav--next {
	right: 12px;
}

.fvm-gallery__counter {
	position: absolute;
	right: 12px;
	bottom: 12px;
	padding: 6px 10px;
	border-radius: var(--fvm-radius-pill);
	background: rgba(13, 33, 41, 0.65);
	color: #fff;
	font-size: 12px;
	line-height: 1.2;
}

.fvm-post__inner .fvm-gallery__caption {
	margin: 8px 0 0;
	font-size: 13px;
	color: var(--fvm-text);
}

.fvm-gallery__thumbs {
	display: flex;
	gap: 8px;
	margin-top: 12px;
	overflow-x: auto;
	scrollbar-width: thin;
	-webkit-overflow-scrolling: touch;
}

.fvm-gallery__thumb {
	flex: 0 0 76px;
	height: 100px;
	padding: 0;
	border: 0;
	background: none;
	cursor: pointer;
	opacity: 0.7;
}

.fvm-gallery__thumb.is-active,
.fvm-gallery__thumb:hover,
.fvm-gallery__thumb:focus-visible {
	opacity: 1;
}

.fvm-gallery__thumb.is-active {
	outline: 2px solid var(--fvm-teal);
	outline-offset: -2px;
}

.fvm-post__inner .fvm-gallery__thumb img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	border-radius: 0;
	box-shadow: none;
}

/* «← Zurück zu News» wie die Vorlage: ohne Trennlinie. */
.fvm-page-content.fvm-post .fvm-back-section--theme {
	margin-top: 40px;
	padding-top: 0;
	border-top: 0;
}

/* Smartphone */
@media (max-width: 600px) {
	.fvm-post-hero h1 {
		font-size: 28px;
		line-height: 1.2;
	}

	.fvm-page-content.fvm-post {
		padding: 36px 0 44px;
	}

	.fvm-gallery__nav {
		width: 44px;
		height: 36px;
	}

	.fvm-gallery__thumb {
		flex-basis: 60px;
		height: 80px;
	}
}
