/* =====================================================
   MENINA — CSS PROPIO (complementa Bootstrap 5)
   Paleta Turquesa: 
   oscuro #0e7a75  |  principal #c6f7f7
   claro #d8fcfc   |  crema/fondo #edfcfc
   ===================================================== */

/* ----- TIPOGRAFÍA Y BASE ----- */

body {
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    background: #edfcfc;
    color: #1e2a3a;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

main { flex: 1; }

h1, h2, h3, h4 { color: #0e7a75; font-weight: 700; }

/* Separador decorativo bajo h2 en área pública */
.titulo-seccion {
    position: relative;
    display: inline-block;
    margin-bottom: 8px;
}
.titulo-seccion::after {
    content: '';
    position: absolute;
    bottom: -6px;
    left: 0;
    width: 48px;
    height: 3px;
    background: #c6f7f7;
    border-radius: 2px;
}

/* ----- NAVBAR ----- */
.navbar-menina {
    background: #0e7a75 !important;
    box-shadow: 0 2px 12px rgba(0,0,0,0.15);
    padding: 10px 0;
}

.navbar-menina .navbar-brand {
    font-size: 1.25rem;
    font-weight: 700;
    color: white !important;
    gap: 10px;
}

.navbar-menina .navbar-brand img {
    height: 38px;
    border-radius: 6px;
    background: white;
    padding: 2px;
}

.navbar-menina .nav-link {
    color: #c1e8e6 !important;
    font-weight: 500;
    font-size: 0.95rem;
    padding: 6px 14px !important;
    border-radius: 20px;
    transition: background 0.18s, color 0.18s;
}

.navbar-menina .nav-link:hover,
.navbar-menina .nav-link.active {
    background: rgba(127,203,200,0.25);
    color: white !important;
}

/* ----- HERO ----- */
.hero {
    position: relative;
    background: #0e7a75 url('../../imagenes/imagen.png') center/cover no-repeat;
    min-height: 500px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 100px 0;
    color: white;
}

/* Capa oscura sobre la imagen para que el texto se lea bien */
.hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(160deg, rgba(14,122,117,0.85) 0%, rgba(14,122,117,0.60) 100%);
}

.hero > * { position: relative; z-index: 1; }

.hero h1 {
    color: white;
    font-size: clamp(2rem, 5vw, 3.2rem);
    font-weight: 800;
    text-shadow: 0 2px 16px rgba(0,0,0,0.3);
    margin-bottom: 14px;
}

.hero h2 {
    color: white !important;
    font-size: clamp(0.95rem, 2vw, 1.2rem);
    font-weight: 600;
    letter-spacing: 0.04em;
    text-shadow: 0 1px 8px rgba(0,0,0,0.5);
    margin-bottom: 20px;
}

.hero p {
    font-size: clamp(1rem, 2.2vw, 1.25rem);
    opacity: 0.92;
    max-width: 600px;
    margin: 0 auto 28px;
}

.hero .btn-hero {
    background: white;
    color: #0e7a75;
    font-weight: 700;
    padding: 13px 34px;
    border-radius: 50px;
    font-size: 1rem;
    border: none;
    text-decoration: none;
    display: inline-block;
    transition: transform 0.2s, box-shadow 0.2s;
}

.hero .btn-hero:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 24px rgba(0,0,0,0.2);
    color: #174f4d;
    text-decoration: none;
}

/* btn-hero fuera del hero (CTA sections, etc.) */
.btn-hero {
    background: white;
    color: #0e7a75;
    font-weight: 700;
    padding: 12px 30px;
    border-radius: 50px;
    font-size: 0.95rem;
    border: none;
    text-decoration: none;
    display: inline-block;
    transition: transform 0.18s, box-shadow 0.18s;
}

.btn-hero:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.18);
    color: #0e7a75;
    text-decoration: none;
}

/* Variante outline del btn-hero (fondo transparente sobre verde) */
.btn-hero[style*="transparent"]:hover,
.btn-hero[style*="border"]:hover {
    color: white !important;
    background: rgba(255,255,255,0.15) !important;
}

/* ----- CARDS PÚBLICAS ----- */
.menina-card {
    background: white;
    border: 1px solid #c1e8e6;
    border-radius: 14px;
    overflow: hidden;
    transition: transform 0.18s, box-shadow 0.18s;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.menina-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 16px 32px -8px rgba(14,122,117,0.18);
    border-color: #c6f7f7;
}

