/* =========================================
   VARIABLES & RESET
   ========================================= */
:root {
    /* Brand Colors from style.css */
    --primary-color: #335a96; /* --color-principal */
    --primary-hover: #202c56; /* --color-secundario */
    --secondary-color: #c29e50; /* --color-terciario */
    --accent-color: #1885c2; /* --color-cuarto */
    
    /* Text Colors */
    --text-main: #000000; /* --color-letras */
    --text-secondary: #666666;
    --text-white: #ffffff; /* --color-letras-blanco */
    
    /* Backgrounds */
    --bg-light: #f3f3f3; /* --color-fondo */
    --bg-white: #ffffff;
    
    /* UI Elements */
    --card-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --card-hover-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.15), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --radius-md: 8px;
    --radius-lg: 12px;
    --transition: all 0.3s ease;
}

body {
    background-color: var(--bg-light);
    font-family: 'Poppins', sans-serif; /* Brand Font */
    color: var(--text-main);
    line-height: 1.6;
}

/* =========================================
   HERO SECTION (SLIDER REPLACEMENT)
   ========================================= */
#slider-lavanderia {
    position: relative;
    height: 400px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--primary-hover); /* Fallback */
}

.wallpaper {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    opacity: 0;
    animation: fadeSlide 18s infinite;
    z-index: 1;
}

.wallpaper::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    /* Brand Gradient Overlay */
    background: linear-gradient(135deg, rgba(32, 44, 86, 0.95) 0%, rgba(51, 90, 150, 0.85) 100%);
}

.wallpaper:nth-child(1) { animation-delay: 0s; background-image: url('https://images.unsplash.com/photo-1503676382389-4809596d5290?auto=format&fit=crop&w=1920&q=80'); }
.wallpaper:nth-child(2) { animation-delay: 6s; background-image: url('https://images.unsplash.com/photo-1523240795612-9a054b0db644?auto=format&fit=crop&w=1920&q=80'); }
.wallpaper:nth-child(3) { animation-delay: 12s; background-image: url('https://images.unsplash.com/photo-1517245386807-bb43f82c33c4?auto=format&fit=crop&w=1920&q=80'); }

@keyframes fadeSlide {
    0% { opacity: 0; transform: scale(1.1); }
    5% { opacity: 1; transform: scale(1); }
    33% { opacity: 1; transform: scale(1); }
    38% { opacity: 0; transform: scale(1.1); }
    100% { opacity: 0; transform: scale(1.1); }
}

.ctn-content-slider {
    position: relative;
    z-index: 10;
    text-align: center;
    color: white;
    padding: 20px;
    max-width: 800px;
}

.ctn-content-slider h1 {
    font-size: 3rem;
    font-weight: 800;
    margin-bottom: 1rem;
    letter-spacing: -0.025em;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.ctn-content-slider span.bold {
    color: var(--secondary-color);
}

.ctn-content-slider p {
    font-size: 1.25rem;
    opacity: 0.9;
    font-weight: 300;
}

/* =========================================
   SECTION HEADERS
   ========================================= */
.section-header {
    margin-bottom: 2rem;
    position: relative;
    display: inline-block;
}

.section-header h2 {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-main);
    margin: 0;
    position: relative;
    z-index: 1;
}

.section-header::after {
    content: '';
    position: absolute;
    bottom: 5px;
    left: 0;
    width: 100%;
    height: 4px;
    background-color: var(--secondary-color); /* Brand Gold */
    z-index: 0;
    border-radius: 2px;
}

/* =========================================
   COURSE GRID LAYOUT (FLEXIBLE & ADAPTIVE)
   ========================================= */
.content-wrapper {
    display: flex;
    flex-wrap: wrap;
    justify-content: center; /* Centra las tarjetas si hay pocas */
    gap: 2rem;
    padding: 1rem 0;
    width: 100%;
}

