/* =============================================================================
   HOMEPAGE — Hugo Cars
   Covers: hero, cars-of-week, welcome/about, about-images,
           finance/warranty splits, reviews carousel, bottom CTA
   ============================================================================= */

/* ─── CSS Custom Properties (override in theme) ──────────────────────────── */
:root {
    --ac-primary:   #fff;
    --ac-accent:    #D2091A;        /* Hugo red */
    --ac-site-bg:   #f0ece6;        /* off-white/sand background */
    --ac-muted:     #888;
    --ac-dark:      #111;
    --ac-radius:    8px;
}


/* =============================================================================
   HERO
   ============================================================================= */
.ac-hero {
    position: relative;
    height: 100vh;
    min-height: 560px;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    /* Must stay visible (not hidden) — the Makes/Models/etc. search dropdowns
       are positioned absolutely and extend below the hero's own box; clipping
       overflow here hides those panels even though the JS opens them correctly. */
    overflow: visible;
}

.ac-hero-bg {
    position: absolute;
    inset: 0;
    z-index: 0;
}

.ac-hero-bg video,
.ac-hero-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.ac-hero-overlay {
    position: absolute;
    inset: 0;
    z-index: 1;
    background: linear-gradient(
        to bottom,
        rgba(0,0,0,.45) 0%,
        rgba(0,0,0,.15) 55%,
        rgba(0,0,0,.55) 100%
    );
}

/* Search bar template-part sits inside hero and is positioned by the
   content-hero-search.php partial — it should have position:relative; z-index:2 */


/* =============================================================================
   CARS OF THE WEEK
   ============================================================================= */
.ac-cars-week {
    background: var(--ac-site-bg);
    padding: 64px 0 80px;
}

.ac-cars-week-header {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    margin-bottom: 36px;
    gap: 20px;
}

.ac-cars-week-header h2 {
    font-size: clamp(1.8rem, 2.8vw, 2.6rem);
    font-weight: 700;
    color: var(--ac-dark);
    letter-spacing: -.01em;
}

.ac-cars-week-showmore {
    font-size: .75rem;
    font-weight: 700;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: #333;
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
    transition: color .2s;
}

.ac-cars-week-showmore:hover { color: var(--ac-accent); }

.ac-cars-week-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}

.ac-cars-empty {
    text-align: center;
    padding: 60px 20px;
    color: var(--ac-muted);
    font-size: 1rem;
}

@media (max-width: 1100px) {
    .ac-cars-week-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 580px) {
    .ac-cars-week-grid { grid-template-columns: 1fr; }
}


/* =============================================================================
   WELCOME / ABOUT
   ============================================================================= */
.ac-welcome-section {
    background: #fff;
    padding: 50px 0 30px;
}

/* Full-width centred title above the two-column grid */
.ac-welcome-title {
    font-size: clamp(2rem, 4.5vw, 3.4rem);
    font-weight: 700;
    color: var(--ac-dark);
    text-align: center;
    margin-bottom: 56px;
    line-height: 1.15;
    letter-spacing: -.02em;
}

/* Accent colour on <span> inside the title */
.ac-welcome-title span { color: var(--ac-accent); }

/* Two-column layout: narrow left (label+arrows) | wide right (text) */
.ac-welcome-grid {
    display: grid;
    grid-template-columns: 140px 1fr;
    gap: 64px;
    align-items: start;
}

.ac-welcome-left {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 350px;
}

.ac-welcome-label-block {
    display: flex;
    flex-direction: column;
}

.ac-welcome-divider {
    width: 36px;
    height: 1.5px;
    background: var(--ac-dark);
    margin-bottom: 12px;
}

.ac-welcome-contact-link {
    font-size: .7rem;
    font-weight: 700;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: #333;
    transition: color .2s;
}
.ac-welcome-contact-link:hover { color: var(--ac-accent); }

.ac-welcome-arrows {
    display: flex;
    gap: 8px;
    margin-top: 40px;
}