.menina-card .card-body {
    padding: 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.menina-card .card-title {
    font-size: 1rem;
    font-weight: 700;
    color: #0e7a75;
    margin-bottom: 6px;
}

.menina-card .card-text {
    font-size: 0.88rem;
    color: #338582;
    flex: 1;
}

/* Icono de categoría en la card */
.badge-actividad {
    background: #c6f7f7;
    color: #0e7a75;
    font-size: 0.75rem;
    font-weight: 600;
    padding: 3px 10px;
    border-radius: 20px;
    display: inline-block;
    margin-bottom: 8px;
}

/* ----- BOTONES PROPIOS ----- */
.btn-menina {
    background: #0e7a75;
    color: white;
    border: none;
    border-radius: 50px;
    padding: 9px 22px;
    font-weight: 600;
    font-size: 0.9rem;
    text-decoration: none;
    display: inline-block;
    transition: background 0.18s, transform 0.15s;
    cursor: pointer;
}

.btn-menina:hover {
    background: #0a5c58;
    color: white;
    transform: translateY(-1px);
    text-decoration: none;
}

.btn-menina-outline {
    background: transparent;
    color: #0e7a75;
    border: 2px solid #0e7a75;
    border-radius: 50px;
    padding: 8px 20px;
    font-weight: 600;
    font-size: 0.9rem;
    text-decoration: none;
    display: inline-block;
    transition: all 0.18s;
    cursor: pointer;
}

.btn-menina-outline:hover {
    background: #0e7a75;
    color: white;
    text-decoration: none;
}

/* ----- PAGINACIÓN ----- */
.pagination .page-link {
    color: #0e7a75;
    border-color: #c6f7f7;
    border-radius: 8px !important;
    margin: 0 2px;
    font-weight: 500;
}

.pagination .page-link:hover {
    background: #c6f7f7;
    color: white;
    border-color: #c6f7f7;
}

.pagination .page-item.active .page-link {
    background: #c6f7f7;
    border-color: #c6f7f7;
}

.pagination .page-item.disabled .page-link {
    color: #d8fcfc;
    border-color: #c1e8e6;
}

/* ----- FOOTER ----- */
footer {
    background: #0e7a75 !important;
    color: #c1e8e6;
    padding: 28px 0;
}

footer a {
    color: #c6f7f7;
    text-decoration: none;
    font-weight: 500;
}

footer a:hover { color: white; }

/* ----- SECCIÓN "CTA" (llamada a la acción) ----- */
.cta-section {
    background: linear-gradient(135deg, #0e7a75 0%, #0a5c58 100%);
    border-radius: 16px;
    padding: 48px 40px;
    color: white;
    text-align: center;
    margin: 48px 0;
}

.cta-section h2 { color: white; }
.cta-section p { color: rgba(255,255,255,0.85); }

/* ----- PANEL ADMIN ----- */
.admin-sidebar {
    background: #0e7a75;
    min-height: 100vh;
    padding: 24px 16px;
}

/* Fondo gris muy suave para el área de contenido del admin */
.admin-content {
    background: #edfcfc;
    min-height: 100vh;
    padding: 32px 24px;
}

/* Tarjeta stat del dashboard */
.stat-card {
    background: white;
    border: 1px solid #c1e8e6;
    border-radius: 12px;
    padding: 24px;
    display: flex;
    align-items: center;
    gap: 16px;
}

.stat-icon {
    width: 52px;
    height: 52px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    flex-shrink: 0;
}

.stat-icon-green { background: #c6f7f7; color: #0e7a75; }
.stat-icon-blue  { background: #d6f9f9; color: #0e7a75; }

.stat-card h3 {
    font-size: 1.8rem;
    font-weight: 800;
    margin: 0;
    line-height: 1;
    color: #0e7a75;
}

.stat-card p {
    font-size: 0.85rem;
    color: #338582;
    margin: 4px 0 0;
}

/* Tabla del admin */
.admin-table {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid #c1e8e6;
}

.admin-table thead th {
    background: #0e7a75;
    color: white;
    font-weight: 600;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    padding: 14px 16px;
    border: none;
}

.admin-table tbody td {
    padding: 12px 16px;
    border-bottom: 1px solid #edfcfc;
    vertical-align: middle;
    font-size: 0.92rem;
}

.admin-table tbody tr:last-child td { border-bottom: none; }

.admin-table tbody tr:hover { background: #edfcfc; }

/* Formularios del admin */
.admin-form-card {
    background: white;
    border-radius: 14px;
    border: 1px solid #c1e8e6;
    padding: 32px;
    max-width: 640px;
}

.admin-form-card .form-label {
    font-weight: 600;
    font-size: 0.88rem;
    color: #0e7a75;
    margin-bottom: 6px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.admin-form-card .form-control,
.admin-form-card .form-control:focus {
    border-color: #a0d4d2;
    border-radius: 8px;
    font-size: 0.95rem;
    padding: 10px 14px;
    box-shadow: none;
    border-width: 1.5px;
}

.admin-form-card .form-control:focus {
    border-color: #0e7a75;
    box-shadow: 0 0 0 3px rgba(14,122,117,0.15);
}

/* Imagen miniatura en tabla */
.thumb {
    width: 48px;
    height: 48px;
    object-fit: cover;
    border-radius: 8px;
    border: 1px solid #c1e8e6;
}

/* ----- RESPONSIVE ----- */
@media (max-width: 768px) {
    .hero { padding: 70px 0; min-height: 380px; }
    .hero h1 { font-size: 1.8rem; }
    .admin-content { padding: 20px 14px; }
    .admin-form-card { padding: 20px; }
    .cta-section { padding: 32px 20px; }
}

/* ----- CARDS DE ASOCIADOS (vista pública con logo) ----- */

.socio-card-pub {
    padding: 0;
}

.socio-logo-wrap {
    width: 100%;
    height: 160px;
    background: #edfcfc;
    border-bottom: 1px solid #c1e8e6;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    padding: 16px;
    box-sizing: border-box;
    flex-shrink: 0;
}

.socio-logo-wrap img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    transition: transform 0.2s ease;
}

.socio-card-pub:hover .socio-logo-wrap img {
    transform: scale(1.05);
}

.socio-logo-fallback {
    font-size: 3rem;
    color: #c6f7f7;
    opacity: 0.65;
}

/* ----- MODAL DE CONFIRMACIÓN PERSONALIZADO ----- */

.mc-overlay {
    position: fixed;
    inset: 0;
    background: rgba(18, 54, 52, 0.65);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.22s ease;
}
.mc-overlay.mc-visible {
    opacity: 1;
    pointer-events: all;
}

.mc-box {
    background: #fff;
    border-radius: 20px;
    padding: 38px 32px 30px;
    max-width: 420px;
    width: 92%;
    box-shadow: 0 28px 70px -12px rgba(14,122,117,0.30);
    text-align: center;
    transform: translateY(20px) scale(0.96);
    opacity: 0;
    transition: transform 0.24s cubic-bezier(.22,.68,0,1.2), opacity 0.22s ease;
}
.mc-overlay.mc-visible .mc-box {
    transform: translateY(0) scale(1);
    opacity: 1;
}

.mc-icono {
    width: 62px;
    height: 62px;
    border-radius: 50%;
    background: #fff1f0;
    border: 2px solid #ffd5d1;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    margin: 0 auto 20px;
}

.mc-titulo {
    font-size: 1.15rem;
    font-weight: 700;
    color: #0e7a75;
    margin-bottom: 8px;
}

.mc-msg {
    font-size: 0.9rem;
    color: #338582;
    margin-bottom: 28px;
    line-height: 1.55;
}

.mc-msg strong {
    color: #0e7a75;
}

.mc-btns {
    display: flex;
    gap: 10px;
}

.mc-btn-cancelar {
    flex: 1;
    padding: 11px 0;
    border-radius: 50px;
    border: 1.5px solid #c1e8e6;
    background: #fff;
    color: #0e7a75;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: background 0.15s, border-color 0.15s, transform 0.1s;
}
.mc-btn-cancelar:hover {
    background: #edfcfc;
    border-color: #c6f7f7;
    transform: translateY(-1px);
}

.mc-btn-confirmar {
    flex: 1;
    padding: 11px 0;
    border-radius: 50px;
    border: none;
    background: linear-gradient(135deg, #e53935, #c62828);
    color: #fff;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: filter 0.15s, transform 0.1s;
    box-shadow: 0 4px 14px -4px rgba(197,40,40,0.45);
}
.mc-btn-confirmar:hover {
    filter: brightness(1.08);
    transform: translateY(-1px);
}

/* ----- HAMBURGER BLANCO en móvil ----- */
.navbar-menina .navbar-toggler {
    border: none !important;
    padding: 6px 8px;
}
.navbar-menina .navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255,255,255,1%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e") !important;
}
.navbar-menina .navbar-toggler:focus {
    box-shadow: none !important;
}

/* ══════════════════════════════════════════════════════════════
   RESPONSIVE DIFERENCIADO — escritorio vs. móvil
   Añadido en la iteración de revisión del tutor
   ══════════════════════════════════════════════════════════════ */

/* ── FICHA DE ASOCIADO: columnas en escritorio, apilado en móvil ── */

/* En escritorio (>=992px): mapa en columna derecha, altura 490px */
@media (min-width: 992px) {
    .mapa-socio-wrapper iframe {
        height: 490px;
    }
}

/* En tablet y móvil (<992px): el mapa va debajo de los datos */
@media (max-width: 991px) {
    .mapa-socio-wrapper iframe {
        height: 280px;
    }
    /* Asegurar que el iframe ocupa el ancho completo */
    .mapa-socio-wrapper {
        width: 100%;
    }
}

/* ── MAPA GENERAL LEAFLET ───────────────────────────────────── */
@media (max-width: 767px) {
    #mapa-general {
        height: 280px !important;
    }
}
@media (min-width: 768px) {
    #mapa-general {
        height: 450px !important;
    }
}

/* ── TABLAS ADMIN: ocultar columnas secundarias en móvil ─────── */
@media (max-width: 767px) {
    .table-admin-col-secondary {
        display: none !important;
    }
    /* Hacer las acciones más compactas */
    .btn-accion-admin {
        padding: 4px 8px !important;
        font-size: 0.78rem !important;
    }
}

/* ── TARJETAS DE ASOCIADOS: ajustar logo en móvil ───────────────── */
@media (max-width: 575px) {
    .socio-logo-wrap {
        height: 120px;
    }
    .menina-card .card-body {
        padding: 16px !important;
    }
}

/* ── HÉROE: reducir tamaño fuente en pantallas pequeñas ─────── */
@media (max-width: 576px) {
    .hero h1 { font-size: 1.5rem; }
    .hero p  { font-size: 0.95rem; }
}

/* ── PAGINACIÓN: contraer en móvil ──────────────────────────── */
@media (max-width: 480px) {
    .pagination .page-link {
        padding: 5px 9px;
        font-size: 0.82rem;
    }
}

/* ── NAVEGACIÓN: separador entre items en móvil desplegado ─── */
@media (max-width: 991px) {
    #navMenu .nav-item {
        border-bottom: 1px solid rgba(255,255,255,0.08);
    }
    #navMenu .nav-item:last-child {
        border-bottom: none;
    }
}

/* ── FORMULARIOS ADMIN: columna única en móvil ───────────────── */
@media (max-width: 767px) {
    .admin-form-card .row > [class*="col-md"] {
        margin-bottom: 0;
    }
}

/* ── DASHBOARD ADMIN: stats cards en columna en móvil ─────── */
@media (max-width: 575px) {
    .stat-card {
        flex-direction: row;
        align-items: center;
        gap: 16px;
        padding: 14px 16px;
    }
    .stat-card h3 {
        font-size: 1.5rem;
        margin: 0;
    }
}

/* ══════════════════════════════════════════════════════════════
   MEJORAS VISUALES GENERALES
   ══════════════════════════════════════════════════════════════ */

/* Hover en tarjetas de asociados — efecto elevación */
.menina-card.socio-card-pub {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.menina-card.socio-card-pub:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(13, 45, 94, 0.15);
}

/* Indicador de página activa en navbar */
.navbar-menina .nav-link.active,
.navbar-menina .nav-link[aria-current="page"] {
    color: #fff !important;
    font-weight: 700;
    border-bottom: 3px solid #0e7a75;
    padding-bottom: calc(0.5rem - 3px);
}

/* Animación suave para el colapso del mapa en móvil */
.mapa-collapse-toggle {
    transition: max-height 0.3s ease;
    overflow: hidden;
}

/* Popup de Leaflet — tipografía consistente */
.leaflet-popup-content {
    font-family: Arial, sans-serif !important;
    font-size: 0.85rem !important;
    line-height: 1.4 !important;
}
.leaflet-popup-content-wrapper {
    border-radius: 10px !important;
    box-shadow: 0 4px 16px rgba(0,0,0,0.18) !important;
}
