.modern-navbar {
    background: #fff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1030;
    border-bottom: 1px solid #e1e5e9;
}

.navbar-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 72px;
    width: 100%;
    box-sizing: border-box;
}

/* Brand/Logo */
.navbar-brand {
    flex-shrink: 0;
}

/* Navbar Left Section (Logo + Mobile Menu) */
.navbar-left {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-shrink: 0;
    min-width: 0;
}

.brand-link {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: #262626;
    font-weight: 600;
    font-size: 24px;
}

.brand-logo {
    height: 40px;
    width: auto;
    object-fit: contain;
}

.brand-text {
    color: #003580;
    font-weight: 700;
}

/* Mobile Menu Toggle */
.mobile-menu-toggle {
    display: none;
}

.hamburger-btn {
    background: none;
    border: none;
    padding: 8px;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    gap: 4px;
    transition: all 0.3s ease;
}

.hamburger-btn:hover {
    background-color: #f8f9fa;
    border-radius: 6px;
}

.hamburger-line {
    width: 24px;
    height: 2px;
    background: #262626;
    transition: all 0.3s ease;
}

/* Navigation Menu */
.navbar-menu {
    flex: 1;
    margin: 0 40px;
    min-width: 0;
    display: flex;
    justify-content: center;
}

.nav-menu {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    gap: 32px;
    align-items: center;
    flex-wrap: nowrap;
}

.nav-menu li {
    position: relative;
}

.nav-menu a {
    color: #262626;
    text-decoration: none;
    font-weight: 500;
    font-size: 16px;
    padding: 12px 0;
    display: block;
    transition: color 0.2s ease;
}

.nav-menu a:hover {
    color: #003580;
}

/* User Actions */
.navbar-actions {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-shrink: 0;
    min-width: 0;
}

/* Cart Icon */
.cart-icon-container {
    position: relative;
}

.cart-link {
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    padding: 8px;
    color: #262626;
    text-decoration: none;
    transition: all 0.2s ease;
    border-radius: 6px;
}

.cart-link:hover {
    color: #003580;
    background-color: #f8f9fa;
}

.cart-icon {
    font-size: 24px;
    line-height: 1;
}

