/* ==========================================================================
   FLECHAS - MÓDULO MENOPAUSIA & BIENESTAR FEMENINO
   Diseño Integral Multi-Dispositivo (Desktop, Tablet & Mobile)
   Paleta: Orquídea, Rosa Flechas, Oro & Menta Clínica
   ========================================================================== */

:root {
    --primary: #9333ea;
    --primary-dark: #7e22ce;
    --primary-deep: #581c87;
    --primary-light: #faf5ff;
    --primary-subtle: #f3e8ff;
    --primary-glow: rgba(147, 51, 234, 0.22);
    
    --rose: #e11d48;
    --rose-dark: #be123c;
    --rose-light: #fff1f2;
    --rose-subtle: #ffe4e6;
    
    --gold: #d97706;
    --gold-light: #fef3c7;
    --gold-dark: #92400e;
    
    --teal: #0d9488;
    --teal-light: #ccfbf1;
    --teal-dark: #115e59;
    
    --bg-page: #fbf8fc;
    --bg-card: #ffffff;
    --text-main: #0f172a;
    --text-body: #334155;
    --text-muted: #64748b;
    --border: #f1ddf4;
    --border-light: #f8eff9;
    
    --shadow-sm: 0 2px 6px rgba(147, 51, 234, 0.05);
    --shadow-md: 0 6px 18px rgba(147, 51, 234, 0.08);
    --shadow-lg: 0 14px 34px rgba(147, 51, 234, 0.12);
    --shadow-hover: 0 16px 36px rgba(147, 51, 234, 0.18);
    
    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 20px;
    --radius-xl: 24px;
    --radius-full: 9999px;
    
    --transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ==========================================================================
   RESETEO BASE & IMÁGENES SEGURAS
   ========================================================================== */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    background-color: var(--bg-page);
    color: var(--text-body);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

/* Regla crítica para evitar imágenes desbordadas */
img, svg, picture {
    max-width: 100%;
    height: auto;
    display: inline-block;
    vertical-align: middle;
}

button, input, select, textarea {
    font-family: inherit;
    font-size: inherit;
}

button {
    cursor: pointer;
    border: none;
    background: none;
    outline: none;
}

a {
    color: inherit;
    text-decoration: none;
}

/* ==========================================================================
   1. CABECERA PRINCIPAL & HUB DE NAVEGACIÓN
   ========================================================================== */
.main-header {
    background: rgba(255, 255, 255, 0.94);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(147, 51, 234, 0.04);
}

.header-container {
    max-width: 1320px;
    margin: 0 auto;
    padding: 0.75rem 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

/* Marca / Logotipo */
.brand-area {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
    flex-shrink: 0;
}

.brand-logo-img {
    width: 44px;
    height: 44px;
    object-fit: contain;
    border-radius: 10px;
    transition: var(--transition);
}

.brand-area:hover .brand-logo-img {
    transform: scale(1.05);
}

.brand-text {
    display: flex;
    flex-direction: column;
}

.brand-name {
    font-family: 'Playfair Display', Georgia, serif;
    font-weight: 700;
    font-size: 1.25rem;
    color: #be123c;
    letter-spacing: 0.05em;
    line-height: 1.1;
}

.brand-tagline {
    font-size: 0.72rem;
    color: var(--text-muted);
    font-weight: 500;
    letter-spacing: 0.02em;
}

/* Botón Hamburguesa Móvil */
.mobile-nav-toggle {
    display: none;
    width: 42px;
    height: 42px;
    border-radius: 10px;
    border: 1px solid var(--border);
    background: #ffffff;
    color: var(--text-main);
    font-size: 1.15rem;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.mobile-nav-toggle:active {
    transform: scale(0.94);
}

/* Enlaces del Hub Superior */
.nav-hub {
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.nav-hub-link {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.5rem 0.85rem;
    border-radius: var(--radius-full);
    font-size: 0.86rem;
    font-weight: 600;
    color: var(--text-body);
    transition: var(--transition);
    border: 1px solid transparent;
}

.nav-hub-link i {
    font-size: 0.95rem;
    color: var(--text-muted);
    transition: var(--transition);
}

.nav-hub-link:hover {
    background: var(--primary-light);
    color: var(--primary);
    border-color: var(--border);
}

.nav-hub-link:hover i {
    color: var(--primary);
}

.nav-hub-link.active {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: #ffffff;
    box-shadow: 0 4px 12px rgba(147, 51, 234, 0.28);
}

.nav-hub-link.active i {
    color: #ffffff;
}

.mobile-nav-divider,
.mobile-logout-btn {
    display: none;
}

/* Perfil y Badge de Usuario */
.user-menu-area {
    position: relative;
    flex-shrink: 0;
}

.user-badge {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.4rem 0.85rem 0.4rem 0.45rem;
    border-radius: var(--radius-full);
    background: #ffffff;
    border: 1.5px solid var(--border);
    cursor: pointer;
    transition: var(--transition);
    user-select: none;
}

.user-badge:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-sm);
}

.avatar-circle {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary) 0%, var(--rose) 100%);
    color: #ffffff;
    font-weight: 700;
    font-size: 0.92rem;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 6px rgba(147, 51, 234, 0.25);
}

.user-text-info {
    display: flex;
    flex-direction: column;
    text-align: left;
    line-height: 1.15;
}

