/* ==========================================================================
   01. CORE & VARIABLES (Глобальные переменные, сброс, базовые теги)
   ========================================================================== */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

:root {
    --accent: #3d5afe;       /* Яркий неон */
    --accent-hover: #536dfe;
    --text: #ffffff;
    --text-dim: #b0b0b0;
    
    /* Цвета стекла */
    --glass-bg: rgba(20, 20, 20, 0.65);     /* Темное полупрозрачное стекло */
    --glass-border: rgba(255, 255, 255, 0.08); /* Тонкая рамка */
    --glass-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.5); /* Глубокая тень */
    
    --input-bg: rgba(0, 0, 0, 0.3); /* Фон инпутов (вдавленный) */
    
    --danger: #ff4757;
    --success: #2ed573;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body { 
    margin: 0;
    padding: 0;
    color: var(--text);
    font-family: 'Inter', sans-serif;
    min-height: 100vh;
    display: flex;
    flex-direction: column;

    /* Изображение теперь намертво прикреплено к экрану */
    background: url('/img/background.jpg') no-repeat center center fixed;
    background-size: cover;
}

/* Плавная прокрутка для всей страницы */
html {
    scroll-behavior: smooth;
}

/* Отступ для якоря, чтобы шапка не перекрывала заголовок */
section[id] {
    scroll-margin-top: 90px;
}

section, [id] {
    scroll-margin-top: 90px; /* Учитываем высоту навигации */
}

/* Запрет перетаскивания любых картинок и ссылок */
img, a {
    -webkit-user-drag: none;
    -khtml-user-drag: none;
    -moz-user-drag: none;
    -o-user-drag: none;
    user-drag: none;
}

/* --- УНИВЕРСАЛЬНАЯ ОБЕРТКА (ЦЕНТРИРОВАНИЕ) --- */
.page-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    /* ВАЖНО: прижимаем всё к верху, чтобы меню не прыгало */
    justify-content: flex-start; 
    
    /* Отступ сверху (высота навбара + зазор) */
    padding: 120px 20px 60px; 
    min-height: 100vh;
    width: 100%;
}
/* Убедись, что у тебя есть эти стили */
.content-wrapper {
    /* Заставляет блок занимать минимум всю высоту экрана */
    min-height: 100vh; 
    
    /* Центрирует карточки внутри по вертикали и горизонтали */
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    
    /* Отступ сверху, чтобы контент не залезал под навигацию (nav) */
    padding-top: 80px; 
    padding-bottom: 40px; /* Небольшой зазор снизу перед футером */
    box-sizing: border-box;
}

/* --- ИСПРАВЛЕНИЕ ШИРИНЫ КАБИНЕТА --- */
.content-area {
    flex-grow: 1;
    width: 100%; /* Заставляем контент занимать всё свободное место */
}

.content-area .card {
    /* Растягиваем на всю ширину контейнера (1150px) */
    width: 100% !important;
    max-width: 100% !important;
    min-height: 400px; /* Минимальная высота, чтобы не "схлопывалось" */
}

/* ==========================================================================
   02. TYPOGRAPHY, GLASSMORPHISM & GLOBALS (Общие классы и эффекты)
   ========================================================================== */
/* --- КОНТЕЙНЕРЫ И КАРТОЧКИ --- */
.container { 
    flex: 1; display: flex; flex-direction: column; align-items: center; 
    padding: 60px 20px; 
}
.container-center {
    background: rgba(0, 0, 0, 0.4);
    min-height: 100vh;
}

/* Основная карточка (Стекло) */
.card {
    padding: 40px;
    border-radius: 24px; /* iOS Roundness */
    width: 100%; max-width: 440px;
    margin-bottom: 20px;
}

/* --- СТЕКЛЯННЫЙ ЭФФЕКТ (МИКСИН) --- */
.card, nav, .stat-box, footer, .btn-glass {
    background: var(--glass-bg);
    backdrop-filter: blur(16px);        /* Размытие фона (Ключевое!) */
    -webkit-backdrop-filter: blur(16px); /* Для Safari/iOS */
    border: 1px solid var(--glass-border);
    box-shadow: var(--glass-shadow);
}

/* --- СТИЛЬ ДЛЯ СТРАНИЦЫ 404 --- */
.error-code {
    font-size: 8rem; /* Очень большая цифра */
    font-weight: 800;
    line-height: 1;
    margin: 0 0 10px 0;
    
    /* Градиентный текст */
    background: linear-gradient(135deg, #fff 30%, var(--accent) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    
    /* Тень */
    filter: drop-shadow(0 0 20px var(--accent-glow));
}

@keyframes slideRight { from { opacity: 0; transform: translateX(-30px); } to { opacity: 1; transform: translateX(0); } }

/* Стили для текстовых страниц */
.text-content h3 {
    color: var(--accent);
    margin-top: 25px;
    margin-bottom: 10px;
}

.text-content ul li {
    margin-bottom: 8px;
    position: relative;
    list-style: none;
}

.text-content ul li::before {
    content: "•";
    color: var(--accent);
    font-weight: bold;
    display: inline-block;
    width: 1em;
    margin-left: -1em;
}


/* ==========================================================================
   03. PRELOADER & PAGE TRANSITIONS (Загрузчик и анимации)
   ========================================================================== */
/* --- АНИМАЦИЯ ЗАГРУЗКИ (PRELOADER) --- */
#preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #0c0c0e; /* Твой темно-серый фон */
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10000; /* Выше всего */
    transition: opacity 0.5s ease, visibility 0.5s;
}

/* Стильный неоновый круг */
.loader-circle {
    width: 60px;
    height: 60px;
    border: 3px solid rgba(61, 90, 254, 0.1);
    border-top: 3px solid var(--accent);
    border-radius: 50%;
    position: relative;
    animation: spin 1s cubic-bezier(0.68, -0.55, 0.265, 1.55) infinite;
    box-shadow: 0 0 15px var(--accent-glow);
}

/* Внутреннее пульсирующее свечение */
.loader-circle::before {
    content: '';
    position: absolute;
    top: 5px; left: 5px; right: 5px; bottom: 5px;
    border: 3px solid rgba(61, 90, 254, 0.05);
    border-top: 3px solid #fff;
    border-radius: 50%;
    animation: spin 2s linear infinite reverse;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Класс для плавного исчезновения всей страницы при уходе */
.page-fade-out {
    opacity: 0 !important;
    transform: scale(0.98);
    transition: all 0.5s ease-in-out;
}

/* Класс для скрытия прелоадера */
.preloader-hidden {
    opacity: 0;
    visibility: hidden;
}


/* ==========================================================================
   04. BUTTONS, INPUTS & FORMS (Кнопки, поля ввода, капча, чекбоксы)
   ========================================================================== */
/* --- КНОПКИ (iOS Style) --- */
.btn {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    padding: 12px 24px;
    border-radius: 12px;
    border: none;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    font-family: inherit;
    font-size: 0.95rem;
    /* Плавный переход для всех свойств с более сложной кривой анимации */
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275); 
}
.btn:active {
    transform: translateY(0) scale(0.97); /* Кнопка "вдавливается" при клике */
}

.btn-small { width: auto !important; margin-top: 0; }
.btn-block { width: 100%; }

/* Основная кнопка (Градиент + Свечение) */
.btn-primary { 
    background: linear-gradient(135deg, var(--accent), #5c6bc0);
    color: #fff; 
    box-shadow: 0 4px 15px rgba(61, 90, 254, 0.4);
    border: 1px solid rgba(255,255,255,0.1);
}
.btn-primary:hover {
    box-shadow: 0 12px 25px var(--accent-glow);
}

/* Стеклянная кнопка (Второстепенная) */
.btn-outline { 
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #fff; 
}
.btn-outline:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: #fff;
    box-shadow: 0 8px 20px rgba(255, 255, 255, 0.1);
}

