/* Modal matrícula — v9 bienvenida + cards mejoradas */
#modalMatricula .modal-container.modal-matricula {
    position: relative;
    max-width: 390px;
    padding: 0 !important;
    overflow: hidden;
    border-radius: 12px !important;
    border: none;
    box-shadow: 0 20px 60px rgba(0, 30, 80, 0.2);
    background: #fff !important;
}

#modalMatricula.modal-overlay {
    backdrop-filter: blur(8px);
    background: rgba(0, 20, 51, 0.45) !important;
}

#modalMatricula .mm-close {
    position: absolute;
    top: 0.65rem;
    right: 0.65rem;
    z-index: 20;
    width: 28px;
    height: 28px;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    color: #94a3b8;
    background: transparent;
    transition: color 0.15s ease;
}

#modalMatricula .mm-close:hover {
    color: #0047AB;
}

#modalMatricula .mm-sheet {
    padding: 1.5rem 1.25rem 1.2rem;
    background: #fff;
    text-align: center;
}

/* ── Cabecera ── */
#modalMatricula .mm-head {
    margin-bottom: 1.15rem;
    padding: 0 0.25rem;
}

#modalMatricula .mm-head__welcome {
    margin: 0 0 0.25rem;
    font-size: 0.78rem;
    font-weight: 600;
    color: #94a3b8;
    letter-spacing: 0.04em;
}

#modalMatricula .mm-head__brand {
    margin: 0 0 0.6rem;
    font-size: 1.35rem;
    font-weight: 800;
    line-height: 1.15;
    letter-spacing: 0.02em;
}

#modalMatricula .mm-head__blue {
    color: #0047AB;
}

#modalMatricula .mm-head__gold {
    color: #C9A227;
}

#modalMatricula .mm-head__badge {
    margin: 0 0 0.55rem;
    font-size: 0.72rem;
    font-weight: 700;
    color: #64748b;
    line-height: 1.35;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

#modalMatricula .mm-head__line {
    margin: 0;
    font-size: 0.92rem;
    font-weight: 600;
    color: #334155;
    line-height: 1.4;
}

#modalMatricula .mm-head__line strong {
    color: #0047AB;
    font-weight: 800;
}

#modalMatricula .mm-head__line--sub {
    margin-top: 0.15rem;
    font-size: 0.84rem;
    font-weight: 500;
    color: #64748b;
}

/* ── Grupos ── */
#modalMatricula .mm-cards {
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
    margin-bottom: 1rem;
}

#modalMatricula .mm-card {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    border: none;
    cursor: pointer;
    padding: 0;
    border-radius: 10px;
    overflow: hidden;
    text-align: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

#modalMatricula .mm-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
}

#modalMatricula .mm-card--menor {
    outline: 2px solid #bfdbfe;
    outline-offset: -2px;
}

#modalMatricula .mm-card--menor:hover {
    outline-color: #0047AB;
}

#modalMatricula .mm-card--mayor {
    outline: 2px solid #fde68a;
    outline-offset: -2px;
}

#modalMatricula .mm-card--mayor:hover {
    outline-color: #C9A227;
}

#modalMatricula .mm-card__top {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.15rem;
    padding: 0.9rem 1rem 0.75rem;
}

#modalMatricula .mm-card--menor .mm-card__top {
    background: linear-gradient(180deg, #f0f7ff 0%, #fff 100%);
}

#modalMatricula .mm-card--mayor .mm-card__top {
    background: linear-gradient(180deg, #fffbeb 0%, #fff 100%);
}

#modalMatricula .mm-card__title {
    font-size: 1rem;
    font-weight: 800;
    line-height: 1.25;
}

#modalMatricula .mm-card--menor .mm-card__title {
    color: #0047AB;
}

#modalMatricula .mm-card--mayor .mm-card__title {
    color: #92710a;
}

#modalMatricula .mm-card__meta {
    font-size: 0.8rem;
    color: #64748b;
    line-height: 1.3;
}

#modalMatricula .mm-card__date {
    font-size: 0.82rem;
    font-weight: 700;
    color: #334155;
    margin-top: 0.15rem;
}

#modalMatricula .mm-card--menor .mm-card__date {
    color: #1d4ed8;
}

#modalMatricula .mm-card--mayor .mm-card__date {
    color: #b45309;
}

#modalMatricula .mm-card__action {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 0.65rem 1rem;
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    color: #fff;
    background: #C8102E;
    transition: background 0.15s ease;
}

#modalMatricula .mm-card:hover .mm-card__action {
    background: #a50d25;
}

/* ── Ventajas en fila ── */
#modalMatricula .mm-perks {
    list-style: none;
    margin: 0 0 1rem;
    padding: 0.7rem 0 0;
    border-top: 1px solid #f1f5f9;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.35rem;
    text-align: center;
}

#modalMatricula .mm-perks li {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.62rem;
    font-weight: 600;
    color: #475569;
    line-height: 1.3;
}

#modalMatricula .mm-perks li i {
    flex-shrink: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    font-size: 0.75rem;
    color: #0047AB;
    background: #eff6ff;
}

#modalMatricula .mm-perks li span {
    display: block;
    max-width: 100%;
}

/* ── WhatsApp ── */
#modalMatricula .mm-footer {
    width: 100%;
}

#modalMatricula .mm-footer__wa-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.45rem;
}

#modalMatricula .mm-wa-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.3rem;
    padding: 0.55rem 0.4rem;
    border-radius: 8px;
    font-size: 0.72rem;
    font-weight: 700;
    text-decoration: none;
    color: #fff;
    background: #22c55e;
    transition: background 0.15s ease;
    white-space: nowrap;
}

#modalMatricula .mm-wa-btn:hover {
    color: #fff;
    background: #16a34a;
}

#modalMatricula .mm-wa-btn i {
    font-size: 0.85rem;
}

@media (max-width: 768px) {
    #modalMatricula .modal-container.modal-matricula {
        max-width: min(370px, calc(100% - 1.25rem)) !important;
        padding: 0 !important;
    }

    #modalMatricula .mm-sheet {
        padding: 1.3rem 1.1rem 1.1rem;
    }

    #modalMatricula .mm-head__brand {
        font-size: 1.22rem;
    }

    #modalMatricula .mm-head__badge {
        font-size: 0.66rem;
        white-space: normal;
    }
}

@media (max-width: 340px) {
    #modalMatricula .mm-footer__wa-row {
        grid-template-columns: 1fr;
    }
}
