﻿@font-face {
    font-family: AESFont;
    src: url(/AESFont.ttf);
}

:root {
    --bg-body: #0b0b0e;
    --bg-block: rgba(24, 24, 32, 0.65);
    --bg-header: rgba(16, 16, 22, 0.96);
    --accent-orange: #ff761b;
    --accent-glow: rgba(255, 118, 27, 0.25);
    --text-primary: #f8fafc;
    --text-muted: #64748b;
    --border-classic: #232332;
    --radius-modern: 8px;
    --font-stack: 'AESFont', 'Inter', system-ui, -apple-system, sans-serif;
    --transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background-color: var(--bg-body);
    color: var(--text-primary);
    font-family: var(--font-stack);
    font-size: 14px;
    line-height: 1.5;
    padding-bottom: 3rem;
}

a {
    color: var(--accent-orange);
    text-decoration: none;
    transition: var(--transition);
    cursor: pointer;
}

    a:hover {
        color: #ff934b;
    }

/* --- ШАПКА САЙТА И НАВИГАЦИЯ --- */
.fa-nav {
    background-color: var(--bg-header);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border-classic);
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 999;
    height: 64px;
}

.nav-left, .nav-right {
    display: flex;
    align-items: center;
    gap: 20px;
    flex: 1;
}

.nav-right {
    justify-content: flex-end;
}

.nav-center {
    display: flex;
    justify-content: center;
    align-items: center;
    flex: 2;
}

.nav-links {
    display: flex;
    gap: 8px;
    list-style: none;
    align-items: center;
}

.nav-btn {
    color: var(--text-primary);
    font-weight: 600;
    font-size: 14px;
    padding: 8px 14px;
    border-radius: var(--radius-modern);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    text-wrap: nowrap;
}

    .nav-btn:hover {
        background-color: rgba(255,255,255,0.04);
        color: var(--accent-orange);
    }

.logo-area {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 18px;
    font-weight: 800;
    color: var(--accent-orange) !important;
    margin-right: 15px;
}

    .logo-area svg {
        fill: var(--accent-orange);
        width: 22px;
        height: 22px;
    }

/* Поиск по центру */
.search-box {
    background-color: rgba(11, 11, 14, 0.8);
    border: 1px solid var(--border-classic);
    color: var(--text-primary);
    padding: 8px 16px;
    border-radius: var(--radius-modern);
    outline: none;
    width: 320px;
    font-size: 14px;
    transition: var(--transition);
    text-align: center;
}

    .search-box:focus {
        border-color: var(--accent-orange);
        width: 420px;
        text-align: left;
        box-shadow: 0 0 15px var(--accent-glow);
    }

/* РАСШИРЕННОЕ МЕНЮ SUPPORT */
.dropdown-wrapper {
    position: relative;
    display: inline-block;
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    width: 260px;
    background-color: #121218;
    border: 1px solid var(--border-classic);
    border-radius: var(--radius-modern);
    box-shadow: 0 8px 32px rgba(0,0,0,0.5);
    display: none;
    flex-direction: column;
    padding: 8px 0;
    z-index: 250;
}

.dropdown-wrapper:hover .dropdown-menu {
    display: flex;
}

.dropdown-section {
    padding: 4px 0;
}

.dropdown-section-title {
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-muted);
    padding: 6px 16px 4px 16px;
    font-weight: 700;
    border-bottom: 1px solid var(--border-classic);
    margin-bottom: 4px;
}

.dropdown-menu a {
    display: block;
    padding: 6px 16px 6px 24px;
    color: var(--text-primary);
    font-size: 13px;
    transition: var(--transition);
}

    .dropdown-menu a:hover {
        background-color: rgba(255,255,255,0.04);
        color: var(--accent-orange);
    }

.btn-upload {
    background-color: rgba(255, 118, 27, 0.1);
    color: var(--accent-orange);
    border: 1px solid rgba(255, 118, 27, 0.2);
}

    .btn-upload:hover {
        background-color: var(--accent-orange);
        color: black !important;
    }

