/* Header: weiße Leiste über die ganze Breite, großes Logo. Seit 30.11.2026 sticky, wird beim Scrollen kleiner (bleibt weiß) */
:root {
  --ts-hd-h: 6rem;
}

html {
  scroll-padding-top: calc(var(--wp-admin--admin-bar--height, 0px) + var(--ts-hd-h, 6rem) + 1rem);
}

#brx-header {
  position: sticky;
  top: var(--wp-admin--admin-bar--height, 0px);
  z-index: 100;
  background-color: var(--white, #FFFFFF);
  border-bottom: var(--border-s, 1px) solid var(--line, #E5E5E5);
  transition: box-shadow 0.3s ease, margin 0.3s ease;
}

@media (max-width: 600px) {
  #brx-header {
    top: 0;
  }
}

/* Beim Scrollen: bleibt weiß, wird flacher, Logo kleiner, leichter Schatten.
   margin-bottom gleicht die gesparte Höhe aus, damit der Inhalt nicht springt. */
#brx-header:has(.ts-hd.is-solid) {
  margin-bottom: 1.75rem;
  box-shadow: var(--shadow-m, 0 10px 30px rgba(17, 17, 17, 0.08));
}

.ts-hd,
.ts-hd__box {
  transition: padding 0.3s ease, min-height 0.3s ease;
}

.ts-hd.is-solid {
  padding-block: 0.5rem;
}

.ts-hd.is-solid .ts-hd__box {
  min-height: 3.25rem;
}

.ts-hd.is-solid .ts-hd__logo svg {
  height: 3.25rem;
}

.ts-hd.is-solid .ts-hd__logo img {
  height: 2.75rem;
}

.ts-hd .ts-hd__cta {
  transition: padding 0.3s ease, background-color 0.3s ease, border-color 0.3s ease, color 0.3s ease;
}

.ts-hd.is-solid .ts-hd__cta {
  padding-block: 0.875rem;
}

@media (max-width: 991px) {
  #brx-header:has(.ts-hd.is-solid) {
    margin-bottom: 1.25rem;
  }

  .ts-hd.is-solid {
    padding-block: 0.625rem;
  }

  .ts-hd.is-solid .ts-hd__box {
    min-height: 2.75rem;
  }

  .ts-hd.is-solid .ts-hd__logo svg {
    height: 2.75rem;
  }

  .ts-hd.is-solid .ts-hd__burger {
    margin-block: -0.25rem;
  }
}

@media (max-width: 767px) {
  .ts-hd.is-solid .ts-hd__logo img {
    height: 2.25rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  #brx-header,
  .ts-hd,
  .ts-hd__box {
    transition: none;
  }
}

#brx-header .brxe-section:has(.ts-hd) {
  padding: 0;
  background-color: transparent;
}

#brx-header .brxe-section:has(.ts-hd) > .brxe-container {
  width: 100%;
  max-width: none;
}

/* max-width = Inhalt plus Seitenabstand, damit das Logo in der Flucht der Sections steht (30.11.2026) */
.ts-hd {
  box-sizing: border-box;
  width: 100%;
  max-width: calc(var(--div-max, 1450px) + 2 * var(--section-sides, 2rem));
  margin-inline: auto;
  padding: 0.75rem var(--section-sides, 1.5rem);
}

.ts-hd__box {
  display: flex;
  align-items: center;
  gap: var(--space-l, 2rem);
  min-height: 4.5rem; /* gleiche Header-Höhe auf allen Seiten, auch mit kleinerem Logo (Tank Clean) */
  color: var(--black, #111111);
}

.ts-hd__logo {
  display: block;
  flex-shrink: 0;
  color: inherit;
}

.ts-hd__logo svg,
.ts-hd__logo img {
  display: block;
  width: auto;
  max-width: none;
  height: 4.5rem;
}

/* Logo schrumpft beim Hover leicht (30.11.2026) */
.ts-hd__logo svg,
.ts-hd__logo img {
  transform-origin: left center;
  transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1), height 0.3s ease;
}

