/* ═══════════════════════════════════════════════════════════════════
   ARTFORM — WooCommerce
   ═══════════════════════════════════════════════════════════════════
   Reines Aufsatz-CSS für die von WooCommerce erzeugte Auszeichnung.
   Kein PHP, keine Templates — WooCommerce liefert seine eigenen Klassen,
   wir übernehmen nur die Optik aus design.css: heller, ruhiger Grund,
   ein gedämpftes Petrol als einziger Akzent, Karten mit dünner Linie
   statt Schatten-Overkill.

   Quelle der Klassennamen: Live-Abgleich mit https://artform.weareweblabs.com
   (Produktliste, Produktseite, Konto-Login). Warenkorb und Kasse liefern
   im leeren Zustand kein HTML mit echten Positionen — dort wird nach den
   Standardklassen von WooCommerce 11 gestaltet. Diese Version nutzt für
   Warenkorb/Kasse den Block-Editor (wp-block-woocommerce-*), deshalb wird
   zusätzlich zur klassischen Tabellen-Auszeichnung (shop_table, form-row)
   auch die Block-Auszeichnung (wc-block-*) bedient — beide zusammen decken
   ab, was WooCommerce 11 je nach Konfiguration ausliefert.

   Nur --wlf-* und --af-*-Tokens, keine festen Farbwerte außer bei
   Zustandsfarben ohne eigenes Token (Sternebewertung, Rabatt-Streichpreis).
   ═══════════════════════════════════════════════════════════════════ */

/* ── Grundrahmen ─────────────────────────────────────────────────────
   WooCommerce bringt seinen Inhalt in .wlf-woocommerce (Theme-Wrapper).
   Die Breite kommt vom Theme, hier nur Lesefluss und Linkfarbe, damit
   WooCommerce-eigene Links (Warenkorb-Meldung, "Zurück zum Shop" etc.)
   nicht in Browser-Blau auftauchen. */
.woocommerce, .woocommerce-page {
  color: var(--wlf-color-ink);
}
/* Gold als Schrift immer in der abgedunkelten Fassung: #bfa774 auf Weiß
   ist als Text nicht lesbar genug. Als Fläche bleibt es die Markenfarbe. */
body.woocommerce .wlf-site-main a:not(.button):not(.af-btn) {
  color: var(--af-gold-text);
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
}
body.woocommerce .wlf-site-main a:not(.button):not(.af-btn):hover { color: var(--wlf-color-ink); }

/* ── Brotkrumen ──────────────────────────────────────────────────────
   Dezent und klein — sie sind Orientierung, kein Gestaltungselement. */
.woocommerce-breadcrumb {
  font-size: var(--wlf-text-sm);
  color: var(--wlf-color-ink-muted);
  margin: 0 0 var(--wlf-space-5);
  padding-top: var(--wlf-space-5);
}
.woocommerce-breadcrumb a { color: var(--wlf-color-ink-muted); text-decoration: none; }
.woocommerce-breadcrumb a:hover { color: var(--wlf-color-ink); text-decoration: underline; }

/* ── Meldungen ───────────────────────────────────────────────────────
   Bewusst KEIN knalliger Flächen-Hintergrund: eine farbige Kante links
   auf ruhiger Fläche reicht, um Erfolg/Info/Fehler zu unterscheiden,
   ohne die helle Seite zu stören. Zustandsfarben stehen als Token
   bereit (--wlf-color-success/-warning/-danger), Info bekommt den
   Marken-Akzent, weil es dafür kein eigenes Token gibt. */
.woocommerce-message,
.woocommerce-info,
.woocommerce-error,
.woocommerce-noreviews,
p.no-comments {
  display: flex; flex-wrap: wrap; align-items: center; gap: var(--wlf-space-3);
  list-style: none; margin: 0 0 var(--wlf-space-5); padding: var(--wlf-space-4) var(--wlf-space-5);
  background: var(--wlf-color-surface);
  border: 1px solid var(--wlf-color-line);
  border-left: 3px solid var(--wlf-color-accent);
  border-radius: var(--wlf-radius-md);
  font-size: var(--wlf-text-sm);
}
.woocommerce-message { border-left-color: var(--wlf-color-success); }
.woocommerce-error { border-left-color: var(--wlf-color-danger); }
/* Fehlerliste kommt manchmal als <ul> mit mehreren <li>-Meldungen daher. */
.woocommerce-error li { margin: 0; }
.woocommerce-message a.button,
.woocommerce-error a.button {
  margin-left: auto;
}

/* ── Ergebniszähler & Sortierung ────────────────────────────────────
   Eine Zeile über dem Raster: links Anzahl, rechts Sortierung. Auf
   Mobil untereinander, damit das Dropdown nicht gequetscht wird. */
.woocommerce > form.woocommerce-ordering,
.woocommerce-ordering { display: inline-block; }
.woocommerce-result-count,
.woocommerce-ordering {
  margin: 0 0 var(--wlf-space-5);
}

/* Die beiden Elemente stehen im Markup ohne gemeinsamen Wrapper direkt
   nacheinander — mit Flex auf dem darüberliegenden Container ließen sie
   sich sauber in eine Zeile bringen, doch der Wrapper ist WooCommerce-
   eigen und hier nicht greifbar. Also über die Geschwister-Beziehung. */
.woocommerce-result-count {
  display: inline-block;
  color: var(--wlf-color-ink-muted);
  font-size: var(--wlf-text-sm);
}
.woocommerce-result-count + form.woocommerce-ordering {
  float: right;
}
@media (max-width: 640px) {
  .woocommerce-result-count + form.woocommerce-ordering { float: none; display: block; margin-top: var(--wlf-space-2); }
}

.orderby {
  appearance: none;
  background: var(--wlf-color-bg);
  border: 1px solid var(--wlf-color-line);
  border-radius: var(--wlf-radius-md);
  padding: .55rem 2.2rem .55rem .9rem;
  font-family: inherit; font-size: var(--wlf-text-sm); color: var(--wlf-color-ink);
  cursor: pointer;
  /* Eigener Pfeil statt System-Pfeil, damit er zur schlichten Optik passt. */
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%236a716d' stroke-width='1.6'%3E%3Cpath d='M5 8l5 5 5-5'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right .7rem center; background-size: 16px;
  transition: border-color var(--wlf-transition);
}
.orderby:hover { border-color: var(--wlf-color-ink); }
.orderby:focus-visible { outline: 2px solid var(--wlf-color-accent); outline-offset: 2px; }

/* ═══════════════════════════════════════════════════════════════════
   PRODUKTLISTE  (.woocommerce ul.products)
   ═══════════════════════════════════════════════════════════════════ */
.woocommerce ul.products {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: clamp(1rem, 2.5vw, 1.75rem);
  list-style: none;
  margin: 0 0 var(--wlf-space-7);
  padding: 0;
  clear: both; /* wegen des float bei der Sortierzeile */
}

.woocommerce ul.products li.product {
  background: var(--wlf-color-bg);
  border: 1px solid var(--wlf-color-line);
  border-radius: var(--wlf-radius-lg);
  overflow: hidden;
  display: flex; flex-direction: column;
  transition: border-color var(--wlf-transition), box-shadow var(--wlf-transition), transform var(--wlf-transition);
}
/* Dezenter Hover: Linie dunkler, leichtes Anheben — kein Schatten-Drama,
   die Felge soll wirken, nicht die Karte. */
