/* =========================================================
   «Авиапочта» — дизайн каталога
   Бумага, синие чернила, кайма авиаконверта, штемпель
   ========================================================= */

:root {
  --paper: #EDF0F5;
  --paper-2: #E2E7EF;
  --card: #FFFFFF;
  --ink: #1B1F3B;
  --ink-2: #4A5072;
  --ink-3: #7D83A3;
  --line: rgba(27, 31, 59, .12);
  --line-2: rgba(27, 31, 59, .22);
  --blue: #2438C6;
  --blue-ink: #1A2A9E;
  --blue-soft: #E3E7FB;
  --red: #E5432F;
  --red-soft: #FCE6E2;
  --yellow: #F4C43B;
  --green: #1F8A5B;
  --green-soft: #DDF2E8;
  --stamp: rgba(36, 56, 198, .72);
  --radius: 10px;
  --radius-sm: 6px;
  --shadow: 0 1px 0 rgba(27, 31, 59, .06), 0 8px 24px -16px rgba(27, 31, 59, .35);
  --display: "Unbounded", "Golos Text", system-ui, sans-serif;
  --text: "Golos Text", system-ui, -apple-system, "Segoe UI", sans-serif;
  --stripes: repeating-linear-gradient(-45deg, var(--red) 0 14px, transparent 14px 22px, var(--blue) 22px 36px, transparent 36px 44px);
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #11142A; --paper-2: #181C38; --card: #1B1F3B;
    --ink: #E9ECF7; --ink-2: #B3B8D4; --ink-3: #8086A8;
    --line: rgba(233, 236, 247, .1); --line-2: rgba(233, 236, 247, .2);
    --blue: #7D8CFF; --blue-ink: #A4AEFF; --blue-soft: #262C5C;
    --red: #FF6B57; --red-soft: #3D2230; --green: #4CC38A; --green-soft: #1C3A33;
    --stamp: rgba(125, 140, 255, .8);
    --shadow: 0 1px 0 rgba(0, 0, 0, .3), 0 10px 30px -18px rgba(0, 0, 0, .8);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --paper: #11142A; --paper-2: #181C38; --card: #1B1F3B;
  --ink: #E9ECF7; --ink-2: #B3B8D4; --ink-3: #8086A8;
  --line: rgba(233, 236, 247, .1); --line-2: rgba(233, 236, 247, .2);
  --blue: #7D8CFF; --blue-ink: #A4AEFF; --blue-soft: #262C5C;
  --red: #FF6B57; --red-soft: #3D2230; --green: #4CC38A; --green-soft: #1C3A33;
  --stamp: rgba(125, 140, 255, .8);
  --shadow: 0 1px 0 rgba(0, 0, 0, .3), 0 10px 30px -18px rgba(0, 0, 0, .8);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font: 400 16px/1.55 var(--text); font-feature-settings: "tnum" 0;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--blue); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--blue-ink); }
:focus-visible { outline: 3px solid var(--yellow); outline-offset: 2px; border-radius: 4px; }
h1, h2, h3 { font-family: var(--display); font-weight: 600; letter-spacing: -.01em; line-height: 1.15; margin: 0; }
h1 { font-size: clamp(28px, 4.4vw, 46px); }
h2 { font-size: clamp(20px, 2.4vw, 26px); }
h3 { font-size: 17px; }
p { margin: 0 0 1em; }
.num { font-variant-numeric: tabular-nums; }
.muted { color: var(--ink-3); }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.wrap { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 20px; }
@media (max-width: 600px) { .wrap { padding: 0 16px; } }

