/* ============================================================
   vehicle-results.css
   Real vehicle card + result chrome styles.
   Works inside .bt-screen created by booking-transition.js.
   ============================================================ */

/* ─── Real header ────────────────────────────────────────────── */
.vr-header {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    padding: 1.1rem 1.25rem 0.85rem;
    position: sticky;
    top: 0;
    background: #ffffff;
    z-index: 10;
    border-bottom: 1px solid #f0f0f0;
    font-family: "Montserrat", "Metropolis", "Segoe UI", sans-serif;
}

.vr-back-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border: none;
    border-radius: 50%;
    background: #f4f4f6;
    cursor: pointer;
    flex-shrink: 0;
    transition: background 0.15s ease;
    color: #1a1a1a;
    font-size: 1.1rem;
    line-height: 1;
}

.vr-back-btn:hover,
.vr-back-btn:focus-visible {
    background: #e8e8ec;
    outline: none;
}

.vr-header-title {
    font-size: 0.9rem;
    font-weight: 700;
    color: #1a1a1a;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    flex: 1;
}

.vr-header-count {
    font-size: 0.75rem;
    font-weight: 600;
    color: #888;
    white-space: nowrap;
    flex-shrink: 0;
}

/* ─── Real filter pills ──────────────────────────────────────── */
.vr-filter-row {
    display: flex;
    gap: 0.55rem;
    padding: 0.75rem 1.25rem;
    overflow-x: auto;
    scrollbar-width: none;
}

.vr-filter-row::-webkit-scrollbar {
    display: none;
}

.vr-filter-pill {
    border: 1.5px solid #e2e2e8;
    border-radius: 999px;
    background: #ffffff;
    padding: 0.35rem 0.9rem;
    font-family: "Montserrat", "Metropolis", "Segoe UI", sans-serif;
    font-size: 0.75rem;
    font-weight: 600;
    color: #555;
    cursor: pointer;
    white-space: nowrap;
    flex-shrink: 0;
    transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.vr-filter-pill:hover {
    border-color: #bbb;
    color: #1a1a1a;
}

.vr-filter-pill--active {
    background: linear-gradient(
        135deg,
        rgba(195, 2, 4, 0.12) 0%,
        rgba(220, 5, 4, 0.08) 42%,
        rgba(242, 242, 245, 0.96) 100%
    );
    border-color: rgba(195, 2, 4, 0.18);
    color: #7d2020;
}

/* ─── Results list ───────────────────────────────────────────── */
.vr-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding: 0.25rem 1.25rem 2rem;
}

/* ─── Vehicle card ───────────────────────────────────────────── */
.vr-card {
    background: #ffffff;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.08);

    /* Staggered enter: --vr-i is set inline by JS */
    opacity: 0;
    transform: translateY(18px);
    animation: vr-card-enter 0.38s cubic-bezier(0.22, 1, 0.36, 1) forwards;
    animation-delay: calc(var(--vr-i, 0) * 70ms + 40ms);
}

@keyframes vr-card-enter {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Hidden by filter */
.vr-card--hidden {
    display: none;
}

/* ─── Card image ─────────────────────────────────────────────── */
.vr-card-img-wrap {
    position: relative;
    width: 100%;
    height: 156px;
    overflow: hidden;
    background: linear-gradient(
        135deg,
        rgba(242, 242, 245, 1) 0%,
        rgba(239, 231, 231, 1) 52%,
        rgba(195, 2, 4, 0.08) 100%
    );
}

.vr-card-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
    display: block;
    padding: 0.5rem;
    box-sizing: border-box;
    transition: opacity 0.3s ease;
}

.vr-card-img[loading] {
    opacity: 0;
}

.vr-card-badge {
    position: absolute;
    top: 0.65rem;
    left: 0.65rem;
    background: linear-gradient(
        135deg,
        rgba(255, 255, 255, 0.82) 0%,
        rgba(195, 2, 4, 0.12) 100%
    );
    color: #7d2020;
    font-family: "Montserrat", "Metropolis", "Segoe UI", sans-serif;
    font-size: 0.65rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    padding: 0.25rem 0.55rem;
    border-radius: 999px;
    border: 1px solid rgba(195, 2, 4, 0.14);
    backdrop-filter: blur(4px);
}

/* ─── Card body ──────────────────────────────────────────────── */
.vr-card-body {
    padding: 0.9rem 1rem 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    font-family: "Montserrat", "Metropolis", "Segoe UI", sans-serif;
}

.vr-card-title {
    font-size: 1rem;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0;
}

.vr-card-sub {
    font-size: 0.75rem;
    color: #999;
    margin: 0;
}

/* ─── Feature chips ──────────────────────────────────────────── */
.vr-card-features {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin-top: 0.15rem;
}

.vr-feat {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    background: #f4f4f6;
    border-radius: 8px;
    padding: 0.3rem 0.55rem;
    font-size: 0.7rem;
    font-weight: 600;
    color: #444;
}

.vr-feat-icon {
    font-size: 0.8rem;
    line-height: 1;
}

/* ─── Price + CTA ────────────────────────────────────────────── */
.vr-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 0.35rem;
    padding-top: 0.7rem;
    border-top: 1px solid #f0f0f0;
}

.vr-price {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.12rem;
}