.ac-welcome-arrow {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1.5px solid #333;
    background: transparent;
    cursor: pointer;
    color: #333;
    font-size: 1rem;
    transition: background .2s, color .2s, border-color .2s;
}
.ac-welcome-arrow:hover {
    background: var(--ac-dark);
    color: #fff;
    border-color: var(--ac-dark);
}

/* Right column body text */
.ac-welcome-text p {
    color: black;
    line-height: 1.8;
    margin-bottom: 5px;
    font-size: 1.3rem;
}

.ac-welcome-list {
    list-style: none;
    margin-top: 12px;
    display: flex;
    flex-direction: column;
    gap: 7px;
    padding: 0;
}

.ac-welcome-list li {
    display: flex;
    gap: 10px;
    font-size: .9rem;
    color: #444;
    line-height: 1.5;
}

.ac-welcome-list li::before {
    content: '–';
    color: #999;
    flex-shrink: 0;
}

@media (max-width: 860px) {
    .ac-welcome-grid {
        grid-template-columns: 1fr;
        gap: 28px;
    }
    .ac-welcome-left {
        flex-direction: row;
        min-height: auto;
        gap: 32px;
        align-items: center;
    }
    .ac-welcome-arrows { margin-top: 0; }
}


/* =============================================================================
   ABOUT IMAGES — full-bleed duo strip
   ============================================================================= */
.ac-about-images-section {
    line-height: 0;
    overflow: hidden;
}

.ac-about-images-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    height: 500px;
}

.ac-about-images-single {
    grid-template-columns: 1fr !important;
}

.ac-about-img-item {
    overflow: hidden;
    position: relative;
}

.ac-about-img-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform .6s ease;
}

.ac-about-img-item:hover img { transform: scale(1.03); }

@media (max-width: 768px) {
    .ac-about-images-grid {
        grid-template-columns: 1fr;
        height: auto;
    }
    .ac-about-img-item { height: 280px; }
}


/* =============================================================================
   SPLIT SECTIONS — Finance (text-left / image-right) &
                    Warranty  (image-left / text-right)
   ============================================================================= */
.ac-split-section {
    background: #fff;
    overflow: hidden;
    border-top: 1px solid #f0f0f0;
}

.ac-split-inner {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: start;
}
/* Warranty: reverse column order so image is on the left */
.ac-split-inner--reverse { direction: rtl; }
.ac-split-inner--reverse > * { direction: ltr; }

/* No image → single column, text centred */
.ac-split-full {
    grid-template-columns: 1fr !important;
    direction: ltr !important;
}
.ac-split-full .ac-split-text {
    max-width: 760px;
    margin: 0 auto;
}

.ac-split-text {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    padding: 72px 8%;
    gap: 0;
    will-change: transform;
}

.ac-split-text h2 {
    font-size: clamp(1.8rem, 3.5vw, 6rem);
    font-weight: 500;
    color: var(--ac-dark);
    margin-bottom: 20px;
    line-height: 1.15;
    letter-spacing: -.01em;
}

.ac-split-text p {
    color: black;
    line-height: 1.8;
    margin-bottom: 14px;
    font-size: .95rem;
}

.ac-split-image {
    overflow: hidden;
    position: relative;
}

.ac-split-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Dark pill button (used in split sections) */
.ac-btn-dark-pill {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-top: 28px;
    padding: 14px 28px;
    background: var(--ac-dark);
    color: #fff;
    font-size: .9rem;
    font-weight: 500;
    letter-spacing: .12em;
    text-transform: uppercase;
    border-radius: 999px;
    transition: background .2s, transform .15s;
    align-self: flex-start;
    white-space: nowrap;
}
.ac-btn-dark-pill:hover {
    background: #333;
    transform: translateY(-1px);
}
.ac-btn-dark-pill svg { flex-shrink: 0; }

@media (max-width: 900px) {
    .ac-split-inner {
        grid-template-columns: 1fr;
        direction: ltr;
    }
    .ac-split-text {         
        position: static;
        max-height: none;
        padding: 52px 7%; }
    .ac-split-image { min-height: 320px; }
}


