/* ─────────────────────────────────────────────
   styles/spotlight.css  –  hero carousel
───────────────────────────────────────────── */

/* ── WRAPPER ── */
.spotlight-wrapper {
    display: flex;
    justify-content: center;
    padding: 52px 32px 0;
}

/* ── CONTAINER ──
   Sweet-spot: wide enough to feel premium,
   never so wide it loses intimacy.
   On desktop: side-by-side (image | details)
   On mobile: stacked portrait card           */
.spotlight-container {
    position: relative;
    width: 100%;
    max-width: 860px;
    /* wider but contained */
    border-radius: 28px;
    overflow: hidden;
    box-shadow:
        0 40px 100px -16px rgba(0, 0, 0, 0.6),
        0 0 0 1px var(--glass-border);
    background: var(--card-bg);
    backdrop-filter: blur(20px);

    /* side-by-side on desktop */
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 1fr auto;
    grid-template-areas:
        "stage  details"
        "dots   dots";
}

/* ── STAGE (image side) ── */
.product-stage {
    grid-area: stage;
    position: relative;
    width: 100%;
    min-height: 420px;
    /* floor height so it never collapses */
    overflow: hidden;
    background: var(--surface);
}

.slide-container {
    position: relative;
    width: 100%;
    height: 100%;
}

/* ── SLIDES ── */
.product-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.65s cubic-bezier(0.4, 0, 0.2, 1);
}

.product-slide.active {
    opacity: 1;
    visibility: visible;
    z-index: 10;
}

/* ── IMAGE ── */
.product-image {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    transform: scale(1.04);
    transition: transform 6s ease;
}

.product-slide.active .product-image {
    transform: scale(1);
}

/* very subtle vignette only — details live beside image on desktop */
.product-image::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg,
            rgba(10, 8, 20, 0.12) 0%,
            transparent 60%);
}

/* ── DETAILS (right column on desktop) ── */
.product-details-panel {
    grid-area: details;
    position: relative;
    display: flex;
    align-items: flex-end;
    /* content anchored to bottom */
    padding: 0;
    overflow: hidden;
}

/* each detail block is absolutely stacked, matching slides */
.product-details {
    position: absolute;
    inset: 0;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.65s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 2.25rem 2rem 2.25rem;
    gap: 0.6rem;
    background: var(--card-bg);
}

.product-details.active {
    opacity: 1;
    visibility: visible;
    z-index: 10;
}

/* ── BADGE ── */
.product-badge {
    position: absolute;
    top: 18px;
    left: 18px;
    z-index: 15;
    background: var(--accent);
    color: #0d0d1a;
    font-size: 0.63rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    padding: 4px 10px;
    border-radius: 20px;
}

/* ── TEXT ── */
.product-category {
    font-size: 0.66rem;
    text-transform: uppercase;
    letter-spacing: 2.5px;
    color: var(--accent);
    font-weight: 600;
}

.product-title {
    font-family: 'Cormorant Garamond', serif;
    font-size: clamp(1.6rem, 2.5vw, 2.2rem);
    font-weight: 600;
    color: var(--text);
    line-height: 1.12;
}

.product-description {
    font-size: 0.82rem;
    color: var(--text-muted);
    line-height: 1.6;
}

/* divider */
.details-divider {
    width: 32px;
    height: 1px;
    background: var(--accent);
    opacity: 0.4;
    margin: 0.25rem 0;
}

/* ── PROGRESS BAR ── */
.progress-bar {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 2px;
    background: var(--accent);
    width: 100%;
    transform-origin: left;
    z-index: 20;
}

@keyframes shrink {
    from {
        transform: scaleX(1);
    }

    to {
        transform: scaleX(0);
    }
}

/* ── DOTS (spans full width) ── */
.navigation-dots {
    grid-area: dots;
    display: flex;
    justify-content: center;
    gap: 6px;
    padding: 13px 16px;
    background: var(--card-bg);
    border-top: 1px solid var(--border);
}

.dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--border);
    cursor: pointer;
    transition: all 0.3s ease;
}

.dot.active {
    background: var(--accent);
    width: 22px;
    border-radius: 4px;
}

/* ── HOVER CONTROLS ── */
.hover-controls {
    position: absolute;
    bottom: 52px;
    left: 25%;
    /* centred over image half */
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.62);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 6px 14px;
    border-radius: 2rem;
    display: flex;
    gap: 6px;
    z-index: 30;
    opacity: 0;
    transition: opacity 0.25s;
    pointer-events: none;
}

.spotlight-container:hover .hover-controls {
    opacity: 1;
    pointer-events: auto;
}

.control-btn {
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.85);
    font-size: 0.9rem;
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 6px;
    transition: background 0.2s, transform 0.2s;
}

.control-btn:hover {
    background: rgba(255, 255, 255, 0.14);
    transform: scale(1.12);
}

/* ════════════════════════════════════════════
   RESPONSIVE BREAKPOINTS
════════════════════════════════════════════ */

/* ── Tablet: narrower side-by-side ── */
@media (max-width: 768px) {
    .spotlight-wrapper {
        padding: 32px 20px 0;
    }

    .spotlight-container {
        max-width: 100%;
        grid-template-columns: 1fr 1fr;
        /* keep side-by-side */
        border-radius: 22px;
    }

    .product-stage {
        min-height: 340px;
    }

    .product-details {
        padding: 1.5rem 1.4rem 1.75rem;
        gap: 0.45rem;
    }

    .product-title {
        font-size: 1.4rem;
    }

    .hover-controls {
        left: 25%;
        bottom: 48px;
    }
}

/* ── Mobile: stacked portrait card ── */
@media (max-width: 540px) {
    .spotlight-wrapper {
        padding: 20px 14px 0;
    }

    .spotlight-container {
        grid-template-columns: 1fr;
        grid-template-rows: auto auto auto;
        grid-template-areas:
            "stage"
            "details"
            "dots";
        border-radius: 18px;
        max-width: 100%;
    }

    .product-stage {
        min-height: 0;
        aspect-ratio: 4 / 3;
        /* landscape-ish crop on small screens */
    }

    /* on mobile, overlay gradient for legibility */
    .product-image::after {
        background: linear-gradient(to bottom,
                transparent 30%,
                rgba(10, 8, 20, 0.55) 100%);
    }

    .product-details-panel {
        position: static;
        height: auto;
    }

    .product-details {
        position: static;
        opacity: 1 !important;
        visibility: visible !important;
        display: none;
        /* JS toggles active one */
        padding: 1.35rem 1.25rem 1.5rem;
        gap: 0.4rem;
        background: var(--card-bg);
    }

    .product-details.active {
        display: flex;
    }

    .product-title {
        font-size: 1.35rem;
    }

    .product-description {
        font-size: 0.78rem;
        display: -webkit-box;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }

    .hover-controls {
        left: 50%;
        bottom: auto;
        top: calc(
                /* stage height */
                75% - 28px);
    }
}

/* ── Very small phones ── */
@media (max-width: 360px) {
    .spotlight-wrapper {
        padding: 16px 10px 0;
    }

    .product-details {
        padding: 1.1rem 1rem 1.25rem;
    }

    .product-title {
        font-size: 1.2rem;
    }
}