/* ========================================
   NAVBAR STYLES - GLOBAL NAVIGATION
   ======================================== */

/* Header */
.header {
    position: fixed;
    top: 2.22vh;
    left: 0;
    right: 0;
    z-index: 1000;
    display: flex;
    justify-content: center;
    transition: all 0.3s ease;
    background: transparent;
}

.header.scrolled {
    background: transparent;
}

.header-nav {
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255);
    backdrop-filter: blur(0.781vw);
    border-radius: 1.48vh;
    padding: 2.2vh 3vw;
    box-shadow: 0 0.37vh 1.85vh rgba(0, 0, 0, 0.33);
    width: auto;
    min-width: 37.04vw;
    max-width: 46.3vw;
    gap: 0.37vh;
    flex-wrap: nowrap;
    position: relative;
    margin: 0 auto;
}

/* Estado quando com scroll */
.header.scrolled .header-nav {
    box-shadow: 0 0.74vh 1.85vh rgba(0, 0, 0, 0.15);
}

/* Nav Brand */
.nav-brand {
    display: flex;
    align-items: center;
    margin-left: 1.11vh;
    position: relative;
    z-index: 1;
    margin-right: 2.55vw;
}

.nav-brand a {
    display: block;
    text-decoration: none;
}

.nav-logo {
    height: 4.5vh;
    width: auto;
    max-width: 10vw;
    transition: transform 0.2s ease;
    display: block;
    visibility: visible;
    opacity: 1;
    object-fit: contain;
}

.nav-logo:hover {
    transform: scale(1.05);
}

/* Nav Links */
.nav-links {
    display: flex;
    align-items: center;
    gap: 1.2vw;
    flex: 1;
    justify-content: center;
    flex-direction: row;
    order: 0;
    flex-wrap: nowrap;
    position: static;
    transform: none;
    margin-right: 2.55vw;
}

.nav-link {
    color: #545454;
    text-decoration: none;
    font-family: 'Inter', sans-serif;
    font-weight: 400;
    font-size: 1.6vh;
    padding: 1vh 1vw;
    transition: all 0.2s ease;
    white-space: nowrap;
    position: relative;
    z-index: 2;
    border-radius: 0.74vh;
    outline: none;
    flex-shrink: 0;
}

/* Remove todos os outlines dos links de navegação */
.nav-link:focus,
.nav-link:focus-visible,
.nav-link:active {
    outline: none;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -0.093vh;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 0.185vh;
    background: #b3ce3a;
    transition: width 0.3s ease;
    border-radius: 0.093vh;
}

.nav-link:hover::after {
    width: 80%;
}

/* Garantir que hover não afete o estado active */
.nav-link.active:hover::after {
    width: 0.46vh !important;
    height: 0.46vh !important;
    background: #b3ce3a !important;
    border-radius: 50% !important;
}

.nav-link.active {
    color: #1F2937;
    font-weight: 500;
    position: relative;
    padding: 0.74vh 0.74vw;
    border-radius: 0.74vh;
}

.nav-link.active::after {
    content: '';
    position: absolute;
    width: 0.46vh;
    height: 0.46vh;
    bottom: -0.093vh;
    left: 50%;
    transform: translateX(-50%);
    background: #b3ce3a;
    border-radius: 50%;
    transition: none;
}

/* Remover qualquer círculo criado dinamicamente por JavaScript */
.nav-link .active-circle,
.nav-link.active .active-circle {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
    pointer-events: none !important;
}

.nav-links a:nth-child(4) { order: 4 !important; }
.nav-links a:nth-child(5) { order: 5 !important; }

/* Regra específica para o link Services */
.nav-link[href*="services"], 
.nav-link[href*="Services"],
a[href*="services"],
a[href*="Services"] {
    order: 3;
    position: relative;
    flex-shrink: 0;
}

/* Regra específica para quando Services está ativo */
.nav-link[href*="services"].active, 
.nav-link[href*="Services"].active,
a[href*="services"].active,
a[href*="Services"].active {
    order: 3;
    position: relative;
    padding: 1vh 1.5vw;
    flex-shrink: 0;
    color: #1F2937;
    font-weight: 500;
}

/* Nav Actions */
.nav-actions {
    display: flex;
    align-items: center;
    gap: 1.2vw;
    margin-right: 0.8vw;
}

/* Garantir alinhamento vertical perfeito do botão Get in Touch */
.nav-animated-btn {
    align-self: center;
    vertical-align: middle;
}

