.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background-color: white;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    z-index: 1000;
}

.navbar-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 70px;
    width: 100%;
    position: relative;
}

.navbar-logo {
    flex: 0;
    position: absolute;
    left: 20px;
    display: flex;
    align-items: center;
    justify-content: flex-start;
}

.navbar-logo a {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    font-weight: bold;
    color: var(--primary-color);
    transition: var(--transition);
}

.navbar-logo a:hover {
    opacity: 0.8;
}

.logo-image {
    height: 40px;
    width: auto;
    max-width: 150px;
    object-fit: contain;
    display: block;
    transition: opacity var(--transition);
}

.navbar-menu {
    display: flex;
    gap: 30px;
    justify-content: center;
}

.desktop-menu {
    display: flex;
}

.nav-link {
    color: var(--dark-color);
    font-weight: 500;
    position: relative;
    transition: var(--transition);
    text-decoration: none;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--primary-color);
    transition: var(--transition);
}

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

.navbar-icons {
    display: flex;
    gap: 20px;
    justify-content: flex-end;
    flex: 0;
    position: absolute;
    right: 20px;
}

.nav-icon {
    font-size: 20px;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    position: relative;
    display: inline-flex;
    align-items: center;
    background: transparent;
}

.nav-icon:hover {
    transform: scale(1.2);
}

/* Dropdown Menu */
.nav-dropdown {
    position: relative;
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    background-color: white;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    min-width: 200px;
    padding: 10px 0;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    display: none;
    flex-direction: column;
    z-index: 1001;
}

.nav-dropdown:hover .dropdown-menu {
    display: flex;
}

.dropdown-item {
    color: var(--dark-color);
    padding: 12px 20px;
    display: block;
    transition: var(--transition);
    position: relative;
    text-decoration: none;
}

.dropdown-item:hover {
    background-color: rgba(0, 0, 0, 0.05);
    color: var(--primary-color);
    padding-left: 28px;
}

/* Hamburger Menu Button */
.hamburger-menu {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    color: var(--dark-color);
    transition: var(--transition);
    position: absolute;
    left: 20px;
}

.hamburger-menu:hover {
    transform: scale(1.1);
}

/* Sidebar Menu */
.sidebar-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 999;
    display: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.sidebar-overlay.active {
    display: block;
    opacity: 1;
}

.sidebar-menu {
    position: fixed;
    top: 0;
    left: 0;
    width: 280px;
    height: 100vh;
    background-color: white;
    box-shadow: 2px 0 10px rgba(0, 0, 0, 0.1);
    z-index: 1001;
    transform: translateX(-100%);
    transition: transform 0.3s ease;
    overflow-y: auto;
    padding-top: 70px;
}

.sidebar-menu.active {
    transform: translateX(0);
}

.sidebar-menu .navbar-menu {
    flex-direction: column;
    gap: 0;
    justify-content: flex-start;
    padding: 20px 0;
}

.sidebar-menu .nav-link {
    padding: 15px 20px;
    display: block;
    width: 100%;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.sidebar-menu .nav-link::after {
    display: none;
}

.sidebar-menu .nav-dropdown {
    width: 100%;
}

.sidebar-menu .dropdown-menu {
    position: static;
    border: none;
    box-shadow: none;
    background-color: rgba(0, 0, 0, 0.02);
    min-width: auto;
    display: none;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    padding: 0;
}

.sidebar-menu .nav-dropdown.open .dropdown-menu {
    display: flex;
    max-height: 300px;
    overflow: scroll;
}

.sidebar-menu .dropdown-item {
    padding: 10px 40px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.03);
}

.sidebar-menu .dropdown-item:hover {
    padding-left: 48px;
}

/* Chevron icon rotation */
.categories-toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.categories-toggle svg {
    transition: transform 0.3s ease;
    flex-shrink: 0;
}

.sidebar-menu .nav-dropdown.open .categories-toggle svg {
    transform: rotate(180deg);
}

/* Desktop chevron */
.desktop-menu .nav-dropdown .nav-link {
    display: flex;
    align-items: center;
    gap: 6px;
}

.desktop-menu .nav-dropdown .nav-link svg {
    transition: transform 0.3s ease;
    flex-shrink: 0;
}

.desktop-menu .nav-dropdown:hover .nav-link svg {
    transform: rotate(180deg);
}

.close-sidebar {
    position: absolute;
    top: 20px;
    right: 20px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
    color: var(--dark-color);
    transition: var(--transition);
    z-index: 1002;
}

.close-sidebar:hover {
    transform: rotate(90deg);
}

/* Responsive */
@media (max-width: 768px) {
    .navbar-container {
        height: 60px;
    }

    .navbar-logo {
        position: absolute;
        left: 50%;
        transform: translateX(-50%);
        text-align: center;
    }

    .navbar-logo a {
        font-size: 22px;
    }

    .desktop-menu {
        display: none !important;
    }

    .hamburger-menu {
        display: block;
        position: absolute;
        left: 20px;
        transform: none;
    }

    .navbar-icons {
        gap: 15px;
        position: absolute;
        right: 20px;
    }

    .sidebar-menu {
        padding-top: 60px;
    }
}
