/* Шрифты лежат на своём сервере, а не на Google Fonts: страница не ждёт
   чужой сервер перед первой отрисовкой и открывается без интернета наружу.
   Golos Text — шрифт панели, Manrope — шрифт приложения, им рисуется макет
   телефона. Файлы урезаны до латиницы и кириллицы (обе гарнитуры — OFL). */

@font-face { font-family: 'Golos Text'; font-style: normal; font-weight: 400; font-display: swap; src: url(fonts/golos-400.woff) format('woff'); }
@font-face { font-family: 'Golos Text'; font-style: normal; font-weight: 500; font-display: swap; src: url(fonts/golos-500.woff) format('woff'); }
@font-face { font-family: 'Golos Text'; font-style: normal; font-weight: 600; font-display: swap; src: url(fonts/golos-600.woff) format('woff'); }
@font-face { font-family: 'Golos Text'; font-style: normal; font-weight: 700; font-display: swap; src: url(fonts/golos-700.woff) format('woff'); }
@font-face { font-family: 'Golos Text'; font-style: normal; font-weight: 800; font-display: swap; src: url(fonts/golos-800.woff) format('woff'); }

@font-face { font-family: 'Manrope'; font-style: normal; font-weight: 400; font-display: swap; src: url(fonts/manrope-400.woff) format('woff'); }
@font-face { font-family: 'Manrope'; font-style: normal; font-weight: 500; font-display: swap; src: url(fonts/manrope-500.woff) format('woff'); }
@font-face { font-family: 'Manrope'; font-style: normal; font-weight: 600; font-display: swap; src: url(fonts/manrope-600.woff) format('woff'); }
@font-face { font-family: 'Manrope'; font-style: normal; font-weight: 700; font-display: swap; src: url(fonts/manrope-700.woff) format('woff'); }
@font-face { font-family: 'Manrope'; font-style: normal; font-weight: 800; font-display: swap; src: url(fonts/manrope-800.woff) format('woff'); }
/* Оформление панели перенесено с шаблона Duralux: белая навигация слева,
   фиксированная шапка, карточки с мягкой тенью, светлая и тёмная темы.
   Здесь нет ни сборщика, ни фреймворка — только переменные и обычный CSS.

   Названия переменных остались прежними (--ink, --line, --alt и так далее):
   на них опираются extra.css и публичные страницы, и менять их значило бы
   переписать заодно и их. Тёмная тема — те же переменные с другими значениями. */

:root {
  /* поверхности */
  --page: #f0f2f8;
  --bg: #ffffff;
  --alt: #eff0f6;
  --hover: #eaebef;
  --line: #e5e7eb;
  --line-2: #dcdee4;

  /* текст */
  --ink: #283c50;
  --ink2: #6b7885;
  --ink3: #91a1b6;

  /* цвета смысла: синий — основной, индиго — выгода, зелёный — «в порядке»,
     красный — сигнальный: ошибки и удаление */
  --primary: #3454d1;
  --primary-dark: #2942ab;
  --primary-soft: rgba(52, 84, 209, .09);
  --accent: #6610f2;
  --accent-soft: rgba(102, 16, 242, .09);
  --ok: #17c666;
  --ok-soft: rgba(23, 198, 102, .1);
  --warn: #e49e3d;
  --warn-soft: rgba(228, 158, 61, .12);
  --red: #ea4d4d;
  --red-soft: rgba(234, 77, 77, .1);

  /* каркас */
  --nav-w: 280px;
  --nav-mini: 88px;
  --header-h: 72px;
  --radius: 10px;
  --radius-sm: 6px;
  --shadow: 0 1px 3px 0 rgb(0 0 0 / .1), 0 1px 2px -1px rgb(0 0 0 / .1);
  --shadow-drop: 0 10px 24px 0 rgba(62, 57, 107, .18);
  --ease: all .15s ease;
}

html.app-skin-dark {
  --page: #121a2d;
  --bg: #0f172a;
  --alt: #1c2438;
  --hover: #1c2438;
  --line: #1b2436;
  --line-2: #222c42;

  --ink: #e9ecf3;
  --ink2: #b1b4c0;
  --ink3: #7d879c;

  --primary: #4b6ae0;
  --primary-dark: #3454d1;
  --primary-soft: rgba(75, 106, 224, .16);
  --accent: #8b5cf6;
  --accent-soft: rgba(139, 92, 246, .16);
  --ok-soft: rgba(23, 198, 102, .14);
  --warn-soft: rgba(228, 158, 61, .16);
  --red-soft: rgba(234, 77, 77, .16);

  --shadow: 0 1px 3px 0 rgb(0 0 0 / .4);
  --shadow-drop: 0 0 20px rgb(0 0 0 / 50%);
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: 'Golos Text', Inter, -apple-system, 'Segoe UI', Roboto, sans-serif;
  font-size: 13.5px;
  line-height: 1.6;
  color: var(--ink2);
  background: var(--page);
  -webkit-font-smoothing: antialiased;
  transition: background-color .3s ease, color .3s ease;
}

a { color: var(--ink); text-decoration: none; transition: var(--ease); }
a:hover { color: var(--primary); }
h1, h2, h3, h4, h5, h6 { margin: 0; color: var(--ink); letter-spacing: -0.2px; }
b, strong { color: var(--ink); }
.muted { color: var(--ink2); }
.muted-xs { color: var(--ink3); font-size: 11.5px; }
.strong { font-weight: 600; color: var(--ink); }
code { background: var(--alt); border-radius: 4px; padding: 2px 6px; font-size: 12.5px; }

.ic { width: 18px; height: 18px; flex: 0 0 auto; }

::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--line-2); border-radius: 6px; }
::-webkit-scrollbar-thumb:hover { background: var(--ink3); }

/* ---------------------------------------------------------- навигация слева */

.nxl-navigation {
  position: fixed;
  top: 0; bottom: 0; left: 0;
  z-index: 1026;
  width: var(--nav-w);
  background: var(--bg);
  border-right: 1px solid var(--line);
  transition: width .3s ease, transform .3s ease;
  display: flex;
  flex-direction: column;
}

.nxl-navigation .m-header {
  height: var(--header-h);
  display: flex;
  align-items: center;
  padding: 0 22px;
  border-bottom: 1px solid var(--line);
  overflow: hidden;
}
.b-brand { display: flex; align-items: center; gap: 12px; color: var(--ink); }
.logo-mark { color: var(--ink); flex: 0 0 38px; line-height: 0; }
.logo-mark svg { width: 38px; height: 38px; display: block; }
.logo-text {
  font-size: 14px; font-weight: 800; letter-spacing: .4px; white-space: nowrap;
  text-transform: uppercase;
}
.logo-text small {
  display: block; font-size: 10.5px; font-weight: 600; letter-spacing: .6px;
  text-transform: none; color: var(--ink3); margin-top: 1px;
}

.navbar-content {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 12px 0 20px;
}
.nxl-navbar { list-style: none; margin: 0; padding: 0; }

.nxl-caption {
  display: block;
  color: var(--ink3);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .07em;
  text-transform: uppercase;
  padding: 16px 22px 8px;
  white-space: nowrap;
}

.nxl-link {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 3px 15px;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  color: var(--ink);
  font-size: 13px;
  font-weight: 600;
  line-height: 1.2;
  transition: var(--ease);
  white-space: nowrap;
}
.nxl-micon { display: flex; color: var(--ink2); transition: var(--ease); }
.nxl-micon .ic { width: 19px; height: 19px; }
.nxl-mtext { flex: 1; overflow: hidden; text-overflow: ellipsis; }
.nxl-badge {
  background: var(--red);
  color: #fff;
  font-size: 10.5px;
  font-weight: 700;
  padding: 1px 7px;
  border-radius: 20px;
}
.nxl-item:hover > .nxl-link { background: var(--hover); color: var(--ink); }
.nxl-item:hover > .nxl-link .nxl-micon { color: var(--ink); }
.nxl-item.active > .nxl-link {
  background: var(--primary);
  color: #fff;
  box-shadow: 0 6px 12px -4px rgba(52, 84, 209, .45);
}
.nxl-item.active > .nxl-link .nxl-micon { color: #fff; }
.nxl-item.active .nxl-badge { background: rgba(255, 255, 255, .25); }

.nav-promo {
  margin: 22px 15px 0;
  padding: 16px;
  border-radius: var(--radius);
  background: var(--alt);
  border: 1px solid var(--line);
}
.nav-promo-title { font-size: 12.5px; font-weight: 700; color: var(--ink); }
.nav-promo p { margin: 6px 0 12px; font-size: 12px; color: var(--ink2); line-height: 1.5; }
.nav-promo-link {
  display: inline-flex; align-items: center; gap: 7px;
  font-size: 12px; font-weight: 700; color: var(--primary);
}
.nav-promo-link .ic { width: 14px; height: 14px; }

.nav-overlay {
  display: none;
  position: fixed; inset: 0; z-index: 1025;
  background: rgba(15, 23, 42, .45);
}

/* свёрнутое меню: остаются одни значки, при наведении разворачивается */
html.minimenu .nxl-navigation { width: var(--nav-mini); }
html.minimenu .logo-text,
html.minimenu .nav-promo { display: none; }
html.minimenu .nxl-navigation .m-header { padding: 0; justify-content: center; }
html.minimenu .nxl-link { margin: 3px 16px; padding: 12px; justify-content: center; }
html.minimenu .nxl-mtext,
html.minimenu .nxl-badge { display: none; }
html.minimenu .nxl-caption { padding: 14px 0 6px; text-align: center; font-size: 0; }
html.minimenu .nxl-caption::before { content: "•••"; font-size: 12px; letter-spacing: 2px; }
html.minimenu .nxl-navigation:hover { width: var(--nav-w); box-shadow: var(--shadow-drop); }
html.minimenu .nxl-navigation:hover .logo-text,
html.minimenu .nxl-navigation:hover .nxl-mtext,
html.minimenu .nxl-navigation:hover .nxl-badge { display: block; }
html.minimenu .nxl-navigation:hover .nav-promo { display: block; }
html.minimenu .nxl-navigation:hover .m-header { padding: 0 22px; justify-content: flex-start; }
html.minimenu .nxl-navigation:hover .nxl-link { margin: 3px 15px; padding: 10px 14px; justify-content: flex-start; }
html.minimenu .nxl-navigation:hover .nxl-caption { padding: 16px 22px 8px; text-align: left; font-size: 10px; }
html.minimenu .nxl-navigation:hover .nxl-caption::before { content: none; }

/* ------------------------------------------------------------------- шапка */

.nxl-header {
  position: fixed;
  top: 0; right: 0;
  left: var(--nav-w);
  z-index: 1024;
  min-height: var(--header-h);
  background: var(--bg);
  border-bottom: 1px solid var(--line);
  transition: left .3s ease;
}
html.minimenu .nxl-header { left: var(--nav-mini); }

.header-wrapper {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 0 26px;
  min-height: var(--header-h);
}
.header-left { display: flex; align-items: center; gap: 14px; flex: 1; min-width: 0; }
.header-right { display: flex; align-items: center; gap: 2px; margin-left: auto; }

.nxl-head-link {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 42px; height: 42px;
  border: 0;
  background: none;
  border-radius: 50%;
  color: var(--ink2);
  cursor: pointer;
  transition: var(--ease);
}
.nxl-head-link .ic { width: 20px; height: 20px; }
.nxl-head-link:hover { background: var(--hover); color: var(--primary); }
.nxl-h-badge {
  position: absolute; top: 2px; right: 1px;
  min-width: 17px; height: 17px; padding: 0 4px;
  border-radius: 20px;
  background: var(--red);
  color: #fff;
  font-size: 9.5px; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
}

.nxl-navigation-toggle, .nxl-head-mobile-toggler {
  border: 0; background: none; cursor: pointer; color: var(--ink);
  display: flex; align-items: center; padding: 0;
}
.nxl-navigation-toggle .ic { width: 22px; height: 22px; }
.nxl-head-mobile-toggler { display: none; }

.hamburger { display: block; position: relative; width: 20px; height: 20px; }
.hamburger-inner,
.hamburger-inner::before,
.hamburger-inner::after {
  position: absolute; width: 18px; height: 2px; border-radius: 4px;
  background: var(--ink); transition: transform .15s ease;
}
.hamburger-inner { top: 50%; margin-top: -1px; }
.hamburger-inner::before { content: ""; top: -6px; }
.hamburger-inner::after { content: ""; top: 6px; }
.hamburger.is-active .hamburger-inner { transform: rotate(-180deg); }
.hamburger.is-active .hamburger-inner::before { transform: translate3d(4px, 2px, 0) rotate(45deg) scale(.7, 1); }
.hamburger.is-active .hamburger-inner::after { transform: translate3d(4px, -2px, 0) rotate(-45deg) scale(.7, 1); }

/* переключатель темы: видна одна иконка из двух */
.dark-light-theme .sun,
html.app-skin-dark .dark-light-theme .moon { display: none; }
html.app-skin-dark .dark-light-theme .sun { display: block; }
.full-screen-switcher .minimize,
html.in-fullscreen .full-screen-switcher .maximize { display: none; }
html.in-fullscreen .full-screen-switcher .minimize { display: block; }

/* поиск */
.nxl-header-search { position: relative; flex: 1; max-width: 420px; }
.header-search-form {
  display: flex; align-items: center; gap: 10px;
  height: 40px; padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--alt);
  transition: var(--ease);
}
.nxl-header-search.show .header-search-form,
.header-search-form:focus-within { background: var(--bg); border-color: var(--primary); }
.header-search-icon { display: flex; color: var(--ink3); }
.header-search-form input,
.header-search-form input:focus {
  flex: 1; width: auto; min-width: 0; border: 0; background: none; outline: none; padding: 0;
  box-shadow: none; font-family: inherit; font-size: 13px; color: var(--ink);
}
.header-search-form input::placeholder { color: var(--ink3); }
.header-search-hint {
  font-size: 9.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .5px;
  color: var(--ink3); border: 1px solid var(--line-2); border-radius: 4px; padding: 2px 5px;
}