.user-name {
    font-size: 0.86rem;
    font-weight: 700;
    color: var(--text-main);
    max-width: 130px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.user-role {
    font-size: 0.7rem;
    color: var(--text-muted);
}

.dropdown-arrow {
    font-size: 0.72rem;
    color: var(--text-muted);
    transition: var(--transition);
}

.user-badge:hover .dropdown-arrow {
    color: var(--primary);
}

/* Menú Desplegable */
.user-dropdown-menu {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    width: 260px;
    background: #ffffff;
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
    box-shadow: var(--shadow-lg);
    padding: 0.6rem;
    display: none;
    flex-direction: column;
    gap: 0.2rem;
    z-index: 1100;
    animation: fadeInDown 0.2s ease-out;
}

.user-dropdown-menu.show {
    display: flex;
}

.dropdown-header {
    padding: 0.6rem 0.8rem;
    background: var(--primary-light);
    border-radius: var(--radius-sm);
    margin-bottom: 0.4rem;
}

.dropdown-header strong {
    display: block;
    font-size: 0.84rem;
    color: var(--primary-dark);
    word-break: break-all;
}

.dropdown-header small {
    font-size: 0.72rem;
    color: var(--text-muted);
}

.dropdown-item {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.6rem 0.8rem;
    font-size: 0.84rem;
    font-weight: 600;
    color: var(--text-body);
    border-radius: var(--radius-sm);
    transition: var(--transition);
    width: 100%;
    text-align: left;
}

.dropdown-item i {
    font-size: 0.95rem;
    color: var(--text-muted);
    width: 18px;
    text-align: center;
}

.dropdown-item:hover {
    background: var(--primary-subtle);
    color: var(--primary);
}

.dropdown-item:hover i {
    color: var(--primary);
}

.dropdown-divider {
    height: 1px;
    background: var(--border-light);
    margin: 0.3rem 0;
}

.dropdown-item.logout {
    color: var(--rose-dark);
}

.dropdown-item.logout:hover {
    background: var(--rose-light);
    color: var(--rose);
}

.dropdown-item.logout:hover i {
    color: var(--rose);
}

/* ==========================================================================
   2. BANNER DE VERSÍCULO BÍBLICO & ESTADO DE NUBE
   ========================================================================== */
.verse-banner {
    background: linear-gradient(135deg, #ffffff 0%, #faf5ff 50%, #fff1f2 100%);
    border-bottom: 1px solid var(--border);
    padding: 0.85rem 1.5rem;
}

.verse-container {
    max-width: 1320px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 1.25rem;
    justify-content: space-between;
}

.verse-pill-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.35rem 0.85rem;
    background: rgba(147, 51, 234, 0.1);
    color: var(--primary-dark);
    border-radius: var(--radius-full);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    flex-shrink: 0;
    border: 1px solid rgba(147, 51, 234, 0.16);
}

.verse-content {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
}

.verse-quote {
    font-family: 'Playfair Display', Georgia, serif;
    font-style: italic;
    font-size: 0.98rem;
    color: #4a044e;
    line-height: 1.45;
    flex: 1;
    min-width: 260px;
}

.verse-meta {
    display: inline-flex;
    align-items: center;
    gap: 0.65rem;
    flex-shrink: 0;
}

.verse-ref {
    font-weight: 700;
    font-size: 0.82rem;
    color: var(--rose-dark);
}

.verse-tag {
    font-size: 0.72rem;
    background: #ffffff;
    border: 1px solid var(--border);
    padding: 0.2rem 0.6rem;
    border-radius: var(--radius-full);
    color: var(--text-muted);
    font-weight: 600;
}

.btn-verse-refresh {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: #ffffff;
    border: 1px solid var(--border);
    color: var(--primary);
    font-size: 0.8rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.btn-verse-refresh:hover {
    background: var(--primary);
    color: #ffffff;
    transform: rotate(180deg);
}

/* ==========================================================================
   3. CONTENEDOR PRINCIPAL
   ========================================================================== */
.menopause-main-container {
    max-width: 1320px;
    width: 100%;
    margin: 0 auto;
    padding: 2rem 1.5rem 5rem 1.5rem;
    flex: 1;
}

/* ==========================================================================
   4. HERO CARD & SELECTOR DE FASES
   ========================================================================== */
.menopause-hero-card {
    background: linear-gradient(135deg, #ffffff 0%, #faf5ff 60%, #fff5f7 100%);
    border-radius: var(--radius-xl);
    border: 1.5px solid var(--border);
    padding: 2.25rem 2.25rem 2rem 2.25rem;
    box-shadow: var(--shadow-md);
    margin-bottom: 2rem;
    position: relative;
    overflow: hidden;
}

.menopause-hero-card::before {
    content: '';
    position: absolute;
    top: -80px;
    right: -80px;
    width: 240px;
    height: 240px;
    background: radial-gradient(circle, rgba(147, 51, 234, 0.12) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}

.hero-top-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.4rem 1rem;
    background: #ffffff;
    border: 1.5px solid rgba(147, 51, 234, 0.25);
    border-radius: var(--radius-full);
    color: var(--primary-dark);
    font-size: 0.75rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    margin-bottom: 0.85rem;
    box-shadow: var(--shadow-sm);
}

.hero-title {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 2.15rem;
    font-weight: 700;
    color: #3b0764;
    line-height: 1.25;
    margin-bottom: 0.75rem;
}

.hero-desc {
    font-size: 1rem;
    color: var(--text-body);
    max-width: 860px;
    line-height: 1.6;
    margin-bottom: 2rem;
}

/* Selector de Fases (3 Tarjetas) */
.stage-selector-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.25rem;
    margin-bottom: 1.75rem;
}

.stage-card {
    background: #ffffff;
    border: 2px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.35rem 1.25rem;
    cursor: pointer;
    transition: var(--transition);
    position: relative;
    display: flex;
    flex-direction: column;
}

.stage-card:hover {
    transform: translateY(-4px);
    border-color: var(--primary);
    box-shadow: var(--shadow-hover);
}

.stage-card.active {
    background: linear-gradient(180deg, #ffffff 0%, var(--primary-light) 100%);
    border-color: var(--primary);
    box-shadow: 0 10px 24px rgba(147, 51, 234, 0.18);
}

.stage-card.active::after {
    content: '✓ Activa';
    position: absolute;
    top: 14px;
    right: 14px;
    font-size: 0.72rem;
    font-weight: 800;
    background: var(--primary);
    color: #ffffff;
    padding: 0.2rem 0.55rem;
    border-radius: var(--radius-full);
}

.stage-badge {
    display: inline-block;
    align-self: flex-start;
    padding: 0.25rem 0.65rem;
    border-radius: var(--radius-full);
    font-size: 0.72rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    margin-bottom: 0.6rem;
}

.stage-badge-peri {
    background: var(--primary-subtle);
    color: var(--primary-dark);
}

.stage-badge-meno {
    background: var(--rose-light);
    color: var(--rose-dark);
}

.stage-badge-post {
    background: var(--teal-light);
    color: var(--teal-dark);
}

.stage-name {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 1.35rem;
    color: var(--text-main);
    margin-bottom: 0.25rem;
}

.stage-time {
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--gold-dark);
    margin-bottom: 0.65rem;
}

.stage-summary {
    font-size: 0.85rem;
    color: var(--text-muted);
    line-height: 1.5;
    flex: 1;
}

/* Barra de Acción Hero */
.hero-action-bar {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    padding-top: 0.5rem;
}

.btn-hero-test {
    display: inline-flex;
    align-items: center;
    gap: 0.65rem;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: #ffffff;
    padding: 0.85rem 1.6rem;
    border-radius: var(--radius-full);
    font-size: 0.94rem;
    font-weight: 700;
    box-shadow: 0 6px 18px rgba(147, 51, 234, 0.32);
    transition: var(--transition);
}

.btn-hero-test:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 24px rgba(147, 51, 234, 0.42);
    background: linear-gradient(135deg, #a855f7 0%, var(--primary) 100%);
}

/* ==========================================================================
   5. NAVEGACIÓN POR PESTAÑAS
   ========================================================================== */
.module-tabs-nav {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 2rem;
    overflow-x: auto;
    padding-bottom: 0.5rem;
    scrollbar-width: thin;
}

.module-tabs-nav::-webkit-scrollbar {
    height: 4px;
}

.module-tabs-nav::-webkit-scrollbar-thumb {
    background: var(--border);
    border-radius: var(--radius-full);
}

.module-tab-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.75rem 1.35rem;
    background: #ffffff;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-full);
    font-size: 0.92rem;
    font-weight: 700;
    color: var(--text-body);
    transition: var(--transition);
    white-space: nowrap;
    flex-shrink: 0;
}

.module-tab-btn i {
    font-size: 1rem;
    color: var(--text-muted);
    transition: var(--transition);
}

.module-tab-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
    background: var(--primary-light);
}