.woocommerce ul.products li.product:hover {
  border-color: var(--wlf-color-ink);
  box-shadow: var(--wlf-shadow-md);
  transform: translateY(-2px);
}

.woocommerce ul.products li.product a.woocommerce-LoopProduct-link {
  display: flex; flex-direction: column; height: 100%;
  text-decoration: none; color: inherit;
}

/* Produktbild: auf Surface-Fläche mit Innenabstand, damit freigestellte
   Felgen "schweben" statt am Kartenrand zu kleben — object-fit: contain,
   weil beschnittene Felgenbilder Kunden beim Passform-Vergleich stören. */
.woocommerce ul.products li.product img {
  display: block;
  width: 100%; aspect-ratio: 1 / 1;
  background: var(--wlf-color-surface);
  object-fit: contain;
  padding: var(--wlf-space-4);
  box-sizing: border-box;
}

.woocommerce ul.products li.product .woocommerce-loop-product__title {
  margin: var(--wlf-space-4) var(--wlf-space-4) 0;
  font-size: var(--wlf-text-base);
  font-weight: var(--wlf-weight-bold);
  letter-spacing: -.02em;
  line-height: var(--wlf-leading-tight);
  color: var(--wlf-color-ink);
}

.woocommerce ul.products li.product .price {
  margin: .35rem var(--wlf-space-4) var(--wlf-space-4);
  margin-top: auto; /* schiebt Preis + Button ans Kartenende, egal wie lang der Titel ist */
  padding-top: .35rem;
  font-weight: var(--wlf-weight-bold);
  font-variant-numeric: tabular-nums;
  color: var(--wlf-color-ink);
}
/* Streichpreis bei reduzierten Produkten — WooCommerce liefert <del>/<ins>. */
.woocommerce ul.products li.product .price del {
  color: var(--wlf-color-ink-muted);
  font-weight: var(--wlf-weight-normal);
  margin-right: .4em;
  text-decoration-thickness: 1px;
}
.woocommerce ul.products li.product .price ins {
  text-decoration: none;
}

/* "In den Warenkorb"-Button im Raster: volle Kartenbreite, damit die
   Zeile mit dem Bild abschließt, wie bei den Modellkarten der Startseite. */
.woocommerce ul.products li.product a.button,
.woocommerce ul.products li.product a.add_to_cart_button {
  display: block;
  margin: 0 var(--wlf-space-4) var(--wlf-space-4);
  padding: .7rem 1.2rem;
  border-radius: var(--wlf-radius-pill);
  border: 1px solid var(--wlf-color-ink);
  background: var(--wlf-color-ink);
  color: var(--af-on-dark);
  font-size: var(--wlf-text-sm); font-weight: var(--wlf-weight-bold);
  text-align: center; text-decoration: none;
  cursor: pointer;
  transition: background var(--wlf-transition), border-color var(--wlf-transition);
}
.woocommerce ul.products li.product a.button:hover,
.woocommerce ul.products li.product a.add_to_cart_button:hover {
  background: var(--wlf-color-accent);
  border-color: var(--wlf-color-accent);
  color: var(--wlf-color-accent-ink);
}
/* WooCommerce fügt "hinzugefügt" per AJAX-Klasse hinzu — sichtbar machen,
   damit der Kunde die Bestätigung ohne Seitenwechsel sieht. */
.woocommerce ul.products li.product a.added_to_cart {
  display: block;
  margin: 0 var(--wlf-space-4) var(--wlf-space-4);
  text-align: center; font-size: var(--wlf-text-xs);
  color: var(--af-gold-text); text-decoration: underline;
}

/* ── Blätterung ──────────────────────────────────────────────────── */
.woocommerce-pagination { margin-top: var(--wlf-space-6); }
.woocommerce-pagination ul.page-numbers {
  display: flex; flex-wrap: wrap; gap: .4rem;
  list-style: none; margin: 0; padding: 0;
}
.woocommerce-pagination .page-numbers li { display: contents; }
.woocommerce-pagination .page-numbers a,
.woocommerce-pagination .page-numbers span {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 2.4rem; height: 2.4rem; padding-inline: .5rem;
  border-radius: var(--wlf-radius-pill);
  border: 1px solid var(--wlf-color-line);
  font-size: var(--wlf-text-sm); font-weight: var(--wlf-weight-medium);
  color: var(--wlf-color-ink); text-decoration: none;
  transition: border-color var(--wlf-transition), background var(--wlf-transition), color var(--wlf-transition);
}
.woocommerce-pagination .page-numbers a:hover {
  border-color: var(--wlf-color-ink);
  background: var(--wlf-color-surface);
}
.woocommerce-pagination .page-numbers .current {
  background: var(--wlf-color-accent);
  border-color: var(--wlf-color-accent);
  color: var(--wlf-color-accent-ink);
}
.woocommerce-pagination .page-numbers .dots {
  border-color: transparent; color: var(--wlf-color-ink-muted);
}

/* ═══════════════════════════════════════════════════════════════════
   PRODUKTSEITE
   ═══════════════════════════════════════════════════════════════════ */
.single-product .product {
  display: grid; gap: clamp(2rem, 5vw, 3.5rem);
  margin-bottom: var(--af-section);
}
@media (min-width: 860px) {
  .single-product .product { grid-template-columns: 1.05fr .95fr; align-items: start; }
}

/* Galerie: gleiche Fläche wie in der Produktliste, damit Bild und Karte
   optisch zur selben Familie gehören. Dieser Shop zeigt aktuell ein
   einzelnes Bild ohne Vorschau-Miniaturen (--without-images-Variante
   greift nicht, es ist einfach kein Thumbnail-Streifen vorhanden). */
.woocommerce-product-gallery {
  background: var(--wlf-color-surface);
  border-radius: var(--wlf-radius-lg);
  overflow: hidden;
}
.woocommerce-product-gallery__wrapper { margin: 0; padding: 0; list-style: none; }
.woocommerce-product-gallery__image { display: block; }
.woocommerce-product-gallery img,
.woocommerce-product-gallery__image img {
  width: 100%; aspect-ratio: 1 / 1;
  object-fit: contain;
  padding: clamp(1.5rem, 4vw, 3rem);
  box-sizing: border-box;
  display: block;
}

.summary.entry-summary { display: flex; flex-direction: column; }
.summary.entry-summary .product_title.entry-title {
  font-size: var(--wlf-text-3xl);
  line-height: var(--wlf-leading-tight);
  letter-spacing: -.03em;
  margin: 0 0 var(--wlf-space-3);
}
.summary.entry-summary > .price {
  font-size: var(--wlf-text-2xl);
  font-weight: var(--wlf-weight-bold);
  font-variant-numeric: tabular-nums;
  color: var(--wlf-color-ink);
  margin: 0 0 var(--wlf-space-5);
}

.woocommerce-product-details__short-description {
  color: var(--wlf-color-ink-muted);
  font-size: var(--wlf-text-base);
  line-height: var(--wlf-leading-base);
  margin: 0 0 var(--wlf-space-5);
}
.woocommerce-product-details__short-description p:last-child { margin-bottom: 0; }

