/* Estilos del popup de promos */
.promos-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.promos-modal-content {
    background: white;
    max-width: 500px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    position: relative;
    display: flex;
    flex-direction: column;
}

.promos-header {
    background: #719c77;
    color: white;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
}

.promos-title h2 {
    margin: 0;
    font-size: 1.5em;
    font-weight: 600;
}

.promos-body {
    flex: 1;
}

/* Botón de cerrar */
.promos-close-btn {
    background: rgba(255, 255, 255, 0.9);
    border: 2px solid rgba(0, 0, 0, 0.1);
    color: #333;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    font-size: 20px;
    font-weight: bold;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    position: absolute;
    top: -15px;
    right: -15px;
    z-index: 1000;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.promos-close-btn:hover {
    background: rgba(255, 255, 255, 1);
    border-color: rgba(0, 0, 0, 0.2);
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.promos-close-btn:active {
    transform: scale(0.95);
}

.promos-close {
    background: none;
    border: none;
    color: white;
    font-size: 2em;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
}


.promos-list {
    display: flex;
    flex-direction: column;
}

/* ===== PLANTILLA OVERLAY (ORIGINAL) ===== */
.promo-item {
    display: flex;
    flex-direction: column;
    background: linear-gradient(145deg, #f1f3f4, #e8f5e8);
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    padding-bottom: 10px;
}


.promo-item:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 15px rgba(0,0,0,0.12);
}

.promo-thumbnail {
    width: 120px;
    height: 120px;
    flex-shrink: 0;
}

.promo-thumb {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 20px;
}

.promo-details {
    flex: 1;
}

/* Nuevos estilos para layout vertical */
.promo-thumbnail-full {
    width: 100%;
    height: 200px;
}

.promo-thumb-full {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.promo-details-full {
    width: 100%;
    text-align: center;
}

/* Estilos base para títulos, descripciones y precios - se sobrescriben dinámicamente */
.promo-name {
    margin: 0 0 8px 0;
    line-height: 1.2;
}

.promo-description {
    margin: 0 0 12px 0;
    line-height: 1.4;
    padding: 0 20px 0 20px;
}

.promo-price {
    margin: 0;
    line-height: 1.2;
}

.promos-footer {
    padding: 15px 20px;
    text-align: center;
    background: white;
    position: sticky;
    bottom: 0;
    z-index: 100;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
}

.promos-btn {
    background: #48694d;
    color: white;
    border: none;
    padding: 12px 30px;
    font-size: 1.1em;
    
    cursor: pointer;
    transition: background-color 0.3s;
}

.promos-btn:hover {
    background: #4a6b52;
}

/* ===== PLANTILLA SIDE BY SIDE ===== */
.promo-item-sidebyside {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

/* Sección superior (roja) */
.promo-top-section-sidebyside {
    background: linear-gradient(135deg, #e74c3c, #c0392b);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    position: relative;
    flex: 1;
    min-height: 240px;
    display: flex;
    flex-direction: column;
}

/* Overlay oscuro para mejor legibilidad del texto */
.promo-top-section-sidebyside::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.3);
    z-index: 1;
    border-radius: inherit;
}

/* Contenido de texto (título y descripción) */
.promo-text-content-sidebyside {
    position: absolute;
    top: 30px;
    left: 30px;
    z-index: 3;
    max-width: 50%;
    text-align: left;

}

.promo-title-sidebyside {
    margin: 0 0 10px 0;
    line-height: 1.2;
    color: white;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.promo-description-sidebyside {
    margin: 0;
    line-height: 1.4;
    color: white;
    text-shadow: 0 1px 2px rgba(0,0,0,0.3);
}


/* Badge de precio */
.promo-price-badge-sidebyside {
    position: absolute;
    bottom: 15px;
    right: 30px;
    background: white;
    color: #333;
    padding: 12px 20px;
    border-radius: 25px 25px 0 25px;
    font-weight: 700;
    font-size: 18px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    z-index: 4;
    border: 3px solid #f8f9fa;
}

/* Sección inferior (gris) */
.promo-bottom-section-sidebyside {
    background: #2c3e50;
    padding: 20px 30px;
    display: flex;
    align-items: center;
    min-height: 60px;
}

/* Botón */
.promo-button-sidebyside {
    background: #000;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
}

.promo-button-sidebyside:hover {
    background: #333;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.3);
}

/* ===== PLANTILLA BANNER ===== */
.promo-item-banner {
    display: flex;
    flex-direction: row;
    background: white;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    border: 1px solid #e9ecef;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    min-height: 200px;
}
.promo-title-banner {
    margin-bottom: 10px;
    font-weight: 600;
}
.promo-description-banner {
    margin-bottom: 10px;
}

.promo-item-banner:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

/* Imagen - 40% */
.promo-image-banner {
    width: 40%;
    background: #dc3545;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.promo-img-banner {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.promo-placeholder-text {
    color: white;
    font-size: 24px;
    font-weight: 500;
    text-align: center;
}

/* Contenido - 60% */
.promo-contenido-banner {
    width: 60%;
    padding: 30px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.titulo {
    margin: 0 0 15px 0;
    line-height: 1.2;
    font-weight: bold;
}

.titulo:last-child {
    margin-bottom: 0;
}

/* Responsive para Side by Side */
@media (max-width: 768px) {
    .promo-item-sidebyside {
        flex-direction: column;
        text-align: center;
    }
    
    .promo-image-sidebyside {
        flex: none;
        width: 100%;
        height: 200px;
    }
}

/* Responsive para Banner */
@media (max-width: 768px) {
    .promo-item-banner {
        flex-direction: row; /* Mantener horizontal en móviles */
        min-height: 150px; /* Reducir altura mínima */
    }
    
    .promo-image-banner {
        width: 44%; /* Mantener proporción 40% */
        height: auto;
        min-height: 150px;
    }
    
    .promo-contenido-banner {
        width: 60%; /* Mantener proporción 60% */
        padding: 15px; /* Reducir padding */
    }
    
    .titulo {
        font-size: 16px; /* Reducir tamaño de fuente */
        margin: 0 0 10px 0; /* Reducir margen */
    }
    
    .titulo:last-child {
        margin-bottom: 0;
    }
}

/* Responsive para Banner en pantallas muy pequeñas */
@media (max-width: 480px) {
    .promo-item-banner {
        min-height: 120px; /* Altura aún más pequeña */
    }
    
    .promo-image-banner {
        min-height: 120px;
    }
    
    .promo-contenido-banner {
        padding: 10px; /* Padding mínimo */
    }
    
    .titulo {
        font-size: 14px; /* Fuente más pequeña */
        margin: 0 0 8px 0;
    }
}

/* Responsive */
@media (max-width: 600px) {
    .promos-modal-content {
        margin: 10px;
        max-height: 90vh;
        max-width: 95vw;

    }
    
    .promos-title h2 { font-size: 1.4em; }
    
    .promos-close-btn {
        width: 22px;
        height: 22px;
        font-size: 18px;
        top: 15px;
        right: 8px;
    }
    
    
    .promos-footer {
        padding: 12px 15px;
    }
    .promo-item {
        flex-direction: column;
        text-align: center;
        gap: 12px;

    }
    .promo-thumbnail {
        width: 140px;
        height: 140px;
        flex-shrink: 0;
    }
    .promo-details { text-align: left; padding-left: 15px; }
    .promo-thumbnail-full {
        height: 150px;
    }
    .promo-details-full {
        text-align: center;
        padding-top: 15px;
        
    }
    .promo-name { font-size: 18px; }
    .promo-description { font-size: 15px; color: #000; font-weight: 400; }
    .promo-price { font-size: 20px; }
}

@media (max-width: 400px) {
    .promos-modal-content { margin: 5px; max-width: 98vw; }
    .promo-item { gap: 0px;}
    .promo-thumbnail { width: 80px; height: 80px; }
    .promo-thumbnail-full { height: 120px; }
    .promo-name { font-size:18px; }
    .promo-description { font-size: 15px; }
    .promo-price { font-size: 20px; }
}