.module-tab-btn:hover i {
    color: var(--primary);
}

.module-tab-btn.active {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: #ffffff;
    border-color: var(--primary);
    box-shadow: 0 6px 18px rgba(147, 51, 234, 0.28);
}

.module-tab-btn.active i {
    color: #ffffff;
}

/* Paneles de Contenido */
.tab-pane {
    display: none;
    animation: fadeIn 0.3s ease-out;
}

.tab-pane.active {
    display: block;
}

.pane-header-box {
    margin-bottom: 1.75rem;
}

.pane-header-box h2 {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 1.85rem;
    font-weight: 700;
    color: #3b0764;
    line-height: 1.25;
    margin-bottom: 0.4rem;
}

.pane-header-box p {
    font-size: 0.98rem;
    color: var(--text-muted);
}

/* ==========================================================================
   6. PESTAÑA 1: COMPARATIVA CLÍNICA & RED FLAGS
   ========================================================================== */
.phases-comparison-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.phase-detail-card {
    background: #ffffff;
    border-radius: var(--radius-xl);
    border: 1.5px solid var(--border);
    padding: 1.75rem;
    box-shadow: var(--shadow-sm);
    display: flex;
    flex-direction: column;
    gap: 1rem;
    transition: var(--transition);
}

.phase-detail-card:hover {
    box-shadow: var(--shadow-md);
}

.phase-detail-card.peri-side {
    border-top: 5px solid var(--primary);
}

.phase-detail-card.meno-side {
    border-top: 5px solid var(--rose);
}

.phase-detail-header {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.phase-chip {
    display: inline-block;
    align-self: flex-start;
    padding: 0.25rem 0.75rem;
    border-radius: var(--radius-full);
    font-size: 0.74rem;
    font-weight: 800;
    text-transform: uppercase;
}

.chip-peri {
    background: var(--primary-subtle);
    color: var(--primary-dark);
}

.chip-meno {
    background: var(--rose-subtle);
    color: var(--rose-dark);
}

.phase-detail-header h3 {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 1.45rem;
    color: var(--text-main);
}

.phase-definition {
    font-size: 0.92rem;
    color: var(--text-body);
    line-height: 1.6;
    margin-bottom: 1.15rem;
}

.phase-detail-body h4 {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text-main);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin: 1rem 0 0.6rem 0;
}

.phase-detail-body h4 i {
    color: var(--primary);
}

.clean-bullet-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
    margin-bottom: 1.15rem;
}

.clean-bullet-list li {
    font-size: 0.88rem;
    line-height: 1.5;
    position: relative;
    padding-left: 1.25rem;
    color: var(--text-body);
}

.clean-bullet-list li::before {
    content: '•';
    position: absolute;
    left: 0.35rem;
    color: var(--primary);
    font-size: 1.1rem;
    line-height: 1;
}

.clinical-box {
    border-radius: var(--radius-md);
    padding: 1rem 1.15rem;
    font-size: 0.86rem;
    line-height: 1.5;
    margin: 1rem 0;
}

.clinical-box.info {
    background: #fdf4ff;
    border: 1px solid #f0abfc;
    color: #701a75;
}

.clinical-box.success {
    background: #ecfdf5;
    border: 1px solid #a7f3d0;
    color: #065f46;
}

/* Alerta de Señales Rojas (Red Flags) */
.red-flags-alert-card {
    background: linear-gradient(135deg, #fff1f2 0%, #fff7ed 100%);
    border: 1.5px solid #fecdd3;
    border-radius: var(--radius-xl);
    padding: 1.5rem 1.75rem;
    display: flex;
    gap: 1.25rem;
    align-items: flex-start;
    box-shadow: var(--shadow-sm);
}

.red-flags-icon {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--rose);
    color: #ffffff;
    font-size: 1.35rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(225, 29, 72, 0.28);
}

.red-flags-text h4 {
    font-size: 1.1rem;
    font-weight: 800;
    color: #881337;
    margin-bottom: 0.4rem;
}

.red-flags-text p {
    font-size: 0.9rem;
    color: #4c0519;
    margin-bottom: 0.85rem;
}

.flags-pills-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
}

.flag-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    background: #ffffff;
    border: 1px solid #fda4af;
    padding: 0.35rem 0.85rem;
    border-radius: var(--radius-full);
    font-size: 0.8rem;
    font-weight: 700;
    color: #9f1239;
}

/* ==========================================================================
   7. PESTAÑA 2: DIRECTORIO DE SÍNTOMAS
   ========================================================================== */
.symptoms-control-bar {
    background: #ffffff;
    border-radius: var(--radius-lg);
    border: 1.5px solid var(--border);
    padding: 1.15rem 1.25rem;
    box-shadow: var(--shadow-sm);
    margin-bottom: 1.75rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.search-input-wrap {
    position: relative;
    width: 100%;
}

.search-input-wrap i {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 1rem;
}

.search-input-wrap input {
    width: 100%;
    padding: 0.75rem 1rem 0.75rem 2.75rem;
    background: var(--bg-page);
    border: 1.5px solid var(--border);
    border-radius: var(--radius-full);
    font-size: 0.92rem;
    color: var(--text-main);
    transition: var(--transition);
}

.search-input-wrap input:focus {
    outline: none;
    border-color: var(--primary);
    background: #ffffff;
    box-shadow: 0 0 0 3px var(--primary-glow);
}

.category-pills-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.cat-pill {
    padding: 0.4rem 0.95rem;
    background: #ffffff;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-full);
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--text-body);
    transition: var(--transition);
}

