/* ---------- NAV GLOBAL STYLES ---------- */

header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.2rem 5%; /* Un poco más de aire */
    background-color: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    z-index: 1000;
    transition: all .4s;
    min-height: 80px; /* Altura mínima consistente */
}

/* Estandarizar logo en todas las páginas */
.logoNav img {
    width: 120px;
    height: auto;
    transition: width 0.3s ease;
}

.user-icon-pc {
    display: none; /* Se manejará dentro del ul.menu */
}

.menu .user-item-pc i, .user-icon-mobile i {
    font-size: 1.6rem;
    color: #fff;
    transition: color 0.3s ease;
}

.menu .user-item-pc:hover i, .user-icon-mobile:hover i,
.menu .user-item-pc.active i, .user-icon-mobile.active i,
.menu .user-item-pc a.active i {
    color: #21bdec;
}

.mobile-actions {
    display: none;
    align-items: center;
    gap: 1rem;
}

.user-icon-mobile {
    text-decoration: none;
    display: flex;
    align-items: center;
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    color: #fff;
    font-size: 2rem;
    cursor: pointer;
    z-index: 1001;
    transition: color 0.3s ease;
    padding: 0;
}

header nav ul.menu {
    list-style: none;
    display: flex;
    gap: 3rem;
    margin: 0;
    padding: 0;
    align-items: center;
    font-family: 'Raleway', sans-serif;
}

header nav ul.menu li a {
    position: relative;
    text-decoration: none;
    color: #fff;
    font-weight: 500;
    font-size: 1rem;
    padding-bottom: 5px;
    transition: .3s;
}

header nav ul.menu li a:hover,
header nav ul.menu li a.active {
    color: #21bdec;
}

header nav ul.menu li a::after {
    content: '';
    position: absolute;
    bottom: -3px;
    left: 0;
    width: 100%;
    height: 2px;
    background-color: #21bdec;
    transform: scaleX(0);
    transform-origin: center;
    transition: transform .3s ease;
}

header nav ul.menu li a:hover::after {
    transform: scaleX(1);
}

/* El icono de usuario en PC no lleva subrayado */
header nav ul.menu li.user-item-pc a::after {
    display: none;
}

/* ---------- MOBILE STYLES ---------- */

@media(max-width: 768px) {
    header {
        padding: 1rem 5% !important; /* Forzar padding consistente */
        min-height: 70px !important;
        background-color: rgba(0, 0, 0, 0.7) !important;
    }

    .logoNav img {
        width: 100px !important; /* Logo estandarizado para móvil */
    }

    .user-item-pc {
        display: none;
    }

    .mobile-actions {
        display: flex;
        align-items: center;
        gap: 1.2rem;
        order: 2;
        margin-left: auto;
    }

    .menu-toggle {
        display: flex;
        align-items: center;
        justify-content: center;
    }

    header nav ul.menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 100%;
        height: 100vh;
        background: rgba(0, 0, 0, 0.95);
        backdrop-filter: blur(25px);
        -webkit-backdrop-filter: blur(25px);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 3.5rem;
        transition: right 0.5s cubic-bezier(0.77, 0.2, 0.05, 1);
        z-index: 1000;
    }

    header nav ul.menu.active {
        right: 0;
    }

    header nav ul.menu li a {
        font-size: 1.5rem;
        font-weight: 600;
        letter-spacing: 1px;
    }

    header nav ul.menu li a.active {
        color: #21bdec !important;
    }

    .user-icon-mobile.active i {
        color: #21bdec !important;
    }
}