@media (hover: hover) {
  .ts-hd__logo:hover svg,
  .ts-hd__logo:hover img {
    transform: scale(0.92);
  }
}

.ts-hd__logo:focus-visible svg,
.ts-hd__logo:focus-visible img {
  transform: scale(0.92);
}

@media (prefers-reduced-motion: reduce) {
  .ts-hd__logo svg,
  .ts-hd__logo img {
    transition: none;
  }
}

.ts-hd__nav {
  display: flex;
  align-items: center;
  gap: var(--space-l, 2rem);
  margin-left: auto;
}

.ts-hd .ts-hd__nav a {
  font-size: var(--fs-body-m, clamp(0.9375rem, 0.9rem + 0.15vw, 1rem));
  font-weight: 600;
  line-height: 1.4;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  white-space: nowrap;
  text-decoration: none;
  color: inherit;
  transition: color 0.3s ease;
}

.ts-hd .ts-hd__nav a:hover,
.ts-hd .ts-hd__nav a:focus-visible,
.ts-hd .ts-hd__nav a[aria-current] {
  color: var(--accent-strong, #0F8029);
}

.ts-hd__actions {
  display: flex;
  flex-shrink: 0;
  align-items: center;
  gap: var(--space-l, 2rem);
  padding-left: var(--space-l, 2rem);
  border-left: var(--border-s, 1px) solid var(--line, #E5E5E5);
}

.ts-hd .ts-hd__phone {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: var(--fs-body-l, clamp(1rem, 0.95rem + 0.25vw, 1.125rem));
  font-weight: 500;
  line-height: 1;
  white-space: nowrap;
  text-decoration: none;
  color: var(--black, #111111);
  transition: color 0.3s ease;
}

.ts-hd .ts-hd__phone:hover,
.ts-hd .ts-hd__phone:focus-visible {
  color: var(--accent-strong, #0F8029);
}

.ts-hd__phone svg {
  flex-shrink: 0;
  width: 1.5rem;
  height: 1.5rem;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.ts-hd .ts-hd__cta {
  align-self: center;
}

.ts-hd__icons {
  display: flex;
  align-items: center;
  gap: var(--space-s, 1rem);
}

.ts-hd .ts-hd__icon {
  box-sizing: border-box;
  display: flex;
  flex-shrink: 0;
  align-items: center;
  justify-content: center;
  width: 2.625rem;
  height: 2.625rem;
  border: var(--border-s, 1px) solid transparent;
  border-radius: 50%;
  background-color: var(--accent, #14A537);
  color: var(--white, #FFFFFF);
  transition: background-color 0.3s ease, border-color 0.3s ease, transform 0.3s ease;
}

.ts-hd .ts-hd__icon:hover,
.ts-hd .ts-hd__icon:focus-visible {
  background-color: var(--accent-strong, #0F8029);
  transform: translateY(-2px);
}

.ts-hd__icon svg {
  width: 1.25rem;
  height: 1.25rem;
  fill: currentColor;
}

.ts-hd .ts-hd__burger {
  display: none;
  position: relative;
  z-index: 1002;
  flex-shrink: 0;
  width: 3.25rem;
  height: 3.25rem;
  margin: 0 0 0 auto;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  cursor: pointer;
  appearance: none;
  -webkit-tap-highlight-color: transparent;
}

.ts-hd__bar {
  position: absolute;
  left: 50%;
  width: 1.25rem;
  height: 2px;
  margin-left: -0.625rem;
  background-color: currentColor;
  transition: transform 0.35s cubic-bezier(0.65, 0, 0.35, 1), top 0.35s cubic-bezier(0.65, 0, 0.35, 1);
}

.ts-hd__bar--1 {
  top: 1.3rem;
}

.ts-hd__bar--2 {
  top: 1.8rem;
}

.ts-hd.is-open .ts-hd__burger {
  color: var(--accent-strong, #0F8029);
}

.ts-hd.is-open .ts-hd__bar--1 {
  top: 1.55rem;
  transform: rotate(45deg);
}

.ts-hd.is-open .ts-hd__bar--2 {
  top: 1.55rem;
  transform: rotate(-45deg);
}

.ts-hd__overlay {
  box-sizing: border-box;
  position: fixed;
  inset: 0;
  z-index: 1001;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--space-l, clamp(2rem, 1.6rem + 1.6vw, 3rem));
  padding: var(--space-xl, 4rem) var(--space-m, 1.5rem);
  overflow-y: auto;
  color: var(--black, #111111);
  background-color: var(--white, #FFFFFF);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.4s ease, visibility 0.4s ease;
}

.ts-hd.is-open .ts-hd__overlay {
  opacity: 1;
  visibility: visible;
}

.ts-hd__overlay-nav {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-m, 1.5rem);
}

.ts-hd .ts-hd__overlay-nav a {
  font-size: var(--fs-h2-s, clamp(1.5rem, 1.2rem + 1.2vw, 2rem));
  font-weight: 600;
  line-height: 1.3;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--black, #111111);
}

.ts-hd .ts-hd__overlay-nav a:hover,
.ts-hd .ts-hd__overlay-nav a:focus-visible,
.ts-hd .ts-hd__overlay-nav a[aria-current] {
  color: var(--accent-strong, #0F8029);
}

.ts-hd__overlay-contact {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-xs, 0.5rem);
  text-align: center;
}

.ts-hd .ts-hd__overlay-contact a {
  display: flex;
  align-items: center;
  gap: var(--space-xs, 0.5rem);
  font-size: var(--fs-body-l, clamp(1rem, 0.95rem + 0.25vw, 1.125rem));
  font-weight: 600;
  line-height: 1.3;
  text-decoration: none;
  color: var(--accent-strong, #0F8029);
}

.ts-hd__overlay-address {
  display: flex;
  align-items: center;
  gap: var(--space-xs, 0.5rem);
  font-size: var(--fs-body-m, clamp(0.9375rem, 0.9rem + 0.15vw, 1rem));
  line-height: 1.4;
  color: var(--grey, #69727D);
}

.ts-hd__overlay-contact svg {
  flex-shrink: 0;
  width: 1rem;
  height: 1rem;
  fill: currentColor;
}

@media (max-width: 1339px) {
  /* enger, damit "Transporte Schmidt" im Tank-Clean-Menü zwischen 992 und 1339 px passt (bei 1280 lief er sonst 3 px über) */
  .ts-hd__box {
    gap: var(--space-m, 1.5rem);
  }

  .ts-hd__nav {
    gap: var(--space-s, 1rem);
  }

  .ts-hd__actions {
    gap: var(--space-s, 1rem);
    padding-left: var(--space-s, 1rem);
  }

  .ts-hd__logo svg,
  .ts-hd__logo img {
    height: 4.5rem;
  }

  .ts-hd__phone span {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
  }
}

@media (max-width: 991px) {
  :root {
    --ts-hd-h: 4.75rem;
  }

  .ts-hd__nav,
  .ts-hd__icons,
  .ts-hd__actions {
    display: none;
  }

  .ts-hd .ts-hd__burger {
    display: block;
  }

  .ts-hd {
    padding-block: var(--space-s, 1rem);
  }

  .ts-hd__box {
    min-height: 3.25rem;
  }

  .ts-hd__logo svg,
  .ts-hd__logo img {
    height: 3.25rem;
  }

  /* Tank-Clean-Logo (Header-Vorlage setzt 3.75rem): gleiche Header-Höhe wie Transporte Schmidt */
  body .ts-hd--tc .ts-hd__logo img {
    height: 3.25rem;
  }
}

/* Hero-Inhalt in derselben Flucht wie die Sections (Startseite und Tank Clean, 30.11.2026) */
.ts-sec-hero .ts-hero__inner,
.ts-sec-tchero .ts-tchero__inner {
  max-width: calc(var(--div-max, 1450px) + 2 * var(--section-sides, 2rem));
}

.ts-sec-tchero .ts-tchero__inner {
  padding-inline: var(--section-sides, 2rem);
}

/* Tank-Clean-H1 in derselben Stärke wie die Startseite (30.11.2026) */
.ts-sec-tchero .ts-tchero__title {
  font-weight: 600;
  line-height: 1.15;
}

/* Tank Clean "Ihre Vorteile": im Raster wie alle Sections statt randlos (30.11.2026) */
body .brxe-section.ts-sec-adv {
  padding: var(--section-block, 4rem) var(--section-sides, 2rem);
}

body .brxe-section.ts-sec-adv > .brxe-container {
  max-width: var(--div-max, 1450px);
}

.ts-sec-adv .ts-adv {
  gap: var(--space-xl, 4rem);
}

.ts-sec-adv .ts-adv__text {
  padding: 0;
  background-color: transparent;
}

/* Hero füllt den Rest des Bildschirms unter dem Header */
body:has(#brx-header .ts-hd) .ts-hero {
  min-height: calc(100vh - var(--wp-admin--admin-bar--height, 0px) - var(--ts-hd-h));
  min-height: calc(100svh - var(--wp-admin--admin-bar--height, 0px) - var(--ts-hd-h));
}

#brx-footer .brxe-section:has(.ts-ft) {
  padding-block-end: 0;
  background-color: var(--bg-light, #F1F1F1);
}

.ts-ft {
  display: flex;
  flex-direction: column;
  gap: var(--space-xl, clamp(2.5rem, 1.8rem + 3vw, 5rem));
  width: 100%;
}

.ts-ft__grid {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(32px, 4vw, 64px);
}

.ts-ft__brand {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--space-m, 1.5rem);
}

.ts-ft__brand a {
  display: block;
}

.ts-ft__brand img {
  display: block;
  width: 100%;
  max-width: 320px;
  height: auto;
}

.ts-ft__brand p {
  max-width: 20rem;
}

.ts-ft__col {
  display: flex;
  flex-direction: column;
  gap: var(--space-s, 1rem);
}

.ts-ft__list {
  display: flex;
  flex-direction: column;
  gap: var(--space-xs, 0.5rem);
  margin: 0;
  padding: 0;
  list-style: none;
}

.ts-ft .ts-ft__list a {
  text-decoration: none;
  color: var(--black, #111111);
  transition: color 0.3s ease;
}

.ts-ft .ts-ft__list a:hover,
.ts-ft .ts-ft__list a:focus-visible {
  color: var(--accent-strong, #0F8029);
}

.ts-ft__bottom {
  padding-block: 14px;
  font-size: var(--fs-body-s, 0.875rem);
  line-height: 1.5;
  color: var(--black, #111111);
  text-align: center;
  background-color: var(--line, #E6E8EE);
  box-shadow: 0 0 0 100vmax var(--line, #E6E8EE);
  clip-path: inset(0 -100vmax);
}

.ts-ft__bottom a {
  text-decoration: none;
}

.ts-ft__bottom a:hover,
.ts-ft__bottom a:focus-visible {
  color: var(--accent-strong, #0F8029);
}

@media (max-width: 767px) {
  .ts-ft__grid {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  }

  .ts-ft__brand {
    grid-column: 1 / -1;
  }
}

/* ========== Nach-oben-Button ========== */
.ts-fab {
  position: fixed;
  right: max(var(--section-sides, 1rem), env(safe-area-inset-right, 0px));
  bottom: calc(var(--section-sides, 1rem) + env(safe-area-inset-bottom, 0px));
  z-index: 90;
  opacity: 0;
  visibility: hidden;
  transform: translateY(1rem);
  transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s ease;
}

.ts-fab.is-on {
  opacity: 1;
  visibility: visible;
  transform: none;
}

.ts-fab[hidden] {
  display: none;
}

.ts-fab__top {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  width: 3.5rem;
  height: 3.5rem;
  margin: 0;
  padding: 0;
  border: var(--border-m, 2px) solid var(--accent-strong, #0F8029);
  border-radius: var(--radius-s, 0px);
  background-color: var(--accent-strong, #0F8029);
  color: var(--white, #FFFFFF);
  box-shadow: var(--shadow-m, 0 10px 30px rgba(17, 17, 17, 0.08));
  cursor: pointer;
  transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.ts-fab__top svg {
  width: 1.375rem;
  height: 1.375rem;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.ts-fab__top:hover,
.ts-fab__top:focus-visible {
  background-color: var(--accent-hover, #006B00);
  border-color: var(--accent-hover, #006B00);
  color: var(--white, #FFFFFF);
}

.ts-fab__top:focus-visible {
  outline: 2px solid var(--accent-strong, #0F8029);
  outline-offset: 3px;
}

@media (max-width: 767px) {
  .ts-fab__top {
    width: 3.25rem;
    height: 3.25rem;
  }

  /* Platz unter dem Footer, damit der Button nichts verdeckt */
  #brx-footer {
    padding-bottom: calc(3.25rem + 2 * var(--section-sides, 1rem));
  }
}

@media (prefers-reduced-motion: reduce) {
  .ts-fab,
  .ts-fab__top {
    transition: none;
  }
}

@media print {
  .ts-fab {
    display: none;
  }
}

/* ========== Kontakt-Section: Abstand Kopf zu Karte wie in den anderen Sections ========== */
body .ts-kx5 {
  gap: var(--space-l, clamp(2rem, 1.6rem + 1.6vw, 3rem));
}

/* Kein weißer Rahmen um die Karte (wirkte auf grauer Section wie ein Streifen) */
body .ts-kx-map {
  border: 0;
}

/* Platz für die Scrollleiste immer reservieren: kurze Seiten (404) springen sonst um 7 px zur Seite */
html {
  scrollbar-gutter: stable;
}

/* ========== Abschluss-CTA (letzte Section vor dem Footer, 30.11.2026) ==========
   Section weiß (Klasse ts-sec-cta), darin graue Box in der Flucht des Containers.
   Hintergrund: feine Linienzeichnung (Fahrerhaus von vorn), Akzent über --accent-strong (Tank Clean blau). */
.brxe-section.ts-sec-cta {
  background-color: var(--white, #FFFFFF);
}

.ts-cta {
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  padding: clamp(3.5rem, 1rem + 6.5vw, 8.5rem) clamp(1.25rem, 0.5rem + 4vw, 6rem);
  background-color: var(--bg-light, #F1F1F1);
  text-align: center;
}

.ts-cta__art {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.ts-cta__art * {
  vector-effect: non-scaling-stroke;
}

.ts-cta__art .l {
  fill: none;
  stroke: #CACACA;
  stroke-width: 1.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.ts-cta__art .a {
  fill: none;
  stroke: var(--accent-strong, #0F8029);
  stroke-width: 1.4;
  opacity: 0.45;
}

.ts-cta > :not(.ts-cta__art) {
  position: relative;
  z-index: 1;
}

.ts-cta .ts-cta__title {
  max-width: 22ch;
  margin: 0;
  text-wrap: balance;
}

.ts-cta .ts-cta__text {
  max-width: 52ch;
  margin: var(--space-s, 1rem) 0 0;
  color: var(--grey, #69727D);
  font-size: var(--fs-body-l, clamp(1rem, 0.95rem + 0.25vw, 1.125rem));
  text-wrap: pretty;
}

.ts-cta__actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-s, 1rem);
  margin-top: var(--space-l, clamp(2rem, 1.6rem + 1.6vw, 3rem));
}

.ts-cta__actions .btn-primary {
  align-self: auto;
  gap: 0.75rem;
}

.ts-cta__actions svg {
  width: 1.125rem;
  height: 1.125rem;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: none;
}

.ts-cta .ts-cta__dark {
  border-color: var(--black, #111111);
  background-color: var(--black, #111111);
}

.ts-cta .ts-cta__dark:hover,
.ts-cta .ts-cta__dark:focus-visible {
  border-color: var(--accent-strong, #0F8029);
  background-color: var(--accent-strong, #0F8029);
}

@media (max-width: 478px) {
  .ts-cta__actions {
    flex-direction: column;
    align-items: stretch;
    width: 100%;
  }

  .ts-cta__actions .btn-primary {
    width: 100%;
  }
}
