/**
 * Estilos Luminosos y Animados para Mandy3D (Light UI)
 * Enfoque: Fondos claros, elementos flotantes, colores vibrantes y Bento Grid.
 */

:root {
    --brand-orange: #FF5722;
    --brand-orange-hover: #E64A19;
    --brand-accent: #8A2BE2;      /* Morado vibrante para degradados */
    --bg-page: transparent;       /* Permite que se mezcle con Astra */
    --surface-light: #FFFFFF;     /* Tarjetas blancas puras */
    --surface-gray: #F8FAFC;      /* Fondos de sección sutiles */
    --text-main: #1E293B;         /* Texto principal oscuro */
    --text-muted: #64748B;
    --shadow-soft: 0 10px 40px rgba(0, 0, 0, 0.06);
    --shadow-hover: 0 20px 50px rgba(255, 87, 34, 0.15);
}

* { box-sizing: border-box; }

/* Contenedor principal mezclado con el tema padre */
.mandy3d-home-main {
    background-color: var(--bg-page) !important;
    color: var(--text-main);
    width: 100%;
    overflow-x: hidden;
}

/* --- Texto con Degradado Animado --- */
.animated-gradient-text {
    background: linear-gradient(270deg, var(--brand-orange), var(--brand-accent), var(--brand-orange));
    background-size: 200% 200%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: gradientShift 5s ease infinite;
    display: inline-block;
}

@keyframes gradientShift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* --- Mosaico de Banners (Bento Grid) --- */
.mandy3d-promo-banners {
    padding: 130px 20px 40px 20px; /* Ajuste para el header fijo */
    max-width: 1400px;
    margin: 0 auto;
}

.promo-bento {
    display: grid;
    grid-template-columns: 2fr 1fr; /* El banner geek ocupa el doble */
    grid-template-rows: 1fr 1fr;
    gap: 20px;
    height: 60vh;
    min-height: 400px;
    max-height: 600px;
}

.bento-item {
    position: relative;
    border-radius: 24px;
    overflow: hidden;
    background-color: #1E293B; /* Color de respaldo si la imagen falla */
    background-size: cover;
    background-position: center;
    text-decoration: none;
    display: flex;
    align-items: flex-end; /* Texto abajo */
    padding: 30px;
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.bento-main { grid-column: 1 / 2; grid-row: 1 / 3; }
.bento-sub1 { grid-column: 2 / 3; grid-row: 1 / 2; }
.bento-sub2 { grid-column: 2 / 3; grid-row: 2 / 3; }

.bento-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0,0,0,0.1);
}

.bento-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.2) 50%, rgba(0,0,0,0) 100%);
    z-index: 1;
    transition: opacity 0.3s ease;
}

.bento-item:hover .bento-overlay {
    background: linear-gradient(to top, rgba(0,0,0,0.9) 0%, rgba(255, 87, 34, 0.4) 100%);
}

.bento-content {
    position: relative;
    z-index: 2;
    color: #fff;
    width: 100%;
    transform: translateY(10px);
    transition: transform 0.3s ease;
}

.bento-item:hover .bento-content {
    transform: translateY(0);
}

.bento-tag {
    display: inline-block;
    background: var(--brand-orange);
    color: #fff;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 800;
    text-transform: uppercase;
    margin-bottom: 15px;
}

