/* ============================================================
   Paushu Reel Theme — main.css
   ============================================================ */

/* ── Variables ─────────────────────────────────────────────── */
:root {
    --accent:       #e63030;
    --bg:           #0a0a0a;
    --surface:      #161616;
    --text:         #f0ece4;
    --muted:        rgba(240,236,228,.55);
    --header-h:     0px;            /* шапка убрана, оставлено для совместимости */
    --rail-w:       58px;           /* ширина сквозной правой панели */
    --radius:       10px;
    --font-display: 'Playfair Display', Georgia, serif;
    --font-body:    'Manrope', 'Helvetica Neue', sans-serif;
    --safe-bottom:  env(safe-area-inset-bottom, 0px);
    --safe-top:     env(safe-area-inset-top, 0px);
}

/* ── Reset ──────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
    background: var(--bg);
    color: var(--text);
    font-family: var(--font-body);
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
}

body {
    min-height: var(--paushu-vh, 100dvh);
    overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
img, video { display: block; max-width: 100%; }

/* ── Google Fonts ───────────────────────────────────────────── */
@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,600;0,700;1,500&family=Manrope:wght@400;500;600&display=swap');

/* ══════════════════════════════════════════════════════════════
   HEADER
══════════════════════════════════════════════════════════════ */
/* ══════════════════════════════════════════════════════════════
   (Old .site-header / .nav-toggle / .site-nav removed — UI переехал в #paushu-rail)
══════════════════════════════════════════════════════════════ */

/* ══════════════════════════════════════════════════════════════
   REEL FEED (TikTok-style)
══════════════════════════════════════════════════════════════ */
.reel-feed {
    /* ═════════════════════════════════════════════════════════════
       INDEX-BASED FEED (v2.13.0):
       Убран scroll-snap полностью. Контейнер не скроллится — вместо
       этого слайды позиционируются абсолютно и сдвигаются через
       transform: translateY(-activeIdx * 100%). Каждый свайп (в JS)
       меняет --paushu-active-idx на контейнере, CSS transition
       делает плавный переход.

       Причина перехода: на Chromium Xiaomi 14 Ultra scroll-snap
       mandatory откатывал программные scrollTop через ~300мс,
       proximity не притягивал slide на snap-point, а "половина
       слайда / половина слайда" после inertia были нерешаемыми
       без mandatory. Вся эта механика теперь не используется —
       управление прямое, 1 свайп = 1 переключение индекса.
       ═════════════════════════════════════════════════════════════ */
    position: relative;
    height: var(--paushu-vh, 100dvh);
    width: 100%;
    overflow: hidden;
    scrollbar-width: none;
    /* Счётчик текущего активного слайда. JS меняет через
       feed.style.setProperty('--paushu-active-idx', N). */
    --paushu-active-idx: 0;
    /* drag-offset — во время live swipe (сейчас не используется, но
       зарезервировано). При базовом варианте = 0px, transition даёт
       плавный перелёт между слайдами. */
    --paushu-drag-y: 0px;
}
.reel-feed::-webkit-scrollbar { display: none; }

/* ── Slide / Card ───────────────────────────────────────────── */
.reel-slide {
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    height: var(--paushu-vh, 100dvh);
    /* Позиция каждого слайда: его собственный индекс (data-slide-idx,
       устанавливается в JS) минус текущий активный. Активный
       получает translateY(0), следующий — translateY(100%), предыдущий —
       translateY(-100%), и т.д.
       Логика: translateY((myIdx - activeIdx) * 100%) */
    transform: translate3d(
        0,
        calc( (var(--paushu-slide-idx, 0) - var(--paushu-active-idx, 0)) * 100% + var(--paushu-drag-y, 0px) ),
        0
    );
    transition: transform 280ms cubic-bezier(0.22, 0.61, 0.36, 1);
    will-change: transform;
    overflow: hidden;
    background: var(--bg);
    display: flex;
    flex-direction: column;
    touch-action: pan-y;
}

/* Во время live-drag (если потом добавим) transition должен быть
   отключён, чтобы следовать за пальцем мгновенно. */
.reel-feed.is-dragging .reel-slide {
    transition: none;
}

/* Зумированная картинка/видео — touch-action: none, вся обработка в JS
   (single-finger pan, two-finger pinch). Чтобы pan в зуме работал. */
.reel-slide .is-zoomed,
.single-slide .is-zoomed,
.comment-slide .is-zoomed {
    touch-action: none;
}

/* ── Media area ─────────────────────────────────────────────── */
.reel-media {
    position: absolute;
    inset: 0;
    z-index: 0;
}

.reel-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center top;
}

.reel-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    /* iOS Safari: <video> имеет нативные touch-обработчики (системный
       play/pause overlay, swipe-через-видео), которые перехватывают
       вертикальный свайп ленты если палец оказался над видео.
       Попытка управлять через touch-action: pan-y конфликтует с JS-
       обработчиком pinch-zoom — получается хаотичный snap.
       Решение: полностью отключаем pointer-events у <video>. Все
       touch/click события проходят насквозь к родителю (.reel-media
       или .reel-slide), где и работает scroll-snap. Play/pause
       управляется только из JS (в activateFeedSlide/deactivateFeedSlide),
       нативные controls у нас не используются. Pinch-zoom продолжает
       работать: initPinchZoom слушает на document, находит слайд через
       elementFromPoint, и уже через querySelector('.reel-video')
       получает target — pointer-events не влияет на querySelector. */
    pointer-events: none;
}

/* iframe wrapper for YouTube/Vimeo */
.reel-iframe-wrap {
    position: relative;
    width: 100%;
    height: 100%;
    cursor: pointer;
}

.reel-iframe-wrap .reel-thumb-placeholder {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.reel-iframe-wrap iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: none;
    pointer-events: none; /* prevent iframe eating touch events */
}

.reel-play-icon {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 4rem;
    color: rgba(255,255,255,.85);
    text-shadow: 0 2px 20px rgba(0,0,0,.5);
    pointer-events: none;
    transition: opacity .3s;
}

.reel-iframe-wrap.is-playing .reel-play-icon,
.reel-iframe-wrap.is-playing .reel-thumb-placeholder {
    opacity: 0;
    pointer-events: none;
}

/* ── Gradient overlay ───────────────────────────────────────── */
.reel-overlay {
    position: absolute;
    inset: 0;
    z-index: 1;
    background: linear-gradient(
        to bottom,
        rgba(0,0,0,.35) 0%,        /* top — header area */
        transparent 30%,
        transparent 50%,
        rgba(0,0,0,.5) 72%,
        rgba(0,0,0,.85) 100%       /* bottom — info area */
    );
    pointer-events: none;
}

/* ── Info panel (bottom 20%) ────────────────────────────────── */
.reel-info {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    z-index: 2;
    padding: 20px 20px calc(20px + var(--safe-bottom));
    min-height: 20dvh;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    gap: 6px;
}

.reel-cat {
    display: inline-block;
    font-size: .65rem;
    font-weight: 600;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--cat-color);
    background: var(--cat-bg);
    border: 1px solid var(--cat-border);
    border-radius: 4px;
    padding: 2px 8px;
    align-self: flex-start;
    text-decoration: none;
    transition: background .18s, border-color .18s, transform .15s;
}
a.reel-cat:hover {
    background: var(--cat-border);
}
a.reel-cat:active { transform: scale(.96); }

.reel-title {
    font-family: var(--font-display);
    font-size: clamp(1.15rem, 5vw, 1.5rem);
    font-weight: 700;
    line-height: 1.2;
    color: #fff;
    text-shadow: 0 1px 12px rgba(0,0,0,.6);
}

.reel-title a { color: inherit; }

.reel-excerpt {
    font-size: .82rem;
    line-height: 1.5;
    color: var(--muted);
    /* Без line-clamp — показываем анонс целиком */
}

.reel-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: 4px;
}

.reel-date {
    font-size: .75rem;
    color: var(--muted);
}

/* .reel-read-btn удалён — кнопка «открыть пост» теперь в rail (.rail-btn--open) */

