/* Estilos específicos para el módulo de promociones */

/* Contenedor principal de promociones */
.promociones-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* Filtros */
.promociones-filters {
    margin-bottom: 30px;
}

.filters-container {
    display: flex;
    gap: 15px;
    align-items: center;
    flex-wrap: wrap;
}

.filter-select {
    padding: 10px 15px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    background: white;
    font-size: 0.95rem;
    color: #4a5568;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 160px;
}

.filter-select:focus {
    outline: none;
    border-color: #4299e1;
    box-shadow: 0 0 0 3px rgba(66, 153, 225, 0.1);
}

.filter-select:hover {
    border-color: #cbd5e0;
}

/* Modal */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.modal-content {
    background: white;
    border-radius: 12px;
    padding: 0;
    max-width: 500px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
}

.modal-header {
    padding: 20px 25px;
    border-bottom: 1px solid #e2e8f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h3 {
    margin: 0;
    color: #2d3748;
    font-size: 1.3rem;
}

.modal-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: #a0aec0;
    padding: 5px;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.modal-close:hover {
    background: #f7fafc;
    color: #4a5568;
}

.modal-body {
    padding: 25px;
}

/* SLIDER DE PROMOCIONES */
.slider-wrapper {
    position: relative;
    width: 100%;
    height: 400px;
    overflow: hidden;
    border-radius: 16px;
    margin-bottom: 40px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.slider-container {
    display: flex;
    width: 100%;
    height: 100%;
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.slider-slide {
    min-width: 100%;
    height: 100%;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.slide-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    opacity: 0.3;
}

.slide-content {
    position: relative;
    z-index: 2;
    padding: 40px;
    width: 100%;
    max-width: 800px;
}

.slide-text {
    text-align: inherit;
}

.slide-title {
    font-size: 3rem;
    font-weight: 700;
    margin: 0 0 20px 0;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    line-height: 1.2;
}

.slide-description {
    font-size: 1.3rem;
    margin: 0 0 30px 0;
    opacity: 0.95;
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.3);
}

.slide-btn {
    display: inline-block;
    padding: 15px 30px;
    background: rgba(255, 255, 255, 0.9);
    color: #333;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.slide-btn:hover {
    background: white;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

/* Controles del slider */
.slider-controls {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 100%;
    display: flex;
    justify-content: space-between;
    padding: 0 20px;
    z-index: 3;
}

.slider-btn {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    color: white;
    font-size: 1.2rem;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
}

.slider-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.1);
}

/* Indicadores del slider */
.slider-indicators {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
    z-index: 3;
}

.indicator {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    border: none;
    background: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: all 0.3s ease;
}

.indicator.active {
    background: white;
    transform: scale(1.2);
}

.indicator:hover {
    background: rgba(255, 255, 255, 0.8);
}

/* Loading del slider */
.slider-loading {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 400px;
    background: #f8f9fa;
    border-radius: 16px;
}

/* Header de promociones */
.promociones-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* Header de promociones */
.promociones-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 40px 20px;
    text-align: center;
    border-radius: 12px;
    margin-bottom: 30px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.promociones-header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin: 0 0 10px 0;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.promociones-header p {
    font-size: 1.1rem;
    opacity: 0.9;
    margin: 0;
}

/* Grid de promociones */
.promociones-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 25px;
    margin-top: 30px;
}

/* Tarjeta de promoción */
.promocion-card {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid #f0f2f5;
    position: relative;
}

.promocion-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15);
}

/* Imagen de la promoción */
.promocion-imagen {
    position: relative;
    height: 200px;
    overflow: hidden;
}

.promocion-imagen img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.promocion-card:hover .promocion-imagen img {
    transform: scale(1.05);
}

/* Badge de descuento */
.promocion-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    background: linear-gradient(135deg, #ff6b6b, #ee5a24);
    color: white;
    padding: 8px 16px;
    border-radius: 20px;
    font-weight: 700;
    font-size: 0.9rem;
    box-shadow: 0 4px 12px rgba(255, 107, 107, 0.3);
}

