/* HEADER */

.site-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.98);
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    backdrop-filter: blur(10px);
}

.header-inner {
    min-height: 78px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.brand {
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

.brand img {
    display: block;
    width: 190px;
    height: auto;
    object-fit: contain;
}

.main-nav {
    display: flex;
    align-items: center;
    gap: 24px;
    font-size: 0.94rem;
    font-weight: 500;
}

.main-nav a {
    white-space: nowrap;
    transition: var(--transition);
}

.main-nav a:hover {
    color: var(--color-teal);
}

.mobile-nav-cta {
    display: none;
}

.header-actions .btn {
    min-height: 46px;
    padding: 0 22px;
    white-space: nowrap;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 16px;
}

.mobile-toggle {
    display: none;
    border: 0;
    background: transparent;
    font-size: 1.6rem;
    cursor: pointer;
}

/* =========================================
   AJUSTE DEFINITIVO HEADER + LOGO
   ========================================= */

.site-header {
    background: rgba(255, 255, 255, 0.98);
}

.header-inner {
    height: 74px;
    min-height: 88px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

/* Contenedor físico del logo */
a.brand {
    width: 165px;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    flex: 0 0 165px;
    overflow: hidden;
}

/* La imagen queda obligada a entrar en el contenedor */
a.brand img {
    width: 100% !important;
    height: 100% !important;
    max-width: 165px !important;
    max-height: 64px !important;
    object-fit: contain;
    object-position: left center;
    display: block;
}

/* Navegación */
.main-nav {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 18px;
    font-size: 0.88rem;
    font-weight: 500;
}

.main-nav a {
    white-space: nowrap;
    transition: var(--transition);
}

/* Botón de agenda */
.header-actions {
    flex: 0 0 auto;
}

.header-actions .btn {
    min-height: 46px;
    padding: 0 24px;
    white-space: nowrap;
}
/* ==================================================
   MENÚ MÓVIL - OVERRIDE FINAL
   ================================================== */

@media (max-width: 960px) {

    .header-inner {
        position: relative !important;
        min-height: 72px;
    }

    .main-nav {
        position: absolute !important;

        top: 100% !important;
        left: 0 !important;
        right: 0 !important;

        width: 100% !important;

        display: none !important;

        flex-direction: column !important;
        align-items: stretch !important;

        gap: 0 !important;

        padding: 10px 20px 18px !important;

        background: #ffffff !important;

        border-top: 1px solid rgba(0, 0, 0, 0.05);
        border-bottom: 1px solid rgba(0, 0, 0, 0.08);

        box-shadow: 0 14px 30px rgba(0, 0, 0, 0.10);

        z-index: 2000 !important;
    }

    .main-nav.is-open {
        display: flex !important;
    }

    .main-nav a {
        display: block !important;

        width: 100% !important;

        padding: 14px 4px !important;

        white-space: normal !important;

        font-size: 0.95rem !important;

        border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    }

    .main-nav a:last-child {
        border-bottom: 0;
    }
    
    .mobile-nav-cta {
    display: flex !important;

    align-items: center;
    justify-content: center;

    margin-top: 14px;

    padding: 13px 18px !important;

    background: #43ACAF !important;
    color: #ffffff !important;

    border: 0 !important;
    border-radius: 999px;

    font-weight: 700;

    text-align: center;
    }

    .mobile-nav-cta:hover {
    background: #378F92 !important;
    color: #ffffff !important;
    }
    .header-actions .btn {
        display: none !important;
    }

    .mobile-toggle {
        display: inline-flex !important;

        align-items: center;
        justify-content: center;

        width: 44px;
        height: 44px;

        flex: 0 0 44px;

        border: 1px solid rgba(67, 172, 175, 0.30);
        border-radius: 12px;

        background: #ffffff;
        color: #43ACAF;

        font-size: 1.45rem;

        cursor: pointer;
    }

}
@media (max-width: 640px) {

    a.brand {
        width: 145px !important;
        height: 58px !important;
        flex: 0 0 145px !important;
    }

    a.brand img {
        width: 145px !important;
        height: 58px !important;

        max-width: 145px !important;
        max-height: 58px !important;

        object-fit: contain !important;
    }

}
