/* Der Ticker eines grossen Sales unter dem Kopf (ADTA, Vorschau «Big Sale»)
 * — components/sale/SaleTicker.tsx. Kommt nur mit dem Ticker (wie
 * ausfuehrung.css): er steht nur während eines Sales da. Nur Token aus
 * tokens.css. */
.ticker {
  --spacing-ticker: 44px;
  --spacing-ticker-bild: 30px;
  display: flex;
  align-items: center;
  height: var(--spacing-ticker);
  border-bottom: var(--spacing-linie) solid var(--color-text);
  background-color: var(--color-bg);
  overflow: hidden;
  font-size: var(--text-xs);
}
.ticker-marke {
  flex: none;
  display: flex;
  align-items: center;
  gap: 8px;
  height: 100%;
  padding: 0 16px 0 var(--spacing-kopf-x);
  color: var(--color-text);
  font-size: var(--text-versal);
  font-weight: 900;
  letter-spacing: var(--text-versal--letter-spacing);
  text-decoration: none;
  text-transform: uppercase;
  white-space: nowrap;
}
.ticker-band {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  mask-image: linear-gradient(90deg, transparent, var(--maske-voll) 24px, var(--maske-voll) calc(100% - 24px), transparent);
}
.ticker-lauf {
  display: flex;
  width: max-content;
  animation: ticker-lauf 60s linear infinite;
}
/* ADTN: der Takt je Deal gleich (SaleTicker.tsx, tickerTempo). */
.ticker-lauf[data-tempo="20"] { animation-duration: 20s; }
.ticker-lauf[data-tempo="30"] { animation-duration: 30s; }
.ticker-lauf[data-tempo="40"] { animation-duration: 40s; }
.ticker-lauf[data-tempo="50"] { animation-duration: 50s; }
.ticker-lauf[data-tempo="60"] { animation-duration: 60s; }
.ticker-lauf[data-tempo="70"] { animation-duration: 70s; }
.ticker-lauf[data-tempo="80"] { animation-duration: 80s; }
.ticker-lauf[data-tempo="90"] { animation-duration: 90s; }
.ticker-lauf[data-tempo="100"] { animation-duration: 100s; }
.ticker-lauf[data-tempo="110"] { animation-duration: 110s; }
.ticker-lauf[data-tempo="120"] { animation-duration: 120s; }
.ticker:hover .ticker-lauf,
.ticker:focus-within .ticker-lauf {
  animation-play-state: paused;
}
@media (prefers-reduced-motion: reduce) {
  .ticker-lauf {
    animation: none;
  }
}
@keyframes ticker-lauf {
  to {
    transform: translateX(-50%);
  }
}
.ticker-liste {
  display: flex;
  gap: 28px;
  margin: 0;
  padding: 0 14px;
  list-style: none;
}
.ticker-deal {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--color-text);
  font-weight: var(--font-weight-fett);
  text-decoration: none;
  white-space: nowrap;
  transition: color var(--dauer-wechsel) ease;
}
.ticker-deal:hover {
  color: var(--color-red);
}
.ticker-bild {
  display: block;
  width: var(--spacing-ticker-bild);
  height: var(--spacing-ticker-bild);
}
.ticker-bild img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.ticker-preis {
  color: var(--color-red);
}
/* ADVO (Baro 25.11.: «als Sale-Pill, so wie wir es sonst überall im Shop
   handhaben»): der Rabatt als rote Pille — dieselbe Form wie .rabatt-pille
   der Karten (katalog.css), in der kleinen Grösse der Listen. Hier
   ausgeschrieben, weil der Ticker auf Seiten ohne den Katalog steht. */
.ticker-spare {
  display: inline-flex;
  flex: none;
  padding: 4px 9px;
  border-radius: var(--radius-pill);
  background-color: var(--color-red);
  color: var(--color-on-red);
  font-size: var(--text-versal);
  font-weight: var(--font-weight-knopf);
  letter-spacing: normal;
  line-height: 1;
  white-space: nowrap;
}
.ticker-deal:hover .ticker-spare {
  color: var(--color-on-red);
}
.ticker-statt {
  font-weight: 500;
}
/* ADTN (Baro 22.11.: «über und unter dem Knopf zu wenig Luft»): so
   kompakt wie die Knopfgruppe (Ready2Race «Direktkauf/Finanzierung»). */
.ticker-knopf {
  flex: none;
  min-height: var(--spacing-knopfgruppe);
  margin: 0 var(--spacing-kopf-x) 0 16px;
}
/* ADZD (Baro 28.11.: «links und rechts das gleiche Padding wie
   Header/Sub-Header»): Name und Knopf stehen auf den Kanten von Kopf und
   Subheader — 32px, kompakt (1241–1400px) 24px, bis 560px 16px. */
@media (min-width: 1241px) and (max-width: 1400px) {
  .ticker-marke {
    padding-left: var(--spacing-kopf-x-kompakt);
  }
  .ticker-knopf {
    margin-right: var(--spacing-kopf-x-kompakt);
  }
}
/* ADYV (Baro 27.11.: «Sale Ticker bei Mobile Sale-Name weg … Button Zu
   den Deals»): am Handy hat das Band den Platz des Namens; rechts der
   Knopf wie am Desktop, mit dem Seitenrand des Handys. */
.ticker-knopf-pfeil {
  display: none;
}
@media (max-width: 640px) {
  .ticker-marke {
    display: none;
  }
  .ticker-knopf {
    margin: 0 var(--spacing-kopf-x) 0 var(--spacing-filter-luft);
  }
  /* ADZB (Baro 27.11., Vorschau «Ticker-Knopf Handy», B): ein runder roter
     Pfeil-Knopf in der Höhe der Knopfgruppe (am Telefon 34px) — die Deals
     haben mehr Platz. «Zu den Deals» bleibt im Knopf, nur unsichtbar. */
  .ticker-knopf {
    width: var(--spacing-knopfgruppe);
    min-width: var(--spacing-knopfgruppe);
    height: var(--spacing-knopfgruppe);
    padding: 0;
    border-radius: var(--radius-pill);
  }
  .ticker-knopf-wort {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
  }
  .ticker-knopf-pfeil {
    display: block;
    width: var(--spacing-icon);
    height: var(--spacing-icon);
  }
}
@media (max-width: 560px) {
  .ticker-knopf {
    margin-right: var(--spacing-seitenrand-schmal);
  }
}
