/* ===== Header depured ===== */
body > header, body.agenda-page > header {
    background: #eff0f1 !important;
    border-bottom: 1px solid #3762b8 !important;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.2) !important;
    position: relative !important;
    z-index: 1000 !important; /* Higher than page content */
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
}

header .headerContainer {
    font-family: 'Inter', sans-serif;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
    width: 100%;
    box-sizing: border-box;
}

header .headerContent {
    display: flex;
    justify-content: space-between;
    align-items: center;
    min-height: 80px;
    height: 80px;
    width: 100%;
    padding: 0.5rem 0;
    flex-wrap: nowrap;
    position: relative;
    z-index: 1001; /* Higher than header */
}

header .logoImage {
    height: 40px;
    width: auto;
    margin: 0.5rem 0;
}

/* Menú móvil */
.menuToggle {
    display: none;
    cursor: pointer;
    padding: 0.5rem;
}

.menuToggle .bar {
    display: block;
    width: 25px;
    height: 3px;
    margin: 5px auto;
    background-color: #2c3e50;
    transition: all 0.3s ease;
}

/* Media Queries para móvil */
@media (max-width: 768px) {
    .menuToggle {
        display: block;
        z-index: 100;
    }

    .menuToggle.active .bar:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }

    .menuToggle.active .bar:nth-child(2) {
        opacity: 0;
    }

    .menuToggle.active .bar:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }

    header .mainNav {
        position: fixed;
        left: -100%;
        top: 0;
        width: 80%;
        height: 100vh;
        background: #eff0f1;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        transition: 0.3s;
        z-index: 99;
        padding: 2rem 0;
        box-shadow: 2px 0 10px rgba(0, 0, 0, 0.1);
    }

    header .mainNav.active {
        left: 0;
    }

    header .navLinks {
        flex-direction: column;
        width: 100%;
        text-align: center;
        gap: 1.5rem;
    }

    header .navItem {
        padding: 0.8rem 0;
        font-size: 1.1rem;
    }

    .overlay {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0, 0, 0, 0.5);
        z-index: 98;
    }

    .overlay.active {
        display: block;
    }
}

header .logoImage:hover {
    transform: scale(1.05) translateY(-2px);
    opacity: 1;
    filter: drop-shadow(0 4px 12px #ffffff66);
}
header .mainNav {
    display: flex;
    align-items: center;
    margin-left: auto;
}

header .navLinks {
    display: flex;
    gap: 2rem;
}

header .navItem {
    position: relative !important;
    text-decoration: none !important;
    color: #2c3e50 !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
    font-size: 0.95rem !important;
    letter-spacing: 1.2px !important;
    border-radius: 5px !important;
    background: transparent !important;
    padding: 0.5rem 1rem !important;
    margin: 0 !important;
    border: none !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    height: 100% !important;
}
body > header .navItem:hover, body.agenda-page > header .navItem:hover {
    color: #3762b8 !important;
    background: rgba(227, 228, 230, 0.4) !important;
    text-shadow: 0 0 15px rgba(255, 255, 255, 0) !important;
    transform: translateY(-2px) !important;
}

header .navItem:hover .navUnderline {
    width: 100%;
}

body > header .navUnderline, body.agenda-page > header .navUnderline {
    position: absolute !important;
    bottom: 0 !important;
    left: 0 !important;
    width: 0 !important;
    height: 2px !important;
    background: linear-gradient(90deg, #005c97, #00a1e0) !important;
    transition: width 0.3s ease !important;
    border-radius: 2px !important;
    border: none !important;
    margin: 0 !important;
    padding: 0 !important;
}

/* Dropdown Menu Styles */
.dropdown {
    position: relative;
    display: inline-block;
    height: 100%;
}

.dropdown > .navLink {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    position: relative;
    color: #2c3e50;
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.dropdown > .navLink .navText {
    position: relative;
    display: flex;
    align-items: center;
    gap: 4px;
}

.dropdown > .navLink .navText::after {
    content: '▼';
    font-size: 0.6em;
    opacity: 0.7;
    transition: transform 0.2s ease;
    margin-left: 4px;
}

.dropdown:hover > .navLink .navText::after {
    transform: rotate(180deg);
}

.dropdown-content {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(0);
    background-color: #fff;
    min-width: 240px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    border-radius: 4px;
    z-index: 2000; /* Higher than header and content */
    opacity: 0;
    visibility: hidden;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(0,0,0,0.1);
    margin-top: 0;
}

.dropdown:hover .dropdown-content,
.dropdown:focus-within .dropdown-content {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

.dropdown-item {
    color: #2c3e50;
    padding: 0.8rem 1.2rem;
    text-decoration: none;
    display: block;
    transition: all 0.2s ease;
    font-size: 0.9rem;
    white-space: nowrap;
    border-left: 3px solid transparent;
    font-weight: 500;
}

.dropdown-item:hover {
    background-color: #f8f9fa;
    color: #0056b3;
    border-left-color: #0056b3;
    padding-left: 1.5rem;
}

/* Hover states for dropdown parent */
.dropdown:hover {
    background: rgba(227, 228, 230, 0.4);
}

.dropdown:hover .navUnderline {
    width: 100%;
}

/* Ensure proper spacing in the nav */
header .navLinks {
    display: flex;
    gap: 0.5rem;
    align-items: center;
    height: 100%;
}

header .navItem {
    height: 100%;
    display: flex;
    align-items: center;
}

/* Mobile responsiveness */
@media (max-width: 768px) {
    .dropdown {
        width: 100%;
    }
    
    .dropdown-content {
        position: static;
        display: none;
        box-shadow: none;
        width: 100%;
        transform: none;
        opacity: 1;
        visibility: visible;
        background-color: #f8f9fa;
        padding-left: 1.5rem;
    }
    
    .dropdown.active .dropdown-content {
        display: block;
    }
    
    .dropdown-item {
        padding: 0.8rem 1rem;
        border-left: none;
        border-bottom: 1px solid #e9ecef;
    }
    
    .dropdown-item:hover {
        padding-left: 1rem;
        border-left: none;
        border-left: 3px solid #0056b3;
    }
}