/* Härtel HP15 (RELAUNCH-01 Block E): nur was keine globale Breakdance-Klasse sein kann.
   1. Zwei Abfragen des Design Systems ohne Breakdance-Breakpoint (bundle.css, Werte unverändert): Fuß einspaltig bis 599 px,
      Handymenü als Leiste von 420 px rechts von 600 bis 1239 px (HP91, vorher 1119).
   2. Seitenrollen bei offenem Handymenü gesperrt (der Sprunglink ht-skip ist eine globale Klasse, scripts/dev/e_klassen.py).
   3. Kopf unter der Werkzeugleiste angemeldeter Nutzer (Breakdance-Anleitung „Sticky and fixed elements“). */
/* Spezifität mit dem Elternteil: die globalen Breakdance-Klassen stehen nach dieser Datei und gewinnen sonst (gemessen 18.11.: Fuß bei 390 px zweispaltig) */
@media (max-width:599px){.ht-fuss .ht-fuss__oben{grid-template-columns:1fr;padding:var(--space-7) 0 var(--space-6)}}
@media (min-width:600px) and (max-width:1239px){html:root .ht-kopf .ht-kopf__handy{left:auto;width:420px;border-left:1px solid var(--line);box-shadow:var(--shadow-overlay)}}
/* nur html sperren: overflow am body macht ihn zum Rollbehälter, der klebende Kopf rollt dann weg (gemessen 18.11. bei gerollter Seite) */
html.ht-menue-offen{overflow:hidden;scrollbar-gutter:stable}
/* HP81 (K2-2): Rollen im Menü schiebt die Seite nicht mit */
.ht-kopf .ht-kopf__handy{overscroll-behavior:contain}
/* Breakdance legt um jeden Shortcode div.bde-shortcode; in Kopf und Fuß soll das Markup wie die Leinwand direkt im Layout stehen */
.ht-kopf .bde-shortcode,.ht-fuss .bde-shortcode{display:contents}
/* HP26 (RELAUNCH-02 Paket G, G-2): eine Quelle für den Abstand unter dem festen Kopf. Kopfhöhe plus 1 px Rand, unter 1240 px (HP91) der
   Handykopf, dazu die Admin-Leiste (WordPress setzt --wp-admin--admin-bar--height nur bei sichtbarer Leiste: 32 px, bis 782 px 46 px).
   Alle sticky-Teile der Leinwand nutzen --ht-kopf-unten (d_fahrzeug_theme.py schreibt top:…var(--header-height)… um), Ankersprünge
   über scroll-padding-top. */
:root{--ht-kopf-unten:calc(var(--wp-admin--admin-bar--height, 0px) + var(--header-height) + 1px)}
@media (max-width:1239px){:root{--ht-kopf-unten:calc(var(--wp-admin--admin-bar--height, 0px) + var(--header-height-phone) + 1px)}}
/* HP91 (K4b): Handymenü bis 1239 px. Regeln aus bundle.css (Kopf, max-width:1119px), unverändert, mit html:root (Vorrang vor selectors.css) */
@media (min-width:1120px) and (max-width:1239px){
 html:root .ht-kopf__in{height:var(--header-height-phone);gap:var(--space-4)}
 html:root .ht-kopf__logo img{height:40px}
 html:root .ht-kopf__nav,html:root .ht-kopf__tel span:not(.ht-i){display:none}
 html:root .ht-kopf__aktion{margin-left:auto}
 html:root .ht-kopf__tel{width:var(--control-height);height:var(--control-height);justify-content:center;border:1px solid var(--line-strong);border-radius:var(--radius-s)}
 html:root .ht-kopf__menue{display:inline-flex}
 html:root .ht-kopf__marken{padding-left:var(--space-4);gap:var(--space-3)}
 html:root .ht-kopf__marken img{height:32px}
 html:root .ht-kopf__handy{display:block;position:absolute;top:100%;left:0;right:0;height:calc(100vh - var(--header-height-phone));overflow-y:auto;overscroll-behavior:contain;background:var(--surface);border-top:1px solid var(--line)}
 html:root .ht-kopf__schleier{display:block;position:absolute;top:100%;left:0;right:0;height:calc(100vh - var(--header-height-phone));background:rgba(0,17,28,.48)}
 html:root .ht-kopf__handyliste,html:root .ht-kopf__handyunter{margin:0;padding:0;list-style:none}
 html:root .ht-kopf__handypunkt{display:flex;align-items:center;justify-content:space-between;gap:var(--space-3);width:100%;min-height:56px;padding:0 var(--gutter);border:0;border-bottom:1px solid var(--line);background:none;color:var(--ink);font:700 18px/24px var(--font-text);text-align:left;text-decoration:none;cursor:pointer}
 html:root .ht-kopf__handypunkt .ht-i{width:20px;height:20px;color:var(--brand)}
 html:root .ht-kopf__handypunkt[aria-expanded="true"]{color:var(--brand)}
 html:root .ht-kopf__handyunter{padding:var(--space-2) 0;background:var(--surface-alt);border-bottom:1px solid var(--line)}
 html:root .ht-kopf__handyunter a{display:flex;align-items:center;min-height:var(--tap-min);padding:0 var(--gutter) 0 calc(var(--gutter) + var(--space-4));color:var(--ink);font:400 16px/24px var(--font-text);text-decoration:none}
 html:root .ht-kopf__handyfuss{display:grid;gap:var(--space-3);padding:var(--space-5) var(--gutter) var(--space-7)}
 html:root .ht-kopf__handymarken{display:flex;align-items:center;gap:var(--space-5);margin-top:var(--space-3);padding-top:var(--space-5);border-top:1px solid var(--line)}
 html:root .ht-kopf__handymarken img{height:36px;width:auto;display:block}
 html:root .ht-kopf__menue[aria-expanded="true"]{border-color:var(--brand);color:var(--brand)}
}
.admin-bar .ht-kopf{top:var(--wp-admin--admin-bar--height, 0px)}
html{scroll-padding-top:calc(var(--ht-kopf-unten) + 16px)}
/* HP33 A-32: Fettbreite reservieren, damit der aktive (fette) Punkt die übrigen nicht verschiebt */
.ht-kopf__wort{display:inline-flex;flex-direction:column}
.ht-kopf__wort::after{content:attr(data-t) / "";height:0;overflow:hidden;visibility:hidden;font-weight:700;pointer-events:none}
/* HP33 A-34, A-42: Fuß zwischen 768 und 1023 px ausgewogen (Standort links über zwei Zeilen, Navigation und Rechtliches rechts),
   Förderhinweis nie beschnitten; Fokusrahmen von „Powered by“ mit Abstand zum Logo */
