/* ===== HORIZONTAL NAVBAR STYLES ===== */
.navbar {
    background-color: #fff;
    box-shadow: var(--shadow);
    padding: 0;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
    height: 70px;
}

.navbar-brand {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
    display: flex;
    align-items: center;
    height: 100%;
    padding: 0 1rem;
}

.navbar-brand img {
    height: 40px;
    margin-right: 10px;
}

.navbar-menu {
    display: flex;
    align-items: center;
    height: 100%;
}

.navbar-nav {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    height: 100%;
}

.nav-item {
    position: relative;
    height: 100%;
    display: flex;
    align-items: center;
}

.nav-link {
    color: var(--dark-color);
    padding: 0 1.2rem;
    display: flex;
    align-items: center;
    height: 100%;
    font-weight: 500;
    transition: var(--transition);
    position: relative;
}

.nav-link:hover {
    color: var(--primary-color);
    background-color: rgba(26, 75, 132, 0.05);
}

.nav-link.active {
    color: var(--primary-color);
    font-weight: 600;
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background-color: var(--primary-color);
}

/* Dropdown menu for horizontal navbar */
.dropdown {
    position: relative;
    height: 100%;
}

.dropdown-toggle::after {
    content: "▼";
    font-size: 0.6rem;
    margin-left: 5px;
    vertical-align: middle;
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    z-index: 1000;
    display: none;
    min-width: 220px;
    padding: 0.5rem 0;
    margin: 0;
    font-size: 0.95rem;
    color: var(--dark-color);
    text-align: left;
    list-style: none;
    background-color: #fff;
    background-clip: padding-box;
    border: 1px solid rgba(0, 0, 0, 0.15);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-lg);
}

.dropdown-item {
    display: block;
    width: 100%;
    padding: 0.6rem 1.5rem;
    clear: both;
    font-weight: 400;
    color: var(--dark-color);
    text-align: inherit;
    white-space: nowrap;
    background-color: transparent;
    border: 0;
    transition: var(--transition);
}

.dropdown-item:hover {
    background-color: var(--gray-light);
    color: var(--primary-color);
}

.dropdown:hover .dropdown-menu {
    display: block;
}

/* User actions in navbar */
.navbar-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.navbar-action-btn {
    padding: 0.5rem 1rem;
    border-radius: var(--border-radius);
    font-weight: 500;
    transition: var(--transition);
}

.btn-login {
    color: var(--primary-color);
    border: 1px solid var(--primary-color);
}

.btn-login:hover {
    background-color: var(--primary-color);
    color: white;
}

.btn-register {
    background-color: var(--primary-color);
    color: white;
}

.btn-register:hover {
    background-color: #0d3a6b;
    color: white;
}

/* User dropdown when logged in */
.user-dropdown {
    position: relative;
}

.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    cursor: pointer;
    border: 2px solid var(--gray-light);
    transition: var(--transition);
}

.user-avatar:hover {
    border-color: var(--primary-color);
}

.user-dropdown-menu {
    position: absolute;
    top: 100%;
    right: 0;
    z-index: 1000;
    display: none;
    min-width: 200px;
    padding: 0.5rem 0;
    background-color: #fff;
    border: 1px solid rgba(0, 0, 0, 0.15);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-lg);
}

.user-dropdown:hover .user-dropdown-menu {
    display: block;
}

.user-dropdown-item {
    display: block;
    padding: 0.6rem 1.5rem;
    color: var(--dark-color);
    text-decoration: none;
    transition: var(--transition);
}

.user-dropdown-item:hover {
    background-color: var(--gray-light);
    color: var(--primary-color);
}

.user-dropdown-divider {
    height: 1px;
    margin: 0.5rem 0;
    background-color: var(--gray-light);
}

/* Mobile menu toggle (hidden by default) */
.navbar-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 21px;
    cursor: pointer;
}

.navbar-toggle span {
    height: 3px;
    width: 100%;
    background-color: var(--primary-color);
    border-radius: 3px;
    transition: var(--transition);
}

/* Main content adjustment for horizontal navbar */
.container-fluid {
    margin-top: 0;
}

.main-content {
    padding: 2rem 0;
}

/* Responsive design for horizontal navbar */
@media (max-width: 992px) {
    .navbar-container {
        height: auto;
        padding: 1rem;
    }
    
    .navbar-menu {
        position: fixed;
        top: 0;
        right: -300px;
        width: 300px;
        height: 100vh;
        background-color: #fff;
        flex-direction: column;
        align-items: flex-start;
        padding: 2rem;
        box-shadow: -5px 0 15px rgba(0, 0, 0, 0.1);
        transition: right 0.3s ease;
        z-index: 1001;
    }
    
    .navbar-menu.active {
        right: 0;
    }
    
    .navbar-nav {
        flex-direction: column;
        width: 100%;
        height: auto;
    }
    
    .nav-item {
        width: 100%;
        height: auto;
        margin-bottom: 0.5rem;
    }
    
    .nav-link {
        padding: 1rem;
        height: auto;
    }
    
    .nav-link.active::after {
        display: none;
    }
    
    .dropdown {
        width: 100%;
        height: auto;
    }
    
    .dropdown-menu {
        position: static;
        display: none;
        width: 100%;
        box-shadow: none;
        border: none;
        padding-left: 1rem;
    }
    
    .dropdown.active .dropdown-menu {
        display: block;
    }
    
    .navbar-toggle {
        display: flex;
        z-index: 1002;
    }
    
    .navbar-toggle.active span:nth-child(1) {
        transform: rotate(45deg) translate(5px, 5px);
    }
    
    .navbar-toggle.active span:nth-child(2) {
        opacity: 0;
    }
    
    .navbar-toggle.active span:nth-child(3) {
        transform: rotate(-45deg) translate(7px, -6px);
    }
    
    .navbar-actions {
        flex-direction: column;
        width: 100%;
        gap: 0.5rem;
        margin-top: 1rem;
    }
    
    .navbar-action-btn {
        width: 100%;
        text-align: center;
    }
    
    .user-dropdown-menu {
        position: static;
        display: none;
        width: 100%;
        box-shadow: none;
        border: none;
    }
    
    .user-dropdown.active .user-dropdown-menu {
        display: block;
    }
}

@media (max-width: 768px) {
    .navbar-brand {
        font-size: 1.25rem;
    }
    
    .navbar-brand img {
        height: 35px;
    }
}