/* =========================================================================
   Fahrzeugbestand (Daten: github.com/escoerfan/ecs-bestand → bestand.json)
   Genutzt auf: index.html (Vorschau), fahrzeuge.html (Liste),
   fahrzeug.html (Einzelseite eines Fahrzeugs). Logik: js/bestand.js
   ========================================================================= */

.vw-section,
.vw-section *,
.vw-section *::before,
.vw-section *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

.vw-section {
    background: #ffffff;
    position: relative;
    left: 50%;
    right: 50%;
    width: 100vw !important;
    max-width: none !important;
    margin-left: -50vw !important;
    margin-right: -50vw !important;
    padding: 64px 24px;
    font-family: 'Figtree', system-ui, sans-serif;
    color: #262626;
    -webkit-font-smoothing: antialiased;
}

.vw-inner {
    max-width: 1294px;
    margin: 0 auto;
}

.vw-filter {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 30px;
}

.vw-filter-btn {
    font-family: 'Figtree', system-ui, sans-serif;
    font-size: 14px;
    font-weight: 600;
    color: #262626;
    background: #ffffff;
    border: 1px solid #dcdcdc;
    padding: 10px 18px;
    border-radius: 8px;
    cursor: pointer;
    transition: border-color 0.15s, background 0.15s;
    white-space: nowrap;
}

.vw-filter-btn:hover {
    border-color: #262626;
}

.vw-filter-btn.active {
    background: linear-gradient(180deg, #262626 0%, #060606 100%);
    color: #ffffff;
    border-color: #262626;
}

.vw-filter-cnt {
    opacity: 0.55;
    margin-left: 5px;
    font-weight: 500;
}

.vw-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 26px;
}

.vw-card {
    min-width: 0;
    color: inherit;
    text-decoration: none;
    background: #ffffff;
    border: 1px solid #e4e4e4;
    border-radius: 12px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    cursor: pointer;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.vw-card:hover {
    border-color: #bdbdbd;
    box-shadow: 0 6px 24px rgba(0, 0, 0, 0.07);
}

.vw-img-wrap {
    position: relative;
    width: 100%;
    aspect-ratio: 16/10;
    background: #f2f2f2;
    overflow: hidden;
}

.vw-img-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.vw-img-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.vw-img-placeholder svg {
    opacity: 0.18;
}

.vw-badge {
    position: absolute;
    top: 14px;
    left: 14px;
    font-size: 13px;
    font-weight: 600;
    color: #262626;
    background: #ffffff;
    padding: 5px 11px;
    border-radius: 20px;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.14);
    font-family: 'Figtree', system-ui, sans-serif;
}

.vw-body {
    padding: 22px 24px 24px;
    text-align: left;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.vw-title {
    font-size: 18px;
    font-weight: 700;
    color: #262626;
    line-height: 1.35;
    margin-bottom: 8px;
    word-break: break-word;
    overflow-wrap: break-word;
    font-family: 'Figtree', system-ui, sans-serif;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 49px;
}

.vw-loc {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    color: #6b6b6b;
    margin-bottom: 16px;
}

.vw-specs {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 11px 16px;
    padding: 17px 0;
    border-top: 1px solid #ececec;
    border-bottom: 1px solid #ececec;
    margin-bottom: 14px;
}

.vw-spec {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    font-size: 14px;
    color: #2b2b2b;
    line-height: 1.35;
}

.vw-spec svg {
    flex-shrink: 0;
    margin-top: 1px;
}

.vw-detail {
    font-size: 14px;
    font-weight: 600;
    color: #262626;
    text-decoration: underline;
    text-underline-offset: 3px;
    margin-bottom: 18px;
}

.vw-footer {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 12px;
    margin-top: auto;
}

.vw-price-label {
    font-size: 13px;
    color: #8a8a8a;
    margin-bottom: 2px;
}

.vw-price {
    font-size: 24px;
    font-weight: 800;
    color: #262626;
    font-variant-numeric: tabular-nums;
    line-height: 1.15;
    font-family: 'Figtree', system-ui, sans-serif;
}

.vw-price-gross {
    font-size: 13px;
    color: #8a8a8a;
    margin-top: 2px;
}

.vw-price.on-request {
    font-size: 16px;
    font-weight: 600;
    color: #3d3d3d;
}

.vw-card-cta {
    font-size: 14px;
    font-weight: 600;
    color: #ffffff;
    background: linear-gradient(180deg, #262626 0%, #060606 100%);
    border: 1px solid #262626;
    padding: 12px 22px;
    border-radius: 8px;
    font-family: 'Figtree', system-ui, sans-serif;
    transition: opacity 0.2s;
    white-space: nowrap;
}

.vw-card:hover .vw-card-cta {
    opacity: 0.82;
}

.vw-status {
    grid-column: 1/-1;
    text-align: left;
    padding: 40px 0;
    color: #7a7a7a;
    font-size: 14px;
    font-family: 'Figtree', system-ui, sans-serif;
}

/* ------------------------------------------------ Vorschau auf der Startseite */
.vw-more {
    display: flex;
    justify-content: center;
    margin-top: 44px;
}

/* ---------------------------------------------------- Einzelseite Fahrzeug */
.vw-detail-section {
    padding-top: 56px;
    padding-bottom: 96px;
}

.vw-back {
    display: inline-block;
    font-size: 15px;
    font-weight: 600;
    color: #262626;
    text-decoration: underline;
    text-underline-offset: 3px;
    margin-bottom: 28px;
}

.vw-d-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.45fr) minmax(0, 1fr);
    gap: 48px;
    align-items: start;
}