/* Kaufzeile: Mengenfeld + Button nebeneinander, auf Mobil volle Breite. */
.summary.entry-summary form.cart {
  display: flex; flex-wrap: wrap; align-items: stretch; gap: var(--wlf-space-3);
  margin: 0 0 var(--wlf-space-5);
}
.summary.entry-summary .quantity { display: flex; }
.summary.entry-summary .quantity .qty,
input.qty {
  width: 4.5rem; height: 100%;
  border: 1px solid var(--wlf-color-line);
  border-radius: var(--wlf-radius-md);
  padding: 0 .7rem;
  font-family: inherit; font-size: var(--wlf-text-base); font-weight: var(--wlf-weight-medium);
  text-align: center; color: var(--wlf-color-ink);
  background: var(--wlf-color-bg);
  transition: border-color var(--wlf-transition);
}
.summary.entry-summary .quantity .qty:focus-visible { border-color: var(--wlf-color-accent); }

/* Kauf-Button im Stil von .af-btn --accent — der Petrol-Akzent ist der
   einzige Ort auf der Seite, an dem er als Fläche auftaucht (Kaufabsicht
   verdient die stärkste Farbe im System). */
.single_add_to_cart_button.button,
.single_add_to_cart_button.button.alt {
  flex: 1 1 12rem;
  display: inline-flex; align-items: center; justify-content: center;
  padding: .85rem 1.6rem;
  border-radius: var(--wlf-radius-pill);
  border: 1px solid var(--wlf-color-accent);
  background: var(--wlf-color-accent);
  color: var(--wlf-color-accent-ink);
  font-size: var(--wlf-text-base); font-weight: var(--wlf-weight-bold);
  cursor: pointer;
  transition: background var(--wlf-transition), border-color var(--wlf-transition);
}
.single_add_to_cart_button.button:hover {
  background: var(--wlf-color-accent-hover);
  border-color: var(--wlf-color-accent-hover);
}
.single_add_to_cart_button.disabled,
.single_add_to_cart_button:disabled {
  opacity: .5; cursor: not-allowed;
}

/* Meta: SKU/Kategorie — kleine, ruhige Zeile, keine Konkurrenz zum Button. */
.product_meta {
  font-size: var(--wlf-text-sm);
  color: var(--wlf-color-ink-muted);
  padding-top: var(--wlf-space-4);
  border-top: 1px solid var(--wlf-color-line-soft);
  display: flex; flex-direction: column; gap: .3rem;
}
.product_meta > span { display: block; }
.product_meta a { color: var(--wlf-color-ink-muted); }
.product_meta a:hover { color: var(--af-gold-text); }
.product_meta .sku { color: var(--wlf-color-ink); font-weight: var(--wlf-weight-medium); }

/* ── Reiter (Zusätzliche Informationen etc.) ────────────────────────
   Schlichte Unterstreich-Tabs statt Karteikarten-Optik — passt zur
   sonst kargen Linienführung des Shops. */
.woocommerce-tabs.wc-taaf-wrapper {
  margin-top: var(--af-section);
  border-top: 1px solid var(--wlf-color-line);
}
ul.tabs.wc-tabs {
  display: flex; flex-wrap: wrap; gap: var(--wlf-space-2);
  list-style: none; margin: 0; padding: var(--wlf-space-5) 0 0;
}
ul.tabs.wc-tabs li {
  margin: 0;
}
ul.tabs.wc-tabs li a {
  display: inline-block;
  padding: .6rem 1.1rem;
  border-radius: var(--wlf-radius-pill);
  font-size: var(--wlf-text-sm); font-weight: var(--wlf-weight-medium);
  color: var(--wlf-color-ink-muted); text-decoration: none;
  transition: background var(--wlf-transition), color var(--wlf-transition);
}
ul.tabs.wc-tabs li a:hover { background: var(--wlf-color-surface); color: var(--wlf-color-ink); }
ul.tabs.wc-tabs li.active a {
  background: var(--wlf-color-ink); color: var(--af-on-dark);
}
.woocommerce-tabs .woocommerce-Taaf-panel {
  padding-top: var(--wlf-space-6);
  max-width: 62ch;
  line-height: var(--wlf-leading-base);
  color: var(--wlf-color-ink-muted);
}
.woocommerce-tabs .woocommerce-Taaf-panel h2 {
  /* WooCommerce setzt hier eine <h2>, die im Fließtext optisch zu groß wäre. */
  font-size: var(--wlf-text-lg); color: var(--wlf-color-ink); margin: 0 0 var(--wlf-space-4);
}

/* Attribut-Tabelle (Größe, Lochkreis, ET, Nabenbohrung …) — für Felgen
   die wichtigste Tabelle im ganzen Shop, deshalb ruhig und gut lesbar. */
table.woocommerce-product-attributes {
  width: 100%; max-width: 62ch;
  border-collapse: collapse;
}
table.woocommerce-product-attributes tr { border-bottom: 1px solid var(--wlf-color-line-soft); }
table.woocommerce-product-attributes tr:last-child { border-bottom: 0; }
.woocommerce-product-attributes-item__label,
.woocommerce-product-attributes-item__value {
  padding: .6rem 0; text-align: left; font-size: var(--wlf-text-sm); font-weight: var(--wlf-weight-normal);
}
.woocommerce-product-attributes-item__label {
  width: 40%; color: var(--wlf-color-ink-muted); font-weight: var(--wlf-weight-medium);
}
.woocommerce-product-attributes-item__value { color: var(--wlf-color-ink); }
.woocommerce-product-attributes-item__value p { margin: 0; }

/* ── Verwandte Produkte ──────────────────────────────────────────── */
.related.products {
  margin-top: var(--af-section);
  padding-top: var(--af-section);
  border-top: 1px solid var(--wlf-color-line);
}
.related.products h2 {
  font-size: var(--wlf-text-2xl);
  margin: 0 0 var(--wlf-space-6);
}
/* Das Produktraster darunter erbt automatisch die Regeln von oben
   (.woocommerce ul.products), eigene Anpassungen sind nicht nötig. */

/* ═══════════════════════════════════════════════════════════════════
   WARENKORB — klassische Tabellen-Auszeichnung (shop_table)
   ═══════════════════════════════════════════════════════════════════ */
table.shop_table {
  width: 100%;
  border-collapse: collapse;
  margin: 0 0 var(--wlf-space-6);
}
table.shop_table th {
  text-align: left;
  padding: var(--wlf-space-3) var(--wlf-space-3);
  font-size: var(--wlf-text-xs); font-weight: var(--wlf-weight-bold);
  letter-spacing: var(--wlf-tracking-wide); text-transform: uppercase;
  color: var(--wlf-color-ink-muted);
  border-bottom: 1px solid var(--wlf-color-line);
}
table.shop_table td {
  padding: var(--wlf-space-4) var(--wlf-space-3);
  border-bottom: 1px solid var(--wlf-color-line-soft);
  vertical-align: middle;
  font-size: var(--wlf-text-sm);
}
table.shop_table td.product-name a { color: var(--wlf-color-ink); font-weight: var(--wlf-weight-medium); text-decoration: none; }
table.shop_table td.product-name a:hover { color: var(--af-gold-text); }
table.shop_table td.product-thumbnail img {
  width: 4.5rem; aspect-ratio: 1 / 1; object-fit: contain;
  background: var(--wlf-color-surface); border-radius: var(--wlf-radius-md);
  padding: .4rem;
}
table.shop_table td.product-price,
table.shop_table td.product-subtotal {
  font-weight: var(--wlf-weight-bold); font-variant-numeric: tabular-nums;
}
table.shop_table td.product-remove a.remove {
  display: inline-flex; align-items: center; justify-content: center;
  width: 1.8rem; height: 1.8rem; border-radius: 50%;
  color: var(--wlf-color-ink-muted); text-decoration: none; font-size: 1.1rem; line-height: 1;
  transition: background var(--wlf-transition), color var(--wlf-transition);
}
table.shop_table td.product-remove a.remove:hover {
  background: var(--wlf-color-surface); color: var(--wlf-color-danger);
}
table.shop_table .product-quantity input.qty { width: 3.6rem; height: 2.5rem; }