/* ── No media fallback ──────────────────────────────────────── */
.reel-no-media {
    width: 100%; height: 100%;
    background: linear-gradient(135deg, var(--surface) 0%, #1e1e1e 100%);
}

/* ══════════════════════════════════════════════════════════════
   (Old .reel-sidebar / .sb-* removed — контролы переехали в #paushu-rail)
══════════════════════════════════════════════════════════════ */

/* ══════════════════════════════════════════════════════════════
   TOAST уведомление
══════════════════════════════════════════════════════════════ */
.paushu-toast {
    position: fixed;
    bottom: calc(var(--safe-bottom) + 80px);
    left: 50%;
    transform: translateX(-50%) translateY(20px);
    z-index: 9999;
    background: rgba(20,20,20,.92);
    border: 1px solid rgba(255,255,255,.12);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    color: #fff;
    font-size: .82rem;
    font-family: var(--font-body);
    padding: 9px 18px;
    border-radius: 24px;
    pointer-events: none;
    opacity: 0;
    transition: opacity .25s, transform .25s;
    white-space: nowrap;
}

.paushu-toast.is-visible {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}


/* ── Loader ─────────────────────────────────────────────────── */
.reel-loader {
    display: flex;
    align-items: center;
    justify-content: center;
    /* height и scroll-snap-align наследуются от .reel-slide */
}

.reel-loader__spinner {
    width: 36px; height: 36px;
    border: 3px solid rgba(255,255,255,.12);
    border-top-color: var(--accent);
    border-radius: 50%;
    animation: spin .8s linear infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }

/* ── Empty state ────────────────────────────────────────────── */
.reel-empty {
    height: var(--paushu-vh, 100dvh);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--muted);
    font-size: 1rem;
}

/* ══════════════════════════════════════════════════════════════
   FOOTER (only visible on single posts / other pages)
══════════════════════════════════════════════════════════════ */
.site-footer {
    padding: 24px 20px calc(20px + var(--safe-bottom));
    text-align: center;
    font-size: .75rem;
    color: var(--muted);
    border-top: 1px solid rgba(255,255,255,.06);
    background: var(--bg);
}

/* On feed, footer is hidden (feed is full-screen) */
.home .site-footer,
.blog .site-footer {
    display: none;
}

/* .archive-context удалён — контекст архива теперь в .rail-menu-context (см. rail-стили) */

.ctx-label {
    text-transform: uppercase;
    letter-spacing: .08em;
    color: rgba(255,255,255,.4);
}

.ctx-value {
    font-weight: 600;
    color: var(--accent);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 200px;
}

/* ── Scroll-snap hint arrow (auto-hides) ───────────────────── */
.reel-scroll-hint {
    position: fixed;
    bottom: calc(24px + var(--safe-bottom));
    left: 50%;
    transform: translateX(-50%);
    z-index: 50;
    color: rgba(255,255,255,.5);
    font-size: .7rem;
    letter-spacing: .08em;
    text-transform: uppercase;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    pointer-events: none;
    animation: hintFloat 1.8s ease-in-out infinite, hintFadeOut 3s 3s forwards;
}

.reel-scroll-hint svg {
    animation: hintFloat 1.8s ease-in-out infinite;
}

@keyframes hintFloat {
    0%, 100% { transform: translateY(0); }
    50%       { transform: translateY(6px); }
}

@keyframes hintFadeOut {
    to { opacity: 0; }
}

/* ══════════════════════════════════════════════════════════════
   УНИВЕРСАЛЬНАЯ КОЛОНКА 9:16 — без медиа-брейкпоинтов по ширине
   Логика:
     экран шире 9:16  → колонка = высота экрана × (9/16)
     экран уже  9:16  → колонка = полная ширина экрана
   Формула min(100vw, 100dvh × 9/16) даёт оба случая автоматически.
══════════════════════════════════════════════════════════════ */

:root {
    --phone-w:  min(100vw, calc(100dvh * 9 / 16));
    --col-left: calc(50% - var(--phone-w) / 2);
}

/* ── Страница не скроллится сама — скролл только внутри колонки */
html, body {
    overflow: hidden;
    height: var(--paushu-vh, 100dvh);
    background: #060606;
}

/* ── Тонкая рамка вокруг колонки + тени по бокам ────────────
   Когда колонка = 100vw (узкий телефон), рамка на краях экрана —
   не видна. Когда колонка < 100vw — видны боковые тени.        */
body::after {
    content: '';
    position: fixed;
    top: 0; bottom: 0;
    left: var(--col-left);
    width: var(--phone-w);
    outline: 1px solid rgba(255,255,255,.06);
    box-shadow:
        -100px 0 200px rgba(0,0,0,.98),
          100px 0 200px rgba(0,0,0,.98);
    pointer-events: none;
    z-index: 9000;
}

/* ── Подпись слева от колонки (видна только на широких экранах)
   Когда колонка = 100vw: right = 50% + 50vw + 20px = 100vw + 20px
   → уходит за край, не видна. Безопасно оставить всегда.       */
body::before {
    content: 'paushu.ru';
    position: fixed;
    left: 0;
    right: calc(50% + var(--phone-w) / 2 + 20px);
    bottom: 28px;
    text-align: right;
    font-family: var(--font-display);
    font-size: .6rem;
    letter-spacing: .22em;
    text-transform: uppercase;
    color: rgba(255,255,255,.07);
    pointer-events: none;
    z-index: 8999;
}

/* ── Лента: фиксированная, в пределах колонки ──────────────── */
.reel-feed {
    position: fixed;
    top: 0; bottom: 0;
    left: var(--col-left);
    right: auto;
    width: var(--phone-w);
    height: var(--paushu-vh, 100dvh);
}

/* ── Одиночный пост (уже position:fixed) ────────────────────── */
.single-reel {
    left: var(--col-left);
    right: auto;
    width: var(--phone-w);
}

/* ── Rail и drawer'ы: прижать к правому краю колонки, не экрана ── */
.paushu-rail {
    right: var(--col-left);         /* симметрично от правого края колонки */
}
.rail-drawer__inner {
    right: calc(var(--col-left) + var(--rail-w));
    /* И не шире колонки за вычетом rail */
    max-width: calc(var(--phone-w) - var(--rail-w));
}

/* Тоаст и scroll-hint центрируем по колонке с учётом rail */
.paushu-toast,
.reel-scroll-hint {
    left: calc(var(--col-left) + (var(--phone-w) - var(--rail-w)) / 2);
}

/* ── Футер скрыт на всех лентах ─────────────────────────────── */
.home .site-footer,
.blog .site-footer,
.archive .site-footer,
.search .site-footer {
    display: none;
}

/* ── Scroll-hint и fixed-попапы уже используют left:50% + translateX(-50%)
   что всегда совпадает с центром колонки — менять не нужно.    */

/* ── Share modal (fallback когда нет navigator.share) ──────────────────── */
body.psm-open { overflow: hidden; }

.paushu-share-modal {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    opacity: 0;
    pointer-events: none;
    transition: opacity .2s ease;
    outline: none;
}
.paushu-share-modal.is-visible {
    opacity: 1;
    pointer-events: auto;
}

.psm-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,.75);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
}

.psm-card {
    position: relative;
    width: 100%;
    max-width: 340px;
    background: var(--surface);
    border: 1px solid rgba(255,255,255,.08);
    border-radius: 16px;
    padding: 16px;
    box-shadow: 0 24px 48px rgba(0,0,0,.5);
    transform: translateY(8px) scale(.98);
    transition: transform .22s ease;
}
.paushu-share-modal.is-visible .psm-card {
    transform: translateY(0) scale(1);
}

.psm-close {
    position: absolute;
    top: 6px; right: 8px;
    width: 32px; height: 32px;
    background: transparent;
    border: 0;
    color: var(--muted);
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
    border-radius: 50%;
    transition: background .15s, color .15s;
}
.psm-close:hover { background: rgba(255,255,255,.06); color: var(--text); }

/* Постер (картинка поста) — основной кликабельный элемент */
.psm-poster {
    display: block;
    width: 100%;
    aspect-ratio: 9 / 16;
    max-height: 320px;
    overflow: hidden;
    border-radius: 12px;
    background: rgba(255,255,255,.04);
    margin-bottom: 14px;
    position: relative;
}
.psm-poster img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform .4s ease;
}
.psm-poster:hover img { transform: scale(1.03); }

/* Если картинки нет — покажем название крупно */
.psm-poster--nopic {
    aspect-ratio: auto;
    min-height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    text-align: center;
}
.psm-poster-title {
    font-family: var(--font-display);
    font-size: 1.2rem;
    color: var(--text);
    line-height: 1.3;
}

.psm-quote {
    font-family: var(--font-display);
    font-style: italic;
    color: var(--muted);
    font-size: .92rem;
    line-height: 1.45;
    padding: 0 8px;
    margin-bottom: 14px;
    border-left: 2px solid var(--accent);
    padding-left: 12px;
    max-height: 4.5em;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
}

.psm-networks {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 4px;
}

.psm-net {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: 10px 2px;
    background: transparent;
    border: 0;
    border-radius: 10px;
    color: var(--text);
    text-decoration: none;
    cursor: pointer;
    font-family: var(--font-body);
    font-size: .66rem;
    transition: background .15s;
}
.psm-net:hover { background: rgba(255,255,255,.06); }

