/* Ferien-Übersicht – „Der Ferienstreifen“: Tafelgrün als Grundton, Gabarito für Überschriften, Rethink Sans für Text,
   jede Ferienart mit eigener Farbe im Zeitband. Hell und dunkel über Variablen. */
@font-face { font-family: "Gabarito"; src: url("/fonts/gabarito-var.woff2") format("woff2"); font-weight: 400 900; font-display: swap; }
@font-face { font-family: "Rethink Sans"; src: url("/fonts/rethink-sans-var.woff2") format("woff2"); font-weight: 400 800; font-display: swap; }

:root {
  --grund: #f3f6f4; --papier: #ffffff; --tinte: #14211c; --leise: #53625b; --linie: #dbe3de; --linie-stark: #bfccc5;
  --tafel: #1e3d33; --tafel-hell: #e4eee9; --link: #17644a;
  --winter: #4f8fd0; --ostern: #6aa83a; --pfingsten: #8d6cc9; --sommer: #f2ad00; --herbst: #d4742a; --weihnachten: #c23b32;
  --accent: #1e3d33; --on-accent: #ffffff; --logo-flame: #ffc233; --schraffur: rgba(20, 33, 28, .42);
  --titel: "Gabarito", system-ui, sans-serif; --text: "Rethink Sans", system-ui, sans-serif;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root { --grund: #0f1714; --papier: #17211d; --tinte: #e8efeb; --leise: #a5b5ad; --linie: #28362f; --linie-stark: #3b4b43;
    --tafel: #9fd4bd; --tafel-hell: #1d3029; --link: #8fd6b6;
    --winter: #79b0ea; --ostern: #8dc85e; --pfingsten: #ae93e6; --sommer: #ffc533; --herbst: #ee9550; --weihnachten: #ef6b60;
    --accent: #9fd4bd; --on-accent: #0f1714; --logo-flame: #ffc533; --schraffur: rgba(232, 239, 235, .42); }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
html, body { overflow-x: clip; }   /* nie seitlich aus der Seite scrollen; breite Inhalte scrollen in ihrem eigenen Rahmen */
body { margin: 0; background: var(--grund); color: var(--tinte); font: 400 1.0625rem/1.62 var(--text); font-variant-numeric: tabular-nums; }
a { color: var(--link); text-underline-offset: .18em; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--sommer); outline-offset: 2px; border-radius: 2px; }
.wrap { max-width: 76rem; margin: 0 auto; padding: 0 1.25rem; }
.skip { position: absolute; left: -999px; top: 0; background: var(--tinte); color: var(--papier); padding: .6rem 1rem; z-index: 9; }
.skip:focus { left: 1rem; top: .6rem; }

header.site { background: var(--tafel); color: #fff; }
@media (prefers-color-scheme: dark) { header.site { background: #13261f; } }
header.site .wrap { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem 2rem; padding-block: .75rem; }
.brand { display: flex; align-items: center; gap: .6rem; color: #fff; text-decoration: none; }
.logo { width: 2.1rem; height: 2.1rem; flex: none; --logo-bg: #ffffff; --logo-fg: #1e3d33; --logo-flame: #f2ad00; }
.wordmark { font: 800 1.35rem/1 var(--titel); letter-spacing: -.01em; }
.wordmark .jahr { color: #ffc533; }
nav.main ul { display: flex; flex-wrap: wrap; gap: .2rem 1.1rem; list-style: none; margin: 0; padding: 0; }
nav.main a { color: #e6efea; text-decoration: none; font-weight: 600; padding: .3rem 0; display: inline-block; border-bottom: 2px solid transparent; }
nav.main a[aria-current] { color: #fff; border-bottom-color: #ffc533; }
nav.main a:hover { color: #fff; border-bottom-color: rgba(255, 255, 255, .45); }

main { padding-bottom: 3rem; }
h1, h2, h3 { font-family: var(--titel); line-height: 1.1; letter-spacing: -.015em; }
h1 { font-size: clamp(2.3rem, 6vw, 3.6rem); font-weight: 850; margin: 1.5rem 0 .8rem; }
h2 { font-size: clamp(1.5rem, 3.2vw, 2rem); font-weight: 800; margin: 2.6rem 0 .8rem; }
h3 { font-size: 1.25rem; font-weight: 750; }
p, ul, ol { max-width: 70ch; }
.lead { font-size: 1.18rem; line-height: 1.55; }
.hero h1 { font-size: clamp(2.8rem, 9vw, 5.4rem); margin: .2rem 0 .7rem; letter-spacing: -.03em; }
.ueber { margin: 1.6rem 0 0; color: var(--leise); font-weight: 600; }
.klein, .stand { font-size: .92rem; color: var(--leise); }
.stand { margin-top: 3rem; border-top: 1px solid var(--linie); padding-top: 1rem; }
.breadcrumb ol { display: flex; flex-wrap: wrap; gap: .3rem; list-style: none; padding: 0; margin: 1.2rem 0 0; font-size: .9rem; color: var(--leise); }
.breadcrumb li + li::before { content: "›"; margin-right: .3rem; }
.breadcrumb a { color: var(--leise); }

/* Ferienstreifen */
.streifen { margin: 1rem 0 1.4rem; background: var(--papier); border: 1px solid var(--linie); border-radius: .7rem; padding: .8rem .9rem .5rem; }
.streifen svg { display: block; width: 100%; height: auto; }
.streifen figcaption { font-size: .82rem; color: var(--leise); margin-top: .3rem; }
.streifen .bahn { fill: var(--grund); }
.streifen .m { stroke: var(--linie-stark); stroke-width: 1; }
.streifen .mt { fill: var(--leise); font: 600 13px var(--text); text-anchor: middle; }
.streifen .lt { fill: var(--tinte); font: 700 13px var(--titel); }
/* Heute: Linie am heutigen Tag, vergangene Zeit schraffiert (heute.js) */
.streifen .heute { stroke: var(--tinte); stroke-width: 2.5; }
.streifen .heute-text { fill: var(--tinte); font: 700 13px var(--text); }
.streifen .vorbei { pointer-events: none; }
.streifen .schraffur-linie { stroke: var(--tinte); stroke-width: 2.2; stroke-opacity: .32; }
.l-vorbei { background-image: repeating-linear-gradient(135deg, var(--schraffur) 0 1.6px, transparent 1.6px 5px);
  box-shadow: inset 0 0 0 1px var(--linie-stark); }
.legende .l-heute { width: 3px; background: var(--tinte); border-radius: 1px; }
.streifen .f.winter { fill: var(--winter); } .streifen .f.ostern { fill: var(--ostern); } .streifen .f.pfingsten { fill: var(--pfingsten); }
.streifen .f.sommer { fill: var(--sommer); } .streifen .f.herbst { fill: var(--herbst); } .streifen .f.weihnachten { fill: var(--weihnachten); }
.streifen .f:hover { opacity: .75; }
/* Kalender auf den Länderseiten (Monatsblätter mit Wochentagen, durchgehend scrollbar) */
.jahr-kal.band { display: flex; gap: 1rem; overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x proximity;
  padding: .2rem .1rem .8rem; margin-top: .6rem; cursor: grab; position: relative; }
.jahr-kal.band.zieht { cursor: grabbing; user-select: none; scroll-snap-type: none; }
.monat { flex: 0 0 15.5rem; scroll-snap-align: start; background: var(--papier); border: 1px solid var(--linie); border-radius: .55rem;
  padding: .3rem .7rem .7rem; }
.monat h3 { margin: .5rem 0 .3rem; font-size: 1.15rem; }
table.roh { font-size: .88rem; }
table.roh th, table.roh td { padding: .22rem 0; text-align: center; border: 0; width: 12.5%; }
table.roh thead th { color: var(--leise); font-size: .75rem; font-weight: 600; }
table.roh .kw { color: var(--leise); font-size: .72rem; font-weight: 500; border-right: 1px solid var(--linie); }
table.roh td.we { color: var(--leise); }
table.roh td span { display: inline-block; min-width: 1.75em; padding: .1em 0; border-radius: 3px; }
table.roh td.fe.winter { background-color: color-mix(in srgb, var(--winter) 38%, transparent); }
table.roh td.fe.ostern { background-color: color-mix(in srgb, var(--ostern) 38%, transparent); }
table.roh td.fe.pfingsten { background-color: color-mix(in srgb, var(--pfingsten) 38%, transparent); }
table.roh td.fe.sommer { background-color: color-mix(in srgb, var(--sommer) 45%, transparent); }
table.roh td.fe.herbst { background-color: color-mix(in srgb, var(--herbst) 40%, transparent); }
table.roh td.fe.weihnachten { background-color: color-mix(in srgb, var(--weihnachten) 34%, transparent); }
table.roh td.fe { color: var(--tinte); font-weight: 600; }
table.roh td.ft span { box-shadow: inset 0 0 0 2px var(--tinte); font-weight: 750; }
.l-ft { box-shadow: inset 0 0 0 2px var(--tinte); }
table.roh td.vorbei { background-image: repeating-linear-gradient(135deg, var(--schraffur) 0 1.4px, transparent 1.4px 5px); color: var(--leise); }
table.roh td.heute { box-shadow: inset 3px 0 0 var(--tinte); font-weight: 800; }
.kal-steuer { display: flex; flex-wrap: wrap; align-items: center; gap: .45rem; margin: .8rem 0 .2rem; }
.kal-steuer[hidden] { display: none; }
.kal-steuer button { font: 600 .95rem var(--text); padding: .45rem .85rem; border-radius: 2rem; border: 1px solid var(--linie-stark);
  background: var(--papier); color: var(--tinte); cursor: pointer; }
.kal-steuer button:hover { border-color: var(--tafel); }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

/* Länderkürzel beim waagerechten Scrollen festhalten (heute.js) */
.laender-fest { position: sticky; left: 0; height: 0; z-index: 2; pointer-events: none; }
.streifen .laender-fest svg { display: block; min-width: 0; background: var(--papier); box-shadow: 3px 0 6px -3px rgba(0, 0, 0, .25); }
/* Lange Zeitleiste der Startseite (fester Maßstab, waagerecht scrollbar) */
.streifen.lang { overflow-x: auto; overscroll-behavior-x: contain; cursor: grab; }
.streifen.lang.zieht { cursor: grabbing; user-select: none; }
.streifen.lang svg { width: auto; height: auto; max-width: none; min-width: 0; }
.streifen .m.j { stroke: var(--tinte); stroke-width: 1.4; stroke-opacity: .55; }
.streifen .offen { fill: var(--leise); font: italic 600 13px var(--text); text-anchor: middle; }
.zeit-knoepfe { display: flex; flex-wrap: wrap; gap: .5rem; margin: 1rem 0 .2rem; }
.zeit-knoepfe[hidden] { display: none; }
.zeit-knoepfe button { font: 600 .95rem var(--text); padding: .5rem .9rem; border-radius: 2rem; border: 1px solid var(--linie-stark);
  background: var(--papier); color: var(--tinte); cursor: pointer; }
.zeit-knoepfe button:hover { border-color: var(--tafel); }
table.naechste td { white-space: normal; }
.legende { display: flex; flex-wrap: wrap; gap: .3rem 1.3rem; list-style: none; padding: 0; font-size: .9rem; max-width: none; margin: 1rem 0 0; }
.legende span, .arten span { display: inline-block; width: .95rem; height: .95rem; border-radius: 3px; vertical-align: -.12rem; margin-right: .45rem; }
.f-winter { background: var(--winter); } .f-ostern { background: var(--ostern); } .f-pfingsten { background: var(--pfingsten); }
.f-sommer { background: var(--sommer); } .f-herbst { background: var(--herbst); } .f-weihnachten { background: var(--weihnachten); }

/* Tabellen */
.table-wrapper { overflow-x: auto; margin: 1rem 0; background: var(--papier); border: 1px solid var(--linie); border-radius: .7rem; }
table { border-collapse: collapse; width: 100%; font-size: .97rem; }
table.jahr { min-width: 56rem; }
caption { text-align: left; padding: .8rem 1rem .2rem; color: var(--leise); font-size: .9rem; }
th, td { padding: .6rem .9rem; text-align: left; border-bottom: 1px solid var(--linie); vertical-align: top; }
thead th { font-size: .85rem; color: var(--leise); font-weight: 650; white-space: nowrap; }
tbody tr:last-child > * { border-bottom: 0; }
tbody th { font-weight: 650; white-space: nowrap; }
table.jahr td { white-space: nowrap; }
table.jahr td.so { font-weight: 700; }
.keine { color: var(--leise); }
.zwei { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 26rem), 1fr)); gap: 0 1rem; }

/* Länder und Arten */
.laender { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(14.5rem, 1fr)); gap: .6rem; max-width: none; }
.laender a { display: grid; gap: .15rem; background: var(--papier); border: 1px solid var(--linie); border-left: 5px solid var(--sommer);
  border-radius: .55rem; padding: .7rem 1rem; text-decoration: none; color: var(--tinte); }
.laender a:hover { border-color: var(--tafel); border-left-color: var(--sommer); }
.l-name { font: 750 1.08rem/1.2 var(--titel); }
.l-sommer { font-size: .88rem; color: var(--leise); }
.arten { list-style: none; padding: 0; display: flex; flex-wrap: wrap; gap: .5rem; max-width: none; }
.arten a { display: inline-block; padding: .5rem .95rem; background: var(--papier); border: 1px solid var(--linie-stark); border-radius: 2rem;
  text-decoration: none; color: var(--tinte); font-weight: 600; }
.arten a:hover { border-color: var(--tafel); }
.downloads { list-style: none; padding: 0; }
.downloads a { display: inline-block; padding: .55rem 1rem; border-radius: .45rem; background: var(--tafel); color: var(--on-accent);
  text-decoration: none; font-weight: 650; }
@media (prefers-color-scheme: dark) { .downloads a { color: #0f1714; } }
.downloads a::before { content: "↓ "; }

details { background: var(--papier); border: 1px solid var(--linie); border-radius: .55rem; margin: .5rem 0; max-width: 72ch; }
summary { cursor: pointer; padding: .8rem 1rem; font-weight: 650; }
details > :not(summary) { padding: 0 1rem; }
details[open] summary { border-bottom: 1px solid var(--linie); margin-bottom: .2rem; }
.sources li { margin: .4rem 0; }
.note { background: var(--tafel-hell); padding: .7rem 1rem; border-radius: .4rem; }

footer.site { border-top: 1px solid var(--linie); background: var(--papier); font-size: .92rem; color: var(--leise); }
footer.site .wrap { padding-block: 1.4rem 2rem; }
footer.site ul { display: flex; flex-wrap: wrap; gap: .3rem 1.2rem; list-style: none; padding: 0; margin: .6rem 0 0; }
footer.site a { color: var(--leise); }

@media (max-width: 40rem) {
  body { font-size: 1rem; }
  th, td { padding: .5rem .65rem; }
  tbody th { white-space: normal; }
  .streifen { padding: .5rem .4rem .4rem; margin-inline: -.6rem; border-radius: .5rem; overflow-x: auto; }
  .streifen svg { min-width: 42rem; }
  .streifen figcaption { position: sticky; left: 0; }

  .streifen .mt { font-size: 17px; } .streifen .lt { font-size: 17px; } .streifen .heute-text { font-size: 17px; }
  .streifen.lang .mt, .streifen.lang .lt, .streifen.lang .heute-text { font-size: 13px; }
  nav.main ul { gap: .1rem .85rem; }
}
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }

/* Tooltips für Diagramme (tooltip.js) */
.tip { position: fixed; z-index: 50; max-width: min(18rem, calc(100vw - 16px)); padding: .4rem .65rem; border-radius: .4rem;
  background: var(--tinte); color: var(--papier); font: 600 .86rem/1.35 var(--text); pointer-events: none;
  box-shadow: 0 4px 14px rgba(0, 0, 0, .22); }
.tip[hidden] { display: none; }
[data-tip] { cursor: pointer; }
rect.tip-aktiv { stroke: var(--tinte); stroke-width: 2.5; }
span.tip-aktiv { outline: 2px solid var(--tinte); outline-offset: 1px; }
.streifen .f.tip-aktiv { opacity: 1; }

/* Überschrift der Tabelle „nächste …“ wiederholt die Zwischenüberschrift: nur für Vorlesehilfen */
table.naechste caption { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
table.naechste td.nw { white-space: normal; min-width: 6.2em; }
@media (max-width: 40rem) { table.naechste th, table.naechste td { padding: .5rem .3rem; font-size: .88rem; } table.naechste th:first-child, table.naechste td:first-child { padding-left: .6rem; } table.naechste td.nw { min-width: 5.2em; } }