.vr-price-old {
    position: relative;
    display: inline-flex;
    align-items: center;
    font-size: 0.78rem;
    font-weight: 600;
    color: #8f8f9b;
    padding: 0 0.1rem;
}

.vr-price-old::after {
    content: "";
    position: absolute;
    left: -0.08rem;
    right: -0.08rem;
    top: 50%;
    border-top: 2px solid rgba(185, 28, 28, 0.55);
    transform: translateY(-50%);
}

.vr-price-current {
    display: flex;
    align-items: baseline;
    gap: 0.2rem;
}

.vr-price-amount {
    font-size: 1.2rem;
    font-weight: 800;
    color: #1a1a1a;
}

.vr-price-period {
    font-size: 0.72rem;
    font-weight: 600;
    color: #999;
}

.vr-select-btn {
    background: linear-gradient(
        135deg,
        #b91c1c 0%,
        #991b1b 52%,
        #7f1d1d 100%
    );
    color: #ffffff;
    border: 1px solid rgba(127, 29, 29, 0.42);
    border-radius: 12px;
    padding: 0.55rem 1.1rem;
    font-family: "Montserrat", "Metropolis", "Segoe UI", sans-serif;
    font-size: 0.78rem;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 10px 22px rgba(127, 29, 29, 0.18);
    transition: border-color 0.15s ease, box-shadow 0.15s ease, transform 0.1s ease;
}

.vr-select-btn:hover {
    border-color: rgba(127, 29, 29, 0.56);
    box-shadow: 0 12px 24px rgba(127, 29, 29, 0.24);
}

.vr-select-btn:active {
    transform: scale(0.97);
}

/* ─── Empty state ────────────────────────────────────────────── */
.vr-empty {
    text-align: center;
    padding: 3rem 1.5rem;
    font-family: "Montserrat", "Metropolis", "Segoe UI", sans-serif;
    color: #999;
}

.vr-empty-icon {
    font-size: 2.5rem;
    margin-bottom: 0.75rem;
}

.vr-empty-text {
    font-size: 0.9rem;
    font-weight: 600;
}

/* ─── Search summary bar (below header) ─────────────────────── */
.vr-search-summary {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0 1.25rem 0.5rem;
    font-family: "Montserrat", "Metropolis", "Segoe UI", sans-serif;
    font-size: 0.72rem;
    color: #777;
    flex-wrap: wrap;
}

.vr-summary-sep {
    color: #ccc;
}

/* ─── Desktop Layout ─────────────────────────────────────────── */
@media (min-width: 900px) {
    .vr-search-summary,
    .vr-filter-row,
    .vr-list,
    .vr-empty {
        width: min(980px, calc(100vw - 7rem));
        margin-left: auto;
        margin-right: auto;
    }

    .vr-search-summary {
        padding: 0 0 0.65rem;
    }

    .vr-filter-row {
        padding: 0.75rem 0 1rem;
    }

    .vr-list {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 1.1rem 1rem;
        padding: 0.25rem 0 2.25rem;
        align-items: start;
    }

    .vr-card {
        height: 100%;
    }
}

/* ─── Mobile Styles ──────────────────────────────────────────── */
@media (max-width: 480px) {
    .vr-header {
        padding: 0.85rem 1rem 0.65rem;
        gap: 0.6rem;
    }

    .vr-back-btn {
        width: 32px;
        height: 32px;
        font-size: 0.95rem;
    }

    .vr-header-title {
        font-size: 0.8rem;
    }

    .vr-header-count {
        font-size: 0.65rem;
    }

    .vr-filter-row {
        gap: 0.4rem;
        padding: 0.6rem 1rem;
    }

    .vr-filter-pill {
        padding: 0.25rem 0.75rem;
        font-size: 0.65rem;
    }

    .vr-list {
        gap: 0.75rem;
        padding: 0.25rem 1rem 1.5rem;
    }

    .vr-card-img-wrap {
        height: 120px;
    }

    .vr-card-body {
        padding: 0.65rem 0.8rem 0.85rem;
        gap: 0.35rem;
    }

    .vr-card-title {
        font-size: 0.85rem;
    }

    .vr-card-sub {
        font-size: 0.65rem;
    }

    .vr-card-features {
        gap: 0.3rem;
        margin-top: 0.1rem;
    }

    .vr-feat {
        padding: 0.25rem 0.45rem;
        font-size: 0.6rem;
    }

    .vr-feat-icon {
        font-size: 0.7rem;
    }

    .vr-card-footer {
        margin-top: 0.25rem;
        padding-top: 0.55rem;
        gap: 0.5rem;
    }

    .vr-price-old {
        font-size: 0.7rem;
    }

    .vr-price-amount {
        font-size: 1rem;
    }

    .vr-price-period {
        font-size: 0.62rem;
    }

    .vr-select-btn {
        padding: 0.45rem 0.85rem;
        font-size: 0.7rem;
    }

    .vr-search-summary {
        padding: 0 1rem 0.35rem;
        font-size: 0.65rem;
        gap: 0.35rem;
    }

    .vr-empty {
        padding: 2rem 1.25rem;
    }

    .vr-empty-icon {
        font-size: 2rem;
        margin-bottom: 0.5rem;
    }

    .vr-empty-text {
        font-size: 0.8rem;
    }
}