.btn-claim { background: var(--success); color: #fff; padding: 5px 15px; border-radius: 8px; text-decoration: none; font-size: 0.8rem; }
.btn-close { background: var(--danger); color: #fff; padding: 5px 15px; border-radius: 8px; text-decoration: none; font-size: 0.8rem; }

/* Кнопка "Назад к списку" */
.btn-back {
    background: transparent;
    color: var(--text-dim);
    border: none;
    cursor: pointer;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 5px;
    margin-bottom: 15px;
}
.btn-back:hover { color: #fff; }

.btn-back {
    text-decoration: none;
    color: var(--text-dim);
    font-size: 0.9rem;
}
.btn-back:hover { color: #fff; }

/* Кнопка выхода в профиле */
.btn-logout {
    margin-top: 15px;
    background: rgba(255, 255, 255, 0.05); /* Легкий красный фон */
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #fff;
    font-size: 0.9rem;
    font-weight: 600;
    transition: 0.3s;
}

.btn-logout:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: #fff;
    box-shadow: 0 8px 20px rgba(255, 255, 255, 0.1);
}

.cf-turnstile {
    width: 100%;
    min-height: 65px;
    
    /* --- ДОБАВЬ ЭТИ СТРОКИ --- */
    margin-top: 25px;    /* Опускает капчу вниз от пароля */
    margin-bottom: 25px; /* Отодвигает кнопку "Войти" ниже */
}

/* --- СТИЛЬ ЧЕКБОКСА "ЗАПОМНИТЬ МЕНЯ" --- */
.checkbox-remember {
    display: flex;
    align-items: center;
    justify-content: flex-start; /* Выравнивание по левому краю */
    margin-top: 15px;
    margin-bottom: 20px;
}

.checkbox-remember input[type="checkbox"] {
    appearance: none; /* Убираем стандартный вид */
    width: 18px;
    height: 18px;
    background: rgba(0,0,0,0.3);
    border: 1px solid var(--glass-border);
    border-radius: 4px;
    cursor: pointer;
    position: relative;
    transition: 0.2s;
    margin-right: 10px;
}

.checkbox-remember input[type="checkbox"]:checked {
    background: var(--accent); /* Синий цвет при выборе */
    border-color: var(--accent);
}

/* Галочка внутри чекбокса */
.checkbox-remember input[type="checkbox"]:checked::before {
    content: '✓';
    font-size: 14px;
    color: white;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.checkbox-remember label {
    font-size: 0.85rem;
    color: var(--text-dim);
    cursor: pointer;
}

/* Поля ввода (Вдавленные) */
.input-group { margin-bottom: 15px; width: 100%; }
.input-group label { display: block; font-size: 0.85rem; color: var(--text-dim); margin-bottom: 8px; margin-left: 5px; }

input, select {
    width: 100%; padding: 14px 18px; 
    background: var(--input-bg); /* Темный фон */
    border: 1px solid transparent; /* Без границ по умолчанию */
    border-radius: 12px; 
    color: #fff; outline: none; transition: 0.3s;
    font-size: 0.95rem;
}
input:focus { 
    background: rgba(0, 0, 0, 0.5);
    border-color: var(--accent); 
    box-shadow: 0 0 0 4px rgba(61, 90, 254, 0.15); /* Эффект фокуса как в macOS */
}

/* Убираем уродливый фон автозаполнения */
input:-webkit-autofill,
input:-webkit-autofill:hover, 
input:-webkit-autofill:focus, 
input:-webkit-autofill:active{
    -webkit-box-shadow: 0 0 0 30px #1a1a1a inset !important; /* Цвет твоего инпута */
    -webkit-text-fill-color: white !important; /* Цвет текста */
    transition: background-color 5000s ease-in-out 0s;
}

/* --- ИНДИКАТОР СЛОЖНОСТИ ПАРОЛЯ --- */
.password-strength-bar {
    width: 100%;
    height: 5px;
    background: rgba(0,0,0,0.3);
    border-radius: 5px;
    margin-top: 5px;
    overflow: hidden;
}

.strength-meter {
    height: 100%;
    width: 0%;
    transition: width 0.3s ease, background-color 0.3s ease;
}

/* Красный - слабый */
.strength-weak { width: 33%; background-color: var(--danger); }
/* Желтый - средний */
.strength-medium { width: 66%; background-color: #f1c40f; }
/* Зеленый - сильный */
.strength-strong { width: 100%; background-color: var(--success); }

/* Контейнер, относительно которого мы позиционируем глаз */
.password-wrapper {
    position: relative; /* Это важно! */
    width: 100%;
    display: flex; /* Чтобы инпут не ломался */
    align-items: center;
}

/* Сам инпут пароля */
.password-wrapper input {
    width: 100%;
    /* Добавляем отступ справа, чтобы текст не наезжал на глаз */
    padding-right: 45px; 
}

/* Кнопка глаза */
.btn-toggle-pass {
    position: absolute; /* Абсолютное позиционирование поверх инпута */
    right: 12px;        /* Прижимаем к правому краю */
    top: 50%;           /* Центр по вертикали */
    transform: translateY(-50%); /* Коррекция центровки */
    
    background: none;
    border: none;
    cursor: pointer;
    color: var(--text-dim); /* Цвет как у текста */
    padding: 5px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.3s;
    z-index: 10;
}

.btn-toggle-pass:hover {
    color: #fff; /* При наведении становится белым */
    transform: translateY(-50%) scale(1.1);
}

/* Размер иконки */
.btn-toggle-pass svg {
    width: 20px;
    height: 20px;
}

/* --- СТИЛЬ ЗВЕЗДНОГО РЕЙТИНГА --- */
.star-rating-input {
    display: flex;
    flex-direction: row-reverse; /* Заставляет звезды работать справа налево */
    justify-content: flex-end;
    align-items: center;
}

/* Скрываем реальные радио-кнопки */
.star-rating-input > input {
    display: none;
}

/* Сама звезда (через CSS) */
.star-rating-input > label {
    cursor: pointer;
    width: 25px;
    height: 25px;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='gray'%3e%3cpath d='M12 17.27L18.18 21l-1.64-7.03L22 9.24l-7.19-.61L12 2 9.19 8.63 2 9.24l5.46 4.73L5.82 21z'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: center;
    background-size: 80%;
    transition: 0.3s;
}

/* Эффект наведения: закрашиваем звезду и все слева от неё */
.star-rating-input > label:hover,
.star-rating-input > label:hover ~ label {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23ffc107'%3e%3cpath d='M12 17.27L18.18 21l-1.64-7.03L22 9.24l-7.19-.61L12 2 9.19 8.63 2 9.24l5.46 4.73L5.82 21z'/%3e%3c/svg%3e");
}

/* Когда радио-кнопка выбрана — звезды слева от неё тоже закрашиваются */
.star-rating-input > input:checked ~ label {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23ffc107'%3e%3cpath d='M12 17.27L18.18 21l-1.64-7.03L22 9.24l-7.19-.61L12 2 9.19 8.63 2 9.24l5.46 4.73L5.82 21z'/%3e%3c/svg%3e");
}

/* Статусы тикетов */
.status-badge { padding: 4px 10px; border-radius: 6px; font-size: 0.75rem; font-weight: 700; text-transform: uppercase; }
.status-open { background: rgba(255, 204, 0, 0.15); color: #ffcc00; border: 1px solid rgba(255, 204, 0, 0.3); }
.status-answered { background: rgba(46, 213, 115, 0.15); color: #2ed573; border: 1px solid rgba(46, 213, 115, 0.3); }
.status-closed { background: rgba(255, 71, 87, 0.15); color: #ff4757; border: 1px solid rgba(255, 71, 87, 0.3); }
.status-completed { background: rgba(94, 114, 228, 0.15); color: var(--accent); border: 1px solid var(--accent); } 
.status-closed { background: rgba(255, 255, 255, 0.05); color: #666; border: 1px solid #333; }

.status-badge {
    font-size: 0.7rem;
    font-weight: 800;
    padding: 4px 10px;
    border-radius: 6px;
}
.status-paid { background: rgba(45, 206, 137, 0.15); color: var(--success); border: 1px solid var(--success); }
.status-pending { background: rgba(251, 175, 21, 0.15); color: #fbaf15; border: 1px solid #fbaf15; }

table { width: 100%; border-collapse: collapse; margin-top: 15px; }
th, td { padding: 15px; text-align: left; border-bottom: 1px solid rgba(255,255,255,0.05); font-size: 0.9rem; }
th { color: var(--text-dim); font-weight: 500; }


/* ==========================================================================
   05. NAVIGATION & HEADER (Шапка сайта, Логотип, Навигация)
   ========================================================================== */

/* --- СТИЛИ ИКОНОК В НАВ БАР МЕНЮ --- */

.dropdown-icon {
    width: 18px;          /* Оптимальный размер для меню */
    height: 18px;
    object-fit: contain;  /* Чтобы иконка не растягивалась */
    opacity: 1;         /* Делаем чуть тусклее в обычном состоянии */
    transition: 0.3s ease;
}

/* Эффект при наведении на всю ссылку */
.dropdown-menu a:hover .dropdown-icon {
    opacity: 1;           /* Становится яркой */
    transform: scale(1.1); /* Слегка увеличивается */
    /* Добавляем легкое свечение под цвет твоего акцента */
    filter: drop-shadow(0 0 5px var(--accent-glow));
}

/* Специальный фильтр для иконки выхода (если хочешь, чтобы она светилась красным) */
.logout-link:hover .dropdown-icon {
    filter: drop-shadow(0 0 5px rgba(245, 54, 92, 0.5));
}

/* Выравнивание текста и иконки */
.dropdown-menu a {
    display: flex;
    align-items: center;
    gap: 12px; /* Расстояние между иконкой и текстом */
    padding: 10px 15px;
    color: var(--text-dim);
    text-decoration: none;
    font-size: 0.85rem;
    transition: 0.2s;
}

/* --- ВЫПАДАЮЩЕЕ МЕНЮ ЮЗЕРА В НАВ БАР --- */

.user-dropdown {
    position: relative;
    margin-left: 20px;
    padding: 5px 0;
}

.nav-avatar-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    transition: 0.3s;
}

.nav-avatar {
    width: 35px;
    height: 35px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--accent);
    box-shadow: 0 0 10px var(--accent-glow);
}

.arrow-down-mini {
    border: solid var(--text-dim);
    border-width: 0 2px 2px 0;
    display: inline-block;
    padding: 2px;
    transform: rotate(45deg);
    transition: 0.3s;
}


/* Контейнер меню */
.dropdown-menu {
    position: absolute;
    top: 55px; /* Дистанция от аватара */
    right: 0;
    width: 220px;
    background: rgba(27, 27, 27, 0.95);
    backdrop-filter: blur(15px);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 10px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    box-shadow: 0 15px 35px rgba(0,0,0,0.6);
    
    /* Анимация скрытия */
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 2000;
}

/* Показ при наведении */
.user-dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.user-dropdown:hover .arrow-down-mini {
    transform: rotate(-135deg);
    border-color: #fff;
}

/* Заголовок меню (имя и UID) */
.dropdown-header {
    padding: 10px 15px;
    display: flex;
    flex-direction: column;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    margin-bottom: 5px;
}
.dropdown-header b { font-size: 0.95rem; color: #fff; }
.dropdown-header span { font-size: 0.75rem; color: var(--text-dim); }

/* Ссылки внутри меню */
.dropdown-menu a {
    padding: 12px 15px;
    color: var(--text-dim);
    text-decoration: none;
    font-size: 0.85rem;
    border-radius: 10px;
    transition: 0.2s;
    display: flex;
    align-items: center;
    gap: 10px;
}

.dropdown-menu a:hover {
    background: rgba(255, 255, 255, 0.05);
    color: #dad7d7;
}

.dropdown-divider {
    height: 1px;
    background: rgba(255, 255, 255, 0.05);
    margin: 5px 10px;
}

.logout-link:hover {
    color: var(--danger) !important;
    background: rgba(245, 54, 92, 0.1) !important;
}

/* Невидимый мостик, чтобы меню не закрывалось, пока ведешь мышку */
.user-dropdown::after {
    content: "";
    position: absolute;
    top: 30px; right: 0;
    width: 100%; height: 30px;
}

/* Контейнер логотипа */
.logo-container {
    display: flex;
    align-items: center; /* Выравнивание иконки и текста по одной линии */
    gap: 10px;           /* Расстояние между иконкой и текстом */
    text-decoration: none;
    transition: 0.3s ease;
}

/* Сама иконка */
.nav-icon {
    width: 200px;         /* Маленький размер иконки */
    height: 200px;
    object-fit: contain;
    /* Легкое свечение под цвет акцента */
    filter: drop-shadow(0 0 5px var(--accent-glow)); 
}

/* Текст логотипа (как на твоем скрине) */
.logo-text {
    font-weight: 800;
    font-size: 1.2rem;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: -0.5px;
}

.logo-text span {
    color: var(--accent);
}

/* Эффект при наведении на всю группу (иконка + текст) */
.logo-container:hover {
    filter: brightness(1.2);
    transform: scale(1.02);
}

/* --- НАВИГАЦИЯ --- */
nav {
    height: 65px;
    background: rgba(0, 0, 0, 0.3); /* Очень легкое затемнение */
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 10%;
    position: fixed; /* Навигация всегда сверху */
    top: 0; 
    width: 100%;
    z-index: 1000;
}

.logo { font-weight: 800; font-size: 1.7rem; color: #fff; text-decoration: none; letter-spacing: -0.5px;  }
.logo span { color: var(--accent); }

.nav-links { display: flex; gap: 25px; }
.nav-links a { color: var(--text-dim); text-decoration: none; font-size: 0.9rem; transition: 0.3s; font-weight: 500; }
.nav-links a:hover { color: #fff; text-shadow: 0 0 10px rgba(255,255,255,0.5); }

/* --- СКОЛЬЗЯЩЕЕ МЕНЮ --- */

.nav-links {
    position: relative; /* Чтобы бэкдроп позиционировался относительно этого блока */
    display: flex;
    align-items: center;
    gap: 5px; /* Отступы между ссылками */
    background: rgba(255, 255, 255, 0.05); /* Легкий фон под всем меню (опционально) */
    padding: 5px;
    border-radius: 12px; /* Скругление всего блока меню */
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.nav-item {
    position: relative;
    z-index: 2; /* Текст должен быть ВЫШЕ бэкдропа */
    color: var(--text-dim);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    padding: 8px 16px; /* Внутренние отступы кнопок */
    transition: color 0.3s;
    border-radius: 8px;
}

/* При наведении текст становится белым */
.nav-item:hover {
    color: #fff;
}

/* ТОТ САМЫЙ БЕГАЮЩИЙ БЛОК */
.nav-backdrop {
    position: absolute;
    top: 5px; /* Отступ сверху (совпадает с padding .nav-links) */
    left: 0;
    height: calc(100% - 10px); /* Высота минус отступы */
    background: rgba(255, 255, 255, 0.1); /* Цвет плашки */
    border-radius: 8px; /* Скругление плашки */
    z-index: 1; /* Под текстом */
    
    /* Скрыт по умолчанию */
    opacity: 0; 
    
    /* Плавная анимация движения и изменения ширины */
    transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
    pointer-events: none; /* Чтобы не мешал кликать */
}


/* ==========================================================================
   06. HERO SECTION (Главная страница, приветственный экран)
   ========================================================================== */
/* --- ЦЕНТРИРОВАННЫЙ ГЛАВНЫЙ ЭКРАН --- */
.hero-centered {
    height: 100vh;
    display: flex;
    justify-content: center; /* Центр по горизонтали */
    align-items: center;     /* Центр по вертикали */
    padding: 0 5%;
    background: transparent; 
}

/* --- ГЛАВНАЯ (HERO) --- */
.hero-left {
    height: 100vh; /* Ровно на весь экран при заходе */
    display: flex;
    align-items: center;
    padding: 0 10%;
    /* Убираем все подложки и градиенты здесь, чтобы видеть чистое фото */
    background: transparent; 
}

.hero-text-block {
    max-width: 500px;
    animation: slideRight 0.8s ease;
    /* Оставляем небольшую стеклянную карточку только под текстом, 
       чтобы буквы не сливались с фоном */
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(10px);
    padding: 40px;
    border-radius: 24px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.hero-text-block h1 {
    font-size: 4rem;
    margin-bottom: 15px;
    line-height: 1;
    text-shadow: 0 5px 15px rgba(0,0,0,0.5);
}
.hero-text-block h1 span { color: var(--accent); }
.hero-text-block p {
    color: #ddd;
    font-size: 1.1rem;
    margin-bottom: 30px;
    line-height: 1.6;
}


/* ==========================================================================
   07. DASHBOARD & PROFILE (Личный кабинет, профиль пользователя)
   ========================================================================== */

/* --- КАРТОЧКА ПРОФИЛЯ (РАСТЯНУТАЯ) --- */
.card-wide {
    width: 100% !important;
    max-width: 100% !important;
}

.dashboard-wrapper {
    display: flex;
    justify-content: center;
    padding: 60px 5%;
    min-height: 80vh;
}

.cabinet-container {
    display: flex;
    flex-direction: column;
    width: 100%;
    /* Ограничиваем ширину как на скрине */
    max-width: 1150px; 
    gap: 25px;
}

/* --- ГОРИЗОНТАЛЬНОЕ МЕНЮ АДМИНКИ (ВМЕСТО САЙДБАРА) --- */
.admin-menu-bar {
    width: 100%;
    background: var(--glass-bg);
    backdrop-filter: blur(15px);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    padding: 6px;
    display: flex;
    position: relative;
    /* Фиксируем высоту, чтобы анимация была плавной */
    height: 60px; 
    flex-shrink: 0; 
}

/* Летающая плашка (Горизонтальная) */
.admin-menu-backdrop {
    position: absolute;
    top: 5px;
    left: 0;
    height: calc(100% - 10px);
    background: var(--accent);
    box-shadow: 0 4px 15px var(--accent-glow);
    border-radius: 12px;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    opacity: 0;
    z-index: 1;
}
.admin-menu-btn {
    position: relative;
    z-index: 2;
    flex: 1; /* Кнопки одинаковой ширины */
    text-align: center;
    padding: 12px;
    color: var(--text-dim);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 600;
    transition: 0.3s;
}

.admin-menu-btn:hover, .admin-menu-btn.active {
    color: #fff;
}

/* Контейнер контента под меню */
.admin-content-wrap {
    width: 100%;
    max-width: 1300px;
    margin: 0 auto;
}

/* Исправление центрирования всей страницы */
.admin-page-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 100px 20px 50px; /* Отступ под Nav */
    width: 100%;
}

/* Исправление наложения заголовков */
.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--glass-border);
}

.section-header h2, .section-header h3 {
    margin: 0; /* Убираем дефолтные отступы, которые создают наложения */
}

/* --- ЦЕНТРИРОВАНИЕ ЛИЧНОГО КАБИНЕТА --- */
.dashboard-container {
    display: flex;
    justify-content: center;  /* Центр по горизонтали */
    align-items: center;      /* Центр по вертикали */
    min-height: calc(100vh - 70px); /* Высота экрана минус высота навигации */
    padding: 40px 10%;
    width: 100%;
}

.dashboard-grid {
    display: grid;
    grid-template-columns: 350px 1fr; /* Левая колонка 350px, правая — всё остальное */
    gap: 30px;
    width: 100%;
    max-width: 1150px; /* Ограничиваем общую ширину, чтобы не растягивалось на весь монитор */
    animation: fadeInUp 0.8s ease;
}

/* Фикс для маленьких карточек справа, чтобы они были одинаковой ширины */
.dashboard-grid .card {
    width: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* Адаптивность: если экран маленький, ставим блоки друг под друга */
@media (max-width: 1000px) {
    .dashboard-container {
        align-items: flex-start; /* На мобилках лучше от верха */
        padding-top: 100px;
    }
    .dashboard-grid {
        grid-template-columns: 1fr;
        max-width: 500px; /* Сужаем для мобилок */
    }
}

/* Адаптивность */
@media (max-width: 900px) {
    .cabinet-container { flex-direction: column; }
    .sidebar { width: 100%; flexDirection: row; overflow-x: auto; }
}

/* --- СТИЛИ ПРОФИЛЯ (КАК НА СКРИНШОТЕ) --- */
.profile-form-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr); /* 3 колонки вместо 2 */
    gap: 20px;
    margin-top: 30px;
}

/* Блок инпута */
.profile-input-box {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 12px 15px;
    text-align: left;
    transition: 0.3s;
}

.profile-input-box:focus-within {
    background: rgba(255, 255, 255, 0.06);
    border-color: var(--accent);
}

.profile-input-box label {
    display: block;
    font-size: 0.75rem;
    color: var(--text-dim);
    margin-bottom: 4px;
}

/* Сам невидимый инпут внутри блока */
.profile-input-box input {
    width: 100%;
    background: transparent;
    border: none;
    color: #fff;
    font-size: 0.95rem;
    outline: none;
    padding: 0;
    font-family: inherit;
}

/* Заблокированный инпут (логин) */
.profile-input-box.disabled {
    background: rgba(0, 0, 0, 0.2);
    cursor: not-allowed;
}
.profile-input-box.disabled input {
    color: #777;
    cursor: not-allowed;
}

/* Растягиваем нижнюю панель с кнопками на всю ширину карточки */
.profile-actions-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid var(--glass-border);
    width: 100%;
}

.profile-actions-left {
    display: flex;
    gap: 10px;
}

/* Адаптивность для мобилок */
@media (max-width: 768px) {
    .profile-form-grid { grid-template-columns: 1fr; }
    .profile-actions-bar { flex-direction: column; gap: 15px; align-items: stretch; }
    .profile-actions-left { flex-direction: column; }
}

/* Добавь/Замени это ниже: */
.profile-input-box {
    position: relative;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 0; /* Убрали паддинг, он теперь у инпута */
    transition: 0.3s border-color, 0.3s background;
    height: 55px; /* Фиксированная высота для красоты */
}
/* При клике на инпут */
.profile-input-box:focus-within {
    background: rgba(255, 255, 255, 0.06);
    border-color: var(--accent); /* Подсветка только рамки, без свечения внутри */
}
/* Сам невидимый инпут */
.profile-input-box input {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: transparent;
    border: none;
    color: #fff;
    font-size: 0.95rem;
    outline: none;
    padding: 22px 15px 8px 15px; /* Сдвигаем текст ввода вниз, освобождая место сверху */
    font-family: inherit;
    z-index: 2;
}
/* Текст (ярлык), который будет летать */
.profile-input-box label {
    position: absolute;
    top: 50%;
    left: 15px;
    transform: translateY(-50%);
    font-size: 0.95rem;
    color: var(--text-dim);
    pointer-events: none; /* Чтобы клик проходил сквозь текст на инпут */
    transition: 0.2s ease-out;
    z-index: 1;
    margin: 0;
}
/* 
  МАГИЯ АНИМАЦИИ: 
  Если на инпут нажали (:focus) ИЛИ в инпуте УЖЕ есть текст (:not(:placeholder-shown))
  -> Поднимаем ярлык наверх и уменьшаем его
*/
.profile-input-box input:focus ~ label,
.profile-input-box input:not(:placeholder-shown) ~ label {
    top: 8px;
    transform: translateY(0);
    font-size: 0.7rem;
    color: var(--accent); /* При фокусе текст подписи синий */
}

/* Когда текст есть, но фокуса нет - оставляем ярлык сверху, но серым */
.profile-input-box input:not(:placeholder-shown):not(:focus) ~ label {
    color: var(--text-dim);
}

/* Стили для заблокированного логина */
.profile-input-box.disabled {
    background: rgba(0, 0, 0, 0.2);
    border-color: transparent;
}
.profile-input-box.disabled input {
    color: #777;
    cursor: not-allowed;
}
.profile-input-box.disabled label {
    color: #555;
}

/* --- СТИЛИ ДЛЯ UID И РОЛИ В ПРОФИЛЕ --- */
.profile-meta-box {
    background: rgba(255, 255, 255, 0.03);
    border-radius: 12px;
    padding: 12px 15px;
    margin-bottom: 20px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.meta-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0; /* Увеличили отступы для 3-х строк */
    font-size: 0.9rem;
}

/* Добавляем полоску между всеми строками, кроме последней */
.meta-row:not(:last-child) {
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.meta-label {
    color: var(--text-dim);
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.uid-value {
    font-family: monospace;
    color: #fff;
    background: rgba(0, 0, 0, 0.3);
    padding: 2px 6px;
    border-radius: 4px;
}

/* Бейджи для ролей */
.role-badge {
    font-size: 0.75rem;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Цвета для разных ролей */
.role-owner {
    background: rgba(255, 204, 0, 0.15);
    color: #ffcc00;
    border: 1px solid rgba(255, 204, 0, 0.3);
    box-shadow: 0 0 10px rgba(255, 204, 0, 0.15);
}

.role-admin {
    background: rgba(255, 71, 87, 0.15);
    color: #ff4757;
    border: 1px solid rgba(255, 71, 87, 0.3);
}

/* Модератор (Фиолетовый) */
.role-moderator {
    background: rgba(155, 89, 182, 0.15);
    color: #9b59b6;
    border: 1px solid rgba(155, 89, 182, 0.3);
    box-shadow: 0 0 10px rgba(155, 89, 182, 0.2);
}

/* Бета-тестер (Голубой) */
.role-beta {
    background: rgba(52, 152, 219, 0.15);
    color: #3498db;
    border: 1px solid rgba(52, 152, 219, 0.3);
    box-shadow: 0 0 10px rgba(52, 152, 219, 0.2);
}

/* Партнер (Розовый/Малиновый) */
.role-partner {
    background: rgba(233, 30, 99, 0.15);
    color: #e91e63;
    border: 1px solid rgba(233, 30, 99, 0.3);
    box-shadow: 0 0 10px rgba(233, 30, 99, 0.2);
}

.role-client {
    background: rgba(46, 213, 115, 0.15);
    color: #2ed573;
    border: 1px solid rgba(46, 213, 115, 0.3);
}

.role-user {
    background: rgba(255, 255, 255, 0.1);
    color: #aaa;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* --- АВАТАРКИ --- */
.avatar-container {
    position: relative;
    width: 100px;
    height: 100px;
    margin: 0 auto 15px;
}

.avatar-img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--accent);
    box-shadow: 0 0 15px var(--accent-glow);
}

.avatar-upload-btn {
    position: absolute;
    bottom: 0;
    right: 0;
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: 50%;
    width: 32px;
    height: 32px;
    display: flex; justify-content: center; align-items: center;
    cursor: pointer;
    color: var(--text);
    font-size: 1.2rem;
    transition: 0.3s;
}
.avatar-upload-btn:hover { background: var(--accent); }


/* ==========================================================================
   08. SHOP & CATALOG (Магазин, Каталог товаров)
   ========================================================================== */

/* Основной контейнер магазина */
.shop-page-wrapper {
    width: 100%;
    max-width: 1300px;
    margin: 100px auto 50px auto; /* 100px отступ сверху, авто-центр */
    padding: 0 20px;
    display: flex;
    gap: 30px;
}


/* Контейнер товаров */
.shop-catalog {
    display: grid;
    /* 6 товаров в ряд */
    grid-template-columns: repeat(6, 1fr); 
    gap: 15px;
    width: 100%;
}

/* Карточка товара */
.product-item {
    background: rgba(20, 20, 20, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 15px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: 0.3s;
}

.product-item:hover { transform: translateY(-5px); border-color: var(--accent); }

.product-img-box {
    width: 100%;
    height: 180px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 15px;
}

.product-img { max-width: 100%; max-height: 100%; object-fit: contain; }

/* Название и цена */
.product-title {
    font-size: 0.85rem;
    font-weight: 600;
    margin-top: 10px;
    color: #fff;
}
.product-price {
    font-size: 1rem;
    font-weight: 800;
    color: var(--accent);
    margin: 5px 0 10px 0;
}


/* Статусы товара */
.prod-status { font-size: 0.75rem; font-weight: 700; padding: 3px 8px; border-radius: 6px; display: inline-block; margin-bottom: 10px; }
.st-in_stock { background: rgba(45, 206, 137, 0.15); color: var(--success); }
.st-preorder { background: rgba(251, 175, 21, 0.15); color: #fbaf15; }
.st-out_of_stock { background: rgba(245, 54, 92, 0.15); color: var(--danger); }

/* --- СТРАНИЦА ОДНОГО ТОВАРА --- */
.product-page-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    background: var(--glass-bg);
    padding: 40px;
    border-radius: 24px;
    border: 1px solid var(--glass-border);
}
.product-page-img { width: 100%; border-radius: 16px; background: rgba(0,0,0,0.3); padding: 20px; object-fit: contain; max-height: 400px; }
.product-page-price { font-size: 3rem; font-weight: 800; color: var(--accent); margin: 20px 0; }

@media (max-width: 900px) {
    .shop-layout { flex-direction: column; }
    .shop-sidebar { width: 100%; }
    .product-page-grid { grid-template-columns: 1fr; }
}

/* --- КОНТЕЙНЕР МАГАЗИНА --- */

/* --- СТИЛЬ ЗАГЛУШКИ ДЛЯ ЗАКАЗОВ --- */
.no-recent-orders {
    background: rgba(255, 255, 255, 0.02);
    border: 1px dashed rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 30px;
    text-align: center;
    color: var(--text-dim);
    transition: 0.3s;
}

.no-recent-orders:hover {
    background: rgba(255, 255, 255, 0.04);
    border-color: var(--accent);
}

.no-recent-orders p {
    margin: 0;
    font-weight: 600;
    font-size: 0.95rem;
    color: #fff;
}

.no-recent-orders small {
    display: block;
    margin-top: 5px;
    font-size: 0.8rem;
    opacity: 0.6;
}

/* --- МИНИ-КАРТОЧКИ ПОСЛЕДНИХ ЗАКАЗОВ --- */
.recent-orders-header {
    margin-top: 40px;
    margin-bottom: 20px;
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text);
    display: flex;
    align-items: center;
    gap: 10px;
}

.recent-orders-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr); /* 3 колонки в ряд */
    gap: 20px;
}

.recent-orders-list {
    margin-top: 30px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.mini-order-row {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 12px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    text-decoration: none;
    color: inherit;
    transition: 0.3s;
}

.mini-order-row:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: var(--accent);
    transform: translateX(5px);
}

.mo-left {
    display: flex;
    align-items: center;
    gap: 15px;
    flex: 1;
}

.mo-img {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    object-fit: cover;
    background: rgba(0,0,0,0.2);
}

.mo-details h4 {
    margin: 0;
    font-size: 0.9rem;
    font-weight: 600;
}

.mo-details span {
    font-size: 0.7rem;
    color: var(--text-dim);
}

.mo-price {
    font-weight: 800;
    color: var(--accent);
    font-size: 0.95rem;
    margin: 0 30px;
}

.mo-right {
    display: flex;
    align-items: center;
    gap: 15px;
}

    /* --- CSS ТОЛЬКО ДЛЯ МАГАЗИНА --- */
    .shop-layout {
        display: flex;
        gap: 30px;
        width: 100%;
        max-width: 1400px;
        margin: 0 auto;
        align-items: flex-start;
    }

    /* Сайдбар слева */
    .shop-sidebar {
        width: 260px;
        background: rgba(15, 15, 17, 0.7);
        backdrop-filter: blur(15px);
        border: 1px solid rgba(255, 255, 255, 0.08);
        border-radius: 16px;
        padding: 25px;
        flex-shrink: 0;
        position: sticky; /* Прилипает при скролле */
        top: 90px;
    }

    .filter-title {
        font-size: 1.1rem;
        font-weight: 800;
        margin-bottom: 20px;
        border-bottom: 1px solid rgba(255,255,255,0.1);
        padding-bottom: 10px;
        color: #fff;
    }

    .filter-list { display: flex; flex-direction: column; gap: 8px; }
    
    .filter-btn {
        background: transparent;
        border: none;
        color: #adb5bd;
        text-align: left;
        cursor: pointer;
        font-size: 0.95rem;
        padding: 8px 12px;
        border-radius: 8px;
        transition: 0.2s;
    }
    .filter-btn:hover, .filter-btn.active {
        background: rgba(61, 90, 254, 0.15); /* Цвет акцента */
        color: #fff;
    }

    /* Верхняя панель (Поиск + Сортировка) */
    .shop-controls {
        width: 100%;
        display: flex;
        justify-content: space-between;
        align-items: center;
        background: rgba(15, 15, 17, 0.7);
        padding: 15px 25px;
        border-radius: 16px;
        border: 1px solid rgba(255, 255, 255, 0.08);
        margin-bottom: 30px;
        gap: 20px;
        backdrop-filter: blur(15px);
    }

    .search-input-wrapper {
        flex: 1;
        position: relative;
    }

    .search-input-wrapper input {
        width: 100%;
        padding: 12px 15px 12px 40px;
        margin: 0;
        background: rgba(0,0,0,0.3);
        border: 1px solid rgba(255,255,255,0.1);
        border-radius: 10px;
        color: #fff;
        outline: none;
    }
    .search-input-wrapper input:focus { border-color: #3d5afe; }

    .search-icon-fixed {
        position: absolute;
        left: 12px; top: 50%; transform: translateY(-50%);
        opacity: 0.5;
    }

    .toolbar-group { display: flex; gap: 10px; align-items: center; }

    /* Сетка товаров (ПО УМОЛЧАНИЮ ПЛИТКА) */
    .shop-catalog {
        display: grid;
        /* Создает карточки по ~200px. На большом экране влезет 5-6 штук */
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: 20px;
        width: 100%;
    }

    /* Карточка товара (Режим Плитки) */
    .product-item {
        background: rgba(20, 20, 20, 0.7);
        backdrop-filter: blur(10px);
        border: 1px solid rgba(255, 255, 255, 0.08);
        border-radius: 16px;
        padding: 15px;
        display: flex;
        flex-direction: column;
        text-align: center;
        text-decoration: none;
        color: inherit;
        transition: 0.3s;
        height: 100%;
    }

    .product-item:hover {
        transform: translateY(-5px);
        border-color: #3d5afe;
        box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    }

    .product-img-box {
        width: 100%;
        aspect-ratio: 1 / 1;
        background: rgba(255,255,255,0.02);
        border-radius: 12px;
        display: flex;
        align-items: center;
        justify-content: center;
        margin-bottom: 15px;
    }

    .product-img { max-width: 80%; max-height: 80%; object-fit: contain; }

    .product-info {
        display: flex;
        flex-direction: column;
        flex-grow: 1; /* Чтобы кнопка всегда была внизу */
    }

    .product-title { font-weight: 600; font-size: 0.95rem; margin-bottom: 5px; }
    .product-price { color: #3d5afe; font-weight: 800; font-size: 1.2rem; margin: auto 0 15px 0; }

    /* --- РЕЖИМ СПИСКА (1 В РЯД) --- */
    /* Когда добавляем класс .list-view к .shop-catalog */
    .shop-catalog.list-view {
        grid-template-columns: 1fr; /* Одна колонка */
    }

    .shop-catalog.list-view .product-item {
        flex-direction: row; /* Элементы в ряд */
        align-items: center;
        text-align: left;
        padding: 15px 25px;
        height: auto;
    }

    .shop-catalog.list-view .product-img-box {
        width: 80px;
        height: 80px;
        margin-bottom: 0;
        margin-right: 25px;
    }

    .shop-catalog.list-view .product-info {
        flex-direction: row;
        align-items: center;
        justify-content: space-between; /* Название слева, цена и кнопка справа */
        width: 100%;
    }

    .shop-catalog.list-view .product-title { margin: 0; font-size: 1.1rem; }
    .shop-catalog.list-view .product-price { margin: 0 30px; font-size: 1.3rem; }
    .shop-catalog.list-view .btn-primary { width: auto; padding: 10px 30px; }

    /* Адаптивность */
    @media (max-width: 900px) {
        .shop-layout { flex-direction: column; }
        .shop-sidebar { width: 100%; position: relative; top: 0; }
        .shop-controls { flex-direction: column; align-items: stretch; }
        .toolbar-group { justify-content: space-between; }
    }

/* ==========================================================================
   09. ORDERS & PAYMENTS (Заказы, Ключи, Методы Оплаты)
   ========================================================================== */
/* Стили ЗАКАЗОВ */

.orders-list-wrapper {
    display: flex;
    flex-direction: column;
}

.order-item-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    transition: 0.3s;
}

.order-item-row:last-child {
    border-bottom: none; /* У последнего элемента нет линии */
}

.order-item-row:hover {
    background: rgba(255, 255, 255, 0.02);
}

.order-main-info {
    display: flex;
    align-items: center;
    gap: 20px;
    flex: 1;
}

.order-item-img {
    width: 50px;
    height: 50px;
    border-radius: 10px;
    object-fit: cover;
    background: rgba(0,0,0,0.2);
    border: 1px solid var(--glass-border);
}

.order-text-meta h4 {
    margin: 0;
    font-size: 1rem;
    font-weight: 600;
}

.order-text-meta span {
    font-size: 0.75rem;
    color: var(--text-dim);
}

.order-price-box {
    font-weight: 800;
    color: var(--accent);
    font-size: 1.1rem;
    margin: 0 40px;
}

.order-status-actions {
    display: flex;
    align-items: center;
    gap: 20px;
    justify-content: flex-end;
    min-width: 250px;
}

.order-pending-box {
    display: flex;
    align-items: center;
    gap: 15px;
}

.order-timer {
    font-family: 'JetBrains Mono', monospace;
    font-weight: 700;
    color: var(--danger);
    font-size: 0.9rem;
    background: rgba(245, 54, 92, 0.1);
    padding: 4px 8px;
    border-radius: 6px;
}

/* --- СЕТКА МЕТОДОВ ОПЛАТЫ --- */
.payment-methods-grid {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.pay-method-item {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--glass-border);
    padding: 18px 25px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    text-decoration: none;
    color: #fff;
    transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.pay-method-item:hover {
    background: rgba(61, 90, 254, 0.1);
    border-color: var(--accent);
    transform: scale(1.02);
}

.pay-icon {
    font-size: 1.8rem;
    margin-right: 20px;
    filter: drop-shadow(0 0 10px rgba(255,255,255,0.2));
}

.pay-text {
    text-align: left;
    flex-grow: 1;
}

.pay-text h4 {
    font-size: 1rem;
    margin-bottom: 2px;
}

.pay-text p {
    font-size: 0.75rem;
    color: var(--text-dim);
}

.pay-arrow {
    font-size: 1.2rem;
    color: var(--accent);
    opacity: 0.5;
    transition: 0.3s;
}

.pay-method-item:hover .pay-arrow {
    opacity: 1;
    transform: translateX(5px);
}

.badge {
    font-size: 0.65rem;
    background: var(--accent);
    padding: 2px 6px;
    border-radius: 4px;
    text-transform: uppercase;
}

.key-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px;
    background: rgba(0,0,0,0.2);
    border-radius: 10px;
    margin-bottom: 8px;
    border: 1px solid var(--glass-border);
}

.key-code { color: var(--accent); font-weight: 700; font-size: 0.85rem; }


/* ==========================================================================
   10. TICKETS & SUPPORT CHAT (Тикеты, Чат поддержки)
   ========================================================================== */
/* --- ГАЛОЧКИ ПРОЧИТАНО --- */
.msg-status {
    margin-left: 7px;
    font-size: 0.7rem;
    display: inline-flex;
    align-items: center;
}

/* Одна серая галочка */
.status-sent::after {
    content: '✓';
    color: rgba(255, 255, 255, 0.4);
}

/* Две голубые галочки */
.status-read::after {
    content: '✓✓';
    color: #00d2ff;
    text-shadow: 0 0 8px rgba(0, 210, 255, 0.6);
    font-weight: bold;
}

/* Для чужих сообщений инфо тоже вправо внутри пузырька */
.msg-admin .msg-info {
    justify-content: flex-end;
}

/* Инфо под сообщением (Имя, Роль, Галочки) */
.msg-info {
    display: flex;
    align-items: center;
    justify-content: flex-end; /* Внутри пузырька текст прижат к его правому краю */
    gap: 6px;
    margin-top: 6px;
    font-size: 0.65rem;
    font-weight: 700;
    opacity: 0.6;
    text-transform: uppercase;
    white-space: nowrap;
}

/* Бот (По центру) */
.msg-bot {
    align-self: center;
    background: rgba(255, 255, 255, 0.03);
    border: 1px dashed var(--accent);
    color: var(--accent);
    font-size: 0.85rem;
    text-align: center;
    margin: 10px auto;
    padding: 8px 20px;
}

.ticket-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

/* Список тикетов */
.ticket-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.ticket-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--glass-border);
    padding: 20px;
    border-radius: 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    transition: 0.2s;
}

.ticket-card:hover {
    background: rgba(255, 255, 255, 0.06);
    border-color: var(--accent);
}

.ticket-info h4 { margin: 0 0 5px 0; font-size: 1.1rem; }
.ticket-info p { margin: 0; font-size: 0.8rem; color: var(--text-dim); }

/* Чат внутри тикета */
.ticket-chat-area {
    display: none; /* Скрыто по умолчанию */
    flex-direction: column;
    height: 500px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 12px;
    border: 1px solid var(--glass-border);
    overflow: hidden;
}

/* Убираем горизонтальный скролл у всего окна чата */
.ticket-chat-history {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden !important;
    padding: 25px;
    display: flex;
    flex-direction: column; /* Элементы один под другим */
    gap: 12px;
    background: rgba(0, 0, 0, 0.15);
}

.msg-bubble {
    position: relative;
    display: block;
    width: fit-content;    /* Пузырек сжимается под размер текста */
    max-width: 75%;        /* Но не шире 75% экрана */
    padding: 10px 16px;
    border-radius: 18px;
    font-size: 0.95rem;
    line-height: 1.4;
    
    /* Фикс длинных слов */
    word-wrap: break-word;
    overflow-wrap: break-word;
    word-break: break-word;
}

/* Мои сообщения (Справа - Синие) */
.msg-user {
    align-self: flex-end;      /* Прижать вправо */
    background: var(--accent); /* Синий цвет */
    color: #fff;
    border-bottom-right-radius: 4px; /* Острый уголок справа */
    margin-left: auto;         /* Доп. страховка прижатия вправо */
}

/* Чужие сообщения (Слева - Серые) */
.msg-admin {
    align-self: flex-start;    /* Прижать влево */
    background: rgba(255, 255, 255, 0.08); /* Серый цвет */
    border: 1px solid var(--glass-border);
    color: #eee;
    border-bottom-left-radius: 4px; /* Острый уголок слева */
    margin-right: auto;             /* Доп. страховка прижатия влево */
}

/* Поле ввода сообщения */
.ticket-input-bar {
    display: flex;
    padding: 15px;
    background: rgba(255, 255, 255, 0.02);
    border-top: 1px solid var(--glass-border);
    gap: 10px;
}

.ticket-input-bar input { margin: 0; }
.ticket-input-bar button { width: auto; margin: 0; padding: 0 25px; }

.ticket-card {
    text-decoration: none;
    color: inherit;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    background: rgba(255,255,255,0.02);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    margin-bottom: 10px;
    transition: 0.3s;
}
.ticket-card:hover {
    background: rgba(255,255,255,0.05);
    border-color: var(--accent);
}

/* Растягиваем карточки тикетов в списке */
.ticket-card {
    padding: 20px 25px !important;
}

/* ЧАТ ПОДДЕРЖКИ */
.support-chat-box {
    margin-top: 20px;
    background: rgba(0,0,0,0.3);
    border-radius: 12px;
    border: 1px solid var(--glass-border);
    display: none; /* Скрыт по умолчанию */
}
.chat-messages {
    height: 300px;
    overflow-y: auto;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.msg { padding: 10px 15px; border-radius: 10px; max-width: 70%; font-size: 0.9rem; }
.msg-support { background: #333; align-self: flex-start; color: #ddd; }

.chat-input-area {
    padding: 15px;
    border-top: 1px solid var(--glass-border);
    display: flex;
    gap: 10px;
}

/* --- СТИЛИ ДЛЯ СТАТИЧНОГО ВВОДА (SUPPORT) --- */
.static-input-group {
    display: flex;
    flex-direction: column;
    gap: 10px;
    text-align: left;
    margin-bottom: 25px;
}

.static-input-group label {
    font-size: 0.85rem;
    color: var(--text-dim);
    margin-left: 5px;
}

.static-input-group textarea {
    width: 100%;
    min-height: 180px; /* Сделали поле выше */
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 20px;
    color: #fff;
    font-size: 1rem;
    outline: none;
    resize: vertical; /* Разрешаем менять высоту вручную */
    font-family: inherit;
    transition: 0.3s;
}

.static-input-group textarea:focus {
    background: rgba(255, 255, 255, 0.06);
    border-color: var(--accent);
}


/* ==========================================================================
   11. STATS & REVIEWS (Статистика, отзывы, блоки информации)
   ========================================================================== */
/* =========================================
   ОБЪЕДИНЕННАЯ СЕКЦИЯ (СТАТА + ОТЗЫВЫ)
   ========================================= */

.bottom-info-section {
    width: 100%;
    padding: 80px 20px;
    background: rgba(10, 10, 10, 0.85); /* Глубокий темный фон (блюр) */
    backdrop-filter: blur(25px);
    border-top: 1px solid var(--glass-border);
    display: flex;
    justify-content: center;
}

.bottom-info-wrapper {
    width: 100%;
    max-width: 1200px;
    display: grid;
    grid-template-columns: 350px 1fr; /* Статистика 350px, отзывы - остальное */
    gap: 50px;
    align-items: flex-start;
}

/* --- КОЛОНКА СТАТИСТИКИ --- */
.stats-column h2 span { color: var(--accent); }

.stats-vertical-grid {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.stat-box-new {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 20px;
    transition: 0.3s;
}

.stat-box-new:hover {
    transform: translateX(5px);
    border-color: var(--accent);
    background: rgba(61, 90, 254, 0.05);
}

.stat-icon {
    font-size: 2rem;
    filter: drop-shadow(0 0 10px var(--accent-glow));
}

.stat-text h3 {
    font-size: 1.8rem;
    color: #fff;
    margin: 0 0 2px 0;
    line-height: 1;
}

.stat-text p {
    font-size: 0.75rem;
    color: var(--text-dim);
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* --- КОЛОНКА ОТЗЫВОВ --- */
.reviews-column h2 span { color: var(--accent); }

.reviews-mini-feed {
    display: flex;
    flex-direction: column;
    gap: 15px;
    max-height: 450px; /* Ограничиваем высоту ленты */
    overflow-y: auto;
    padding-right: 10px;
}

/* Кастомный скроллбар для ленты */
.reviews-mini-feed::-webkit-scrollbar { width: 5px; }
.reviews-mini-feed::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.2); border-radius: 10px; }

.review-mini-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 20px;
    transition: 0.3s;
}
.review-mini-card:hover { border-color: rgba(255,255,255,0.2); }

.rm-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 12px;
}

.rm-header img {
    width: 40px; height: 40px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--accent);
}

.rm-info { flex-grow: 1; }
.rm-info b { font-size: 1rem; color: #fff; }
.rm-stars { color: #ffcc00; font-size: 0.7rem; letter-spacing: 1px; margin-top: 3px; }
.rm-date { font-size: 0.75rem; color: var(--text-dim); }

.rm-text {
    font-size: 0.9rem;
    color: #ccc;
    line-height: 1.5;
    margin: 0;
}

/* --- АДАПТИВНОСТЬ --- */
@media (max-width: 900px) {
    .bottom-info-wrapper {
        grid-template-columns: 1fr; /* Одна колонка на планшетах/телефонах */
    }
    .stats-vertical-grid {
        display: grid;
        grid-template-columns: 1fr 1fr; /* Стата в 2 столбика на мобилках */
    }
}
@media (max-width: 500px) {
    .stats-vertical-grid { grid-template-columns: 1fr; }
}

/* --- СЕКЦИЯ ПОСЛЕДНИХ ОТЗЫВОВ (СТАТИЧНАЯ) --- */
.recent-reviews-section {
    padding: 80px 10% 40px; /* Отступы сверху и по бокам */
    background: rgba(0, 0, 0, 0.5); /* Затемнение как у статистики */
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-top: 1px solid var(--glass-border);
    width: 100%;
}

.recent-reviews-grid {
    display: grid;
    /* 5 колонок для 5 отзывов. Минимум 200px на каждый */
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    width: 100%;
    max-width: 1300px;
    margin: 0 auto;
}

.review-static-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    transition: 0.3s;
}

.review-static-card:hover {
    border-color: var(--accent);
    background: rgba(255, 255, 255, 0.05);
    transform: translateY(-5px);
}

.review-card-header {
    display: flex;
    align-items: center;
    gap: 10px;
}

.review-card-header img {
    width: 35px;
    height: 35px;
    border-radius: 50%;
    object-fit: cover;
    border: 1px solid var(--accent);
}

.review-card-user-info b {
    display: block;
    font-size: 0.9rem;
    color: #fff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.review-card-time {
    font-size: 0.65rem;
    color: var(--text-dim);
    margin-top: 2px;
}

.review-card-stars {
    color: #ffcc00;
    font-size: 0.7rem;
    letter-spacing: 1px;
}

.review-card-text {
    font-size: 0.85rem;
    color: #ccc;
    line-height: 1.5;
    font-style: italic;
    /* Ограничение текста до 4 строк, чтобы карточки были ровными */
    display: -webkit-box;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Стык со статистикой: убираем лишние отступы и границы */
.stats-container {
    padding-top: 40px; /* Уменьшаем верхний отступ */
    background: rgba(0, 0, 0, 0.5); /* Тот же фон */
    backdrop-filter: blur(20px);
    border-top: none; /* Убираем линию между отзывами и статой */
}

/* --- СТАТИСТИКА --- */
.stats-container {
    position: relative;
    z-index: 2; /* Чтобы она была над фоном */
    padding: 100px 10%;
    /* Делаем темную "стеклянную" подложку для всей секции контента */
    background: rgba(10, 10, 10, 0.85); 
    backdrop-filter: blur(20px);
    border-top: 1px solid var(--glass-border);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 30px;
}
.stat-box {
    /* Стили наследуются от общего селектора .stat-box выше */
    padding: 30px;
    border-radius: 20px;
    text-align: center;
    transition: 0.3s;
}
.stat-box:hover { 
    background: rgba(61, 90, 254, 0.15); 
    border-color: var(--accent);
    transform: translateY(-5px);
}
.stat-box h3 { font-size: 2.5rem; color: #fff; margin-bottom: 5px; }
.stat-box p { color: var(--text-dim); font-size: 0.9rem; text-transform: uppercase; letter-spacing: 1px; }


/* ==========================================================================
   12. ABOUT & ADVANTAGES (Страница "О нас" и блок преимуществ)
   ========================================================================== */
/* Широкая карточка "О нас" (как в профиле) */
.about-card-wide {
    width: 100%;
    max-width: 1000px; /* Большая ширина как у карточки профиля */
    padding: 50px;
    text-align: center;
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    box-shadow: var(--glass-shadow);
    animation: fadeInUp 0.8s ease;
}

.about-card-wide h1 {
    font-size: 3.5rem;
    font-weight: 800;
    margin-bottom: 20px;
}

.about-card-wide p {
    font-size: 1.15rem;
    color: var(--text-dim);
    line-height: 1.8;
    margin-bottom: 35px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

/* =========================================
   СТРАНИЦА "О НАС" (INFO PAGE) 
   ========================================= */

.info-page-wrapper {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding: 100px 20px 60px;
    width: 100%;
    min-height: calc(100vh - 70px);
}

.info-content-box {
    width: 100%;
    max-width: 1100px;
    display: flex;
    flex-direction: column;
    gap: 60px;
}

.section-title {
    font-size: 2.2rem;
    font-weight: 800;
    margin-bottom: 25px;
    text-align: left;
    color: #fff;
}
.section-title span { color: var(--accent); }

/* --- СОЦСЕТИ --- */
.social-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    width: 100%;
}

.social-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(15px);
    border-radius: 16px;
    padding: 25px;
    display: flex;
    align-items: center;
    gap: 20px;
    text-decoration: none;
    color: #fff;
    transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: var(--glass-shadow);
}

.social-card:hover {
    transform: translateY(-5px);
    background: rgba(255, 255, 255, 0.05);
    border-color: var(--accent);
}

.social-icon {
    font-size: 2.5rem;
    line-height: 1;
    filter: drop-shadow(0 0 10px var(--accent-glow));
}

.social-info {
    display: flex;
    flex-direction: column;
    justify-content: center;
}
.social-info h3 { margin: 0; font-size: 1.2rem; }
.social-info p { margin: 5px 0 0; color: var(--text-dim); font-size: 0.85rem; }

/* --- ОТЗЫВЫ (ОДНА КОЛОНКА) --- */
.reviews-section-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 25px;
    border-bottom: 1px solid var(--glass-border);
    padding-bottom: 15px;
}

.info-reviews-count {
    color: var(--text-dim);
    font-size: 0.9rem;
    font-weight: 600;
}

.reviews-layout-new {
    display: flex;
    flex-direction: column;
    gap: 40px;
    width: 100%;
}

/* Форма */
.review-form-box {
    /* Те же параметры, что и у карточек отзывов */
    background: var(--glass-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--glass-border);
    box-shadow: var(--glass-shadow);
    
    padding: 30px;
    border-radius: 20px;
    width: 100%;
    margin-bottom: 40px; /* Отступ от ленты отзывов */
    transition: 0.3s ease;
}
.review-form-box:hover {
    border-color: rgba(255, 255, 255, 0.15);
}

.info-textarea {
    width: 100%;
    min-height: 120px;
    background: rgba(0, 0, 0, 0.2); /* Темная подложка внутри стекла */
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 20px;
    color: #fff;
    font-family: inherit;
    font-size: 1rem;
    resize: vertical;
    outline: none;
    margin-bottom: 20px;
    transition: 0.3s;
}

.info-textarea:focus {
    background: rgba(0, 0, 0, 0.4);
    border-color: var(--accent);
}
/* Контейнер для звезд и кнопки */
.info-form-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Лента */
.reviews-feed-new {
    display: flex;
    flex-direction: column;
    gap: 20px;
    width: 100%;
}

.review-item-new {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(10px);
    border-radius: 16px;
    padding: 25px 30px;
    width: 100%;
}

.review-user-info {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 15px;
}

.review-avatar-box { display: flex; align-items: center; gap: 15px; }
.review-avatar-box img { width: 45px; height: 45px; border-radius: 50%; object-fit: cover; border: 2px solid var(--accent); }
.review-stars { color: #ffcc00; font-size: 0.85rem; letter-spacing: 2px; margin-top: 3px; }
.review-date { color: var(--text-dim); font-size: 0.8rem; }
.review-text-new { color: #e0e0e0; line-height: 1.6; font-size: 0.95rem; word-wrap: break-word; }

/* --- ПЛОТНАЯ СЕКЦИЯ ПРЕИМУЩЕСТВ (ИСПРАВЛЕННАЯ СЕТКА) --- */
.advantages-container {
    padding: 100px 0;
    background: rgba(10, 10, 10, 0.9);
    backdrop-filter: blur(25px);
    display: flex;
    justify-content: center;
    border-top: 1px solid var(--glass-border);
}

.advantages-wrapper {
    max-width: 1200px;
    width: 90%;
    display: grid;
    /* 3 колонки: под заголовок и две под карточки */
    grid-template-columns: 1.4fr 1fr 1fr; 
    /* 3 строки в высоту */
    grid-template-rows: auto auto auto;
    gap: 20px;
}

/* Блок с заголовком теперь растягивается на 3 строки вниз */
.adv-header-block {
    grid-column: 1;
    grid-row: 1 / span 3; /* Занимает высоту всех трёх рядов карточек */
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding-right: 40px;
}

/* Обычные карточки */
.adv-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    padding: 30px;
    border-radius: 20px;
    transition: 0.3s;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* ШИРОКАЯ КАРТОЧКА (ПОДДЕРЖКА) */
.adv-card-wide {
    grid-column: span 2; /* Растягивается на две колонки справа */
    text-align: left;
}

.adv-card:hover {
    background: rgba(255, 255, 255, 0.07);
    border-color: var(--accent);
    transform: translateY(-5px);
}

/* Стили заголовков и текста в карточках */
.adv-card h3 {
    font-size: 1.2rem;
    margin-bottom: 15px;
    color: #fff;
    display: flex;
    align-items: center;
    gap: 12px;
}

.adv-card p {
    font-size: 0.9rem;
    color: var(--text-dim);
    line-height: 1.6;
}

/* Адаптивность для планшетов и телефонов */
@media (max-width: 1050px) {
    .advantages-wrapper {
        grid-template-columns: 1fr 1fr; /* Убираем 3 колонки */
    }
    .adv-header-block {
        grid-column: span 2; /* Заголовок наверх */
        grid-row: 1;
        padding: 0;
        text-align: center;
        margin-bottom: 40px;
    }
    .adv-card-wide {
        grid-column: span 2; /* Оставляем широкой */
    }
}

@media (max-width: 600px) {
    .advantages-wrapper {
        grid-template-columns: 1fr;
    }
    .adv-header-block, .adv-card-wide {
        grid-column: span 1;
    }
}


/* ==========================================================================
   13. LEGAL PAGES (Юридические документы, Политики)
   ========================================================================== */
/* --- СТИЛИ ДЛЯ ЮРИДИЧЕСКИХ СТРАНИЦ --- */

.legal-wrapper {
    min-height: 100vh;
    padding-top: 100px; /* Отступ от шапки */
    padding-bottom: 60px;
    display: flex;
    justify-content: center;
    width: 100%;
}

.legal-document {
    background: #0f0f0f; /* Сплошной темный цвет (без прозрачности) */
    width: 100%;
    max-width: 1000px; /* Ширина как на скрине */
    padding: 60px 80px; /* Большие внутренние отступы */
    border-radius: 20px; /* Слегка скругленные углы */
    box-shadow: 0 10px 50px rgba(0,0,0,0.8); /* Тень, чтобы отделить от фона */
    color: #cecece; /* Мягкий серый цвет текста */
    font-size: 0.95rem;
    line-height: 1.8; /* Увеличенный интервал для удобства чтения */
}

.legal-document h1 {
    text-align: center;
    color: #fff;
    font-size: 2rem;
    margin-bottom: 40px;
}

.legal-document p {
    margin-bottom: 15px;
    text-align: justify; /* Выравнивание по ширине (как в документах) */
}

.legal-document ul {
    list-style-type: disc;
    padding-left: 20px;
    margin-bottom: 20px;
}

.legal-document li {
    margin-bottom: 8px;
}

/* Адаптивность для телефонов */
@media (max-width: 768px) {
    .legal-document {
        padding: 30px 20px;
        width: 95%;
    }
}

.appendix-box {
    background: rgba(0, 0, 0, 0.2); /* Темнее фона */
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-left: 3px solid var(--accent); /* Цветная полоска слева */
    padding: 20px 25px;
    border-radius: 12px;
    margin-top: 30px;
    font-size: 0.9rem;
}

.appendix-box p {
    color: #b0b0b0; /* Чуть светлее, чтобы выделить текст */
    line-height: 1.6;
}

/* Ссылка внутри приложения */
.appendix-box a {
    color: var(--accent);
    font-weight: 600;
    text-decoration: none;
    border-bottom: 1px dashed var(--accent);
    transition: 0.3s;
}

.appendix-box a:hover {
    color: #fff;
    border-bottom: 1px solid #fff;
}


/* ==========================================================================
   14. ADMIN PANEL (Админ-панель, Статистика администратора, Консоль)
   ========================================================================== */
/* --- СТИЛИ ДЛЯ ОТЗЫВОВ В АДМИНКЕ --- */
.admin-reviews-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    width: 100%;
}

.admin-review-card {
    background: rgba(255,255,255,0.02);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 20px;
    display: flex;
    flex-direction: column;
    justify-content: space-between; /* Кнопка удаления всегда внизу */
}

.admin-review-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

.admin-review-text {
    font-size: 0.9rem;
    color: #ccc;
    margin-bottom: 20px;
    word-wrap: break-word;
    flex-grow: 1;
}

.btn-delete-full {
    background: rgba(245, 54, 92, 0.1);
    color: var(--danger);
    border: 1px solid var(--danger);
    padding: 8px;
    border-radius: 8px;
    width: 100%;
    cursor: pointer;
    transition: 0.3s;
    font-weight: bold;
}
.btn-delete-full:hover {
    background: var(--danger);
    color: #fff;
}

/* --- НОВЫЙ ДИЗАЙН АДМИНКИ --- */

/* --- ИСПРАВЛЕНИЕ СТАТИСТИКИ АДМИНКИ --- */

.admin-stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr); /* Ровно 4 колонки */
    gap: 20px;
    width: 100%;
    margin-bottom: 30px;
}

.admin-stat-card {
    background: var(--glass-bg); /* Темный стеклянный фон */
    backdrop-filter: blur(16px);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 20px;
    text-align: center;
    box-shadow: var(--glass-shadow);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    transition: 0.3s;
}

.admin-stat-card:hover {
    background: rgba(255, 255, 255, 0.05);
    transform: translateY(-5px);
    border-color: var(--accent);
}

.admin-stat-card h2 {
    font-size: 1.8rem;
    font-weight: 800;
    margin-bottom: 5px;
    text-shadow: 0 0 20px rgba(0,0,0,0.5);
}

.admin-stat-card p {
    font-size: 0.75rem;
    color: var(--text-dim);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
}

/* Адаптивность: на планшетах 2x2, на телефонах 1 колонка */
@media (max-width: 1000px) {
    .admin-stats-grid {
        grid-template-columns: 1fr 1fr;
    }
}
@media (max-width: 600px) {
    .admin-stats-grid {
        grid-template-columns: 1fr;
    }
}

/* --- НОВЫЕ ЭЛЕМЕНТЫ АДМИНКИ --- */

/* Поиск пользователей */
.search-box {
    margin-bottom: 15px;
    position: relative;
}
.search-input {
    width: 100%;
    padding: 12px 40px 12px 15px;
    background: rgba(0,0,0,0.3);
    border: 1px solid var(--glass-border);
    border-radius: 10px;
    color: #fff;
    font-size: 0.9rem;
}
.search-icon {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    opacity: 0.5;
}

/* Генератор времени (в ряд) */
.time-inputs {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 10px;
}

/* Кнопка редактирования (карандаш) */
.btn-icon {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    color: var(--text-dim);
    width: 32px;
    height: 32px;
    border-radius: 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: 0.2s;
}
.btn-icon:hover { background: var(--accent); color: #fff; border-color: var(--accent); }
.btn-icon.delete:hover { background: var(--danger); border-color: var(--danger); }

/* Модальное окно редактирования */
.edit-modal {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(0,0,0,0.7);
    backdrop-filter: blur(5px);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 2000;
}
.edit-modal.active { display: flex; }

.edit-modal-content {
    background: #121212;
    border: 1px solid var(--glass-border);
    padding: 30px;
    border-radius: 20px;
    width: 400px;
    box-shadow: 0 20px 50px rgba(0,0,0,0.5);
    position: relative;
}

/* Снимаем ограничение ширины для карточек в админке */
.admin-card {
    width: 100% !important;
    max-width: 100% !important;
    height: 100%;
    display: flex;
    flex-direction: column;
}

/* Сетка для средней части (Консоль + Ключи) */
.admin-mid-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr; /* Консоль пошире, ключи поуже */
    gap: 25px;
    width: 100%;
    margin-bottom: 30px;
}

/* --- ТЕРМИНАЛ (КОНСОЛЬ) --- */
.console-wrapper {
    background: #0f0f0f;
    border: 1px solid #333;
    border-radius: 12px;
    padding: 0;
    overflow: hidden;
    font-family: 'Consolas', 'Courier New', monospace;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    height: 400px;
    display: flex;
    flex-direction: column;
}

.console-header {
    background: #1a1a1a;
    padding: 8px 15px;
    font-size: 0.8rem;
    color: #888;
    border-bottom: 1px solid #333;
    display: flex;
    justify-content: space-between;
}

.console-logs {
    flex: 1;
    padding: 15px;
    overflow-y: auto;
    color: #fff;
    font-size: 0.9rem;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.log-entry { word-break: break-all; }

.console-input-area {
    display: flex;
    border-top: 1px solid #333;
    background: #111;
}

.console-prompt {
    padding: 12px 0 12px 15px;
    color: var(--accent);
    font-weight: bold;
}

.console-input {
    flex: 1;
    background: transparent;
    border: none;
    color: #fff;
    padding: 12px;
    font-family: inherit;
    outline: none;
}

/* Стили для консоли внутри карточки */
.console-wrapper {
    flex-grow: 1; /* Растягивает консоль на всю высоту карточки */
    min-height: 350px;
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    background: #0a0a0a;
    display: flex;
    flex-direction: column;
}

.console-logs {
    height: 300px; /* Фиксированная высота логов */
}

/* Таблица пользователей на всю ширину */
.admin-table-container {
    width: 100%;
    overflow-x: auto;
}

/* Кнопка сброса HWID (нормальная) */
.btn-reset-hwid {
    background: rgba(255, 71, 87, 0.15);
    border: 1px solid rgba(255, 71, 87, 0.3);
    color: #ff4757;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 600;
    cursor: pointer;
    transition: 0.3s;
}
.btn-reset-hwid:hover {
    background: #ff4757;
    color: #fff;
}

.hwid-label {
    font-size: 0.75rem;
    background: rgba(255,255,255,0.05);
    padding: 4px 8px;
    border-radius: 6px;
    color: var(--text-dim);
}

.icon-save {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.2rem;
    transition: 0.2s;
}
.icon-save:hover { transform: scale(1.2); }

.table-form {
    display: flex;
    align-items: center;
    gap: 10px;
}

.small-select {
    padding: 5px 10px !important;
    font-size: 0.8rem !important;
    width: auto !important;
    margin: 0 !important;
}

.sub-status-active { color: var(--success); font-weight: 700; text-shadow: 0 0 10px rgba(46, 213, 115, 0.4); }
.sub-status-inactive { color: var(--danger); font-weight: 700; }


/* ==========================================================================
   15. NOTIFICATIONS & MODALS (Уведомления, Тосты, Всплывающие окна)
   ========================================================================== */
/* --- СИСТЕМА УВЕДОМЛЕНИЙ (TOASTS) --- */

/* Контейнер для уведомлений (висит справа сверху) */
.toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999; /* Чтобы было поверх всего */
    display: flex;
    flex-direction: column;
    gap: 10px; /* Отступ между уведомлениями */
    pointer-events: none; /* Чтобы контейнер не мешал кликать по сайту */
}

/* Сами уведомления */
.alert {
    width: 320px;
    padding: 15px 20px;
    border-radius: 12px;
    background: rgba(20, 20, 20, 0.9); /* Темный фон */
    backdrop-filter: blur(12px); /* Размытие */
    border-left: 4px solid; /* Цветная полоска слева */
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.5);
    color: #fff;
    font-size: 0.9rem;
    position: relative;
    pointer-events: auto; /* Чтобы можно было закрыть кликом */
    
    /* Анимация появления */
    animation: slideInRight 0.4s ease forwards;
    transition: opacity 0.5s ease, transform 0.5s ease;
}

/* Цвета для ошибок и успеха */
.alert-error {
    border-color: var(--danger);
    background: linear-gradient(90deg, rgba(255, 71, 87, 0.1) 0%, rgba(20, 20, 20, 0.9) 20%);
}

.alert-success {
    border-color: var(--success);
    background: linear-gradient(90deg, rgba(46, 213, 115, 0.1) 0%, rgba(20, 20, 20, 0.9) 20%);
}

/* Крестик закрытия */
.close-btn {
    position: absolute;
    top: 50%;
    right: 15px;
    transform: translateY(-50%);
    cursor: pointer;
    font-size: 1.2rem;
    color: var(--text-dim);
    transition: 0.2s;
}
.close-btn:hover { color: #fff; }

/* Анимация выезда справа */
@keyframes slideInRight {
    from { transform: translateX(100%); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

/* --- МОДАЛЬНОЕ ОКНО (СМЕНА ПАРОЛЯ) --- */
.modal-overlay {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px); /* Размытие заднего фона */
    display: none; /* Скрыто по умолчанию */
    justify-content: center;
    align-items: center;
    z-index: 2000;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.modal-overlay.active {
    display: flex;
    opacity: 1;
}

.modal-content {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    padding: 40px;
    border-radius: 24px;
    width: 100%;
    max-width: 400px;
    position: relative;
    transform: translateY(50px);
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: var(--glass-shadow);
}

.modal-overlay.active .modal-content {
    transform: translateY(0);
}

.modal-close {
    position: absolute;
    top: 20px; right: 20px;
    cursor: pointer;
    font-size: 1.5rem;
    color: var(--text-dim);
    transition: 0.3s;
}
.modal-close:hover { color: #fff; }


/* ==========================================================================
   16. FOOTER & COOKIES (Подвал сайта, Карточка Cookies)
   ========================================================================== */
/* =========================================
   НОВЫЙ МАССИВНЫЙ ФУТЕР (DNS Style)
   ========================================= */

footer {
    width: 100%;
    background: rgba(10, 10, 12, 0.95);
    backdrop-filter: blur(25px);
    border-top: 1px solid var(--glass-border);
    margin-top: auto;
    color: var(--text-dim);
    font-size: 0.85rem;
}

/* Верхняя часть (Колонки с навигацией) */
.footer-top {
    display: grid;
    grid-template-columns: repeat(4, 1fr); /* 4 колонки */
    gap: 40px;
    max-width: 1300px;
    margin: 0 auto;
    padding: 50px 20px;
}

.footer-col {
    display: flex;
    flex-direction: column;
}

.footer-col h4 {
    color: #fff;
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 20px;
    text-transform: uppercase;
}

.footer-col a {
    color: var(--text-dim);
    text-decoration: none;
    margin-bottom: 12px;
    transition: 0.2s;
    font-weight: 500;
}

.footer-col a:hover {
    color: var(--accent);
}

.footer-contact-info {
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.footer-contact-info i {
    font-size: 1.2rem;
    color: var(--accent);
}

/* Нижняя часть (Копирайт и Платежки) */
.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    padding: 25px 20px;
}

.footer-bottom-wrapper {
    max-width: 1300px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap; /* Для мобильных устройств */
    gap: 20px;
}

.footer-copyright {
    text-align: center;
}

.footer-copyright p {
    margin: 0 0 5px 0;
    color: #fff;
    font-weight: 600;
}

.footer-copyright span {
    font-size: 0.75rem;
}

/* Платежные иконки */
.footer-payments {
    display: flex;
    align-items: center;
    gap: 15px;
}

.payment-icon {
    height: 22px;
    opacity: 0.6;
    filter: grayscale(1);
    transition: 0.3s;
}

.payment-icon:hover {
    opacity: 1;
    filter: grayscale(0);
}

.freekassa-logo {
    height: 30px;
    opacity: 0.8;
    transition: 0.3s;
}

.freekassa-logo:hover {
    opacity: 1;
}

/* Адаптивность для телефонов и планшетов */
@media (max-width: 900px) {
    .footer-top {
        grid-template-columns: repeat(2, 1fr); /* По 2 колонки */
    }
    .footer-bottom-wrapper {
        flex-direction: column;
        justify-content: center;
    }
}

@media (max-width: 600px) {
    .footer-top {
        grid-template-columns: 1fr; /* 1 колонка */
        text-align: center;
    }
    .footer-contact-info { justify-content: center; }
}

/* --- COOKIE-КАРТОЧКА (В ЦЕНТРЕ) --- */
.cookie-card {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%) translateY(150%); /* Спрятано внизу */
    
    width: 90%;
    max-width: 550px; /* Ширина побольше для центра */
    
    background: rgba(20, 20, 22, 0.9);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    
    padding: 25px;
    z-index: 10001;
    
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.6);
    
    opacity: 0;
    transition: all 0.6s cubic-bezier(0.19, 1, 0.22, 1);
    pointer-events: none;
}

.cookie-card.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
    pointer-events: auto;
}

/* Заголовок с иконкой */
.cookie-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 12px;
}
.cookie-icon { font-size: 1.5rem; }
.cookie-header h4 { font-size: 1.1rem; color: #fff; font-weight: 700; }

/* Текст */
.cookie-text {
    font-size: 0.9rem;
    color: var(--text-dim);
    line-height: 1.5;
    margin-bottom: 25px; /* Увеличили отступ до кнопок */
}
.cookie-text a {
    color: var(--accent);
    font-weight: 600;
    text-decoration: none;
}
.cookie-text a:hover { text-decoration: underline; }

/* КНОПКИ (ПРИНЯТЬ И ОТКАЗАТЬСЯ) */
.cookie-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr; /* Две равные колонки */
    gap: 15px;
}

.cookie-buttons .btn {
    flex: 1;
    margin: 0;
    padding: 12px;
    font-size: 0.9rem;
    border-radius: 12px;
}

/* Адаптивность: на телефонах карточка снизу на всю ширину */
@media (max-width: 480px) {
    .cookie-card {
        width: 100%;
        left: 0;
        bottom: 0;
        border-radius: 24px 24px 0 0;
    }
}

/* Фикс для очень маленьких экранов */
@media (max-width: 450px) {
    .cookie-card {
        width: 100% !important;
        left: 0 !important;
        bottom: 0 !important;
        border-radius: 20px 20px 0 0 !important;
    }
}


/* ==========================================================================
   17. GLOBAL MOBILE OVERRIDES (Общие фиксы для мобильных устройств)
   ========================================================================== */
/* ======================================================
   ФИНАЛЬНЫЙ ФИКС МОБИЛЬНОЙ ВЕРСИИ
   ====================================================== */

/* --- МОБИЛЬНОЕ МЕНЮ (БУРГЕР) --- */
.menu-toggle {
    display: none; /* Скрыто на ПК */
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    z-index: 10002;
}

.menu-toggle span {
    width: 25px;
    height: 3px;
    background: #fff;
    border-radius: 2px;
    transition: 0.3s;
}

@media (max-width: 850px) {

    /* 1. Отключаем тяжелое размытие. 
       Вместо блюра просто делаем фон чуть темнее и плотнее.
       Это даст +30 FPS к скроллу сразу. */
    .card, .stat-box, .admin-stat-card, footer, .nav-right, .cookie-card {
        backdrop-filter: none !important;
        -webkit-backdrop-filter: none !important;
        background: rgba(20, 20, 25, 0.95) !important; /* Плотный фон */
    }
        /* 3. Упрощаем тени. 
       Длинные тени с большим радиусом размытия сильно грузят графику. */
    .card, {
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5) !important;
    }
        /* 4. Принудительное аппаратное ускорение для всех анимированных элементов */
    .card, .btn, .hero-text-block, .animate {
        transform: translateZ(0);
        backface-visibility: hidden;
        perspective: 1000;
    }
        /* 5. Убираем плавный скролл.
       На многих телефонах системный скролл и CSS smooth scroll конфликтуют и создают "желе". */
    html {
        scroll-behavior: auto !important;
    }
    /* 1. Навигация: убираем наслоение */
    nav {
        height: auto !important;
        padding: 15px 0 !important;
        position: relative !important; /* Убираем фиксацию, чтобы не перекрывала контент */
    }
    
    .nav-container {
        flex-direction: column !important;
        gap: 10px !important;
    }

    .nav-links {
        margin: 0 !important;
        gap: 15px !important;
        flex-wrap: wrap;
        justify-content: center;
    }

    .nav-backdrop { display: none !important; } /* Плашка за мышкой на мобилках только мешает */

    /* 2. Контейнеры: убираем фиксированную ширину */
    .page-wrapper, .shop-container, .dashboard-wrapper {
        padding: 40px 15px !important;
        min-height: auto !important;
        display: block !important; /* Отключаем flex-центровку, если она ломает скролл */
    }

    /* 3. Сетки: всё в одну колонку (Force 1 Column) */
    .shop-grid, 
    .dashboard-grid, 
    .admin-stats-grid, 
    .admin-mid-grid, 
    .advantages-wrapper {
        grid-template-columns: 1fr !important; 
        display: grid !important;
        width: 100% !important;
        max-width: 100% !important;
        gap: 20px !important;
    }

    /* 4. Заголовки: уменьшаем размер, чтобы не вылезали */
    h1 { font-size: 2rem !important; text-align: center; }
    h2 { font-size: 1.5rem !important; text-align: center; }

    /* 5. Карточки: делаем их резиновыми */
    .card, .shop-card, .profile-card, .admin-card {
        max-width: 100% !important;
        width: 100% !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
        padding: 25px 20px !important;
    }

    /* Специально для твоей сетки 300px 1fr */
    [style*="grid-template-columns: 300px 1fr"] {
        grid-template-columns: 1fr !important;
    }

    /* 6. Кнопки: на всю ширину для удобства нажатия пальцем */
    .btn {
        width: 100% !important;
        max-width: 100% !important;
        margin-top: 15px !important;
    }

    /* 7. Главная страница (Hero) */
    .hero-left {
        padding: 40px 15px !important;
        text-align: center !important;
    }
    .hero-text-block {
        max-width: 100% !important;
        padding: 20px !important;
    }
    .hero-text-block h1 { font-size: 2.5rem !important; }

    /* 8. Футер: выстраиваем в ряд */
    footer, .footer-main {
        flex-direction: column !important;
        text-align: center !important;
        gap: 20px !important;
    }
    .footer-column {
        justify-content: center !important;
    }
    .footer-top-info {
        flex-direction: column !important;
        gap: 5px !important;
    }
}
