/**
 * on_demand.css - Cinematic styles for On Demand
 */

:root {
    --panel: #f2d34c;
    --bg-dark: #0d0d0f;
    --bg-card: #15151b;
    --border: rgba(255, 255, 255, 0.08);
    --muted: #b9b9bd;
}

.on-demand-wrap {
    background-color: var(--bg-dark);
    color: #fff;
    min-height: 100vh;
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
}

/* =========================================
   HERO CARRUSEL V2
   ========================================= */
.od-hero {
    background: #000;
    height: 480px !important;
    overflow: hidden;
    position: relative;
}

.od-ambient-bg {
    position: absolute;
    inset: -20px;
    background-size: cover;
    background-position: center;
    filter: blur(60px) brightness(0.3);
    z-index: 1;
    transition: background-image 0.8s ease;
    opacity: 0.8;
}

.od-hero .carrusel-od {
    position: relative;
    z-index: 2;
    width: 100%;
    height: 100%;
    display: grid;
    grid-template-columns: 0.8fr 2.2fr 0.8fr;
    align-items: center;
    gap: 40px;
    padding: 0 40px 0 120px;
}

.od-v2-info {
    z-index: 10;
    text-align: left;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.6s ease;
    width: min(100%, 280px);
    min-width: 0;
}

.od-v2-info.active {
    opacity: 1;
    transform: translateY(0);
}

.od-v2-info .kicker {
    display: block;
    color: var(--panel);
    font-weight: 900;
    letter-spacing: 3px;
    font-size: 0.75rem;
    margin-bottom: 8px;
    text-transform: uppercase;
}

.od-v2-info h1 {
    max-width: 260px;
    font-size: clamp(1.75rem, 2.35vw, 2.45rem);
    font-weight: 900;
    margin: 0;
    line-height: 1.05;
    color: #fff;
    text-transform: uppercase;
    overflow-wrap: anywhere;
    word-break: normal;
}

.od-v2-info p {
    color: rgba(255,255,255,0.7);
    font-size: 0.95rem;
    margin: 20px 0;
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    max-width: 260px;
}

.btn-hero-action {
    background: var(--panel);
    color: #000;
    border: none;
    padding: 14px 34px;
    border-radius: 60px;
    font-weight: 950;
    font-size: 1rem;
    cursor: pointer;
    text-transform: uppercase;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    box-shadow: 0 15px 35px rgba(242, 211, 76, 0.3);
    display: inline-block;
}

.btn-hero-action:hover {
    background: #fff;
    transform: translateY(-5px) scale(1.05);
    box-shadow: 0 20px 45px rgba(255, 255, 255, 0.4);
}

.od-v2-center {
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    width: 100%;
}

.od-v2-card {
    width: 100%;
    height: 400px;
    border-radius: 15px;
    box-shadow: 0 20px 50px rgba(0,0,0,0.8);
    position: relative;
    z-index: 5;
    transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    overflow: hidden;
    background-color: #000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.od-v2-card::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: var(--card-bg);
    background-size: cover;
    background-position: center;
    filter: blur(50px) brightness(0.4);
    opacity: 0.9;
    z-index: 1;
}

.od-v2-card-img {
    position: relative;
    z-index: 2;
    width: 100%;
    height: 100%;
    background-image: var(--card-bg);
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    transform: scale(1);
    transition: transform 0.6s ease;
}

.neon-border {
    position: absolute;
    inset: -2px;
    background: linear-gradient(45deg, var(--panel), transparent, var(--panel));
    border-radius: 17px;
    z-index: 4;
    opacity: 0.3;
    filter: blur(8px);
}

.od-v2-stack {
    display: flex;
    flex-direction: column;
    gap: 12px;
    perspective: 1000px;
    padding-left: 20px;
}

.stack-preview {
    width: 150px;
    height: 85px;
    background-size: cover;
    background-position: center;
    border-radius: 8px;
    border: 2px solid rgba(255,255,255,0.1);
    opacity: 0.5;
    transform: rotateY(-15deg);
    transition: all 0.4s ease;
    cursor: pointer;
}

.stack-preview:hover {
    opacity: 1;
    transform: rotateY(0deg) scale(1.05);
    border-color: var(--panel);
}

.od-hero .carrusel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 100;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.6) !important;
    border: 1px solid rgba(255, 255, 255, 0.2) !important;
    color: #fff !important;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 1.2rem;
}

.od-hero .carrusel-btn:hover {
    background: var(--panel) !important;
    color: #000 !important;
    border-color: var(--panel) !important;
}

.od-hero .carrusel-btn.anterior { left: 25px; }
.od-hero .carrusel-btn.siguiente { right: 25px; }

/* =========================================
   SECCIONES DE CONTENIDO
   ========================================= */
.on-demand-section {
    padding: 54px 0 24px;
    width: min(1500px, 96%);
    max-width: 1500px;
    margin: 0 auto;
}

