@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@500;600;700&family=IBM+Plex+Sans:wght@400;500;600;700&display=swap');

:root {
    --bg: #f2f3f5;
    --card: #ffffff;
    --ink: #14171c;
    --muted: #6b7280;
    --line: #e3e6ea;
    --brand: #e2001a;
    --brand-dark: #b00014;
    --accent: #c8102e;
    --ok: #1f9d55;
    --dark: #14171c;
    --radius: 0px;
    --shadow: 0 1px 3px rgba(16,24,40,.08), 0 1px 2px rgba(16,24,40,.06);
    --head: "Space Grotesk", system-ui, sans-serif;
}
* { box-sizing: border-box; }
body {
    margin: 0;
    font-family: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
    background: var(--bg);
    color: var(--ink);
    line-height: 1.5;
}
a { color: inherit; text-decoration: none; }

/* Kräftige, „männliche" Überschriften */
h1, h2, h3, .cat-head, .vd-title { font-family: var(--head); text-transform: uppercase; letter-spacing: .02em; font-weight: 700; }

/* Topbar (dunkel – passend zum Logo) */
.topbar {
    display: flex; align-items: center; justify-content: space-between;
    background: var(--dark); border-bottom: 3px solid var(--brand);
    padding: 0 24px; height: 66px; position: sticky; top: 0; z-index: 10;
}
.logo { display: flex; align-items: center; gap: 10px; font-family: var(--head); font-size: 20px; font-weight: 700; color: #fff; text-transform: uppercase; letter-spacing: .04em; }
.logo img { height: 48px; width: auto; display: block; }
.topbar-right { display: flex; align-items: center; gap: 14px; }
.cart-link { position: relative; font-weight: 700; color: #fff; font-size: 20px; }
.cart-count {
    background: var(--brand); color: #fff; border-radius: 0;
    font-size: 12px; padding: 1px 7px; margin-left: 2px; vertical-align: top;
}
.cart-count[hidden] { display: none; }
.cart-toast {
    position: fixed; left: 50%; bottom: 28px; transform: translateX(-50%) translateY(20px);
    background: #1f9d3a; color: #fff; padding: 11px 22px; font-weight: 700; font-size: 14px;
    box-shadow: 0 8px 24px rgba(0,0,0,.28); opacity: 0; pointer-events: none;
    transition: opacity .2s ease, transform .2s ease; z-index: 2000;
}
.cart-toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
.badge { font-size: 11px; font-weight: 700; padding: 4px 10px; border-radius: 0; letter-spacing: .05em; }
.badge-mock { background: #3a3320; color: #f6c945; }
.badge-live { background: #16331f; color: #46d17e; }

/* Artikelsuche in der Kopfleiste */
.art-search { flex: 1; max-width: 520px; margin: 0 24px; display: flex; }
.art-search input {
    flex: 1; border: 1px solid var(--line); border-right: none; border-radius: 0;
    padding: 10px 14px; font-size: 15px; min-width: 0;
}
.art-search input:focus { outline: none; border-color: var(--accent); }
.art-search button {
    border: none; background: var(--brand); color: #fff; padding: 0 18px; border-radius: 0; cursor: pointer; font-size: 16px;
}
.art-search button:hover { background: var(--brand-dark); }

/* Aktuelles Fahrzeug (Chip) */
.veh-chip {
    display: inline-flex; align-items: center; gap: 6px; background: #eef2f6;
    border: 1px solid var(--line); border-radius: 0; padding: 5px 10px; font-size: 13px; max-width: 280px;
}
.veh-chip span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.veh-x { color: var(--muted); cursor: pointer; font-weight: 700; padding-left: 2px; }
.veh-x:hover { color: var(--brand); }
.veh-chip-wrap { position: relative; }
.veh-chip-wrap summary.veh-chip { cursor: pointer; list-style: none; }
.veh-chip-wrap summary.veh-chip::-webkit-details-marker { display: none; }
.veh-caret { display: inline-block; color: var(--muted); font-size: 11px; transition: transform .15s; }
.veh-chip-wrap[open] .veh-caret { transform: rotate(180deg); }
.veh-menu { position: absolute; top: calc(100% + 6px); right: 0; z-index: 60; width: 340px; max-height: 65vh; overflow-y: auto; background: #fff; border: 1px solid var(--line); box-shadow: 0 10px 28px rgba(0,0,0,.20); }
.veh-menu-head { padding: 8px 12px; font-size: 11px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); background: #f5f7f9; border-bottom: 1px solid var(--line); position: sticky; top: 0; }
.veh-menu-item { display: flex; flex-direction: column; gap: 1px; padding: 9px 12px; border-bottom: 1px solid #eef1f4; color: #1c2128; }
.veh-menu-item:last-child { border-bottom: 0; }
.veh-menu-item:hover { background: #eef2f6; }
.veh-menu-item.current { background: #fdeaea; }
.vmi-label { font-size: 13px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.vmi-meta { font-size: 11.5px; color: var(--muted); }

/* Navigationsleiste */
.mainnav { background: #20242b; padding: 0 24px; display: flex; gap: 2px; position: sticky; top: 66px; z-index: 9; }
.mainnav a { color: #c4c9d2; padding: 13px 18px; font-size: 14px; font-weight: 600; text-transform: uppercase; letter-spacing: .04em; font-family: var(--head); }
.mainnav a:hover { background: rgba(255,255,255,.07); color: #fff; }
.mainnav a.active { color: #fff; box-shadow: inset 0 -3px 0 var(--brand); }
.mainnav .nav-user { margin-left: auto; display: flex; align-items: center; color: #c4c9d2; font-size: 13.5px; padding: 0 14px; }
.mainnav a.nav-logout { color: #fff; }

/* Login-Seite */
.login-body { min-height: 100vh; display: flex; align-items: center; justify-content: center; background: #1c1c1c; padding: 20px; margin: 0; }
.login-card { background: var(--card); border: 1px solid var(--line); box-shadow: 0 12px 44px rgba(0,0,0,.35); padding: 34px 30px; width: 100%; max-width: 380px; }
.login-logo { text-align: center; margin-bottom: 6px; font-family: var(--head); font-weight: 800; font-size: 22px; }
.login-logo img { max-height: 56px; width: auto; }
.login-title { font-size: 19px; text-align: center; margin: 8px 0 18px; }
.login-form label { display: block; font-size: 14px; font-weight: 600; margin-bottom: 13px; }
.login-form input { width: 100%; box-sizing: border-box; margin-top: 5px; padding: 11px 12px; border: 1px solid var(--line); border-radius: 0; font-size: 15px; }
.login-form input:focus { outline: none; border-color: var(--brand); }
.login-btn { width: 100%; padding: 12px; background: var(--brand); color: #fff; border: 0; border-radius: 0; font-weight: 700; font-size: 15px; cursor: pointer; text-transform: uppercase; letter-spacing: .03em; font-family: var(--head); }
.login-btn:hover { filter: brightness(1.08); }
.login-error { background: #fdecec; border: 1px solid #e6a3a3; color: #a11; padding: 9px 12px; font-size: 14px; margin-bottom: 14px; }
.login-hint { color: var(--muted); font-size: 12.5px; text-align: center; margin-top: 16px; }

/* Zugänge-Verwaltung */
.acc-table { border-collapse: collapse; margin: 12px 0; min-width: 360px; }
.acc-table th, .acc-table td { text-align: left; padding: 8px 14px; border-bottom: 1px solid var(--line); font-size: 14px; }
.acc-table th { color: var(--muted); font-weight: 600; }
.acc-form { display: flex; gap: 14px; align-items: flex-end; flex-wrap: wrap; margin-top: 8px; }
.acc-form label { display: flex; flex-direction: column; gap: 5px; font-size: 13px; font-weight: 600; }
.acc-form input[type="text"] { padding: 9px 11px; border: 1px solid var(--line); border-radius: 0; font-size: 14px; }
.acc-form .acc-check { flex-direction: row; align-items: center; gap: 7px; }
.acc-pw { display: flex; gap: 6px; align-items: center; }
.acc-pw input { padding: 7px 9px; border: 1px solid var(--line); border-radius: 0; font-size: 13.5px; }
.acc-sync { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; background: #fff6e6; border: 1px solid #f0c860; padding: 12px 14px; margin: 14px 0 18px; }
.acc-sync .muted { font-size: 13px; }

/* Fahrzeugauswahl-Seite (PartsFinder-Stil) */
.fahrzeug-page { max-width: 920px; margin: 0 auto; }
.fz-title { text-align: center; margin: 4px 0 24px; }
.fs-row {
    display: grid; grid-template-columns: 160px 1fr 130px; gap: 16px; align-items: center;
    padding: 16px 0; border-bottom: 1px solid var(--line);
}
.fs-row > label { font-weight: 600; color: var(--ink); }
.fs-fields { display: flex; gap: 12px; }
.fs-fields input, .fs-selects select {
    width: 100%; border: 1px solid var(--line); border-radius: 0; padding: 11px 14px; font-size: 15px; background: #fff; min-width: 0;
}
.fs-fields input:focus, .fs-selects select:focus { outline: none; border-color: var(--accent); }
.fs-kba { max-width: 420px; }
.fs-selects { flex-direction: column; }
.fs-row-select { align-items: start; }
.fs-classes { display: flex; gap: 8px; justify-content: flex-start; margin-bottom: 6px; }
.class-btn {
    border: 1px solid var(--line); background: #fff; border-radius: 0;
    padding: 9px 14px; font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: .03em;
    cursor: pointer; color: var(--ink);
}
.class-btn:hover { border-color: var(--brand); }
.class-btn.active { background: var(--ink); border-color: var(--ink); color: #fff; }
.btn-search {
    border: none; background: var(--brand); color: #fff; border-radius: 0; padding: 11px 18px;
    font-size: 14px; font-weight: 700; text-transform: uppercase; letter-spacing: .03em; cursor: pointer; height: fit-content;
}
.btn-search:hover { background: var(--brand-dark); }

/* Promo rechts */
.promo-card {
    background: linear-gradient(160deg, var(--ink), #2b3a5e); color: #fff; border-radius: var(--radius);
    padding: 22px; box-shadow: var(--shadow);
}
.promo-badge { display: inline-block; background: var(--brand); color: #fff; font-weight: 700; font-size: 12px; padding: 3px 10px; border-radius: 0; }
.promo-card h3 { margin: 12px 0 6px; font-size: 22px; }
.promo-card p { margin: 0; color: #cdd6e6; font-size: 14px; line-height: 1.5; }

@media (max-width: 800px) {
    .fahrzeug-page { grid-template-columns: 1fr; }
    .fs-row { grid-template-columns: 1fr; gap: 8px; }
    .fs-classes { justify-content: flex-start; }
    .art-search { display: none; }
}

/* Layout */
.container { max-width: 1280px; margin: 0 auto; padding: 24px; }
h1 { font-size: 26px; margin: 8px 0 20px; }
.muted { color: var(--muted); }
.breadcrumb { font-size: 14px; color: var(--muted); margin-bottom: 16px; }
.breadcrumb a { color: var(--accent); }
.breadcrumb .sep { margin: 0 8px; }
.breadcrumb .bc-back { display: inline-block; background: #20242b; color: #fff; padding: 5px 13px; margin-right: 14px; font-weight: 600; border-radius: 0; }
.breadcrumb .bc-back:hover { background: var(--brand); color: #fff; }

.hero { margin-bottom: 24px; }
.hero h1 { margin-bottom: 4px; }
.hero p { color: var(--muted); margin: 0; }

/* Tiles (Hersteller / Warengruppen) */
.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 14px; }
.tile {
    background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
    padding: 22px 18px; font-weight: 600; text-align: center; box-shadow: var(--shadow);
    transition: .12s;
}
.tile:hover { border-color: var(--brand); transform: translateY(-2px); }
.tiles-manu .tile { font-size: 18px; }

/* Listen (Modelle / Motorisierungen) */
.list { display: flex; flex-direction: column; gap: 8px; }
.row {
    display: flex; flex-direction: column; background: var(--card);
    border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 18px;
    box-shadow: var(--shadow); transition: .12s;
}
.row:hover { border-color: var(--brand); }
.row-main { font-weight: 600; }
.row-sub { font-size: 14px; color: var(--muted); }

/* Artikel-Grid */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 16px; }
.card {
    background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
    padding: 16px; box-shadow: var(--shadow); transition: .12s; display: flex; flex-direction: column;
}
.card:hover { border-color: var(--brand); transform: translateY(-2px); }
.card-img, .detail-image img, .card-img img { width: 100%; }
.card-img { height: 120px; display: flex; align-items: center; justify-content: center; margin-bottom: 10px; }
.card-img img { height: 120px; object-fit: contain; }
.noimg {
    width: 100%; height: 120px; background: #f0f2f5; border-radius: 0;
    display: flex; align-items: center; justify-content: center; color: var(--muted); font-size: 14px;
}
.card-brand { font-size: 12px; font-weight: 700; color: var(--accent); text-transform: uppercase; }
.card-name { font-weight: 600; margin: 4px 0; flex: 1; }
.card-artno { font-size: 13px; color: var(--muted); }
.card-price { font-size: 18px; font-weight: 700; margin-top: 8px; }

/* Detail */
.detail { display: grid; grid-template-columns: 320px 1fr; gap: 32px; background: var(--card);
    border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; box-shadow: var(--shadow); }
.detail-image { display: flex; align-items: flex-start; justify-content: center; }
.detail-image img { max-height: 300px; object-fit: contain; }
.detail-info .brand { display: flex; align-items: center; gap: 10px; font-weight: 700; color: var(--accent); text-transform: uppercase; font-size: 13px; }
.brand-logo-lg { max-height: 34px; max-width: 130px; object-fit: contain; }
.detail-info h1 { margin: 6px 0; }
.artno { color: var(--muted); margin-bottom: 12px; }
.desc { margin: 12px 0 20px; }
.price-row { display: flex; align-items: baseline; gap: 16px; margin-bottom: 12px; }
.price { font-size: 28px; font-weight: 800; }
.price-list { color: var(--muted); font-size: 14px; }
.buy-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 20px; }
.add-form { display: inline-flex; align-items: center; gap: 12px; }
.qty-label { font-size: 13px; color: var(--muted); display: inline-flex; align-items: center; gap: 7px; text-transform: uppercase; letter-spacing: .03em; }
.qty-input { width: 66px; padding: 9px 8px; border: 1px solid #c7ccd4; border-radius: 0; font-size: 15px; font-weight: 700; text-align: center; }
.oe-list { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.chip { background: #eef2f6; border-radius: 0; padding: 4px 10px; font-size: 13px; font-family: monospace; color: var(--ink); text-decoration: none; }
a.chip:hover { background: #e2e8f0; color: var(--brand); }

/* Verknüpfte Fahrzeuge: eigenes Fenster */
.veh-link { margin-top: 16px; }
.veh-overlay {
    position: fixed; inset: 0; background: rgba(16,24,40,.55); z-index: 1050;
    display: none; align-items: flex-start; justify-content: center; padding: 28px 20px;
}
.veh-overlay.open { display: flex; }
.veh-window {
    position: relative; background: #fff; border-radius: 0; width: 100%; max-width: 1120px; height: 86vh;
    display: flex; flex-direction: column; overflow: hidden; box-shadow: 0 24px 70px rgba(0,0,0,.35);
}
.veh-close {
    position: absolute; top: 12px; right: 14px; width: 36px; height: 36px; border: none; border-radius: 0;
    background: transparent; color: var(--ink); font-size: 20px; cursor: pointer; z-index: 2;
}
.veh-close:hover { background: #f2f3f5; }
.veh-window-content { display: flex; flex-direction: column; flex: 1; min-height: 0; }
.veh-loading { padding: 40px; text-align: center; color: var(--muted); }
.vehmodal { display: flex; flex-direction: column; flex: 1; min-height: 0; }
.vehmodal-head { display: flex; align-items: baseline; gap: 14px; padding: 16px 56px 16px 20px; border-bottom: 1px solid var(--line); }
.vehmodal-title { font-family: var(--head); font-weight: 600; font-size: 18px; }
.vehmodal-total { color: var(--muted); font-size: 13px; }
.vehmodal-empty { padding: 30px 20px; }
.vehmodal-body { display: flex; flex: 1; min-height: 0; }
.vehmodal-side { width: 210px; flex: none; border-right: 1px solid var(--line); overflow-y: auto; padding: 8px; }
.vm-manu { display: flex; align-items: center; gap: 6px; width: 100%; text-align: left; padding: 9px 12px; border: none; background: none; cursor: pointer; font-weight: 700; color: var(--ink); border-radius: 0; font-size: 14px; }
.vm-manu:hover { background: #f2f3f5; }
.vm-manu.active { color: var(--brand); background: #fcf3f4; }
.vm-manu-cnt { margin-left: auto; font-size: 12px; color: var(--muted); font-weight: 600; }
.vehmodal-main { flex: 1; overflow-y: auto; }
.vm-manu-sec { display: none; }
.vm-manu-sec.active { display: block; }
.vm-model { background: #eef2f6; padding: 10px 20px; font-weight: 600; font-size: 14px; color: var(--ink); position: sticky; top: 0; }
.vm-veh { padding: 8px 20px; font-size: 13.5px; color: var(--accent); border-bottom: 1px solid var(--line); }

/* Sicherheits-/Gefahrenhinweis (Chemie-Marken) */
.safety-box { border: 1px solid #f1c40f; border-left: 4px solid #e2001a; background: #fff9e6; padding: 12px 14px; margin: 0 0 16px; }
.safety-head { font-weight: 700; color: var(--ink); display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
.safety-ico { color: #e2001a; font-size: 18px; }
.safety-note { margin: 0 0 6px; font-size: 14px; }
.safety-signal { margin: 0 0 6px; font-size: 14px; }
.safety-signal strong { color: #e2001a; text-transform: uppercase; }
.safety-link { display: inline-block; font-weight: 700; color: var(--accent); text-decoration: none; }
.safety-link:hover { text-decoration: underline; }

/* OE-Nummern als aufklappbares, nach Hersteller gruppiertes Menü */
.oe-box { border: 1px solid var(--line); border-radius: 0; margin-bottom: 16px; background: #fff; }
.oe-box > summary {
    cursor: pointer; list-style: none; padding: 11px 14px; font-weight: 700; color: var(--ink);
    display: flex; align-items: center; gap: 8px;
}
.oe-box > summary::-webkit-details-marker { display: none; }
.oe-box > summary::after { content: '▾'; margin-left: auto; color: var(--muted); transition: transform .15s; }
.oe-box[open] > summary::after { transform: rotate(180deg); }
.oe-box[open] > summary { border-bottom: 1px solid var(--line); }
.oe-total { font-size: 12px; font-weight: 700; color: #fff; background: var(--brand); border-radius: 0; padding: 1px 8px; }
.oe-groups { max-height: 360px; overflow-y: auto; }
.oe-grp { display: flex; gap: 16px; padding: 10px 14px; border-bottom: 1px solid var(--line); }
.oe-grp:last-child { border-bottom: none; }
.oe-grp-brand { flex: none; width: 130px; font-weight: 700; color: var(--ink); text-transform: uppercase; font-size: 13px; }
.oe-grp-nos { flex: 1; display: flex; flex-direction: column; align-items: flex-end; gap: 3px; }
.oe-grp-no { font-family: monospace; font-size: 13.5px; color: var(--accent); text-decoration: none; cursor: pointer; }
.oe-grp-no:hover { text-decoration: underline; color: var(--brand); }
.oe-box .oe-list { padding: 12px 14px; margin-bottom: 0; }
.attr { border-collapse: collapse; width: 100%; }
.attr td { padding: 7px 10px; border-bottom: 1px solid var(--line); font-size: 14px; }
.attr td:first-child { color: var(--muted); width: 45%; }

/* Dokumente (PDFs / Hersteller-Links) */
.docs { list-style: none; margin: 0 0 16px; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.doc-link { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 0; text-decoration: none; color: var(--ink); background: #fff; transition: border-color .12s, background .12s; }
.doc-link:hover { border-color: var(--brand); background: #fcf3f4; }
.doc-kind { flex: none; font-size: 11px; font-weight: 700; letter-spacing: .5px; color: #fff; background: var(--brand); border-radius: 0; padding: 3px 7px; }
.doc-kind-link { background: var(--ink); }
.doc-label { font-size: 14px; font-weight: 600; }

/* Buttons */
.btn { display: inline-block; padding: 11px 20px; border-radius: 0; font-weight: 600; cursor: pointer; border: 1px solid transparent; font-size: 15px; }
.btn-primary { background: var(--brand); color: #fff; }
.btn-primary:hover { background: var(--brand-dark); }
.btn-primary:disabled { opacity: .5; cursor: not-allowed; }
.btn-ghost { background: #fff; border-color: var(--line); }
.actions { display: flex; gap: 12px; margin-top: 16px; }

/* Warenkorb */
.cart { width: 100%; border-collapse: collapse; background: var(--card); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.cart th, .cart td { padding: 12px 16px; text-align: left; border-bottom: 1px solid var(--line); }
.cart th { background: #f7f9fb; font-size: 13px; text-transform: uppercase; color: var(--muted); }
.cart-art-link { color: inherit; text-decoration: none; display: flex; align-items: center; gap: 12px; }
.cart-art-link:hover strong { color: var(--brand); text-decoration: underline; }
.cart-thumb { width: 56px; height: 56px; flex: 0 0 56px; object-fit: contain; background: #fff; border: 1px solid var(--line); }
.cart-noimg { display: flex; align-items: center; justify-content: center; font-size: 10px; line-height: 1.1; color: var(--muted); text-align: center; }
.cart-art-txt { min-width: 0; }
.checkout-form { max-width: 560px; margin-top: 18px; }
.co-field { margin-bottom: 14px; }
.co-field label { display: block; font-size: 12px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); margin-bottom: 5px; }
.co-field input { width: 100%; padding: 10px 12px; border: 1px solid #c7ccd4; border-radius: 0; font-size: 15px; }
.co-field select { width: 100%; padding: 10px 12px; border: 1px solid #c7ccd4; border-radius: 0; font-size: 15px; background: #fff; }
.co-hint { margin-top: 10px; font-size: 13px; }
.co-ready { margin: 2px 0 12px; padding: 8px 12px; background: #fff8e6; border: 1px solid #f0d48a; color: #6a5300; font-size: 13px; }
/* Nachfrage: Auftrag aufsplitten? */
.split-ask { max-width: 640px; margin-top: 12px; }
.split-ask h2 { margin: 0 0 8px; }
.split-list { margin: 10px 0 18px; padding-left: 18px; }
.split-list li { margin: 6px 0; }
.split-actions { display: flex; gap: 12px; flex-wrap: wrap; margin: 4px 0 6px; }
.split-actions .btn { flex: 1 1 auto; }
/* Tour-Auswahl (Liste wie im WaWi) */
.tour-picker { border: 1px solid #c7ccd4; background: #fff; }
.tour-opt { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-top: 1px solid #ececec; cursor: pointer; font-size: 15px; }
.tour-opt:first-child { border-top: 0; }
.tour-opt input[type="radio"] { width: auto; margin: 0; flex: 0 0 auto; accent-color: var(--brand); }
.tour-opt .tour-name { font-weight: 700; min-width: 84px; }
.tour-opt .tour-time { color: #222; font-variant-numeric: tabular-nums; }
.tour-opt .tour-meta { margin-left: auto; color: var(--muted); font-size: 12px; }
.tour-opt .tour-flag { margin-left: auto; color: var(--brand); font-size: 12px; }
.tour-opt:hover { background: #f7f8fa; }
.tour-opt:has(input:checked) { background: #fff3f3; box-shadow: inset 3px 0 0 var(--brand); }
.tour-opt.is-past, .tour-opt.is-off { cursor: not-allowed; background: #f3f4f6; color: #9aa0a8; }
.tour-opt.is-past .tour-name, .tour-opt.is-off .tour-name,
.tour-opt.is-past .tour-time, .tour-opt.is-off .tour-time { color: #9aa0a8; }
.order-ok { background: #e9f7ee; border: 1px solid #1f9d3a; padding: 24px; margin-top: 12px; }
.order-ok h2 { color: #1f9d3a; margin: 0 0 8px; }
.notice-error { background: #fdeaea; border-color: var(--brand); color: #8a1f1f; }
.order-card { border: 1px solid var(--line); background: var(--card); margin-bottom: 12px; box-shadow: var(--shadow); }
.order-card > summary { list-style: none; cursor: pointer; display: flex; align-items: center; gap: 16px; flex-wrap: wrap; padding: 14px 18px; font-weight: 600; }
.order-card > summary::-webkit-details-marker { display: none; }
.order-card[open] > summary { border-bottom: 1px solid var(--line); }
.oc-no { font-size: 15px; }
.oc-date { color: var(--muted); font-weight: 400; }
.oc-status { background: #eef2f6; padding: 2px 10px; font-size: 12px; text-transform: uppercase; letter-spacing: .03em; }
.oc-komm { color: var(--muted); font-weight: 400; font-size: 13px; }
.oc-lief { background: #e9f7ee; color: #1f7a36; padding: 2px 10px; font-size: 12px; font-weight: 700; border: 1px solid #b8e3c6; }
.oc-sum { margin-left: auto; font-weight: 800; font-size: 16px; }
.order-pos { width: 100%; border-collapse: collapse; }
.order-pos th, .order-pos td { padding: 9px 18px; text-align: left; border-top: 1px solid #eef1f4; font-size: 14px; }
.order-pos th { background: #f7f9fb; font-size: 12px; text-transform: uppercase; color: var(--muted); }
.cart-total { text-align: right; font-size: 20px; margin: 16px 0; }
.link-danger { color: var(--brand); }

/* KBA-Suche */
.kba {
    display: flex; align-items: flex-end; gap: 16px; flex-wrap: wrap;
    background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
    padding: 20px 24px; box-shadow: var(--shadow); margin-bottom: 20px;
}
.kba-field { display: flex; flex-direction: column; }
.kba-field label { font-size: 13px; font-weight: 600; margin-bottom: 6px; }
.kba-field label span { color: var(--muted); font-weight: 400; }
.kba-field input {
    border: 1px solid var(--line); border-radius: 0; padding: 11px 14px; font-size: 18px;
    width: 130px; text-transform: uppercase; letter-spacing: 1px; font-family: monospace;
}
.kba-field input:focus { outline: none; border-color: var(--brand); }
.or-divider { text-align: center; margin: 24px 0; position: relative; color: var(--muted); font-size: 14px; }
.or-divider::before { content: ""; position: absolute; top: 50%; left: 0; right: 0; height: 1px; background: var(--line); }
.or-divider span { background: var(--bg); padding: 0 14px; position: relative; }

/* Fahrzeugauswahl (Startseite) */
.vehicle-select { display: grid; grid-template-columns: 320px 1fr; gap: 20px; align-items: start; }
.vs-card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px 24px; box-shadow: var(--shadow); }
.vs-card h2 { font-size: 17px; margin: 0 0 18px; }

/* KBA-Spalte */
.kba-row { display: flex; gap: 14px; }
.kba-form .kba-field { display: flex; flex-direction: column; flex: 1; }
.kba-form .kba-field label { font-size: 13px; color: var(--muted); margin-bottom: 6px; }
.kba-form .kba-field input {
    border: 1px solid var(--line); border-radius: 0; padding: 10px 12px; font-size: 16px;
    width: 100%; text-transform: uppercase; letter-spacing: 1px;
}
.kba-form .kba-field input:focus { outline: none; border-color: var(--accent); }
.kba-help-toggle { background: none; border: none; color: var(--accent); cursor: pointer; padding: 12px 0 0; font-size: 14px; }
.kba-help { display: none; font-size: 13px; color: var(--muted); background: #f7f9fb; border-radius: 0; padding: 0; max-height: 0; overflow: hidden; transition: .15s; }
.kba-help.open { display: block; max-height: 200px; padding: 12px 14px; margin-top: 8px; }
.kba-submit { width: 100%; margin-top: 16px; }
.btn-accent { background: var(--accent); color: #fff; }
.btn-accent:hover { filter: brightness(.93); }

/* Kriterien-Spalte */
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 20px; }
.chip-btn {
    border: 1px solid var(--line); background: #fff; border-radius: 0;
    padding: 8px 16px; font-size: 14px; font-weight: 600; cursor: pointer; transition: .12s; color: var(--ink);
}
.chip-btn:hover { border-color: var(--accent); }
.chip-btn.active { background: var(--ink); color: #fff; border-color: var(--ink); }
.criteria-row { display: grid; grid-template-columns: 110px 1fr; align-items: center; gap: 12px; margin-bottom: 12px; }
.criteria-row label { color: var(--brand); font-weight: 600; font-size: 15px; }
.criteria-row select {
    width: 100%; border: 1px solid var(--line); border-radius: 0; padding: 11px 14px; font-size: 15px;
    background: #fff; cursor: pointer;
}
.criteria-row select:disabled { background: #f3f5f7; color: var(--muted); cursor: not-allowed; }
.criteria-row select:focus { outline: none; border-color: var(--accent); }

@media (max-width: 760px) {
    .vehicle-select { grid-template-columns: 1fr; }
    .criteria-row { grid-template-columns: 1fr; gap: 4px; }
}

/* 3-Spalten-Maske: Baugruppen | Artikel-Icons | Fahrzeugdetails */
.cat-layout {
    display: grid; grid-template-columns: 340px minmax(0, 1fr) 320px; gap: 20px; align-items: start;
    /* volle Bildschirmbreite: aus dem zentrierten Container ausbrechen, 20px Rand */
    margin-left: calc(-50vw + 50% + 20px);
    margin-right: calc(-50vw + 50% + 20px);
}
.cat-layout aside, .cat-main {
    background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
    box-shadow: var(--shadow); padding: 20px;
}
.cat-layout h2 { font-size: 18px; margin: 0 0 16px; border-bottom: 1px solid var(--line); padding-bottom: 12px; }

/* Links: Baugruppen */
.bg-search { position: relative; margin-bottom: 12px; }
.bg-search input { width: 100%; border: 1px solid var(--line); border-radius: 0; padding: 9px 32px 9px 12px; font-size: 14px; }
.bg-search input:focus { outline: none; border-color: var(--accent); }
/* Fahrzeugteile-Treffer – direkt in der Baugruppen-Liste (#bgUl), kein extra Kasten */
#bgUl li.gen-head { list-style: none; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .4px; color: var(--muted); padding: 8px 8px 4px; }
#bgUl li.gen-li { list-style: none; }
#bgUl li.gen-li a { display: block; padding: 7px 8px; font-size: 14px; color: var(--accent); border-left: 2px solid var(--brand); overflow-wrap: anywhere; }
#bgUl li.gen-li a:hover { background: #fcf3f4; }
#bgUl li.gen-li .gen-grp { display: block; font-size: 12px; color: var(--muted); }
.bg-search span { position: absolute; right: 10px; top: 8px; color: var(--muted); }
#bgUl { list-style: none; margin: 0; padding: 0; max-height: 640px; overflow-y: auto; overflow-x: hidden; }
#bgUl li.child { display: none; } /* Unterkategorien standardmäßig aus; per Suche sichtbar */
#bgUl li a { display: block; padding: 7px 8px; font-size: 14px; color: var(--ink); border-radius: 0; overflow-wrap: anywhere; }
#bgUl li a:hover { color: var(--brand); background: #f3f5f7; }
.bg-parent { color: var(--muted); font-size: 12px; font-weight: 400; }
#bgUl li a:hover { background: #f3f5f7; }
#bgUl li.active a { background: #eef2f6; font-weight: 700; color: var(--brand); }

/* Mitte: Icon-Kacheln */
.cat-layout.two-col { grid-template-columns: 340px minmax(0, 1fr); }
.cat-main { min-width: 0; }
/* Rechte Spalte: bleibt beim Scrollen im Blick */
.cat-right { position: sticky; top: 16px; align-self: start; display: flex; flex-direction: column; gap: 20px; max-height: calc(100vh - 32px); overflow-y: auto; }

/* Filter-Leiste über der Artikelliste (Dropdowns) */
.art-filterbar { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 14px; }
.art-flt {
    border: 1px solid var(--line); border-radius: 0; padding: 9px 14px; font-size: 14px; background: #fff;
    cursor: pointer; min-width: 200px;
}
.art-flt:focus { outline: none; border-color: var(--accent); }

/* Hersteller-Mehrfachauswahl */
.art-flt-multi { position: relative; }
.art-flt-btn { text-align: left; display: flex; align-items: center; gap: 8px; }
.art-flt-btn::after { content: '▾'; margin-left: auto; color: var(--muted); }
.art-flt-menu {
    position: absolute; top: calc(100% + 4px); left: 0; z-index: 50; min-width: 240px; max-height: 320px; overflow-y: auto;
    background: #fff; border: 1px solid var(--line); border-radius: 0; box-shadow: 0 12px 30px rgba(0,0,0,.14); padding: 6px;
}
.flt-opt { display: flex; align-items: center; gap: 9px; padding: 7px 10px; border-radius: 0; font-size: 14px; cursor: pointer; }
.flt-opt:hover { background: #f2f3f5; }
.flt-opt input { width: 16px; height: 16px; accent-color: var(--brand); cursor: pointer; }
.flt-opt-name { flex: 1; }
.flt-logo { max-height: 20px; max-width: 72px; object-fit: contain; flex: none; }
.flt-cnt { color: var(--muted); font-size: 12.5px; }
.cat-head { font-size: 18px; font-weight: 700; margin-bottom: 16px; border-bottom: 1px solid var(--line); padding-bottom: 12px; }
.cat-head-icon { color: var(--accent); }
.icon-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.icon-card {
    display: flex; align-items: center; gap: 12px; padding: 14px; border: 1px solid var(--line);
    border-radius: 0; transition: .12s; min-width: 0;
}
.icon-card:hover { border-color: var(--brand); background: #fafbfc; transform: translateY(-1px); }
.icon-card .ic {
    width: 40px; height: 40px; flex: none; display: flex; align-items: center; justify-content: center;
    font-size: 22px; background: #eef2f6; border-radius: 0;
}
.icon-card .ic-name { font-weight: 600; font-size: 13.5px; color: var(--ink); min-width: 0; overflow-wrap: anywhere; }

/* Mitte: Themen-Schnellauswahl */
.theme-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 24px 28px; }
.theme-block h3 {
    font-size: 15px; font-weight: 700; color: var(--ink); margin: 0 0 8px;
    padding-bottom: 8px; border-bottom: 2px solid var(--line);
}
.theme-block ul { list-style: none; margin: 0; padding: 0; }
.theme-block li a {
    display: flex; align-items: center; gap: 10px; padding: 8px 6px; border-radius: 0;
    font-size: 14.5px; color: var(--ink);
}
.theme-block li a:hover { background: #f3f5f7; color: var(--brand); }
.theme-block .ti {
    width: 30px; height: 30px; flex: none; display: flex; align-items: center; justify-content: center;
    font-size: 16px; background: #eef2f6; border-radius: 0;
}

/* Rechts: Fahrzeugdetails */
.veh-photo { display: flex; justify-content: center; align-items: center; min-height: 0; margin-bottom: 4px; }
.veh-photo-img { max-width: 100%; max-height: 130px; width: auto; object-fit: contain; transform: scaleX(-1); }
.vd-table-3 { border-top: 1px solid var(--line); padding-top: 6px; }
.vd-title { font-size: 17px; font-weight: 700; margin-bottom: 14px; }
.vd-kennzeichen { margin: 0 0 16px; }
.vd-kennzeichen label { display: block; font-size: 11px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); margin-bottom: 5px; }
.kz-row { display: flex; align-items: center; gap: 8px; }
.kz-input { flex: 1; min-width: 0; padding: 9px 10px; border: 1px solid #c7ccd4; border-radius: 0; font-size: 15px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; }
.kz-input:focus { outline: none; border-color: var(--brand); }
.kz-status { font-size: 12px; color: #1f9d3a; white-space: nowrap; }
.vd-table { width: 100%; border-collapse: collapse; margin-bottom: 14px; }
.vd-table td { padding: 6px 0; font-size: 14px; vertical-align: top; }
.vd-table td:first-child { color: var(--muted); width: 45%; }
.vd-table td:last-child { font-weight: 600; }
.vd-table-2 { border-top: 1px solid var(--line); padding-top: 6px; }
.vd-field { margin: 10px 0; }
.vd-field label { display: block; font-size: 13px; color: var(--muted); margin-bottom: 4px; }
.vd-field input { width: 100%; border: 1px solid var(--line); border-radius: 0; padding: 9px 12px; font-size: 14px; background: #f7f9fb; }
.vd-recall { display: block; text-align: center; margin-top: 14px; padding: 11px; border: 1px solid var(--line); border-radius: 0; font-weight: 600; color: var(--ink); }
.vd-recall:hover { border-color: var(--brand); }

@media (max-width: 980px) {
    .cat-layout { grid-template-columns: 1fr; }
    .icon-grid { grid-template-columns: repeat(2, 1fr); }
}

/* Unterkategorie-Liste (mit ↘) */
.subcat-list { list-style: none; margin: 0; padding: 0; columns: 2; column-gap: 28px; }
.subcat-list li { break-inside: avoid; }
.subcat-list li a { display: flex; align-items: center; gap: 10px; padding: 9px 6px; border-radius: 0; color: var(--ink); }
.subcat-list li a:hover { background: #f3f5f7; color: var(--brand); }
.sc-arrow { color: var(--muted); font-size: 14px; flex: none; }
.sc-name { font-weight: 600; }
.sc-count { margin-left: auto; color: var(--muted); font-size: 13px; }
@media (max-width: 760px) { .subcat-list { columns: 1; } }

/* Kategorie-Filter (rechte Spalte in Unterkategorien) */
.cat-filter h2 .cf-star { color: #f6b100; }
.cat-filter h2 .cf-sub { color: var(--muted); font-weight: 400; font-size: 15px; }
.cf-list { list-style: none; margin: 0 0 14px; padding: 0; max-height: 420px; overflow-y: auto; }
.cf-list li { padding: 4px 0; }
.cf-list label { display: flex; align-items: center; gap: 8px; font-size: 14.5px; cursor: pointer; }
.cf-list input { width: 16px; height: 16px; }
.cf-actions { display: flex; gap: 8px; border-top: 1px solid var(--line); padding-top: 12px; }
.btn-apply { flex: 1; background: var(--ok); color: #fff; border: none; border-radius: 0; padding: 10px; font-weight: 600; cursor: pointer; }
.btn-apply:hover { filter: brightness(.95); }
.btn-calc { flex: 1; background: #eef2f6; color: var(--muted); border: 1px solid var(--line); border-radius: 0; padding: 10px; font-weight: 600; cursor: not-allowed; }

/* Kategorie-Kacheln (mit Anzahl + Bild) */
/* Norm- & Universalteile: Abschnittsüberschrift */
.nu-sec { font-size: 17px; font-weight: 700; color: var(--ink); margin: 26px 0 12px; padding-bottom: 8px; border-bottom: 2px solid var(--brand); }
.nu-sec:first-of-type { margin-top: 16px; }

.cat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 14px; }
.cat-card {
    display: flex; align-items: center; gap: 14px;
    background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
    padding: 16px 18px; box-shadow: var(--shadow); transition: .12s;
}
.cat-card:hover { border-color: var(--brand); transform: translateY(-2px); }
/* Kombi-Karte „Alle …": hervorgehoben */
.cat-card-all { border-color: var(--brand); background: #fcf3f4; }
.cat-card-all .cat-icon { background: var(--brand); color: #fff; }
.cat-card-all .cat-name { color: var(--brand); }
.cat-icon {
    width: 44px; height: 44px; flex: none; display: flex; align-items: center; justify-content: center;
    font-size: 22px; background: #eef2f6; border-radius: 0;
}
.cat-text { min-width: 0; }
.cat-name { font-weight: 700; font-size: 16px; color: var(--ink); }
.cat-count { color: var(--accent); font-size: 14px; margin-top: 2px; min-height: 18px; }
.cat-count-load { display: inline-block; width: 26px; height: 8px; background: #e6e8ec; animation: catpulse 1s ease-in-out infinite; }
@keyframes catpulse { 0%,100% { opacity: .4; } 50% { opacity: 1; } }
.cat-card-empty { opacity: .5; }
.cat-card-empty .cat-count { color: var(--muted); }
.chev { color: var(--muted); }

/* Listenansicht (Kategorie geöffnet) */
.listing { display: grid; grid-template-columns: 230px 1fr; gap: 22px; align-items: start; }
.listing-side { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 8px; box-shadow: var(--shadow); }
.listing-side h3 { font-size: 14px; text-transform: uppercase; color: var(--muted); margin: 4px 12px 10px; }
.listing-side ul { list-style: none; margin: 0; padding: 0; }
.listing-side li a { display: flex; justify-content: space-between; padding: 8px 12px; border-radius: 0; font-size: 15px; }
.listing-side li a:hover { background: #f3f5f7; }
.listing-side li.active a { background: #eef2f6; color: var(--brand); font-weight: 700; }
.listing-main { min-width: 0; }
.listing-main h1 { margin: 0 0 14px; }

.fits { background: #eafaf0; border: 1px solid #b7ebc6; border-radius: 0; padding: 10px 14px; margin-bottom: 16px; font-size: 15px; }
.fits-badge { background: var(--ok); color: #fff; border-radius: 0; padding: 2px 8px; font-size: 13px; font-weight: 700; margin-right: 8px; }
.fits-meta { color: var(--muted); }
.art-count { color: var(--muted); font-size: 14px; margin-bottom: 10px; }

.art-row {
    display: grid; grid-template-columns: 150px 1fr 200px; gap: 18px;
    background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
    padding: 18px; box-shadow: var(--shadow); margin-bottom: 14px;
}
.art-img { display: flex; align-items: flex-start; justify-content: center; }
.art-img img { max-width: 150px; max-height: 150px; object-fit: contain; }
.art-info { min-width: 0; }
.art-info .art-brand { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 700; color: var(--accent); text-transform: uppercase; }
.art-brand .brand-logo { max-height: 22px; max-width: 90px; object-fit: contain; }

/* Marken-Logo-Übersicht (?brandlogos=1) */
.bl-stat { margin: 4px 0 14px; }
.bl-search { width: 320px; max-width: 100%; padding: 9px 12px; border: 1px solid var(--line); border-radius: 0; margin-bottom: 14px; font-size: 14px; }
.bl-table { width: 100%; border-collapse: collapse; }
.bl-table th, .bl-table td { padding: 8px 12px; border-bottom: 1px solid var(--line); text-align: left; font-size: 14px; vertical-align: middle; }
.bl-table th { color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: .4px; }
.bl-cell-logo { width: 110px; }
.bl-logo { max-height: 26px; max-width: 90px; object-fit: contain; }
.bl-empty { color: var(--muted); }
.bl-ok { color: #1a8a3a; font-weight: 700; }
.bl-miss { color: var(--muted); }
.bl-table code { background: #eef2f6; padding: 2px 7px; border-radius: 0; font-size: 13px; }

/* Katalog-Marken auswählen (?catbrands=1) */
.cb-saved { color: #1a8a3a; font-weight: 700; }
.cb-shared { background: #fff6e6; border: 1px solid #f0c860; padding: 8px 12px; font-size: 14px; color: var(--ink); }
.cb-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-bottom: 14px; }
.cb-bar .bl-search { margin-bottom: 0; }
.cb-bar-bottom { margin-top: 16px; }
.cb-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 6px; }
.cb-item { display: flex; align-items: center; gap: 9px; padding: 8px 10px; border: 1px solid var(--line); background: #fff; cursor: pointer; font-size: 14px; }
.cb-item:hover { border-color: var(--brand); background: #fcf3f4; }
.cb-cb { width: 16px; height: 16px; accent-color: var(--brand); flex: none; cursor: pointer; }
.cb-logo { max-height: 18px; max-width: 46px; object-fit: contain; flex: none; }
.cb-name { flex: 1; min-width: 0; overflow-wrap: anywhere; }

/* Kategorie-Baum (Marken pro Kategorie ausdünnen) */
.ctree { font-size: 14px; }
.ctree-ul { list-style: none; margin: 0; padding-left: 18px; }
.ctree > .ctree-ul { padding-left: 0; }
.ctree-branch > summary { cursor: pointer; padding: 6px 8px; font-weight: 600; list-style: none; border-bottom: 1px solid var(--line); }
.ctree-branch > summary::-webkit-details-marker { display: none; }
.ctree-branch > summary::before { content: '▸'; color: var(--muted); margin-right: 8px; display: inline-block; transition: transform .12s; }
.ctree-branch[open] > summary::before { transform: rotate(90deg); }
.ctree-leaf { display: inline-flex; align-items: center; gap: 8px; padding: 6px 8px; color: var(--ink); text-decoration: none; }
.ctree-leaf::before { content: '·'; color: var(--brand); font-weight: 700; }
.ctree-leaf:hover { color: var(--brand); text-decoration: underline; }
.ctree-hid { font-size: 12px; font-weight: 700; color: #fff; background: var(--brand); padding: 1px 7px; text-transform: none; }

/* Alternativartikel-Liste (?alternatives=ID) */
.alts-head h2 { margin: 0 0 4px; }
.alts-count { font-size: 13px; color: var(--muted); margin: 12px 0 8px; }
.alts-list { display: flex; flex-direction: column; gap: 6px; }
.alt-row { display: flex; align-items: center; gap: 14px; padding: 10px 14px; border: 1px solid var(--line); border-radius: 0; background: #fff; text-decoration: none; color: var(--ink); transition: border-color .12s, background .12s; }
.alt-row:hover { border-color: var(--brand); background: #fcf3f4; }
.alt-brand { display: flex; align-items: center; gap: 8px; width: 200px; flex: none; font-weight: 700; color: var(--accent); text-transform: uppercase; font-size: 13px; }
.alt-logo { max-height: 22px; max-width: 80px; object-fit: contain; }
.alt-no { font-family: monospace; font-size: 15px; font-weight: 700; }
.alt-go { margin-left: auto; font-size: 13px; color: var(--muted); }
.alt-row:hover .alt-go { color: var(--brand); }
.alts-inline { margin-top: 28px; padding-top: 20px; border-top: 2px solid var(--line); }
.alts-inline h2 { margin: 0 0 2px; }
.alts-inline > .muted { margin: 0 0 12px; }
/* "Weitere Marken" als kompakte Chips unter den Alternativ-Karten */
.alts-more { margin-top: 14px; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.alts-more-label { font-weight: 700; color: var(--muted); font-size: 13px; margin-right: 4px; }
.alts-more-chip { display: inline-flex; align-items: center; gap: 6px; padding: 5px 10px; border: 1px solid var(--line); border-radius: 0; font-size: 13px; font-weight: 700; color: var(--accent); text-transform: uppercase; text-decoration: none; background: #fff; }
.alts-more-chip:hover { border-color: var(--brand); background: #fcf3f4; }
.alts-more-logo { max-height: 16px; max-width: 50px; object-fit: contain; }
.alts-more-no { font-family: monospace; font-weight: 600; color: var(--ink); text-transform: none; }
.art-name { display: block; font-size: 18px; font-weight: 700; color: var(--ink); margin: 2px 0 6px; }
.art-name:hover { color: var(--brand); }
.art-no { font-size: 14px; color: var(--muted); margin-bottom: 10px; }
.art-specs { display: grid; grid-template-columns: auto 1fr; gap: 2px 10px; margin: 0; font-size: 13.5px; }
.art-specs dt { color: var(--muted); }
.art-specs dt::after { content: ":"; }
.art-specs dd { margin: 0; }
.art-actions { display: flex; flex-direction: column; align-items: stretch; gap: 8px; }
.art-price { font-size: 22px; font-weight: 800; text-align: right; }
.art-actions .btn { text-align: center; }

@media (max-width: 820px) {
    .listing { grid-template-columns: 1fr; }
    .art-row { grid-template-columns: 110px 1fr; }
    .art-actions { grid-column: 1 / -1; flex-direction: row; justify-content: flex-end; align-items: center; }
}

/* Filter-Seitenleiste (Artikelliste) */
.filter-side { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; box-shadow: var(--shadow); }
.filter-side h3 { margin: 0 0 12px; font-size: 16px; }
.fs-group { border-top: 1px solid var(--line); padding: 12px 0; }
.fs-head { font-weight: 700; font-size: 14px; margin-bottom: 8px; }
.fs-opt { display: flex; align-items: center; gap: 8px; padding: 4px 0; font-size: 14px; cursor: pointer; }
.fs-opt input { width: 15px; height: 15px; }
.fs-disabled { color: var(--muted); cursor: not-allowed; }
.fs-cnt { margin-left: auto; color: var(--muted); font-size: 12px; }
#brandFilter { max-height: 360px; overflow-y: auto; }

/* Reiche Artikel-Karten */
/* Kategorie-Abschnitt in der kombinierten Schnellauswahl */
.art-group { margin-bottom: 22px; }
.art-group-head {
    display: flex; align-items: center; gap: 10px; margin: 0 0 12px;
    font-family: var(--head); text-transform: uppercase; font-size: 17px; font-weight: 600;
    color: var(--ink); padding-bottom: 8px; border-bottom: 2px solid var(--line);
}
.art-group-head::before { content: ''; width: 5px; height: 18px; background: var(--brand); border-radius: 2px; }
.art-group-count { font-family: inherit; font-size: 13px; font-weight: 600; color: #fff; background: var(--brand); border-radius: 0; padding: 1px 9px; }

.art-card {
    display: grid; grid-template-columns: 130px 1fr 150px; gap: 16px;
    background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
    padding: 16px; box-shadow: var(--shadow); margin-bottom: 12px;
}
.ac-img { display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; }
.ac-img img { max-width: 120px; max-height: 110px; object-fit: contain; }
.ac-img .noimg { width: 120px; height: 90px; }
.ac-brand { display: flex; flex-direction: column; align-items: center; gap: 4px; font-size: 12px; font-weight: 700; color: var(--accent); }
.ac-brand-logo { max-width: 92px; max-height: 26px; object-fit: contain; }
/* Wenn ein Logo da ist, Markenname kleiner/dezenter darunter */
.ac-brand-logo + .ac-brand-name { font-size: 10px; color: var(--muted); font-weight: 600; }
.ac-body { min-width: 0; }
.ac-head { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; margin-bottom: 10px; }
.ac-no { font-size: 18px; font-weight: 800; color: var(--accent); }
.ac-name { font-weight: 600; }
.ac-buttons { margin-left: auto; display: flex; gap: 6px; flex-wrap: wrap; }
.ac-btn { font-size: 12.5px; padding: 5px 9px; border: 1px solid var(--line); border-radius: 0; color: var(--ink); white-space: nowrap; }
.ac-btn:hover { border-color: var(--brand); }
.ac-ph { color: var(--muted); cursor: default; }
.ac-replaced { display: inline-block; font-size: 12.5px; font-weight: 600; color: #8a5a00; background: #fff3d6; border: 1px solid #ffe2a3; border-radius: 0; padding: 3px 9px; margin-bottom: 8px; cursor: pointer; }
.ac-replaced:hover { background: #ffe9b3; border-color: #f0c860; }
.ac-replaced strong { color: #6b4500; text-decoration: underline; }
.ac-oehit { display: inline-block; font-size: 12px; font-weight: 600; color: var(--accent); background: #fdeaec; border: 1px solid #f6c9cf; border-radius: 0; padding: 3px 9px; margin-bottom: 8px; }
.ac-specs { display: flex; flex-wrap: wrap; gap: 5px 8px; margin-bottom: 8px; }
.ac-spec { font-size: 12.5px; background: #f3f5f7; border-radius: 0; padding: 3px 8px; }
.ac-spec em { color: var(--muted); font-style: normal; }
.ac-spec b { color: var(--ink); }
.ac-oe { font-size: 12.5px; }
.ac-oe-lbl { color: var(--muted); font-weight: 600; }
.ac-oechip { font-family: monospace; background: #eef2f6; border-radius: 0; padding: 1px 6px; margin: 0 3px 3px 0; display: inline-block; }
.ac-buy { display: flex; flex-direction: column; align-items: flex-end; gap: 8px; }
.ac-avail { font-size: 12px; font-weight: 700; padding: 3px 9px; border-radius: 0; white-space: nowrap; }
.ac-avail:empty { padding: 0; }
.av-in { background: #e3f6e5; color: #1f7a34; }
.av-mor { background: linear-gradient(90deg, #fdf3cf 0%, #fdf3cf 60%, #cdeccf 100%); color: #7a6a00; }
.av-two { background: #fdf3cf; color: #8a6a00; }
.av-ext { background: #e1edfb; color: #1c5aa6; }
.av-soon { background: #fff3d6; color: #9a6a00; }
.av-out { background: #fde8e8; color: #b3261e; }
.av-part { background: #fdebd0; color: #a04a00; }
.ac-price { font-size: 20px; font-weight: 800; }
.ac-price-brutto { font-size: 12px; font-weight: 600; color: #777; margin-top: -6px; }
.ac-price-list { font-size: 12px; font-weight: 600; color: #777; margin-top: -6px; }
.ac-deliv { display: inline-block; font-size: 12px; font-weight: 800; color: #1c5aa6; background: #e1edfb; padding: 3px 10px; border-radius: 0; letter-spacing: .2px; }
.ac-deliv-heute { color: #fff; background: #1f9d3a; box-shadow: 0 1px 5px rgba(31,157,58,.45); }
.ac-deliv-morgen { color: #fff; background: linear-gradient(90deg, #f5c518 0%, #f5c518 60%, #1f9d3a 100%); text-shadow: 0 1px 2px rgba(0,0,0,.45); box-shadow: 0 1px 5px rgba(120,160,40,.4); }
.ac-deliv-zwei { color: #4d3b00; background: #f3c200; box-shadow: 0 1px 5px rgba(243,194,0,.45); }
.avail-box { margin: 14px 0; }
.avail-box h3 { margin: 0 0 8px; }
.avail-rows { display: flex; flex-direction: column; gap: 8px; align-items: flex-start; }
.avail-row { display: flex; align-items: center; gap: 10px; }
.ac-avail-wrap.av-loading { opacity: .4; }

/* MANN-Landmaschinen-Katalog */
.agri-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px; margin: 14px 0; }
.agri-card { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 14px 16px; background: #fff; border: 1px solid var(--line, #e6e6e3); border-left: 4px solid var(--rot, #d40511); border-radius: 0; font-weight: 700; color: #111; text-decoration: none; }
.agri-card:hover { background: #faf3f3; }
.agri-count { font-size: 12px; font-weight: 700; background: #111; color: #fff; padding: 1px 8px; border-radius: 999px; }
.agri-types { display: flex; flex-direction: column; gap: 10px; margin: 14px 0; }
.agri-type { background: #fff; border: 1px solid var(--line, #e6e6e3); border-radius: 0; padding: 12px 14px; }
.agri-type-head { font-size: 15px; margin-bottom: 8px; border-bottom: 1px solid #f0f0ee; padding-bottom: 6px; }
.agri-meta { font-size: 13px; color: #777; font-weight: 400; }
.agri-filters { display: flex; flex-direction: column; gap: 6px; }
.agri-fcat { font-size: 13px; }
.agri-fcat-l { display: inline-block; min-width: 92px; font-weight: 700; color: #d40511; }
.agri-art { display: inline-block; background: #f1efe8; color: #111; padding: 2px 8px; margin: 2px 4px 2px 0; border-radius: 0; text-decoration: none; font-weight: 600; }
.agri-art:hover { background: #111; color: #fff; }
.ac-cart { display: flex; gap: 6px; }
.ac-qty { width: 52px; border: 1px solid var(--line); border-radius: 0; padding: 8px; text-align: center; }
.ac-cart .btn { padding: 8px 12px; }

@media (max-width: 820px) {
    .art-card { grid-template-columns: 90px 1fr; }
    .ac-buy { grid-column: 1 / -1; flex-direction: row; align-items: center; justify-content: flex-end; }
}

/* Artikel-/OE-Suchergebnisse */
.search-results { display: flex; flex-direction: column; gap: 10px; }
.sr-row {
    display: grid; grid-template-columns: 1fr 200px; gap: 16px; align-items: center;
    background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
    padding: 14px 18px; box-shadow: var(--shadow);
}
.sr-info { min-width: 0; }
.sr-actions { display: flex; flex-direction: column; gap: 8px; }
.sr-actions .btn { text-align: center; }
.oe-hit { color: var(--accent); font-size: 13px; }

@media (max-width: 700px) {
    .sr-row { grid-template-columns: 1fr; }
    .sr-actions { flex-direction: row; }
}

/* Hinweisbox */
.notice {
    background: #fff8e1; border: 1px solid #ffe08a; color: #7a5c00;
    border-radius: var(--radius); padding: 16px 20px; line-height: 1.6;
}
.notice a { color: var(--accent); text-decoration: underline; }

/* Bildergalerie (durchblättern) */
.gallery { position: relative; display: flex; align-items: center; justify-content: center; min-height: 220px; }
.gallery-main { width: 100%; max-height: 320px; object-fit: contain; cursor: zoom-in; }
.gal-nav {
    position: absolute; top: 50%; transform: translateY(-50%); width: 36px; height: 36px;
    border: 1px solid var(--line); background: rgba(255,255,255,.9); border-radius: 0;
    font-size: 22px; line-height: 1; cursor: pointer; color: var(--ink); display: flex; align-items: center; justify-content: center;
}
.gal-nav:hover { background: var(--brand); color: #fff; border-color: var(--brand); }
.gal-prev { left: 4px; }
.gal-next { right: 4px; }
.gal-count {
    position: absolute; bottom: 4px; left: 50%; transform: translateX(-50%);
    background: rgba(16,24,40,.7); color: #fff; font-size: 12px; padding: 2px 10px; border-radius: 0;
}

/* Lightbox (Bild vergrößern) – liegt über dem Artikel-Modal */
.lightbox {
    position: fixed; inset: 0; background: rgba(8, 12, 20, .85); z-index: 1100;
    display: none; align-items: center; justify-content: center; padding: 32px; cursor: zoom-out;
}
.lightbox.open { display: flex; }
.lightbox-img { max-width: 88vw; max-height: 90vh; object-fit: contain; border-radius: 0; box-shadow: 0 20px 60px rgba(0,0,0,.5); cursor: pointer; }
.lightbox-close {
    position: absolute; top: 18px; right: 22px; width: 42px; height: 42px; border: none; border-radius: 0;
    background: rgba(255,255,255,.12); color: #fff; font-size: 22px; line-height: 1; cursor: pointer;
}
.lightbox-close:hover { background: var(--brand); }
.lightbox-nav {
    position: absolute; top: 50%; transform: translateY(-50%); width: 52px; height: 52px; border: none; border-radius: 0;
    background: rgba(255,255,255,.12); color: #fff; font-size: 34px; line-height: 1; cursor: pointer;
    display: flex; align-items: center; justify-content: center;
}
.lightbox-nav:hover { background: var(--brand); }
.lightbox-prev { left: 24px; }
.lightbox-next { right: 24px; }
.lightbox-count {
    position: absolute; bottom: 24px; left: 50%; transform: translateX(-50%);
    background: rgba(0,0,0,.55); color: #fff; font-size: 14px; padding: 4px 14px; border-radius: 0;
}

/* Lade-Overlay für Suchen ("Suche läuft …") – über allem */
.search-overlay {
    position: fixed; inset: 0; background: rgba(255,255,255,.85); z-index: 1200;
    display: none; align-items: center; justify-content: center;
}
.search-overlay.open { display: flex; }
.search-overlay-box { text-align: center; }
.search-overlay-text { font-weight: 700; color: var(--ink); font-size: 16px; }
.spinner {
    width: 46px; height: 46px; margin: 0 auto 14px;
    border: 4px solid var(--line); border-top-color: var(--brand);
    border-radius: 50%; animation: spin .8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
/* Spinner auch in Popup-Ladezuständen (Artikel-Modal, Fahrzeug-Fenster, Alternativen, Favoriten) */
.modal-loading, .veh-loading, .modal-content > .modal-loading, .alts-inline-body > .muted {
    display: flex; flex-direction: column; align-items: center; gap: 12px; padding: 40px; color: var(--muted); text-align: center;
}
.modal-loading::before, .veh-loading::before {
    content: ''; width: 40px; height: 40px; border: 4px solid var(--line); border-top-color: var(--brand);
    border-radius: 50%; animation: spin .8s linear infinite;
}

/* Favoriten */
.fav-btn.is-fav { color: #b8860b; border-color: #e8b400; background: #fff8e1; font-weight: 700; }
.fav-btn.is-fav:hover { border-color: #d4a017; background: #fff3cd; }
.btn-ghost.fav-btn.is-fav { color: #b8860b; border-color: #e8b400; background: #fff8e1; }
.fav-count { background: var(--brand); color: #fff; border-radius: 0; font-size: 11px; font-weight: 700; padding: 1px 7px; margin-left: 2px; }
.fav-overlay {
    position: fixed; inset: 0; background: rgba(16,24,40,.55); z-index: 1040;
    display: none; align-items: flex-start; justify-content: center; padding: 40px 20px; overflow-y: auto;
}
.fav-overlay.open { display: flex; }
.fav-box { position: relative; background: #fff; border-radius: 0; width: 100%; max-width: 640px; padding: 24px 26px; box-shadow: 0 24px 70px rgba(0,0,0,.35); }
.fav-close { position: absolute; top: 12px; right: 14px; width: 36px; height: 36px; border: none; border-radius: 0; background: transparent; font-size: 20px; cursor: pointer; color: var(--ink); }
.fav-close:hover { background: #f2f3f5; }
.fav-h { margin: 0 0 12px; font-family: var(--head); }
.fav-art { color: var(--accent); margin-bottom: 16px; }
.fav-sub { font-weight: 700; font-size: 13px; color: var(--muted); margin-bottom: 8px; }
.fav-folders { display: flex; flex-direction: column; gap: 6px; margin-bottom: 16px; }
.fav-folder { display: flex; align-items: center; gap: 10px; padding: 11px 14px; border: 1px solid var(--line); border-radius: 0; background: #fff; cursor: pointer; font-size: 15px; text-align: left; }
.fav-folder:hover { border-color: var(--brand); background: #fcf3f4; }
.fav-folder.in { border-color: #1a8a3a; }
.fav-folder-name { font-weight: 700; flex: 1; }
.fav-folder-cnt { color: var(--muted); font-size: 13px; font-weight: 600; }
.fav-new { display: flex; gap: 8px; }
.fav-new-input { flex: 1; border: 1px solid var(--line); border-radius: 0; padding: 11px 14px; font-size: 15px; }
.fav-new-input.err { border-color: var(--brand); }
.fav-new-input:focus { outline: none; border-color: var(--accent); }
.fav-new-btn { border: none; background: var(--brand); color: #fff; border-radius: 0; padding: 11px 16px; font-weight: 700; cursor: pointer; white-space: nowrap; }
.fav-new-btn:hover { background: var(--accent); }
/* Übersicht */
.fav-grp { border: 1px solid var(--line); border-radius: 0; margin-bottom: 12px; overflow: hidden; }
summary.fav-grp-head { display: flex; align-items: center; gap: 10px; background: #f2f3f5; padding: 9px 14px; cursor: pointer; list-style: none; }
summary.fav-grp-head::-webkit-details-marker { display: none; }
summary.fav-grp-head::after { content: '▾'; color: var(--muted); transition: transform .15s; order: 5; }
.fav-grp[open] > summary.fav-grp-head::after { transform: rotate(180deg); }
.fav-grp-name { font-weight: 700; font-size: 15px; }
.fav-grp-cnt { background: var(--brand); color: #fff; border-radius: 0; font-size: 12px; font-weight: 700; padding: 1px 8px; }
.fav-del-folder { margin-left: auto; border: none; background: none; color: var(--muted); font-size: 12px; cursor: pointer; text-decoration: underline; }
.fav-del-folder:hover { color: var(--brand); }
.fav-items { display: flex; flex-direction: column; }
.fav-item { display: flex; align-items: center; gap: 12px; padding: 9px 14px; border-top: 1px solid var(--line); }
.fav-item-img { width: 44px; height: 44px; object-fit: contain; flex: none; }
.fav-item-img.noimg { background: #eef2f6; border-radius: 0; }
.fav-item-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 5px; }
.fav-item-link { text-decoration: none; color: var(--ink); display: flex; gap: 8px; align-items: baseline; }
.fav-item-link:hover .fav-item-no { text-decoration: underline; }
.fav-item-brand { font-weight: 700; color: var(--accent); font-size: 12px; text-transform: uppercase; }
.fav-item-no { font-weight: 700; }
.fav-item-desc { width: 100%; border: 1px solid var(--line); border-radius: 0; padding: 6px 9px; font-size: 13px; color: var(--ink); }
.fav-item-desc:focus { outline: none; border-color: var(--accent); }
.fav-item-del { border: none; background: none; color: var(--muted); font-size: 16px; cursor: pointer; flex: none; align-self: flex-start; }
.fav-item-del:hover { color: var(--brand); }

/* Artikel-Popup (Modal) */
body.modal-on { overflow: hidden; }
.modal-overlay {
    position: fixed; inset: 0; background: rgba(16, 24, 40, .55); z-index: 1000;
    display: none; align-items: flex-start; justify-content: center; padding: 40px 20px; overflow-y: auto;
}
.modal-overlay.open { display: flex; }
.modal-box {
    position: relative; background: var(--card); border-radius: var(--radius); box-shadow: 0 20px 60px rgba(0,0,0,.3);
    width: 100%; max-width: 900px; padding: 28px;
}
.modal-close {
    position: absolute; top: 12px; right: 12px; width: 34px; height: 34px; border-radius: 0;
    border: 1px solid var(--line); background: #fff; cursor: pointer; font-size: 16px; color: var(--ink); line-height: 1;
}
.modal-close:hover { background: var(--brand); color: #fff; border-color: var(--brand); }
.modal-content .detail { border: none; box-shadow: none; padding: 0; }
.modal-content h1 { margin-top: 0; }
.modal-loading { padding: 40px; text-align: center; color: var(--muted); }

/* Schnellauswahl in der Mitte (breite Checkbox-Liste in Spalten) */
.cat-filter-mid { margin-bottom: 22px; background: #fafbfc !important; }
.cf-load { color: var(--muted); padding: 6px 2px; font-size: 14px; }
.cat-filter-mid .cf-list { max-height: none; columns: 3; column-gap: 26px; }
.cat-filter-mid .cf-list li { break-inside: avoid; }
.cat-filter-mid .cf-actions { justify-content: flex-start; }
.cat-filter-mid .btn-apply { flex: 0 0 auto; min-width: 220px; }
@media (max-width: 900px) { .cat-filter-mid .cf-list { columns: 2; } }

/* === Markenanpassung: keine Emojis, klare rote Akzente === */
.ti:empty, .ic:empty, .cat-icon:empty { display: none; }
.cat-head-icon { display: inline-block; width: 5px; height: 20px; background: var(--brand); border-radius: 2px; margin-right: 10px; vertical-align: -4px; }
/* Kategorie-Karten: rote Kante statt Icon */
.cat-card, .icon-card { border-left: 3px solid var(--brand); }
/* Themen-Listenpunkte: kleiner roter Marker */
.theme-block li a::before { content: ""; width: 6px; height: 6px; background: var(--brand); border-radius: 1px; flex: none; }
/* Promo-Karte dunkel/markig */
.promo-card { background: linear-gradient(155deg, #14171c, #2a2f3a); }

/* Footer */
.footer { text-align: center; color: var(--muted); font-size: 13px; padding: 30px; }

@media (max-width: 640px) {
    .detail { grid-template-columns: 1fr; }
}