/* Contenido de la tarjeta */
.promocion-content {
    padding: 25px;
}

.promocion-title {
    font-size: 1.4rem;
    font-weight: 700;
    color: #2d3748;
    margin: 0 0 10px 0;
    line-height: 1.3;
}

.promocion-description {
    color: #718096;
    font-size: 0.95rem;
    line-height: 1.6;
    margin: 0 0 20px 0;
}

/* Fechas de validez */
.promocion-fechas {
    background: #f7fafc;
    padding: 15px;
    border-radius: 8px;
    margin: 15px 0;
    border-left: 4px solid #4299e1;
}

.promocion-fechas p {
    margin: 0;
    font-size: 0.85rem;
    color: #4a5568;
}

.promocion-fechas strong {
    color: #2d3748;
}

/* Precios */
.promocion-precios {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 20px 0;
}

.precio-original {
    font-size: 1rem;
    color: #a0aec0;
    text-decoration: line-through;
}

.precio-promocional {
    font-size: 1.4rem;
    font-weight: 700;
    color: #48bb78;
}

/* Botón de acción */
.promocion-btn {
    width: 100%;
    background: linear-gradient(135deg, #4299e1, #3182ce);
    color: white;
    border: none;
    padding: 14px 20px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.promocion-btn:hover {
    background: linear-gradient(135deg, #3182ce, #2c5282);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(66, 153, 225, 0.3);
}

/* Estados de las promociones */
.promocion-activa .promocion-card {
    border-left: 4px solid #48bb78;
}

.promocion-expirada .promocion-card {
    opacity: 0.6;
    border-left: 4px solid #f56565;
}

.promocion-expirada .promocion-btn {
    background: #cbd5e0;
    cursor: not-allowed;
}

.promocion-expirada .promocion-btn:hover {
    background: #cbd5e0;
    transform: none;
    box-shadow: none;
}

/* Loading state */
.promociones-loading {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 300px;
    flex-direction: column;
    gap: 20px;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #4299e1;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Error state */
.promociones-error {
    text-align: center;
    padding: 40px;
    color: #e53e3e;
    background: #fed7d7;
    border-radius: 8px;
    margin: 20px 0;
}

/* Empty state */
.promociones-empty {
    text-align: center;
    padding: 60px 20px;
    color: #718096;
}

.promociones-empty img {
    width: 120px;
    height: 120px;
    opacity: 0.5;
    margin-bottom: 20px;
}

/* Responsive */
@media (max-width: 768px) {
    .promociones-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .promociones-header {
        padding: 30px 15px;
    }
    
    .promociones-header h1 {
        font-size: 2rem;
    }
    
    .promocion-content {
        padding: 20px;
    }
    
    .promocion-title {
        font-size: 1.2rem;
    }
    
    /* Slider responsive */
    .slider-wrapper {
        height: 300px;
    }
    
    .slide-content {
        padding: 20px;
    }
    
    .slide-title {
        font-size: 2rem;
    }
    
    .slide-description {
        font-size: 1rem;
    }
    
    .slider-controls {
        padding: 0 10px;
    }
    
    .slider-btn {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .promociones-container {
        padding: 15px;
    }
    
    .promociones-header h1 {
        font-size: 1.8rem;
    }
    
    .promocion-badge {
        top: 10px;
        right: 10px;
        padding: 6px 12px;
        font-size: 0.8rem;
    }
    
    /* Slider mobile */
    .slider-wrapper {
        height: 250px;
        border-radius: 12px;
    }
    
    .slide-content {
        padding: 15px;
    }
    
    .slide-title {
        font-size: 1.5rem;
        margin-bottom: 15px;
    }
    
    .slide-description {
        font-size: 0.9rem;
        margin-bottom: 20px;
    }
    
    .slide-btn {
        padding: 12px 24px;
        font-size: 0.9rem;
    }
    
    .filters-container {
        flex-direction: column;
        align-items: stretch;
    }
    
    .filter-select {
        min-width: auto;
        width: 100%;
        margin-bottom: 10px;
    }
}