.section-title-modern {
    font-size: 1.25rem;
    font-weight: 900;
    color: #fff;
    margin-bottom: 20px;
    text-transform: uppercase;
    display: flex;
    align-items: center;
    gap: 14px;
    letter-spacing: 0.5px;
}

.section-title-modern::before {
    content: "";
    width: 42px;
    height: 4px;
    background: var(--panel);
}

/* CAROUSEL / SLIDER */
.carousel-container {
    position: relative;
    width: 100%;
    margin-bottom: 32px;
    padding: 0 36px;
    display: flex;
    align-items: center;
}

.carousel {
    display: flex;
    gap: 24px;
    overflow-x: auto;
    padding: 20px 5px 34px;
    scroll-behavior: smooth;
    scrollbar-width: none;
    flex: 1;
}

.carousel::-webkit-scrollbar { display: none; }

.item {
    flex: 0 0 220px;
    width: 220px;
    height: 320px;
    border-radius: 12px;
    overflow: hidden;
    background: #111;
    border: 1px solid #222;
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
    position: relative;
    box-shadow: none;
}

.item:hover {
    transform: scale(1.05);
    border-color: var(--panel);
    box-shadow: 0 10px 30px rgba(0,0,0,0.8);
    z-index: 10;
}

.item a {
    text-decoration: none;
    color: inherit;
    display: block;
    width: 100%;
    height: 100%;
}

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

.item-overlay {
    padding: 20px 15px;
    background: linear-gradient(to top, rgba(0,0,0,0.95), transparent);
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    opacity: 0.9;
}

.item-overlay p {
    margin: 0;
    font-size: 0.95rem;
    font-weight: 700;
    line-height: 1.25;
    color: #fff;
    text-align: center;
    text-transform: uppercase;
}

/* NAVEGACIÓN SECCIONES */
.nav-btn {
    position: absolute;
    top: calc(50% - 15px);
    z-index: 20;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: rgba(13, 13, 15, 0.98);
    border: none;
    color: var(--panel);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 2rem;
    transition: opacity 0.3s, background 0.3s, transform 0.3s;
    box-shadow: none;
}

.nav-btn:hover {
    background: var(--panel);
    color: #000;
    transform: scale(1.05);
}

.left-btn { left: 0; }
.right-btn { right: 0; }

@media (max-width: 1650px) {
    .on-demand-section { width: min(1420px, 96%); }
    .carousel-container { padding: 0 18px; }
    .left-btn { left: -10px; }
    .right-btn { right: -10px; }
    .nav-btn { width: 44px; height: 44px; background: rgba(242, 211, 76, 0.95); color: #000; }
}

/* =========================================
   RESPONSIVO
   ========================================= */
@media (max-width: 1200px) {
    .od-hero .carrusel-od {
        padding-left: 100px;
        gap: 20px;
    }
}

@media (max-width: 1024px) {
    .od-hero .carrusel-od {
        grid-template-columns: 1.2fr 1.8fr;
        padding-left: 80px;
        padding-right: 40px;
    }
    .od-v2-stack { display: none; }
    .od-v2-info h1 { font-size: 2.2rem; }
}

@media (max-width: 768px) {
    .od-hero { height: auto !important; min-height: 600px; }
    .od-hero .carrusel-od {
        grid-template-columns: 1fr;
        grid-template-rows: auto auto;
        padding: 52px 16px 36px;
        gap: 24px;
    }
    .od-v2-info { text-align: center; order: 2; min-width: auto; }
    .od-v2-info h1 { font-size: 1.8rem; }
    .od-v2-info p { display: none; }
    .od-v2-center { order: 1; width: 100%; }
    .od-v2-card {
        width: min(100%, 460px);
        height: clamp(300px, 78vw, 390px);
    }
    .od-hero .carrusel-btn { top: 32%; width: 45px; height: 45px; font-size: 1.1rem; }
    .od-hero .carrusel-btn.anterior { left: 10px; }
    .od-hero .carrusel-btn.siguiente { right: 10px; }
    
    .on-demand-section {
        width: min(100%, 94%);
        padding: 40px 0 10px;
    }
    .carousel-container { padding: 0 12px; }
    .carousel { gap: 18px; padding-bottom: 28px; }
    .item {
        flex: 0 0 190px;
        width: 190px;
        height: 276px;
    }
    .nav-btn { width: 42px; height: 42px; font-size: 18px; }
}

@media (max-width: 640px) {
    .od-hero .carrusel-od {
        padding: 44px 18px 34px;
        align-content: center;
    }

    .od-v2-info {
        width: min(100%, 340px);
        max-width: 340px;
        margin: -4px auto 0;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
    }

    .od-v2-info h1 {
        max-width: 320px;
        text-align: center;
        line-height: 1.08;
    }

    .btn-hero-action {
        align-self: center;
        margin-top: 2px;
    }
}
