/* Основные стили навбара */
#mainNavbar {
    background: linear-gradient(135deg, #1a237e 0%, #3949ab 100%);
    box-shadow: 0 4px 20px rgba(26, 35, 126, 0.2);
    padding: 0.5rem 1rem;
    transition: all 0.3s ease;
    z-index: 1030;
}

#mainNavbar.scrolled {
    padding: 0.3rem 1rem;
    background: rgba(26, 35, 126, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
}

/* Логотип */
.logo-icon {
    width: 3rem;
    height: 3rem;
    /*background: rgba(255, 255, 255, 0.1);*/
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: white;
}

/* Навигационные ссылки */
.nav-link {
    color: rgba(255, 255, 255, 0.8) !important;
    padding: 0.75rem 1rem !important;
    margin: 0 0.25rem;
    border-radius: 10px;
    display: flex;
    align-items: center;
    transition: all 0.3s ease;
    position: relative;
}

.nav-link:hover {
    color: white !important;
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-1px);
}

.nav-link.active {
    color: white !important;
    background: rgba(255, 255, 255, 0.15);
}

.nav-icon {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 0.5rem;
    font-size: 1.1rem;
}

.nav-text {
    font-weight: 500;
    font-size: 0.95rem;
}

.nav-indicator {
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 20px;
    height: 3px;
    background: linear-gradient(90deg, #00c853, #64dd17);
    border-radius: 3px 3px 0 0;
}

/* Бейджи */
.badge {
    font-size: 0.7rem;
    padding: 0.25rem 0.5rem;
}

/* Уведомления */
.notification-bell {
    position: relative;
}

.notification-badge {
    position: absolute;
    top: 0;
    right: 0;
    background: linear-gradient(135deg, #ff6d00, #ffab00);
    color: white;
    font-size: 0.6rem;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    border: 2px solid #1a237e;
}

.notification-header {
    padding: 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(0, 0, 0, 0.2);
}

.notification-list {
    max-height: 400px;
    overflow-y: auto;
}

.notification-item {
    display: flex;
    align-items: center;
    padding: 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    text-decoration: none;
    color: inherit;
    transition: background 0.3s ease;
}

.notification-item:hover {
    background: rgba(255, 255, 255, 0.05);
}

.notification-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 1rem;
    font-size: 1.2rem;
    flex-shrink: 0;
}

.notification-content {
    flex: 1;
    min-width: 0;
}

.notification-content h6 {
    margin: 0;
    font-size: 0.9rem;
    color: white;
}

.notification-content small {
    font-size: 0.8rem;
}

.notification-time {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.5);
    margin-left: 1rem;
    white-space: nowrap;
}

.notification-footer {
    padding: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* Поиск */
.search-toggle {
    cursor: pointer;
}

.search-box {
    position: absolute;
    top: 100%;
    right: 0;
    width: 400px;
    background: rgba(26, 35, 126, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 10px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    padding: 1rem;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 1060;
}

.search-box.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.search-input {
    position: relative;
    display: flex;
    align-items: center;
}

.search-input i {
    position: absolute;
    left: 1rem;
    color: rgba(255, 255, 255, 0.6);
    font-size: 1.2rem;
}

.search-input input {
    width: 100%;
    padding: 0.75rem 1rem 0.75rem 3rem;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    color: white;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.search-input input:focus {
    outline: none;
    border-color: rgba(255, 255, 255, 0.4);
    background: rgba(255, 255, 255, 0.15);
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.1);
}

.search-input input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.btn-close-search {
    position: absolute;
    right: 1rem;
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.6);
    font-size: 1.2rem;
    cursor: pointer;
    padding: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.btn-close-search:hover {
    background: rgba(255, 255, 255, 0.1);
    color: white;
}

.search-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(5px);
    z-index: 1059;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.search-overlay.show {
    opacity: 1;
    visibility: visible;
}

/* Профиль пользователя */
.user-profile {
    display: flex;
    align-items: center;
    padding: 0.25rem 0.75rem !important;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 50px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.user-avatar {
    position: relative;
    margin-right: 0.75rem;
}

.user-avatar img {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
}

.avatar-placeholder {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: linear-gradient(135deg, #00c853, #64dd17);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 1rem;
}



.user-info {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
}

.user-name {
    font-weight: 600;
    font-size: 0.9rem;
    color: white;
}

.user-role {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.7);
}

/* Дропдаун меню */
.dropdown-menu {
    background: rgba(26, 35, 126, 0.95);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    border-radius: 10px;
    margin-top: 0.5rem;
}

.dropdown-item {
    color: rgba(255, 255, 255, 0.9);
    padding: 0.75rem 1rem;
    display: flex;
    align-items: center;
    transition: all 0.3s ease;
}

.dropdown-item:hover {
    background: rgba(255, 255, 255, 0.1);
    color: white;
}

.dropdown-item i {
    width: 20px;
    text-align: center;
}

/* Адаптивность */
@media (max-width: 992px) {
    .search-box {
        position: fixed;
        top: 70px;
        left: 1rem;
        right: 1rem;
        width: auto;
    }

    .nav-text {
        font-size: 0.85rem;
    }

    .nav-icon {
        margin-right: 0.75rem;
    }
}

@media (max-width: 768px) {
    .navbar-nav .nav-item {
        margin-bottom: 0.25rem;
    }

    .nav-link {
        padding: 0.75rem !important;
        margin: 0.125rem 0;
    }

    .notification-badge {
        top: 5px;
        right: 5px;
    }
}