.bento-main h2 { font-size: 2.2rem; margin: 0; color: #fff; font-weight: 800; }
.bento-sub1 h3, .bento-sub2 h3 { font-size: 1.4rem; margin: 0; color: #fff; font-weight: 700; }

/* --- Intro Compacta Horizontal --- */
.mandy3d-compact-intro {
    max-width: 1200px;
    /* CORRECCIÓN PRINCIPAL: Margen superior en 0, margen inferior 40px. Ya no se monta encima. */
    margin: 0 auto 40px auto; 
    padding: 0 20px;
    position: relative;
    z-index: 10;
}

.compact-intro-glass {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid #E2E8F0;
    border-radius: 20px;
    padding: 30px 40px;
    box-shadow: 0 15px 40px rgba(0,0,0,0.06);
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 30px;
}

/* Alineación de textos en la caja intro */
.intro-text {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    text-align: left;
}

/* La etiqueta (Badge) */
.mandy3d-badge-light {
    display: inline-block;
    padding: 6px 16px;
    background: rgba(255, 87, 34, 0.1);
    color: var(--brand-orange);
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 8px;
}

.intro-text h1 {
    font-size: 2.2rem;
    margin: 5px 0 10px 0;
    line-height: 1.2;
}

.intro-text p {
    margin: 0;
    color: var(--text-muted);
    font-size: 1.1rem;
}

.intro-actions {
    display: flex;
    gap: 15px;
    flex-shrink: 0;
}

/* Responsivo para móviles */
@media (max-width: 991px) {
    .promo-bento {
        grid-template-columns: 1fr;
        grid-template-rows: 2fr 1fr 1fr;
        height: 80vh;
    }
    .bento-main { grid-column: 1 / 2; grid-row: 1 / 2; }
    .bento-sub1 { grid-column: 1 / 2; grid-row: 2 / 3; }
    .bento-sub2 { grid-column: 1 / 2; grid-row: 3 / 4; }
    
    .compact-intro-glass {
        flex-direction: column;
        text-align: center;
        padding: 30px 20px;
    }
    
    .intro-text {
        align-items: center;
        text-align: center;
    }
    
    .intro-actions {
        flex-direction: column;
        width: 100%;
    }
}

/* --- Botones Animados --- */
.mandy3d-hero-buttons { display: flex; gap: 20px; justify-content: center; flex-wrap: wrap; }

.mandy3d-btn {
    padding: 16px 36px;
    border-radius: 50px;
    font-weight: 700;
    text-decoration: none;
    font-size: 1rem;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.mandy3d-btn-vibrant {
    background: linear-gradient(45deg, var(--brand-orange), #FF8A65);
    color: #fff;
    box-shadow: 0 10px 20px rgba(255, 87, 34, 0.3);
    border: none;
}

.mandy3d-btn-vibrant:hover {
    transform: translateY(-5px) scale(1.05);
    box-shadow: 0 15px 25px rgba(255, 87, 34, 0.5);
    color: #fff;
}

.mandy3d-btn-outline-light {
    background: #fff;
    color: var(--text-main);
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    border: 2px solid transparent;
}

.mandy3d-btn-outline-light:hover {
    border-color: var(--brand-orange);
    color: var(--brand-orange);
    transform: translateY(-5px);
}

/* --- Headers de Sección --- */
.mandy3d-section-header { text-align: center; margin-bottom: 50px; }
.mandy3d-section-header h2 { font-size: 2.5rem; margin-bottom: 15px; font-weight: 800; }
.mandy3d-section-header p { color: var(--text-muted); font-size: 1.2rem; }

/* --- Grid de Categorías (Blancas y Flotantes) --- */
.mandy3d-categories { 
    padding: 20px 20px 80px 20px; 
    max-width: 1300px; 
    margin: 0 auto; 
}

.mandy3d-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    align-items: stretch;
}

.mandy3d-light-card {
    background: var(--surface-light);
    border-radius: 20px;
    overflow: hidden;
    text-decoration: none;
    box-shadow: var(--shadow-soft);
    display: flex;
    flex-direction: column;
    transition: all 0.4s ease;
    border: 1px solid #E2E8F0;
}

.mandy3d-light-card:hover {
    transform: translateY(-12px);
    box-shadow: var(--shadow-hover);
    border-color: var(--brand-orange);
}

.card-image {
    height: 220px;
    background-size: cover;
    background-position: center;
    transition: transform 0.6s ease;
}

.bg-empresas { background-image: url('https://images.unsplash.com/photo-1542744094-24638ea0b3b5?q=80&w=800'); }
.bg-hogar { background-image: url('https://images.unsplash.com/photo-1485955900006-10f4d324d411?q=80&w=800'); }
.bg-geek { background-image: url('https://images.unsplash.com/photo-1608889175123-8ee362201f81?q=80&w=800'); }
.bg-universos { background-image: url('https://images.unsplash.com/photo-1606660265514-358ebbadc80d?q=80&w=800'); }

.mandy3d-light-card:hover .card-image { transform: scale(1.08); }

.card-content {
    padding: 30px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.card-content h3 { font-size: 1.3rem; color: var(--text-main); margin-bottom: 12px; font-weight: 800; }
.card-content p { color: var(--text-muted); font-size: 0.95rem; line-height: 1.6; margin: 0; }

.card-arrow {
    margin-top: auto;
    align-self: flex-end;
    font-size: 1.5rem;
    color: var(--brand-orange);
    transition: all 0.3s ease;
    background: rgba(255, 87, 34, 0.1);
    width: 40px; height: 40px;
    display: flex; align-items: center; justify-content: center;
    border-radius: 50%;
}

.mandy3d-light-card:hover .card-arrow {
    background: var(--brand-orange);
    color: #fff;
    transform: translateX(5px);
}

/* --- WooCommerce (Tarjetas Blancas y Limpias) --- */
.mandy3d-store-preview { 
    padding: 80px 20px; 
    max-width: 1300px; 
    margin: 0 auto; 
    background-color: var(--surface-gray);
    border-radius: 30px;
}

.mandy3d-woo-light .woocommerce ul.products {
    display: grid !important;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)) !important;
    gap: 30px !important;
    justify-content: center !important;
    margin: 0 !important;
}

.mandy3d-woo-light .woocommerce ul.products li.product {
    background: var(--surface-light);
    border: 1px solid #E2E8F0;
    border-radius: 20px;
    padding: 20px;
    margin: 0 auto !important;
    width: 100% !important;
    max-width: 320px !important;
    display: flex !important;
    flex-direction: column;
    transition: all 0.4s ease;
    text-align: center;
    box-shadow: 0 4px 15px rgba(0,0,0,0.02);
}

.mandy3d-woo-light .woocommerce ul.products li.product:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-hover);
    border-color: var(--brand-orange);
}

