/* ================================
   ESTILOS ESPECÍFICOS DE EXTRAESCOLARES
   ================================ */

.sa-main--extraescolares .sa-main__header {
    display: flex;
    flex-direction: column;
    align-items: center;

    max-width: 800px;
    margin: 0 auto 2rem;
    text-align: center;
}

.sa-main--extraescolares .sa-main__title,
.sa-main--extraescolares .sa-main__subtitle {
    width: 100%;
    text-align: center;
}

.sa-schedule {
    margin-bottom: 3rem;
}

.sa-schedule__header {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    margin-bottom: 1.25rem;
}

/* ==================================================
   CALENDARIO VISUAL (BASE — ESCRITORIO)
   ================================================== */

.sa-calendar {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 1rem;
}

/* COLUMNA DE DÍA */
.sa-calendar__day {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}

/* CABECERA DEL DÍA */
.sa-calendar__day-title {
    text-align: center;
    font-weight: 800;
    font-size: 0.85rem;
    padding: 0.45rem 0.3rem;
    border: 3px solid #000;
    background: #fff;
    letter-spacing: 0.05em;
}

/* TARJETA CLICABLE */
.sa-calendar__activity {
    --sa-activity-color: #f472b6;
    display: block;
    background: color-mix(in srgb, var(--sa-activity-color) 20%, #ffffff 80%);
    border: 2px solid var(--sa-activity-color);
    border-radius: 14px;
    padding: 0.55rem 0.6rem;
    text-align: center;
    text-decoration: none;
    color: inherit;
    transition: transform 0.12s ease, box-shadow 0.12s ease;
    cursor: pointer;
}

.sa-calendar__activity:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.12);
}

/* TÍTULO */
.sa-calendar__activity-title {
    display: block;
    font-weight: 800;
    font-size: 1rem;
    color: #000;
    text-decoration: none;
    margin-bottom: 0.25rem;
}

/* HORARIOS */
.sa-calendar__activity-slot {
    font-size: 0.82rem;
    line-height: 1.3;
}

/* VACÍO */
.sa-calendar__empty {
    text-align: center;
    opacity: 0.35;
    font-style: italic;
    font-size: 0.75rem;
}
.sa-layout .sa-calendar__activity {
        margin-bottom: 0 !important;
    }

/* ==================================================
   RESPONSIVE (SIN TOCAR ESCRITORIO)
   ================================================== */

/* TABLET Y MÓVIL */
@media (max-width: 1024px) {

    .sa-calendar {
        grid-template-columns: repeat(5, minmax(0, 1fr));
        gap: 0.75rem;
    }

    .sa-calendar__day {
        min-width: 0;
        gap: 0.35rem;
    }
   
}

/* MÓVIL */
@media (max-width: 500px) {

    .sa-calendar {
        gap: 0.1rem;
    }

    .sa-calendar__day {
        gap: 0.15rem;
    }

    /* Título del día más compacto */
    .sa-calendar__day-title {
        font-size: 0.45rem;
        padding: 0.2rem 0.15rem;
        border-width: 2px;
        letter-spacing: 0.02em;
        line-height: 1.1;
        margin: 0;
    }

    /* Tarjetas más compactas */
    .sa-calendar__activity {
        padding: 0.28rem 0.32rem;
        border-radius: 9px;

    }

    /* Texto de actividad más compacto */
    .sa-calendar__activity-title {
        font-size: 0.58rem;
        margin-bottom: 0.01rem;
        line-height: 1.1;
    }

    .sa-calendar__activity-slot {
        font-size: 0.53rem;
        line-height: 1.1;
    }

    .sa-calendar__activity strong {
        display: block;
        font-weight: 700;
    }

    .sa-schedule {
        position: relative;
        width: 100vw;
        left: 50%;
        right: 50%;
        margin-left: -50vw;
        margin-right: -50vw;

        padding-left: 0.7rem;
        padding-right: 0.7rem;
        box-sizing: border-box;
    }
}

/* ==================================================
   CARRUSEL DE ACTIVIDADES (FINAL)
   ================================================== */

.sa-carousel {
    position: relative;
    margin-bottom: 0.1rem;
}

/* ======================
   TRACK
   ====================== */

.sa-carousel__track {
    display: flex;
    gap: 0.75rem;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    padding-bottom: 0.3rem;
}

.sa-carousel__track::-webkit-scrollbar {
    display: none;
}

/* ======================
   TARJETA
   ====================== */

.sa-carousel__card {
    flex: 0 0 180px;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 6px 14px rgba(0,0,0,0.08);
    scroll-snap-align: start;
    text-decoration: none;
    color: inherit;
}

/* ======================
   IMAGEN
   ====================== */