.cat-pill:hover {
    border-color: var(--primary);
    color: var(--primary);
    background: var(--primary-light);
}

.cat-pill.active {
    background: var(--primary);
    color: #ffffff;
    border-color: var(--primary);
    box-shadow: 0 2px 8px rgba(147, 51, 234, 0.25);
}

/* Grid de Síntomas */
.symptoms-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 1.25rem;
}

.symptom-card {
    background: #ffffff;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.35rem;
    box-shadow: var(--shadow-sm);
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.symptom-card:hover {
    transform: translateY(-4px);
    border-color: var(--primary);
    box-shadow: var(--shadow-hover);
}

.symptom-card-top {
    display: flex;
    align-items: flex-start;
    gap: 0.9rem;
    margin-bottom: 0.75rem;
}

.symptom-icon-box {
    width: 44px;
    height: 44px;
    border-radius: var(--radius-md);
    background: var(--primary-subtle);
    color: var(--primary-dark);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    flex-shrink: 0;
}

.symptom-name {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--text-main);
    line-height: 1.3;
}

.symptom-badge-phase {
    display: inline-block;
    padding: 0.2rem 0.55rem;
    border-radius: var(--radius-full);
    font-size: 0.7rem;
    font-weight: 800;
    text-transform: uppercase;
    margin-top: 0.25rem;
}

.phase-peri {
    background: var(--primary-subtle);
    color: var(--primary-dark);
}

.phase-meno {
    background: var(--rose-subtle);
    color: var(--rose-dark);
}

.phase-both {
    background: #f1f5f9;
    color: #475569;
}

.symptom-brief {
    font-size: 0.88rem;
    color: var(--text-muted);
    line-height: 1.5;
    margin-bottom: 1rem;
    flex: 1;
}

.symptom-footer-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 0.75rem;
    border-top: 1px solid var(--border-light);
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--primary);
}

.symptom-footer-row i {
    transition: var(--transition);
}

.symptom-card:hover .symptom-footer-row i {
    transform: translateX(4px);
}

/* ==========================================================================
   8. PESTAÑA 3: REMEDIOS NATURALES & OMS
   ========================================================================== */
.remedies-filter-bar {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    margin-bottom: 1.75rem;
    flex-wrap: wrap;
}

.remedy-tab-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 1.15rem;
    background: #ffffff;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-full);
    font-size: 0.86rem;
    font-weight: 700;
    color: var(--text-body);
    transition: var(--transition);
}

.remedy-tab-pill:hover {
    border-color: var(--teal);
    color: var(--teal-dark);
    background: var(--teal-light);
}

.remedy-tab-pill.active {
    background: var(--teal);
    color: #ffffff;
    border-color: var(--teal);
    box-shadow: 0 4px 12px rgba(13, 148, 136, 0.28);
}

.remedies-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 1.35rem;
    margin-bottom: 2.25rem;
}

.remedy-card {
    background: #ffffff;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.45rem;
    box-shadow: var(--shadow-sm);
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
    transition: var(--transition);
}

.remedy-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
    border-color: var(--teal);
}

.remedy-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.75rem;
}

.remedy-badge-evidence {
    display: inline-block;
    padding: 0.25rem 0.65rem;
    border-radius: var(--radius-full);
    font-size: 0.72rem;
    font-weight: 800;
    text-transform: uppercase;
}

.evidence-who {
    background: #e0f2fe;
    color: #0369a1;
    border: 1px solid #bae6fd;
}

.evidence-clinical {
    background: #f0fdf4;
    color: #15803d;
    border: 1px solid #bbf7d0;
}

.evidence-herbal {
    background: #fefce8;
    color: #854d0e;
    border: 1px solid #fef08a;
}

.remedy-title {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 1.3rem;
    color: var(--text-main);
    line-height: 1.25;
}

.remedy-target {
    font-size: 0.86rem;
    color: var(--primary-dark);
    font-weight: 700;
}

.remedy-mechanism {
    font-size: 0.88rem;
    color: var(--text-body);
    line-height: 1.55;
}

.remedy-caution {
    background: #fff7ed;
    border: 1px solid #fed7aa;
    border-radius: var(--radius-sm);
    padding: 0.65rem 0.85rem;
    font-size: 0.8rem;
    color: #9a3412;
    line-height: 1.4;
}

/* Spotlight de Paced Breathing */
.paced-breathing-spotlight {
    background: linear-gradient(135deg, #0f172a 0%, #1e1b4b 60%, #311042 100%);
    border-radius: var(--radius-xl);
    padding: 2.25rem;
    color: #ffffff;
    box-shadow: var(--shadow-lg);
    position: relative;
    overflow: hidden;
}

.spotlight-content {
    max-width: 820px;
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
}

.spotlight-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    background: rgba(255, 255, 255, 0.15);
    padding: 0.3rem 0.75rem;
    border-radius: var(--radius-full);
    font-size: 0.76rem;
    font-weight: 800;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    align-self: flex-start;
}

.spotlight-content h3 {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 1.75rem;
    color: #f8fafc;
}

.spotlight-content p {
    font-size: 0.95rem;
    color: #cbd5e1;
    line-height: 1.6;
}

.btn-primary-action {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: #ffffff;
    padding: 0.8rem 1.5rem;
    border-radius: var(--radius-full);
    font-size: 0.92rem;
    font-weight: 700;
    box-shadow: 0 4px 14px rgba(147, 51, 234, 0.35);
    transition: var(--transition);
    align-self: flex-start;
    margin-top: 0.5rem;
}

.btn-primary-action:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(147, 51, 234, 0.45);
}

.btn-secondary-action {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    background: #f1f5f9;
    color: var(--text-body);
    padding: 0.8rem 1.35rem;
    border-radius: var(--radius-full);
    font-size: 0.92rem;
    font-weight: 700;
    transition: var(--transition);
}

.btn-secondary-action:hover {
    background: #e2e8f0;
}

/* ==========================================================================
   9. PESTAÑA 4: TRACKER DIARIO & RESPIRACIÓN EN VIVO
   ========================================================================== */
