/*
Theme Name: KGV Im Beisen
Theme URI: https://kgv-im-beisen.com
Author: Gerhard Gromberg
Description: Eigenes schlankes Theme für den KGV Im Beisen e.V. — kein Page-Builder, liefert nur den Rahmen (Header, Footer, Startseiten-Layout). Bestehende Plugin-Shortcodes bleiben unverändert nutzbar.
Version: 7.3
Text Domain: kgv-im-beisen
*/

/* Der separate Pfeil-Button (.submenu-toggle) aus früheren Experimenten wird
   nicht mehr verwendet — nur noch der einfache Pfeil im Linktext selbst.
   Diese Regel blendet den Button unabhängig von allen anderen (auch alten,
   evtl. noch nicht überschriebenen) Regeln zuverlässig aus. */
.submenu-toggle { display: none !important; }
:root {
  --soil: #1C1810;
  --leaf: #5B8A3A;
  --forest: #14210F;
  --clay: #D13B1F;
  --parchment: #F4EDD8;
  --marigold: #F0A81C;
  --leaf-light: #D9E6C4;
  --line: rgba(46,42,31,0.14);
}
* { box-sizing: border-box; margin: 0; padding: 0; }
body {
  background: var(--parchment);
  color: var(--soil);
  font-family: 'Work Sans', sans-serif;
  line-height: 1.6;
}
.wrap { max-width: 100%; margin: 0 auto; padding: 0 clamp(20px, 3vw, 64px); }
h1, h2, h3 { font-family: 'Fraunces', serif; font-weight: 500; letter-spacing: -0.01em; }
a { color: inherit; text-decoration: none; }

/* Header */
.site-header {
  border-bottom: 1px solid var(--line);
  background: var(--parchment);
  position: sticky; top: 0; z-index: 20;
}
.nav-row {
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px clamp(20px, 3vw, 64px); max-width: 100%; margin: 0 auto;
  position: relative;
}
.logo { display: flex; align-items: center; gap: 10px; font-family: 'Fraunces', serif; font-weight: 600; font-size: 19px; white-space: nowrap; flex-shrink: 0; }
.logo-mark { width: 34px; height: 34px; flex-shrink: 0; }
nav ul { display: flex; gap: 26px; list-style: none; }
nav ul li { position: relative; }
nav a { font-size: 14px; font-weight: 500; color: var(--forest); position: relative; display: flex; align-items: center; gap: 4px; }
nav a:hover { color: var(--clay); }
.menu-item-has-children > a::after { content: '▾'; font-size: 10px; opacity: 0.6; }
.menu-item-locked > a::before {
  content: '🔒'; font-size: 10px; opacity: 0.6;
}
.nav-toggle { display: none; }
.nav-burger {
  display: none; flex-direction: column; justify-content: center; gap: 5px;
  width: 30px; height: 24px; cursor: pointer;
}
.nav-burger span { display: block; height: 2px; background: var(--forest); border-radius: 2px; }
nav ul.sub-menu {
  display: none; position: absolute; top: 100%; left: 0; margin-top: 14px;
  background: #fff; border: 1px solid var(--line); border-radius: 6px;
  padding: 8px; min-width: 220px; box-shadow: 0 8px 20px rgba(46,42,31,0.08);
  flex-direction: column; gap: 0;
}
nav ul.sub-menu::before {
  content: ""; position: absolute; top: -14px; left: 0; right: 0; height: 14px;
}
li:hover > ul.sub-menu, li:focus-within > ul.sub-menu { display: flex; }
ul.sub-menu a { padding: 8px 10px; border-radius: 4px; font-size: 13.5px; font-weight: 400; }
ul.sub-menu a:hover { background: var(--leaf-light); color: var(--forest); }
/* Verschachtelte Untermenüs (2. Ebene, z. B. Vereinshaus → Aktuelles → Termine) seitlich statt darunter öffnen */
ul.sub-menu li { position: relative; }
ul.sub-menu ul.sub-menu { top: -9px; left: calc(100% + 6px); margin-top: 0; }
ul.sub-menu ul.sub-menu::before { top: 0; left: -14px; right: auto; width: 14px; height: 100%; }
.btn-login {
  border: 1px solid var(--forest); border-radius: 3px;
  padding: 9px 18px; font-size: 13.5px; font-weight: 500;
  color: var(--forest); white-space: nowrap;
}
.btn-login:hover { background: var(--forest); color: var(--parchment); }