.sa-carousel__image {
    height: 120px;
    background-size: cover;
    background-position: center;
    border-radius: 12px 12px 0 0;
}

/* ======================
   CONTENIDO
   ====================== */

.sa-carousel__content {
    padding: 0.5rem 0.6rem 0.7rem;
}

.sa-carousel__tag {
    display: block;
    font-size: 0.65rem;
    font-weight: 700;
    text-align: right;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: #777;
    margin-bottom: 0.2rem;
}

.sa-carousel__title {
    font-size: 0.9rem;
    font-weight: 700;
    margin: 0 0 0.25rem;
    color: #000;
}

.sa-carousel__excerpt {
    font-size: 0.75rem;
    line-height: 1.35;
    color: #555;

    display: -webkit-box;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ======================
   FLECHAS (BASE)
   ====================== */

.sa-carousel__arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10;
    border-radius: 50%;
    border: none;
    background: #ffffff;
    box-shadow: 0 6px 14px rgba(0,0,0,0.18);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #000;
}

.sa-carousel__arrow--prev {
    left: -12px;
}

.sa-carousel__arrow--next {
    right: -12px;
}

/* ======================
   ESCRITORIO → 5 TARJETAS
   ====================== */

@media (min-width: 1025px) {

    .sa-carousel__card {
        flex: 0 0 calc((100% - (4 * 0.75rem)) / 5);
    }

    .sa-carousel__arrow {
        width: 38px;
        height: 38px;
        font-size: 1.4rem;
    }
    
    .sa-carousel__excerpt {
        -webkit-line-clamp: unset;
    }
}

/* ======================
   TABLET → 3 TARJETAS
   ====================== */

@media (max-width: 1024px) and (min-width: 501px) {

    .sa-carousel__card {
        flex: 0 0 calc((100% - (2 * 0.75rem)) / 3);
    }

    .sa-carousel__arrow {
        width: 30px;
        height: 30px;
        font-size: 1.1rem;
    }
    .sa-layout.sa-carousel__title {
        font-size: 0.82rem !important;
        line-height: 1.2;
    }
     .sa-carousel__tag {
        font-size: 0.58rem;
        letter-spacing: 0.03em;
    }

    .sa-layout .sa-carousel__excerpt {
        font-size: 0.70rem !important;
        line-height: 1.3;
        -webkit-line-clamp: 3;
    }
}

/* ======================
   MÓVIL → 2 TARJETAS
   ====================== */

@media (max-width: 500px) {

    .sa-carousel__card {
        flex: 0 0 calc((100% - 0.75rem) / 2);
    }

    .sa-carousel__arrow {
        width: 26px;
        height: 26px;
        font-size: 0.95rem;
    }
    .sa-layout .sa-carousel__title {
        font-size: 0.75rem !important;
        line-height: 1.15 !important;
    }
     .sa-carousel__tag {
        font-size: 0.45rem;
        letter-spacing: 0.03em;
    }

    .sa-carousel__arrow--prev {
        left: -8px;
    }

    .sa-carousel__arrow--next {
        right: -8px;
    }

    .sa-layout .sa-carousel__excerpt {
        font-size: 0.7rem !important;
        line-height: 1.25 !important;
        -webkit-line-clamp: 3;
    }
}

/* ==================================================
   SECCIONES POR NIVEL
   ================================================== */

.sa-level {
    margin-bottom: 1rem !important;
}

.sa-level__header {
    margin-bottom: 1.5rem !important;
}

.sa-level__title {
    font-size: 1.6rem !important;
    font-weight: 800 !important;
    margin: 0 !important;
}


/* Colores por nivel (opcional pero recomendable) */

.sa-level--primaria .sa-level__title {
    color: #2563eb !important; /* azul */
}

.sa-level--infantil .sa-level__title {
    color: #16a34a !important; /* verde */
}

/* ==================================================
   ENLACE "VER TODAS LAS ACTIVIDADES" (DEBAJO DEL CARRUSEL)
   ================================================== */

.sa-level__actions--forward {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 1.5rem !important;
}

/* Estilo base */
.sa-forward-link {
    font-family: 'Quicksand_Bold';
    font-size: 0.8rem;
    color: #2563eb;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    white-space: nowrap;
}

.sa-forward-link:hover {
    text-decoration: underline;
}

/* ======================
   TABLET → TEXTO MÁS PEQUEÑO
   ====================== */

@media (max-width: 1024px) {
    .sa-forward-link {
        font-size: 0.75rem;
    }
}

/* ======================
   MÓVIL → AÚN MÁS DISCRETO
   ====================== */

@media (max-width: 600px) {
    .sa-forward-link {
        font-size: 0.70rem;
    }
}