.search-dropdown {
  position: absolute; top: calc(100% + 10px); left: 0; right: 0;
  display: none;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-drop);
  padding: 8px 0 10px;
  max-height: min(420px, calc(100vh - 120px));
  overflow-y: auto;
  z-index: 1030;
  animation: .35s ease-in-out 0s normal forwards 1 fadein;
}
.nxl-header-search.show .search-dropdown { display: block; }
.search-head {
  padding: 8px 18px 10px; font-size: 10px; font-weight: 700; letter-spacing: .07em;
  text-transform: uppercase; color: var(--ink3);
}
.search-item {
  display: flex; align-items: center; gap: 12px;
  margin: 2px 10px; padding: 9px 12px;
  border-radius: var(--radius-sm);
  font-size: 13px; font-weight: 600; color: var(--ink);
  transition: var(--ease);
}
.search-item:hover { background: var(--hover); color: var(--ink); }
.search-item-icon { display: flex; color: var(--ink2); }
.search-item-arrow { width: 14px; height: 14px; margin-left: auto; color: var(--ink3); }
.search-empty { padding: 14px 22px; font-size: 12.5px; color: var(--ink3); }

/* выпадающие меню шапки */
.nxl-h-item { position: relative; display: flex; align-items: center; }
.dropdown-menu {
  position: absolute; top: calc(100% + 8px); right: 0;
  display: none;
  min-width: 240px;
  padding: 12px 0;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-drop);
  z-index: 1030;
}
.dropdown.show .dropdown-menu { display: block; animation: .35s ease-in-out 0s normal forwards 1 fadein; }
@keyframes fadein {
  from { opacity: 0; transform: translate3d(0, 8px, 0); }
  to { opacity: 1; transform: translate3d(0, 0, 0); }
}
.dropdown-item {
  display: flex; align-items: center; gap: 12px;
  margin: 2px 10px; padding: 9px 14px;
  border-radius: var(--radius-sm);
  color: var(--ink); font-size: 13px; font-weight: 600;
  transition: var(--ease);
}
.dropdown-item:hover { background: var(--hover); color: var(--ink); }
.dropdown-item .ic { color: var(--ink2); }
.dropdown-item.danger, .dropdown-item.danger .ic { color: var(--red); }
.dropdown-item.danger:hover { background: var(--red-soft); }
.dropdown-item.as-switch { cursor: default; justify-content: space-between; }
.dropdown-item.as-switch:hover { background: none; }
.dropdown-item .hstack { display: flex; align-items: center; gap: 12px; }
.dropdown-divider { height: 1px; background: var(--line); margin: 10px 0; }

.nxl-user-dropdown { min-width: 290px; }
.dropdown-header {
  display: flex; align-items: center; gap: 12px;
  padding: 4px 20px 16px; margin-bottom: 8px;
  border-bottom: 1px solid var(--line);
}
.dropdown-header h6 { font-size: 13.5px; font-weight: 700; margin: 0; }

.user-link { width: 42px; height: 42px; }
.user-avtar {
  width: 36px; height: 36px; border-radius: 50%;
  background: var(--primary); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 12.5px; font-weight: 700; letter-spacing: .3px;
}
.user-avtar.lg { width: 44px; height: 44px; font-size: 14px; }

/* переключатель-тумблер */
.switch { position: relative; width: 36px; height: 20px; flex: 0 0 36px; }
.switch input { position: absolute; opacity: 0; pointer-events: none; }
.switch span {
  position: absolute; inset: 0; border-radius: 20px;
  background: var(--line-2); cursor: pointer; transition: var(--ease);
}
.switch span::after {
  content: ""; position: absolute; top: 2px; left: 2px;
  width: 16px; height: 16px; border-radius: 50%; background: #fff;
  transition: var(--ease);
}
.switch input:checked + span { background: var(--primary); }
.switch input:checked + span::after { transform: translateX(16px); }

/* уведомления */
.nxl-notifications-menu { min-width: 330px; padding: 0; }
.notifications-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 20px; border-bottom: 1px solid var(--line);
}
.notifications-head h6 { font-size: 13.5px; font-weight: 700; }
.notifications-body { max-height: 340px; overflow-y: auto; }
.notifications-item {
  display: flex; gap: 14px; align-items: flex-start;
  padding: 14px 20px;
  transition: var(--ease);
}
.notifications-item + .notifications-item { border-top: 1px dashed var(--line); }
.notifications-item:hover { background: var(--alt); }
.notifications-icon {
  width: 36px; height: 36px; flex: 0 0 36px;
  border-radius: var(--radius-sm);
  background: var(--primary-soft); color: var(--primary);
  display: flex; align-items: center; justify-content: center;
}
.notifications-desc { display: block; }
.notifications-title {
  display: flex; align-items: center; gap: 8px;
  font-size: 13px; font-weight: 600; color: var(--ink);
}
.notifications-title b {
  background: var(--red-soft); color: var(--red);
  font-size: 10.5px; padding: 1px 7px; border-radius: 20px;
}
.notifications-note { display: block; font-size: 11.5px; color: var(--ink3); margin-top: 2px; }
.notifications-empty {
  display: flex; align-items: center; gap: 10px;
  padding: 26px 20px; color: var(--ink3); font-size: 12.5px;
}
.notifications-empty .ic { color: var(--ok); }
.notifications-footer {
  padding: 13px 20px; border-top: 1px solid var(--line); text-align: center;
}
.notifications-footer a { font-size: 12.5px; font-weight: 700; color: var(--ink); }

/* ----------------------------------------------------------------- каркас */

.nxl-container {
  position: relative;
  top: var(--header-h);
  margin-left: var(--nav-w);
  min-height: calc(100vh - var(--header-h));
  transition: margin-left .3s ease;
}
html.minimenu .nxl-container { margin-left: var(--nav-mini); }

.page-header {
  position: sticky;
  top: var(--header-h);
  z-index: 1022;
  display: flex;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
  min-height: 66px;
  padding: 12px 26px;
  background: var(--bg);
  border-bottom: 1px solid var(--line);
  box-shadow: var(--shadow);
}
.page-header-left { min-width: 0; }
.page-header h1 { font-size: 18px; font-weight: 700; }
.page-header .breadcrumb {
  list-style: none; display: flex; flex-wrap: wrap; align-items: center; gap: 8px;
  margin: 4px 0 0; padding: 0;
  font-size: 12px; color: var(--ink3);
}
.page-header .breadcrumb li + li::before { content: "/"; margin-right: 8px; color: var(--ink3); }
.page-header .breadcrumb a { color: var(--ink2); font-weight: 600; }
.page-header .breadcrumb a:hover { color: var(--primary); }
.page-header .breadcrumb .sub { color: var(--ink3); }
.page-header-right { display: flex; align-items: center; gap: 8px; margin-left: auto; flex-wrap: wrap; }

.main-content { padding: 26px 26px 10px; }

.footer {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px; flex-wrap: wrap;
  margin: 26px -26px 0;
  padding: 18px 26px;
  border-top: 1px solid var(--line);
  background: var(--bg);
  font-size: 12px; color: var(--ink3);
}