.psm-net-icon {
    width: 36px; height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255,255,255,.07);
    color: var(--text);
}
.psm-net--tg   .psm-net-icon { background: #2AABEE; color: #fff; }
.psm-net--wa   .psm-net-icon { background: #25D366; color: #fff; }
.psm-net--vk   .psm-net-icon { background: #0077FF; color: #fff; }
.psm-net--tw   .psm-net-icon { background: #000;    color: #fff; }
.psm-net--copy .psm-net-icon { background: rgba(255,255,255,.1); color: var(--text); }

.psm-net-label {
    color: var(--muted);
    letter-spacing: .02em;
}

/* Узкие экраны — 3 колонки в 2 ряда */
@media (max-width: 360px) {
    .psm-networks { grid-template-columns: repeat(3, 1fr); }
}

/* ════════════════════════════════════════════════════════════════════════
   COMMENT MODAL — компактный диалог «оставить комментарий» (single post)
   Открывается по клику на rail-кнопку .rail-btn--comments в single-режиме.
   Submit идёт по AJAX (action=paushu_submit_comment), после успеха —
   показываем статус «на модерации» и закрываем через пару секунд.
   ════════════════════════════════════════════════════════════════════════ */
body.pcm-open { overflow: hidden; }

.paushu-comment-modal {
    position: fixed;
    inset: 0;
    z-index: 10001;          /* выше share-modal (10000) */
    display: flex;
    align-items: flex-end;   /* на мобиле выезжает снизу как bottom-sheet */
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity .22s ease;
    padding: 0;
}
.paushu-comment-modal[hidden] { display: none !important; }
.paushu-comment-modal.is-visible {
    opacity: 1;
    pointer-events: auto;
}
@media (min-width: 600px) {
    /* Десктоп — центрируем, не bottom-sheet */
    .paushu-comment-modal { align-items: center; padding: 16px; }
}

.pcm-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,.72);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
}

.pcm-card {
    position: relative;
    width: 100%;
    max-width: 460px;
    background: var(--surface);
    border: 1px solid rgba(255,255,255,.08);
    border-radius: 20px 20px 0 0;
    padding: 20px 20px calc(18px + var(--safe-bottom));
    box-shadow: 0 -10px 40px rgba(0,0,0,.6);
    transform: translateY(100%);
    transition: transform .28s cubic-bezier(.16,1,.3,1);
}
@media (min-width: 600px) {
    .pcm-card {
        border-radius: 18px;
        padding: 22px;
        transform: translateY(8px) scale(.98);
    }
}
.paushu-comment-modal.is-visible .pcm-card {
    transform: translateY(0);
}
@media (min-width: 600px) {
    .paushu-comment-modal.is-visible .pcm-card {
        transform: translateY(0) scale(1);
    }
}

.pcm-close {
    position: absolute;
    top: 8px; right: 10px;
    width: 36px; height: 36px;
    background: transparent;
    border: 0;
    color: var(--muted);
    font-size: 26px;
    line-height: 1;
    cursor: pointer;
    border-radius: 50%;
    transition: background .15s, color .15s;
}
.pcm-close:hover { background: rgba(255,255,255,.06); color: var(--text); }

.pcm-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
}
.pcm-header-icon { font-size: 1.3rem; line-height: 1; }
.pcm-header-text {
    font-family: var(--font-display);
    font-size: 1.15rem;
    font-weight: 600;
    color: var(--text);
    margin: 0;
}

.pcm-form { display: flex; flex-direction: column; gap: 10px; }

.pcm-row { display: block; }
.pcm-row--inline {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}
@media (max-width: 420px) {
    .pcm-row--inline { grid-template-columns: 1fr; }
}

.pcm-input {
    width: 100%;
    background: rgba(255,255,255,.05);
    border: 1px solid rgba(255,255,255,.1);
    border-radius: 999px;
    color: var(--text);
    padding: 11px 16px;
    font-size: .92rem;
    font-family: var(--font-body);
    line-height: 1.3;
    transition: border-color .2s, background .2s, box-shadow .2s;
    box-sizing: border-box;
    outline: none;
    -webkit-appearance: none;
    appearance: none;
}
.pcm-input::placeholder { color: rgba(255,255,255,.4); }
.pcm-input:focus {
    border-color: var(--accent);
    background: rgba(255,255,255,.08);
    box-shadow: 0 0 0 3px rgba(230,48,48,.15);
}
.pcm-input--textarea {
    border-radius: 18px;
    padding: 12px 16px;
    min-height: 90px;
    resize: vertical;
    line-height: 1.5;
    font-family: var(--font-body);
}

.pcm-row--submit {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-top: 4px;
}

.pcm-cookies {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: .78rem;
    color: var(--muted);
    cursor: pointer;
    user-select: none;
}
.pcm-cookies input { accent-color: var(--accent); cursor: pointer; }

.pcm-submit {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--accent);
    color: #fff;
    border: 0;
    padding: 10px 20px;
    border-radius: 999px;
    font-family: var(--font-body);
    font-weight: 600;
    font-size: .88rem;
    cursor: pointer;
    transition: background .18s, transform .15s, opacity .15s;
}
.pcm-submit:hover { background: #c42020; }
.pcm-submit:active { transform: scale(.96); }
.pcm-submit:disabled { opacity: .5; cursor: wait; }

.pcm-status {
    font-size: .85rem;
    line-height: 1.4;
    padding: 10px 14px;
    border-radius: 12px;
    text-align: center;
    display: none;
}
.pcm-status.is-success {
    display: block;
    background: rgba(76, 175, 80, .14);
    border: 1px solid rgba(76, 175, 80, .32);
    color: #a0e8a5;
}
.pcm-status.is-error {
    display: block;
    background: rgba(230, 48, 48, .12);
    border: 1px solid rgba(230, 48, 48, .32);
    color: #ffaaaa;
}


/* ════════════════════════════════════════════════════════════════════════
   PAUSHU RAIL — единая правая панель управления
   Поверх контента, полупрозрачный стиль, одна группа кнопок.
   Контент НЕ сдвигается — rail лежит оверлеем.
   ════════════════════════════════════════════════════════════════════════ */

:root {
    --rail-w:        56px;
    --rail-w-desk:   64px;
    --rail-btn-size: 44px;
    --rail-pad-v:    10px;
    --rail-gap:      8px;
    /* Стиль «стекла»: полупрозрачное чёрное со слабым блюром */
    --rail-btn-bg:        rgba(20, 20, 20, .38);
    --rail-btn-bg-hover:  rgba(20, 20, 20, .58);
    --rail-btn-border:    rgba(255, 255, 255, .12);
    --rail-btn-border-hv: rgba(255, 255, 255, .22);
}

/* ══════════════════════════════════════════════════════════════════════
   Универсальный прогресс-бар сверху (единый для всего сайта)
   Режимы: .paushu-progress[data-mode="slides|video"]
   Все размеры/цвета выводятся из Customizer через CSS vars:
     --pp-accent-slides, --pp-accent-video  (цвета)
     --pp-thumb-size, --pp-thumb-size-d     (размер ползунка моб/десктоп)
     --progress-h, --progress-h-d           (толщина дорожки моб/десктоп)
     --progress-hit                         (высота хит-зоны)
   Управление JS — initProgressBar() в swipe.js
   ══════════════════════════════════════════════════════════════════════ */

/* Fallback'и — если кастомайзер не выставил, используем разумные дефолты */
:root {
    --pp-accent-slides: var(--accent, #e63030);
    --pp-accent-video:  #4dd0e1;
    --pp-thumb-size:    18px;
    --pp-thumb-size-d:  22px;
    --progress-h:       3px;
    --progress-h-d:     4px;
    --progress-hit:     28px;
}

.paushu-progress {
    position: fixed;
    top: var(--safe-top);
    left: 0;
    right: 0;
    height: var(--progress-hit);     /* хит-зона — чтобы тап попадал легко */
    z-index: 96;                      /* выше rail (95), под модалками */
    display: flex;
    align-items: flex-start;          /* дорожка сверху, ниже — воздух для тапа */
    justify-content: center;
    pointer-events: none;             /* активны только .pp-track и .pp-thumb */
    opacity: 0;
    transition: opacity .22s ease;
    /* Текущий акцент — по умолчанию "slides", переопределяется в video-режиме */
    --pp-current-accent: var(--pp-accent-slides);
}
.paushu-progress[data-mode="video"] {
    --pp-current-accent: var(--pp-accent-video);
}
.paushu-progress.is-ready {
    opacity: 1;
}
/* Скрываем когда общий UI спрятан (body.ui-hidden) */
body.ui-hidden .paushu-progress {
    opacity: 0;
    pointer-events: none;
}
/* В галерее не показываем — там своя навигация-пагинатор */
body.galleries-mode .paushu-progress {
    opacity: 0;
    pointer-events: none;
}

.pp-track {
    position: relative;
    width: 100%;
    max-width: 720px;
    height: var(--progress-h);
    background: rgba(255,255,255,.14);
    border-radius: 2px;
    margin: 0 12px;
    pointer-events: auto;             /* тап по дорожке = перейти к позиции */
    cursor: pointer;
    touch-action: none;               /* забираем жесты себе для drag */
    /* Расширяем "кликабельную" зону вокруг дорожки до высоты хит-зоны,
       чтобы палец попадал в полоску даже если жмёт чуть выше/ниже */
    box-sizing: content-box;
}

.pp-fill {
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: 0%;
    background: var(--pp-current-accent);
    border-radius: inherit;
    /* Плавность заполнения — но не на времени видео (там JS сам скачет) */
    transition: width .15s linear, background .2s ease;
}
/* В режиме видео дорожка заливается без плавной анимации (секунды идут тикающе) */
.paushu-progress[data-mode="video"] .pp-fill {
    transition: background .2s ease;
}
/* Во время drag'а анимация отключается — ползунок обязан следовать за пальцем */
.paushu-progress.is-dragging .pp-fill {
    transition: background .2s ease;
}

.pp-thumb {
    position: absolute;
    top: 50%;
    left: 0;
    width:  var(--pp-thumb-size);
    height: var(--pp-thumb-size);
    /* Центрируем ползунок по его центру — половина ширины влево */
    margin-left: calc(var(--pp-thumb-size) / -2);
    border-radius: 50%;
    background: var(--pp-current-accent);
    box-shadow: 0 0 0 2px rgba(0,0,0,.45), 0 2px 6px rgba(0,0,0,.35);
    transform: translateY(-50%) scale(.9);
    transition: transform .18s ease, left .15s linear, background .2s ease,
                width .2s ease, height .2s ease, margin-left .2s ease;
    pointer-events: auto;
    cursor: grab;
    touch-action: none;
}
.paushu-progress[data-mode="video"] .pp-thumb {
    transition: transform .18s ease, left .08s linear, background .2s ease,
                width .2s ease, height .2s ease, margin-left .2s ease;
}
.paushu-progress.is-dragging .pp-thumb {
    transform: translateY(-50%) scale(1.25);
    transition: transform .12s ease, background .2s ease;
    cursor: grabbing;
    left: var(--pp-drag-left, 0%);    /* во время drag — мгновенно */
}
.pp-track:hover .pp-thumb {
    transform: translateY(-50%) scale(1.1);
}

/* Десктоп: бар толще + ползунок крупнее */
@media (min-width: 900px) {
    :root {
        --progress-h:    var(--progress-h-d);
        --pp-thumb-size: var(--pp-thumb-size-d);
    }
}


/* ── Сам rail: fixed, прозрачный фон (никакого градиента/подложки) ──
   Контент виден насквозь; каждая кнопка сама несёт своё стекло. */
.paushu-rail {
    position: fixed;
    top: var(--safe-top);
    right: 0;
    bottom: var(--safe-bottom);
    width: var(--rail-w);
    z-index: 95;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;     /* центруем группу кнопок по вертикали */
    gap: var(--rail-gap);
    padding: var(--rail-pad-v) 0;
    pointer-events: none;        /* только кнопки перехватывают клики */
    -webkit-user-select: none;
    user-select: none;
}
@media (min-width: 600px) {
    .paushu-rail { width: var(--rail-w-desk); }
}

/* Видео-группа — визуально не отличается от остальных кнопок,
   просто ведёт себя как подгруппа (можно спрятать целиком). */
.rail-group {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--rail-gap);
}
.rail-group[hidden] { display: none; }

/* ── Универсальная кнопка rail ──────────────────────────────────── */
.rail-btn {
    width: var(--rail-btn-size);
    height: var(--rail-btn-size);
    border-radius: 50%;
    background: var(--rail-btn-bg);
    border: 1px solid var(--rail-btn-border);
    backdrop-filter: blur(14px) saturate(140%);
    -webkit-backdrop-filter: blur(14px) saturate(140%);
    color: #fff;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    padding: 0;
    flex-shrink: 0;
    pointer-events: auto;
    text-decoration: none;
    font-family: var(--font-body);
    transition: background .18s, border-color .18s, transform .12s, color .18s;
    -webkit-tap-highlight-color: transparent;
    animation: rail-fade-in .22s ease;
}
.rail-btn[hidden] { display: none !important; }
.rail-btn:hover {
    background: var(--rail-btn-bg-hover);
    border-color: var(--rail-btn-border-hv);
}
.rail-btn:active { transform: scale(.88); }

.rail-btn svg {
    width: 20px; height: 20px;
    flex-shrink: 0;
    pointer-events: none;
}

/* Счётчик лайков под иконкой */
.rail-count {
    font-size: .56rem;
    font-weight: 700;
    line-height: 1;
    color: rgba(255,255,255,.88);
    pointer-events: none;
    letter-spacing: .01em;
}
.rail-count:empty { display: none; }

/* ── Play / Pause icon swap ─────────────────────────────────────── */
.rail-btn--play .ri--play  { display: none; }
.rail-btn--play .ri--pause { display: block; }
.paushu-rail.is-paused .rail-btn--play .ri--play  { display: block; }
.paushu-rail.is-paused .rail-btn--play .ri--pause { display: none; }

/* ── Mute icon swap ─────────────────────────────────────────────── */
.rail-btn--mute .ri--sound { display: block; }
.rail-btn--mute .ri--muted { display: none; }
.paushu-rail.is-muted .rail-btn--mute .ri--sound { display: none; }
.paushu-rail.is-muted .rail-btn--mute .ri--muted { display: block; }

/* ── Fullscreen icon swap ───────────────────────────────────────── */
/* fullscreen кнопка убрана */

/* ── Volume slider (вертикальный, круглый корпус как у кнопки) ─── */
.rail-vol-wrap {
    width: var(--rail-btn-size);
    height: 72px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--rail-btn-bg);
    border: 1px solid var(--rail-btn-border);
    border-radius: 22px;
    backdrop-filter: blur(14px) saturate(140%);
    -webkit-backdrop-filter: blur(14px) saturate(140%);
    pointer-events: auto;
    animation: rail-fade-in .22s ease;
}
.rail-vol {
    -webkit-appearance: none;
    appearance: none;
    writing-mode: vertical-lr;
    direction: rtl;
    width: 4px;
    height: 52px;
    background: rgba(255,255,255,.2);
    border-radius: 2px;
    cursor: pointer;
    outline: none;
    accent-color: #fff;
}
.rail-vol::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 12px; height: 12px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 0 4px rgba(0,0,0,.5);
}