.wellness-dashboard-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

.wellness-col {
    display: flex;
    flex-direction: column;
    gap: 1.35rem;
}

.tracker-box {
    background: #ffffff;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.35rem;
    box-shadow: var(--shadow-sm);
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
}

.tracker-box-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.tracker-box-header h4,
.tracker-box > h4 {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--text-main);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.tracker-box-header small {
    font-size: 0.78rem;
    color: var(--text-muted);
}

.tracker-big-num {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary);
    line-height: 1;
}

.water-liters-badge {
    font-size: 1.15rem;
    font-weight: 800;
    color: #0284c7;
    background: #f0f9ff;
    padding: 0.35rem 0.85rem;
    border-radius: var(--radius-full);
    border: 1px solid #bae6fd;
}

.tracker-actions-row {
    display: flex;
    align-items: center;
    gap: 0.65rem;
}

.btn-counter-sub,
.btn-counter-add {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.65rem 1.15rem;
    border-radius: var(--radius-full);
    font-weight: 700;
    font-size: 0.88rem;
    transition: var(--transition);
}

.btn-counter-sub {
    background: var(--bg-page);
    border: 1.5px solid var(--border);
    color: var(--text-body);
    width: 42px;
    height: 42px;
    padding: 0;
}

.btn-counter-sub:hover {
    background: var(--rose-light);
    color: var(--rose);
    border-color: #fecdd3;
}

.btn-counter-add {
    flex: 1;
    background: linear-gradient(135deg, var(--rose) 0%, var(--rose-dark) 100%);
    color: #ffffff;
    box-shadow: 0 4px 12px rgba(225, 29, 72, 0.28);
}

.btn-counter-add:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(225, 29, 72, 0.38);
}

/* Vasos de Agua */
.water-cups-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.4rem;
    padding: 0.5rem 0;
}

.water-cup-btn {
    flex: 1;
    aspect-ratio: 1;
    max-width: 48px;
    border-radius: 12px;
    background: var(--bg-page);
    border: 1.5px solid var(--border);
    color: var(--text-muted);
    font-size: 1.15rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.water-cup-btn:hover {
    border-color: #38bdf8;
    color: #0284c7;
    background: #f0f9ff;
    transform: translateY(-2px);
}

.water-cup-btn.filled {
    background: linear-gradient(135deg, #0284c7 0%, #0369a1 100%);
    color: #ffffff;
    border-color: #0284c7;
    box-shadow: 0 4px 10px rgba(2, 132, 199, 0.28);
}

/* Suplementos Checklist */
.checklist-items {
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
}

.check-item-label {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 0.75rem 0.9rem;
    background: var(--bg-page);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: var(--transition);
}

.check-item-label:hover {
    background: #ffffff;
    border-color: var(--primary);
    box-shadow: var(--shadow-sm);
}

.check-item-label input[type="checkbox"] {
    width: 20px;
    height: 20px;
    accent-color: var(--primary);
    margin-top: 2px;
    cursor: pointer;
}

.check-item-label div {
    display: flex;
    flex-direction: column;
}

.check-item-label strong {
    font-size: 0.88rem;
    color: var(--text-main);
}

.check-item-label span {
    font-size: 0.76rem;
    color: var(--text-muted);
}

/* Minutos de Ejercicio */
.btn-chip-action {
    padding: 0.55rem 0.95rem;
    background: var(--bg-page);
    border: 1.5px solid var(--border);
    border-radius: var(--radius-full);
    font-size: 0.84rem;
    font-weight: 700;
    color: var(--text-body);
    transition: var(--transition);
}

.btn-chip-action:hover {
    background: var(--gold-light);
    color: var(--gold-dark);
    border-color: #fde68a;
}

.btn-chip-action.reset {
    color: var(--rose-dark);
}

.btn-chip-action.reset:hover {
    background: var(--rose-light);
    border-color: #fecdd3;
}

/* Entrenador de Respiración Paced */
.breathing-card {
    background: linear-gradient(135deg, #1e1b4b 0%, #311042 100%);
    border-radius: var(--radius-lg);
    padding: 1.75rem;
    color: #ffffff;
    box-shadow: var(--shadow-md);
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.breathing-header {
    display: flex;
    align-items: center;
    gap: 0.85rem;
}

.breathing-icon-box {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    color: #e0e7ff;
}

.breathing-header h3 {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 1.25rem;
    color: #ffffff;
}

.breathing-header p {
    font-size: 0.78rem;
    color: #cbd5e1;
}

.breathing-trainer-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem 0;
}

.breathing-circle-outer {
    width: 170px;
    height: 170px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.05);
    border: 2px dashed rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.4s ease;
}

.breathing-circle-inner {
    width: 135px;
    height: 135px;
    border-radius: 50%;
    background: radial-gradient(circle, #a855f7 0%, #6b21a8 100%);
    box-shadow: 0 0 24px rgba(168, 85, 247, 0.4);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    text-align: center;
    transition: transform 1s ease, box-shadow 1s ease, background 1s ease;
    user-select: none;
}

.breathing-circle-inner.inhale {
    transform: scale(1.30);
    background: radial-gradient(circle, #d946ef 0%, #7e22ce 100%);
    box-shadow: 0 0 45px rgba(217, 70, 239, 0.7), 0 0 80px rgba(147, 51, 234, 0.4);
    transition: transform 5s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 5s ease, background 5s ease;
}

.breathing-circle-inner.exhale {
    transform: scale(0.92);
    background: radial-gradient(circle, #7e22ce 0%, #3b0764 100%);
    box-shadow: 0 0 20px rgba(126, 34, 206, 0.35);
    transition: transform 5s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 5s ease, background 5s ease;
}

.btn-breathing-toggle.active {
    background: linear-gradient(135deg, #be123c 0%, #9f1239 100%) !important;
    box-shadow: 0 4px 14px rgba(190, 18, 60, 0.45) !important;
}

.breathing-counter {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 2.25rem;
    font-weight: 700;
    line-height: 1;
    color: #ffffff;
}

.breathing-cue {
    font-size: 0.74rem;
    color: #f1f5f9;
    margin-top: 0.35rem;
    line-height: 1.25;
}

.breathing-controls {
    display: flex;
    justify-content: center;
}

.btn-breathing-toggle {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    padding: 0.8rem 1.6rem;
    background: linear-gradient(135deg, #a855f7 0%, var(--primary) 100%);
    color: #ffffff;
    border-radius: var(--radius-full);
    font-weight: 700;
    font-size: 0.9rem;
    box-shadow: 0 4px 14px rgba(168, 85, 247, 0.35);
    transition: var(--transition);
}

.btn-breathing-toggle:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(168, 85, 247, 0.45);
}

/* Síntomas Hoy */
.today-symptoms-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
}

.empty-hint {
    font-size: 0.84rem;
    color: var(--text-muted);
    font-style: italic;
}

.symptom-tag-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.35rem 0.75rem;
    background: var(--primary-subtle);
    color: var(--primary-dark);
    border-radius: var(--radius-full);
    font-size: 0.8rem;
    font-weight: 700;
}

/* Card Reporte Médico */
.doctor-report-card {
    background: linear-gradient(135deg, #ffffff 0%, var(--primary-light) 100%);
    border: 1.5px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.45rem;
    display: flex;
    gap: 1.15rem;
    align-items: flex-start;
    box-shadow: var(--shadow-sm);
}

.doctor-report-icon {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    background: var(--primary-subtle);
    color: var(--primary-dark);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.35rem;
    flex-shrink: 0;
}

.doctor-report-card h4 {
    font-size: 1.05rem;
    color: var(--text-main);
    margin-bottom: 0.25rem;
}

.doctor-report-card p {
    font-size: 0.85rem;
    color: var(--text-muted);
    line-height: 1.5;
    margin-bottom: 0.95rem;
}

.btn-doctor-report {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.65rem 1.25rem;
    background: #0f172a;
    color: #ffffff;
    border-radius: var(--radius-full);
    font-size: 0.86rem;
    font-weight: 700;
    transition: var(--transition);
}

.btn-doctor-report:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.25);
}

/* ==========================================================================
   10. MODALES (VENTANAS EMERGENTES FLOTANTES)
   ========================================================================== */
.menopause-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(15, 23, 42, 0.72);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 999999;
    padding: 1.5rem;
    display: none; /* OCULTO POR DEFECTO */
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease, visibility 0.25s ease;
}

.menopause-modal.show {
    display: flex !important;
    opacity: 1;
    visibility: visible;
}

.modal-card {
    background: #ffffff;
    border-radius: var(--radius-xl);
    width: 100%;
    max-width: 600px;
    max-height: 90vh;
    overflow-y: auto;
    padding: 2.25rem;
    position: relative;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.35);
    border: 1px solid var(--border);
    animation: modalPop 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.modal-close-btn {
    position: absolute;
    top: 1.25rem;
    right: 1.25rem;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #f1f5f9;
    color: var(--text-muted);
    font-size: 1.15rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    z-index: 10;
}

.modal-close-btn:hover {
    background: var(--rose-light);
    color: var(--rose);
    transform: rotate(90deg);
}

.modal-header-area {
    margin-bottom: 1.5rem;
}

.modal-pill-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.3rem 0.75rem;
    background: var(--primary-subtle);
    color: var(--primary-dark);
    border-radius: var(--radius-full);
    font-size: 0.75rem;
    font-weight: 800;
    text-transform: uppercase;
    margin-bottom: 0.65rem;
}

.modal-header-area h3 {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 1.65rem;
    color: var(--text-main);
    line-height: 1.25;
    margin-bottom: 0.4rem;
}

.modal-header-area p {
    font-size: 0.9rem;
    color: var(--text-muted);
}

/* Formulario del Test */
.test-form {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
}

.form-group label {
    font-size: 0.88rem;
    font-weight: 700;
    color: var(--text-main);
    display: flex;
    align-items: center;
    gap: 0.45rem;
}

.form-group label i {
    color: var(--primary);
}

.form-input {
    width: 100%;
    padding: 0.8rem 1rem;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-md);
    background: var(--bg-page);
    font-size: 0.92rem;
    color: var(--text-main);
    transition: var(--transition);
}