.cart-count {
    position: absolute;
    top: 2px;
    right: 2px;
    background: #dc3545;
    color: white;
    border-radius: 50%;
    min-width: 18px;
    height: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 600;
    line-height: 1;
    padding: 0 4px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.cart-count:empty {
    display: none;
}

/* Guest Actions */
.guest-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.btn {
    padding: 10px 20px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 500;
    font-size: 14px;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border: none;
    cursor: pointer;
    white-space: nowrap;
    height: auto;
    line-height: 1.4;
}

/* Large Screen Optimizations */
@media (min-width: 992px) {
    .navbar-container {
        padding: 0 24px;
    }
    
    .navbar-menu {
        margin: 0 48px;
    }
    
    .nav-menu {
        gap: 40px;
    }
    
    .navbar-actions {
        gap: 20px;
    }
    
    .btn {
        padding: 12px 24px;
        font-size: 15px;
    }
}

/* Hide mobile menu header on desktop/laptop */
@media (min-width: 768px) {
    .mobile-menu-header,
    .mobile-menu-close,
    .mobile-menu-title {
        display: none !important;
        visibility: hidden !important;
        opacity: 0 !important;
    }
}

/* Responsive Design */
@media (max-width: 991px) {
    .mobile-menu-toggle {
        display: block;
    }

    .navbar-left {
        gap: 12px;
    }

    .navbar-menu {
        position: fixed;
        top: 0;
        left: -100%;
        width: 280px;
        height: 100vh;
        background: white;
        z-index: 1040;
        transition: left 0.3s ease;
        overflow-y: auto;
        margin: 0;
        box-shadow: 4px 0 20px rgba(0, 0, 0, 0.15);
        pointer-events: auto;
        border-right: 1px solid #e1e5e9;
    }

    .navbar-menu.active {
        left: 0;
    }

    .nav-menu {
        flex-direction: column;
        gap: 0;
        padding: 20px 0;
    }

    .mobile-menu-header {
        display: none;
        justify-content: space-between;
        align-items: center;
        padding: 20px;
        border-bottom: 1px solid #e1e5e9;
        background: #f8f9fa;
    }

    .mobile-menu-close {
        background: none;
        border: none;
        font-size: 24px;
        color: #666;
        cursor: pointer;
        padding: 8px;
        border-radius: 4px;
        transition: all 0.2s ease;
    }

    .mobile-menu-close:hover {
        background: #e9ecef;
        color: #333;
    }

    /* Hide mobile menu header on large screens */
    @media (min-width: 769px) {
        .mobile-menu-header {
            display: none !important;
        }
    }

    .nav-menu a {
        padding: 16px 20px;
        display: block;
        text-decoration: none;
        color: #262626;
        transition: background-color 0.2s ease;
        cursor: pointer;
        position: relative;
        z-index: 1041;
    }

    .nav-menu a:hover {
        background-color: #f8f9fa;
    }

    .nav-menu li {
        border-bottom: 1px solid #e1e5e9;
        position: relative;
        z-index: 1041;
    }

    .menu-overlay {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: transparent;
        z-index: 1035;
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s ease;
        pointer-events: none;
    }

    .menu-overlay.active {
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
        cursor: pointer;
    }

    .navbar-actions {
        gap: 8px;
    }

    .guest-actions {
        gap: 8px;
    }

    .btn {
        padding: 8px 16px;
        font-size: 13px;
    }

    .btn-text {
        font-size: 13px;
    }
}

@media (max-width: 768px) {
    .mobile-menu-header {
        display: flex;
    }

    .navbar-container {
        padding: 0 16px;
        height: 64px;
        position: relative;
    }

    .navbar-left {
        gap: 8px;
    }

    .brand-logo {
        height: 32px;
    }

    .brand-text {
        font-size: 20px;
    }

    .profile-name {
        display: none;
    }

    .navbar-actions {
        gap: 8px;
    }

    .guest-actions {
        flex-direction: column;
        gap: 8px;
        position: absolute;
        top: 100%;
        right: 0;
        background: white;
        border: 1px solid #e1e5e9;
        border-radius: 8px;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
        padding: 12px;
        min-width: 200px;
        opacity: 0;
        visibility: hidden;
        transform: translateY(-10px);
        transition: all 0.3s ease;
        z-index: 1000;
    }

    .guest-actions.active {
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
    }

    .btn {
        width: 100%;
        justify-content: center;
        padding: 12px 16px;
        font-size: 14px;
    }

    .btn-text {
        font-size: 14px;
    }

    /* Mobile guest actions toggle */
    .guest-actions-toggle {
        display: block;
        background: none;
        border: none;
        padding: 8px;
        cursor: pointer;
        color: #262626;
        font-size: 18px;
    }
}

@media (max-width: 576px) {
    .navbar-container {
        padding: 0 12px;
        height: 60px;
        position: relative;
    }

    .navbar-left {
        gap: 6px;
    }

    .brand-logo {
        height: 28px;
    }

    .brand-text {
        font-size: 18px;
    }

    .hamburger-line {
        width: 20px;
        height: 2px;
    }

    .navbar-actions {
        gap: 6px;
    }

    .guest-actions {
        min-width: 180px;
        right: 12px;
    }

    .btn {
        padding: 10px 12px;
        font-size: 13px;
    }

    .btn-text {
        font-size: 13px;
    }
}

@media (max-width: 480px) {
    .navbar-container {
        padding: 0 8px;
        position: relative;
    }

    .navbar-left {
        gap: 4px;
    }

    .brand-text {
        font-size: 16px;
    }

    .navbar-actions {
        gap: 4px;
    }

    .guest-actions {
        min-width: 160px;
        right: 8px;
    }

    .btn {
        padding: 8px 10px;
        font-size: 12px;
    }

    .btn-text {
        font-size: 12px;
    }
}