/* Coupon-Zeile + Warenkorb aktualisieren */
.woocommerce-cart-form .coupon {
  display: flex; flex-wrap: wrap; gap: var(--wlf-space-2); align-items: center;
}
.woocommerce-cart-form .coupon input#coupon_code {
  flex: 1 1 12rem;
  border: 1px solid var(--wlf-color-line); border-radius: var(--wlf-radius-md);
  padding: .65rem .85rem; font-family: inherit; font-size: var(--wlf-text-sm);
}
.woocommerce-cart-form .coupon input#coupon_code:focus-visible { border-color: var(--wlf-color-accent); }

/* Summen-Box: eigene Fläche, damit sie sich vom Positionslisting abhebt. */
.cart_totals, .cart-collaterals .cart_totals {
  background: var(--wlf-color-surface);
  border: 1px solid var(--wlf-color-line);
  border-radius: var(--wlf-radius-lg);
  padding: var(--wlf-space-5) var(--wlf-space-6);
  max-width: 26rem; margin-left: auto;
}
.cart_totals h2 { font-size: var(--wlf-text-lg); margin: 0 0 var(--wlf-space-4); }
.cart_totals table.shop_table { margin-bottom: var(--wlf-space-5); }
.cart_totals table.shop_table td,
.cart_totals table.shop_table th { padding: var(--wlf-space-2) 0; border-color: var(--wlf-color-line-soft); }
.cart_totals .order-total .amount { font-size: var(--wlf-text-lg); font-weight: var(--wlf-weight-bold); }

/* Buttons in Warenkorb/Kasse einheitlich im .af-btn-Stil: Pille, 1px
   Rahmen, klarer Hover. "Warenkorb aktualisieren" ist zweitrangig →
   Ghost-Stil; "Zur Kasse" ist die Hauptaktion → Akzentfläche. */
.woocommerce button.button,
.woocommerce input.button,
.woocommerce a.button,
.wc-proceed-to-checkout a.checkout-button,
a.checkout-button {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  padding: .8rem 1.5rem;
  border-radius: var(--wlf-radius-pill);
  border: 1px solid var(--wlf-color-line);
  background: transparent; color: var(--wlf-color-ink);
  font-size: var(--wlf-text-sm); font-weight: var(--wlf-weight-bold);
  text-decoration: none; cursor: pointer;
  transition: background var(--wlf-transition), border-color var(--wlf-transition), color var(--wlf-transition);
}
.woocommerce button.button:hover,
.woocommerce input.button:hover,
.woocommerce a.button:hover {
  border-color: var(--wlf-color-ink); background: var(--wlf-color-bg);
}
/* Hauptaktionen (Zur Kasse, Bestellen) heben sich mit dem Akzent ab. */
.wc-proceed-to-checkout a.checkout-button,
a.checkout-button,
#place_order {
  border-color: var(--wlf-color-accent);
  background: var(--wlf-color-accent);
  color: var(--wlf-color-accent-ink);
  width: 100%;
}
.wc-proceed-to-checkout a.checkout-button:hover,
a.checkout-button:hover,
#place_order:hover {
  background: var(--wlf-color-accent-hover); border-color: var(--wlf-color-accent-hover);
}

/* Warenkorb-Tabelle auf Mobil als Karten stapeln: WooCommerce liefert
   dafür bereits data-title-Attribute auf den <td>-Zellen mit; die
   ::before-Beschriftung ist Standard-WooCommerce-Praxis und braucht
   keine eigenen Templates. */
@media (max-width: 640px) {
  table.shop_table thead { display: none; }
  table.shop_table, table.shop_table tbody, table.shop_table tr, table.shop_table td {
    display: block; width: 100%;
  }
  table.shop_table tr {
    border: 1px solid var(--wlf-color-line);
    border-radius: var(--wlf-radius-md);
    margin-bottom: var(--wlf-space-4);
    padding: var(--wlf-space-2) var(--wlf-space-4);
  }
  table.shop_table td {
    display: flex; align-items: center; justify-content: space-between; gap: var(--wlf-space-3);
    border-bottom: 1px solid var(--wlf-color-line-soft);
    text-align: right;
  }
  table.shop_table td:last-child { border-bottom: 0; }
  table.shop_table td.product-remove { justify-content: flex-end; }
  table.shop_table td::before {
    content: attr(data-title);
    font-size: var(--wlf-text-xs); font-weight: var(--wlf-weight-bold);
    text-transform: uppercase; letter-spacing: var(--wlf-tracking-wide);
    color: var(--wlf-color-ink-muted);
  }
  .cart_totals, .cart-collaterals .cart_totals { max-width: none; }
}

/* ═══════════════════════════════════════════════════════════════════
   WARENKORB & KASSE — WooCommerce-Blocks (dieser Shop verwendet den
   Block-Editor für /cart/ und /checkout/, die Klassen tragen daher das
   Präfix wc-block-* statt der klassischen shop_table-Auszeichnung).
   ═══════════════════════════════════════════════════════════════════ */
.wp-block-woocommerce-cart,
.wp-block-woocommerce-checkout {
  display: grid; gap: clamp(1.5rem, 4vw, 3rem);
}
@media (min-width: 860px) {
  .wp-block-woocommerce-cart,
  .wp-block-woocommerce-checkout {
    grid-template-columns: 1.5fr 1fr; align-items: start;
  }
}

/* Positionszeilen im Block-Warenkorb: gleiche Kartenoptik wie sonst im
   Shop, statt der WooCommerce-eigenen Fließtabelle. */
.wc-block-cart-items, .wc-block-components-order-summary {
  background: var(--wlf-color-bg);
  border: 1px solid var(--wlf-color-line);
  border-radius: var(--wlf-radius-lg);
  overflow: hidden;
}
.wc-block-cart-item, .wc-block-components-totals-item {
  padding: var(--wlf-space-4) var(--wlf-space-5);
  border-bottom: 1px solid var(--wlf-color-line-soft);
}
.wc-block-cart-item:last-child { border-bottom: 0; }
.wc-block-components-product-image img,
.wc-block-cart-item__image img {
  background: var(--wlf-color-surface);
  border-radius: var(--wlf-radius-md);
  object-fit: contain;
  padding: .5rem;
}
.wc-block-components-product-name { color: var(--wlf-color-ink); font-weight: var(--wlf-weight-medium); text-decoration: none; }
.wc-block-components-formatted-money-amount { font-variant-numeric: tabular-nums; font-weight: var(--wlf-weight-bold); }

/* Mengenfeld im Block-Warenkorb: Stepper mit +/- statt reinem Zahlenfeld —
   optisch an das übrige Formularmuster angleichen (Rahmen, Radius, Akzent
   bei Fokus), Feinheiten der internen Struktur bleiben WooCommerce-Sache. */