/* ── Скорость: текстовая кнопка ─────────────────────────────────── */
.rail-btn--speed { font-size: .72rem; font-weight: 700; letter-spacing: -.01em; }
.rail-speed-label { pointer-events: none; }

/* ── Лайк active ────────────────────────────────────────────────── */
.rail-btn--like svg {
    transition: fill .18s, stroke .18s, transform .18s;
    /* Подсказка браузеру: scale на SVG — в composite-слое, не трогаем
       reflow и не двигаем scroll-snap. */
    will-change: transform;
    transform-origin: center;
}

/* ── Видео-группа в состоянии «iframe ещё грузится» ──────────────
   Когда пользователь только что свайпнул на YouTube/Vimeo-слайд,
   iframe создаётся лениво и load-событие приходит через 200-2000мс.
   До этого момента кнопки play/mute/speed не работают (controller=null).
   Делаем их визуально неактивными — чтобы пользователь не тапал впустую. */
.paushu-rail.rail-video-loading .rail-group--video .rail-btn,
.paushu-rail.rail-video-loading .rail-vol-wrap {
    opacity: .45;
    cursor: wait;
    pointer-events: none;
}
.paushu-rail.rail-video-loading .rail-group--video .rail-btn--play {
    /* Маленький индикатор: spin-анимация вместо play-иконки */
    position: relative;
}
.paushu-rail.rail-video-loading .rail-group--video .rail-btn--play::after {
    content: '';
    position: absolute;
    inset: 30%;
    border: 2px solid rgba(255,255,255,.2);
    border-top-color: #fff;
    border-radius: 50%;
    animation: rail-spin .7s linear infinite;
}
.paushu-rail.rail-video-loading .rail-group--video .rail-btn--play svg {
    opacity: 0;
}
.rail-btn--like.is-liked svg {
    fill: var(--accent);
    stroke: var(--accent);
    transform: scale(1.18);
}
.rail-btn--like.is-liked { border-color: rgba(230,48,48,.4); }

/* ── Поиск / меню — тот же стиль что у остальных кнопок ─────────
   В активном состоянии (drawer открыт) — акцент, чтобы было видно. */
.rail-btn--search[aria-expanded="true"],
.rail-btn--menu[aria-expanded="true"] {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
}