.vw-d-gallery {
    min-width: 0;
}

.vw-d-stage {
    position: relative;
    aspect-ratio: 4 / 3;
    background: #f2f2f2;
    overflow: hidden;
}

.vw-d-stage img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.vw-d-nav {
    position: absolute;
    bottom: 14px;
    left: 0;
    right: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
}

.vw-d-nav-btn {
    background: #ffffff;
    border: 1px solid #e0e0e0;
    color: #262626;
    width: 40px;
    height: 40px;
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.vw-d-nav-btn:hover {
    background: #f2f2f2;
}

.vw-d-counter {
    font-size: 13px;
    font-weight: 600;
    color: #262626;
    background: #ffffff;
    border: 1px solid #e0e0e0;
    padding: 8px 12px;
    min-width: 64px;
    text-align: center;
}

.vw-d-thumbs {
    display: flex;
    gap: 8px;
    margin-top: 10px;
    overflow-x: auto;
    padding-bottom: 4px;
}

.vw-d-thumbs button {
    width: 88px;
    height: 62px;
    flex-shrink: 0;
    overflow: hidden;
    border: 2px solid transparent;
    background: #f2f2f2;
    cursor: pointer;
    opacity: 0.6;
}

.vw-d-thumbs button.active {
    border-color: #262626;
    opacity: 1;
}

.vw-d-thumbs button:hover {
    opacity: 1;
}

.vw-d-thumbs img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.vw-d-info {
    position: sticky;
    top: 110px;
    border: 1px solid #e4e4e4;
    padding: 30px;
}

.vw-d-info .vw-loc {
    margin-bottom: 20px;
}

.vw-d-price-block {
    padding: 20px 0;
    border-top: 1px solid #ececec;
}

.vw-d-price {
    font-size: 34px;
    font-weight: 800;
    color: #262626;
    font-variant-numeric: tabular-nums;
    line-height: 1.15;
}

.vw-d-price.on-request {
    font-size: 22px;
    font-weight: 600;
}

.vw-d-info .vw-specs {
    grid-template-columns: 1fr;
    margin-bottom: 24px;
}

.vw-d-actions {
    display: grid;
    gap: 10px;
}

.vw-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 50px;
    padding: 12px 22px;
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    white-space: nowrap;
    transition: opacity 0.2s;
}

.vw-btn:hover {
    opacity: 0.82;
}

.vw-btn-primary {
    background: linear-gradient(180deg, #262626 0%, #060606 100%);
    color: #ffffff;
    border: 1px solid #262626;
}

.vw-btn-secondary {
    background: #ffffff;
    color: #262626;
    border: 1px solid #d5d5d5;
}

.vw-d-desc {
    margin-top: 64px;
    max-width: 860px;
}

.vw-d-desc h2 {
    font-size: 24px;
    font-weight: 700;
    color: #262626;
    margin-bottom: 18px;
}

.vw-d-desc-text {
    font-size: 16px;
    line-height: 1.75;
    color: #333333;
    white-space: pre-line;
}

/* ---------------------------------------------------------------- Responsive */
@media (max-width: 1050px) {
    .vw-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .vw-d-grid {
        grid-template-columns: 1fr;
        gap: 28px;
    }

    .vw-d-info {
        position: static;
    }
}

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

    .vw-section {
        padding: 36px 18px;
    }

    .vw-detail-section {
        padding-top: 32px;
        padding-bottom: 64px;
    }

    .vw-d-info {
        padding: 22px 20px;
    }

    .vw-d-price {
        font-size: 28px;
    }
}