.mandy3d-woo-light .woocommerce ul.products li.product img {
    width: 100% !important;
    max-height: 260px !important;
    aspect-ratio: 1 / 1;
    object-fit: contain !important;
    border-radius: 12px;
    margin-bottom: 20px;
    background-color: transparent; 
    padding: 10px;
    transition: transform 0.5s ease;
}

.mandy3d-woo-light .woocommerce ul.products li.product:hover img {
    transform: scale(1.05);
}

.mandy3d-woo-light .woocommerce ul.products li.product h2,
.mandy3d-woo-light .woocommerce ul.products li.product .woocommerce-loop-product__title {
    color: var(--text-main);
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 10px;
}

.mandy3d-woo-light .woocommerce ul.products li.product .price {
    color: var(--brand-orange);
    font-weight: 800;
    font-size: 1.1rem;
    margin-bottom: 20px;
}

.mandy3d-woo-light .woocommerce ul.products li.product .button {
    margin-top: auto !important;
    background: var(--surface-gray);
    color: var(--text-main);
    border-radius: 50px;
    padding: 12px 20px;
    font-weight: 700;
    transition: all 0.3s ease;
    border: 1px solid #E2E8F0;
}

.mandy3d-woo-light .woocommerce ul.products li.product .button:hover {
    background: var(--brand-orange);
    color: #fff;
    border-color: var(--brand-orange);
}

/* Botón Ver Todo */
.text-center { text-align: center !important; width: 100%; display: block; }

.mandy3d-btn-ghost-light {
    display: inline-block !important;
    padding: 16px 40px !important;
    background: #fff !important;
    color: var(--text-main) !important;
    border: 2px solid #E2E8F0 !important;
    border-radius: 50px !important;
    font-weight: 700 !important;
    text-decoration: none !important;
    transition: all 0.3s ease !important;
}

.mandy3d-btn-ghost-light:hover {
    border-color: var(--brand-orange) !important;
    color: var(--brand-orange) !important;
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.05) !important;
}

/* --- CTA Final --- */
.mandy3d-cta-light {
    padding: 120px 20px;
    background: linear-gradient(135deg, var(--brand-orange) 0%, #FF8A65 100%);
    text-align: center;
    position: relative;
    overflow: hidden;
    margin-top: 60px;
}

.cta-content-light {
    position: relative;
    z-index: 1;
    max-width: 700px;
    margin: 0 auto;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    padding: 50px;
    border-radius: 24px;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.cta-content-light h2 { font-size: 2.2rem; color: #fff; margin-bottom: 20px; font-weight: 800; }
.cta-content-light p { color: rgba(255, 255, 255, 0.9); font-size: 1.1rem; margin-bottom: 40px; }

.mandy3d-btn-vibrant-large {
    background: #fff;
    color: var(--brand-orange);
    padding: 18px 45px;
    font-size: 1.2rem;
    border-radius: 50px;
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
    display: inline-block;
    text-decoration: none;
    font-weight: 800;
    transition: all 0.3s ease;
}

.mandy3d-btn-vibrant-large:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
    color: var(--brand-orange-hover);
}