.wc-block-components-quantity-selector {
  border: 1px solid var(--wlf-color-line); border-radius: var(--wlf-radius-md);
  overflow: hidden;
}
.wc-block-components-quantity-selector input.wc-block-components-quantity-selector__input {
  border: 0; font-family: inherit; text-align: center;
}
.wc-block-components-quantity-selector__button {
  background: var(--wlf-color-surface); border: 0; color: var(--wlf-color-ink);
  cursor: pointer; transition: background var(--wlf-transition);
}
.wc-block-components-quantity-selector__button:hover { background: var(--wlf-color-surface-alt); }

/* Formularfelder in Adress-/Zahlungsschritten des Block-Checkouts */
.wc-block-components-text-input input,
.wc-block-components-text-input textarea,
.wc-block-components-address-form input,
.wc-block-checkout__form input[type="text"],
.wc-block-checkout__form input[type="email"],
.wc-block-checkout__form input[type="tel"] {
  border: 1px solid var(--wlf-color-line); border-radius: var(--wlf-radius-md);
  padding: .75rem .9rem; font-family: inherit; font-size: var(--wlf-text-base);
  background: var(--wlf-color-bg); color: var(--wlf-color-ink);
  transition: border-color var(--wlf-transition);
}
.wc-block-components-text-input input:focus-visible,
.wc-block-checkout__form input:focus-visible {
  border-color: var(--wlf-color-accent);
}
.wc-block-components-radio-control__option {
  border: 1px solid var(--wlf-color-line); border-radius: var(--wlf-radius-md);
  padding: var(--wlf-space-3) var(--wlf-space-4);
  transition: border-color var(--wlf-transition), background var(--wlf-transition);
}
.wc-block-components-radio-control__option:hover { border-color: var(--wlf-color-ink); }
.wc-block-components-radio-control__input:checked + .wc-block-components-radio-control__label-group,
.wc-block-components-radio-control__option:has(:checked) {
  border-color: var(--wlf-color-accent);
}

/* Bestellen-Button des Block-Checkouts — gleiche Hauptaktion-Optik wie
   der klassische Checkout-Button oben. */
.wc-block-components-checkout-place-order-button,
.wc-block-cart__submit-button {
  width: 100%;
  border-radius: var(--wlf-radius-pill);
  background: var(--wlf-color-accent); border-color: var(--wlf-color-accent);
  color: var(--wlf-color-accent-ink); font-weight: var(--wlf-weight-bold);
  transition: background var(--wlf-transition), border-color var(--wlf-transition);
}
.wc-block-components-checkout-place-order-button:hover,
.wc-block-cart__submit-button:hover {
  background: var(--wlf-color-accent-hover); border-color: var(--wlf-color-accent-hover);
}

/* ═══════════════════════════════════════════════════════════════════
   KONTO-SEITEN
   ═══════════════════════════════════════════════════════════════════ */
/* Navigation (Bestellungen, Adressen, Logout …) im Stil der Haupt-
   navigation — schmale Pillen, aktiver Punkt in Volltext-Kontrast. */
.woocommerce-MyAccount-navigation ul {
  list-style: none; margin: 0 0 var(--wlf-space-6); padding: 0;
  display: flex; flex-wrap: wrap; gap: .35rem;
  border-bottom: 1px solid var(--wlf-color-line);
  padding-bottom: var(--wlf-space-4);
}
.woocommerce-MyAccount-navigation ul li a {
  display: block; padding: .5rem .9rem; border-radius: var(--wlf-radius-pill);
  font-size: var(--wlf-text-sm); font-weight: var(--wlf-weight-medium);
  color: var(--wlf-color-ink-muted); text-decoration: none;
  transition: background var(--wlf-transition), color var(--wlf-transition);
}
.woocommerce-MyAccount-navigation ul li a:hover { background: var(--wlf-color-surface); color: var(--wlf-color-ink); }
.woocommerce-MyAccount-navigation ul li.is-active a {
  background: var(--wlf-color-ink); color: var(--af-on-dark);
}

/* Formulare: Login, Registrierung, Adressen, Passwort ändern — alle
   teilen sich .woocommerce-form-row / .woocommerce-Input. */
.woocommerce-form-row { margin: 0 0 var(--wlf-space-4); }
.woocommerce-form-row label {
  display: block; margin-bottom: .35rem;
  font-size: var(--wlf-text-sm); font-weight: var(--wlf-weight-medium); color: var(--wlf-color-ink);
}
.woocommerce-Input.woocommerce-Input--text,
.woocommerce-form-row select,
.woocommerce-form-row textarea {
  width: 100%; box-sizing: border-box;
  border: 1px solid var(--wlf-color-line); border-radius: var(--wlf-radius-md);
  padding: .7rem .9rem; font-family: inherit; font-size: var(--wlf-text-base);
  color: var(--wlf-color-ink); background: var(--wlf-color-bg);
  transition: border-color var(--wlf-transition);
}
.woocommerce-Input.woocommerce-Input--text:focus-visible { border-color: var(--wlf-color-accent); }
.woocommerce-form__label-for-checkbox {
  display: flex; align-items: center; gap: .5rem;
  font-size: var(--wlf-text-sm); color: var(--wlf-color-ink-muted); font-weight: var(--wlf-weight-normal);
}
.woocommerce-form-row .required { color: var(--wlf-color-danger); text-decoration: none; }

/* Login-/Bestellformular-Button im Haupt-Button-Stil (dunkel, wie
   .af-btn) statt Akzentfarbe — Login ist keine Kaufhandlung. */
.woocommerce-button.button,
.woocommerce-form-login__submit,
.woocommerce-form-register__submit {
  border-radius: var(--wlf-radius-pill);
  background: var(--wlf-color-ink); border-color: var(--wlf-color-ink); color: var(--af-on-dark);
}
.woocommerce-button.button:hover,
.woocommerce-form-login__submit:hover {
  background: color-mix(in srgb, var(--wlf-color-ink) 82%, var(--wlf-color-accent));
  border-color: color-mix(in srgb, var(--wlf-color-ink) 82%, var(--wlf-color-accent));
}

/* Bestellübersicht-Tabellen auf den Konto-Seiten nutzen dieselbe
   shop_table-Optik wie der Warenkorb — keine doppelte Definition nötig. */

/* ═══════════════════════════════════════════════════════════════════
   FEINSCHLIFF: STERNEBEWERTUNG
   Für den Stern selbst gibt es kein Marken-Token (weder Gold noch
   Petrol passen als Bewertungsfarbe) — ein warmes Gelb ist hier die
   allgemein verständliche Ausnahme von der Token-Pflicht.
   ═══════════════════════════════════════════════════════════════════ */
