/* Garage Limacher – Fahrzeuge, modernes Design */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700;800&display=swap');

.v-wrap { font-family: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif; color: var(--fg); background: var(--white); }
.v-wrap *, .v-wrap *::before, .v-wrap *::after { box-sizing: border-box; }

/* Hero */
.v-hero { background: linear-gradient(160deg, var(--dark) 0%, var(--navy) 100%); color: var(--white); padding: 78px 24px 64px; text-align: center; }
.v-hero h1 { font-size: clamp(2rem, 5vw, 3.2rem); font-weight: 800; letter-spacing: -.02em; margin: 0 0 16px; }
.v-hero p { color: var(--on-dark); max-width: 640px; margin: 0 auto; font-size: 1.06rem; line-height: 1.6; }
.v-count { display: inline-block; margin-top: 24px; padding: 9px 20px; border: 1px solid rgba(255,200,69,.45); color: var(--gold); border-radius: 100px; font-size: .85rem; font-weight: 600; letter-spacing: .04em; }

/* Toolbar: Filter + Sortierung */
.v-toolbar { max-width: 1180px; margin: 0 auto; padding: 40px 24px 0; display: flex; justify-content: space-between; align-items: center; gap: 18px 26px; flex-wrap: wrap; }
.v-filters { display: flex; flex-wrap: wrap; gap: 10px; }
.vf-pill { border: 1px solid var(--line); background: var(--white); color: var(--muted); border-radius: 100px; padding: 9px 18px; font: inherit; font-size: .86rem; font-weight: 600; cursor: pointer; transition: background .2s, color .2s, border-color .2s; }
.vf-pill:hover { border-color: var(--dark); color: var(--dark); }
.vf-pill.is-active { background: var(--dark); border-color: var(--dark); color: var(--white); }
.v-selects { display: flex; gap: 10px; flex-wrap: wrap; }
.v-select { border: 1px solid var(--line); background: var(--white); color: var(--fg); border-radius: 100px; padding: 9px 16px; font: inherit; font-size: .86rem; cursor: pointer; }
.v-select:focus { outline: none; border-color: var(--dark); }

/* Karten-Raster */
.v-grid { max-width: 1180px; margin: 0 auto; padding: 26px 24px var(--section-y); display: grid; grid-template-columns: repeat(auto-fill, minmax(332px, 1fr)); gap: 30px; }
.vcard { display: flex; flex-direction: column; background: var(--white); border: 1px solid var(--line); border-radius: 16px; overflow: hidden; text-decoration: none; color: inherit; transition: transform .25s ease, border-color .25s ease; }
.vcard:hover { transform: translateY(-4px); border-color: var(--gold); }
.vcard-media { position: relative; aspect-ratio: 16/10; background: var(--dark); overflow: hidden; }
.vcard-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s cubic-bezier(.2,.7,.2,1); }
.vcard:hover .vcard-media img { transform: scale(1.06); }
.vcard-tag { position: absolute; top: 14px; left: 14px; background: var(--dark); color: var(--gold); font-size: .64rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; padding: 6px 12px; border-radius: 100px; }
.vcard-noimg { width: 100%; height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; color: var(--on-dark); background: linear-gradient(160deg, var(--dark), var(--navy)); font-size: .85rem; }
.vcard-noimg svg { width: 40px; height: 40px; opacity: .5; }
.vcard-body { display: flex; flex-direction: column; flex: 1; padding: 22px 22px 24px; }
.vcard-title { font-size: 1.2rem; font-weight: 700; letter-spacing: -.01em; line-height: 1.25; margin: 0 0 6px; color: var(--dark); }
.vcard-price { font-size: 1.25rem; font-weight: 800; color: var(--dark); margin: 0 0 16px; }
.vcard-meta { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; padding: 0; margin: 0 0 20px; }
.vcard-meta li { background: var(--bg-soft); border: 1px solid var(--line); border-radius: 8px; padding: 5px 11px; font-size: .79rem; font-weight: 500; color: var(--muted); }
.vcard-more { margin-top: auto; display: inline-flex; align-items: center; gap: 8px; color: var(--dark); font-weight: 600; font-size: .92rem; }
.vcard:hover .vcard-more { color: var(--gold); }
.v-empty { max-width: 1180px; margin: 0 auto; padding: 30px 24px var(--section-y); text-align: center; color: var(--muted); }

/* AutoScout24 HCI-Widget-Bereich */
.v-hci { max-width: 1180px; margin: 0 auto; padding: 42px 24px var(--section-y); }
.v-hci .embedded-content-area { min-height: 360px; }
.v-hci .hci-container { min-height: 360px; }
@media (max-width: 560px) { .v-grid { grid-template-columns: 1fr; padding: 22px 20px var(--section-y); } .v-toolbar { padding-top: 30px; } }