/* =============================================================================
   REVIEWS — Swiper carousel
   ============================================================================= */
.ac-reviews-section {
    background: var(--ac-site-bg);
    padding: 72px 0 88px;
}

.ac-reviews-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 48px;
    flex-wrap: wrap;
    gap: 16px;
}

.ac-reviews-label-block {
    display: flex;
    flex-direction: column;
}

.ac-reviews-divider {
    width: 36px;
    height: 1.5px;
    background: var(--ac-dark);
    margin-bottom: 10px;
}

.ac-reviews-label {
    font-size: .7rem;
    font-weight: 700;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: #333;
}

.ac-reviews-tagline {
    font-size: clamp(1rem, 1.8vw, 1.3rem);
    font-weight: 700;
    color: var(--ac-dark);
    align-self: flex-end;
    text-align: right;
    max-width: 320px;
}

/* Review cards */
.ac-review-card {
    background: #fff;
    padding: 40px 28px 36px;
    text-align: center;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.ac-review-avatar {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    overflow: hidden;
    margin: 0 auto 4px;
    flex-shrink: 0;
}

.ac-review-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.ac-review-avatar-placeholder {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    font-weight: 700;
    color: #fff;
    background: #c0392b;
}

.ac-review-author strong {
    display: block;
    font-size: .95rem;
    font-weight: 700;
    color: var(--ac-dark);
    margin-top: 12px;
}

.ac-review-date {
    font-size: .76rem;
    color: #bbb;
    display: block;
    margin-top: 2px;
}

.ac-review-stars {
    display: flex;
    gap: 2px;
    justify-content: center;
    margin: 14px 0 12px;
    font-size: 1.15rem;
}

.ac-review-text {
    font-size: .88rem;
    color: #555;
    line-height: 1.7;
    margin: 0;
}

/* Swiper pagination dots */
.ac-reviews-swiper { padding-bottom: 44px !important; }
.ac-reviews-swiper .swiper-pagination { bottom: 0; }
.ac-reviews-swiper .swiper-pagination-bullet {
    width: 10px;
    height: 10px;
    background: #333;
    opacity: .2;
    transition: opacity .2s;
}
.ac-reviews-swiper .swiper-pagination-bullet-active {
    opacity: 1;
    background: var(--ac-accent);
}


/* =============================================================================
   BOTTOM CTA STRIP
   ============================================================================= */
.ac-cta-strip {
    background: var(--ac-accent);
    padding: 60px 0;
}

.ac-cta-strip .ac-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 28px;
    flex-wrap: wrap;
}

.ac-cta-content h2 {
    font-size: clamp(1.4rem, 2.5vw, 2.1rem);
    color: #fff;
    font-weight: 700;
    letter-spacing: -.01em;
}

.ac-cta-content p {
    color: rgba(255,255,255,.75);
    margin-top: 8px;
    font-size: .95rem;
}

/* Outline white button variant */
.ac-btn-outline-white {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 15px 34px;
    border: 2px solid #fff;
    color: #fff;
    font-size: .8rem;
    font-weight: 700;
    letter-spacing: .12em;
    text-transform: uppercase;
    border-radius: 4px;
    transition: background .2s, color .2s;
    white-space: nowrap;
    flex-shrink: 0;
}
.ac-btn-outline-white:hover {
    background: #fff;
    color: var(--ac-accent);
}

.ac-btn--lg { padding: 17px 40px; font-size: .82rem; }

@media (max-width: 680px) {
    .ac-cta-strip .ac-container {
        flex-direction: column;
        text-align: center;
        align-items: center;
    }
}


/* =============================================================================
   SHARED UTILITIES
   ============================================================================= */

/* Container — matches theme's .ac-container width */
.ac-container {
    width: 100%;
    max-width: 1480px;
    margin: 0 auto;
    padding: 0 24px;
}

@media (max-width: 768px) {
    .ac-container { padding: 0 16px; }
}