/* =============================================
   المسار الكوري للسيارات — app.css
   ============================================= */

:root {
    /* ── Charcoal Black ── */
    --charcoal:         #1a1c20;
    --charcoal-deep:    #111316;
    --charcoal-mid:     #22252b;
    --charcoal-light:   #2d3139;
    --charcoal-soft:    #3a3f48;

    /* ── Ivory White ── */
    --ivory:            #f4f1ec;
    --ivory-light:      #faf8f5;
    --ivory-mid:        #e8e4dd;
    --ivory-dark:       #cdc8be;

    /* ── Medium Gray ── */
    --gray:             #8a8f98;
    --gray-light:       #b4b9c2;
    --gray-dark:        #5c6170;
    --gray-subtle:      #444950;

    /* ── Sky Blue (calm) ── */
    --blue:             #4a90b8;
    --blue-light:       #6aadd1;
    --blue-dark:        #3370a0;
    --blue-pale:        #d6eaf8;
    --blue-glow:        rgba(74,144,184,.25);

    /* ── Semantic aliases (keep old names working) ── */
    --gold:             var(--blue);
    --gold-light:       var(--blue-light);
    --gold-dark:        var(--blue-dark);
    --brown-dark:       var(--charcoal-deep);
    --brown-mid:        var(--charcoal-mid);
    --brown-light:      var(--charcoal-light);
    --cream:            var(--ivory);
    --cream-light:      var(--ivory-light);
    --text-dark:        var(--ivory);
    --text-muted:       var(--gray);
    --card-bg:          var(--charcoal-mid);
    --border:           var(--charcoal-soft);
    --shadow:       0 4px 24px rgba(0,0,0,.28);
    --shadow-hover: 0 12px 40px rgba(0,0,0,.42);
    --radius:       14px;
    --radius-sm:    8px;
    --transition:   all .3s cubic-bezier(.25,.8,.25,1);
}

* { box-sizing: border-box; }

body {
    font-family: 'Cairo', sans-serif;
    background: var(--charcoal-deep);
    color: var(--ivory);
    direction: rtl;
}

/* ===== SCROLLBAR ===== */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--charcoal-mid); }
::-webkit-scrollbar-thumb { background: var(--blue); border-radius: 3px; }

/* ===== NPROGRESS ===== */
#nprogress .bar { background: var(--blue-light) !important; height: 3px; }
#nprogress .peg  { box-shadow: 0 0 10px var(--blue-light), 0 0 5px var(--blue-light) !important; }

/* ===== NAVBAR ===== */
.navbar-custom {
    background: var(--charcoal-deep);
    padding: 0;
    box-shadow: 0 2px 20px rgba(0,0,0,.4);
    border-bottom: 2px solid var(--gold);
    z-index: 1050;
}
.navbar-custom .navbar-brand img { height: 52px; filter: drop-shadow(0 0 8px rgba(200,151,42,.5)); transition: transform .3s; }
.navbar-custom .navbar-brand img:hover { transform: scale(1.05); }
.logo-text { color: var(--gold-light); font-weight: 900; font-size: 1.1rem; display: flex; align-items: center; gap: .4rem; }

.navbar-custom .nav-link {
    color: var(--cream) !important;
    font-weight: 600;
    font-size: 14.5px;
    padding: 1.15rem .9rem !important;
    position: relative;
    transition: color .3s;
}
.navbar-custom .nav-link::after {
    content: '';
    position: absolute;
    bottom: 0; right: 50%; left: 50%;
    height: 2px;
    background: var(--blue-light);
    transition: all .3s;
}
.navbar-custom .nav-link:hover::after,
.navbar-custom .nav-link.active::after { right: 0; left: 0; }
.navbar-custom .nav-link:hover,
.navbar-custom .nav-link.active { color: var(--gold-light) !important; }

.navbar-toggler { border-color: var(--gold) !important; }
.navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='%23c8972a' stroke-linecap='round' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e") !important;
}