/* ---------- Шапка ---------- */
.top { background: var(--card); position: sticky; top: 0; z-index: 30; }
.top::after { content: ""; display: block; height: 6px; background: var(--stripes); }
.top-in { display: flex; align-items: center; gap: 18px; height: 66px; }
.logo { display: flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; flex-shrink: 0; }
.logo:hover { color: var(--ink); }
.logo-mark { width: 36px; height: 36px; border-radius: 8px; background: var(--blue); display: grid; place-items: center; }
.logo-mark svg { width: 20px; height: 20px; }
.logo-name { font: 700 19px/1 var(--display); letter-spacing: -.02em; }
.top-search { flex: 1; max-width: 420px; position: relative; }
.top-search input { width: 100%; height: 40px; border-radius: 999px; border: 1px solid var(--line-2); background: var(--paper); color: var(--ink); padding: 0 16px 0 40px; font: inherit; font-size: 15px; }
.top-search input:focus { outline: none; border-color: var(--blue); background: var(--card); }
.top-search svg { position: absolute; left: 14px; top: 11px; width: 18px; height: 18px; color: var(--ink-3); }
.nav { display: flex; align-items: center; gap: 4px; margin-left: auto; }
.nav a, .nav button.linkish { color: var(--ink-2); text-decoration: none; padding: 8px 12px; border-radius: 8px; font-size: 15px; font-weight: 500; }
.nav a:hover, .nav button.linkish:hover { background: var(--paper); color: var(--ink); }
.nav a[aria-current="page"] { color: var(--ink); background: var(--paper); }
.nav .btn { margin-left: 6px; }
.nav a.btn--primary, .nav a.btn--primary:hover { color: #fff; background: var(--blue); }
:root[data-theme="dark"] .nav a.btn--primary { color: #11142A; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .nav a.btn--primary { color: #11142A; } }
.theme-btn { border: 0; background: none; color: var(--ink-2); width: 38px; height: 38px; border-radius: 8px; cursor: pointer; display: grid; place-items: center; }
.theme-btn:hover { background: var(--paper); }
.menu-btn { display: none; border: 1px solid var(--line-2); background: var(--card); color: var(--ink); border-radius: 8px; height: 38px; padding: 0 12px; font: inherit; font-weight: 500; cursor: pointer; margin-left: auto; }
@media (max-width: 1140px) {
  .top-search { display: none; }
  .menu-btn { display: block; }
  .nav { display: none; position: absolute; left: 0; right: 0; top: 72px; max-height: calc(100vh - 80px); overflow: auto; background: var(--card); flex-direction: column; align-items: stretch; padding: 10px 16px 16px; border-bottom: 1px solid var(--line); box-shadow: var(--shadow); }
  .nav.open { display: flex; }
  .nav .btn { margin: 6px 0 0; }
  .nav .theme-btn { width: 100%; }
}

/* ---------- Кнопки ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 42px; padding: 0 18px; border-radius: 999px; border: 1px solid var(--line-2); background: var(--card); color: var(--ink); font: 500 15px/1 var(--text); text-decoration: none; cursor: pointer; white-space: nowrap; transition: background .15s, border-color .15s, transform .1s; }
.btn:hover { border-color: var(--ink-3); color: var(--ink); }
.btn:active { transform: translateY(1px); }
.btn--primary { background: var(--blue); border-color: var(--blue); color: #fff; }
.btn--primary:hover { background: var(--blue-ink); border-color: var(--blue-ink); color: #fff; }
:root[data-theme="dark"] .btn--primary, :root[data-theme="dark"] .btn--primary:hover { color: #11142A; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .btn--primary, :root:not([data-theme="light"]) .btn--primary:hover { color: #11142A; } }
.btn--big { height: 52px; padding: 0 26px; font-size: 16px; }
.btn--sm { height: 34px; padding: 0 13px; font-size: 14px; }
.btn--ghost { background: transparent; }
.btn--danger { color: var(--red); border-color: color-mix(in srgb, var(--red) 40%, transparent); background: transparent; }
.btn--danger:hover { background: var(--red-soft); color: var(--red); border-color: var(--red); }
.btn svg { width: 18px; height: 18px; flex-shrink: 0; }

.icon-btn { display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 11px; border-radius: 999px; border: 1px solid var(--line); background: transparent; color: var(--ink-2); cursor: pointer; font: 500 14px/1 var(--text); }
.icon-btn:hover { border-color: var(--line-2); color: var(--ink); }
.icon-btn svg { width: 17px; height: 17px; }
.icon-btn[aria-pressed="true"].is-fav { color: var(--blue); border-color: var(--blue); background: var(--blue-soft); }
.icon-btn[aria-pressed="true"].is-like { color: var(--red); border-color: var(--red); background: var(--red-soft); }
.icon-btn[aria-pressed="true"] svg { fill: currentColor; }

/* ---------- Главная: hero и конверт ---------- */
.hero { padding: 56px 0 40px; display: grid; grid-template-columns: 1.15fr .85fr; gap: 48px; align-items: center; }
.hero h1 { max-width: 15ch; }
.hero-lead { color: var(--ink-2); font-size: 18px; max-width: 46ch; margin: 18px 0 26px; }
.hero-search { display: flex; gap: 8px; max-width: 560px; }
.hero-search input { flex: 1; min-width: 0; height: 52px; border-radius: 999px; border: 1px solid var(--line-2); background: var(--card); color: var(--ink); padding: 0 22px; font: inherit; font-size: 16px; box-shadow: var(--shadow); }
.hero-search input:focus { outline: none; border-color: var(--blue); }
.hero-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
@media (max-width: 860px) { .hero { grid-template-columns: 1fr; padding-top: 36px; gap: 32px; } }

.envelope { position: relative; background: var(--card); border-radius: var(--radius); padding: 14px; box-shadow: var(--shadow); transform: rotate(-1.5deg); }
.envelope::before { content: ""; position: absolute; inset: 0; border-radius: var(--radius); padding: 10px; background: var(--stripes); -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask-composite: exclude; pointer-events: none; }
.envelope-in { border: 1px dashed var(--line-2); border-radius: 4px; padding: 26px 26px 22px; position: relative; min-height: 260px; }
.envelope-from { font-size: 13px; color: var(--ink-3); line-height: 1.45; }
.envelope-to { margin-top: 44px; margin-left: 30%; }
.envelope-to .label { font-size: 13px; color: var(--ink-3); }
.envelope-to .line { font: 500 18px/1.35 var(--display); border-bottom: 1px solid var(--line-2); padding: 6px 0 4px; }
.envelope-to .line:last-child { border-bottom: 0; }
.stamp { position: absolute; top: 18px; right: 18px; width: 76px; height: 90px; background: var(--yellow); display: grid; place-items: center; transform: rotate(4deg); border: 5px dotted var(--card); box-shadow: 0 0 0 2px var(--yellow); }
.stamp svg { width: 40px; height: 40px; color: var(--ink); }
@media (prefers-reduced-motion: no-preference) {
  .envelope { animation: drop .7s cubic-bezier(.2, .9, .3, 1.2) both; }
  @keyframes drop { from { opacity: 0; transform: translateY(-22px) rotate(-6deg); } to { opacity: 1; transform: rotate(-1.5deg); } }
}
@media (max-width: 860px) { .envelope { transform: none; } .envelope-to { margin-left: 0; } @keyframes drop { from { opacity: 0; } to { opacity: 1; } } }

/* ---------- Чипы и секции ---------- */
.chip { display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--line-2); background: var(--card); color: var(--ink); text-decoration: none; font-size: 14px; font-weight: 500; white-space: nowrap; }
.chip:hover { border-color: var(--blue); color: var(--blue); }
.chip[aria-current="true"] { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.chip .cnt { color: var(--ink-3); font-weight: 400; font-variant-numeric: tabular-nums; }
.chip[aria-current="true"] .cnt { color: inherit; opacity: .7; }

.section { padding: 34px 0; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; margin-bottom: 20px; flex-wrap: wrap; }
.section-head a { font-weight: 500; }

/* Список разделов: строки, не карточки */
.cat-index { columns: 4 230px; column-gap: 28px; background: var(--card); border-radius: var(--radius); padding: 14px 22px; box-shadow: var(--shadow); }
.cat-index a { display: flex; align-items: center; gap: 10px; padding: 9px 0; border-bottom: 1px solid var(--line); text-decoration: none; color: var(--ink); break-inside: avoid; }
.cat-index a:hover .cat-name { color: var(--blue); }
.cat-icon { width: 24px; text-align: center; flex-shrink: 0; }
.cat-name { flex: 1; font-weight: 500; }
.cat-cnt { color: var(--ink-3); font-size: 14px; font-variant-numeric: tabular-nums; }

/* ---------- Карточка канала ---------- */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 16px; }
@media (max-width: 400px) { .grid { grid-template-columns: 1fr; } }
.card { position: relative; background: var(--card); border-radius: var(--radius); padding: 20px 20px 16px; box-shadow: var(--shadow); display: flex; flex-direction: column; min-width: 0; }
.card.is-featured { box-shadow: inset 0 0 0 2px var(--yellow), var(--shadow); }
.card-head { display: flex; gap: 14px; align-items: center; padding-right: 74px; min-width: 0; }
.ava { width: 56px; height: 56px; border-radius: 50%; flex-shrink: 0; object-fit: cover; background: var(--paper-2); }
.ava--ph { display: grid; place-items: center; color: #fff; font: 600 19px/1 var(--display); }
.card-title { font: 600 16px/1.3 var(--display); margin: 0; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow-wrap: anywhere; }
.card-title a { color: var(--ink); text-decoration: none; }
.card-title a::after { content: ""; position: absolute; inset: 0; border-radius: var(--radius); }
.card-title a:hover { color: var(--blue); }
.card-meta { font-size: 13.5px; color: var(--ink-3); margin-top: 3px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.card-text { color: var(--ink-2); font-size: 14.5px; margin: 14px 0 16px; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; }
.card-foot { margin-top: auto; display: flex; align-items: center; gap: 8px; position: relative; z-index: 2; }
.card-foot .btn { margin-right: auto; }
.card-cat { position: relative; z-index: 2; align-self: flex-start; font-size: 13px; color: var(--ink-2); text-decoration: none; background: var(--paper); border-radius: 999px; padding: 4px 10px; margin-top: 12px; }
.card-cat:hover { color: var(--blue); }

/* Штемпель: число подписчиков */
.postmark { position: absolute; top: 14px; right: 14px; width: 66px; height: 66px; border-radius: 50%; border: 2px dashed var(--stamp); color: var(--stamp); display: grid; place-content: center; text-align: center; transform: rotate(-12deg); line-height: 1.05; pointer-events: none; }
.postmark::before { content: ""; position: absolute; inset: 4px; border-radius: 50%; border: 1px solid var(--stamp); opacity: .5; }
.postmark b { font: 700 13px/1 var(--display); font-variant-numeric: tabular-nums; }
.postmark small { font-size: 9.5px; margin-top: 2px; }
.postmark--bot b { font-size: 12px; }

/* ---------- Фильтры, крошки, пагинация ---------- */
.crumbs { font-size: 14px; color: var(--ink-3); margin: 24px 0 14px; }
.crumbs a { color: var(--ink-2); text-decoration: none; }
.crumbs a:hover { color: var(--blue); }
.crumbs span[aria-hidden] { margin: 0 6px; }
.page-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; flex-wrap: wrap; margin-bottom: 22px; }
.page-head p { color: var(--ink-2); margin: 10px 0 0; max-width: 62ch; }
.filters { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 20px; }
.filters .sep { width: 1px; height: 22px; background: var(--line-2); margin: 0 6px; }
.select { height: 34px; border-radius: 999px; border: 1px solid var(--line-2); background: var(--card); color: var(--ink); padding: 0 32px 0 14px; font: 500 14px var(--text); appearance: none; background-image: linear-gradient(45deg, transparent 50%, currentColor 50%), linear-gradient(135deg, currentColor 50%, transparent 50%); background-position: right 15px top 15px, right 10px top 15px; background-size: 5px 5px; background-repeat: no-repeat; cursor: pointer; }
.pager { display: flex; justify-content: center; flex-wrap: wrap; gap: 6px; margin: 30px 0 10px; }
.pager a, .pager span { min-width: 40px; height: 40px; display: grid; place-items: center; padding: 0 12px; border-radius: 999px; text-decoration: none; color: var(--ink); background: var(--card); border: 1px solid var(--line); font-variant-numeric: tabular-nums; }
.pager a:hover { border-color: var(--blue); color: var(--blue); }
.pager .cur { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.pager .gap { border: 0; background: none; }

.layout-side { display: grid; grid-template-columns: 250px 1fr; gap: 28px; align-items: start; }
.side-cats { position: sticky; top: 96px; background: var(--card); border-radius: var(--radius); padding: 10px; box-shadow: var(--shadow); max-height: calc(100vh - 120px); overflow: auto; }
.side-cats a { display: flex; gap: 8px; align-items: center; padding: 7px 10px; border-radius: 7px; color: var(--ink-2); text-decoration: none; font-size: 14.5px; }
.side-cats a:hover { background: var(--paper); color: var(--ink); }
.side-cats a[aria-current="page"] { background: var(--blue-soft); color: var(--blue-ink); font-weight: 600; }
.side-cats .cat-cnt { margin-left: auto; font-size: 13px; }
@media (max-width: 900px) { .layout-side { grid-template-columns: 1fr; } .side-cats { display: none; } }

.seo-text { background: var(--card); border-radius: var(--radius); padding: 26px 28px; margin: 34px 0 10px; color: var(--ink-2); max-width: 820px; box-shadow: var(--shadow); }
.seo-text h2 { color: var(--ink); margin-bottom: 12px; font-size: 20px; }
.seo-text p:last-child { margin-bottom: 0; }

/* ---------- Страница канала ---------- */
.channel { display: grid; grid-template-columns: 1fr 330px; gap: 28px; align-items: start; margin-bottom: 40px; }
@media (max-width: 960px) { .channel { grid-template-columns: 1fr; } }
.letter { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.letter::before { content: ""; display: block; height: 10px; background: var(--stripes); }
.letter-body { padding: 30px 32px 32px; position: relative; }
@media (max-width: 600px) { .letter-body { padding: 22px 18px 24px; } }
.ch-head { display: flex; gap: 22px; align-items: center; padding-right: 100px; }
.ch-head .ava { width: 104px; height: 104px; }
.ch-head .ava--ph { font-size: 34px; }
.ch-head h1 { font-size: clamp(24px, 3.4vw, 34px); overflow-wrap: anywhere; }
.ch-user { margin-top: 8px; color: var(--ink-3); font-size: 15px; }
.letter .postmark { width: 92px; height: 92px; top: 26px; right: 26px; }
.letter .postmark b { font-size: 16px; }
.letter .postmark small { font-size: 11px; }
@media (max-width: 600px) { .ch-head { flex-direction: column; align-items: flex-start; padding-right: 0; } .letter .postmark { width: 76px; height: 76px; top: 20px; } }
.ch-actions { display: flex; flex-wrap: wrap; gap: 10px; margin: 26px 0 6px; align-items: center; }
.ch-stats { display: flex; flex-wrap: wrap; gap: 0; margin: 24px 0 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.ch-stats div { flex: 1; min-width: 120px; padding: 14px 16px 14px 0; }
.ch-stats div + div { padding-left: 16px; border-left: 1px solid var(--line); }
.ch-stats dt { font-size: 13px; color: var(--ink-3); }
.ch-stats dd { margin: 2px 0 0; font: 600 20px/1.2 var(--display); font-variant-numeric: tabular-nums; }
.ch-desc { font-size: 17px; line-height: 1.65; margin-top: 26px; max-width: 68ch; }
.ch-about { margin-top: 26px; padding: 18px 20px; background: var(--paper); border-radius: var(--radius-sm); border-left: 3px solid var(--blue); }
.ch-about h2 { font-size: 15px; margin-bottom: 8px; }
.ch-about p { white-space: pre-line; margin: 0; color: var(--ink-2); font-size: 15px; }
.side-box { background: var(--card); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); margin-bottom: 16px; }
.side-box h2 { font-size: 16px; margin-bottom: 14px; }
.mini { display: flex; gap: 12px; align-items: center; padding: 10px 0; border-top: 1px solid var(--line); text-decoration: none; color: var(--ink); }
.mini:first-of-type { border-top: 0; padding-top: 0; }
.mini .ava { width: 40px; height: 40px; }
.mini .ava--ph { font-size: 14px; }
.mini-t { font-weight: 600; font-size: 14.5px; line-height: 1.3; overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; }
.mini-s { font-size: 13px; color: var(--ink-3); }
.mini:hover .mini-t { color: var(--blue); }
.owner-bar { background: var(--blue-soft); color: var(--blue-ink); border-radius: var(--radius-sm); padding: 12px 16px; margin-bottom: 16px; font-size: 14.5px; display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }

/* ---------- Формы ---------- */
.form { display: grid; gap: 18px; }
.form-card { background: var(--card); border-radius: var(--radius); padding: 30px; box-shadow: var(--shadow); max-width: 680px; }
@media (max-width: 600px) { .form-card { padding: 22px 18px; } }
.form-group { border: 0; padding: 0; margin: 0; display: grid; gap: 14px; }
.form-group legend { font: 600 16px var(--display); margin-bottom: 10px; }
.field { display: grid; gap: 6px; }
.field > span { font-weight: 600; font-size: 14.5px; }
.field input, .field select, .field textarea {
  width: 100%; border: 1px solid var(--line-2); border-radius: 8px; background: var(--card); color: var(--ink);
  font: inherit; font-size: 15.5px; padding: 11px 13px; }
.field textarea { min-height: 120px; resize: vertical; line-height: 1.5; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px var(--blue-soft); }
.field .hint { font-size: 13.5px; color: var(--ink-3); }
.field .err { font-size: 13.5px; color: var(--red); }
.field.has-err input, .field.has-err select, .field.has-err textarea { border-color: var(--red); }
.check { display: flex; gap: 10px; align-items: flex-start; font-size: 15px; cursor: pointer; }
.check input { width: 18px; height: 18px; margin-top: 2px; accent-color: var(--blue); }
.radio { display: flex; gap: 8px; align-items: center; cursor: pointer; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media (max-width: 600px) { .grid-2 { grid-template-columns: 1fr; } }
.hp { position: absolute; left: -9999px; }

.note { padding: 12px 16px; border-radius: 8px; font-size: 15px; margin-bottom: 16px; }
.note--ok { background: var(--green-soft); color: var(--green); }
.note--error { background: var(--red-soft); color: var(--red); }
.note--info { background: var(--blue-soft); color: var(--blue-ink); }

.auth { max-width: 440px; margin: 48px auto 70px; }
.auth h1 { font-size: 28px; margin-bottom: 8px; }
.auth .lead { color: var(--ink-2); margin-bottom: 24px; }
.auth .switch { margin-top: 18px; font-size: 15px; color: var(--ink-2); }

.code { font: 600 18px/1 ui-monospace, "SF Mono", Menlo, monospace; background: var(--paper); border: 1px dashed var(--line-2); border-radius: 8px; padding: 12px 16px; display: inline-block; letter-spacing: .02em; user-select: all; }

/* Кабинет */
.table-wrap { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); overflow-x: auto; }
.tbl { width: 100%; border-collapse: collapse; font-size: 14.5px; }
.tbl th, .tbl td { text-align: left; padding: 12px 14px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.tbl th { font-weight: 600; color: var(--ink-3); font-size: 13px; background: var(--paper); }
.tbl tr:last-child td { border-bottom: 0; }
.tbl .ava { width: 36px; height: 36px; }
.tbl .ava--ph { font-size: 13px; }
.badge { display: inline-block; font-size: 12.5px; font-weight: 600; padding: 3px 9px; border-radius: 999px; background: var(--paper-2); color: var(--ink-2); white-space: nowrap; }
.badge--active { background: var(--green-soft); color: var(--green); }
.badge--pending { background: #FFF2CC; color: #8A6200; }
.badge--rejected { background: var(--red-soft); color: var(--red); }
:root[data-theme="dark"] .badge--pending { background: #3A3216; color: var(--yellow); }

.empty { text-align: center; padding: 56px 20px; background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); color: var(--ink-2); }
.empty h2 { color: var(--ink); margin-bottom: 10px; }

/* CTA */
.cta { display: grid; grid-template-columns: 1fr auto; gap: 24px; align-items: center; background: var(--ink); color: var(--paper); border-radius: var(--radius); padding: 34px 36px; margin: 20px 0 50px; position: relative; overflow: hidden; }
.cta::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 8px; background: var(--stripes); }
.cta h2 { color: var(--paper); margin-bottom: 8px; }
.cta p { margin: 0; opacity: .8; max-width: 52ch; }
.cta .btn--primary { background: var(--yellow); border-color: var(--yellow); color: #1B1F3B; }
.cta .btn--primary:hover { background: #FFD45A; border-color: #FFD45A; color: #1B1F3B; }
@media (max-width: 700px) { .cta { grid-template-columns: 1fr; padding: 26px 22px 30px; } }

/* Подвал */
.foot { border-top: 1px solid var(--line); padding: 34px 0 40px; margin-top: 30px; color: var(--ink-3); font-size: 14px; }
.foot-in { display: flex; flex-wrap: wrap; gap: 24px 40px; justify-content: space-between; }
.foot nav { display: flex; flex-wrap: wrap; gap: 8px 22px; }
.foot a { color: var(--ink-2); text-decoration: none; }
.foot a:hover { color: var(--blue); }

.prose { max-width: 72ch; background: var(--card); border-radius: var(--radius); padding: 30px 34px; box-shadow: var(--shadow); margin-bottom: 40px; }
.prose h2 { font-size: 20px; margin: 26px 0 10px; }
.prose ul { padding-left: 20px; }
.prose li { margin-bottom: 6px; }

.toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); background: var(--ink); color: var(--paper); padding: 11px 18px; border-radius: 999px; font-size: 14.5px; z-index: 99; box-shadow: var(--shadow); }

/* Установщик */
.install { padding: 40px 16px; }
.install-box { max-width: 620px; margin: 0 auto; background: var(--card); border-radius: var(--radius); padding: 32px; box-shadow: var(--shadow); }
.install-box::before { content: ""; display: block; height: 8px; margin: -32px -32px 26px; background: var(--stripes); border-radius: var(--radius) var(--radius) 0 0; }
.install-title { margin-bottom: 20px; font-size: 28px; }
.install-steps li { margin-bottom: 12px; }
.install-steps code { word-break: break-all; }

@media (max-width: 600px) {
  .ch-stats { display: grid; grid-template-columns: 1fr 1fr; }
  .ch-stats div, .ch-stats div + div { padding: 12px 0 12px 14px; border-left: 0; }
  .ch-stats div:nth-child(odd) { padding-left: 0; border-right: 1px solid var(--line); }
  .ch-stats div:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
}

/* =========================================================
   Обновление 2: кнопки, продвижение, ленты, графики
   ========================================================= */
:root { --gold: #E3A008; --gold-soft: #FFF4D6; --press: #16239A; }
:root[data-theme="dark"] { --gold: #F4C43B; --gold-soft: #3A3216; --press: #4352C9; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --gold: #F4C43B; --gold-soft: #3A3216; --press: #4352C9; } }

/* Кнопка-штамп: твёрдая тень, при нажатии «вдавливается» */
.btn-press { box-shadow: 0 4px 0 var(--press); transform: translateY(0); transition: transform .08s, box-shadow .08s, background .15s; }
.btn-press:hover { transform: translateY(-1px); box-shadow: 0 5px 0 var(--press); }
.btn-press:active { transform: translateY(4px); box-shadow: 0 0 0 var(--press); }
.btn-press:not(.btn--primary) { box-shadow: 0 3px 0 var(--line-2); }
.btn-press:not(.btn--primary):active { box-shadow: 0 0 0 var(--line-2); transform: translateY(3px); }
.btn:disabled { opacity: .55; cursor: not-allowed; transform: none; box-shadow: none; }

/* «Открыть в Telegram»: самолётик улетает и возвращается */
.btn-tg { overflow: hidden; position: relative; }
.btn-tg .plane { transition: transform .35s cubic-bezier(.5, -0.4, .5, 1.4); }
.btn-tg:hover .plane { animation: fly .9s ease-in-out; }
@keyframes fly { 0% { transform: none; } 45% { transform: translate(26px, -22px) rotate(-12deg); opacity: 0; } 46% { transform: translate(-26px, 22px); opacity: 0; } 100% { transform: none; opacity: 1; } }
.card-foot .btn-tg { gap: 7px; }

/* Лайк: сердце «пружинит» и разлетается искрами */
.icon-btn { position: relative; transition: transform .12s, border-color .15s, background .15s; }
.icon-btn:active { transform: scale(.9); }
.icon-btn.pop svg { animation: pop .45s cubic-bezier(.3, 1.6, .5, 1); }
@keyframes pop { 0% { transform: scale(1); } 40% { transform: scale(1.45); } 100% { transform: scale(1); } }
.burst { position: absolute; left: 50%; top: 50%; width: 4px; height: 4px; margin: -2px; border-radius: 50%; pointer-events: none; opacity: 0; }
.icon-btn.pop .burst { animation: burst .6s ease-out; }
@keyframes burst {
  0% { opacity: 1; box-shadow: 0 0 0 var(--red), 0 0 0 var(--yellow), 0 0 0 var(--blue), 0 0 0 var(--red), 0 0 0 var(--yellow), 0 0 0 var(--blue); }
  100% { opacity: 0; box-shadow: 0 -22px 0 var(--red), 19px -11px 0 var(--yellow), 19px 11px 0 var(--blue), 0 22px 0 var(--red), -19px 11px 0 var(--yellow), -19px -11px 0 var(--blue); }
}
.icon-btn.is-fav.pop svg { animation: drop-in .4s ease-out; }
@keyframes drop-in { 0% { transform: translateY(-6px); } 60% { transform: translateY(2px); } 100% { transform: none; } }

/* Кубик «случайный канал» */
.dice svg { width: 20px; height: 20px; display: block; transition: transform .5s cubic-bezier(.3, 1.5, .5, 1); }
.dice:hover svg { transform: rotate(200deg) scale(1.1); }
.chip--dice .dice-ico { display: inline-block; transition: transform .5s cubic-bezier(.3, 1.5, .5, 1); }
.chip--dice:hover .dice-ico { transform: rotate(-360deg); }
.chip--dice { border-style: dashed; }

/* Кнопка «наверх» — самолётик */
.to-top { position: fixed; right: 20px; bottom: 22px; width: 50px; height: 50px; border-radius: 50%; border: 0; background: var(--blue); color: #fff; cursor: pointer; display: grid; place-items: center; z-index: 40; box-shadow: 0 4px 0 var(--press), 0 10px 24px -10px rgba(36, 56, 198, .7); transition: transform .15s; }
.to-top svg { width: 22px; height: 22px; transform: rotate(-45deg) translate(-1px, 1px); transition: transform .3s; }
.to-top:hover svg { transform: rotate(-45deg) translate(3px, -3px); }
.to-top:active { transform: translateY(4px); box-shadow: 0 0 0 var(--press); }
.to-top.launch svg { animation: launch .6s ease-in forwards; }
@keyframes launch { to { transform: rotate(-45deg) translate(40px, -40px); opacity: 0; } }

/* Телеграфная лента */
.ticker { display: flex; align-items: stretch; background: var(--ink); color: var(--paper); font-size: 14px; overflow: hidden; }
.ticker-label { flex-shrink: 0; background: var(--yellow); color: #1B1F3B; font: 600 13px/1 var(--display); padding: 11px 14px; display: flex; align-items: center; }
.ticker-track { overflow: hidden; flex: 1; mask-image: linear-gradient(90deg, transparent, #000 4%, #000 96%, transparent); }
.ticker-move { display: inline-flex; align-items: center; white-space: nowrap; padding: 10px 0; animation: tape 60s linear infinite; }
.ticker:hover .ticker-move { animation-play-state: paused; }
.ticker a { color: inherit; text-decoration: none; padding: 0 12px; }
.ticker a:hover { color: var(--yellow); }
.tick-dot { color: var(--yellow); opacity: .7; }
@keyframes tape { to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) { .ticker-move { animation: none; } .btn-tg:hover .plane, .icon-btn.pop svg, .icon-btn.pop .burst { animation: none; } }

/* Канал дня */
.spot { display: grid; grid-template-columns: auto 1fr auto; gap: 24px; align-items: center; background: linear-gradient(120deg, var(--gold-soft), var(--card) 60%); border: 2px solid var(--gold); border-radius: var(--radius); padding: 26px 28px; margin: 10px 0 20px; box-shadow: var(--shadow); position: relative; overflow: hidden; }
.spot-sun { font-size: 46px; line-height: 1; }
@media (prefers-reduced-motion: no-preference) { .spot-sun { animation: spin 18s linear infinite; } @keyframes spin { to { transform: rotate(360deg); } } }
.spot-kicker { font: 600 13px/1 var(--display); color: var(--gold); margin-bottom: 10px; }
.spot-main { display: flex; gap: 18px; align-items: center; }
.spot h2 { font-size: clamp(20px, 2.6vw, 28px); }
.spot h2 a { color: var(--ink); text-decoration: none; }
.spot h2 a:hover { color: var(--blue); }
.spot-meta { color: var(--ink-3); font-size: 14.5px; margin: 4px 0 8px; }
.spot p { margin: 0; color: var(--ink-2); max-width: 70ch; }
.spot-actions { display: flex; flex-direction: column; align-items: center; gap: 8px; }
.spot-ad { font-size: 12px; color: var(--ink-3); }
.ava--xl { width: 84px !important; height: 84px !important; }
@media (max-width: 800px) { .spot { grid-template-columns: 1fr; } .spot-sun { position: absolute; right: 16px; top: 14px; font-size: 32px; } .spot-main { flex-direction: column; align-items: flex-start; } .spot-actions { align-items: stretch; } }

/* Метки продвижения на карточках */
.card.is-vip { box-shadow: inset 0 0 0 2px var(--gold), 0 10px 30px -14px rgba(227, 160, 8, .55); background: linear-gradient(180deg, var(--gold-soft), var(--card) 46%); }
.card.is-top { box-shadow: inset 0 0 0 2px var(--blue), var(--shadow); }
.card.is-ad { box-shadow: inset 0 0 0 1px var(--line-2), var(--shadow); background: repeating-linear-gradient(135deg, var(--card) 0 14px, var(--paper) 14px 15px); }
.card.is-featured { box-shadow: inset 0 0 0 2px var(--blue), var(--shadow); }
.card .ribbon { position: absolute; left: 16px; top: -10px; z-index: 3; }
.card:has(.ribbon) { margin-top: 10px; }
.ribbon, .ribbon-inline { display: inline-flex; align-items: center; gap: 4px; font: 600 12px/1 var(--text); padding: 5px 9px; border-radius: 6px; white-space: nowrap; }
.ribbon--top { background: var(--blue); color: #fff; }
.ribbon--vip { background: var(--gold); color: #1B1F3B; }
.ribbon--ad { background: var(--ink); color: var(--paper); }
.ch-badges { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 8px; }
.ch-badges:empty { display: none; }
.letter.is-vip { box-shadow: 0 0 0 2px var(--gold), var(--shadow); }
.tag-18 { display: inline-block; font: 700 11px/1 var(--display); color: #fff; background: var(--red); border-radius: 5px; padding: 3px 5px; vertical-align: middle; }
.tag-18--big { font-size: 14px; padding: 5px 8px; vertical-align: middle; }
.card-tags { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-top: 12px; position: relative; z-index: 2; }
.card-tags:empty { display: none; }
.card-tags .card-cat { margin-top: 0; }
.growth { font-size: 13px; font-weight: 600; color: var(--green); background: var(--green-soft); border-radius: 999px; padding: 4px 10px; }
.up { color: var(--green); }
.down { color: var(--red); }

/* Подсказки поиска */
.top-search, .hero-search { position: relative; }
.suggest { position: absolute; left: 0; right: 0; top: calc(100% + 6px); background: var(--card); border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 20px 40px -18px rgba(27, 31, 59, .45); z-index: 60; padding: 6px; max-height: 70vh; overflow: auto; }
.hero-search .suggest { right: 120px; }
.suggest a { display: flex; gap: 10px; align-items: center; padding: 8px 10px; border-radius: 8px; text-decoration: none; color: var(--ink); }
.suggest a:hover, .suggest a[aria-selected="true"] { background: var(--paper); }
.suggest .ava { width: 34px; height: 34px; }
.suggest .ava--ph { font-size: 12px; }
.suggest .s-t { font-weight: 600; font-size: 14.5px; display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.suggest .s-s { font-size: 13px; color: var(--ink-3); }
.suggest .s-cat { font-size: 14px; }
.suggest .s-all { justify-content: center; color: var(--blue); font-weight: 600; font-size: 14px; border-top: 1px solid var(--line); border-radius: 0 0 8px 8px; margin-top: 4px; }
.suggest .s-empty { padding: 12px; color: var(--ink-3); font-size: 14px; }

/* 18+ */
.gate { max-width: 560px; margin: 60px auto 80px; text-align: center; background: var(--card); border-radius: var(--radius); padding: 40px 30px; box-shadow: var(--shadow); }
.gate-badge { width: 92px; height: 92px; margin: 0 auto 20px; border-radius: 50%; border: 3px dashed var(--red); color: var(--red); display: grid; place-items: center; font: 700 28px var(--display); transform: rotate(-10deg); }
.gate h1 { font-size: 26px; margin-bottom: 12px; }
.gate p { color: var(--ink-2); }
.gate-btns { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin-top: 22px; }

/* Загрузка картинки */
.drop { display: flex; gap: 16px; align-items: center; border: 2px dashed var(--line-2); border-radius: 10px; padding: 14px 16px; cursor: pointer; position: relative; transition: border-color .15s, background .15s; }
.drop:hover, .drop.over { border-color: var(--blue); background: var(--blue-soft); }
.drop input[type=file] { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.drop-preview { width: 64px; height: 64px; border-radius: 50%; background: var(--paper-2) center / cover no-repeat; flex-shrink: 0; display: grid; place-items: center; }
.drop-preview:not([style])::before { content: "🖼"; font-size: 24px; }
.drop-text { font-size: 14.5px; color: var(--ink-2); }
.drop-text b { color: var(--blue); }
.drop-text small { color: var(--ink-3); }
.linkbtn { border: 0; background: none; padding: 0; color: var(--blue); font: inherit; font-size: 14px; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; justify-self: start; }
.price-note { font-size: 14px; font-weight: 600; color: #8A6200; background: #FFF2CC; border-radius: 8px; padding: 8px 12px; }
:root[data-theme="dark"] .price-note { background: #3A3216; color: var(--yellow); }

/* Кабинет */
.btns-row { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.my-grid { display: grid; grid-template-columns: minmax(0, 680px) 330px; gap: 24px; align-items: start; }
@media (max-width: 1060px) { .my-grid { grid-template-columns: 1fr; } }
.mini-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 0 0 12px; }
.mini-stats dt { font-size: 13px; color: var(--ink-3); }
.mini-stats dd { margin: 2px 0 0; font: 600 22px var(--display); }
.spark { width: 100%; height: 56px; color: var(--blue); display: block; }
.spark-wrap { border-top: 1px solid var(--line); padding-top: 10px; }
.promo-line { display: flex; justify-content: space-between; gap: 10px; align-items: center; padding: 9px 0; border-top: 1px solid var(--line); font-size: 14.5px; color: var(--ink); text-decoration: none; }
.promo-line:first-of-type { border-top: 0; }
a.promo-line:hover { color: var(--blue); }
.growth-box { margin-top: 20px; color: var(--blue); }
.growth-head { display: flex; justify-content: space-between; font-size: 14px; color: var(--ink-3); margin-bottom: 6px; }
.growth-box .spark { height: 70px; }
.report { margin-top: 26px; border-top: 1px solid var(--line); padding-top: 14px; }
.report summary { cursor: pointer; color: var(--ink-3); font-size: 14px; }
.report summary:hover { color: var(--red); }
.side-ad { position: relative; }
.side-ad-label { position: absolute; top: 12px; right: 14px; font-size: 11.5px; color: var(--ink-3); }
.cta-btns { display: flex; gap: 10px; flex-wrap: wrap; }
.btn--ghost-light { background: transparent; color: var(--paper); border-color: rgba(255, 255, 255, .35); }
.btn--ghost-light:hover { color: var(--paper); border-color: var(--paper); background: rgba(255, 255, 255, .06); }

/* Продвижение: «билеты» */
.promo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 18px; margin-bottom: 26px; }
.ticket { background: var(--card); border-radius: 14px; box-shadow: var(--shadow); display: flex; flex-direction: column; position: relative; transition: transform .2s; }
.ticket:hover { transform: translateY(-3px) rotate(-.4deg); }
.ticket-top { padding: 22px 22px 18px; flex: 1; }
.ticket-ico { font-size: 34px; margin-bottom: 10px; }
.ticket h2 { font-size: 18px; margin-bottom: 8px; }
.ticket p { color: var(--ink-2); font-size: 14.5px; margin: 0; }
.ticket-active { color: var(--green) !important; font-weight: 600; margin-top: 10px !important; }
.ticket-cut { height: 0; border-top: 2px dashed var(--line-2); margin: 0 14px; position: relative; }
.ticket-cut::before, .ticket-cut::after { content: ""; position: absolute; top: -11px; width: 20px; height: 20px; border-radius: 50%; background: var(--paper); }
.ticket-cut::before { left: -25px; }
.ticket-cut::after { right: -25px; }
.ticket-prices { list-style: none; margin: 0; padding: 14px 22px 20px; }
.ticket-prices li { display: flex; justify-content: space-between; padding: 6px 0; font-size: 15px; }
.ticket-prices b { font-family: var(--display); }
.ticket--top { border-top: 6px solid var(--blue); }
.ticket--vip { border-top: 6px solid var(--gold); }
.ticket--bump { border-top: 6px solid #6B5CF0; }
.ticket--spot { border-top: 6px solid var(--yellow); }
.ticket--ad { border-top: 6px solid var(--ink); }
.ticket--free { border-top: 6px solid var(--green); }
.ticket-buy { display: grid; gap: 8px; padding: 16px 18px 20px; }
.buy { width: 100%; display: flex; justify-content: space-between; align-items: center; border: 1px solid var(--line-2); background: var(--paper); color: var(--ink); border-radius: 10px; padding: 12px 14px; font: 500 15px var(--text); cursor: pointer; }
.buy b { font-family: var(--display); color: var(--blue); }
.buy:hover { border-color: var(--blue); background: var(--blue-soft); }
.promo-pick { max-width: none; margin-bottom: 20px; }
.promo-pick h2 { margin-bottom: 10px; }
.free-promo { max-width: none; margin-bottom: 20px; }
.free-promo h2 { font-size: 17px; }

/* Чек заказа */
.receipt { max-width: 620px; background: var(--card); border-radius: 12px 12px 0 0; padding: 28px 28px 30px; box-shadow: var(--shadow); margin: 10px 0 16px; position: relative; }
.receipt::after { content: ""; position: absolute; left: 0; right: 0; bottom: -9px; height: 10px; background: radial-gradient(circle 9px at 9px 0, var(--card) 98%, transparent) 0 0 / 18px 10px repeat-x; }
.receipt-head { display: flex; gap: 14px; align-items: center; margin-bottom: 18px; }
.receipt-ico { font-size: 34px; }
.receipt h1 { font-size: 24px; }
.receipt-lines { margin: 0 0 20px; }
.receipt-lines div { display: flex; justify-content: space-between; gap: 16px; padding: 10px 0; border-bottom: 1px dashed var(--line-2); }
.receipt-lines dt { color: var(--ink-3); }
.receipt-lines dd { margin: 0; text-align: right; }
.receipt-lines .total dd { font: 700 22px var(--display); }
.pay-box { background: var(--paper); border-radius: 10px; padding: 18px 20px; margin-bottom: 16px; }
.pay-box h2 { font-size: 17px; margin-bottom: 8px; }
.badge--unpaid { background: #FFF2CC; color: #8A6200; }

/* Меню аккаунта в шапке */
.top-search { min-width: 200px; }
.acct { position: relative; }
.acct summary { list-style: none; display: flex; align-items: center; gap: 8px; padding: 5px 10px 5px 5px; border-radius: 999px; cursor: pointer; color: var(--ink-2); font-weight: 500; font-size: 15px; }
.acct summary::-webkit-details-marker { display: none; }
.acct summary:hover, .acct[open] summary { background: var(--paper); color: var(--ink); }
.acct-ava { width: 30px; height: 30px; border-radius: 50%; background: var(--blue); color: #fff; display: grid; place-items: center; font: 600 13px var(--display); }
.acct-name { max-width: 110px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.acct-menu { position: absolute; right: 0; top: calc(100% + 8px); background: var(--card); border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 20px 40px -18px rgba(27, 31, 59, .45); padding: 6px; min-width: 200px; display: grid; z-index: 70; }
.acct-menu a, .acct-menu button { display: block; text-align: left; padding: 9px 12px !important; border-radius: 8px; color: var(--ink) !important; text-decoration: none; font: 500 15px var(--text); background: none; border: 0; cursor: pointer; width: 100%; }
.acct-menu a:hover, .acct-menu button:hover { background: var(--paper) !important; }
.acct-menu form { border-top: 1px solid var(--line); margin-top: 4px; padding-top: 4px; }
@media (max-width: 1140px) { .acct-menu { position: static; box-shadow: none; border: 0; padding: 0 0 0 10px; } .acct-name { max-width: none; } }
a.icon-btn { text-decoration: none; }
.side-ad .mini { padding-right: 56px; }
input[type=number].select { background-image: none; padding-right: 10px; }

.top-search .suggest { right: auto; width: min(400px, 90vw); }
.ticker-track { min-width: 0; }
.hero > div { min-width: 0; }
html, body { overflow-x: clip; }

/* Онлайн-оплата */
.pay-btn { width: 100%; }
.pay-wait { display: flex; gap: 14px; align-items: center; background: var(--blue-soft); color: var(--ink); border-radius: 10px; padding: 14px 16px; margin-bottom: 14px; font-size: 14.5px; }
.spinner { width: 26px; height: 26px; border-radius: 50%; border: 3px solid var(--line-2); border-top-color: var(--blue); flex-shrink: 0; animation: spin360 .8s linear infinite; }
@keyframes spin360 { to { transform: rotate(360deg); } }

/* ===== Форма «Добавить канал» ===== */
.add-layout { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 28px; align-items: start; }
@media (max-width: 1000px) { .add-layout { grid-template-columns: 1fr; } .add-preview { order: -1; position: static !important; } .preview-check { display: none; } }
.add-steps { display: grid; gap: 14px; }
.step { display: grid; grid-template-columns: 40px 1fr; gap: 16px; background: var(--card); border-radius: var(--radius); padding: 22px 24px; box-shadow: var(--shadow); border: 1px solid transparent; transition: border-color .15s; }
.step:focus-within { border-color: var(--blue); }
.step.has-err { border-color: var(--red); }
@media (max-width: 600px) { .step { grid-template-columns: 1fr; padding: 18px 16px; gap: 10px; } .step-n { width: 30px !important; height: 30px !important; font-size: 14px !important; } }
.step-n { width: 40px; height: 40px; border-radius: 50%; border: 2px dashed var(--stamp); color: var(--blue); display: grid; place-items: center; font: 700 17px var(--display); transform: rotate(-8deg); }
.step:focus-within .step-n { background: var(--blue); color: #fff; border-style: solid; border-color: var(--blue); }
.step-body { min-width: 0; display: grid; gap: 10px; }
.step-title { font: 600 17px var(--display); }
.step-title-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.inp { width: 100%; border: 1px solid var(--line-2); border-radius: 10px; background: var(--card); color: var(--ink); font: inherit; font-size: 16px; padding: 12px 14px; }
textarea.inp { resize: vertical; line-height: 1.55; min-height: 120px; }
.inp:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px var(--blue-soft); }
.field-foot { display: flex; justify-content: space-between; gap: 12px; font-size: 13.5px; }
.field-foot .hint { color: var(--ink-3); }
.field-foot .err { color: var(--red); }
.counter { color: var(--ink-3); font-variant-numeric: tabular-nums; white-space: nowrap; }
.counter.warn { color: #B26B00; }
.step .err { font-size: 13.5px; color: var(--red); }

.link-row { display: flex; gap: 10px; }
.link-input { flex: 1; position: relative; min-width: 0; }
.link-input svg { position: absolute; left: 14px; top: 50%; width: 20px; height: 20px; margin-top: -10px; color: var(--blue); }
.link-input input { width: 100%; height: 52px; border: 1px solid var(--line-2); border-radius: 12px; background: var(--paper); color: var(--ink); font: 500 17px var(--text); padding: 0 14px 0 44px; }
.link-input input:focus { outline: none; border-color: var(--blue); background: var(--card); box-shadow: 0 0 0 3px var(--blue-soft); }
.link-row .btn { height: 52px; border-radius: 12px; }
.lookup { font-size: 14.5px; display: grid; gap: 6px; min-height: 22px; }
.lookup-ok { color: var(--green); font-weight: 600; }
.lookup-err { color: var(--red); }
.lookup-warn { background: #FFF2CC; color: #6B4C00; border-radius: 8px; padding: 8px 12px; }
:root[data-theme="dark"] .lookup-warn { background: #3A3216; color: var(--yellow); }
.spinner--sm { width: 14px; height: 14px; border-width: 2px; display: inline-block; vertical-align: -2px; margin-right: 6px; }

.photo-drop { display: flex; gap: 18px; align-items: center; border: 2px dashed var(--line-2); border-radius: 14px; padding: 16px 18px; cursor: pointer; position: relative; transition: border-color .15s, background .15s; }
.photo-drop:hover, .photo-drop.over { border-color: var(--blue); background: var(--blue-soft); }
.photo-drop input[type=file] { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.photo-circle { width: 88px; height: 88px; border-radius: 50%; background: var(--paper-2) center / cover no-repeat; flex-shrink: 0; display: grid; place-items: center; box-shadow: inset 0 0 0 1px var(--line); }
.photo-circle.has-img .photo-plus, .photo-circle[style*="data:"] .photo-plus { display: none; }
.photo-plus { font-size: 30px; color: var(--ink-3); }

.cat-search { height: 36px; border: 1px solid var(--line-2); border-radius: 999px; background: var(--paper); color: var(--ink); padding: 0 14px; font: inherit; font-size: 14px; width: 200px; }
.cat-search:focus { outline: none; border-color: var(--blue); }
.cat-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 8px; max-height: 330px; overflow: auto; padding: 2px; position: relative; }
.cat-tile { display: flex; align-items: center; gap: 8px; padding: 10px 12px; border: 1px solid var(--line-2); border-radius: 10px; cursor: pointer; font-size: 14.5px; background: var(--card); position: relative; transition: border-color .12s, background .12s, transform .1s; }
.cat-tile:hover { border-color: var(--blue); }
.cat-tile:active { transform: scale(.98); }
.cat-tile input { position: absolute; opacity: 0; pointer-events: none; }
.cat-tile:has(input:checked) { background: var(--blue); border-color: var(--blue); color: #fff; box-shadow: 0 3px 0 var(--press); }
.cat-tile:has(input:focus-visible) { outline: 3px solid var(--yellow); outline-offset: 2px; }
.cat-tile-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cat-price { font-size: 12px; font-weight: 600; background: #FFF2CC; color: #8A6200; border-radius: 6px; padding: 2px 6px; white-space: nowrap; }
.cat-tile:has(input:checked) .cat-price { background: rgba(255, 255, 255, .2); color: #fff; }
.cat-none { grid-column: 1 / -1; margin: 6px 0; }

.step--extra { display: block; padding: 16px 24px; }
.step--extra summary { cursor: pointer; color: var(--ink-2); font-weight: 500; }
.add-submit { background: var(--card); border-radius: var(--radius); padding: 22px 24px; box-shadow: var(--shadow); display: grid; gap: 12px; }
.add-total { font-size: 16px; }
.add-total b { font-family: var(--display); }
.add-submit .btn { width: 100%; }
.add-rules { font-size: 13.5px; margin: 0; }

.add-preview { position: sticky; top: 96px; }
.preview-label { font: 600 13px var(--display); color: var(--ink-3); margin-bottom: 10px; }
.card--preview { pointer-events: none; }
.card--preview .card-title { -webkit-line-clamp: 2; }
.card-text.muted { color: var(--ink-3); font-style: italic; }
.preview-check { list-style: none; margin: 16px 0 0; padding: 16px 18px; background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); display: grid; gap: 8px; font-size: 14.5px; }
.preview-check li { display: flex; gap: 10px; align-items: center; color: var(--ink-3); }
.preview-check li::before { content: ""; width: 18px; height: 18px; border-radius: 50%; border: 2px solid var(--line-2); flex-shrink: 0; transition: all .2s; }
.preview-check li.ok { color: var(--ink); }
.preview-check li.ok::before { background: var(--green) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3.5'%3E%3Cpath d='m5 12 5 5 9-10'/%3E%3C/svg%3E") center / 12px no-repeat; border-color: var(--green); }
@media (max-width: 1000px) { .add-layout .add-preview { order: 0; position: static; } .add-layout .preview-check { display: none; } }

.lookup-info { background: var(--blue-soft); color: var(--blue-ink); border-radius: 8px; padding: 8px 12px; }
.lock { font-size: 12px; }

/* ===== Разделы: цветные плитки ===== */
.cat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 12px; }
.cat-grid.is-collapsed .cat-card--more { display: none; }
.cat-card { --bg: hsl(var(--h) 85% 96%); --bubble: hsl(var(--h) 80% 88%); --ink-h: hsl(var(--h) 55% 30%);
  display: flex; align-items: center; gap: 14px; padding: 14px 16px; border-radius: 14px; background: var(--bg); color: var(--ink); text-decoration: none;
  border: 1px solid hsl(var(--h) 60% 88%); position: relative; overflow: hidden; transition: transform .18s cubic-bezier(.3, 1.4, .5, 1), box-shadow .18s, border-color .18s; }
.cat-card::after { content: ""; position: absolute; right: -18px; bottom: -18px; width: 64px; height: 64px; border-radius: 50%; border: 2px dashed hsl(var(--h) 60% 78%); opacity: .6; transform: rotate(-12deg); transition: transform .4s; }
.cat-card:hover { transform: translateY(-3px); box-shadow: 0 4px 0 hsl(var(--h) 55% 78%), 0 14px 26px -16px hsl(var(--h) 60% 40% / .6); border-color: hsl(var(--h) 60% 75%); color: var(--ink); }
.cat-card:hover::after { transform: rotate(40deg) scale(1.1); }
.cat-card:active { transform: translateY(1px); box-shadow: none; }
.cat-card-ico { width: 48px; height: 48px; border-radius: 14px; background: var(--bubble); display: grid; place-items: center; font-size: 24px; flex-shrink: 0; transform: rotate(-4deg); transition: transform .3s cubic-bezier(.3, 1.6, .5, 1); }
.cat-card:hover .cat-card-ico { transform: rotate(8deg) scale(1.12); }
.cat-card-body { display: grid; gap: 2px; min-width: 0; position: relative; z-index: 1; }
.cat-card-name { font: 600 15.5px/1.25 var(--display); letter-spacing: -.01em; }
.cat-card-cnt { font-size: 13.5px; color: var(--ink-h); font-variant-numeric: tabular-nums; }
.cat-more { display: flex; justify-content: center; margin-top: 18px; }
:root[data-theme="dark"] .cat-card { --bg: hsl(var(--h) 30% 17%); --bubble: hsl(var(--h) 35% 26%); --ink-h: hsl(var(--h) 60% 75%); border-color: hsl(var(--h) 30% 24%); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .cat-card { --bg: hsl(var(--h) 30% 17%); --bubble: hsl(var(--h) 35% 26%); --ink-h: hsl(var(--h) 60% 75%); border-color: hsl(var(--h) 30% 24%); } }
@media (max-width: 520px) { .cat-grid { grid-template-columns: 1fr 1fr; gap: 8px; } .cat-card { flex-direction: column; align-items: flex-start; gap: 10px; padding: 12px; } .cat-card-ico { width: 40px; height: 40px; font-size: 20px; } .cat-card-name { font-size: 14px; } }
@media (prefers-reduced-motion: reduce) { .cat-card, .cat-card-ico, .cat-card::after { transition: none; } }

/* ===== Чат поддержки ===== */
.sup { position: fixed; left: 20px; bottom: 22px; z-index: 80; }
.sup-fab { width: 58px; height: 58px; border-radius: 50%; border: 0; background: var(--blue); color: #fff; cursor: pointer; display: grid; place-items: center; position: relative;
  box-shadow: 0 4px 0 var(--press), 0 12px 28px -10px rgba(36, 56, 198, .7); transition: transform .15s; }
.sup-fab:hover { transform: translateY(-2px) rotate(-4deg); }
.sup-fab:active { transform: translateY(3px); box-shadow: 0 1px 0 var(--press); }
.sup-fab svg { width: 28px; height: 28px; }
.sup-ico-close { display: none; }
.sup.is-open .sup-ico-open { display: none; }
.sup.is-open .sup-ico-close { display: block; }
.sup-badge { position: absolute; top: -4px; right: -4px; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 999px; background: var(--red); color: #fff; font: 700 12px/22px var(--text); border: 2px solid var(--paper); }
@media (prefers-reduced-motion: no-preference) { .sup-badge:not([hidden]) { animation: nudge 2.4s ease-in-out infinite; } @keyframes nudge { 0%, 85%, 100% { transform: none; } 90% { transform: scale(1.25); } } }
.sup-panel { position: absolute; left: 0; bottom: 74px; width: min(380px, calc(100vw - 32px)); height: min(560px, calc(100vh - 120px)); background: var(--card); border-radius: 18px;
  box-shadow: 0 24px 60px -20px rgba(27, 31, 59, .55), 0 0 0 1px var(--line); display: flex; flex-direction: column; overflow: hidden; transform-origin: 30px 100%; }
@media (prefers-reduced-motion: no-preference) { .sup-panel:not([hidden]) { animation: sup-in .22s cubic-bezier(.2, 1.2, .4, 1); } @keyframes sup-in { from { opacity: 0; transform: translateY(14px) scale(.96); } } }
.sup-head { display: flex; align-items: center; gap: 12px; padding: 14px 16px; background: var(--blue); color: #fff; position: relative; }
.sup-head::after { content: ""; position: absolute; left: 0; right: 0; bottom: -6px; height: 6px; background: var(--stripes); }
.sup-head b { display: block; font: 600 15px var(--display); }
.sup-head small { opacity: .8; font-size: 12.5px; }
.sup-ava { width: 38px; height: 38px; border-radius: 50%; background: rgba(255, 255, 255, .18); display: grid; place-items: center; flex-shrink: 0; }
.sup-ava svg { width: 20px; height: 20px; }
.sup-x { margin-left: auto; border: 0; background: rgba(255, 255, 255, .15); color: #fff; width: 32px; height: 32px; border-radius: 50%; cursor: pointer; font-size: 14px; }
.sup-body { flex: 1; overflow-y: auto; padding: 18px 14px 10px; display: flex; flex-direction: column; gap: 8px; background: var(--paper); scroll-behavior: smooth; }
.sup-msg { display: flex; flex-direction: column; max-width: 82%; }
.sup-msg--me { align-self: flex-end; align-items: flex-end; }
.sup-bubble { padding: 9px 13px; border-radius: 16px 16px 16px 4px; background: var(--card); color: var(--ink); font-size: 14.5px; line-height: 1.45; white-space: pre-wrap; overflow-wrap: anywhere; box-shadow: 0 1px 0 var(--line); }
.sup-msg--me .sup-bubble { background: var(--blue); color: #fff; border-radius: 16px 16px 4px 16px; }
:root[data-theme="dark"] .sup-msg--me .sup-bubble { color: #11142A; }
.sup-bubble img { display: block; max-width: 100%; max-height: 260px; border-radius: 10px; margin: 2px 0; cursor: zoom-in; }
.sup-bubble img + span { display: block; margin-top: 6px; }
.sup-time { font-size: 11px; color: var(--ink-3); margin: 3px 6px 0; }
.sup-day { align-self: center; font-size: 12px; color: var(--ink-3); }
.sup-form { border-top: 1px solid var(--line); padding: 10px 12px 12px; display: grid; gap: 8px; background: var(--card); }
.sup-contact { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.sup-contact input { border: 1px solid var(--line-2); border-radius: 10px; padding: 8px 10px; font: inherit; font-size: 14px; background: var(--paper); color: var(--ink); min-width: 0; }
.sup-row { display: flex; align-items: flex-end; gap: 6px; }
.sup-row textarea { flex: 1; border: 1px solid var(--line-2); border-radius: 14px; padding: 10px 12px; font: inherit; font-size: 15px; resize: none; max-height: 120px; background: var(--paper); color: var(--ink); line-height: 1.35; }
.sup-row textarea:focus, .sup-contact input:focus { outline: none; border-color: var(--blue); }
.sup-clip { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; color: var(--ink-3); cursor: pointer; position: relative; flex-shrink: 0; }
.sup-clip:hover { color: var(--blue); background: var(--blue-soft); }
.sup-clip input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.sup-clip svg { width: 21px; height: 21px; }
.sup-send { width: 42px; height: 42px; border-radius: 50%; border: 0; background: var(--blue); color: #fff; cursor: pointer; display: grid; place-items: center; flex-shrink: 0; transition: transform .1s; }
.sup-send:active { transform: scale(.9); }
.sup-send:disabled { opacity: .5; }
.sup-send svg { width: 20px; height: 20px; }
.sup-attach-preview { position: relative; width: 74px; }
.sup-attach-preview img { width: 74px; height: 74px; object-fit: cover; border-radius: 10px; }
.sup-attach-preview button { position: absolute; top: -6px; right: -6px; width: 22px; height: 22px; border-radius: 50%; border: 0; background: var(--ink); color: var(--paper); font-size: 11px; cursor: pointer; }
.sup-err { font-size: 13px; color: var(--red); }
.sup-lightbox { position: fixed; inset: 0; background: rgba(10, 12, 30, .85); z-index: 200; display: grid; place-items: center; padding: 20px; cursor: zoom-out; }
.sup-lightbox img { max-width: 100%; max-height: 100%; border-radius: 10px; }
@media (max-width: 520px) { .sup { left: 14px; bottom: 16px; } .sup-panel { position: fixed; left: 8px; right: 8px; bottom: 86px; width: auto; height: calc(100vh - 110px); } }

/* ===== Страница раздела ===== */
.cat-main { min-width: 0; }
.cat-hero { --bg: hsl(var(--h) 85% 95%); display: flex; align-items: center; gap: 20px; background: var(--bg); border: 1px solid hsl(var(--h) 60% 86%); border-radius: 18px;
  padding: 22px 24px; margin-bottom: 18px; position: relative; overflow: hidden; }
.cat-hero::after { content: ""; position: absolute; right: 170px; top: -30px; width: 120px; height: 120px; border-radius: 50%; border: 2px dashed hsl(var(--h) 55% 78%); transform: rotate(-12deg); opacity: .7; pointer-events: none; }
.cat-hero-ico { width: 72px; height: 72px; border-radius: 20px; background: hsl(var(--h) 80% 86%); display: grid; place-items: center; font-size: 36px; flex-shrink: 0; transform: rotate(-5deg); box-shadow: 0 4px 0 hsl(var(--h) 55% 76%); }
.cat-hero-text { min-width: 0; flex: 1; position: relative; z-index: 1; }
.cat-hero h1 { font-size: clamp(26px, 3.4vw, 38px); }
.cat-hero p { margin: 6px 0 0; color: hsl(var(--h) 35% 30%); max-width: 60ch; }
.cat-hero-btn { flex-shrink: 0; position: relative; z-index: 1; }
:root[data-theme="dark"] .cat-hero { --bg: hsl(var(--h) 30% 16%); border-color: hsl(var(--h) 30% 24%); }
:root[data-theme="dark"] .cat-hero-ico { background: hsl(var(--h) 35% 26%); box-shadow: 0 4px 0 hsl(var(--h) 30% 12%); }
:root[data-theme="dark"] .cat-hero p { color: hsl(var(--h) 50% 80%); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .cat-hero { --bg: hsl(var(--h) 30% 16%); border-color: hsl(var(--h) 30% 24%); } :root:not([data-theme="light"]) .cat-hero-ico { background: hsl(var(--h) 35% 26%); box-shadow: 0 4px 0 hsl(var(--h) 30% 12%); } :root:not([data-theme="light"]) .cat-hero p { color: hsl(var(--h) 50% 80%); } }
@media (max-width: 720px) { .cat-hero { flex-wrap: wrap; padding: 18px; gap: 14px; } .cat-hero-ico { width: 56px; height: 56px; font-size: 28px; } .cat-hero-btn { width: 100%; } .cat-hero::after { right: -30px; } }
.cat-toolbar .filters { margin-bottom: 18px; }

/* Боковое меню разделов */
.side-cats { padding: 12px 8px; scrollbar-width: thin; scrollbar-color: var(--line-2) transparent; }
.side-cats::-webkit-scrollbar { width: 6px; }
.side-cats::-webkit-scrollbar-thumb { background: var(--line-2); border-radius: 6px; }
.side-cats-title { font: 600 13px var(--display); color: var(--ink-3); padding: 2px 10px 8px; }
.side-cats a { display: flex; align-items: center; gap: 10px; padding: 7px 10px; border-radius: 10px; color: var(--ink); font-size: 14.5px; transition: background .12s; }
.side-cats a.is-empty { color: var(--ink-3); }
.side-cats a:hover { background: hsl(var(--h) 85% 95%); color: var(--ink); }
.side-ico { width: 30px; height: 30px; border-radius: 9px; background: hsl(var(--h) 80% 92%); display: grid; place-items: center; font-size: 15px; flex-shrink: 0; transition: transform .2s; }
.side-cats a:hover .side-ico { transform: rotate(-8deg) scale(1.08); }
.side-name { flex: 1; min-width: 0; line-height: 1.25; }
.side-cnt { font-size: 12px; font-weight: 600; color: hsl(var(--h) 45% 35%); background: hsl(var(--h) 80% 93%); border-radius: 999px; padding: 2px 8px; }
.side-cats a[aria-current="page"] { background: hsl(var(--h) 75% 90%); color: var(--ink); font-weight: 600; box-shadow: inset 3px 0 0 hsl(var(--h) 60% 45%); }
.side-cats a[aria-current="page"] .side-ico { background: var(--card); }
:root[data-theme="dark"] .side-cats a:hover, :root[data-theme="dark"] .side-cats a[aria-current="page"] { background: hsl(var(--h) 30% 20%); }
:root[data-theme="dark"] .side-ico, :root[data-theme="dark"] .side-cnt { background: hsl(var(--h) 30% 24%); color: hsl(var(--h) 60% 80%); }

/* Пустые состояния */
.empty-box { background: var(--card); border-radius: 18px; padding: 40px 28px; text-align: center; box-shadow: var(--shadow); display: grid; justify-items: center; gap: 12px; }
.empty-box h2 { font-size: clamp(20px, 2.4vw, 26px); max-width: 26ch; }
.empty-box p { color: var(--ink-2); max-width: 52ch; margin: 0 0 6px; }
.empty-art { width: 160px; height: 110px; margin-bottom: 6px; }
@media (prefers-reduced-motion: no-preference) { .empty-art { animation: float 4s ease-in-out infinite; } @keyframes float { 50% { transform: translateY(-6px) rotate(-1deg); } } }
.empty-others { margin-top: 18px; padding-top: 20px; border-top: 1px dashed var(--line-2); width: 100%; display: grid; gap: 12px; }
.seo-text { max-width: none; margin-top: 26px; }
.seo-text p { max-width: 75ch; }

/* Кнопка баланса в шапке */
.bal-pill { display: inline-flex !important; align-items: center; gap: 6px; height: 36px; padding: 0 6px 0 11px !important; border-radius: 999px !important;
  background: var(--green-soft) !important; color: var(--green) !important; font-weight: 600 !important; font-size: 14px !important; white-space: nowrap; text-decoration: none; transition: transform .12s; }
.bal-pill:hover { transform: translateY(-1px); }
.bal-pill svg { width: 18px; height: 18px; flex-shrink: 0; }
.bal-plus { width: 22px; height: 22px; border-radius: 50%; background: var(--green); color: #fff; display: grid; place-items: center; font-size: 15px; line-height: 1; }
:root[data-theme="dark"] .bal-plus { color: #11142A; }
@media (max-width: 1360px) { .acct-name { display: none; } .acct summary { padding: 3px; } }
@media (max-width: 1140px) { .bal-pill { align-self: flex-start; margin: 4px 0; } .acct-name { display: inline; } }

/* Страница баланса */
.bal-grid { display: grid; grid-template-columns: 380px minmax(0, 520px); gap: 24px; align-items: start; }
@media (max-width: 900px) { .bal-grid { grid-template-columns: 1fr; } }
.wallet { position: relative; aspect-ratio: 1.586; border-radius: 20px; padding: 24px; color: #fff; overflow: hidden;
  background: radial-gradient(120% 140% at 100% 0%, #4A5BE0 0%, var(--blue) 45%, #18237E 100%); box-shadow: 0 6px 0 #101860, 0 24px 40px -20px rgba(36, 56, 198, .8); display: flex; flex-direction: column; }
.wallet-top { display: flex; justify-content: space-between; align-items: center; }
.wallet-label { font-size: 14px; opacity: .85; }
.wallet-chip { width: 42px; height: 32px; border-radius: 7px; background: linear-gradient(135deg, #F4C43B, #D99A0B); box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .15); }
.wallet-sum { font: 700 clamp(34px, 5vw, 44px)/1 var(--display); margin-top: auto; letter-spacing: -.02em; }
.wallet-sum span { font-size: .6em; opacity: .8; }
.wallet-name { margin-top: 10px; font-size: 14px; opacity: .85; letter-spacing: .04em; }
.wallet-stripes { position: absolute; left: 0; right: 0; bottom: 0; height: 8px; background: var(--stripes); opacity: .9; }
.topup { max-width: none; display: grid; gap: 14px; }
.topup h2 { font-size: 20px; }
.amount-chips { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.amount-chip { position: relative; }
.amount-chip input { position: absolute; opacity: 0; }
.amount-chip span { display: block; text-align: center; padding: 11px 6px; border: 1px solid var(--line-2); border-radius: 12px; font: 600 15px var(--display); cursor: pointer; transition: all .12s; }
.amount-chip span:hover { border-color: var(--blue); }
.amount-chip input:checked + span { background: var(--blue); border-color: var(--blue); color: #fff; box-shadow: 0 3px 0 var(--press); }
.amount-chip input:focus-visible + span { outline: 3px solid var(--yellow); outline-offset: 2px; }
.amount-input { position: relative; }
.amount-input input { width: 100%; border: 1px solid var(--line-2); border-radius: 12px; padding: 12px 40px 12px 14px; font: 600 20px var(--display); background: var(--card); color: var(--ink); }
.amount-input input:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px var(--blue-soft); }
.amount-input span { position: absolute; right: 14px; top: 50%; transform: translateY(-50%); color: var(--ink-3); font-weight: 600; }
.pay-balance { display: flex; justify-content: space-between; align-items: center; gap: 14px; flex-wrap: wrap; border: 1px solid var(--line-2); border-radius: 10px; padding: 14px 16px; margin-bottom: 12px; }
.pay-balance.is-enough { border-color: var(--green); background: var(--green-soft); }
.bal-adj summary { cursor: pointer; color: var(--blue); font-size: 13px; }
.bal-adj-form { display: grid; gap: 6px; margin-top: 6px; min-width: 200px; }
.bal-adj-form input { border: 1px solid var(--line-2); border-radius: 6px; padding: 6px 8px; font: inherit; font-size: 13.5px; background: var(--card); color: var(--ink); }
