/* UI-Umsetzung 25.11.2026: Stile dieses Bereichs. Gemeinsame Regeln (Breite, Schrift, Kopfzeile, Tabellen) stehen in styles.css. */
/* Ladekarte /ladestationen/ und /einbetten/ladekarte/ (H5, M4, M8, M10, N3). Überschreibt die .station-*- und .embed-*-Regeln aus styles.css. */

/* ---------- Seitenkopf (M4): Überschrift über die ganze Breite, Zähler rechts neben dem Einleitungstext ---------- */
.station-intro .eyebrow{font-size:.75rem}
.station-intro h1{max-width:none}
@media(min-width:1100px){
.station-intro{display:grid;grid-template-columns:minmax(0,1fr) minmax(250px,330px);column-gap:56px;align-items:start}
.station-intro>*{grid-column:1/-1}
.station-intro>.lead,.station-intro>.notice,.station-intro>.station-embed-link{grid-column:1}
.station-intro>.station-counts{grid-column:2;grid-row:4/span 3;flex-direction:column;gap:10px;margin:4px 0 0}
html[lang="en"] .station-intro>.station-counts{grid-row:3/span 3}
.station-counts li{display:flex;align-items:baseline;gap:10px;padding:12px 16px;font-size:.9rem}
.station-counts strong{font-family:var(--serif);font-weight:400;font-size:2.1rem;line-height:1;min-width:2.2ch;margin:0}
}

/* ---------- Karte und Liste: Karte läuft mit, Liste am Desktop zweispaltig ---------- */
@media(min-width:901px){
.station-map-figure:not(.is-full){top:calc(var(--sticky-top,0px) + 16px);max-height:calc(100vh - 32px - var(--sticky-top,0px))}
.station-map{max-height:calc(100vh - 215px - var(--sticky-top,0px))}
}
.station-listbar{top:var(--sticky-top,0px)}
/* Die Karte bleibt das Hauptelement: mindestens die halbe Inhaltsbreite (bestehende Prüfung in planning-tools.mjs). */
@media(min-width:1400px){
.station-layout{grid-template-columns:minmax(0,calc(50% + 40px)) minmax(0,1fr)}
.station-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));column-gap:14px;align-items:start}
.station-list>:not(.station-card){grid-column:1/-1}
.station-list .station-card{margin:0 0 14px}
.station-list .station-card dt{flex-basis:5.4rem}
.station-list .station-card dd{flex-basis:10rem}
}

/* Layoutsprung (M10): Filter, Leiste und Kartenknöpfe sind ohne Skript ausgeblendet. Läuft Skript, steht ihr Platz schon
   vor dem Laden fest; das Skript entfernt nur noch das hidden-Attribut. !important wegen [hidden]{display:none!important}. */
@media (scripting:enabled){
.station-filter[hidden]{display:grid!important;visibility:hidden}
.station-listbar[hidden]{display:block!important;visibility:hidden}
.station-map-tools[hidden]{display:flex!important;visibility:hidden}
}