/* Detailseite */
.v-detail { max-width: 1180px; margin: 0 auto; padding: 28px 24px var(--section-y); }
.v-back { display: inline-block; color: var(--muted); text-decoration: none; font-weight: 500; margin-bottom: 22px; }
.v-back:hover { color: var(--dark); }
.v-dhead { display: flex; justify-content: space-between; align-items: flex-end; flex-wrap: wrap; gap: 14px; padding-bottom: 24px; margin-bottom: 30px; border-bottom: 1px solid var(--line); }
.v-dhead .v-brand { color: var(--navy); font-weight: 700; letter-spacing: .15em; font-size: .8rem; text-transform: uppercase; margin: 0 0 6px; }
.v-dhead h1 { font-size: clamp(1.8rem, 4vw, 2.7rem); font-weight: 800; letter-spacing: -.02em; margin: 0; }
.v-dhead .v-price { font-size: 2rem; margin: 0; }

.v-gallery { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 46px; }
.v-gallery a { display: block; border-radius: 12px; overflow: hidden; aspect-ratio: 4/3; cursor: pointer; }
.v-gallery a:first-child { grid-column: span 2; grid-row: span 2; }
.v-gallery img { width: 100%; height: 100%; object-fit: cover; transition: transform .45s ease; }
.v-gallery a:hover img { transform: scale(1.07); }
.v-gallery-none { background: linear-gradient(160deg,var(--dark),var(--navy)); color: var(--muted); border-radius: 14px; padding: 70px 20px; text-align: center; margin-bottom: 46px; }

.v-cols { display: grid; grid-template-columns: 1fr 330px; gap: 44px; align-items: start; }
.v-sec { margin-bottom: 42px; }
.v-sec h3 { font-size: 1.3rem; font-weight: 700; margin: 0 0 18px; }
.v-spec-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.v-spec-grid > div { background: var(--white); padding: 14px 17px; }
.v-spec-grid .k { font-size: .73rem; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; margin-bottom: 3px; }
.v-spec-grid .val { font-weight: 600; font-size: 1.02rem; }
.v-equip ul { columns: 2; column-gap: 28px; list-style: none; padding: 0; margin: 0; }
.v-equip li { padding: 7px 0 7px 24px; position: relative; color: var(--muted); break-inside: avoid; border-bottom: 1px solid var(--bg-soft); }
.v-equip li::before { content: ""; position: absolute; left: 0; top: 14px; width: 8px; height: 8px; border-radius: 50%; background: var(--gold); }
.v-desc p { line-height: 1.75; color: var(--muted); white-space: pre-line; margin: 0; }

.v-cta { background: linear-gradient(160deg,var(--dark),var(--navy)); color: var(--white); border-radius: 16px; padding: 30px; position: sticky; top: 24px; }
.v-cta h3 { color: var(--white); font-size: 1.2rem; margin: 0 0 8px; }
.v-cta p { color: var(--on-dark); font-size: .92rem; line-height: 1.55; margin: 0 0 20px; }
.v-cta .v-btn { width: 100%; justify-content: center; margin-bottom: 10px; background: var(--gold); color: var(--dark); }
.v-cta .v-btn:hover { background: var(--white); }
.v-cta .v-btn.alt { background: transparent; color: var(--white); border: 1px solid rgba(255,255,255,.3); }
.v-cta .v-btn.alt:hover { background: rgba(255,255,255,.1); }
@media (max-width: 880px) { .v-cols{grid-template-columns:1fr;gap:8px;} .v-cta{position:static;} .v-gallery{grid-template-columns:repeat(2,1fr);} .v-equip ul{columns:1;} }

/* Lightbox */
.v-lb { position: fixed; inset: 0; background: rgba(7,13,21,.95); display: none; align-items: center; justify-content: center; z-index: 9999; }
.v-lb.open { display: flex; }
.v-lb img { max-width: 92vw; max-height: 88vh; border-radius: 6px; box-shadow: none; }
.v-lb button { position: absolute; background: none; border: 0; color: var(--white); cursor: pointer; line-height: 1; }
.v-lb .close { top: 20px; right: 28px; font-size: 2.6rem; }
.v-lb .prev, .v-lb .next { top: 50%; transform: translateY(-50%); font-size: 3.4rem; padding: 0 18px; opacity: .8; }
.v-lb .prev { left: 10px; } .v-lb .next { right: 10px; }
.v-lb .prev:hover, .v-lb .next:hover, .v-lb .close:hover { opacity: 1; color: var(--gold); }

