﻿.modern-navbar {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    width: calc(100% - 40px);
    max-width: 1200px;
    background: rgba(255, 255, 255, 0.75);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    box-shadow: 0 4px 25px rgba(0, 0, 0, 0.08);
    border-radius: 25px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    z-index: 1050;
    /* Enhanced transition for smooth hide/show */
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* Navbar Hide Animation */
.modern-navbar.navbar-hidden {
    transform: translateX(-50%) translateY(-120%);
    opacity: 0;
    pointer-events: none;
}

.modern-navbar.scrolled {
    background: rgba(255, 255, 255, 0.25);
    box-shadow: 0 6px 35px rgba(0, 0, 0, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.3);
    top: 10px;
}

/* Combined states for smooth transition */
.modern-navbar.navbar-hidden.scrolled {
    transform: translateX(-50%) translateY(-120%);
    top: 10px;
}

.modern-navbar.navbar-visible.scrolled {
    transform: translateX(-50%) translateY(0);
    top: 10px;
}

/* Hover effect when navbar is partially hidden (optional) */
.modern-navbar.navbar-hidden:hover {
    transform: translateX(-50%) translateY(-50%);
    opacity: 0.7;
    pointer-events: auto;
}

.navbar-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 20px;
    position: relative;
}

/* Logo */
.navbar-logo img {
    height: 40px;
    transition: height 0.3s ease;
}



/* Menü */
.navbar-menu {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 25px;
    flex-wrap: wrap;
}

.nav-item {
    color: #2c3e50;
    text-decoration: none;
    font-weight: 600;
    font-size: 15px;
    transition: all 0.3s ease;
    position: relative;
    padding: 8px 0;
    text-shadow: 0 1px 2px rgba(255, 255, 255, 0.8);
}

.nav-item:hover {
    color: #005cb9;
}

.nav-item.active {
    color: #005cb9;
}

.nav-item.active::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 50%;
    transform: translateX(-50%);
    width: 30px;
    height: 3px;
    background: linear-gradient(90deg, #005cb9, #0080ff);
    border-radius: 2px;
}

/* Dropdown */
.nav-dropdown {
    position: relative;
}

.dropdown-toggle {
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 5px;
}

.dropdown-toggle i {
    font-size: 12px;
    transition: transform 0.3s ease;
}

.nav-dropdown:hover .dropdown-toggle i {
    transform: rotate(180deg);
}

.dropdown-menu-custom {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(-10px);
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 15px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.3);
    min-width: 280px;
    padding: 15px 0;
    margin-top: 10px;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 1000;
}

.dropdown-toggle::after {
    display: none;
}

.nav-dropdown:hover .dropdown-menu-custom {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

.dropdown-item-custom {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 20px;
    color: #2c3e50;
    font-weight: 500;
    font-size: 14px;
    transition: all 0.3s ease;
}

.dropdown-item-custom:hover {
    background: rgba(0, 92, 185, 0.1);
    color: #005cb9;
}

.dropdown-item-custom i {
    width: 20px;
    text-align: center;
    color: #005cb9;
    font-size: 16px;
}

/* Sağ aksiyonlar */
.navbar-actions {
    display: flex;
    align-items: center;
    gap: 15px;
}

/* Mobile-only contact link hidden by default */
.contact-mobile {
    display: none;
}

/* Search buton */
.search-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: none;
    background: rgba(255, 255, 255, 0.8);
    color: #333;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    cursor: pointer;
}

.search-btn:hover {
    background: #005cb9;
    color: white;
    box-shadow: 0 4px 15px rgba(0, 92, 185, 0.3);
}

/* Contact buton */
.contact-btn {
    background: linear-gradient(135deg, #005cb9, #0080ff);
    color: white;
    padding: 10px 25px;
    border-radius: 25px;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 92, 185, 0.2);
}

.contact-btn:hover {
    transform: translateY(-2px);
    color: white;
}

/* Dil bayrakları */
.language-flags {
    display: flex;
    gap: 10px;
}

.flag-icon {
    width: 30px;
    height: 22px;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
    opacity: 0.7;
}

.flag-icon:hover {
    opacity: 1;
    transform: scale(1.1);
}

.flag-icon.active {
    opacity: 1;
    transform: scale(1.05);
}

/* Mobil */
.mobile-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
}

.mobile-toggle span {
    width: 25px;
    height: 3px;
    background: #333;
    border-radius: 2px;
}

/* Medium ekran */
@media (max-width: 1199.98px) {
    .navbar-menu {
        gap: 20px;
    }

    .nav-item {
        font-size: 14px;
    }
}

/* Tablet ve altı */
@media (max-width: 1091.98px) {
    .navbar-menu {
        display: none;
        flex-direction: column;
        gap: 15px;
        background: white;
        position: fixed;
        top: 70px;
        left: 0;
        width: 100%;
        padding: 20px;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    }

    .navbar-menu.show {
        display: flex;
    }

    .mobile-toggle {
        display: flex;
    }

    /* Show prominent contact button inside mobile menu */
    .navbar-menu .contact-mobile {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        background: linear-gradient(135deg, #005cb9, #0080ff);
        color: #fff;
        padding: 10px 18px;
        border-radius: 24px;
        font-weight: 600;
        margin-top: 5px;
    }
}

/* Küçük ekran */
@media (max-width: 767.98px) {
    .navbar-logo img {
        height: 30px;
    }

    /* Keep contact button visible; just slightly smaller on small phones */
    .contact-btn {
        padding: 6px 14px;
        font-size: 12px;
    }

    .search-btn {
        width: 32px;
        height: 32px;
    }

    .flag-icon {
        width: 22px;
        height: 16px;
    }
}

/* Very small phones */
@media (max-width: 400px) {

    /* Hide header contact button under 400px */
    .contact-btn {
        display: none;
    }
}

@media (max-width: 768px) {
    .modern-navbar {
        width: calc(100% - 20px);
        top: 10px;
    }

    .modern-navbar.scrolled {
        top: 5px;
    }

    .modern-navbar.navbar-hidden.scrolled {
        top: 5px;
    }

    .modern-navbar.navbar-visible.scrolled {
        top: 5px;
    }
}

@media (max-width: 480px) {
    .navbar-logo img {
        height: 15px;
        transition: height 0.3s ease;
    }

    .contact-btn {
        padding: 4px 12px;
    }

    .search-btn {
        width: 24px;
        height: 24px;
    }
}