/* Полоса наверху: видна, только если переход между разделами задержался. */
.nav-progress {
  position: fixed; top: 0; left: 0; z-index: 2000;
  height: 2px; width: 0; opacity: 0;
  background: var(--primary);
  box-shadow: 0 0 8px var(--primary);
  pointer-events: none;
}
/* Ход загрузки большого файла под формой: видео и подкасты весят сотни мегабайт. */
.upload-badge { margin-top: 12px; display: grid; gap: 6px; font-size: 13px; color: var(--ink2); }
.upload-badge i { display: block; height: 6px; border-radius: 3px; background: var(--line); overflow: hidden; }
.upload-badge b { display: block; height: 100%; width: 0; background: var(--primary); transition: width .2s ease; }
.nav-progress.run { opacity: 1; width: 80%; transition: width 8s cubic-bezier(.1, .7, .2, 1); }
.nav-progress.run.done { width: 100%; opacity: 0; transition: width .2s ease, opacity .25s ease .1s; }
form.is-sending { opacity: .75; }

/* ---------------------------------------------------------------- карточки */

/* Карточки появляются сразу. Раньше они проявлялись по очереди, и каждый
   переход между разделами ощущался на полсекунды дольше, чем шёл на деле. */
.card, .panel {
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  transition: var(--ease);
}
.panel { margin-bottom: 24px; overflow-x: auto; }
.panel .head {
  display: flex; align-items: center; gap: 12px;
  padding: 16px 24px;
  border-bottom: 1px solid var(--line);
  font-size: 15px; font-weight: 700; color: var(--ink);
}
.panel .body { padding: 24px; }

.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(205px, 1fr));
  gap: 24px;
  margin-bottom: 26px;
}
.card { padding: 22px 24px; }
.card .label {
  font-size: 10px; letter-spacing: .07em; text-transform: uppercase;
  color: var(--ink3); font-weight: 700;
}
.card .value {
  font-size: 26px; font-weight: 700; color: var(--ink);
  letter-spacing: -.6px; margin-top: 6px; font-variant-numeric: tabular-nums;
}
.card .value.red { color: var(--red); }
.card .note { font-size: 12px; color: var(--ink2); margin-top: 2px; }

.stat-card { display: flex; align-items: center; gap: 16px; }
.stat-card:hover { transform: translateY(-2px); box-shadow: 0 10px 20px -8px rgba(40, 60, 80, .25); }
html.app-skin-dark .stat-card:hover { box-shadow: 0 10px 20px -8px rgb(0 0 0 / .6); }
.stat-body { flex: 1; min-width: 0; }
.stat-icon {
  width: 46px; height: 46px; flex: 0 0 46px;
  border-radius: var(--radius);
  display: flex; align-items: center; justify-content: center;
  background: var(--primary-soft); color: var(--primary);
}
.stat-icon .ic { width: 22px; height: 22px; }
.stat-icon.accent { background: var(--accent-soft); color: var(--accent); }
.stat-icon.ok { background: var(--ok-soft); color: var(--ok); }
.stat-icon.warning { background: var(--warn-soft); color: var(--warn); }
.stat-icon.red { background: var(--red-soft); color: var(--red); }
.stat-go { color: var(--ink3); opacity: 0; transform: translateX(-6px); transition: var(--ease); }
.stat-card:hover .stat-go { opacity: 1; transform: none; }

.section {
  display: flex; align-items: baseline; gap: 14px;
  margin: 26px 0 14px;
}
.section h2 { font-size: 16px; font-weight: 700; }
.section .hint { color: var(--ink3); font-size: 12px; }
.section .spacer { flex: 1; }

/* minmax(0, …): колонка не растягивается под широкую таблицу или длинное
   поле — иначе страница вылезала за экран на ноутбуке и телефоне. */
.grid2 { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 24px; align-items: start; }
.grid2 > * { min-width: 0; }
@media (max-width: 1100px) { .grid2 { grid-template-columns: minmax(0, 1fr); } }

/* ---------------------------------------------------------------- таблицы */

table { width: 100%; border-collapse: collapse; }
th {
  text-align: left;
  padding: 11px 16px;
  font-size: 10px;
  letter-spacing: .06em;
  text-transform: uppercase;
  font-weight: 700;
  color: var(--ink);
  background: var(--alt);
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}
th:first-child, td:first-child { padding-left: 24px; }
th:last-child, td:last-child { padding-right: 24px; }
td {
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
  vertical-align: middle;
  color: var(--ink2);
}
tbody tr:last-child td, table tr:last-child td { border-bottom: 0; }
tr:hover td { background: var(--alt); }
td.num, .num { font-variant-numeric: tabular-nums; }
td.num, .nowrap { white-space: nowrap; }
td.right, th.right { text-align: right; }
/* Прошедшее событие: строка остаётся для статистики явки, но уходит в тень. */
tr.is-past > td:not(.checkin) { opacity: .55; }

.avatar {
  width: 38px; height: 38px; border-radius: 50%;
  background: var(--primary); color: #fff;
  object-fit: cover;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 12.5px; font-weight: 700; flex: 0 0 38px;
  border: 1px solid var(--line-2);
}
.avatar.light { background: var(--alt); color: var(--ink); }
.who { display: flex; align-items: center; gap: 12px; min-width: 210px; }
.who .strong { color: var(--ink); }

/* ----------------------------------------------------------------- плашки */

.pill {
  display: inline-block; padding: 4px 8px; border-radius: 4px; white-space: nowrap;
  font-size: 10.5px; font-weight: 700; letter-spacing: .3px;
  background: var(--alt); color: var(--ink);
}
.pill.ok { background: var(--ok-soft); color: var(--ok); }
.pill.red { background: var(--red-soft); color: var(--red); }
.pill.warn { background: var(--warn-soft); color: var(--warn); }
.pill.accent { background: var(--accent-soft); color: var(--accent); }

/* ---------------------------------------------------------------- кнопки */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 38px; padding: 0 16px;
  border: 1px solid var(--primary);
  border-radius: var(--radius-sm);
  background: var(--primary);
  color: #fff;
  font-family: inherit;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .5px;
  text-transform: uppercase;
  cursor: pointer;
  transition: var(--ease);
  white-space: nowrap;
}
.btn:hover { background: var(--primary-dark); border-color: var(--primary-dark); color: #fff; }
.btn .ic { width: 15px; height: 15px; }
.btn-block { width: 100%; }

.btn.ghost {
  background: var(--bg); color: var(--ink); border-color: var(--line-2);
}
.btn.ghost:hover { background: var(--alt); color: var(--ink); border-color: var(--ink3); }
.btn.red { background: var(--red); border-color: var(--red); }
.btn.red:hover { background: #d13b4c; border-color: #d13b4c; }
.btn.sm { height: 31px; padding: 0 11px; font-size: 10px; }
.btn.link {
  border: 0; background: none; color: var(--primary); padding: 0; height: auto;
  text-transform: none; letter-spacing: 0; font-size: 12.5px; font-weight: 700;
}
.btn.link:hover { background: none; color: var(--primary-dark); text-decoration: underline; }
.btn[disabled] { opacity: .45; cursor: not-allowed; }

/* ----------------------------------------------------------------- формы */

label.f { display: block; margin-bottom: 16px; }
label.f .cap,
.cap {
  display: block; font-size: 11px; font-weight: 600;
  color: var(--ink); margin-bottom: 6px;
}
input[type=text], input[type=number], input[type=password], input[type=date],
input[type=time], input[type=email], input[type=search], select, textarea {
  width: 100%;
  font-family: inherit;
  font-size: 13px;
  color: var(--ink);
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 10px 13px;
  transition: var(--ease);
}
input::placeholder, textarea::placeholder { color: var(--ink3); }
input:focus, select:focus, textarea:focus {
  outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-soft);
}
textarea { min-height: 96px; resize: vertical; line-height: 1.55; }
select {
  appearance: none;
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath fill='none' stroke='%2391a1b6' stroke-width='2' d='m2 5 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 10px;
  padding-right: 34px;
  cursor: pointer;
}
/* Компактный список: в строке таблицы, в пагинации. Стрелке — свой отступ,
   иначе она налезает на цифры. */
select.sm {
  width: auto; height: 32px; padding: 0 30px 0 10px;
  font-size: 13px; background-position: right 10px center;
}
/* Статус членства прямо в строке: цвет — как у плашек. */
select.status-active { color: var(--ok); font-weight: 600; }
select.status-suspended { color: var(--warn); font-weight: 600; }
select.status-revoked { color: var(--red); font-weight: 600; }
select.status-graduated { color: var(--ink2); font-weight: 600; }
input[type=checkbox], input[type=radio] { accent-color: var(--primary); width: 15px; height: 15px; }

.row { display: flex; column-gap: 16px; row-gap: 0; flex-wrap: wrap; }
.row > * { flex: 1; min-width: 200px; }
.check { display: flex; align-items: flex-start; gap: 10px; font-size: 13px; margin-bottom: 14px; }
.check input { margin-top: 3px; }

.filters {
  display: flex; gap: 10px; align-items: center; flex-wrap: wrap;
  padding: 16px 20px;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.filters select, .filters input { width: auto; min-width: 180px; }
.filters input[type=text], .filters input[type=search] { flex: 1 1 260px; }
/* тот же набор фильтров внутри панели — уже не карточка, а её первая полоса */
.panel > .filters { border: 0; border-bottom: 1px solid var(--line); border-radius: 0; box-shadow: none; }

/* Поиск студентов: широкое поле с лупой, дальше фильтры с числами. */
.finder-q {
  flex: 1 1 100%; display: flex; align-items: center; gap: 10px;
  padding: 0 14px; border: 1px solid var(--line-2); border-radius: var(--radius);
  background: var(--bg); transition: var(--ease);
}
.finder-q:focus-within { border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-soft); }
.finder-q svg { width: 18px; height: 18px; flex: 0 0 18px; color: var(--ink3); }
.filters .finder-q input {
  flex: 1; min-width: 0; border: 0; box-shadow: none; background: transparent;
  padding: 12px 0; font-size: 14px;
}
.filters .finder-q input:focus { outline: none; box-shadow: none; }
.f-day { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--ink2); }
.filters .f-day input { min-width: 0; width: 150px; }
.f-quick { display: flex; gap: 6px; flex-wrap: wrap; }
.fchip {
  display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 20px;
  font-size: 12.5px; font-weight: 600; color: var(--ink2); background: var(--alt);
  white-space: nowrap; transition: var(--ease);
}
.fchip:hover { color: var(--ink); background: var(--hover); }
.fchip.on { color: var(--primary); background: var(--primary-soft); }
.fchip.x i { font-style: normal; font-size: 15px; line-height: 1; opacity: .7; }
.fchip.x:hover i { opacity: 1; }
.f-active { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-top: 12px; }
.f-reset { font-size: 12.5px; font-weight: 600; color: var(--ink3); margin-left: 4px; }
.f-reset:hover { color: var(--red); }
mark { background: rgba(228, 158, 61, .3); color: inherit; border-radius: 3px; padding: 0 1px; }
.app-skin-dark mark { background: rgba(228, 158, 61, .35); }
.day-row td {
  background: var(--alt); color: var(--ink2); font-size: 11.5px; font-weight: 700;
  letter-spacing: .4px; text-transform: uppercase; padding-top: 8px; padding-bottom: 8px;
}
a.plain { color: inherit; }
a.plain:hover { color: var(--primary); }