/* Hero */
.hero {
  padding: 72px clamp(20px, 3vw, 64px) 56px;
  background-image: radial-gradient(circle, rgba(46,42,31,0.12) 1px, transparent 1px);
  background-size: 22px 22px;
}
.hero-grid { max-width: 100%; margin: 0 auto; display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 64px; align-items: start; }
.eyebrow { font-family: 'IBM Plex Mono', monospace; font-size: 12.5px; letter-spacing: 0.06em; color: var(--clay); text-transform: uppercase; margin-bottom: 18px; display: block; }
.hero h1 { font-size: 36px; line-height: 1.15; margin-bottom: 18px; color: var(--forest); font-weight: 500; }
.hero p.lead { font-size: 17px; color: rgba(46,42,31,0.78); max-width: 460px; margin-bottom: 32px; }
.hero-ctas { display: flex; gap: 14px; flex-wrap: wrap; }
.hero-extra { font-size: 15px; color: rgba(46,42,31,0.8); margin: 28px 0 16px; max-width: 480px; }
.btn-primary {
  background: var(--clay); color: var(--parchment); padding: 13px 24px;
  border-radius: 3px; font-size: 14.5px; font-weight: 500; display: inline-block;
}
.btn-primary:hover { background: #9c4622; }
.btn-secondary {
  border: 1px solid var(--forest); color: var(--forest); padding: 12px 23px;
  border-radius: 3px; font-size: 14.5px; font-weight: 500; display: inline-block;
}
.btn-secondary:hover { background: var(--forest); color: var(--parchment); }

/* Plot grid signature element */
.plot-panel {
  background: var(--forest); border-radius: 6px; padding: 28px;
  color: var(--parchment);
}
.plot-panel .plot-label {
  font-family: 'IBM Plex Mono', monospace; font-size: 12px; letter-spacing: 0.04em;
  color: rgba(241,236,221,0.65); margin-bottom: 16px; display: flex; justify-content: space-between;
}
.plot-grid { display: flex; flex-direction: column; gap: 5px; margin-bottom: 16px; }
.plot-row { display: grid; grid-template-columns: repeat(13, 1fr); gap: 5px; }
.plot-doublerow { display: flex; flex-direction: column; gap: 0; }
.plot-doublerow .plot-row { gap: 5px; }
.plot {
  aspect-ratio: 1; border-radius: 2px; background: #6E8A5D;
  display: flex; align-items: center; justify-content: center;
  font-family: 'IBM Plex Mono', monospace; font-size: 9px; color: rgba(241,236,221,0.85);
}
.vh-block {
  aspect-ratio: 1; background: var(--marigold); border-radius: 2px; color: #4A340A;
  display: flex; align-items: center; justify-content: center;
  font-family: 'IBM Plex Mono', monospace; font-size: 9px; font-weight: 500;
}
.plot-legend { display: flex; gap: 16px; font-size: 12px; color: rgba(241,236,221,0.75); flex-wrap: wrap; }
.plot-legend span { display: flex; align-items: center; gap: 6px; }

/* Ticker */
.ticker {
  background: var(--clay); color: var(--parchment); padding: 15px 0;
  font-family: 'IBM Plex Mono', monospace; font-size: 13px; overflow: hidden;
}
.ticker .wrap { display: flex; align-items: center; gap: 22px; flex-wrap: wrap; }
.ticker-scroll { overflow: hidden; flex: 1; min-width: 0; -webkit-mask-image: linear-gradient(90deg, transparent, #000 24px, #000 calc(100% - 24px), transparent); mask-image: linear-gradient(90deg, transparent, #000 24px, #000 calc(100% - 24px), transparent); }
.ticker-track { display: flex; align-items: center; gap: 14px; white-space: nowrap; width: max-content; animation: ticker-scroll-anim 28s linear infinite; }
.ticker:hover .ticker-track { animation-play-state: paused; }
@keyframes ticker-scroll-anim {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}
.ticker .tag {
  background: var(--soil); color: var(--parchment); padding: 5px 12px;
  border-radius: 2px; font-weight: 500; flex-shrink: 0;
  display: flex; align-items: center; gap: 6px;
}
.ticker .tag svg { flex-shrink: 0; }
.ticker-track a { color: inherit; }
.ticker-track a:hover { text-decoration: underline; }
.ticker-track .sep { opacity: 0.6; }
@media (max-width: 640px) {
  .ticker-track { animation-duration: 18s; }
}

/* Welcome-Inhalte (jetzt Teil der Hero-Textspalte) */
.welcome-links { list-style: none; margin-bottom: 26px; display: flex; flex-direction: column; gap: 10px; max-width: 480px; }
.welcome-links a {
  display: block; font-size: 14.5px; font-weight: 500; color: var(--forest);
  background: var(--leaf-light); border-left: 3px solid var(--leaf);
  border-radius: 4px; padding: 12px 16px;
}
.welcome-links a:hover { background: rgba(209,59,31,0.1); border-left-color: var(--clay); color: var(--clay); }
.welcome-note {
  background: var(--leaf-light); border-radius: 6px; padding: 20px 24px;
  border-left: 3px solid var(--leaf);
}
.welcome-note strong { display: block; color: var(--forest); font-size: 15px; margin-bottom: 8px; }
.welcome-note p { font-size: 14.5px; color: rgba(46,42,31,0.78); margin: 0; }
.welcome-note a { color: var(--clay); font-weight: 500; }

/* Features */
.features { padding: 64px clamp(20px, 3vw, 64px); }
.section-head { max-width: 100%; margin: 0 auto 34px; display: flex; justify-content: space-between; align-items: flex-end; }
.section-head h2 { font-size: 26px; color: var(--forest); }
.card-grid { max-width: 100%; margin: 0 auto; display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.card {
  background: #fff; border: 1px solid var(--line); border-radius: 6px;
  padding: 26px; display: flex; flex-direction: column; gap: 12px;
}
.card .icon {
  width: 38px; height: 38px; border-radius: 5px; background: var(--leaf-light);
  display: flex; align-items: center; justify-content: center;
}
.card .icon.marigold { background: rgba(240,168,28,0.22); }
.card .icon.clay { background: rgba(209,59,31,0.13); }
.card h3 { font-size: 18px; color: var(--forest); }
.card p { font-size: 14.5px; color: rgba(46,42,31,0.72); }
.card .link { font-size: 13.5px; font-weight: 500; color: var(--clay); margin-top: auto; }
.card .link + .link { margin-top: 4px; }
.card.accent { background: var(--forest); color: var(--parchment); border-color: var(--forest); }
.card.accent h3 { color: var(--parchment); }
.card.accent p { color: rgba(241,236,221,0.75); }
.card.accent .icon { background: rgba(241,236,221,0.14); }
.card.accent .link { color: var(--marigold); }

/* Belegung */
.hero-side { display: flex; flex-direction: column; gap: 20px; }
.beleg-mini {
  background: #fff; border: 1px solid var(--clay); border-radius: 6px; padding: 22px;
  box-shadow: 0 10px 28px rgba(46,42,31,0.08);
}
.beleg-mini-head { display: flex; flex-direction: column; margin-bottom: 14px; }
.beleg-mini-head .eyebrow { margin-bottom: 6px; }
.beleg-mini-head h2 { font-size: 19px; color: var(--forest); }
.legend-list { display: flex; flex-direction: column; gap: 10px; font-size: 13.5px; }
.legend-list.legend-list-row { flex-direction: row; flex-wrap: wrap; gap: 8px 16px; margin: 14px 0 16px; }
.legend-list span { display: flex; align-items: center; gap: 8px; }
.legend-list .sw { width: 12px; height: 12px; border-radius: 2px; }
.sw.avail { background: var(--leaf-light); border: 1px solid var(--leaf); }
.sw.booked { background: #E9C4C4; }
.sw.change { background: var(--marigold); }
.sw.internal { background: var(--soil); }
.btn-block { display: block; text-align: center; width: 100%; box-sizing: border-box; }
.cal-head { font-family: 'IBM Plex Mono', monospace; font-size: 13px; color: var(--forest); margin-bottom: 12px; display: flex; justify-content: space-between; align-items: center; }
.cal-head a {
  display: inline-flex; align-items: center; justify-content: center;
  width: 26px; height: 26px; border: 1px solid var(--line); border-radius: 4px;
  color: var(--forest); font-size: 15px;
}
.cal-head a:hover { background: var(--leaf-light); border-color: var(--leaf); }
.cal-head a:first-child { margin-right: 6px; }
.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; }
.cal-grid .d { text-align: center; font-size: 11.5px; color: rgba(46,42,31,0.45); padding-bottom: 4px; font-family: 'IBM Plex Mono', monospace; }
.cal-grid .cell {
  height: 32px; border-radius: 3px; background: var(--leaf-light);
  display: flex; align-items: center; justify-content: center;
  font-family: 'IBM Plex Mono', monospace; font-size: 12.5px; color: var(--forest);
}
.cal-grid .cell.b { background: #E9C4C4; }
.cal-grid .cell.c { background: var(--marigold); }
.cal-grid .cell.empty { background: transparent; }

.page-content { max-width: 1320px; margin: 0 auto; padding: 56px clamp(20px, 3vw, 64px); }
.page-content h1 { font-size: 32px; color: var(--forest); margin-bottom: 20px; }
.page-content p { margin-bottom: 16px; }

/* Unterseiten (Vorstand, Vita, Anlage, Pacht & Kosten usw.) */
.page-hero {
  background: var(--forest); color: var(--parchment);
  padding: 48px clamp(20px, 3vw, 64px) 40px;
  background-image: radial-gradient(circle, rgba(241,236,221,0.08) 1px, transparent 1px);
  background-size: 22px 22px;
}
.page-hero-inner { max-width: 1320px; margin: 0 auto; }
.page-hero .eyebrow { color: var(--marigold); }
.page-hero h1 { font-size: 34px; color: var(--parchment); }
.page-content-wrap { background: var(--parchment); }
.page-body { font-size: 16px; color: rgba(46,42,31,0.85); }
.page-body p { margin-bottom: 20px; }
.page-body h2 { font-size: 24px; color: var(--forest); margin: 32px 0 14px; }
.page-body h3 { font-size: 19px; color: var(--forest); margin: 24px 0 10px; }
.page-body strong { color: var(--forest); }
.page-body a { color: var(--clay); font-weight: 500; text-decoration: underline; }
.page-body ul, .page-body ol { margin: 0 0 20px 22px; }
.page-body img {
  max-width: 100%; height: auto; border-radius: 8px; border: 1px solid var(--line);
}
.page-body img.alignleft {
  float: left; margin: 6px 24px 16px 0; max-width: 46%;
}
.page-body img.alignright {
  float: right; margin: 6px 0 16px 24px; max-width: 46%;
}
.page-body img.aligncenter {
  display: block; margin: 28px auto;
}
.page-body img:not(.alignleft):not(.alignright):not(.aligncenter) {
  display: block; margin: 28px 0;
}
.page-body::after { content: ""; display: table; clear: both; }
.page-body p { overflow: visible; }

/* WordPress-Galerie-Blöcke (mehrere Bilder als Raster). Wichtig: WordPress
   regelt Breite/Höhe/Zuschnitt der Bilder in diesem Block-Typ bereits selbst
   sehr zuverlässig (flex-basis pro Bild, object-fit:cover). Hier NICHT
   dagegen ankämpfen (frühere Versionen taten das mit display:grid + fester
   Bildhöhe und verursachten dadurch genau die Darstellungsfehler, die wir
   beheben wollten) — nur behutsam Rahmen/Ecken/Hover ergänzen. */
.page-body .wp-block-gallery {
  clear: both;
}
.page-body .wp-block-gallery figure.wp-block-image img {
  border-radius: 6px; border: 1px solid var(--line);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.page-body .wp-block-gallery figure.wp-block-image img:hover {
  transform: scale(1.03); box-shadow: 0 8px 20px rgba(46,42,31,0.15);
}
/* Klassische WordPress-Galerie ([gallery]-Shortcode, älteres Format) — bisher
   ohne eigene Gestaltung, fiel dadurch auf winzige Standard-Miniaturbilder
   zurück. Bekommt jetzt dieselbe Optik wie die Block-Editor-Galerie oben. */
.page-body .gallery {
  display: grid !important; grid-template-columns: repeat(3, 1fr); gap: 12px;
  margin: 32px 0; list-style: none; padding: 0; clear: both;
}
.page-body .gallery-item { margin: 0 !important; width: auto !important; float: none !important; }
.page-body .gallery-icon { margin: 0; }
.page-body .gallery-icon img {
  width: 100% !important; height: 220px !important; object-fit: cover; display: block;
  border-radius: 6px; border: 1px solid var(--line); margin: 0;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.page-body .gallery-icon img:hover {
  transform: scale(1.03); box-shadow: 0 8px 20px rgba(46,42,31,0.15);
}
.page-body .gallery-caption { display: none; }
@media (max-width: 700px) {
  .page-body .gallery { grid-template-columns: repeat(2, 1fr) !important; }
}
@media (max-width: 460px) {
  .page-body .gallery { grid-template-columns: 1fr !important; }
}
.page-body blockquote {
  background: var(--leaf-light); border-left: 3px solid var(--leaf);
  border-radius: 6px; padding: 18px 22px; margin: 24px 0; font-style: italic;
}

/* Tabellen (u. a. TablePress) — auf schmalen Bildschirmen wischbar statt gequetscht */
.page-body table,
.page-body .tablepress-scroll-wrapper {
  display: block; overflow-x: auto; -webkit-overflow-scrolling: touch;
  max-width: 100%; margin: 24px 0; border-radius: 6px; border: 1px solid var(--line);
}
.page-body table {
  border-collapse: collapse; width: 100%; font-size: 14.5px;
}
.page-body table th, .page-body table td {
  padding: 10px 14px; text-align: left; border-bottom: 1px solid var(--line);
  white-space: normal; word-wrap: break-word; overflow-wrap: break-word;
}
.page-body table th {
  background: var(--forest); color: var(--parchment); font-weight: 500;
  font-family: 'IBM Plex Mono', monospace; font-size: 12.5px;
  text-transform: uppercase; letter-spacing: 0.03em;
}
.page-body table tr:nth-child(even) td { background: var(--leaf-light); }
.page-body table td:first-child { background: #fff; }
.page-body table tr:nth-child(even) td:first-child { background: var(--leaf-light); }
.page-body table th:first-child,
.page-body table td:first-child {
  position: sticky; left: 0; box-shadow: 4px 0 6px -4px rgba(46,42,31,0.25);
}
.page-body table th:first-child { z-index: 2; }
.page-body table td:first-child { z-index: 1; }
@media (max-width: 640px) {
  .page-body table { font-size: 12px; width: auto !important; min-width: 100% !important; table-layout: auto !important; }
  .page-body table th, .page-body table td {
    padding: 6px 8px; width: auto !important; min-width: 68px; white-space: normal !important;
  }
  .page-body table td { word-break: break-word; }
  .page-body table th {
    font-size: 10.5px; hyphens: auto; -webkit-hyphens: auto;
    word-break: normal; overflow-wrap: break-word;
  }
  /* Erste Spalte (Aufgabe/Bezeichnung) breiter als die übrigen, schmalen Datenspalten */
  .page-body table th:first-child,
  .page-body table td:first-child {
    min-width: 150px;
  }
  .page-body table th:not(:first-child),
  .page-body table td:not(:first-child) {
    min-width: 52px;
  }
  /* Jahresabrechnung (.ml-abr-table, 15 Spalten): bleibt bewusst horizontal
     wischbar statt umzubrechen — sonst brechen Namen wie "Thomas Händel"
     buchstabenweise um. Die obige allgemeine Regel wird hier gezielt wieder
     zurückgenommen. */
  .page-body table.ml-abr-table {
    width: auto !important; min-width: 0 !important; table-layout: auto !important;
  }
  .page-body table.ml-abr-table th,
  .page-body table.ml-abr-table td {
    width: auto !important; min-width: 0 !important; white-space: nowrap !important;
  }
  .page-body table.ml-abr-table td { word-break: normal !important; }
  .page-body table.ml-abr-table th:first-child,
  .page-body table.ml-abr-table td:first-child {
    min-width: 0 !important;
  }
  .page-body .dataTables_wrapper,
  .page-body .dataTables_wrapper div {
    max-width: 100% !important; width: auto !important;
  }
  .page-body .dataTables_wrapper table { min-width: 100% !important; }
}
.page-content-grid { display: grid; grid-template-columns: 1fr 320px; gap: 44px; align-items: start; }
.page-aside { display: flex; flex-direction: column; gap: 20px; position: sticky; top: 90px; }
.side-widget {
  background: #fff; border: 1px solid var(--line); border-radius: 6px; padding: 20px;
}
.side-widget h4 {
  font-family: 'IBM Plex Mono', monospace; font-size: 12.5px; text-transform: uppercase;
  letter-spacing: 0.05em; color: var(--clay); margin-bottom: 12px;
}
.side-widget img { max-width: 100%; height: auto; border-radius: 4px; }
.side-widget p { font-size: 14px; margin-bottom: 10px; }
.side-widget a { color: var(--clay); font-weight: 500; }
@media (max-width: 960px) {
  .page-content-grid { grid-template-columns: 1fr; }
  .page-aside { position: static; }
}

/* Footer */
.site-footer { background: var(--forest); color: var(--parchment); padding: 48px clamp(20px, 3vw, 64px) 28px; }
.foot-grid { max-width: 100%; margin: 0 auto; display: grid; grid-template-columns: 1.2fr 1fr; gap: 40px; margin-bottom: 36px; }
.site-footer h4 { font-family: 'IBM Plex Mono', monospace; font-size: 12.5px; text-transform: uppercase; letter-spacing: 0.05em; color: var(--marigold); margin-bottom: 14px; }
.site-footer p, .site-footer a { font-size: 14px; color: rgba(241,236,221,0.78); }
.site-footer ul { list-style: none; display: flex; flex-direction: column; gap: 9px; }
.foot-bottom { max-width: 100%; margin: 0 auto; border-top: 1px solid rgba(241,236,221,0.15); padding-top: 20px; font-size: 12.5px; color: rgba(241,236,221,0.5); font-family: 'IBM Plex Mono', monospace; }

@media (max-width: 1080px) {
  .card-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 1500px) {
  .nav-row { justify-content: flex-start; }
  .logo { font-size: 16px; }
  .btn-login { display: none; }
  .nav-burger { display: flex; margin-left: auto; }
  nav { order: 1; }
  nav ul.menu {
    display: none; position: absolute; top: 100%; left: 0; right: 0;
    background: #fff; flex-direction: column; gap: 0; border-top: 1px solid var(--line);
    box-shadow: 0 12px 24px rgba(46,42,31,0.1); padding: 8px 0; z-index: 30;
    max-height: calc(100vh - 74px); overflow-y: auto; -webkit-overflow-scrolling: touch;
  }
  nav ul.menu > li { width: 100%; }
  nav ul.menu > li > a { padding: 12px clamp(20px, 3vw, 64px); width: 100%; box-sizing: border-box; }
  .menu-item-has-children > a::after {
    transition: transform 0.15s ease;
    font-size: 15px; opacity: 1; color: var(--clay); margin-left: 6px; font-weight: 700;
  }
  li.submenu-open > a::after { transform: rotate(180deg); }
  nav ul.sub-menu { position: static; box-shadow: none; border: none; padding-left: 16px; margin-top: 0; display: none; width: 100%; }
  li.menu-item-has-children.submenu-open > ul.sub-menu { display: flex; }
  /* Alte Desktop-Hover/Fokus-Regel (li:hover/li:focus-within öffnet automatisch) auf Mobile deaktivieren — hier zählt nur noch die per JS gesetzte .submenu-open-Klasse */
  nav li:hover > ul.sub-menu, nav li:focus-within > ul.sub-menu { display: none; }
  li.menu-item-has-children.submenu-open > ul.sub-menu { display: flex; }
  .nav-toggle:checked ~ nav ul.menu { display: flex; }
  /* Mobiles Menü kompakter: Desktop-Abstand (gap:26px) hier nicht übernehmen, alle Ebenen einheitlich eng */
  nav ul.menu, nav ul.sub-menu { gap: 0; }
  /* Zusätzlicher Login-Punkt am Ende des mobilen Menüs (nur Mobile, Desktop-Button bleibt wie gewohnt oben rechts) */
  nav ul.menu > li > a,
  nav ul.sub-menu a {
    padding: 7px 16px;
    line-height: 1.25;
  }
  nav ul.menu > li > a { font-size: 15px; padding-left: clamp(20px, 3vw, 64px); padding-right: clamp(20px, 3vw, 64px); }
  nav ul.sub-menu a { font-size: 13.5px; }
  .hero-grid { grid-template-columns: 1fr; }
  .hero h1 { font-size: 28px; }
  .card-grid { grid-template-columns: 1fr; }
  .foot-grid { grid-template-columns: 1fr; gap: 28px; }
}

/* Termine-Tabelle (TablePress ID 11): Termin/Uhrzeit schmal, Beschreibung/Zusatzinfo breiter */
@media (max-width: 640px) {
  .page-body table#tablepress-11 th,
  .page-body table#tablepress-11 td {
    min-width: 0;
  }
  .page-body table#tablepress-11 th:first-child,
  .page-body table#tablepress-11 td:first-child {
    min-width: 60px;
  }
  .page-body table#tablepress-11 th:nth-child(2),
  .page-body table#tablepress-11 td:nth-child(2) {
    min-width: 55px;
  }
  .page-body table#tablepress-11 th:nth-child(3),
  .page-body table#tablepress-11 td:nth-child(3),
  .page-body table#tablepress-11 th:nth-child(4),
  .page-body table#tablepress-11 td:nth-child(4) {
    min-width: 130px;
  }
}

/* Gartenliste-Tabelle: Die allgemeine Regel weiter unten (".page-body table")
   setzt auf JEDER Tabelle "display:block" (ursprünglich für TablePress
   gedacht, damit sie auf dem Handy wischbar ist). Das bricht bei der
   Gartenliste-Tabelle das normale Tabellen-Layout — der äußere Rahmen wird
   breit, die Spalten richten sich dann aber nur noch nach ihrem Inhalt statt
   nach der Containerbreite, wodurch sie schmal bleibt. Hier gezielt nur für
   die Gartenliste-Tabelle zurückgesetzt; die Seitenbreite selbst bleibt wie
   bei allen anderen Unterseiten unverändert. */
.page-body table.gl-table {
  display: table !important;
  overflow: visible !important;
  margin: 0 !important;
  border: none !important;
  border-radius: 0 !important;
}
/* Gleiches Problem/gleiche Lösung bei der Stundenverwaltungs-Tabelle (Plugin
   "Gemeinschaftsstunden KGV im Beisen", Klasse .gs-table). */
.page-body table.gs-table {
  display: table !important;
  overflow: visible !important;
  margin: 0 !important;
  border: none !important;
  border-radius: 0 !important;
}
/* Gleiches Problem/gleiche Lösung bei der Jahresabrechnungs-Tabelle (Plugin
   "Mitgliederlisten KGV im Beisen", Klasse .ml-abr-table). Die Tabelle hat
   viele Spalten und bleibt daher bewusst horizontal wischbar statt in Karten
   umgewandelt zu werden — der äußere Wrapper (.ml-abr-table-wrap) übernimmt
   dafür weiterhin overflow-x:auto aus dem Plugin-CSS. */
.page-body table.ml-abr-table {
  display: table !important;
  overflow: visible !important;
  margin: 0 !important;
  border: none !important;
  border-radius: 0 !important;
}

/* Jahresabrechnungs-Tabelle auch von der generischen Mobile-Tabellen-Regel
   (68px-Mindestbreite, weißspace:normal, word-break) ausnehmen — die zwang
   Namen wie "Thomas Händel" zu buchstabenweisem Umbruch. Stattdessen behält
   die Tabelle ihre natürliche, ungebrochene Breite und bleibt über den
   Wrapper (.ml-abr-table-wrap) horizontal wischbar. */
@media (max-width: 640px) {
  .page-body table.ml-abr-table,
  .page-body table.ml-abr-table th,
  .page-body table.ml-abr-table td {
    width: auto !important;
    min-width: 0 !important;
    white-space: nowrap !important;
    word-break: normal !important;
  }
  .page-body table.ml-abr-table {
    table-layout: auto !important;
  }
}

/* Jahresabrechnung / Vereinshaus-Abrechnung (Plugin "Mitgliederlisten KGV im
   Beisen", erkennbar an der Klasse .ml-abr-app, die nur bei diesen beiden
   Shortcodes vorkommt): Tabelle hat viele Spalten — Content-Bereich dieser
   Seite gezielt verbreitert (moderat, Ränder bleiben erhalten), damit auf
   Desktop-Breiten kein horizontales Scrollen mehr nötig ist. Andere Seiten
   bleiben unverändert bei 1320px. */
body:has(.ml-abr-app) .page-content {
  max-width: 1600px;
}