/* Language Toggle Button */
.language-toggle {
    display: flex;
    align-items: center;
    gap: 0.74vh;
    background: #ffffff;
    border: none;
    border-radius: 0.74vh;
    padding: 1vh 0.8vw;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: 'Inter', sans-serif;
    font-size: 1.5vh;
    font-weight: 500;
    color: #545454;
    min-width: 4vw;
    max-width: 4vw;
    height: 2vh;
    justify-content: center;
    flex-shrink: 0;
}

.language-toggle:hover {
    background: #ffffff;
    color: #000000;
}

.language-toggle.active {
    background: #ffffff;
    color: #545454;
}

.language-text {
    transition: all 0.2s ease;
    cursor: pointer;
    padding: 0;
    border-radius: 0;
    color: #545454;
    font-weight: 500;
}

.language-text:hover {
    color: #000000;
}

.language-text.active {
    color: #545454;
    font-weight: 600;
}

.globe-icon {
    width: 0.74vw;
    height: 0.74vw;
    color: #545454;
    transition: all 0.2s ease;
}

/* Botão Animado da Navbar */
.nav-animated-btn {
    background: #b3ce3a;
    color: white;
    border: none;
    border-radius: 0.74vw;
    padding: 1vh 2vw;
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    font-size: 1.4vh;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    white-space: nowrap;
    letter-spacing: 0.02vw;
    box-shadow: none;
    position: relative;
    z-index: 2;
    overflow: hidden;
    min-width: 7vw;
    height: 4.2vh;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(1.875vw) saturate(1.2);
    -webkit-backdrop-filter: blur(1.875vw) saturate(1.2);
}

.nav-animated-btn:hover {
    min-width: 11vw;
    background: #b3ce3a;
    transform: scale(1.02);
    backdrop-filter: blur(2.188vw) saturate(1.3);
    -webkit-backdrop-filter: blur(2.188vw) saturate(1.3);
}

.nav-animated-btn:hover .action-text {
    color: #ffffff;
}

/* Conteúdo do Botão */
.btn-content {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Estado Inicial - Apenas JDC. */
.btn-initial {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    transition: all 0.3s ease;
    opacity: 1;
    font-size: 1.3vh;
}

.nav-animated-btn:hover .btn-initial {
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.8);
}

.btn-brand {
    color: #ffffff !important;
}

.btn-brand::after {
    content: "\203A"; 
    margin-left: 0.469vw; 
    font-weight: bold; 
}

/* Estado Expandido - Conteúdo Completo */
.btn-expanded {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    display: flex;
    align-items: center;
    gap: 0.74vh;
    opacity: 0;
    transition: all 0.3s ease;
}

.nav-animated-btn:hover .btn-expanded {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
}

/* Foto de Perfil */
.profile-picture {
    width: 2.2vh;
    height: 2.2vh;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.profile-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    filter: brightness(0) invert(1) !important;
}

/* Indicador de Conexão */
.connection-indicator {
    display: flex;
    align-items: center;
    gap: 0.37vh;
}

.plus-icon {
    font-size: 1.19vh;
    font-weight: 600;
    color: #2d3748;
}

.you-text {
    font-size: 1.04vh;
    font-weight: 500;
    color: #2d3748;
    background: #f7fafc;
    padding: 0.185vh 0.56vh;
    border-radius: 1.48vh;
    border: 0.078vw solid rgba(45, 55, 72, 0.1);
}

/* Texto de Ação */
.action-text {
    font-size: 1.26vh;
    font-weight: 500;
    color: #ffffff;
    margin-left: 0.37vh;
}


/* Responsive Design */
@media (max-width: 480px) {
    .header-nav {
        padding: 1.5vh 2.5vw !important;
        min-width: 60vw !important;
        max-width: 80vw !important;
        gap: 0.5vw !important;
    }

    .nav-brand {
        margin-right: 1.5vw !important;
    }

    .nav-links {
        gap: 1vw !important;
        margin-right: 1.5vw !important;
    }

    .nav-link {
        font-size: 1.2vh !important;
        padding: 0.6vh 1vw !important;
    }

    .nav-logo {
        height: 3.2vh !important;
    }

    .nav-actions {
        gap: 1.5vw !important;
    }

    .language-toggle {
        padding: 0.6vh 1.2vw !important;
        font-size: 1.4vh !important;
        min-width: 10vw !important;
        max-width: 10vw !important;
        height: 3.8vh !important;
        flex-shrink: 0;
    }

    .globe-icon {
        width: 4vw !important;
        height: 4vw !important;
    }

    .nav-animated-btn {
        padding: 0.8vh 1.5vw !important;
        font-size: 1.3vh !important;
        min-width: 7vw !important;
        height: 3.5vh !important;
    }

    .nav-animated-btn:hover {
        min-width: 10vw !important;
        transform: scale(1.02);
    }
}