.tabs {
  display: flex; gap: 24px; flex-wrap: wrap;
  border-bottom: 1px solid var(--line);
  margin-bottom: 20px;
}
.tabs a {
  padding: 11px 0; font-size: 13px; font-weight: 600; color: var(--ink2);
  border-bottom: 2px solid transparent; margin-bottom: -1px; transition: var(--ease);
}
.tabs a:hover { color: var(--ink); }
.tabs a.on { color: var(--primary); border-bottom-color: var(--primary); }

.bar { height: 8px; background: var(--alt); border-radius: 20px; overflow: hidden; }
.bar > i { display: block; height: 100%; background: var(--primary); border-radius: 20px; }

.empty { padding: 46px 0; text-align: center; color: var(--ink3); font-size: 13px; }

.flash {
  display: flex; align-items: center; gap: 10px;
  background: var(--ok-soft); color: var(--ok);
  border: 1px dashed rgba(23, 198, 102, .45);
  padding: 12px 18px;
  font-size: 13px; font-weight: 600;
  margin-bottom: 22px;
  border-radius: var(--radius-sm);
}
.flash > span { flex: 1; min-width: 0; }
.flash > .ic { flex: 0 0 18px; }
.flash.red { background: var(--red-soft); color: var(--red); border-color: rgba(234, 77, 77, .45); }
.flash.warn { background: var(--warn-soft); color: #9a6212; border-color: rgba(228, 158, 61, .5); }
html.app-skin-dark .flash.warn { color: var(--warn); }
.flash code { background: rgba(255, 255, 255, .6); }

/* ------------------------------------------------------------------- вход */

.auth { display: grid; grid-template-columns: 1.1fr 1fr; min-height: 100vh; background: var(--bg); }
.auth-promo {
  display: flex; align-items: center; justify-content: center;
  padding: 60px;
  background: linear-gradient(135deg, #0f172a 0%, #23325c 55%, #3454d1 100%);
  color: #fff;
}
.auth-promo-inner { max-width: 440px; }
.auth-logo {
  font-size: 13px; font-weight: 800; letter-spacing: 2px; text-transform: uppercase;
  opacity: .75; margin-bottom: 26px;
}
.auth-promo h2 { color: #fff; font-size: 32px; font-weight: 800; line-height: 1.15; }
.auth-promo p { color: rgba(255, 255, 255, .72); font-size: 14px; margin: 16px 0 28px; }
.auth-points { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.auth-points li { display: flex; align-items: center; gap: 12px; font-size: 13.5px; color: rgba(255, 255, 255, .9); }
.auth-points .ic { color: #6ee7a8; }

.auth-form { display: grid; place-items: center; padding: 40px 24px; }
.auth-box { width: 100%; max-width: 380px; }
.auth-box h1 { font-size: 26px; font-weight: 800; }
.auth-sub { color: var(--ink2); font-size: 13px; margin: 6px 0 26px; }
.auth-box .hint { margin-top: 20px; font-size: 12px; color: var(--ink3); line-height: 1.6; }

@media (max-width: 900px) { .auth { grid-template-columns: 1fr; } .auth-promo { display: none; } }

/* ------------------------------------------- страница проверки профбилета */

.verify { min-height: 100vh; display: grid; place-items: center; padding: 24px; background: var(--page); }
.verify .res {
  width: 100%; max-width: 440px; text-align: center;
  background: var(--bg); border: 1px solid var(--line); border-radius: 16px;
  box-shadow: var(--shadow); padding: 30px 26px;
}
.verify .big { font-size: 27px; font-weight: 800; letter-spacing: -.5px; margin: 18px 0 6px; color: var(--ink); }
.verify .big.ok { color: var(--ok); }
.verify .big.no { color: var(--red); }
.verify .face { width: 188px; height: 188px; border-radius: 18px; margin: 0 auto; object-fit: cover; }
@media (max-width: 420px) { .verify .face { width: 68vw; height: 68vw; max-width: 260px; max-height: 260px; } }
.verify .disc { font-size: 58px; font-weight: 800; color: var(--accent); letter-spacing: -3px; line-height: 1; margin: 22px 0 6px; }
.verify dl { text-align: left; border-top: 1px solid var(--line); margin-top: 24px; }
.verify dt { font-size: 10px; letter-spacing: .06em; text-transform: uppercase; color: var(--ink3); font-weight: 700; padding-top: 14px; }
.verify dd { margin: 3px 0 14px; font-weight: 600; color: var(--ink); border-bottom: 1px solid var(--line); padding-bottom: 14px; }

/* ------------------------------------------------------------- адаптивность */

@media (max-width: 1024px) {
  .nxl-navigation { transform: translateX(-100%); }
  html.nav-open .nxl-navigation { transform: none; box-shadow: var(--shadow-drop); }
  html.nav-open .nav-overlay { display: block; }
  .nxl-header, html.minimenu .nxl-header { left: 0; }
  .nxl-container, html.minimenu .nxl-container { margin-left: 0; }
  .nxl-head-mobile-toggler { display: flex; }
  .nxl-navigation-toggle { display: none; }
  html.minimenu .nxl-navigation { width: var(--nav-w); }
  html.minimenu .logo-text, html.minimenu .nxl-mtext,
  html.minimenu .nxl-badge, html.minimenu .nav-promo { display: block; }
  html.minimenu .nxl-link { margin: 3px 15px; padding: 10px 14px; justify-content: flex-start; }
  html.minimenu .nxl-caption { padding: 16px 22px 8px; text-align: left; font-size: 10px; }
  html.minimenu .nxl-caption::before { content: none; }
  html.minimenu .nxl-navigation .m-header { padding: 0 22px; justify-content: flex-start; }
}

@media (max-width: 768px) {
  .header-wrapper { padding: 0 16px; gap: 10px; }
  .nxl-header-search { display: none; }
  .full-screen-switcher { display: none; }
  .main-content { padding: 18px 16px 10px; }
  .page-header { padding: 12px 16px; position: static; }
  .footer { margin: 20px -16px 0; padding: 16px; }
  th:first-child, td:first-child { padding-left: 16px; }
  th:last-child, td:last-child { padding-right: 16px; }
  .panel { overflow-x: auto; }
  .dropdown-menu { position: fixed; top: var(--header-h); left: 10px; right: 10px; }
  .filters > * { flex: 1 1 100%; }
  .filters select, .filters input { width: 100%; min-width: 0; }
  .filters .f-day input { width: 100%; }
  .f-day { flex: 1 1 calc(50% - 5px) !important; }
  .page-header .breadcrumb .sub { display: none; }
  .cards { gap: 14px; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
  .card { padding: 16px; }
}

@media print {
  .nxl-navigation, .nxl-header, .page-header-right, .footer, .nav-overlay { display: none; }
  .nxl-container { top: 0; margin: 0; }
  .main-content { padding: 0; }
  .card, .panel { box-shadow: none; animation: none; }
}

/* Узкий экран: широкая таблица листается внутри своей карточки, а не тянет страницу. */
@media (max-width: 760px) {
  .panel > table { display: block; overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .tabs { overflow-x: auto; flex-wrap: nowrap; scrollbar-width: none; }
  .tabs a { white-space: nowrap; }
  form.filters { flex-wrap: wrap; }
  form.filters > * { min-width: 0; max-width: 100%; }
}
/* Элементы, добавленные во вторую версию панели:
   загрузка файлов, пагинация, галерея, карточка студента, переписка. */

/* --------------------------------------------------------------- пагинация */

.pager {
  display: flex; align-items: center; gap: 14px; flex-wrap: wrap;
  padding: 14px 2px 0; font-size: 13.5px; color: var(--ink2);
}
/* Пагинация внутри карточки со списком — её нижняя полоса. */
.panel > .pager { padding: 12px 24px; border-top: 1px solid var(--line); }
.pager .spacer { flex: 1; }
.pg-per { display: flex; align-items: center; gap: 8px; }
.pg-per select { width: auto; height: 32px; padding: 0 30px 0 11px; font-size: 13.5px; background-position: right 10px center; }
.pg-info { font-variant-numeric: tabular-nums; }
.pg-btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 32px; height: 32px; padding: 0 9px; margin-left: 4px;
  border: 1px solid var(--line); border-radius: 8px;
  font-size: 13px; font-weight: 600; color: var(--ink); background: var(--bg);
}
.pg-btn:hover { background: var(--alt); }
.pg-btn.on { background: var(--primary); border-color: var(--primary); color: #fff; }
.pg-btn.off { color: var(--ink3); background: var(--alt); cursor: default; }

/* ------------------------------------------------------------ загрузка файлов */

.up { margin-bottom: 16px; }
.up .cap {
  display: block; font-size: 10.5px; letter-spacing: 1px; text-transform: uppercase;
  color: var(--ink3); font-weight: 700; margin-bottom: 6px;
}
.up-zone {
  display: flex; align-items: center; gap: 14px;
  padding: 16px 18px; border: 1.5px dashed var(--line); border-radius: 12px;
  background: var(--alt); cursor: pointer; color: var(--ink2);
}
.up-zone:hover, .up-zone.over { border-color: var(--primary); background: var(--bg); color: var(--ink); }
.up-zone svg { width: 26px; height: 26px; flex: 0 0 26px; }
.up-zone input[type=file] { display: none; }
.up-text { font-size: 13.5px; line-height: 1.4; }
.up-text b { display: block; font-size: 14.5px; font-weight: 600; color: var(--ink); }
.up-text i { display: block; font-style: normal; font-size: 12.5px; color: var(--ink3); margin-top: 2px; }
.up-list { margin-top: 10px; display: flex; flex-direction: column; gap: 6px; }
.up-item {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 12px; border: 1px solid var(--line); border-radius: 9px; font-size: 13px;
}
.up-name { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.up-size { color: var(--ink3); font-variant-numeric: tabular-nums; }

/* ----------------------------------------------------------------- галерея */

.gal {
  position: relative; border-radius: 12px; overflow: hidden;
  background: #0f172a; display: flex; align-items: center; justify-content: center;
}
.g-slide { display: none; width: 100%; height: 100%; object-fit: cover; }
.g-slide.on { display: block; }
.g-bars { position: absolute; top: 10px; left: 10px; right: 10px; display: flex; gap: 4px; z-index: 2; }
.g-bars i { flex: 1; height: 3px; border-radius: 2px; background: rgba(255,255,255,.3); }
.g-bars i.on { background: #fff; }
.g-arrow {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 38px; height: 38px; border-radius: 50%; border: 0; cursor: pointer; z-index: 2;
  background: rgba(255,255,255,.9); color: var(--ink); font-size: 24px; line-height: 1;
  display: flex; align-items: center; justify-content: center;
}
.g-arrow:hover { background: #fff; }
.g-arrow.prev { left: 10px; }
.g-arrow.next { right: 10px; }
.g-count {
  position: absolute; right: 12px; bottom: 12px; z-index: 2;
  background: rgba(12,16,14,.7); color: #fff; border-radius: 8px;
  padding: 4px 9px; font-size: 12px; font-variant-numeric: tabular-nums;
}
.preview-text { padding: 16px 2px 2px; }
.preview-text .tag {
  font-size: 10.5px; letter-spacing: 1px; text-transform: uppercase;
  font-weight: 700; color: var(--ok);
}
.preview-text h3 { font-size: 19px; font-weight: 800; margin: 8px 0 6px; }
.preview-text p { margin: 0; color: var(--ink2); font-size: 14px; }

/* ------------------------------------------------------- медиа в списке новости */

.mlist { margin-top: 16px; display: flex; flex-direction: column; gap: 8px; }
.mitem { display: flex; align-items: center; gap: 12px; padding: 8px; border: 1px solid var(--line); border-radius: 10px; }
.mthumb { width: 54px; height: 54px; border-radius: 8px; object-fit: cover; flex: 0 0 54px; background: var(--alt); }
.mthumb.vid {
  display: flex; align-items: center; justify-content: center;
  background: var(--primary); color: #fff; font-size: 11px; font-weight: 700;
}
.mmeta { flex: 1; min-width: 0; }
.mmeta .muted { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mact { display: flex; gap: 4px; }

/* --------------------------------------------------------- карточка студента */

.person { display: flex; gap: 20px; align-items: center; }
.face { width: 108px; height: 108px; border-radius: 16px; object-fit: cover; flex: 0 0 108px; background: var(--alt); }
.person-name { font-size: 22px; font-weight: 800; letter-spacing: -0.4px; }
.person-sub { color: var(--ink2); margin-top: 4px; }
.person-pills { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 12px; }

.kvs { margin: 0; }
.kv { display: flex; gap: 16px; padding: 11px 0; border-bottom: 1px solid var(--line); }
.kv:last-child { border-bottom: 0; }
.kv dt { flex: 0 0 190px; color: var(--ink2); font-size: 14px; margin: 0; }
.kv dd { flex: 1; margin: 0; font-weight: 600; }
.kv .num { font-variant-numeric: tabular-nums; }

/* ---------------------------------------------------------------- переписка */

.chat { display: flex; flex-direction: column; gap: 10px; max-height: 560px; overflow-y: auto; }
.chat.mini { max-height: 260px; }
.msg { max-width: 76%; padding: 10px 13px; border-radius: 14px; font-size: 14px; line-height: 1.45; }
.msg.in { align-self: flex-start; background: var(--alt); border-bottom-left-radius: 5px; }
.msg.out { align-self: flex-end; background: var(--primary); color: #fff; border-bottom-right-radius: 5px; }
.msg-at { font-size: 11px; opacity: .55; margin-top: 5px; }
.msg-media { display: block; max-width: 100%; border-radius: 10px; margin-bottom: 8px; }
.msg-file { display: inline-block; text-decoration: underline; margin-bottom: 6px; }

/* ------------------------------------------------------------ вопросы юристу */

.qitem { padding: 18px; border-bottom: 1px solid var(--line); }
.qitem:last-child { border-bottom: 0; }
.qhead { display: flex; align-items: center; gap: 12px; }
.qhead .spacer { flex: 1; }
.qbody { margin: 12px 0 0; font-size: 15px; line-height: 1.5; white-space: pre-wrap; }
.qanswer {
  margin-top: 14px; padding: 13px 15px; border-radius: 10px;
  background: var(--ok-soft); font-size: 14px; line-height: 1.5;
}
.qanswer b { display: block; font-size: 11px; letter-spacing: .8px; text-transform: uppercase; color: var(--ok); margin-bottom: 6px; }
.qform { margin-top: 14px; }
.qact { display: flex; align-items: center; gap: 12px; margin-top: 10px; }

/* --------------------------------------------------------------- разметка */

.fmt { display: flex; gap: 4px; margin-bottom: 8px; }
.fmt button {
  min-width: 34px; height: 30px; border: 1px solid var(--line); border-radius: 7px;
  background: var(--bg); cursor: pointer; font-family: inherit; font-size: 13px; color: var(--ink);
}
.fmt button:hover { background: var(--alt); }

/* ------------------------------------------- выбор заведения на странице кассира */

.pick { display: flex; flex-direction: column; gap: 8px; text-align: left; }
.pick-row {
  display: flex; align-items: center; gap: 12px;
  padding: 14px 16px; border: 1px solid var(--line); border-radius: 12px;
}
.pick-row:hover { border-color: var(--primary); background: var(--alt); }
.pick-name { flex: 1; font-weight: 600; }
.pick-disc { font-weight: 800; color: var(--accent); font-variant-numeric: tabular-nums; }


/* --------------------------------------------- форма и макет телефона рядом */

.grid-preview {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 430px;
  gap: 26px;
  align-items: start;
}
@media (max-width: 1240px) { .grid-preview { grid-template-columns: minmax(0, 1fr); } }
/* Макет телефона шире узкого экрана — пусть листается внутри, а не растягивает страницу. */
.grid-preview > div { min-width: 0; }
.grid-preview .ph-wrap { max-width: 100%; overflow-x: auto; }


/* Выбор академических групп в форме рассылки */
.gsearch { width: 100%; margin-bottom: 8px; }
.gchips { display: flex; flex-wrap: wrap; gap: 6px; max-height: 190px; overflow-y: auto;
  padding: 8px; border: 1px solid var(--line); border-radius: 10px; background: var(--alt); }
.gchip { position: relative; }
.gchip input { position: absolute; opacity: 0; pointer-events: none; }
.gchip span { display: inline-flex; flex-direction: column; gap: 1px; cursor: pointer;
  padding: 6px 10px; border-radius: 8px; background: var(--bg); border: 1px solid var(--line);
  font-size: 13px; font-weight: 600; line-height: 1.15; }
.gchip span i { font-style: normal; font-size: 11px; font-weight: 500; color: var(--ink3); }
.gchip input:checked + span { background: var(--primary); color: #fff; border-color: var(--primary); }
.gchip input:checked + span i { color: rgba(255,255,255,.65); }
.gchip input:focus-visible + span { outline: 2px solid var(--primary); outline-offset: 2px; }
.gchip[hidden] { display: none; }

/* «Кому» в рассылках и опросах: инструменты под группами и итог. */
.aud .gchips { max-height: 240px; }
.aud-tools { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-top: 8px; }
.aud-tools [data-aud-shown] { margin-right: auto; font-size: 12.5px; }
.aud-count { margin: 4px 0 16px; padding: 10px 12px; border-radius: 10px; background: var(--alt);
  font-size: 13px; color: var(--ink2); line-height: 1.45; transition: opacity .15s; }
.aud-count b { color: var(--ink); }
.aud-count.busy { opacity: .55; }


/* Графики статистики: те же два цвета, что и во всей панели — чернила и акцент.
   Различение не держится на цвете: у серий есть легенда и подписи значений. */
.chart-legend { display: flex; gap: 18px; align-items: center; flex-wrap: wrap;
  font-size: 12.5px; color: var(--ink2); margin-bottom: 14px; }
.chart-legend span { display: inline-flex; align-items: center; gap: 7px; }
.chart-legend .sw { width: 10px; height: 10px; border-radius: 3px; }
.chart-legend .sw1 { background: var(--primary); }
.chart-legend .sw2 { background: var(--ok); }
.chart-legend .chart-max { margin-left: auto; color: var(--ink3); }

.cols { display: flex; align-items: flex-end; gap: 4px; height: 190px; }
.cols.dense { gap: 2px; height: 130px; }
.col { flex: 1; display: flex; flex-direction: column; align-items: center; height: 100%; min-width: 0; }
.col-bars { flex: 1; width: 100%; display: flex; align-items: flex-end; justify-content: center;
  gap: 2px; position: relative; }
.col-bars i { display: block; width: 45%; max-width: 14px; min-height: 2px;
  border-radius: 4px 4px 0 0; }
.cols.dense .col-bars i { width: 70%; }
.col-bars .b1 { background: var(--primary); }
.col-bars .b2 { background: var(--ok); }
.col-num { position: absolute; left: -6px; right: -6px; margin-bottom: 3px; text-align: center;
  font-size: 11px; font-weight: 700; color: var(--ink2); line-height: 1; }
.col-day { font-size: 10.5px; color: var(--ink3); margin-top: 6px; height: 13px; }
.col:hover .col-bars i { opacity: .72; }


/* Опасная зона: та же панель, но с красной рамкой — чтобы её нельзя было
   спутать с обычными настройками. */
.panel.danger { border-color: var(--red); }
.panel.danger .head { color: var(--red); border-bottom-color: var(--red); }
.wipe { border-top: 1px solid var(--line); padding-top: 16px; margin-top: 16px; }
.wipe .muted { margin: 4px 0 10px; }
.wipe .btn[disabled] { opacity: .4; cursor: not-allowed; }


/* Ссылка для контролёра прямо в строке события */
td.checkin { min-width: 300px; }
.checkin .cap { display: block; font-size: 10.5px; letter-spacing: 1px; text-transform: uppercase;
  color: var(--ink3); font-weight: 700; margin-bottom: 5px; }
.checkin input { width: 100%; max-width: 420px; font-family: inherit; font-size: 13px;
  padding: 8px 10px; border: 1px solid var(--line); border-radius: 8px;
  background: var(--alt); color: var(--ink2); }
.checkin-acts { display: inline-flex; gap: 6px; margin-top: 8px; flex-wrap: wrap; }


/* Памятка контролёру — её печатают и кладут рядом с ноутбуком на входе */
.guide { max-width: 780px; }
.guide-link { width: 100%; font-family: inherit; font-size: 15px; padding: 12px 14px;
  border: 1px solid var(--line); border-radius: 10px; background: var(--alt);
  color: var(--ink); margin-bottom: 10px; }
.guide-acts { display: flex; gap: 8px; margin-bottom: 14px; }
.guide-steps { margin: 0; padding-left: 22px; }
.guide-steps li { margin-bottom: 12px; line-height: 1.55; }
.guide-steps li:last-child { margin-bottom: 0; }
.guide-table { width: 100%; border-collapse: collapse; }
.guide-table td { padding: 12px 14px 12px 0; border-bottom: 1px solid var(--line);
  vertical-align: top; line-height: 1.5; }
.guide-table td:first-child { width: 190px; }
.guide-table tr:last-child td { border-bottom: 0; }

@media print {
  .guide-acts { display: none; }
  .panel { border-color: #ccc; break-inside: avoid; }
}


/* Сотрудники и роли */
tr.off td { opacity: .55; }
.inline-form { display: flex; gap: 10px; align-items: flex-end; margin-top: 14px; }
.inline-form .f { flex: 1; margin: 0; }
.perms { border: 0; padding: 0; margin: 0 0 18px; display: grid; gap: 18px;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.perms[disabled] { opacity: .55; }
.perm-group { border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; }
.perm-head { font-size: 10.5px; letter-spacing: 1px; text-transform: uppercase;
  color: var(--ink3); font-weight: 700; margin-bottom: 8px; }
.perm-group .check { margin-bottom: 4px; }


/* Партнёры: выгода — индиго (красный в панели только сигнал), акция строкой,
   логотип в списке, подсказка про координаты, медиафайлы карточки. */
.card .value.accent { color: var(--accent); }
.promo-line { margin-top: 3px; font-size: 12.5px; font-weight: 600; color: var(--accent); }
.avatar.sq { border-radius: 10px; }
.hint-line { margin: -6px 0 16px; font-size: 12px; line-height: 1.5; color: var(--ink3); }
.hint-line a { color: var(--primary); font-weight: 600; white-space: nowrap; }
.media-preview { width: 100%; display: block; border-radius: 10px; }
.media-logo { max-width: 110px; }
.media-empty {
  background: var(--alt); border-radius: 10px; padding: 22px; text-align: center;
  color: var(--ink3); font-size: 13px;
}
.media-form { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 12px; }
.media-form label.f { flex: 1 1 100%; margin-bottom: 4px; }
.media-form input[type=file] { font-size: 12.5px; color: var(--ink2); max-width: 100%; }
.muted.small { font-size: 12px; margin: 10px 0 0; }
.btn-row { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.grid2.even { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 24px; }
@media (max-width: 700px) { .grid2.even { grid-template-columns: minmax(0, 1fr); } }

/* ------------------------------------------------------ опросы: редактор */

.seg { display: inline-flex; gap: 3px; padding: 3px; background: var(--alt); border-radius: var(--radius-sm); }
.seg label { position: relative; }
.seg input { position: absolute; opacity: 0; pointer-events: none; }
.seg span {
  display: block; padding: 7px 16px; border-radius: 6px; cursor: pointer;
  font-size: 13px; font-weight: 600; color: var(--ink2); transition: var(--ease);
}
.seg input:checked + span { background: var(--bg); color: var(--primary); box-shadow: var(--shadow); }

.qed-list { display: flex; flex-direction: column; gap: 14px; }
.qed-empty {
  padding: 26px; text-align: center; font-size: 13px; color: var(--ink3);
  border: 1px dashed var(--line); border-radius: var(--radius);
}
.qcard { padding: 16px 18px 2px; background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius); transition: var(--ease); }
.qcard:focus-within { border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-soft); }
.qcard-head { display: flex; align-items: center; gap: 8px; margin-bottom: 14px; }
.qcard-head select { width: auto; height: 34px; padding: 0 32px 0 12px; }
.qcard-head .spacer { flex: 1; }
.qnum {
  display: inline-flex; align-items: center; justify-content: center;
  width: 26px; height: 26px; flex: 0 0 26px; border-radius: 50%;
  background: var(--primary-soft); color: var(--primary); font-size: 12px; font-weight: 700;
}
.qact {
  display: inline-flex; align-items: center; justify-content: center;
  width: 30px; height: 30px; border-radius: 8px; cursor: pointer;
  border: 1px solid var(--line); background: var(--bg); color: var(--ink2); font-size: 14px;
}
.qact:hover { color: var(--ink); border-color: var(--ink3); }
.qact.del:hover { color: var(--red); border-color: var(--red); }
.qcard .inline { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 16px; font-size: 13px; }
.qcard .inline select, .qcard .inline input[type=number] { width: auto; }
.qcard .inline input[type=number] { width: 76px; }
.qcard .note { margin: 0 0 16px; font-size: 12.5px; color: var(--ink3); }
.qed-add { margin-top: 18px; padding-top: 16px; border-top: 1px dashed var(--line); }
.qed-add-btns { display: flex; flex-wrap: wrap; gap: 8px; }
.poll-submit { display: flex; flex-wrap: wrap; gap: 10px; }

/* --------------------------------------------------------- опросы: итоги */

.panel .head .spacer { flex: 1; }
.res-row {
  display: grid; grid-template-columns: minmax(120px, 1.2fr) 2fr 110px;
  align-items: center; gap: 14px; padding: 7px 0; font-size: 13px;
}
.res-label { color: var(--ink); }
.res-row.top .res-label { font-weight: 700; }
.res-bar { height: 10px; background: var(--alt); border-radius: 20px; overflow: hidden; }
.res-bar i { display: block; height: 100%; background: var(--accent); border-radius: 20px; }
.res-row.top .res-bar i { background: var(--primary); }
.res-num { text-align: right; white-space: nowrap; color: var(--ink2); font-variant-numeric: tabular-nums; }
.res-num b { color: var(--ink); }
.res-more { margin-top: 12px; font-size: 13px; }
.res-more summary { cursor: pointer; color: var(--primary); font-weight: 600; }
.res-texts { list-style: none; margin: 10px 0 0; padding: 0; max-height: 420px; overflow-y: auto; }
.res-texts li {
  display: flex; justify-content: space-between; gap: 12px;
  padding: 10px 12px; margin-bottom: 8px; border-radius: var(--radius-sm);
  background: var(--alt); font-size: 13px; line-height: 1.5;
}
.res-scale { display: grid; grid-template-columns: 150px 1fr; gap: 10px 24px; align-items: end; }
.res-avg b { display: block; font-size: 38px; font-weight: 700; letter-spacing: -1px; line-height: 1; color: var(--ink); }
.res-avg span { font-size: 12px; color: var(--ink2); }
.res-cols { display: flex; align-items: flex-end; gap: 6px; height: 140px; }
.res-col { flex: 1; height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 4px; }
.res-col i { display: block; width: 100%; max-width: 46px; min-height: 3px; background: var(--accent); border-radius: 6px 6px 2px 2px; }
.res-col-num { font-size: 11px; font-weight: 700; color: var(--ink2); }
.res-col-n { font-size: 11.5px; font-weight: 600; color: var(--ink3); }
.res-scale-labels { grid-column: 2; display: flex; justify-content: space-between; font-size: 12px; color: var(--ink3); }
.stars { color: #f5b50a; letter-spacing: 1px; white-space: nowrap; }
.stars .off { color: var(--line); }
@media (max-width: 700px) {
  .res-row { grid-template-columns: 1fr 90px; }
  .res-row .res-bar { grid-column: 1 / -1; grid-row: 2; }
  .res-scale { grid-template-columns: 1fr; }
  .res-scale-labels { grid-column: 1; }
}

/* Вкладка с числом и сводка выпуска на странице заявок */
.tab-n { display: inline-block; min-width: 18px; padding: 1px 6px; margin-left: 4px; border-radius: 10px;
  background: var(--primary); color: #fff; font-size: 11px; line-height: 16px; text-align: center; }
.grad-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 10px; margin-bottom: 14px; }
.grad-stats div { padding: 12px 14px; border-radius: 12px; background: var(--alt); }
.grad-stats b { display: block; font-size: 22px; line-height: 1.1; color: var(--ink); }
.grad-stats span { font-size: 12.5px; color: var(--ink2); line-height: 1.35; }

/* Подгонка обложки новости: карточка как в ленте приложения, кадр 16:9 */
.cover-edit { margin: 4px 0 16px; }
.cover-card { max-width: 380px; border-radius: 20px; overflow: hidden; background: #fff; border: 1px solid var(--line);
  box-shadow: 0 8px 24px rgba(10, 42, 29, .08); font-family: Manrope, var(--font, sans-serif); }
.cover-frame { position: relative; aspect-ratio: 16 / 9; overflow: hidden; background: #F0F4F1; cursor: grab; touch-action: none; user-select: none; }
.cover-frame.dragging { cursor: grabbing; }
.cover-frame img { width: 100%; height: 100%; object-fit: cover; display: block; pointer-events: none; transition: none; }
.cover-stamp { position: absolute; top: 12px; padding: 5px 10px; border-radius: 100px; background: rgba(255,255,255,.92);
  color: #0A2A1D; font-size: 11.5px; font-weight: 800; }
.cover-stamp.l { left: 12px; }
.cover-stamp.r { right: 12px; }
.cover-hint { position: absolute; left: 50%; bottom: 10px; transform: translateX(-50%); padding: 4px 10px; border-radius: 100px;
  background: rgba(10, 42, 29, .62); color: #fff; font-size: 11px; font-weight: 700; opacity: .9; pointer-events: none; }
.cover-frame.dragging .cover-hint, .cover-edit.touched .cover-hint { opacity: 0; }
.cover-body { padding: 12px 16px 16px; display: flex; flex-direction: column; gap: 4px; }
.cover-body b { font-size: 16px; line-height: 1.3; color: #0E1A14; letter-spacing: -.2px; }
.cover-body span { font-size: 13px; line-height: 1.45; color: #5E6B64; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.cover-body span:empty { display: none; }
.cover-tools { display: flex; align-items: center; gap: 10px; max-width: 380px; margin-top: 10px; }
.cover-tools input[type=range] { flex: 1; accent-color: var(--primary); }
/* Предпросмотр «как в приложении» — дизайн 0.10 «Зелёная карта».
   Значения перенесены из app/lib/theme.dart и экранов приложения: те же
   цвета, кегли, скругления, тени и отступы. Меняете там — правьте здесь.
   Макет живёт внутри панели, но её тёмная тема его не трогает: приложение
   светлое, и студент увидит именно так. */

.ph-wrap { position: sticky; top: calc(var(--header-h) + 84px); width: 408px; max-width: 100%; }
.ph-label-top {
  font-size: 10px; font-weight: 700; letter-spacing: .07em; text-transform: uppercase;
  color: var(--ink3); margin: 0 0 10px 4px;
}

.ph {
  --p-ink: #0E1A14;
  --p-ink2: #5E6B64;
  --p-ink3: #97A39D;
  --p-line: #E4EAE6;
  --p-bg: #FFFFFF;
  --p-canvas: #F3F6F4;
  --p-field: #F0F4F1;
  --p-green: #0E9A52;
  --p-green-ink: #0A7F45;
  --p-green-soft: #E6F5EC;
  --p-forest: #0A2A1D;
  --p-forest-hi: #13492F;
  --p-mint: #7FE3AE;
  --p-lime: #D6F56A;
  --p-lime-soft: #F4FBD9;
  --p-amber: #A8670C;
  --p-amber-soft: #FFF4E0;
  --p-read: #2A362F;
  --p-shadow: 0 1px 2px rgba(10, 42, 29, .04), 0 8px 24px rgba(10, 42, 29, .063);

  position: relative;
  width: 408px;
  max-width: 100%;
  height: 844px;
  max-height: calc(100vh - var(--header-h) - 140px);
  min-height: 560px;
  border-radius: 44px;
  overflow: hidden;
  background: var(--p-bg);
  border: 9px solid #0E1A14;
  box-shadow: 0 30px 60px -20px rgba(10, 42, 29, .35), 0 0 0 1px rgba(10, 42, 29, .08);
  font-family: 'Manrope', 'Golos Text', -apple-system, 'Segoe UI', Roboto, sans-serif;
  color: var(--p-ink);
  font-size: 15px;
  line-height: 1.4;
  letter-spacing: 0;
  -webkit-font-smoothing: antialiased;
  display: flex;
  flex-direction: column;
}
.ph.canvas { background: var(--p-canvas); }
.ph * { box-sizing: border-box; }
.ph img, .ph video { display: block; max-width: 100%; }
.ph b, .ph strong { color: inherit; }

.ph-i {
  width: 20px; height: 20px; flex: 0 0 auto;
  fill: none; stroke: currentColor; stroke-width: 1.6;
  stroke-linecap: round; stroke-linejoin: round;
}
.ph-i .fill { fill: currentColor; }

/* строка состояния */
.ph-status {
  height: 34px; flex: 0 0 34px; padding: 0 26px;
  display: flex; align-items: center; justify-content: space-between;
  font-size: 14px; font-weight: 700; color: var(--p-ink);
}
.ph-sys { display: flex; gap: 5px; align-items: center; }
.ph-sys i { width: 15px; height: 9px; border-radius: 2px; background: var(--p-ink); opacity: .85; }
.ph-sys i:first-child { width: 12px; clip-path: polygon(0 100%, 100% 0, 100% 100%); border-radius: 0; }
.ph-sys i.bat { width: 22px; height: 10px; border-radius: 3px; background: none; border: 1.6px solid var(--p-ink); position: relative; }
.ph-sys i.bat::after { content: ""; position: absolute; inset: 1.4px 5px 1.4px 1.4px; background: var(--p-ink); border-radius: 1px; }

.ph-scroll { flex: 1; overflow-y: auto; overflow-x: hidden; }
.ph-scroll::-webkit-scrollbar { width: 0; }

/* ----------------------------------------------------------- общие детали */

.ph-pad { padding: 0 20px; }
.ph-row { display: flex; align-items: center; gap: 6px; min-width: 0; }
.ph-row .sp, .ph .sp { flex: 1; }
.ph-hair { height: 1px; background: var(--p-line); }
.ph-hair.in { margin-left: 56px; }
.ph-caption { font-size: 12px; font-weight: 600; color: var(--p-ink3); }
.ph-cap-i { width: 14px; height: 14px; color: var(--p-ink3); }

.ph-top {
  height: 64px; display: flex; align-items: center; padding: 0 16px; gap: 8px;
}
.ph-top-title {
  flex: 1; text-align: center; font-size: 16.5px; font-weight: 800; letter-spacing: -.2px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.ph-circle {
  width: 44px; height: 44px; flex: 0 0 44px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: var(--p-bg); border: 1.2px solid var(--p-line); color: var(--p-ink);
}
.ph-circle .ph-i { width: 22px; height: 22px; }
.ph-circle.ghost { visibility: hidden; }
.ph-circle.float { position: absolute; top: 44px; border: 0; box-shadow: var(--p-shadow); background: rgba(255, 255, 255, .96); }
.ph-circle.float.l { left: 16px; }
.ph-circle.float.r { right: 16px; }

/* плашки: мятная (StatusChip), хвойная «закреплено», жёлтая */
.ph-chip {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 5px 10px; border-radius: 100px;
  background: var(--p-green-soft); color: var(--p-green-ink);
  font-size: 12px; font-weight: 700; line-height: 1.2; white-space: nowrap;
  max-width: 200px; overflow: hidden; text-overflow: ellipsis;
}
.ph-chip .dot { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.ph-chip.amber { background: var(--p-amber-soft); color: var(--p-amber); }
.ph-pin {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 5px 10px 5px 8px; border-radius: 100px;
  background: var(--p-forest); color: #fff; font-size: 11.5px; font-weight: 700; white-space: nowrap;
}
.ph-pin .ph-i { width: 12px; height: 12px; color: var(--p-mint); }

/* типографика экранов */
.ph-display { font-size: 28px; font-weight: 800; line-height: 1.14; letter-spacing: -.8px; margin-top: 14px; overflow-wrap: anywhere; }
.ph-title { font-size: 23px; font-weight: 800; line-height: 1.2; letter-spacing: -.4px; margin-top: 10px; overflow-wrap: anywhere; }
.ph-lead { font-size: 17px; font-weight: 700; line-height: 1.5; margin-top: 14px; }
.ph-read {
  font-size: 15.5px; font-weight: 500; line-height: 1.65; color: var(--p-read);
  margin-top: 20px; white-space: pre-wrap; overflow-wrap: anywhere;
}

/* галерея 4:5 со скруглением 22 */
.ph-gal {
  position: relative; margin-top: 20px; aspect-ratio: 4 / 5; height: auto;
  border-radius: 22px; overflow: hidden; background: var(--p-field);
}
.ph .g-slide { display: none; width: 100%; height: 100%; object-fit: cover; }
.ph .g-slide.on { display: block; }
.ph .g-bars { position: absolute; top: 12px; left: 12px; right: 12px; display: flex; gap: 4px; z-index: 2; }
.ph .g-bars i { flex: 1; height: 3px; border-radius: 2px; background: rgba(255, 255, 255, .3); }
.ph .g-bars i.on { background: #fff; }
.ph .g-arrow {
  position: absolute; top: 50%; transform: translateY(-50%); z-index: 2;
  width: 38px; height: 38px; border-radius: 50%; border: 0; cursor: pointer;
  background: rgba(255, 255, 255, .96); color: var(--p-ink); font-size: 22px; line-height: 1;
  display: flex; align-items: center; justify-content: center; box-shadow: var(--p-shadow);
}
.ph .g-arrow.prev { left: 10px; }
.ph .g-arrow.next { right: 10px; }
.ph .g-count {
  position: absolute; right: 12px; bottom: 12px; z-index: 2;
  padding: 5px 10px; border-radius: 100px; background: rgba(10, 42, 29, .7);
  color: #fff; font-size: 12px; font-weight: 700;
}
.ph-empty {
  position: absolute; inset: 0;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px;
  color: var(--p-ink3); font-size: 12.5px; font-weight: 600;
}
.ph-empty .ph-i { width: 30px; height: 30px; }
/* Без фото галереи в приложении нет вовсе — в макете тоже. Появляется,
   как только в форме выбрали файлы. */
.ph-gal.is-empty { display: none; }
.ph-ad .ph-empty { border: 1.5px dashed #D5DDD8; border-radius: 22px; }

/* рамка со строками (Panel с обводкой) */
.ph-box { margin-top: 22px; padding: 4px 14px; border: 1px solid var(--p-line); border-radius: 22px; background: var(--p-bg); }
.ph-badge {
  width: 42px; height: 42px; flex: 0 0 42px; border-radius: 13px;
  display: flex; align-items: center; justify-content: center;
  background: var(--p-green-soft); color: var(--p-green-ink);
}
.ph-nav, .ph-info { display: flex; align-items: center; gap: 14px; padding: 12px 0; }
.ph-nav + .ph-nav { border-top: 1px solid var(--p-line); margin-left: 0; }
.ph-nav-text, .ph-info-text { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.ph-nav-text b, .ph-info-text b { font-size: 15px; font-weight: 700; line-height: 1.3; overflow-wrap: anywhere; }
.ph-nav-text small { font-size: 13px; font-weight: 500; color: var(--p-ink2); }
.ph-info-text small { font-size: 12px; font-weight: 600; color: var(--p-ink3); }
.ph-trail { width: 18px; height: 18px; color: var(--p-ink3); }

/* реакции под новостью */
.ph-react {
  display: flex; align-items: center; gap: 6px; margin: 18px 0 32px;
  padding: 14px 16px; border-radius: 18px; background: var(--p-field);
  font-size: 12px; font-weight: 600; color: var(--p-ink3);
}
.ph-react > span { display: inline-flex; align-items: center; gap: 6px; }
.ph-heart { font-weight: 700; font-size: 12.5px; }
.ph-heart .ph-i { width: 17px; height: 17px; }

/* кнопки: зелёная пилюля и контурная */
.ph-btn {
  height: 56px; margin-top: 26px; border-radius: 100px;
  display: flex; align-items: center; justify-content: center; gap: 9px;
  background: var(--p-green); color: #fff; font-size: 16px; font-weight: 700; letter-spacing: -.1px;
}
.ph-btn .ph-i { width: 21px; height: 21px; }
.ph-btn.outline { background: var(--p-bg); color: var(--p-ink); border: 1.4px solid #D5DDD8; margin-top: 10px; font-size: 15px; padding: 0 16px; text-align: center; }
.ph-btn.outline .ph-i { width: 20px; height: 20px; }

/* ---------------------------------------------------------------- событие */

.ph-event-head { display: flex; gap: 16px; align-items: flex-start; margin-top: 6px; }
/* Листок календаря (DateTile): месяц на зелёной полосе, число, день недели. */
.ph-datetile {
  width: 66px; height: 72px; flex: 0 0 66px; border-radius: 16px; overflow: hidden;
  background: var(--p-bg); border: 1px solid var(--p-line); box-sizing: border-box;
  display: flex; flex-direction: column; align-items: center; color: var(--p-ink);
}
.ph-datetile i {
  align-self: stretch; height: 20px; flex: 0 0 20px; background: var(--p-green); color: #fff;
  font-style: normal; font-size: 10.5px; font-weight: 800; letter-spacing: .8px;
  text-transform: uppercase; display: flex; align-items: center; justify-content: center;
}
.ph-datetile b {
  margin-top: auto; font-size: 24.4px; font-weight: 800; line-height: 1.05; letter-spacing: -.6px;
  font-variant-numeric: tabular-nums; white-space: nowrap;
}
.ph-datetile b .is-long { font-size: 19px; letter-spacing: -.8px; }
.ph-datetile small { margin-bottom: auto; font-size: 11px; font-weight: 700; color: var(--p-ink3); }
.ph-event-title { flex: 1; min-width: 0; }
.ph-seats { margin-top: 22px; padding: 16px; border-radius: 18px; background: var(--p-field); font-size: 14px; }
.ph-seats .ph-row { gap: 8px; }
.ph-seats b { font-weight: 700; }
.ph-seats b.num { font-weight: 800; font-variant-numeric: tabular-nums; }
.ph-seat-i { width: 18px; height: 18px; color: var(--p-ink2); }
.ph-progress { height: 8px; margin-top: 12px; border-radius: 8px; background: #DDE5E0; overflow: hidden; }
.ph-progress i { display: block; height: 100%; border-radius: 8px; background: var(--p-green); }

/* ------------------------------------------------------------ лента новостей */

.ph-head { display: flex; align-items: center; padding: 10px 20px 0; }
.ph-h1 { flex: 1; font-size: 28px; font-weight: 800; letter-spacing: -.8px; }
.ph-head .ph-circle .ph-i { width: 21px; height: 21px; }
.ph-chips { display: flex; gap: 8px; padding: 14px 20px; overflow: hidden; }
.ph-pill {
  height: 40px; padding: 0 16px; border-radius: 100px; white-space: nowrap;
  display: inline-flex; align-items: center;
  background: var(--p-bg); border: 1px solid var(--p-line);
  font-size: 14px; font-weight: 700; color: var(--p-ink);
}
.ph-pill.on { background: var(--p-green); border-color: var(--p-green); color: #fff; }

.ph-ads { padding: 0 0 16px; }
.ph-ads-track { display: flex; gap: 10px; padding: 0 20px; }
.ph-ad {
  position: relative; flex: 0 0 calc(100% - 22px); height: 168px;
  border-radius: 22px; overflow: hidden; background: var(--p-field);
}
.ph-ad.peek { flex: 0 0 60px; opacity: .6; }
.ph-ad img, .ph-ad video { width: 100%; height: 100%; object-fit: cover; }
.ph-ad-tag {
  position: absolute; left: 12px; top: 12px; z-index: 2;
  padding: 4px 8px; border-radius: 100px; background: rgba(255, 255, 255, .7);
  font-size: 10.5px; font-weight: 700; color: var(--p-ink2);
}
.ph-dots { display: flex; justify-content: center; gap: 5px; margin-top: 10px; }
.ph-dots i { width: 6px; height: 6px; border-radius: 3px; background: #D5DDD8; }
.ph-dots i.on { width: 18px; background: var(--p-green); }

.ph-card { background: var(--p-bg); border-radius: 22px; overflow: hidden; box-shadow: var(--p-shadow); margin-bottom: 14px; }
.ph-cover { position: relative; aspect-ratio: 16 / 9; background: var(--p-field); overflow: hidden; }
.ph-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ph-stamp {
  position: absolute; top: 12px; padding: 6px 10px; border-radius: 100px;
  background: rgba(255, 255, 255, .94); font-size: 11.5px; font-weight: 700; color: var(--p-ink);
}
.ph-stamp.l { left: 12px; }
.ph-stamp.r { right: 12px; }
.ph-card-body { padding: 14px 16px; }
.ph-card-body > .ph-row { margin-bottom: 12px; }
.ph-card-title { font-size: 17px; font-weight: 800; line-height: 1.28; letter-spacing: -.3px; }
.ph-card-lead {
  margin-top: 6px; font-size: 14px; font-weight: 500; line-height: 1.45; color: var(--p-ink2);
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.ph-card .ph-hair { margin: 12px 0 10px; }
.ph-meta { display: flex; gap: 18px; font-size: 12px; font-weight: 600; color: var(--p-ink3); }
.ph-meta span { display: inline-flex; align-items: center; gap: 6px; }
.ph-meta .ph-i { width: 16px; height: 16px; }

/* плавающая панель вкладок с зелёной кнопкой кода по центру */
.ph-tabbar {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 18px 14px 12px;
  background: linear-gradient(to bottom, rgba(243, 246, 244, 0), rgba(243, 246, 244, .9) 45%, #F3F6F4);
}
.ph-tabbar-in {
  height: 70px; padding: 0 6px; border-radius: 28px; background: var(--p-bg);
  display: flex; align-items: center;
  box-shadow: 0 2px 4px rgba(10, 42, 29, .08), 0 14px 32px rgba(10, 42, 29, .12);
}
.ph-tab {
  flex: 1; display: flex; flex-direction: column; align-items: center; gap: 4px;
  font-size: 11px; font-weight: 600; color: var(--p-ink3);
}
.ph-tab .ph-i { width: 24px; height: 24px; }
.ph-tab.on { color: var(--p-green-ink); font-weight: 800; }
.ph-tab.on .ph-i { color: var(--p-green); stroke-width: 2.1; }
.ph-tab-pass {
  width: 56px; height: 56px; margin: 0 4px; border-radius: 50%;
  background: var(--p-green); color: #fff;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 6px 16px rgba(14, 154, 82, .35);
}
.ph-tab-pass .ph-i { width: 26px; height: 26px; }

/* ----------------------------------------------------------------- партнёр */

.ph-hero { position: relative; height: 250px; background: var(--p-forest); }
.ph-hero img { width: 100%; height: 100%; object-fit: cover; }
.ph-forest {
  background:
    radial-gradient(circle at 85% 20%, rgba(127, 227, 174, .18), transparent 45%),
    linear-gradient(135deg, var(--p-forest-hi), var(--p-forest));
}
.ph-lift { margin-top: -34px; position: relative; }
.ph-logo-box {
  display: inline-block; padding: 4px; border-radius: 26px; background: var(--p-bg); box-shadow: var(--p-shadow);
}
.ph-logo {
  position: relative; width: 68px; height: 68px; border-radius: 20px; overflow: hidden;
  background: var(--p-green-soft);
}
.ph-logo img { width: 100%; height: 100%; object-fit: cover; }
.ph-mono { font-size: 22px; font-weight: 800; letter-spacing: -.3px; color: var(--p-green-ink); }
.ph-sub { margin-top: 8px; gap: 6px; font-size: 13.5px; font-weight: 700; color: var(--p-ink2); }
.ph-sub-i { width: 16px; height: 16px; }
.ph-dotsep { color: var(--p-ink3); margin: 0 6px; }
.ph-discount {
  margin-top: 20px; padding: 16px 18px; border-radius: 22px; background: var(--p-green-soft);
  display: flex; align-items: center; gap: 14px; color: var(--p-green-ink);
}
.ph-discount b { font-size: 44px; font-weight: 800; line-height: 1; letter-spacing: -1.6px; }
.ph-discount > span { flex: 1; font-size: 13.5px; font-weight: 700; line-height: 1.35; }
.ph-discount .ph-i { width: 26px; height: 26px; color: var(--p-green); }
.ph-promo {
  margin-top: 10px; padding: 13px 12px; border-radius: 14px; background: var(--p-lime-soft);
  display: flex; align-items: center; gap: 8px;
  font-size: 14px; font-weight: 700; line-height: 1.35; color: var(--p-forest);
}
.ph-promo .ph-i { width: 18px; height: 18px; }
.ph-promo .ph-i path { fill: currentColor; stroke: none; }

/* подпись под макетом */
.ph-note { margin-top: 12px; font-size: 12.5px; line-height: 1.5; color: var(--ink3); }

@media (max-width: 1240px) {
  .ph-wrap { position: static; margin: 0 auto; }
  .ph { max-height: none; }
}
@media (max-width: 480px) {
  .ph { border-width: 6px; border-radius: 34px; height: 760px; }
}
/* В тёмной теме панели тёмная рамка телефона сливается с фоном. */
html.app-skin-dark .ph { box-shadow: 0 0 0 1px rgba(255, 255, 255, .14), 0 30px 60px -20px rgba(0, 0, 0, .6); }

/* Галерея партнёра лентой (PartnerGallery в приложении) */
.ph-sect { margin: 22px 0 10px; font-size: 16px; font-weight: 800; letter-spacing: -.2px; color: var(--p-ink); }
.ph-strip { display: flex; gap: 8px; overflow-x: auto; margin: 0 -18px; padding: 0 18px 2px; scrollbar-width: none; }
.ph-strip::-webkit-scrollbar { display: none; }
.ph-thumb { position: relative; flex: 0 0 104px; width: 104px; height: 104px; border-radius: 16px; overflow: hidden; background: var(--p-field, #f1f4f2); }
.ph-thumb:first-child { flex-basis: 150px; width: 150px; }
.ph-thumb img, .ph-thumb video { width: 100%; height: 100%; object-fit: cover; display: block; }
.ph-thumb.vid::after { content: '▶'; position: absolute; left: 50%; top: 50%; width: 34px; height: 34px; margin: -17px 0 0 -17px;
  border-radius: 50%; background: rgba(0,0,0,.45); color: #fff; font-size: 13px; line-height: 34px; text-align: center; }
.ph-strip-empty { display: flex; align-items: center; justify-content: center; color: var(--p-ink3); }
.ph-strip-empty .ph-i { width: 28px; height: 28px; }

/* Уведомление на экране блокировки — предпросмотр рассылки */
.push-lock { width: 100%; max-width: 390px; margin: 0 auto; padding: 34px 14px 26px; border-radius: 34px;
  background: linear-gradient(160deg, #0A2A1D 0%, #13492F 55%, #0E9A52 130%); color: #fff; font-family: Manrope, sans-serif; }
.push-time { text-align: center; font-size: 64px; font-weight: 300; letter-spacing: -2px; line-height: 1; margin-bottom: 26px; opacity: .95; }
.push-card { background: rgba(255,255,255,.9); color: #0E1A14; border-radius: 20px; padding: 12px 14px 14px;
  box-shadow: 0 10px 30px rgba(0,0,0,.18); backdrop-filter: blur(10px); }
.push-head { display: flex; align-items: center; gap: 8px; font-size: 12.5px; color: #5E6B64; margin-bottom: 6px; }
.push-head img { width: 20px; height: 20px; border-radius: 6px; }
.push-head b { color: #0E1A14; font-weight: 700; }
.push-head span { margin-left: auto; }
.push-title { font-weight: 800; font-size: 15px; line-height: 1.3; overflow-wrap: anywhere; }
.push-body { font-size: 14px; line-height: 1.4; color: #2B3A33; margin-top: 2px; display: -webkit-box; -webkit-line-clamp: 4;
  -webkit-box-orient: vertical; overflow: hidden; white-space: pre-wrap; overflow-wrap: anywhere; }