@media (min-width:768px) and (max-width:1023px){.ht-fuss__oben{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:var(--space-6) var(--space-5)}.ht-fuss__oben>:nth-child(1){grid-row:1/3}.ht-fuss__oben>:nth-child(3){grid-column:2}}
.ht-fuss__oben img{max-width:100%;height:auto}
.ht-fuss__powered{padding:0;margin:0}
.ht-fuss__powered:focus-visible{outline-offset:0}
.ht-kopf__handypunkt[aria-current="page"]{color:var(--brand);font-weight:700}
/* Härtel HP54 (RELAUNCH-03 STOP 3d, B6, 21.11.2026): Sprungziele (/werkstatt/#form u. a.) landen direkt unter dem Kopf. Das Theme-Skript
   js/scripts.js (adjustAnchor, bei load und hashchange) scrollt auf „Ziel minus 300 px“, außer das Ziel hat ein scroll-margin-top; dann
   nimmt es diesen Wert. Gemessen 21.11. vorher: #form bei 1440 px 300 statt 97 px unter der Fensteroberkante, bei 390 px 160 statt 81 px.
   Ziele mit eigener Regel (Fahrzeugseiten, :is(.ht,#haertel-fz) …, Kopf plus 12 px) behalten sie, weil diese spezifischer ist. */
:target{scroll-margin-top:calc(var(--ht-kopf-unten) + var(--space-4))}
/* Härtel HP57 (3e-3, Fjodor 21.11.2026): auch Angebots- und Fahrzeugseiten 16 px unter dem Kopf. Die Sonderregel „Kopf plus 12 px“ der
   Leinwand steckt außer in haertel-fahrzeuge.css (dort entfernt, Erzeuger d_fahrzeug_theme.py) in vier globalen Breakdance-Klassen
   (selectors.css lädt nach dem Theme); html:root gewinnt, wie bei den übrigen Theme-Regeln gegen globale Klassen. Gilt auch für
   scrollIntoView auf diese Abschnitte. */
html:root :target,html:root .lw-ang-gruppe,html:root .lw-vdp__abschnitt,html:root .lw-rat__karte,html:root .lw-hinweis-karte{scroll-margin-top:calc(var(--ht-kopf-unten) + var(--space-4))}

/* HP61 (K1 B2, 23.11.2026): Herstellerlogos im Kopf sind Links (Vorlage 62, ContainerLink 116 bis 118 um die Bilder 111 bis 113).
   Die globale Klasse ht-kopf__marken blendet unter 768 px img:not(:first-child) aus; jedes Bild ist jetzt erstes Kind seines Links,
   deshalb blendet diese Regel die Links aus (sonst bliebe ein leerer, fokussierbarer Link). */
html:root .ht-kopf__marken>a{display:inline-flex;align-items:center;border-radius:var(--radius-s)}
@media (max-width:767px){html:root .ht-kopf__marken>a:not(:first-child){display:none}}

/* HP62 (K1 B3, 23.11.2026, Kundenpunkte 10 und 2): Bildausschnitte.
   Werkstatt 224, Bühnenbild werkstatt-team.webp (1722 x 692) in figure 101: alle vier Köpfe ganz bei 360 bis 2560 px. Köpfe liegen im
   Original zwischen x 255 und 1490, y 0 und 390. Unter 1024 px Format 2:1 (sichtbar 1384 von 1722 px Breite, ganze Höhe), ab 1920 px
   mitwachsende Höhe (bei 2560 px 589 px, sichtbar y 0 bis 396), Ausrichtung immer oben. */