/* Nav search */
.nav-search-wrap { position: relative; }
.nav-search-input {
    border: 1.5px solid rgba(200,151,42,.4);
    border-radius: 30px;
    background: rgba(255,255,255,.1);
    color: var(--cream);
    padding: .35rem 2.2rem .35rem 1rem;
    font-family: 'Cairo', sans-serif;
    font-size: 13px;
    width: 220px;
    transition: var(--transition);
    outline: none;
}
.nav-search-input::placeholder { color: rgba(245,237,224,.5); }
.nav-search-input:focus { background: rgba(255,255,255,.18); border-color: var(--gold); width: 260px; }
.nav-search-icon { position: absolute; left: .7rem; top: 50%; transform: translateY(-50%); color: var(--gold); font-size: 13px; pointer-events: none; }
.nav-search-results {
    display: none;
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    width: 320px;
    background: var(--charcoal-mid);
    border-radius: var(--radius-sm);
    border: 1.5px solid var(--border);
    box-shadow: var(--shadow-hover);
    z-index: 9999;
    overflow: hidden;
}
.search-result-item {
    display: flex;
    align-items: center;
    gap: .8rem;
    padding: .7rem 1rem;
    text-decoration: none;
    border-bottom: 1px solid var(--border);
    transition: background .2s;
    color: var(--text-dark);
}
.search-result-item:hover { background: var(--cream-light); }
.search-result-item img { width: 60px; height: 42px; object-fit: cover; border-radius: 6px; flex-shrink: 0; }
.sr-title { font-weight: 700; font-size: 13px; }
.sr-sub { font-size: 12px; color: var(--text-muted); }
.sr-empty { padding: 1rem; text-align: center; color: var(--text-muted); font-size: 13px; }

/* Call btn */
.btn-call {
    background: linear-gradient(135deg, var(--gold) 0%, var(--gold-light) 100%);
    color: var(--brown-dark) !important;
    border-radius: 30px;
    font-weight: 700;
    padding: .4rem 1.2rem;
    font-size: 13px;
    text-decoration: none;
    transition: var(--transition);
    box-shadow: 0 2px 12px rgba(200,151,42,.4);
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    white-space: nowrap;
}
.btn-call:hover { transform: translateY(-1px); box-shadow: 0 4px 18px rgba(200,151,42,.5); }

/* ===== HERO STRIP ===== */
.hero-strip {
    background: var(--charcoal-mid);
    border-bottom: 1px solid var(--charcoal-soft);
    padding: .45rem 0;
    font-size: 12.5px;
    font-weight: 700;
    color: var(--gray-light);
    letter-spacing: .3px;
}
.hero-strip .sep { opacity: .4; }

/* ===== PAGE HEADER ===== */
.page-header {
    background: var(--charcoal-mid);
    border-bottom: 2px solid var(--charcoal-soft);
    padding: 2.2rem 0 1.8rem;
    color: var(--ivory);
    position: relative;
    overflow: hidden;
}
.page-header::before {
    content: '';
    position: absolute;
    top: -40px; left: -40px;
    width: 200px; height: 200px;
    background: radial-gradient(circle, rgba(200,151,42,.15) 0%, transparent 70%);
    border-radius: 50%;
}
.page-header h1 { font-size: 1.75rem; font-weight: 900; color: var(--ivory); text-shadow: 0 2px 8px rgba(0,0,0,.5); }
.page-header p { color: var(--cream); opacity: .78; font-size: 13.5px; }
.page-header .breadcrumb .breadcrumb-item,
.page-header .breadcrumb .breadcrumb-item a { color: rgba(245,237,224,.7); font-size: 12.5px; text-decoration: none; }
.page-header .breadcrumb .breadcrumb-item.active { color: var(--gold-light); }
.page-header .breadcrumb-item+.breadcrumb-item::before { color: rgba(245,237,224,.4); }

