/* Автосборка стилей доп. модулей (modules_extra) — не редактировать,
   файл перезаписывается движком. Правьте css внутри модулей. */

/* === cookies/cookies.css === */
/* ============================================================================
   Модуль cookies — баннер согласия, окно настроек и страница /cookies.
   Цвета берутся из переменных активной темы, поэтому блок одинаково уместен
   и в светлой, и в тёмной, и в зомби-теме.
   ========================================================================= */

/* --- Баннер --- */
.ck-bar {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 120;
    display: flex; align-items: flex-start; gap: 18px; flex-wrap: wrap;
    max-width: 1100px; margin: 0 auto 16px; padding: 20px 22px;
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius); box-shadow: var(--shadow-lg);
    transform: translateY(120%); opacity: 0;
    transition: transform .32s cubic-bezier(.16,1,.3,1), opacity .32s;
}
.ck-bar.is-in { transform: translateY(0); opacity: 1; }
.ck-bar__body { flex: 1 1 380px; min-width: 0; }
.ck-bar__title { font-size: 16px; font-weight: 800; margin: 0 0 6px; }
.ck-bar__text { margin: 0; font-size: 14px; line-height: 1.6; color: var(--text-muted); }
.ck-bar__text a { text-decoration: underline; }
.ck-bar__actions { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
/* «Отклонить» такая же заметная, как «Принять» — это требование закона
   о равнозначности выбора, а не вкусовое решение. */
.ck-bar__actions .btn { min-width: 168px; justify-content: center; }
.ck-bar__link {
    background: none; border: 0; padding: 6px 4px; cursor: pointer;
    font: inherit; font-size: 14px; font-weight: 600;
    color: var(--text-muted); text-decoration: underline;
}
.ck-bar__link:hover { color: var(--accent); }

/* --- Окно настроек --- */
.ck-modal { position: fixed; inset: 0; z-index: 130; display: none; }
.ck-modal.is-open { display: block; }
.ck-modal__backdrop { position: absolute; inset: 0; background: rgba(0, 0, 0, .55); }
.ck-modal__win {
    position: relative; z-index: 1;
    width: min(620px, calc(100% - 28px)); max-height: min(86vh, 760px);
    margin: 6vh auto 0; display: flex; flex-direction: column;
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius); box-shadow: var(--shadow-lg);
}
.ck-modal__head {
    display: flex; align-items: center; justify-content: space-between; gap: 14px;
    padding: 18px 20px; border-bottom: 1px solid var(--border);
}
.ck-modal__title { margin: 0; font-size: 17px; font-weight: 800; }
.ck-modal__close {
    width: 34px; height: 34px; flex: none; cursor: pointer;
    display: grid; place-items: center; font-size: 20px; line-height: 1;
    background: var(--bg-elev); border: 1px solid var(--border);
    border-radius: var(--radius-sm); color: var(--text);
}
.ck-modal__close:hover { border-color: var(--accent); color: var(--accent); }
.ck-modal__body { padding: 6px 20px 18px; overflow-y: auto; }
.ck-modal__foot {
    display: flex; gap: 10px; flex-wrap: wrap; justify-content: flex-end;
    padding: 16px 20px; border-top: 1px solid var(--border);
}

/* --- Строка категории --- */
.ck-cat { padding: 16px 0; border-bottom: 1px solid var(--border); }
.ck-cat:last-child { border-bottom: none; }
.ck-cat__top { display: flex; align-items: center; justify-content: space-between; gap: 14px; }
.ck-cat__name { font-size: 15px; font-weight: 700; }
.ck-cat__descr { margin: 6px 0 0; font-size: 13.5px; line-height: 1.6; color: var(--text-muted); }
.ck-cat__lock { font-size: 12px; font-weight: 700; color: var(--text-muted); white-space: nowrap; }

/* Переключатель-«айфон». input визуально скрыт, но доступен с клавиатуры. */
.ck-switch { position: relative; flex: none; width: 46px; height: 26px; }
.ck-switch input {
    position: absolute; inset: 0; width: 100%; height: 100%;
    margin: 0; padding: 0; opacity: 0; cursor: pointer;
}
.ck-switch__track {
    position: absolute; inset: 0; pointer-events: none;
    background: var(--bg-elev); border: 1px solid var(--border);
    border-radius: 100px; transition: background .18s, border-color .18s;
}
.ck-switch__track::after {
    content: ""; position: absolute; top: 3px; left: 3px;
    width: 18px; height: 18px; border-radius: 50%;
    background: var(--text-muted); transition: transform .18s, background .18s;
}
.ck-switch input:checked + .ck-switch__track { background: var(--accent-soft); border-color: var(--accent); }
.ck-switch input:checked + .ck-switch__track::after { transform: translateX(20px); background: var(--accent); }
.ck-switch input:focus-visible + .ck-switch__track { box-shadow: 0 0 0 3px var(--accent-soft); }
.ck-switch input:disabled { cursor: not-allowed; }
.ck-switch input:disabled + .ck-switch__track { opacity: .6; }