/* ===== Original-Suche/Filterleiste (AutoScout-Stil) ===== */
.v-search { max-width: 1180px; margin: 0 auto; padding: 36px 24px 0; }
.vs-head { display: flex; align-items: center; justify-content: space-between; gap: 16px 24px; flex-wrap: wrap; padding-bottom: 18px; border-bottom: 1px solid var(--line); }
.vs-count { font-size: 1.55rem; font-weight: 800; letter-spacing: -.015em; color: var(--dark); }
.vs-tools { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.vs-reset { display: inline-flex; align-items: center; gap: 7px; border: 0; background: none; color: var(--muted); font: inherit; font-size: .9rem; font-weight: 600; cursor: pointer; padding: 0; }
.vs-reset:hover { color: var(--dark); }
.vs-reset svg { width: 16px; height: 16px; }
.vs-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px 22px; padding: 26px 0 10px; }
.vs-field label { display: block; font-size: .82rem; font-weight: 700; color: var(--dark); margin-bottom: 8px; }
.vs-select, .vs-input { width: 100%; border: 1px solid var(--line); background: var(--white); color: var(--fg); border-radius: 10px; padding: 12px 14px; font: inherit; font-size: .92rem; }
.vs-select { cursor: pointer; }
.vs-sort { width: auto; min-width: 210px; }
.vs-select:focus, .vs-input:focus { outline: none; border-color: var(--dark); box-shadow: 0 0 0 3px rgba(12,35,64,.08); }
@media (max-width: 900px) { .vs-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 520px) { .vs-grid { grid-template-columns: 1fr; } .vs-sort { min-width: 0; } }

/* ===== Galerie auf 5 Kacheln begrenzen + „+N"-Overlay ===== */
.v-gallery a { position: relative; }
.v-gallery a.is-hidden { display: none; }
.v-more { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  background: rgba(2,7,13,.55); color: #fff; font-size: clamp(1.4rem, 2.4vw, 2rem); font-weight: 700;
  letter-spacing: .01em; -webkit-backdrop-filter: blur(1px); backdrop-filter: blur(1px); transition: background .25s ease; }
.v-gallery a:hover .v-more { background: rgba(2,7,13,.42); }

/* ===== Basis-Button für Detail-CTA (nach cars.css-Umbau wieder ergänzt) ===== */
.v-btn { display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  padding: 14px 26px; border: 1px solid transparent; border-radius: 100px;
  font: inherit; font-size: .95rem; font-weight: 600; text-decoration: none; cursor: pointer;
  transition: background .2s ease, color .2s ease, border-color .2s ease; }
.v-back { display: inline-block; color: var(--muted); text-decoration: none; font-weight: 600; margin-bottom: 22px; }
.v-back:hover { color: var(--dark); }

/* ===== Detail: Fahrzeugdaten + CTA nebeneinander, gleiche Höhe ===== */
.v-top { display: grid; grid-template-columns: 1fr 330px; gap: 44px; align-items: stretch; margin-bottom: 14px; }
.v-top > div, .v-top > aside { min-width: 0; }
.v-top .v-sec { margin-bottom: 0; }
.v-top .v-cta { position: static; top: auto; height: 100%; display: flex; flex-direction: column; }
.v-top .v-cta p { margin-bottom: auto; }       /* Buttons nach unten */
.v-top .v-cta .v-btn:first-of-type { margin-top: 22px; }
.v-rest { margin-top: 8px; }
@media (max-width: 880px) {
  .v-top { grid-template-columns: 1fr; gap: 16px; }
  .v-top .v-cta { height: auto; }
  .v-top .v-cta p { margin-bottom: 20px; }
}

/* ===== CTA-Höhe an Fahrzeugdaten gekoppelt (min-height per JS), Buttons unten ===== */
.v-cta { display: flex; flex-direction: column; }
.v-cta p { margin-bottom: auto; }
@media (max-width: 880px) { .v-cta p { margin-bottom: 20px; } }

/* =========================================================
   Fahrzeug-Seiten – Mobile-Feinschliff
   ========================================================= */
@media (max-width: 600px) {
  /* Hero kompakter */
  .v-hero { padding: 60px 22px 48px; }
  /* Detail-Header: kompakter, Preis nicht grösser als der Titel */
  .v-dhead { padding-bottom: 18px; margin-bottom: 22px; }
  .v-dhead .v-price { font-size: 1.55rem; }
  /* Fahrzeugdaten als gut lesbare einspaltige Liste (keine umbrechenden Werte) */
  .v-spec-grid { grid-template-columns: 1fr; }
  /* Galerie etwas enger */
  .v-gallery { gap: 8px; margin-bottom: 32px; }
  /* CTA-Buttons gut tappbar */
  .v-cta .v-btn { padding: 15px 26px; }
}