/* КНОПКА УВЕДОМЛЕНИЙ */
.notification-bell {
    position: relative;
    display: flex;
    align-items: center;
    cursor: pointer;
    padding: 6px 10px;
    border: 1px solid var(--border-classic);
    border-radius: var(--radius-modern);
    background-color: rgba(24, 24, 32, 0.4);
    transition: var(--transition);
}

    .notification-bell:hover {
        border-color: var(--accent-orange);
        background-color: rgba(255,118,27,0.08);
    }

    .notification-bell svg {
        fill: var(--text-muted);
        width: 20px;
        height: 20px;
        transition: var(--transition);
    }

    .notification-bell:hover svg {
        fill: var(--accent-orange);
    }

.notification-preview {
    display: none;
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    background-color: #121218;
    border: 1px solid var(--border-classic);
    border-radius: var(--radius-modern);
    padding: 10px 14px;
    min-width: 180px;
    z-index: 300;
    box-shadow: 0 8px 30px rgba(0,0,0,0.6);
    font-size: 13px;
    font-weight: 600;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: flex-start;
}

.notification-bell:hover .notification-preview {
    display: flex;
}

.notification-preview span {
    background: rgba(255,255,255,0.04);
    padding: 2px 8px;
    border-radius: 4px;
    border: 1px solid var(--border-classic);
    color: var(--text-primary);
}

    .notification-preview span:first-child {
        color: var(--accent-orange);
        border-color: rgba(255,118,27,0.3);
    }

/* Попап уведомлений */
.notification-popup {
    display: none;
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    background-color: #121218;
    border: 1px solid var(--border-classic);
    border-radius: var(--radius-modern);
    padding: 12px 16px;
    min-width: 280px;
    max-width: 360px;
    z-index: 350;
    box-shadow: 0 10px 40px rgba(0,0,0,0.7);
}

    .notification-popup.show {
        display: block;
    }

.popup-categories ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.popup-categories li {
    padding: 8px 4px;
    border-bottom: 1px solid var(--border-classic);
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-primary);
    transition: var(--transition);
}

    .popup-categories li:last-child {
        border-bottom: none;
    }

    .popup-categories li:hover {
        color: var(--accent-orange);
        padding-left: 8px;
    }

    .popup-categories li .badge {
        float: right;
        color: var(--text-muted);
        font-weight: 400;
        font-size: 12px;
    }

    .popup-categories li:hover .badge {
        color: var(--accent-orange);
    }

.popup-samples {
    display: none;
    flex-direction: column;
    gap: 10px;
}

    .popup-samples.active {
        display: flex;
    }

    .popup-samples .back-btn {
        color: var(--text-muted);
        font-size: 12px;
        cursor: pointer;
        margin-bottom: 6px;
        transition: var(--transition);
        background: none;
        border: none;
        text-align: left;
        padding: 0;
    }

        .popup-samples .back-btn:hover {
            color: var(--accent-orange);
        }

.sample-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 6px 8px;
    border-radius: var(--radius-modern);
    background: rgba(255,255,255,0.02);
    border: 1px solid var(--border-classic);
    transition: var(--transition);
}

    .sample-item:hover {
        border-color: var(--accent-orange);
    }

.sample-icon {
    width: 32px;
    height: 32px;
    background: #181824;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

    .sample-icon svg {
        fill: var(--text-muted);
        width: 18px;
        height: 18px;
    }

.sample-info {
    font-size: 13px;
}

    .sample-info .title {
        font-weight: 500;
    }

    .sample-info .sub {
        color: var(--text-muted);
        font-size: 11px;
    }

/* Аватар пользователя */
.user-avatar-trigger {
    width: 38px;
    height: 38px;
    border-radius: 6px;
    overflow: hidden;
    cursor: pointer;
    position: relative;
    flex-shrink: 0;
    border: 1px solid var(--border-classic);
}

    .user-avatar-trigger img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        display: block;
    }

.profile-popup {
    position: absolute;
    top: 48px;
    right: 0;
    width: 200px;
    background-color: #121218;
    border: 1px solid var(--border-classic);
    border-radius: var(--radius-modern);
    box-shadow: 0 10px 30px rgba(0,0,0,0.6);
    display: none;
    flex-direction: column;
    padding: 6px 0;
    z-index: 200;
}

    .profile-popup.show {
        display: flex;
    }

    .profile-popup a {
        padding: 10px 16px;
        color: var(--text-primary);
        font-size: 13px;
    }

        .profile-popup a:hover {
            background-color: rgba(255,255,255,0.03);
            color: var(--accent-orange);
        }

.popup-divider {
    height: 1px;
    background-color: var(--border-classic);
    margin: 6px 0;
}