/* Base card sizing for normal grid behavior (3+ items) */
.course-card {
    flex: 1 1 300px; /* Grow, shrink, basis */
    max-width: 400px; /* Prevent becoming too wide in grid */
    min-width: 280px;
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--card-shadow);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    height: auto; /* Allow height to adapt */
    border: 1px solid rgba(0,0,0,0.05);
}

/* =========================================
   ADAPTIVE LAYOUT LOGIC (Based on data-count)
   ========================================= */

/* Case: 1 Course (Hero Card Style) */
.content-wrapper[data-count="1"] .course-card {
    flex: 0 1 800px; /* Don't grow beyond 800px */
    max-width: 800px;
    flex-direction: row; /* Horizontal layout */
    min-height: 280px;
}

.content-wrapper[data-count="1"] .course-card__image-container {
    width: 50%;
    height: auto;
}

.content-wrapper[data-count="1"] .course-card__content {
    width: 50%;
    justify-content: center;
    padding: 2.5rem;
}

.content-wrapper[data-count="1"] .course-card__title {
    font-size: 1.75rem;
}

.content-wrapper[data-count="1"] .course-card__description {
    font-size: 1.1rem;
    -webkit-line-clamp: 5;
}

/* Case: 2 Courses (Balanced Split) */
.content-wrapper[data-count="2"] .course-card {
    flex: 0 1 500px;
    max-width: 550px;
}

.content-wrapper[data-count="2"] .course-card__image-container {
    height: 240px; /* Slightly taller image */
}

/* Responsive adjustments for Adaptive Layouts */
@media (max-width: 768px) {
    /* Revert 1-card layout to vertical on mobile */
    .content-wrapper[data-count="1"] .course-card {
        flex-direction: column;
        max-width: 400px;
    }
    
    .content-wrapper[data-count="1"] .course-card__image-container,
    .content-wrapper[data-count="1"] .course-card__content {
        width: 100%;
    }
    
    .content-wrapper[data-count="1"] .course-card__image-container {
        height: 200px;
    }
}

/* =========================================
   COURSE CARD DESIGN (Rest of styles)
   ========================================= */

.course-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--card-hover-shadow);
}

.course-card__image-container {
    position: relative;
    height: 200px;
    overflow: hidden;
}

.course-card__image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.course-card:hover .course-card__image {
    transform: scale(1.05);
}

.course-card__badge {
    position: absolute;
    top: 12px;
    right: 12px;
    background: rgba(255, 255, 255, 0.95);
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-main);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.course-card__content {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.course-card__title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    color: var(--text-main);
    line-height: 1.3;
}

.course-card__description {
    font-size: 0.95rem;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    flex-grow: 1;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.course-card__footer {
    margin-top: auto;
}

/* =========================================
   BUTTONS
   ========================================= */
.course-btn {
    display: block;
    width: 100%;
    padding: 12px 20px;
    text-align: center;
    border-radius: var(--radius-md);
    font-weight: 600;
    text-decoration: none;
    transition: var(--transition);
    font-size: 1rem;
    letter-spacing: 0.01em;
}

.course-btn:hover {
    text-decoration: none;
}

.btn-primary {
    background: var(--primary-color);
    color: white;
    box-shadow: 0 4px 6px rgba(51, 90, 150, 0.2);
    border: none;
}

.btn-primary:hover {
    background: var(--secondary-color); /* Gold hover effect */
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(194, 158, 80, 0.3);
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
}

.btn-outline:hover {
    background: var(--primary-color);
    color: white;
    transform: translateY(-2px);
}

.btn-secondary {
    background: var(--bg-light);
    color: var(--text-main);
}

.btn-secondary:hover {
    background: #e5e7eb;
    color: var(--text-main);
}

/* =========================================
   RESPONSIVE
   ========================================= */
@media (max-width: 768px) {
    .ctn-content-slider h1 {
        font-size: 2rem;
    }
    
    .content-wrapper {
        grid-template-columns: 1fr;
    }
}