/* ── Появление кнопок при смене слайда ───────────────────────── */
@keyframes rail-fade-in {
    from { opacity: 0; transform: translateY(4px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ════════════════════════════════════════════════════════════════════════
   DRAWER — выпадающие панели поиска и меню (выезжают справа, прилипают к rail)
   ════════════════════════════════════════════════════════════════════════ */
body.rail-drawer-open { overflow: hidden; }
/* Но если открыт только popover (меню или поиск), body-scroll не блокируем */
body.rail-drawer-open:has(.rail-drawer--menu.is-open),
body.rail-drawer-open:has(.rail-drawer--search.is-open) {
    overflow: auto;
}

.rail-drawer {
    position: fixed;
    inset: 0;
    z-index: 96;
    background: rgba(0,0,0,.6);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    opacity: 0;
    pointer-events: none;
    transition: opacity .22s ease;
}
.rail-drawer.is-open {
    opacity: 1;
    pointer-events: auto;
}

.rail-drawer__inner {
    position: absolute;
    top: 0; bottom: 0;
    right: var(--rail-w);
    width: min(360px, calc(100vw - var(--rail-w)));
    background: rgba(16, 16, 16, .96);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: calc(var(--safe-top) + 18px) 22px calc(var(--safe-bottom) + 22px);
    overflow-y: auto;
    transform: translateX(100%);
    transition: transform .28s cubic-bezier(.16,1,.3,1);
    box-shadow: -8px 0 24px rgba(0,0,0,.45);
}
@media (min-width: 600px) {
    .rail-drawer__inner { right: var(--rail-w-desk); }
}
.rail-drawer.is-open .rail-drawer__inner {
    transform: translateX(0);
}

.rail-drawer__close {
    background: transparent;
    border: 0;
    color: var(--muted);
    font-size: 26px;
    line-height: 1;
    width: 32px; height: 32px;
    cursor: pointer;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: background .15s, color .15s;
    flex-shrink: 0;
}
.rail-drawer__close:hover { background: rgba(255,255,255,.08); color: var(--text); }

/* ── Search drawer — стеклянная пилула рядом с кнопкой поиска ─────────────── */
.rail-drawer--search {
    /* Полупрозрачный бэкдроп чтобы клик мимо закрывал */
    background: transparent;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
}

.rail-drawer--search .rail-drawer__inner {
    /* Поверх default-позиции: panel-on-right → popover под кнопкой поиска */
    position: absolute;
    top: calc(var(--safe-top) + var(--rail-pad-v) + var(--rail-btn-size) * 3 + 12px);
    bottom: auto;
    right: calc(var(--rail-w) + 8px);
    left: auto;
    width: min(320px, calc(100vw - var(--rail-w) - 24px));
    height: auto;
    padding: 10px 12px;
    background: rgba(16, 16, 16, .92);
    backdrop-filter: blur(18px) saturate(150%);
    -webkit-backdrop-filter: blur(18px) saturate(150%);
    border: 1px solid rgba(255,255,255,.1);
    border-radius: 999px;    /* пилула */
    box-shadow: 0 12px 32px rgba(0,0,0,.5);
    transform: translateX(8px) scale(.96);
    transform-origin: top right;
    opacity: 0;
    transition: transform .22s cubic-bezier(.16,1,.3,1), opacity .18s;
}
.rail-drawer--search.is-open .rail-drawer__inner {
    transform: translateX(0) scale(1);
    opacity: 1;
}

@media (min-width: 600px) {
    .rail-drawer--search .rail-drawer__inner {
        right: calc(var(--rail-w-desk) + 8px);
    }
}

.rail-search-form {
    display: flex;
    align-items: center;
    gap: 6px;
    border-bottom: 0;           /* больше нет подчёркивания — сама пилула достаточно границ */
    padding-bottom: 0;
    margin: 0;
}
.rail-search-form input[type="search"] {
    flex: 1 1 auto;
    min-width: 0;
    background: transparent;
    border: 0;
    outline: none;
    color: var(--text);
    font-family: var(--font-body);
    font-size: 1rem;
    padding: 4px 6px;
    -webkit-appearance: none;
}
.rail-search-form input[type="search"]::placeholder {
    color: var(--muted);
    font-style: normal;
}
.rail-search-submit {
    background: transparent;
    border: 0;
    color: var(--text);
    width: 32px; height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border-radius: 50%;
    transition: background .15s;
    flex-shrink: 0;
}
.rail-search-submit:hover { background: rgba(255,255,255,.08); }

/* Крестик внутри пилулы — компактный */
.rail-drawer--search .rail-drawer__close {
    width: 28px; height: 28px;
    font-size: 20px;
}

/* ── Menu popover ───────────────────────────────────────────────
   Выпадает рядом с кнопкой меню (справа внизу), не на весь экран.
   Пункты — пилулы в стилистике .reel-cat, только крупнее. */
.rail-drawer--menu.rail-popover {
    /* Бэкдроп прозрачный, но inset: 0 остаётся — чтобы клик мимо popover закрывал */
    background: transparent;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
}
.rail-drawer--menu.rail-popover.is-open {
    /* Не блокируем body scroll для такого компактного попапа */
}
body.rail-drawer-open:has(.rail-drawer--menu.is-open:not(.rail-drawer--search)) {
    /* уже учтено в блоке выше */
}
.rail-drawer--menu.rail-popover .rail-drawer__inner,
.rail-popover__inner {
    position: absolute;
    /* Позиция рядом с кнопкой меню: справа, сверху (под кнопкой, т.к. меню теперь
       наверху rail). Popover выезжает из-под кнопки вниз. */
    top: calc(var(--safe-top) + var(--rail-pad-v) + var(--rail-btn-size) + 12px);
    bottom: auto;
    right: calc(var(--rail-w) + 8px);
    left: auto;
    width: auto;
    max-width: min(280px, calc(100vw - var(--rail-w) - 24px));
    padding: 8px;
    background: rgba(16, 16, 16, .92);
    backdrop-filter: blur(18px) saturate(150%);
    -webkit-backdrop-filter: blur(18px) saturate(150%);
    border: 1px solid rgba(255,255,255,.1);
    border-radius: 16px;
    box-shadow: 0 12px 32px rgba(0,0,0,.5);
    transform: translateX(8px) scale(.96);
    transform-origin: top right;
    transition: transform .22s cubic-bezier(.16,1,.3,1), opacity .18s;
    opacity: 0;
}
.rail-drawer--menu.rail-popover.is-open .rail-drawer__inner,
.rail-drawer--menu.rail-popover.is-open .rail-popover__inner {
    transform: translateX(0) scale(1);
    opacity: 1;
}
/* Десктоп: подтянуть popover к правому краю колонки */
@media (min-width: 600px) {
    .rail-drawer--menu.rail-popover .rail-drawer__inner,
    .rail-popover__inner {
        right: calc(var(--col-right, 0px) + var(--rail-w-desk) + 8px);
    }
}

.rail-popover .rail-menu-nav { margin: 0; }

.rail-popover .rail-menu-list {
    list-style: none;
    margin: 0; padding: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.rail-popover .rail-menu-list li a {
    display: block;
    font-family: var(--font-body);
    font-size: .92rem;
    font-weight: 600;
    letter-spacing: .04em;
    color: var(--accent);
    background: rgba(230,48,48,.10);
    border: 1px solid rgba(230,48,48,.3);
    border-radius: 999px;
    padding: 8px 16px;
    text-decoration: none;
    transition: background .18s, border-color .18s, transform .15s, color .18s;
    text-align: center;
    white-space: nowrap;
}
.rail-popover .rail-menu-list li a:hover {
    background: rgba(230,48,48,.22);
    border-color: rgba(230,48,48,.5);
    color: #fff;
}
.rail-popover .rail-menu-list li a:active { transform: scale(.96); }

/* Текущий пункт меню (.current-menu-item от WP) — залит акцентом */
.rail-popover .rail-menu-list li.current-menu-item a,
.rail-popover .rail-menu-list li.current-menu-ancestor a {
    background: var(--accent);
    color: #fff;
    border-color: var(--accent);
}

/* ════════════════════════════════════════════════════════════════════════
   Контент НЕ сдвигается — rail лежит оверлеем.
   Но мелкие inline-элементы внизу карточки (.reel-info, .hero-content)
   чуть прижимаем к левому краю, чтобы не перекрываться кнопками.
   ════════════════════════════════════════════════════════════════════════ */
.reel-feed,
.single-reel {
    padding-right: 0;
}
.reel-slide .reel-info {
    padding-right: calc(var(--rail-w) + 4px);
}
@media (min-width: 600px) {
    .reel-slide .reel-info { padding-right: calc(var(--rail-w-desk) + 6px); }
}
/* Hero-текст в single-posts — то же */
.single-slide--hero .hero-content {
    padding-right: calc(var(--rail-w) + 4px);
}
@media (min-width: 600px) {
    .single-slide--hero .hero-content { padding-right: calc(var(--rail-w-desk) + 6px); }
}
/* Exit-слайд центрирован — никаких отступов не нужно, контент сам узкий */

/* Тоаст и scroll-hint центрируем по «видимой» части (без rail) */
.paushu-toast,
.reel-scroll-hint {
    left: calc(50% - var(--rail-w) / 2);
}
@media (min-width: 600px) {
    .paushu-toast,
    .reel-scroll-hint {
        left: calc(50% - var(--rail-w-desk) / 2);
    }
}

/* Rail и drawer прижаты к правому краю колонки 9:16 на десктопе */
@media (min-width: 600px) {
    :root { --col-right: calc(50vw - var(--phone-w) / 2); }
    .paushu-rail { right: var(--col-right); }
    .rail-drawer__inner {
        right: calc(var(--col-right) + var(--rail-w-desk));
        max-width: calc(var(--phone-w) - var(--rail-w-desk));
    }
    .paushu-toast,
    .reel-scroll-hint {
        left: calc(var(--col-left) + (var(--phone-w) - var(--rail-w-desk)) / 2);
    }
}

/* Узкие мобильные — ужимаем rail чтобы не доминировал */
@media (max-width: 360px) {
    :root {
        --rail-w: 50px;
        --rail-btn-size: 40px;
    }
    .rail-btn svg { width: 18px; height: 18px; }
}

/* Accessibility helper */
.screen-reader-text {
    position: absolute;
    width: 1px; height: 1px;
    padding: 0; margin: -1px;
    overflow: hidden; clip: rect(0,0,0,0);
    white-space: nowrap; border: 0;
}

/* ════════════════════════════════════════════════════════════════════════
   CYCLE DIVIDER — финальный слайд «вы досмотрели ленту»
   ════════════════════════════════════════════════════════════════════════ */
.reel-cycle-divider {
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(180deg, var(--bg) 0%, #151012 100%);
    position: relative;
}

.cycle-inner {
    max-width: 280px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
    padding: 0 20px;
    padding-right: calc(var(--rail-w) + 20px); /* не под rail */
}
@media (min-width: 600px) {
    .cycle-inner { padding-right: calc(var(--rail-w-desk) + 24px); }
}

.cycle-icon {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: rgba(255,255,255,.06);
    border: 1px solid rgba(255,255,255,.12);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 34px;
    color: var(--accent);
    margin-bottom: 4px;
    animation: cycle-arrow-bounce 1.6s ease-in-out infinite;
}

@keyframes cycle-arrow-bounce {
    0%, 100% { transform: translateY(0); }
    50%      { transform: translateY(-6px); }
}

.cycle-text {
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text);
    line-height: 1.25;
    letter-spacing: .01em;
}

.cycle-sub {
    font-size: .85rem;
    color: var(--muted);
    line-height: 1.4;
    letter-spacing: .02em;
}

.cycle-back-btn {
    margin-top: 8px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--accent);
    color: #fff;
    border: 0;
    padding: 12px 28px;
    border-radius: 28px;
    font-weight: 600;
    font-size: .9rem;
    letter-spacing: .04em;
    font-family: var(--font-body);
    cursor: pointer;
    transition: background .2s, transform .15s;
    -webkit-tap-highlight-color: transparent;
}
.cycle-back-btn:hover  { background: #c42020; }
.cycle-back-btn:active { transform: scale(.96); }

/* ════════════════════════════════════════════════════════════════════════
   PINNED категория/метка на страницах архива
   Та же стилистика что .reel-cat (пилула с полупрозрачным акцентом),
   но крупнее и прижата к верху экрана, поверх слайдов.
   ════════════════════════════════════════════════════════════════════════ */
.reel-pin {
    position: fixed;
    top: calc(var(--safe-top) + 14px);
    left: 50%;
    transform: translateX(-50%);
    z-index: 90;              /* ниже rail (95), но выше overlay-ов слайда */
    display: inline-flex;
    align-items: baseline;
    gap: 4px;
    max-width: calc(100vw - var(--rail-w) - 32px);
    padding: 8px 18px;
    font-family: var(--font-body);
    font-size: .82rem;
    font-weight: 700;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: var(--accent);
    background: rgba(230, 48, 48, .14);
    border: 1px solid rgba(230, 48, 48, .45);
    border-radius: 999px;
    backdrop-filter: blur(14px) saturate(140%);
    -webkit-backdrop-filter: blur(14px) saturate(140%);
    box-shadow: 0 4px 18px rgba(0,0,0,.35);
    text-decoration: none;
    transition: background .18s, border-color .18s, transform .15s;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.reel-pin:hover {
    background: rgba(230, 48, 48, .22);
    border-color: rgba(230, 48, 48, .6);
}
.reel-pin:active { transform: translateX(-50%) scale(.97); }

.reel-pin-prefix {
    font-weight: 700;
    opacity: .8;
}
.reel-pin-label { letter-spacing: .08em; }

/* На десктопе центрируем по колонке, с учётом rail */
@media (min-width: 600px) {
    .reel-pin {
        left: calc(var(--col-left) + (var(--phone-w) - var(--rail-w-desk)) / 2);
        transform: translateX(-50%);
        max-width: calc(var(--phone-w) - var(--rail-w-desk) - 32px);
    }
    .reel-pin:active { transform: translateX(-50%) scale(.97); }
}

/* На совсем узких — чуть компактнее */
@media (max-width: 360px) {
    .reel-pin {
        font-size: .75rem;
        padding: 6px 14px;
        letter-spacing: .08em;
    }
}

/* .rail-menu-list--nav / .rail-menu-special / .rail-menu-ico удалены —
   кнопки «Домой» и «Назад» переехали из меню прямо в rail. */

/* ════════════════════════════════════════════════════════════════════════
   UI HIDE — при классе body.ui-hidden прячем rail и все подписи
   (заголовок/рубрика/дата внизу, pin сверху). Контент (картинки/видео)
   остаётся виден. Повторный тап возвращает.
   ════════════════════════════════════════════════════════════════════════ */
/* ════════════════════════════════════════════════════════════════════════
   CAPTURE MODE — при создании скриншота текущего слайда (share feature)
   прячем весь UI мгновенно (без transition) чтобы html2canvas снял
   чистый контент. Режим включается на ~1 сек пока идёт рендер.
   ════════════════════════════════════════════════════════════════════════ */
body.is-capturing .paushu-rail,
body.is-capturing .reel-pin,
body.is-capturing .paushu-progress,
body.is-capturing .gallery-page-indicator,
body.is-capturing .slide-next-peek,
body.is-capturing .reel-scroll-hint,
body.is-capturing .paushu-toast {
    opacity: 0 !important;
    visibility: hidden !important;
    transition: none !important;
}

body.ui-hidden .paushu-rail,
body.ui-hidden .reel-pin,
body.ui-hidden .reel-info,
body.ui-hidden .hero-content,
body.ui-hidden .block-actions,
body.ui-hidden .slide-next-peek,
body.ui-hidden .reel-scroll-hint {
    opacity: 0;
    pointer-events: none;
    transition: opacity .25s ease;
}

/* Обратный переход — появление */
.paushu-rail,
.reel-pin,
.reel-info,
.hero-content,
.block-actions,
.slide-next-peek,
.reel-scroll-hint {
    transition: opacity .25s ease;
}

/* Чтобы тап был приятнее — меняем курсор на указатель в пустом месте слайда */
.reel-slide,
.single-slide {
    cursor: pointer;
}
/* Но на интерактивных — default курсор */
.reel-slide a, .reel-slide button,
.single-slide a, .single-slide button,
.paushu-rail, .paushu-rail * {
    cursor: auto;
}
.rail-btn, .reel-pin, .reel-cat, .rail-menu-list a {
    cursor: pointer;
}

/* ════════════════════════════════════════════════════════════════════════
   GALLERY MODE — горизонтальный свайп переключает reel в галерею 3×3.
   Слайды группируются в страницы по 9 через JS (.gallery-page).
   Страницы листаются вертикальным scroll-snap.
   ════════════════════════════════════════════════════════════════════════ */

/* Rail и pin прячем в галерее */
body.galleries-mode .paushu-rail,
body.galleries-mode .reel-pin {
    opacity: 0;
    pointer-events: none;
    transition: opacity .2s ease;
}

/* ── Общий контейнер галереи (feed или single-reel) ────────── */
.reel-feed.galleries-mode,
.single-reel.galleries-mode {
    display: flex !important;
    flex-direction: column;
    gap: 0;
    height: var(--paushu-vh, 100dvh);
    /* В галерее снова разрешаем скролл (в feed-режиме overflow:hidden
       и index-based transform). */
    overflow-y: auto !important;
    overflow-x: hidden !important;
    scroll-snap-type: y mandatory;
    scrollbar-width: none;
    background: var(--bg);
}
.reel-feed.galleries-mode::-webkit-scrollbar,
.single-reel.galleries-mode::-webkit-scrollbar { display: none; }

/* ── Страница галереи (ровно 9 тайлов) ──────────────────────── */
.gallery-page {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: repeat(3, 1fr);
    gap: 4px;
    padding: calc(var(--safe-top) + 8px) 8px calc(var(--safe-bottom) + 8px);
    height: var(--paushu-vh, 100dvh);
    min-height: var(--paushu-vh, 100dvh);
    flex: 0 0 var(--paushu-vh, 100dvh);
    scroll-snap-align: start;
    scroll-snap-stop: always;
    align-content: stretch;
    justify-content: stretch;
    box-sizing: border-box;
}

/* Пагинатор — мелкие точки внизу страницы */
.gallery-page-indicator {
    position: fixed;
    bottom: calc(var(--safe-bottom) + 12px);
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 6px;
    z-index: 97;
    pointer-events: none;
    transition: opacity .2s;
}
body:not(.galleries-mode) .gallery-page-indicator { opacity: 0; }
.gallery-page-indicator .dot {
    width: 5px; height: 5px;
    border-radius: 50%;
    background: rgba(255,255,255,.35);
    transition: background .2s, transform .2s;
}
.gallery-page-indicator .dot.is-active {
    background: var(--accent);
    transform: scale(1.4);
}

/* ── Тайл в галерее (и для .reel-slide, и для .single-slide) ── */
.gallery-page .reel-slide,
.gallery-page .single-slide {
    height: auto !important;
    aspect-ratio: auto;
    width: 100%;
    scroll-snap-align: none;
    overflow: hidden;
    border-radius: 8px;
    display: block !important;
    position: relative !important;
    left: auto !important;
    top: auto !important;
    /* Сбрасываем transform из feed-режима (translateY по индексу) —
       в галерее слайды лежат в гриде, не абсолютно. */
    transform: none !important;
    transition: transform .15s;
    cursor: pointer;
    background: var(--surface);
    min-height: 0; /* grid-child must shrink */
}
.gallery-page .reel-slide:active,
.gallery-page .single-slide:active {
    transform: scale(.96);
}

/* Медиа заполняет весь тайл */
.gallery-page .reel-media {
    position: absolute;
    inset: 0;
}
.gallery-page .reel-video,
.gallery-page .reel-img,
.gallery-page .reel-thumb-placeholder {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.gallery-page .reel-no-media {
    width: 100%; height: 100%;
    background: linear-gradient(135deg, var(--surface) 0%, #1e1e1e 100%);
}

/* reel-info — узкий overlay снизу */
.gallery-page .reel-info {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    padding: 6px 8px !important;
    background: linear-gradient(to top, rgba(0,0,0,.88) 0%, transparent 100%);
    pointer-events: none;
    gap: 2px;
    margin-top: 0;
}
.gallery-page .reel-title {
    font-size: .65rem;
    line-height: 1.25;
    text-shadow: 0 1px 3px rgba(0,0,0,.9);
    /* без line-clamp — показываем заголовок целиком */
}
.gallery-page .reel-title a {
    color: #fff;
    text-decoration: none;
    pointer-events: none;
}
.gallery-page .reel-cat,
.gallery-page .reel-excerpt,
.gallery-page .reel-meta,
.gallery-page .reel-overlay {
    display: none;
}

/* Лоадер и cycle-divider в галерее не нужны — они не попадут в страницы */
.gallery-page .reel-loader,
.gallery-page .reel-cycle-divider { display: none; }

/* ── Hero-слайд single-поста в галерее ──────────────────────── */
.gallery-page .single-slide--hero .hero-image-wrap {
    position: absolute;
    inset: 0;
}
.gallery-page .single-slide--hero .hero-img {
    width: 100%; height: 100%;
    object-fit: cover;
}
.gallery-page .single-slide--hero .hero-content {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    padding: 6px 8px !important;
    background: linear-gradient(to top, rgba(0,0,0,.88) 0%, transparent 100%);
    pointer-events: none;
}
.gallery-page .single-slide--hero .hero-title {
    font-size: .7rem !important;
    line-height: 1.2;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin: 0;
}
.gallery-page .single-slide--hero .slide-cat,
.gallery-page .single-slide--hero .hero-taxonomy,
.gallery-page .single-slide--hero .hero-meta,
.gallery-page .single-slide--hero .hero-hint,
.gallery-page .single-slide--hero .hero-img-overlay {
    display: none;
}

/* ── Block-тайл: мини-превью HTML ────────────────────────── */
.gallery-page .single-slide--block {
    background: var(--bg);
    border: 1px solid rgba(255,255,255,.08);
}
.gallery-page .single-slide--block .slide-inner {
    overflow: hidden;
    height: 100%;
}
.gallery-page .slide-content {
    font-size: 6px;
    line-height: 1.4;
    padding: 10px;
    color: rgba(255,255,255,.75);
    overflow: hidden;
    max-height: 100%;
}
.gallery-page .slide-content h1,
.gallery-page .slide-content h2,
.gallery-page .slide-content h3,
.gallery-page .slide-content h4 {
    font-size: 8px;
    margin: 0 0 4px;
}
.gallery-page .slide-content p { margin: 0 0 3px; }
.gallery-page .slide-content img {
    max-width: 100%; height: auto; display: block;
    border-radius: 3px; margin: 2px 0;
}

/* Блок с картинкой — картинка на весь тайл */
.gallery-page .single-slide--block[data-block-img]:not([data-block-img=""]) {
    background: #000;
}
.gallery-page .single-slide--block[data-block-img]:not([data-block-img=""]) .slide-content {
    position: absolute;
    inset: 0;
    padding: 0;
}
.gallery-page .single-slide--block[data-block-img]:not([data-block-img=""]) .slide-content img {
    width: 100%; height: 100%;
    object-fit: cover;
    margin: 0;
    border-radius: 0;
}
.gallery-page .single-slide--block[data-block-img]:not([data-block-img=""]) .slide-content p,
.gallery-page .single-slide--block[data-block-img]:not([data-block-img=""]) .slide-content h1,
.gallery-page .single-slide--block[data-block-img]:not([data-block-img=""]) .slide-content h2 {
    display: none;
}

/* Служебные элементы блока прячем */
.gallery-page .slide-bottom-sentinel,
.gallery-page .slide-next-peek,
.gallery-page .block-actions { display: none; }

/* Номер блока в углу тайла */
.gallery-page .single-slide--block::before {
    content: attr(data-index);
    position: absolute;
    top: 4px; right: 6px;
    font-size: 10px;
    font-weight: 700;
    color: rgba(255,255,255,.85);
    background: rgba(0,0,0,.55);
    padding: 2px 6px;
    border-radius: 4px;
    z-index: 2;
    pointer-events: none;
    font-family: var(--font-body);
}

/* Подсветка «текущего» тайла — с которого пришли */
.gallery-page .is-current-tile {
    outline: 2px solid var(--accent);
    outline-offset: -2px;
}

/* Колонка 9:16 на десктопе */
@media (min-width: 600px) {
    .reel-feed.galleries-mode,
    .single-reel.galleries-mode {
        left: var(--col-left);
        width: var(--phone-w);
    }
}

/* ── FAB — выход обратно в reel ─────────────────────────── */
.gallery-toggle-fab {
    display: none;
    position: fixed;
    bottom: calc(var(--safe-bottom) + 20px);
    right: 20px;
    z-index: 99;
    width: 48px; height: 48px;
    border-radius: 50%;
    background: var(--accent);
    border: 0;
    color: #fff;
    cursor: pointer;
    box-shadow: 0 6px 18px rgba(0,0,0,.5);
    align-items: center;
    justify-content: center;
    transition: transform .15s;
}
body.galleries-mode .gallery-toggle-fab {
    display: flex;
    animation: rail-fade-in .25s ease;
}
.gallery-toggle-fab:active { transform: scale(.92); }
.gallery-toggle-fab svg { width: 22px; height: 22px; }

@media (min-width: 600px) {
    .gallery-toggle-fab { right: calc(var(--col-left) + 20px); }
}

/* ════════════════════════════════════════════════════════════════════════
   PINCH ZOOM — плавность трансформации для медиа
   ════════════════════════════════════════════════════════════════════════ */
.reel-video, .reel-img, .slide-content img, .slide-content video {
    transition: transform .15s ease-out;
    transform-origin: center center;
    will-change: transform;
}
/* В зум-режиме — без transition (следим за пальцем в реалтайме) */
.reel-video.is-zoomed, .reel-img.is-zoomed,
.slide-content img.is-zoomed, .slide-content video.is-zoomed {
    transition: none;
    z-index: 10;
    position: relative;
}

.slide-content { transition: font-size .08s ease-out; }

/* ════════════════════════════════════════════════════════════════════════
   Share modal: галерея картинок блока (если больше одной)
   ════════════════════════════════════════════════════════════════════════ */
.psm-block-gallery {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 4px;
    margin-bottom: 12px;
    border-radius: 12px;
    overflow: hidden;
}
.psm-block-gallery img {
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    display: block;
    border-radius: 6px;
    background: var(--surface);
}
/* Две картинки — в 2 колонки, одна — на всю ширину */
.psm-block-gallery:has(img:only-child) { grid-template-columns: 1fr; }
.psm-block-gallery:has(img:nth-child(2):last-child) { grid-template-columns: 1fr 1fr; }

/* ════════════════════════════════════════════════════════════════════════
   Облако тегов в бургер-меню — зелёные пилулы, размер зависит от count
   ════════════════════════════════════════════════════════════════════════ */
.rail-tag-cloud {
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid rgba(255,255,255,.1);
    display: flex;
    flex-wrap: wrap;
    gap: 6px 8px;
    align-items: center;
    line-height: 1.2;
}
.rail-tag {
    display: inline-block;
    color: var(--tag-color);
    background: var(--tag-bg);
    border: 1px solid var(--tag-border);
    border-radius: 999px;
    padding: 3px 10px;
    text-decoration: none;
    font-weight: 500;
    letter-spacing: .01em;
    transition: background .15s, color .15s, border-color .15s, transform .15s;
    white-space: nowrap;
}
.rail-tag:hover {
    background: var(--tag-border);
    transform: translateY(-1px);
}

/* Индикатор загрузки при входе в галерею (догружаем все посты) */
.gallery-loading::after {
    content: '';
    position: fixed;
    inset: 0;
    background: rgba(10,10,10,.55);
    backdrop-filter: blur(4px);
    z-index: 95;
    pointer-events: none;
}
.gallery-loading::before {
    content: '';
    position: fixed;
    top: 50%; left: 50%;
    width: 36px; height: 36px;
    margin: -18px 0 0 -18px;
    border: 3px solid rgba(255,255,255,.15);
    border-top-color: var(--accent);
    border-radius: 50%;
    animation: rail-spin 0.8s linear infinite;
    z-index: 96;
    pointer-events: none;
}
@keyframes rail-spin { to { transform: rotate(360deg); } }

/* ════════════════════════════════════════════════════════════════════════
   TEXT SCALE — глобальный множитель размера шрифта.
   Применяется на <html> через CSS-переменную, все rem-единицы по сайту
   автоматически масштабируются.
   ════════════════════════════════════════════════════════════════════════ */
:root { --text-scale: 1; }
html { font-size: calc(16px * var(--text-scale, 1)); }

/* Раньше был transition: font-size .22s на html — создавал дрожание
   слайдов: пока шрифт анимировался, менялась высота .single-slide
   (rem-единицы), и scroll-snap-mandatory каждый кадр корректировал
   scrollTop к новому snap-point. Убрали — переключение мгновенное.
   Плавность текста внутри контента всё равно есть (см. .slide-content). */

/* Rail-группа text — три кнопки (A− / A / A+) */
.rail-group--text {
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.rail-btn--text-minus,
.rail-btn--text-reset,
.rail-btn--text-plus {
    font-family: var(--font-body);
    font-weight: 700;
    letter-spacing: -0.02em;
}
.rail-text-ico {
    font-size: 14px;
    line-height: 1;
    color: currentColor;
    white-space: nowrap;
    display: inline-block;
}
.rail-text-ico--minus { font-size: 13px; }
.rail-text-ico--plus  { font-size: 15px; }

/* Визуальный индикатор что размер шрифта изменён (не дефолт) */
body.is-text-scaled .rail-btn--text-reset {
    color: var(--accent);
}

/* ════════════════════════════════════════════════════════════════════════
   Коммент-тайлы в галерее single-поста.
   Основные правила — в блоке «мини-превью на манер блок-тайла» ниже.
   Здесь только то, что второй блок не перекрывает — подсказка expand.
   ════════════════════════════════════════════════════════════════════════ */

/* Убираем подсказку "нажмите для разворота" — в галерее не нужна */
.gallery-page .comment-slide::after { content: none !important; }

/* ════════════════════════════════════════════════════════════════════════
   Коммент-тайл в галерее — мини-превью на манер блок-тайла
   ════════════════════════════════════════════════════════════════════════ */
.gallery-page .comment-slide {
    position: relative;
    background: var(--surface);
    border: 1px solid rgba(255,255,255,.08);
    border-radius: 8px;
    overflow: hidden;
    /* Отменяем scroll-snap внутри galleries-mode — тайлы не снэпятся */
    scroll-snap-align: unset;
    height: 100%;
    min-height: 0;
    /* В обычном режиме .comment-slide теперь имеет padding:0 (скролл
       живёт внутри .cslide-inner). В галерее нам padding не нужен —
       сам тайл — карточка. */
    padding: 0;
    /* В галерее инициализация: сам тайл не скроллится, превью заморожено. */
    align-items: stretch;
}
.gallery-page .comment-slide .cslide-inner {
    padding: 10px 8px 22px;
    height: 100%;
    width: 100%;
    max-width: none;             /* В обычном режиме стоит 520px — в тайле не нужно */
    overflow: hidden;            /* тайл — превью, внутренний скролл выкл */
    overscroll-behavior: auto;   /* сбрасываем contain из обычного режима */
    display: flex;
    flex-direction: column;
    justify-content: flex-start; /* иначе из обычного режима наследуется center */
    gap: 4px;
}
.gallery-page .comment-slide .cslide-head {
    gap: 6px;
    margin-bottom: 2px;
}
.gallery-page .comment-slide .cslide-author {
    font-size: 9px;
    font-weight: 600;
    color: #fff;
}
.gallery-page .comment-slide .cslide-date,
.gallery-page .comment-slide .cslide-num {
    font-size: 7px;
    padding: 1px 4px;
}
.gallery-page .comment-slide .cslide-text {
    font-size: 7px;
    line-height: 1.4;
    color: rgba(255,255,255,.7);
    overflow: hidden;
    max-height: none;
    /* РАНЬШЕ: flex: 1 + line-clamp: 4 — ответ оставался, но без flex-базы
       обрезался целиком. Теперь задаём flex-basis через число строк,
       чтобы ответы получили свою долю места. */
    flex: 0 1 auto;
    display: -webkit-box;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
}
.gallery-page .comment-slide .cslide-text p { margin: 0 0 2px; }

/* В галерее скрываем лайки (ответы остаются — нужны в превью) */
.gallery-page .comment-slide .cslide-actions {
    display: none;
}

/* Блок ответов в тайле — компактное продолжение текста */
.gallery-page .comment-slide .cslide-replies {
    margin-top: 4px;
    padding-top: 4px;
    border-top: 1px solid rgba(255,255,255,.08);
}
.gallery-page .comment-slide .cslide-replies-title {
    font-size: 6px;
    margin-bottom: 3px;
    letter-spacing: .04em;
    color: rgba(255,255,255,.4);
}
.gallery-page .comment-slide .cslide-reply {
    margin-bottom: 4px;
    padding-left: 5px;
    border-left-width: 1px;
}
.gallery-page .comment-slide .cslide-reply:last-child { margin-bottom: 0; }
.gallery-page .comment-slide .cslide-reply-head {
    gap: 4px;
    margin-bottom: 2px;
}
.gallery-page .comment-slide .cslide-reply-author {
    font-size: 7px;
    color: rgba(255,255,255,.85);
}
.gallery-page .comment-slide .cslide-reply-date {
    font-size: 6px;
}
.gallery-page .comment-slide .cslide-reply-text {
    font-size: 6.5px;
    line-height: 1.35;
    color: rgba(255,255,255,.65);
    /* обрезаем длинные ответы */
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.gallery-page .comment-slide .cslide-reply-text p { margin: 0 0 1px; }
.gallery-page .comment-slide .cslide-reply .cslide-like { display: none; }

/* Иконка 💬 в углу — отличает коммент-тайл от блок-тайла */
.gallery-page .comment-slide::before {
    content: '💬';
    position: absolute;
    top: 4px; right: 6px;
    font-size: 10px;
    opacity: .7;
    pointer-events: none;
    z-index: 2;
}

/* Пустой state (пока нет комментов) тоже может попасть в галерею */
.gallery-page .comment-slide--empty {
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--muted);
    font-size: 9px;
    text-align: center;
}
.gallery-page .comment-slide--empty .ch-icon { font-size: 20px; }
.gallery-page .comment-slide--empty .ch-count { font-size: 8px; }