/* --- Страница /cookies --- */
.ck-doc__row { padding: 14px 0; border-bottom: 1px solid var(--border); }
.ck-doc__row:last-child { border-bottom: none; }
.ck-doc__head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.ck-doc__text { margin: 6px 0 0; font-size: 14px; line-height: 1.6; }
.ck-doc__actions { display: flex; gap: 10px; flex-wrap: wrap; }

@media (max-width: 640px) {
    .ck-bar { margin: 0; border-radius: var(--radius) var(--radius) 0 0; padding: 16px; gap: 14px; }
    .ck-bar__actions { width: 100%; }
    .ck-bar__actions .btn { flex: 1 1 100%; min-width: 0; }
    .ck-modal__win { margin: 0; width: 100%; max-height: 92vh;
        position: absolute; left: 0; right: 0; bottom: 0;
        border-radius: var(--radius) var(--radius) 0 0; }
    .ck-modal__foot .btn { flex: 1 1 100%; }
}

/* Уважение к системной настройке «меньше движения». */
@media (prefers-reduced-motion: reduce) {
    .ck-bar { transition: none; }
}


/* === gameshop/gameshop.css === */
/* ============================================================================
   Модуль gameshop (Игровой магазин) — витрина скинов/транспорта.
   Попадает в общий бандл модулей (files/cache/modules.css), пока модуль включён.
   ========================================================================= */

/* Вкладки категорий */
.gshop__tabs { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 20px; }
.gshop__tab {
    padding: 8px 16px; border: 1px solid var(--border); border-radius: var(--radius-sm);
    background: var(--bg-elev); color: var(--text-muted); font-weight: 600; font-size: 14px;
    transition: border-color .15s, color .15s;
}
.gshop__tab:hover { color: var(--text); border-color: var(--accent); }
.gshop__tab.is-active { background: linear-gradient(135deg, var(--accent), var(--accent-strong)); color: #fff; border-color: transparent; }

/* Сетка карточек */
.gshop__grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 16px; }
.gshop-card {
    position: relative; display: flex; flex-direction: column; gap: 8px;
    background: var(--bg-elev); border: 1px solid var(--border); border-radius: var(--radius);
    padding: 14px; text-align: center;
}
.gshop-card__sale {
    position: absolute; top: 10px; left: 10px; z-index: 2;
    background: var(--green); color: #fff; font-size: 12px; font-weight: 800;
    padding: 2px 8px; border-radius: 20px;
}
.gshop-card__img {
    display: flex; align-items: center; justify-content: center;
    height: 140px; background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius-sm); overflow: hidden;
}
.gshop-card__img img { max-width: 100%; max-height: 100%; object-fit: contain; }
.gshop-card__noimg { font-size: 44px; opacity: .5; }
.gshop-card__name { font-weight: 700; font-size: 15px; }
.gshop-card__server { font-size: 12px; }
.gshop-card__prices { display: flex; flex-direction: column; gap: 2px; margin: 4px 0 8px; }
.gshop-card__price { font-weight: 800; font-size: 15px; color: var(--accent); }
.gshop-card__price s { font-weight: 400; font-size: 12px; }
.gshop-card__price b { font-size: 12px; }
.gshop-card__owned { cursor: default; opacity: .8; }

/* Плашка баланса монет на выбранном сервере */
.gshop-coins-bar {
    display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
    padding: 10px 14px; margin-bottom: 16px;
    border: 1px solid var(--border); border-radius: var(--radius-sm);
    background: var(--bg-elev); font-size: 14px;
}
.gshop-coins-bar b { color: var(--accent); }
.gshop-coins-bar--locked { border-color: var(--red); }

/* Способ оплаты в модалке: нативный radio спрятан, рисуем свою «точку» */
.gshop-pay { display: flex; flex-direction: column; gap: 8px; }
.gshop-pay__opt {
    position: relative; display: flex; align-items: center; gap: 12px;
    padding: 13px 14px; border: 1px solid var(--border); border-radius: var(--radius-sm);
    background: var(--bg-elev); cursor: pointer; font-weight: 700; font-size: 15px;
    transition: border-color .15s, box-shadow .15s;
}
.gshop-pay__opt:hover { border-color: var(--accent); }
.gshop-pay__opt input[type="radio"] {
    position: absolute; opacity: 0; width: 0; height: 0; margin: 0; pointer-events: none;
}
.gshop-pay__dot {
    width: 20px; height: 20px; flex: 0 0 auto; border-radius: 50%;
    border: 2px solid var(--border); background: var(--bg-card);
    transition: border-color .15s, background .15s, box-shadow .15s;
}
.gshop-pay__opt input:checked ~ .gshop-pay__dot {
    border-color: var(--accent); background: var(--accent);
    box-shadow: inset 0 0 0 3px var(--bg-elev);
}
.gshop-pay__opt:has(input:checked) { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent) inset; }