.star-rating { color: #e0a336; font-size: var(--wlf-text-sm); }
.star-rating span::before { color: #e0a336; }

/* ═══════════════════════════════════════════════════════════════════
   RESPONSIVES FEINTUNING < 640px
   Das meiste regelt der Grid-Autofill der Produktkarten und die
   Karten-Umwandlung der Warenkorb-Tabelle bereits selbst — hier nur,
   was sonst noch aus dem Ruder läuft.
   ═══════════════════════════════════════════════════════════════════ */
@media (max-width: 640px) {
  .woocommerce ul.products { grid-template-columns: 1fr 1fr; gap: var(--wlf-space-3); }
  .single-product .woocommerce-product-details__short-description,
  .woocommerce-tabs .woocommerce-Taaf-panel { max-width: none; }
  .summary.entry-summary form.cart { flex-direction: column; }
  .summary.entry-summary .quantity { width: 100%; }
  .summary.entry-summary .quantity .qty { width: 100%; }
  .cart_totals, .cart-collaterals .cart_totals { padding: var(--wlf-space-5); }
}

/* Ganz schmale Geräte: Produktraster einspaltig, damit Titel/Preis
   nicht auf zwei Wörter pro Zeile umbrechen. */
@media (max-width: 420px) {
  .woocommerce ul.products { grid-template-columns: 1fr; }
}

/* ═══════════════════════════════════════════════════════════════════
   BEWEGUNG REDUZIEREN
   design.css setzt --wlf-transition bereits global auf 0ms; das allein
   stoppt aber keine transform-Animation wie das Karten-Anheben beim
   Hover — die muss hier zusätzlich ausgeschaltet werden.
   ═══════════════════════════════════════════════════════════════════ */
@media (prefers-reduced-motion: reduce) {
  .woocommerce ul.products li.product:hover { transform: none; }
}

/* ═══════════════════════════════════════════════════════════════════
   NACHTRAG — zwei Kollisionen mit WooCommerce' eigenen Stylesheets
   ═══════════════════════════════════════════════════════════════════
   1. woocommerce-layout.css setzt auf die Produktkarten `width: 22.05%`
      und `float: left`. Solange das Raster ein Flexbox-/Float-Layout war,
      passte das. In einem CSS-Grid bezieht sich die Prozentbreite aber auf
      die SPALTE, nicht auf die Zeile — aus 263px Spalte wurden 58px Karte.
      Deshalb muss die Breite hier ausdrücklich zurückgenommen werden.
   2. Die Marken-/Logo-Verlinkung im Kopfbereich liegt außerhalb von
      WooCommerce und darf die Akzentfarbe nicht erben.
   ─────────────────────────────────────────────────────────────────── */

.woocommerce ul.products li.product,
.woocommerce-page ul.products li.product {
	width: auto;
	float: none;
	margin: 0;
	clear: none;
}

/* WooCommerce raeumt jeder 4. Karte `clear: both` ein — im Grid stiftet das
   nur Unordnung. */
.woocommerce ul.products li.product.first,
.woocommerce ul.products li.product.last { clear: none; margin: 0; }

/* Bild darf die Karte fuellen; Woo gibt ihm sonst eine feste Hoehe. */
.woocommerce ul.products li.product a img {
	width: 100%;
	height: auto;
	display: block;
	margin: 0;
	box-shadow: none;
}

/* WooCommerce raeumt dem Produktraster einen Clearfix ein
   (ul.products::before/::after mit display:table). In einem CSS-Grid werden
   daraus zwei LEERE Rasterzellen — die erste Karte rutscht in Spalte 2. */
.woocommerce ul.products::before,
.woocommerce ul.products::after,
.woocommerce-page ul.products::before,
.woocommerce-page ul.products::after { content: none; display: none; }

/* ═══════════════════════════════════════════════════════════════════
   Produktseite: Passform und Varianten
   ═══════════════════════════════════════════════════════════════════ */

.af-passform {
	margin: 1.5rem 0;
	padding: 1.1rem 1.25rem;
	border: 1px solid var(--wlf-color-line);
	border-radius: var(--wlf-radius-lg);
	background: var(--wlf-color-surface);
}
.af-passform__zeile { margin: 0; font-size: .97rem; line-height: 1.55; }
.af-passform__zeile strong { display: block; font-size: 1.05rem; margin-bottom: .2rem; }
.af-passform__zeile--ja strong    { color: #1f6152; }
.af-passform__zeile--teils strong { color: #8a5a1e; }
.af-passform__zeile--nein strong  { color: #8d3128; }
.af-passform__wechsel { margin: .7rem 0 0; font-size: .85rem; }
.af-passform__wechsel a { color: var(--wlf-color-ink-muted); }
/* Die Suche in der Passform-Box ist kompakter als die auf der Startseite. */
.af-passform .wlf-fitment-search { background: none; border: 0; padding: 0; margin-top: .9rem; }
.af-passform .wlf-fitment-search__intro { display: none; }
.af-passform .wlf-fitment-search__fields { display: grid; grid-template-columns: 1fr 1fr; gap: .6rem; margin-bottom: .7rem; }
.af-passform .wlf-field { display: flex; flex-direction: column; gap: .25rem; }
.af-passform .wlf-field__label { font-size: .68rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--wlf-color-ink-muted); }
.af-passform .wlf-field__input {
	width: 100%; box-sizing: border-box; padding: .55rem .7rem;
	border: 1px solid var(--wlf-color-line); border-radius: var(--wlf-radius-md);
	font-family: inherit; font-size: .98rem; font-weight: 600; background: var(--wlf-color-bg);
}
.af-passform .wlf-btn, .af-passform button[type="submit"] {
	width: 100%; padding: .6rem 1.2rem; border: 0; border-radius: var(--wlf-radius-pill, 999px);
	background: var(--wlf-color-ink); color: var(--af-on-dark); font-family: inherit; font-weight: 600; cursor: pointer;
}

.af-varianten { margin: 1.5rem 0; display: flex; flex-direction: column; gap: 1.15rem; }
.af-varianten__titel {
	display: block; font-size: .72rem; font-weight: 700; letter-spacing: .1em;
	text-transform: uppercase; color: var(--wlf-color-ink-muted); margin-bottom: .55rem;
}
.af-varianten__farben { display: flex; flex-wrap: wrap; gap: .6rem; }
.af-farbe {
	display: flex; flex-direction: column; align-items: center; gap: .3rem;
	width: 72px; text-decoration: none; color: var(--wlf-color-ink-muted);
	font-size: .68rem; line-height: 1.25; text-align: center;
}
.af-farbe img {
	width: 64px; height: 64px; object-fit: contain; padding: 4px;
	background: var(--wlf-color-surface); border: 2px solid transparent;
	border-radius: var(--wlf-radius-md); transition: border-color var(--wlf-transition);
}
.af-farbe:hover img { border-color: var(--wlf-color-line); }
.af-farbe.is-aktuell img { border-color: var(--wlf-color-ink); }
.af-farbe.is-aktuell { color: var(--wlf-color-ink); font-weight: 600; }

.af-varianten__groessen { display: flex; flex-wrap: wrap; gap: .45rem; }
.af-groesse {
	padding: .45rem .85rem; border: 1px solid var(--wlf-color-line);
	border-radius: var(--wlf-radius-pill, 999px); font-size: .88rem; font-weight: 600;
	text-decoration: none; color: var(--wlf-color-ink); background: var(--wlf-color-bg);
	transition: border-color var(--wlf-transition), background var(--wlf-transition);
}
.af-groesse:hover { border-color: var(--wlf-color-ink); }
.af-groesse.is-aktuell { background: var(--wlf-color-ink); border-color: var(--wlf-color-ink); color: var(--af-on-dark); }

@media (max-width: 520px) {
	.af-passform .wlf-fitment-search__fields { grid-template-columns: 1fr; }
}

/* ═══════════════════════════════════════════════════════════════════
   WooCommerce' eigenes Farbschema auf unsere Tokens umstellen
   ═══════════════════════════════════════════════════════════════════
   WooCommerce 11 faerbt Kaufen-Knopf und Preis ueber eigene Variablen
   (--wc-primary violett, --wc-highlight oliv). Die einzeln per Selektor
   zu ueberschreiben ist ein Wettruesten — an den Variablen anzusetzen
   erledigt es an einer Stelle und wirkt auch dort, wo wir gar nicht
   hinsehen (Block-Warenkorb, Konto, Meldungen).
   ─────────────────────────────────────────────────────────────────── */
:root,
.woocommerce,
.wc-block-components-notice-banner {
	--wc-green:       var(--wlf-color-accent);
	--wc-red:         #a3342a;
	--wc-orange:      #a9682f;
	--wc-blue:        var(--wlf-color-accent);
	--wc-primary:     var(--wlf-color-ink);
	--wc-primary-text: var(--wlf-color-accent-ink);
	--wc-secondary:   var(--wlf-color-surface);
	--wc-secondary-text: var(--wlf-color-ink);
	--wc-highlight:   var(--wlf-color-ink);
	--wc-highlight-text: var(--wlf-color-accent-ink);
	--wc-content-bg:  var(--wlf-color-bg);
	--wc-subtext:     var(--wlf-color-ink-muted);
	--wc-form-border-color: var(--wlf-color-line);
	--wc-form-color-background: var(--wlf-color-bg);
}

/* Preis: WooCommerce nimmt --wc-highlight, wir wollen die Textfarbe. */
.woocommerce div.product p.price,
.woocommerce div.product span.price,
.woocommerce ul.products li.product .price {
	color: var(--wlf-color-ink);
	font-weight: 700;
	font-variant-numeric: tabular-nums;
}

/* Kaufen-Knopf in der Pillenform des uebrigen Shops. */
.woocommerce div.product form.cart .button,
.woocommerce .single_add_to_cart_button {
	background: var(--wlf-color-ink);
	color: var(--af-on-dark);
	border: 1px solid var(--wlf-color-ink);
	border-radius: var(--wlf-radius-pill, 999px);
	padding: .85rem 1.8rem;
	font-weight: 600;
	font-size: .98rem;
	transition: background var(--wlf-transition), border-color var(--wlf-transition);
}
.woocommerce div.product form.cart .button:hover,
.woocommerce .single_add_to_cart_button:hover { background: color-mix(in srgb, var(--wlf-color-ink) 82%, var(--wlf-color-accent));
  border-color: color-mix(in srgb, var(--wlf-color-ink) 82%, var(--wlf-color-accent)); }

/* Mengenfeld neben dem Knopf statt darueber. */
.woocommerce div.product form.cart { display: flex; flex-wrap: wrap; align-items: center; gap: .75rem; margin: 1.5rem 0; }
.woocommerce div.product form.cart .quantity { margin: 0; }
.woocommerce div.product form.cart .quantity .qty {
	width: 5rem; padding: .8rem .6rem; text-align: center;
	border: 1px solid var(--wlf-color-line); border-radius: var(--wlf-radius-md);
	font-family: inherit; font-size: 1rem; font-weight: 600; background: var(--wlf-color-bg);
}

/* Produktseite breiter aufteilen: Bild links gross, Angaben rechts. */
@media (min-width: 900px) {
	.woocommerce div.product { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); column-gap: clamp(2rem, 4vw, 3.5rem); align-items: start; }
	.woocommerce div.product .woocommerce-product-gallery { width: auto; float: none; margin: 0; grid-column: 1; }
	.woocommerce div.product .summary { width: auto; float: none; margin: 0; grid-column: 2; }
	.woocommerce div.product .woocommerce-tabs,
	.woocommerce div.product .related,
	.woocommerce div.product .up-sells { grid-column: 1 / -1; }
}
.woocommerce div.product .woocommerce-product-gallery__image img {
	width: 100%; height: auto; border-radius: var(--wlf-radius-lg);
	background: var(--wlf-color-surface);
}
.woocommerce div.product .product_title { font-size: clamp(1.5rem, 3vw, 2.1rem); letter-spacing: -.03em; margin-bottom: .5rem; }
.woocommerce div.product .woocommerce-product-details__short-description { color: var(--wlf-color-ink-muted); font-size: .95rem; line-height: 1.6; }

/* Fahrzeugbalken und Suchhinweis über der Artikelliste */
.woocommerce .wlf-vehicle-banner,
.woocommerce .af-felgen-suche { margin-bottom: 1.5rem; }
.af-felgen-suche--schmal { max-width: 100%; }
.af-suche-frage { margin: 0 0 .9rem; font-size: .95rem; color: var(--wlf-color-ink); font-weight: 600; }

/* ═══════════════════════════════════════════════════════════════════
   DER KAUFMOMENT
   ═══════════════════════════════════════════════════════════════════ */

/* ── Zusagen unter dem Kaufknopf ─────────────────────────────────── */
.af-promises {
  list-style: none; margin: 1.4rem 0 0; padding: 1.1rem 1.2rem;
  display: grid; gap: .85rem;
  background: var(--wlf-color-surface);
  border: 1px solid var(--wlf-color-line);
  border-radius: var(--wlf-radius-md);
}
.af-promises__item { display: flex; align-items: flex-start; gap: .7rem; margin: 0; }
.af-promises__item .af-ikon { width: 20px; height: 20px; margin-top: 1px; color: var(--wlf-color-accent); }
.af-promises__item span { display: flex; flex-direction: column; gap: .1rem; }
.af-promises__item strong { font-size: .92rem; font-weight: 700; }
.af-promises__item em { font-style: normal; font-size: .86rem; color: var(--wlf-color-ink-muted); }

/* ── Mengenschritte ──────────────────────────────────────────────── */
.woocommerce div.product form.cart .quantity {
  display: inline-flex; align-items: stretch;
  border: 1px solid var(--wlf-color-line); border-radius: var(--wlf-radius-pill);
  overflow: hidden; background: var(--wlf-color-bg);
}
.af-qty-step {
  display: inline-flex; align-items: center; justify-content: center;
  width: 42px; padding: 0; flex: none;
  background: none; border: 0; cursor: pointer; color: var(--wlf-color-ink);
}
.af-qty-step:hover { background: var(--wlf-color-surface); }
.af-qty-step .af-ikon { width: 17px; height: 17px; }
.woocommerce div.product form.cart .quantity input.qty {
  width: 46px; height: 46px; padding: 0; margin: 0;
  border: 0; background: none; text-align: center;
  font-size: 1rem; font-weight: 600; color: var(--wlf-color-ink);
  /* Die Pfeilchen des Browsers stünden neben unseren eigenen Knöpfen. */
  -moz-appearance: textfield; appearance: textfield;
}
.woocommerce div.product form.cart .quantity input.qty::-webkit-outer-spin-button,
.woocommerce div.product form.cart .quantity input.qty::-webkit-inner-spin-button {
  -webkit-appearance: none; margin: 0;
}

/* ── Klebrige Kaufleiste ─────────────────────────────────────────── */
.af-stickybuy {
  position: fixed; inset: auto 0 0 0; z-index: 120;
  display: flex; align-items: center; gap: 1rem;
  padding: .7rem clamp(1rem, 4vw, 1.5rem);
  padding-bottom: calc(.7rem + env(safe-area-inset-bottom, 0px));
  background: color-mix(in srgb, var(--wlf-color-bg) 96%, transparent);
  backdrop-filter: saturate(180%) blur(12px);
  border-top: 1px solid var(--wlf-color-line);
  transform: translateY(110%);
  transition: transform .22s ease;
}
.af-stickybuy.is-visible { transform: translateY(0); }
.af-stickybuy__info { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; }
.af-stickybuy__info strong {
  font-size: .88rem; font-weight: 700;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.af-stickybuy__info span { font-size: .92rem; color: var(--wlf-color-ink-muted); }
.af-stickybuy__info span .amount { color: var(--wlf-color-ink); font-weight: 700; }
.af-stickybuy .af-btn { flex: none; padding-inline: 1.3rem; }

/* Auf breiten Geräten steht der echte Kaufknopf ohnehin im Bild. */
@media (min-width: 900px) { .af-stickybuy { display: none; } }
@media (prefers-reduced-motion: reduce) { .af-stickybuy { transition: none; } }

/* ── Die Produktkarte im Raster ──────────────────────────────────── */
.af-specs {
  list-style: none; margin: .5rem 0 0; padding: 0;
  display: flex; flex-wrap: wrap; gap: .3rem;
}
.af-specs li {
  padding: .2rem .5rem; margin: 0;
  background: var(--wlf-color-surface); border: 1px solid var(--wlf-color-line);
  border-radius: var(--wlf-radius-sm);
  font-size: .74rem; font-weight: 600; color: var(--wlf-color-ink-muted);
  font-variant-numeric: tabular-nums;
}

.af-pricenote {
  display: block; margin-top: .1rem;
  font-size: .72rem; color: var(--wlf-color-ink-muted);
}

/* Die Marke sitzt über dem Bild, nicht darunter — dort wird zuerst
   hingesehen, und dort verdrängt sie keinen Text. */
.woocommerce ul.products li.product { position: relative; }
.af-fitmark {
  position: absolute; top: .6rem; left: .6rem; z-index: 2;
  display: inline-flex; align-items: center; gap: .3rem;
  padding: .25rem .6rem; border-radius: var(--wlf-radius-pill);
  font-size: .72rem; font-weight: 700;
  background: var(--wlf-color-bg); border: 1px solid var(--wlf-color-line);
}
.af-fitmark .af-ikon { width: 14px; height: 14px; }
.af-fitmark--ok { color: var(--wlf-color-success); border-color: color-mix(in srgb, var(--wlf-color-success) 40%, transparent); }
.af-fitmark--pruefen { color: var(--wlf-color-warning); border-color: color-mix(in srgb, var(--wlf-color-warning) 40%, transparent); }

.af-cardlink {
  display: inline-flex; align-items: center; gap: .25rem;
  margin-top: .55rem;
  font-size: .82rem; font-weight: 600; text-decoration: none;
  color: var(--wlf-color-ink-muted);
}
.af-cardlink:hover { color: var(--af-gold-text); }
.af-cardlink .af-ikon { width: 15px; height: 15px; }

/* ═══════════════════════════════════════════════════════════════════
   DIE KARTE, NACH DEM VORBILD VON FF-WHEELS UND FELGENFORUM
   ═══════════════════════════════════════════════════════════════════
   Übernommen ist der Aufbau und die Bewegung, nicht die Farbwelt: Beide
   Vorbilder sind dunkle Shops mit Weiß als einziger Primärfarbe. Der
   Artform muss in jeder Vorlage funktionieren, also kommt hier keine
   Farbe vor, die nicht aus einem Token stammt.
   ═══════════════════════════════════════════════════════════════════ */

/* Der eingerückte Bildrahmen. Die 4 px Radiusdifferenz bei 8 px Abstand
   ergeben konzentrische Ecken — mit gleichem Radius sähe es falsch aus. */
.woocommerce ul.products li.product .af-card-media {
  position: relative;
  margin: .5rem;
  border: 1px solid var(--wlf-color-line-soft);
  border-radius: calc(var(--wlf-radius-lg) - 4px);
  overflow: hidden;
  background: var(--wlf-color-surface);
  transition: border-color var(--wlf-transition);
}
.woocommerce ul.products li.product:hover .af-card-media { border-color: var(--wlf-color-line); }

.woocommerce ul.products li.product .af-card-media img {
  padding: var(--wlf-space-4);
  /* Deutlich langsamer als alles andere an der Karte. Der schwere Zoom
     gegen die schnellen Rahmen lässt die Bewegung ruhig wirken statt
     zappelig — bei gleicher Dauer sieht es nach Sprung aus. */
  transition: transform .7s cubic-bezier(.2, .6, .2, 1);
}
.woocommerce ul.products li.product:hover .af-card-media img { transform: scale(1.045); }

/* Die Passform-Marke liegt jetzt im Bildrahmen, nicht auf der Karte. */
.woocommerce ul.products li.product .af-card-media .af-fitmark { top: .55rem; left: .55rem; }

/* Gleiche Grundlinie über die ganze Zeile: Zwei Zeilen Titel sind
   reserviert, der Preisblock wird nach unten geschoben. Ohne das tanzen
   die Preise benachbarter Karten je nach Titellänge. */
.woocommerce ul.products li.product .woocommerce-loop-product__title {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 2.6em;
}

.woocommerce ul.products li.product .price {
  border-top: 1px solid var(--wlf-color-line-soft);
  padding-top: .6rem;
  font-size: 1.12rem;
  /* Enges Tracking auf Zahlen, weites auf Kleinschrift — dieser Kontrast
     ist das, was beide Vorbilder wertig aussehen lässt. */
  letter-spacing: -.02em;
}

/* Kleinschrift bekommt Sperrung, nicht Fettung. */
.af-specs li { letter-spacing: .04em; }
.af-pricenote { letter-spacing: .02em; }

/* Der Hinweis, dass vier Stück voreingestellt sind. Er steht neben dem
   Feld, nicht darunter: Eine Vorgabe, die man erst nach dem Scrollen
   bemerkt, ist keine Vorgabe, sondern eine Falle. */
.af-satz {
  align-self: center; margin-left: .75rem;
  font-size: .82rem; font-weight: 600; color: var(--wlf-color-ink-muted);
  white-space: nowrap;
}

/* Die Galerie läuft mit, solange rechts noch Angaben kommen. Ohne das
   sieht man beim Lesen der technischen Daten die Felge nicht mehr, um
   die es geht. */
@media (min-width: 993px) {
  .woocommerce div.product div.images {
    position: sticky;
    top: calc(72px + 1.5rem);
    align-self: start;
  }
}

/* Statusfarben nach einer Formel statt nach Gefühl: Fläche 8 %, Rahmen
   30 %, Text voll. Beide Vorbildshops halten das für jeden Zustand durch —
   dadurch sprechen Passform-Marken, Lagerampel und Meldungen dieselbe
   Sprache, auch wenn die Vorlage die Farbe wechselt. */
.af-fitmark--ok {
  background: color-mix(in srgb, var(--wlf-color-success) 8%, var(--wlf-color-bg));
  border-color: color-mix(in srgb, var(--wlf-color-success) 30%, transparent);
  color: var(--wlf-color-success);
}
.af-fitmark--pruefen {
  background: color-mix(in srgb, var(--wlf-color-warning) 8%, var(--wlf-color-bg));
  border-color: color-mix(in srgb, var(--wlf-color-warning) 30%, transparent);
  color: var(--wlf-color-warning);
}

/* FEHLER: Der Details-Link hing mit 1 px Abstand am Kartenrand — er wird
   über woocommerce_after_shop_loop_item ausgegeben und liegt damit
   ausserhalb des Innenabstands, den der Kartenkörper setzt. */
.woocommerce ul.products li.product .af-cardlink {
  margin: 0 var(--wlf-space-4) var(--wlf-space-4);
  padding-top: .1rem;
}