html:root .bde-f-container-224-101 img{object-position:50% 0%}
@media (max-width:1023px){html:root .bde-f-container-224-101{height:auto}html:root .bde-f-container-224-101 img{height:auto;aspect-ratio:2/1}}
@media (min-width:1920px){html:root .bde-f-container-224-101{height:max(520px,23vw)}}
/* Startseite 345, Hausfoto in .ht-bewertung__bild (figure 233): Ausschnitt unten (Fahrzeugreihe y 560 bis 675 von 737 ganz, Himmel weicht).
   Ab 1024 px liegt der Autohauskenner-Kasten über dem Bild; unten rechts verdeckte er die rechten Fahrzeugfronten, deshalb an die
   obere rechte Bildkante (gleicher Versatz wie zuvor unten). Unter 1024 px steht er unter dem Bild, unverändert. */
html:root .ht-bewertung__bild img{object-position:100% 100%}
@media (min-width:1024px){html:root .ht-bewertung__siegel{top:calc(-1 * var(--space-6));bottom:auto}}

/* HP69 (K1 B11, Kundenpunkt 12, K1-6 Fjodor 23.11.2026): Knopf „Nach oben“, Variante B: weiß, Rahmen und Schrift Härtel-Blau, Rundung
   4 px (HR-1), Symbol aus dem eigenen Satz, ab 768 px mit Text, darunter nur Symbol (aria-label), Zielgröße 48 px (control-height).
   Rand nach R19: unter 768 px 16 px (gutter-phone), sonst an der Containerkante. Über der Handyleiste (Höhe aus --ht-handyleiste-hoehe,
   abgeleitet aus Polster und Knopfhöhe der Leiste). Ein- und Ausblenden 180 ms per opacity und transform; ohne Bewegung bei
   prefers-reduced-motion; im Druck nie. Verhalten in assets/haertel-oben.js. */
:root{--ht-handyleiste-hoehe:calc(1px + var(--space-2) + var(--control-height) + var(--space-2) + env(safe-area-inset-bottom))}
html:root .ht-oben{position:fixed;right:var(--gutter-phone);bottom:var(--gutter-phone);z-index:90;display:inline-flex;align-items:center;justify-content:center;gap:var(--space-2);min-width:var(--control-height);height:var(--control-height);margin:0;padding:0;border:1px solid var(--blau);border-radius:var(--radius-s);background:var(--weiss);color:var(--blau);font:700 16px/24px var(--font-text);box-shadow:var(--shadow-raised);cursor:pointer;opacity:0;visibility:hidden;transform:translateY(var(--space-2));transition:opacity .18s ease,transform .18s ease,visibility 0s linear .18s}
html:root .ht-oben.ist-sichtbar{opacity:1;visibility:visible;transform:none;transition:opacity .18s ease,transform .18s ease,visibility 0s}
html:root .ht-oben:hover{background:var(--surface-alt)}
html:root .ht-oben:focus-visible{outline:2px solid var(--blau);outline-offset:2px}
html:root .ht-oben .ht-i{width:24px;height:24px}
html:root .ht-oben__text{display:none}
.ht-oben__marke{position:absolute;top:200vh;left:0;width:1px;height:1px;pointer-events:none}
@media (min-width:768px){html:root .ht-oben{right:max(var(--gutter),calc((100vw - var(--container)) / 2));bottom:var(--space-5);padding:0 var(--space-4)}html:root .ht-oben__text{display:inline}}
@media (max-width:1119px){html:root:has(.ht-handyleiste) .ht-oben{bottom:calc(var(--ht-handyleiste-hoehe) + var(--space-4))}}
@media (min-width:768px) and (max-width:1119px){html:root:has(.ht-handyleiste) .ht-oben{bottom:calc(var(--ht-handyleiste-hoehe) + var(--space-5))}}
@media (prefers-reduced-motion:reduce){html:root .ht-oben,html:root .ht-oben.ist-sichtbar{transition:none;transform:none}}
@media print{html:root .ht-oben{display:none!important}}

/* HP74 (K1c-1, Befund Fjodor 23.11.): nach „Nach oben“ liegt der Fokus auf dem Kopf (.ht-oben-ziel, tabindex -1). Bei Zeiger-Bedienung
   kein Ring, bei Tastatur ein Ring innen (der Kopf steht am oberen Rand). Der Sprunglink „Zum Inhalt springen“ erscheint nur noch bei
   :focus-visible (Tastatur); die globale Klasse ht-skip zeigt ihn sonst bei jedem :focus. */
html:root .ht-oben-ziel:focus:not(:focus-visible){outline:0}
html:root .ht-oben-ziel:focus-visible{outline:2px solid var(--focus);outline-offset:-2px}
html:root .ht-skip:focus:not(:focus-visible){top:-100px}