select.form-input {
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%239333ea' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    background-size: 1.1em;
    padding-right: 2.5rem;
    cursor: pointer;
}

.form-input:focus {
    outline: none;
    border-color: var(--primary);
    background: #ffffff;
    box-shadow: 0 0 0 3px var(--primary-glow);
}

.form-footer {
    display: flex;
    justify-content: flex-end;
    margin-top: 0.5rem;
}

/* ==========================================================================
   11. PIE DE PÁGINA (FOOTER) - IMAGEN PROTEGIDA
   ========================================================================== */
.menopause-footer {
    background: #ffffff;
    border-top: 1px solid var(--border);
    padding: 2.25rem 1.5rem;
    margin-top: auto;
}

.footer-inner {
    max-width: 1320px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 1rem;
}

/* CRÍTICO: Tamaño fijo y controlado del logo en footer */
.footer-logo {
    width: 48px;
    height: 48px;
    max-width: 48px;
    max-height: 48px;
    object-fit: contain;
    border-radius: 12px;
    background: #ffffff;
    padding: 4px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    flex-shrink: 0;
}

.footer-brand strong {
    display: block;
    font-size: 0.98rem;
    color: var(--text-main);
}

.footer-brand p {
    font-size: 0.82rem;
    color: var(--text-muted);
}

.footer-disclaimer {
    border-top: 1px solid var(--border-light);
    padding-top: 1rem;
    font-size: 0.78rem;
    color: var(--text-muted);
    line-height: 1.5;
}

/* Toast de Notificación */
.toast-box {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    background: #0f172a;
    color: #ffffff;
    padding: 0.85rem 1.45rem;
    border-radius: var(--radius-full);
    font-size: 0.9rem;
    font-weight: 700;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
    z-index: 1000000;
    display: none;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.3s ease;
}

.toast-box.show {
    display: block;
    opacity: 1;
    transform: translateY(0);
}

/* ==========================================================================
   12. RESPONSIVIDAD (TABLET & MOBILE)
   ========================================================================== */

/* Tablets & Pantallas Medianas (< 1024px) */
@media (max-width: 1024px) {
    .stage-selector-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 0.9rem;
    }
    
    .phases-comparison-grid,
    .wellness-dashboard-grid {
        grid-template-columns: 1fr;
    }

    .hero-title {
        font-size: 1.85rem;
    }
}