/* ---------- Standortkarte: eingeklappt Status, Name, Ort, Betreiber, Anschlüsse ---------- */
.station-card{display:flow-root;padding:14px 16px}
.station-card h3{font-size:1.08rem;line-height:1.3;margin:4px 0 2px}
.station-status{font-size:.75rem;line-height:1.45}
.station-place{margin:0 0 6px;line-height:1.5}
.station-card dl{font-size:.82rem;line-height:1.45}
/* Bezeichnung und Wert nebeneinander, wenn der Wert mindestens 12rem Platz hat; sonst (320 px, große Schrift) untereinander. */
.station-card dl div{display:flex;flex-wrap:wrap;column-gap:10px;row-gap:2px;padding:4px 0}
.station-card dt{flex:0 0 6.2rem}
.station-card dd{flex:1 1 12rem;min-width:0}
.station-key{margin:0}
.station-card .station-maplink{float:left;max-width:60%;margin:0 12px 0 0;line-height:1.35}
.station-card .station-maplink.is-list-only{display:flex;align-items:center;min-height:44px;font-size:.8rem}
.station-show{display:inline-flex;align-items:center;min-height:44px;padding:0}
.station-card .station-approx{display:block;margin:-8px 0 6px;font-size:.78rem}
.station-more>summary{display:flex;align-items:center;gap:8px;width:fit-content;white-space:nowrap;min-height:44px;margin-left:auto;padding:0 2px;font-size:.85rem;font-weight:700;color:var(--green);cursor:pointer;list-style:none}
.station-more>summary::-webkit-details-marker{display:none}
.station-more>summary::after,.station-fold>summary::after{content:"";flex:none;width:7px;height:7px;border-right:2px solid currentColor;border-bottom:2px solid currentColor;transform:translateY(-2px) rotate(45deg)}
.station-more[open]>summary::after,.station-fold[open]>summary::after{transform:translateY(2px) rotate(-135deg)}
.station-more>summary:focus-visible,.station-fold>summary:focus-visible{outline:3px solid #172e28;outline-offset:2px}
.station-more>:not(summary){clear:both}
/* Der Inhaltsbereich eines eingeklappten <details> ist ein eigener Formatierungskontext und wiche sonst dem schwebenden
   Kartenlink aus (nur 115 px breit gemessen: Scheinüberlauf und Scheinumbrüche in Messungen). */
.station-more::details-content{clear:both}
.station-more[open]>summary{margin-bottom:4px}
.station-place-road{font-size:.85rem;color:var(--muted);line-height:1.5;margin:0 0 6px}
.station-note{font-size:.82rem}
.station-tariff{margin:8px 0 0}
.station-tariff a{display:inline-flex;align-items:center;min-height:44px;font-size:.85rem;font-weight:600}
.station-source{font-size:.78rem}
.station-card:target{scroll-margin-top:calc(var(--sticky-top,0px) + 80px)}

/* ---------- Karte: Schrift, Infofeld, Tippflächen (M8) ---------- */
.station-map-figure figcaption{font-size:.76rem}
.station-road-label{font-size:calc(var(--px,.42) * 12px)}
/* Städtenamen 12 px; bis 360 px Breite (Karte rund 250 px) bleiben sie bei 10,5 px, sonst entfallen in dichten Gebieten zu viele. */
@media(min-width:361px) and (max-width:400px){.station-city text{font-size:calc(var(--px,.42) * 12px)}}
.station-map-close{width:44px;height:44px;right:2px;top:2px}
.station-map-also button{min-height:44px}
.station-map-more{display:inline-flex;align-items:center;min-height:44px;padding:0}
@media(max-width:900px){
.station-filter input[type=search],.station-filter select{min-height:44px}
.station-filter .finder-check{display:flex;align-items:center;gap:8px;min-height:44px}
}

/* ---------- Abschnitte unter der Liste: eingeklappt, Überschrift sichtbar ---------- */
.stations-text.article-layout.is-single{grid-template-columns:minmax(0,1fr);justify-content:stretch;padding-top:16px}
.stations-text .prose>p,.stations-text .prose>.notice,.stations-text .prose>section>p,.stations-text .prose>section>ul,.stations-text .station-fold-body>p,.stations-text .station-fold-body>ul,.stations-text .station-fold-body>ol,.stations-text .station-fold-body>.example,.stations-text .ladekarten-preise>p,.stations-text .ladekarten-preise>ul{max-width:var(--measure)}
.stations-text .prose>.notice{margin-bottom:28px}
.station-fold{border-top:1px solid var(--line)}
.station-fold:has(+:not(.station-fold)),.station-fold:last-child{border-bottom:1px solid var(--line)}
.station-fold>summary{display:flex;align-items:center;justify-content:space-between;gap:20px;min-height:56px;padding:10px 4px 10px 0;cursor:pointer;list-style:none;color:var(--ink)}
.station-fold>summary::-webkit-details-marker{display:none}
.station-fold>summary::after{width:10px;height:10px;margin-right:6px}
.prose .station-fold>summary h2{margin:0;font-size:1.45rem;line-height:1.3}
.station-fold>summary:hover h2{text-decoration:underline;text-underline-offset:4px;text-decoration-thickness:1px}
.station-fold[open]>summary{margin-bottom:6px}
.station-fold-body{padding-bottom:24px}
.station-fold-body>:first-child{margin-top:0}
.stations-text .prose h2#aenderungen{margin-top:36px}
/* Zeichnung im Kasten mittig und mindestens halb so breit wie der Kasten (bestehende Darstellungsprüfung D-05/D-10). */
.stations-text .europe-visual{margin:28px 0;max-width:52rem}
.stations-text .europe-visual>.diagram-caption{max-width:none}
.stations-text .eyebrow,.stations-text .photo-story-copy .eyebrow,.stations-text .visual-heading .eyebrow{font-size:.75rem}
.stations-text .prose .diagram-caption{font-size:.8rem}
.stations-text figcaption{font-size:.8125rem}
.stations-text .visual-tag{font-size:.75rem}
@media(max-width:360px){
.station-card{padding:12px}
.station-card .station-maplink{margin-right:8px}
.station-more>summary{gap:6px;font-size:.8rem}
}
@media(max-width:900px){.station-listbar .station-result{flex:1 1 120px}}

/* Breite Teile am Desktop: Änderungsliste zweispaltig. Die Zeichnung bleibt mittig (bestehende Darstellungsprüfung). */
@media(min-width:1100px){
.stations-text #aenderungen+ul{columns:2;column-gap:56px;max-width:none}
.stations-text #aenderungen+ul>li{break-inside:avoid-column}
}

/* Reine Textabschnitte am Desktop zweispaltig; Abschnitte mit Tabellen oder Fotos behalten die volle Breite. */
@media(min-width:1100px){
.station-fold-body:not(:has(.table-scroll,.photo-story,.example,figure)){columns:2;column-gap:56px}
.station-fold-body:not(:has(.table-scroll,.photo-story,.example,figure))>*{break-inside:avoid-column;max-width:none}
.station-fold-body:not(:has(.table-scroll,.photo-story,.example,figure))>ol,.station-fold-body:not(:has(.table-scroll,.photo-story,.example,figure))>ul{break-inside:auto}
}

/* ---------- Ladekarte zum Einbinden (N3): Titelzeile, Karte und Fußzeile auf einer linken Kante ---------- */
.embed-head,.embed-foot{max-width:1344px;margin-inline:auto}
@media(min-width:1600px){.embed-head,.embed-foot{max-width:1480px}}
.embed-head p,.embed-foot p{font-size:.8rem}
.embed-page .station-intro{display:block}

/* ---------- Trefferflächen der Kartenpunkte (M8): Voronoi-Zelle bis 22 px Radius; der Kreis bleibt nur Fokusring ---------- */
.station-hit{pointer-events:none}
.station-hit-area{fill:transparent;stroke:none}
.station-marker.is-dimmed .station-hit-area{display:none}
.station-map-figure figcaption{font-size:.8125rem}

/* ---------- Schnellwahl „In Betrieb · mit Auflieger“ (Umbau 29.11.2026): Knopf mit aria-pressed, gedrückt mit Haken ---------- */
.station-filter .station-quick{grid-column:1/-1;justify-self:start;display:inline-flex;align-items:center;gap:8px;min-height:44px;max-width:100%;padding:0 16px;border:1px solid #8ea394;border-radius:22px;background:white;color:var(--ink);font:inherit;font-size:.85rem;font-weight:600;line-height:1.2;text-align:left;cursor:pointer}
.station-filter .station-quick::before{content:"";flex:none;width:14px;height:14px;border:2px solid currentColor;border-radius:50%}
.station-filter .station-quick[aria-pressed="true"]{background:var(--green);border-color:var(--green);color:white}
.station-filter .station-quick[aria-pressed="true"]::before{content:"✓";content:"✓"/"";width:auto;height:auto;border:0;border-radius:0;font-weight:700}
.station-filter .station-quick:focus-visible{outline:3px solid #587b20;outline-offset:3px}