/* ===== STATS BAR ===== */
.stats-bar {
    background: var(--charcoal-mid);
    border-bottom: 1px solid var(--charcoal-soft);
    padding: .65rem 0;
}
.stat-item {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    padding: .3rem .9rem;
    font-size: 13px;
    font-weight: 600;
    border-left: 1px solid var(--border);
    color: var(--text-muted);
}
.stat-item:last-child { border: none; }
.stat-item .num { color: var(--blue-light); font-weight: 800; font-size: 15px; }
.stat-badge {
    background: var(--blue);
    color: var(--ivory);
    border-radius: 20px;
    padding: .25rem .9rem;
    font-weight: 700;
    font-size: 12.5px;
}

/* ===== FILTER CHIPS ===== */
.filter-chips-bar {
    background: var(--charcoal-mid);
    padding: .65rem 0;
    border-bottom: 1px solid var(--charcoal-soft);
    overflow-x: auto;
}
.filter-chip {
    display: inline-flex;
    align-items: center;
    gap: .3rem;
    background: var(--charcoal-light);
    border: 1.5px solid var(--charcoal-soft);
    border-radius: 20px;
    padding: .28rem .85rem;
    font-size: 12px;
    font-weight: 600;
    color: var(--gray-light);
    cursor: pointer;
    transition: var(--transition);
    white-space: nowrap;
    text-decoration: none;
    margin: 0 .2rem;
}
.filter-chip:hover, .filter-chip.active {
    background: var(--blue);
    border-color: var(--blue);
    color: var(--ivory);
}
.filter-chip .chip-remove {
    background: var(--brown-mid);
    color: white;
    border-radius: 50%;
    width: 15px; height: 15px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 9px;
}

/* ===== SORT BAR ===== */
.sort-bar {
    background: var(--charcoal-mid);
    padding: .6rem 0;
    border-bottom: 1px solid var(--charcoal-soft);
}
.sort-btn {
    background: var(--charcoal-light);
    border: 1.5px solid var(--charcoal-soft);
    border-radius: 20px;
    padding: .28rem .85rem;
    font-family: 'Cairo', sans-serif;
    font-size: 12.5px;
    font-weight: 600;
    color: var(--gray);
    cursor: pointer;
    transition: var(--transition);
    margin: 0 .15rem;
}
.sort-btn:hover, .sort-btn.active {
    background: var(--blue);
    border-color: var(--blue);
    color: var(--ivory);
}
.results-count { color: var(--gray); font-size: 12.5px; font-weight: 600; }
.results-count span { color: var(--blue-light); font-weight: 800; }

/* ===== FILTER SIDEBAR ===== */
.filter-sidebar {
    background: var(--charcoal-mid);
    border-radius: var(--radius);
    border: 1.5px solid var(--charcoal-soft);
    padding: 1.2rem;
    box-shadow: var(--shadow);
    position: sticky;
    top: 76px;
}
.sidebar-title {
    font-size: 15px;
    font-weight: 800;
    color: var(--ivory);
    padding-bottom: .8rem;
    border-bottom: 1px solid var(--charcoal-soft);
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: .4rem;
}
.sidebar-title i { color: var(--gold); }
.filter-group { margin-bottom: 1.1rem; }
.filter-group > label {
    font-size: 12.5px;
    font-weight: 700;
    color: var(--gray-light);
    display: block;
    margin-bottom: .35rem;
}
.filter-select,
.filter-input {
    width: 100%;
    border: 1.5px solid var(--charcoal-soft);
    border-radius: var(--radius-sm);
    padding: .42rem .8rem;
    font-family: 'Cairo', sans-serif;
    font-size: 12.5px;
    color: var(--ivory);
    background: var(--charcoal-light);
    transition: border-color .2s;
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%234a90b8' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M2 5l6 6 6-6'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: left .7rem center;
    background-size: 13px;
}
.filter-select:focus,
.filter-input:focus {
    outline: none;
    border-color: var(--blue);
    box-shadow: 0 0 0 3px var(--blue-glow);
}
.filter-select option { background: var(--charcoal-mid); color: var(--ivory); }
.filter-input { background-image: none; }
.year-range-inputs { display: flex; gap: .5rem; align-items: center; }
.year-range-inputs span { color: var(--text-muted); font-size: 12px; }