/* Dispositivos Móviles (< 768px) */
@media (max-width: 768px) {
    .header-container {
        padding: 0.65rem 1rem;
    }

    .mobile-nav-toggle {
        display: flex;
    }

    /* Menú Desplegable Lateral/Drawer para Móvil */
    .nav-hub {
        position: fixed;
        top: 61px;
        left: 0;
        right: 0;
        background: #ffffff;
        border-bottom: 2px solid var(--border);
        flex-direction: column;
        padding: 1.25rem 1rem;
        gap: 0.65rem;
        display: none;
        box-shadow: var(--shadow-lg);
        max-height: calc(100vh - 61px);
        overflow-y: auto;
        z-index: 9999;
    }

    .nav-hub.mobile-open {
        display: flex;
    }

    .nav-hub-link {
        width: 100%;
        justify-content: flex-start;
        padding: 0.75rem 1rem;
        font-size: 0.94rem;
        border-radius: var(--radius-md);
    }

    .mobile-nav-divider {
        display: block;
        width: 100%;
        height: 1px;
        background: var(--border);
        margin: 0.5rem 0;
    }

    .mobile-logout-btn {
        display: inline-flex;
        width: 100%;
        color: var(--rose-dark);
        padding: 0.75rem 1rem;
    }

    .user-text-info {
        display: flex !important;
    }

    .user-badge {
        padding: 0.3rem;
        border: none;
        background: transparent;
    }

    .dropdown-arrow {
        display: none;
    }

    .verse-banner {
        padding: 0.75rem 1rem;
    }

    .verse-container {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }

    .verse-content {
        flex-direction: column;
        align-items: flex-start;
    }

    .menopause-main-container {
        padding: 1.25rem 1rem 6rem 1rem;
    }

    .menopause-hero-card {
        padding: 1.5rem 1.25rem;
        border-radius: var(--radius-lg);
    }

    .hero-title {
        font-size: 1.5rem;
    }

    .hero-desc {
        font-size: 0.92rem;
        margin-bottom: 1.5rem;
    }

    /* En móvil las etapas se apilan verticalmente */
    .stage-selector-grid {
        grid-template-columns: 1fr;
        gap: 0.85rem;
    }

    .btn-hero-test {
        width: 100%;
        justify-content: center;
        text-align: center;
    }

    .module-tab-btn {
        padding: 0.65rem 1.1rem;
        font-size: 0.84rem;
    }

    .symptoms-grid,
    .remedies-grid {
        grid-template-columns: 1fr;
    }

    .red-flags-alert-card {
        flex-direction: column;
        padding: 1.25rem;
    }

    .breathing-card {
        padding: 1.35rem;
    }

    .breathing-circle-outer {
        width: 140px;
        height: 140px;
    }

    .breathing-circle-inner {
        width: 110px;
        height: 110px;
    }

    .breathing-counter {
        font-size: 1.85rem;
    }

    .modal-card {
        padding: 1.5rem 1.25rem;
        border-radius: var(--radius-lg);
    }

    .water-cups-row {
        gap: 0.25rem;
    }

    .water-cup-btn {
        font-size: 0.95rem;
    }

    .toast-box {
        bottom: 5.5rem;
        right: 1rem;
        left: 1rem;
        text-align: center;
    }
}