/* Админ-редактор товаров (таблица тарифов/цен) */
.gshop-adm-img { width: 46px; height: 46px; object-fit: contain; border: 1px solid var(--border); border-radius: 6px; background: var(--bg-elev); }

@media (max-width: 560px) {
    .gshop__grid { grid-template-columns: repeat(2, 1fr); }
}


/* === site_stats/site_stats.css === */
/* ============================================================================
   Модуль site_stats — стили блока «Статистика».
   Подключается автоматически на всех страницах, пока модуль включён
   (админка «Модули»); main.css темы не затрагивается.
   ========================================================================= */

.site-stats { display: grid; gap: 8px 34px; font-size: 14px; }
.site-stats--h { grid-template-columns: repeat(3, minmax(0, 1fr)); grid-auto-flow: column; grid-template-rows: repeat(4, auto); }
.site-stats--v { grid-template-columns: 1fr; }
.site-stats__item { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.site-stats__label { color: var(--text-muted); }
.site-stats__value { color: var(--text); font-weight: 800; }
.site-stats__today { color: var(--red); font-weight: 800; font-size: 11px; margin-left: 2px; }

@media (max-width: 760px) {
    .site-stats--h { grid-template-columns: 1fr; grid-auto-flow: row; grid-template-rows: none; }
}


/* === verification/verification.css === */
/* Модуль verification — значки возле ников (собираются в общий бандл modules.css) */

/* Значок-иконка: цветной квадрат со скруглением и белой SVG-иконкой */
.vbadge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 16px;
    height: 16px;
    margin-left: 4px;
    vertical-align: -2px;
    border-radius: 5px;
    background: var(--vb, #6366f1);
    color: #fff;
    flex: none;
    line-height: 1;
}
.vbadge svg { width: 10px; height: 10px; fill: currentColor; display: block; }

/* Значок-«пилюля» с текстом (как «Проверенный» ✔) */
.vbadge--label {
    width: auto;
    gap: 4px;
    padding: 2px 8px 2px 6px;
    font-size: 11px;
    font-weight: 700;
    border-radius: 999px;
}
.vbadge--label i { font-style: normal; white-space: nowrap; }

/* В тесных местах (топ по балансу) пилюля не должна раздувать строку.
   В шапке значки не выводятся вовсе (userId в Page::userbar не передаётся). */
.top-list__name .vbadge--label i { display: none; }
.top-list__name .vbadge--label { width: 16px; padding: 0; justify-content: center; border-radius: 5px; }

/* --- Значок подтверждения поверх аватарки (как в мессенджерах) ---------- */
/* Обёртка аватара: <span class="v-avatar"><img …>{значок}</span> */
.v-avatar { position: relative; display: inline-block; line-height: 0; }
.v-avatar__badge {
    position: absolute;
    top: -2px;
    right: -2px;
    width: 30%;
    min-width: 18px;
    max-width: 36px;
    height: auto;
    pointer-events: none;
    filter: drop-shadow(0 2px 5px rgba(0, 0, 0, .35));
    z-index: 1;
}
/* В профиле аватар крупнее — значок чуть больше и ближе к краю круга */
.v-avatar--profile .v-avatar__badge { top: 0; right: 0; width: 32px; }
.v-avatar--card .v-avatar__badge { top: 2px; right: 2px; }

/* Строка «Профиль подтверждён» под ником в профиле */
.profile__verified {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin: 0 0 8px;
    padding: 3px 12px 3px 8px;
    border-radius: 999px;
    background: rgba(0, 168, 252, .12);
    color: #00a8fc;
    font-size: 13px;
    font-weight: 700;
}
.profile__verified img { width: 16px; height: 16px; flex: none; }

/* Страница /verification — карточки значков */
.verif-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; }
.verif-card { display: flex; gap: 12px; align-items: flex-start; padding: 14px; background: var(--bg-elev); border: 1px solid var(--border); border-radius: var(--radius-sm); }
.verif-card .vbadge { width: 34px; height: 34px; margin: 0; border-radius: 10px; }
.verif-card .vbadge svg { width: 20px; height: 20px; }
.verif-card .vbadge--label { width: 34px; padding: 0; }
.verif-card .vbadge--label i { display: none; }
.verif-card__name { font-weight: 700; margin-bottom: 2px; }
.verif-card__descr { font-size: 13px; color: var(--text-muted); }
.verif-card__count { margin-top: 6px; font-size: 12px; color: var(--text-muted); }

@media (max-width: 560px) {
    .verif-grid { grid-template-columns: 1fr; }
}