/* Range slider */
.price-range-wrap { padding: .3rem .2rem; }
.range-slider { width: 100%; accent-color: var(--gold); }
.range-values { display: flex; justify-content: space-between; font-size: 11.5px; color: var(--text-muted); font-weight: 600; margin-top: .3rem; }

.btn-filter-apply {
    background: var(--blue);
    color: var(--ivory);
    border: none;
    border-radius: var(--radius-sm);
    padding: .55rem;
    width: 100%;
    font-family: 'Cairo', sans-serif;
    font-weight: 700;
    font-size: 13.5px;
    cursor: pointer;
    transition: var(--transition);
    margin-top: .4rem;
}
.btn-filter-apply:hover { background: var(--blue-dark); transform: translateY(-1px); box-shadow: 0 4px 18px rgba(74,144,184,.35); }

.btn-filter-reset {
    background: transparent;
    color: var(--gray);
    border: 1.5px solid var(--charcoal-soft);
    border-radius: var(--radius-sm);
    padding: .45rem;
    width: 100%;
    font-family: 'Cairo', sans-serif;
    font-weight: 600;
    font-size: 12.5px;
    cursor: pointer;
    transition: var(--transition);
    margin-top: .4rem;
}
.btn-filter-reset:hover { border-color: var(--blue); color: var(--blue-light); }

/* ===== CARS GRID ROW ===== */
#carsGrid {
    align-items: flex-start !important;
}
/* Each column is an independent stacking context */
#carsGrid > [class*="col"] {
    isolation: isolate;
    z-index: 0;
    transition: z-index 0s .35s; /* reset z-index after hover transition ends */
}
#carsGrid > [class*="col"]:has(.car-card:hover) {
    z-index: 10;
    transition: z-index 0s 0s;
}

/* ===== CAR CARDS ===== */
.car-card {
    background: var(--charcoal-mid);
    border-radius: var(--radius);
    border: 1.5px solid var(--charcoal-soft);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
    cursor: pointer;
    isolation: isolate;
    position: relative;
    z-index: 1;
}
.car-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 16px 48px rgba(0,0,0,.45), 0 0 0 1px var(--blue);
    border-color: var(--blue);
    z-index: 2;
}

.card-img-wrap {
    position: relative;
    overflow: hidden;
    background: var(--charcoal-light);
    height: 185px;
    flex-shrink: 0;
}
.card-img-wrap img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.car-card:hover .card-img-wrap img { transform: scale(1.06); }