/* Animaciones */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(6px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeInDown {
    from { opacity: 0; transform: translateY(-8px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes modalPop {
    from { opacity: 0; transform: scale(0.92); }
    to { opacity: 1; transform: scale(1); }
}

@media print {
    .no-print, .main-header, .verse-banner, .module-tabs-nav, .mobile-bottom-nav, .menopause-footer {
        display: none !important;
    }
}


/* ==========================================================================
   BARRA DE NAVEGACIÓN DE FECHAS (TRACKER DIARIO)
   ========================================================================== */
.tracker-date-bar {
    background: #ffffff;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    padding: 0.85rem 1.25rem;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
    transition: var(--transition);
}

.tracker-date-bar:hover {
    box-shadow: var(--shadow-md);
}

.date-bar-left, .date-bar-right {
    display: flex;
    align-items: center;
}

.btn-date-nav {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.55rem 1.1rem;
    border-radius: 999px;
    background: #f8fafc;
    border: 1px solid var(--border);
    color: var(--text-dark);
    font-size: 0.86rem;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
}

.btn-date-nav:hover {
    background: #f3e8ff;
    border-color: #d8b4fe;
    color: var(--primary);
    transform: translateY(-1px);
}

.date-bar-center {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
    justify-content: center;
}

.date-badge-box {
    display: inline-flex;
    align-items: center;
    gap: 0.65rem;
    background: linear-gradient(135deg, #faf5ff 0%, #fdf4ff 100%);
    border: 1.5px solid #e9d5ff;
    padding: 0.55rem 1.25rem;
    border-radius: 999px;
    position: relative;
    cursor: pointer;
    box-shadow: 0 2px 4px rgba(147, 51, 234, 0.05);
}

.tracker-date-label {
    font-size: 0.95rem;
    font-weight: 800;
    color: #581c87;
    letter-spacing: -0.01em;
}

.tracker-date-native-picker {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
}

.btn-date-today {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    background: #e11d48;
    color: #ffffff;
    border: none;
    border-radius: 999px;
    padding: 0.45rem 0.9rem;
    font-size: 0.78rem;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: 0 2px 6px rgba(225, 29, 72, 0.25);
}

.btn-date-today:hover {
    background: #be123c;
    transform: translateY(-1px);
}

/* ==========================================================================
   TARJETA Y BASE DE DATOS DEL HISTORIAL CLIMATÉRICO
   ========================================================================== */
.menopause-history-card {
    background: #ffffff;
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-sm);
    padding: 1.85rem;
    margin-top: 2rem;
    position: relative;
    overflow: hidden;
}

.menopause-history-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #9333ea, #e11d48, #d946ef);
}

.history-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1.25rem;
    padding-bottom: 1.25rem;
    border-bottom: 1px solid var(--border);
    margin-bottom: 1.5rem;
}

.history-card-title-group {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.history-icon-badge {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    background: linear-gradient(135deg, #f3e8ff 0%, #fae8ff 100%);
    color: #9333ea;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.35rem;
    flex-shrink: 0;
    border: 1px solid #e9d5ff;
}

.history-card-title {
    font-family: 'Playfair Display', serif;
    font-size: 1.35rem;
    font-weight: 800;
    color: #0f172a;
    margin: 0;
}

.history-card-subtitle {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin: 0.25rem 0 0 0;
}

.history-actions-row {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.btn-export-backup {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: #f8fafc;
    border: 1px solid #cbd5e1;
    color: #334155;
    padding: 0.6rem 1.1rem;
    border-radius: 999px;
    font-size: 0.82rem;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
}

.btn-export-backup:hover {
    background: #e2e8f0;
    color: #0f172a;
    border-color: #94a3b8;
}

.btn-doctor-report-compact {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: linear-gradient(135deg, #9333ea 0%, #7e22ce 100%);
    color: #ffffff;
    border: none;
    padding: 0.6rem 1.15rem;
    border-radius: 999px;
    font-size: 0.82rem;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: 0 2px 6px rgba(147, 51, 234, 0.25);
}

.btn-doctor-report-compact:hover {
    background: linear-gradient(135deg, #7e22ce 0%, #6b21a8 100%);
    transform: translateY(-1px);
}

/* Banner de Evaluación Clínica Reciente */
.user-last-test-banner {
    margin-bottom: 1.5rem;
}

.last-test-inner-box {
    background: linear-gradient(135deg, #fdf4ff 0%, #faf5ff 100%);
    border: 1.5px solid #f0abfc;
    border-radius: var(--radius-lg);
    padding: 1.25rem 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1.25rem;
    flex-wrap: wrap;
}

.last-test-badge-row {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.4rem;
}

.last-test-badge {
    background: #a21caf;
    color: #ffffff;
    font-size: 0.72rem;
    font-weight: 800;
    padding: 0.2rem 0.65rem;
    border-radius: 999px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.last-test-date {
    font-size: 0.8rem;
    color: #701a75;
    font-weight: 600;
}

.last-test-title {
    font-size: 1.05rem;
    font-weight: 800;
    color: #0f172a;
    margin: 0 0 0.25rem 0;
}

.last-test-desc {
    font-size: 0.86rem;
    color: #475569;
    line-height: 1.5;
    margin: 0;
    max-width: 750px;
}

.btn-repeat-test {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    background: #ffffff;
    border: 1px solid #d946ef;
    color: #a21caf;
    padding: 0.5rem 1rem;
    border-radius: 999px;
    font-size: 0.82rem;
    font-weight: 700;
    cursor: pointer;
    white-space: nowrap;
    transition: var(--transition);
}

.btn-repeat-test:hover {
    background: #fdf4ff;
    border-color: #c026d3;
}

/* Grid de Días Históricos */
.history-filter-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: 1.25rem;
}

.history-filter-bar h4 {
    font-size: 1.05rem;
    font-weight: 800;
    color: #0f172a;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.history-note-hint {
    font-size: 0.8rem;
    color: var(--text-muted);
}

.history-records-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(310px, 1fr));
    gap: 1.15rem;
}

.history-day-card {
    background: #ffffff;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.15rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
}

.history-day-card:hover {
    border-color: #d8b4fe;
    box-shadow: 0 4px 12px rgba(147, 51, 234, 0.08);
    transform: translateY(-2px);
}

.history-day-card.selected-active {
    border-color: #9333ea;
    background: linear-gradient(180deg, #faf5ff 0%, #ffffff 100%);
    box-shadow: 0 0 0 2px #d8b4fe;
}

.history-day-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.85rem;
}

.history-day-date {
    font-size: 0.92rem;
    font-weight: 800;
    color: #0f172a;
}

.history-badge-today {
    background: #e11d48;
    color: #ffffff;
    font-size: 0.68rem;
    font-weight: 800;
    padding: 0.15rem 0.5rem;
    border-radius: 999px;
    text-transform: uppercase;
}

.history-badge-past {
    background: #f1f5f9;
    color: #64748b;
    font-size: 0.7rem;
    font-weight: 700;
    padding: 0.15rem 0.5rem;
    border-radius: 999px;
}

.history-day-stats-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 0.85rem;
}

.history-stat-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.25rem 0.65rem;
    border-radius: 8px;
    font-size: 0.78rem;
    font-weight: 700;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    color: #334155;
}

.history-stat-chip.hot-flash {
    background: #fff1f2;
    border-color: #fecdd3;
    color: #be123c;
}

.history-stat-chip.water {
    background: #f0f9ff;
    border-color: #bae6fd;
    color: #0369a1;
}

.history-stat-chip.exercise {
    background: #fffbeb;
    border-color: #fde68a;
    color: #b45309;
}

.history-supps-row {
    display: flex;
    gap: 0.35rem;
    margin-bottom: 0.85rem;
    flex-wrap: wrap;
}

.supp-pill-tag {
    font-size: 0.72rem;
    padding: 0.15rem 0.5rem;
    border-radius: 999px;
    font-weight: 600;
}

.supp-pill-tag.taken {
    background: #f3e8ff;
    color: #7e22ce;
    border: 1px solid #d8b4fe;
}

.supp-pill-tag.empty {
    background: #f1f5f9;
    color: #94a3b8;
    text-decoration: line-through;
}

.history-symptoms-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
    margin-bottom: 1rem;
    min-height: 24px;
}

.history-symptom-tag {
    background: #fdf4ff;
    border: 1px solid #f0abfc;
    color: #701a75;
    font-size: 0.72rem;
    font-weight: 600;
    padding: 0.15rem 0.55rem;
    border-radius: 999px;
}

.history-day-footer {
    display: flex;
    justify-content: flex-end;
    border-top: 1px dashed var(--border);
    padding-top: 0.75rem;
}

.btn-load-history-day {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    background: #f8fafc;
    border: 1px solid #cbd5e1;
    color: var(--primary);
    padding: 0.4rem 0.85rem;
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
}

.btn-load-history-day:hover {
    background: #f3e8ff;
    border-color: #9333ea;
    color: #7e22ce;
}

.history-empty-state {
    grid-column: 1 / -1;
    text-align: center;
    padding: 2.5rem 1rem;
    background: #f8fafc;
    border: 1.5px dashed var(--border);
    border-radius: var(--radius-lg);
    color: var(--text-muted);
}

.history-empty-state i {
    font-size: 2.5rem;
    color: #d8b4fe;
    margin-bottom: 0.75rem;
    display: block;
}

@media (max-width: 768px) {
    .tracker-date-bar {
        padding: 0.75rem;
        gap: 0.5rem;
    }
    .btn-date-nav span {
        display: none;
    }
    .btn-date-nav {
        padding: 0.5rem 0.75rem;
    }
    .history-card-header {
        flex-direction: column;
        align-items: flex-start;
    }
    .history-actions-row {
        width: 100%;
    }
    .btn-export-backup, .btn-doctor-report-compact {
        width: 100%;
        justify-content: center;
    }
    .history-records-grid {
        grid-template-columns: 1fr;
    }
}