.card-source-badge {
    position: absolute;
    top: 9px; right: 9px;
    background: rgba(17,19,22,.85);
    color: var(--ivory-mid);
    font-size: 10px; font-weight: 700;
    padding: 3px 8px;
    border-radius: 20px;
    border: 1px solid var(--charcoal-soft);
    backdrop-filter: blur(6px);
}
.card-year-badge {
    position: absolute;
    bottom: 9px; left: 9px;
    background: rgba(17,19,22,.85);
    color: var(--blue-light);
    font-size: 11.5px; font-weight: 700;
    padding: 3px 10px;
    border-radius: 6px;
    backdrop-filter: blur(6px);
}
.card-status-badge {
    position: absolute;
    top: 9px; left: 9px;
    font-size: 10px; font-weight: 700;
    padding: 3px 8px;
    border-radius: 20px;
    color: white;
}
.card-fav-btn {
    position: absolute;
    bottom: 9px; right: 9px;
    background: rgba(255,255,255,.9);
    border: none;
    border-radius: 50%;
    width: 30px; height: 30px;
    display: flex; align-items: center; justify-content: center;
    font-size: 14px;
    color: var(--text-muted);
    cursor: pointer;
    transition: var(--transition);
    backdrop-filter: blur(4px);
}
.card-fav-btn:hover, .card-fav-btn.active { color: #e74c3c; background: var(--charcoal-mid); }

.card-body-custom { padding: .9rem 1rem .5rem; }
.car-title { font-size: 14.5px; font-weight: 800; color: var(--ivory); margin-bottom: .15rem; line-height: 1.3; }
.car-subtitle { font-size: 11.5px; color: var(--gray); margin-bottom: .6rem; }
.car-specs { display: flex; gap: .5rem; flex-wrap: wrap; }
.spec-tag {
    display: inline-flex;
    align-items: center;
    gap: .2rem;
    font-size: 11px;
    color: var(--gray-light);
    background: var(--charcoal-light);
    padding: 2px 7px;
    border-radius: 5px;
    border: 1px solid var(--charcoal-soft);
}
.spec-tag i { color: var(--blue); font-size: 10px; }

.card-footer-custom {
    padding: .65rem 1rem;
    border-top: 1px solid var(--charcoal-soft);
    background: var(--charcoal-light);
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.car-price { font-size: 16.5px; font-weight: 900; color: var(--blue-light); display: flex; align-items: baseline; gap: .2rem; }
.car-price .cur { font-size: 11.5px; font-weight: 600; color: var(--gray); }
.car-timer { display: flex; align-items: center; gap: .3rem; font-size: 11.5px; color: var(--text-muted); font-weight: 600; }
.car-timer i { color: #e74c3c; }

/* Sale type badge */
.sale-type-badge {
    position: absolute;
    top: 40px; right: 9px;
    font-size: 10px; font-weight: 700;
    padding: 3px 8px;
    border-radius: 20px;
    border: 1px solid;
}
.sale-type-badge.auction { background: rgba(74,144,184,.15); border-color: var(--blue); color: var(--blue-light); }
.sale-type-badge.direct { background: rgba(74,184,144,.12); border-color: #4ab890; color: #4ab890; }

/* Loading skeleton */
.skeleton { background: linear-gradient(90deg, var(--charcoal-mid) 25%, var(--charcoal-light) 37%, var(--charcoal-mid) 63%); background-size: 400% 100%; animation: skeleton-loading 1.4s ease infinite; }
@keyframes skeleton-loading { 0% { background-position: 100% 50%; } 100% { background-position: 0% 50%; } }
.skeleton-card { border-radius: var(--radius); border: 1.5px solid var(--charcoal-soft); overflow: hidden; }
.skeleton-img { height: 185px; }
.skeleton-line { height: 14px; border-radius: 7px; margin: .5rem .8rem; }
.skeleton-line.short { width: 60%; }
.skeleton-line.price { width: 40%; height: 18px; }

/* ===== CAR DETAIL PAGE ===== */
.detail-main-carousel .carousel-item img {
    height: 440px;
    object-fit: cover;
    border-radius: var(--radius);
}
.detail-thumb-strip { display: flex; gap: 6px; margin-top: 8px; overflow-x: auto; padding-bottom: 4px; }
.detail-thumb-strip img {
    width: 78px; height: 56px;
    object-fit: cover;
    border-radius: 8px;
    border: 2px solid transparent;
    cursor: pointer;
    transition: border-color .2s;
    flex-shrink: 0;
}
.detail-thumb-strip img.active,
.detail-thumb-strip img:hover { border-color: var(--gold); }

.detail-info-card {
    background: var(--charcoal-mid);
    border-radius: var(--radius);
    border: 1.5px solid var(--charcoal-soft);
    padding: 1.5rem;
    box-shadow: var(--shadow);
    position: sticky;
    top: 76px;
}
.detail-price { font-size: 2.2rem; font-weight: 900; color: var(--blue-light); line-height: 1.1; }
.detail-price .cur { font-size: 1rem; color: var(--gray); }

.detail-badge {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    background: var(--charcoal-light);
    border: 1.5px solid var(--charcoal-soft);
    border-radius: 8px;
    padding: .42rem .9rem;
    font-size: 12.5px;
    font-weight: 600;
    margin: .2rem;
    color: var(--ivory-mid);
}
.detail-badge i { color: var(--blue-light); }
.detail-badge strong { color: var(--ivory); }

.section-title {
    font-size: 1.1rem;
    font-weight: 800;
    color: var(--ivory);
    padding-bottom: .6rem;
    border-bottom: 1px solid var(--charcoal-soft);
    margin-bottom: 1.2rem;
    display: flex;
    align-items: center;
    gap: .5rem;
}
.section-title i { color: var(--blue); }

/* Damage map */
.damage-map-wrap { position: relative; display: inline-block; }
.damage-map-wrap img { max-width: 100%; border-radius: var(--radius-sm); }
.damage-point {
    position: absolute;
    width: 22px; height: 22px;
    border-radius: 50%;
    border: 2px solid white;
    display: flex; align-items: center; justify-content: center;
    font-size: 10px; font-weight: 700;
    color: white;
    cursor: pointer;
    transform: translate(-50%, -50%);
    transition: transform .2s;
    box-shadow: 0 2px 8px rgba(0,0,0,.3);
}
.damage-point:hover { transform: translate(-50%, -50%) scale(1.3); }
.damage-point.scratch { background: #e67e22; }
.damage-point.dent    { background: #e74c3c; }
.damage-point.paint   { background: #3498db; }

/* WhatsApp / action buttons */
.btn-whatsapp {
    background: linear-gradient(135deg, #25d366, #128C7E);
    color: white;
    border: none;
    border-radius: 30px;
    padding: .65rem 1.6rem;
    font-family: 'Cairo', sans-serif;
    font-weight: 700;
    font-size: 14px;
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: 0 4px 14px rgba(37,211,102,.35);
    text-decoration: none;
}
.btn-whatsapp:hover { transform: translateY(-2px); box-shadow: 0 8px 22px rgba(37,211,102,.4); color: white; }

.btn-gold {
    background: var(--blue);
    color: var(--ivory);
    border: none;
    border-radius: 30px;
    padding: .65rem 1.6rem;
    font-family: 'Cairo', sans-serif;
    font-weight: 700;
    font-size: 14px;
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    box-shadow: 0 4px 16px rgba(74,144,184,.3);
}
.btn-gold:hover { background: var(--blue-dark); color: var(--ivory); transform: translateY(-2px); box-shadow: 0 8px 24px rgba(74,144,184,.4); }

/* ===== ARTICLE CARD ===== */
.article-card {
    background: var(--charcoal-mid);
    border-radius: var(--radius);
    border: 1.5px solid var(--charcoal-soft);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
    height: 100%;
}
.article-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-hover); border-color: var(--blue); }
.article-card .card-img-wrap { height: 200px; }
.article-card .article-meta { font-size: 11.5px; color: var(--gray); font-weight: 600; }
.article-card .article-title { font-size: 15px; font-weight: 800; color: var(--ivory); line-height: 1.4; }
.article-card .article-brief { font-size: 13px; color: var(--gray); line-height: 1.6; }
.article-card .article-body { padding: 1.1rem; display: flex; flex-direction: column; gap: .5rem; }
.article-card .read-more { color: var(--blue-light); font-weight: 700; font-size: 13px; text-decoration: none; transition: color .2s; }
.article-card .read-more:hover { color: var(--blue); }

/* ===== SECTION DIVIDER ===== */
.sec-divider {
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--charcoal-soft), var(--gray-dark), var(--charcoal-soft), transparent);
    border-radius: 1px;
    margin: 1rem 0;
}

/* ===== PAGINATION ===== */
.pagination .page-link {
    font-family: 'Cairo', sans-serif;
    font-weight: 600;
    color: var(--ivory-mid);
    background: var(--charcoal-mid);
    border-color: var(--charcoal-soft);
    border-radius: var(--radius-sm) !important;
    margin: 0 2px;
    transition: var(--transition);
}
.pagination .page-link:hover,
.pagination .page-item.active .page-link { background: var(--blue); border-color: var(--blue); color: var(--ivory); }

/* ===== CONTACT FORM ===== */
.contact-form-card {
    background: var(--charcoal-mid);
    border-radius: var(--radius);
    border: 1.5px solid var(--charcoal-soft);
    padding: 2rem;
    box-shadow: var(--shadow);
}
.form-label-custom { font-size: 13px; font-weight: 700; color: var(--gray-light); margin-bottom: .35rem; }
.form-control-custom {
    border: 1.5px solid var(--charcoal-soft);
    border-radius: var(--radius-sm);
    padding: .55rem .9rem;
    font-family: 'Cairo', sans-serif;
    font-size: 13.5px;
    background: var(--charcoal-light);
    color: var(--ivory);
    transition: border-color .2s;
    width: 100%;
}
.form-control-custom:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px var(--blue-glow); }
.form-control-custom::placeholder { color: var(--gray-dark); }

.contact-info-card {
    background: var(--charcoal-mid);
    border-radius: var(--radius);
    padding: 2rem;
    color: var(--ivory);
    border: 1.5px solid var(--charcoal-soft);
    height: 100%;
}
.contact-info-title { color: var(--blue-light); font-weight: 800; font-size: 1.1rem; margin-bottom: 1.5rem; }
.contact-row { display: flex; align-items: flex-start; gap: 1rem; padding: .9rem 0; border-bottom: 1px solid rgba(200,151,42,.2); }
.contact-row:last-child { border: none; }
.contact-icon { background: var(--charcoal-light); border: 1.5px solid var(--charcoal-soft); border-radius: 10px; padding: .6rem; font-size: 18px; color: var(--blue-light); min-width: 44px; text-align: center; }
.contact-label { font-size: 11.5px; color: rgba(245,237,224,.6); font-weight: 600; }
.contact-value { font-size: 13.5px; color: var(--cream); font-weight: 700; }
.contact-value a { color: var(--cream); text-decoration: none; }
.contact-value a:hover { color: var(--gold-light); }

/* ===== ABOUT US ===== */
.about-stat-card {
    background: var(--charcoal-mid);
    border-radius: var(--radius);
    padding: 2rem 1.5rem;
    text-align: center;
    border: 1.5px solid var(--charcoal-soft);
    transition: var(--transition);
}
.about-stat-card:hover { border-color: var(--blue); transform: translateY(-3px); box-shadow: 0 8px 28px rgba(74,144,184,.2); }
.about-stat-num { font-size: 2.5rem; font-weight: 900; color: var(--blue-light); line-height: 1; }
.about-stat-label { font-size: 13px; color: var(--gray-light); margin-top: .4rem; }
.feature-icon {
    width: 56px; height: 56px;
    background: linear-gradient(135deg, rgba(200,151,42,.15), rgba(200,151,42,.05));
    border: 2px solid rgba(200,151,42,.25);
    border-radius: 14px;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.5rem; color: var(--gold);
    margin-bottom: 1rem;
    transition: var(--transition);
}
.feature-card:hover .feature-icon { background: var(--gold); color: var(--brown-dark); }
.feature-card { padding: 1.5rem; border-radius: var(--radius); border: 1.5px solid var(--border); background: var(--charcoal-mid); transition: var(--transition); }
.feature-card:hover { box-shadow: var(--shadow-hover); border-color: var(--gold); }

/* ===== TOAST ===== */
.app-toast {
    position: fixed;
    bottom: 1.5rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 9999;
    background: var(--charcoal-mid);
    color: var(--ivory);
    border: 1px solid var(--blue);
    border-radius: 30px;
    padding: .55rem 1.4rem;
    font-size: 13px;
    font-weight: 600;
    white-space: nowrap;
    animation: toastIn .3s ease;
    box-shadow: 0 4px 20px rgba(0,0,0,.4);
}
@keyframes toastIn { from { opacity:0; transform:translateX(-50%) translateY(16px); } to { opacity:1; transform:translateX(-50%) translateY(0); } }

/* ===== FOOTER ===== */
.site-footer {
    background: var(--charcoal-deep);
    color: var(--ivory-mid);
    padding: 2.8rem 0 1rem;
    border-top: 1px solid var(--charcoal-soft);
    margin-top: 3rem;
}
.footer-brand { color: var(--ivory); font-weight: 900; font-size: 1.15rem; }
.footer-text { font-size: 12.5px; color: var(--gray); line-height: 1.7; }
.footer-title { color: var(--blue-light); font-weight: 700; margin-bottom: .9rem; font-size: 14px; }
.footer-link { color: var(--gray); text-decoration: none; font-size: 12.5px; display: block; margin-bottom: 6px; transition: var(--transition); }
.footer-link:hover { color: var(--ivory); }
.footer-hr { border-color: var(--charcoal-soft); margin-top: 1.5rem; }
.footer-bottom { font-size: 12px; color: var(--gray); padding-top: .8rem; }
.social-icons a { color: var(--gray); font-size: 19px; margin: 0 7px; transition: var(--transition); display: inline-block; }
.social-icons a:hover { color: var(--blue-light); transform: translateY(-3px); }
.contact-items { display: flex; flex-direction: column; gap: .5rem; }
.contact-item { display: flex; align-items: center; gap: .7rem; font-size: 13px; }
.contact-item i { color: var(--blue); font-size: 15px; width: 18px; text-align: center; }
.contact-item a { color: var(--cream); text-decoration: none; opacity: .85; transition: color .2s; }
.contact-item a:hover { color: var(--gold-light); opacity: 1; }

/* ===== WHATSAPP FLOAT ===== */
.whatsapp-float {
    position: fixed;
    bottom: 24px; left: 24px;
    background: #25d366;
    color: white;
    border-radius: 50%;
    width: 54px; height: 54px;
    display: flex; align-items: center; justify-content: center;
    font-size: 24px;
    box-shadow: 0 4px 20px rgba(37,211,102,.4);
    cursor: pointer;
    z-index: 900;
    text-decoration: none;
    transition: var(--transition);
    animation: waPulse 2s infinite;
}
.whatsapp-float:hover { transform: scale(1.1); color: white; }
@keyframes waPulse { 0%,100% { box-shadow:0 4px 20px rgba(37,211,102,.4); } 50% { box-shadow:0 4px 32px rgba(37,211,102,.7); } }

/* ===== SCROLL TOP ===== */
.scroll-top-btn {
    position: fixed;
    bottom: 90px; left: 24px;
    background: var(--charcoal-mid);
    color: var(--blue-light);
    border: 1.5px solid var(--blue);
    border-radius: 50%;
    width: 42px; height: 42px;
    display: flex; align-items: center; justify-content: center;
    font-size: 16px;
    cursor: pointer;
    z-index: 900;
    transition: var(--transition);
    opacity: 0;
    pointer-events: none;
}
.scroll-top-btn.visible { opacity: 1; pointer-events: all; }
.scroll-top-btn:hover { background: var(--blue); color: var(--ivory); transform: translateY(-2px); }

/* ===== RESPONSIVE ===== */
@media (max-width: 991px) {
    .filter-sidebar { position: static; margin-bottom: 1.2rem; top: auto; }
    .detail-info-card { position: static; }
}
@media (max-width: 767px) {
    .page-header h1 { font-size: 1.3rem; }
    .car-card .card-img-wrap { height: 165px; }
    .detail-main-carousel .carousel-item img { height: 260px; }
    .detail-price { font-size: 1.6rem; }
    .stat-item { padding: .25rem .5rem; font-size: 12px; }
    .whatsapp-float { bottom: 16px; left: 16px; width: 48px; height: 48px; font-size: 21px; }
}
@media (max-width: 575px) {
    .navbar-collapse { background: var(--brown-dark); padding: .5rem 0; }
    .navbar-custom .nav-link { padding: .65rem 1rem !important; }
    .sort-btn { padding: .22rem .65rem; font-size: 11.5px; }
}
