/* Рассылыч: почти чёрный фон с розовым свечением, плотный гротеск, розовые кнопки-таблетки.
   Имена переменных (--green, --lime) остались от зелёной темы: --green — основной розовый, --lime — светлый коралловый. */
:root {
  --bg: #0e0a0c;
  --surface: rgba(24, 19, 21, .82);
  --surface-2: #1c1619;
  --line: rgba(255, 255, 255, .07);
  --line-2: rgba(255, 255, 255, .12);
  --text: #d4c4cb;
  --head: #d1c7cb;
  --muted: #bcb2b6;
  --faint: #7f6f76;
  --green: #d02373;
  --green-hi: #db4a8c;
  --lime: #ea6d8d;
  --amber: #f0c25e;
  --red: #f0697a;
  --grad: linear-gradient(90deg, #dc3d84 0%, #e06f92 60%, #ea6d8d 100%);
  --tier: var(--green-hi);
  --ease: cubic-bezier(.22, 1, .36, 1);
  --spring: cubic-bezier(.34, 1.45, .64, 1);
  --safe-b: env(safe-area-inset-bottom, 0px);
  --chrome-h: 128px;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; height: 100%; }
body {
  background: var(--bg); color: var(--text);
  font-family: Onest, system-ui, -apple-system, "Segoe UI", sans-serif; font-size: 15px;
  overflow: hidden; -webkit-font-smoothing: antialiased;
  user-select: none; -webkit-user-select: none;
}
input, textarea { user-select: text; -webkit-user-select: text; }
button, input, textarea, select { font: inherit; color: inherit; }
button { background: none; border: 0; cursor: pointer; padding: 0; }
svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- фон: зелёные пятна света и редкие точки ---------- */
.atmos { position: fixed; inset: 0; pointer-events: none; z-index: 0; overflow: hidden; }
.glow { position: absolute; border-radius: 50%; filter: blur(70px); animation: drift 28s ease-in-out infinite alternate; will-change: transform; }
@media (max-width: 600px) { .glow { animation: none; } } /* на телефонах фон неподвижный: размытые пятна дорого перерисовывать */
.g1 { width: 420px; height: 520px; left: -260px; top: -80px; background: rgba(175, 31, 94, .45); }
.g2 { width: 520px; height: 360px; right: -260px; top: -140px; background: rgba(148, 48, 88, .32); animation-duration: 34s; }
.g3 { width: 460px; height: 460px; left: 20%; top: 120%; background: rgba(137, 26, 77, .25); animation-duration: 40s; }
@keyframes drift { to { transform: translate3d(50px, 40px, 0) scale(1.08); } }
.dots {
  position: absolute; inset: 0; opacity: .5;
  background-image:
    radial-gradient(1.2px 1.2px at 30px 40px, rgba(255, 255, 255,.35), transparent),
    radial-gradient(1px 1px at 190px 120px, rgba(255, 255, 255,.25), transparent),
    radial-gradient(1px 1px at 110px 260px, rgba(255, 255, 255,.2), transparent),
    radial-gradient(1.2px 1.2px at 260px 330px, rgba(255, 255, 255,.3), transparent);
  background-size: 300px 380px;
}

/* ---------- типографика ---------- */
.headline {
  margin: 4px 0 0; font-size: 40px; font-weight: 800; line-height: 1.02; letter-spacing: -.035em; color: var(--head);
}
.hl-num { display: block; font-size: 64px; color: var(--text); font-variant-numeric: tabular-nums; letter-spacing: -.045em; }
.grad { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.lead { margin: 0; color: var(--muted); font-size: 15px; line-height: 1.5; }
.title { margin: 0; font-size: 32px; font-weight: 800; letter-spacing: -.03em; color: var(--head); }
.h3 { margin: 0; font-size: 17px; font-weight: 700; letter-spacing: -.01em; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.xs { font-size: 12px; line-height: 1.45; }
.center { text-align: center; }
.caption { margin: 0; color: var(--faint); font-size: 12.5px; line-height: 1.55; }
.row-between { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.title-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; }

/* ---------- шапка: плавающая панель ---------- */
.chrome { position: fixed; top: 0; left: 0; right: 0; z-index: 10; padding: 12px 14px 10px; transition: transform .55s var(--ease), filter .55s, opacity .4s; }
.chrome::before { content: ""; position: absolute; inset: 0 0 -24px; background: linear-gradient(180deg, var(--bg) 55%, transparent); pointer-events: none; z-index: -1; }
.bar {
  display: flex; align-items: center; justify-content: space-between; height: 58px; padding: 0 8px 0 12px;
  border-radius: 22px; background: rgba(25, 20, 22, .9); border: 1px solid var(--line);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 14px 36px -18px rgba(0, 0, 0,.9);
}
.brand { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 19px; letter-spacing: -.02em; min-width: 0; text-align: left; transition: transform .25s var(--spring); }
.brand:active { transform: scale(.95); }
/* баланс вместо названия: подпись сверху, сумма крупно; нажатие открывает пополнение */
.bar-bal { display: flex; flex-direction: column; line-height: 1.1; min-width: 0; }
.bar-bal small { font-size: 10.5px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); }
.bar-bal b { font-size: 18px; font-weight: 800; font-variant-numeric: tabular-nums; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.logo {
  position: relative; width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center;
  background: linear-gradient(160deg, #d93781, #9e1b58); color: #fff; font-weight: 800; font-size: 17px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255,.25), 0 6px 14px -6px rgba(208, 35, 115,.8);
}
.logo i { position: absolute; top: 6px; right: 6px; width: 4px; height: 4px; border-radius: 50%; background: #ff99c7; }
.bar-r { display: flex; align-items: center; gap: 6px; }
.plan-chip { height: 34px; padding: 0 12px; max-width: 190px; border-radius: 17px; background: var(--green); color: #fff; font-size: 11.5px; font-weight: 800; letter-spacing: .02em; white-space: nowrap; transition: transform .25s var(--spring), background .3s; }
.plan-chip:active { transform: scale(.93); background: var(--green-hi); }
.icon-btn { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; color: var(--muted); transition: color .3s, background .3s; }
.icon-btn:active { background: rgba(255, 255, 255,.06); color: var(--text); }

.tabs {
  position: relative; display: flex; gap: 2px; margin-top: 10px; padding: 4px; width: max-content; max-width: 100%;
  border-radius: 18px; background: rgba(25, 20, 22, .85); border: 1px solid var(--line); overflow-x: auto; scrollbar-width: none;
  /* листается пальцем влево-вправо; прокрутка не передаётся странице и не закрывает приложение */
  overscroll-behavior-x: contain; touch-action: pan-x; -webkit-overflow-scrolling: touch; scroll-snap-type: x proximity;
  /* мягкое затухание у края, за которым есть ещё вкладки: --fl / --fr включает app.js */
  --fl: 0px; --fr: 0px;
  -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 var(--fl), #000 calc(100% - var(--fr)), transparent 100%);
  mask-image: linear-gradient(90deg, transparent 0, #000 var(--fl), #000 calc(100% - var(--fr)), transparent 100%);
}
.tabs.fade-l { --fl: 28px; }
.tabs.fade-r { --fr: 28px; }
.tabs.dragging { cursor: grabbing; scroll-snap-type: none; }
.tabs.dragging button { pointer-events: none; }
.tabs::-webkit-scrollbar { display: none; }
.tabs button { position: relative; z-index: 1; scroll-snap-align: center; flex-shrink: 0; padding: 9px 15px; border-radius: 14px; font-size: 14px; font-weight: 500; color: var(--muted); white-space: nowrap; transition: color .3s; }
.tabs button.on { color: var(--text); }
.tabs button[hidden] { display: none; }
.tab-glider { position: absolute; top: 4px; bottom: 4px; left: 0; width: 60px; border-radius: 14px; background: rgba(255, 255, 255,.08); box-shadow: inset 0 1px 0 rgba(255, 255, 255,.06); transition: transform .5s var(--ease), width .5s var(--ease); }
.badge { display: inline-grid; place-items: center; min-width: 17px; height: 17px; padding: 0 5px; margin-left: 6px; border-radius: 9px; background: var(--green); color: #fff; font-size: 10.5px; font-weight: 700; font-style: normal; vertical-align: 1px; }
.badge[hidden] { display: none; }

/* ---------- экраны ---------- */
/* overflow: экраны вне кадра сдвинуты на 36px для анимации — без обрезки страница становилась шире телефона */
#app { position: relative; z-index: 1; height: 100%; perspective: 1200px; overflow: hidden; transition: transform .6s var(--ease); }
.screen {
  position: absolute; inset: 0; overflow-y: auto; overflow-x: hidden;
  padding: calc(var(--chrome-h) + 14px) 18px calc(40px + var(--safe-b));
  display: flex; flex-direction: column; gap: 18px;
  opacity: 0; pointer-events: none; transform: translate3d(calc(var(--dir, 1) * 36px), 0, 0);
  transition: opacity .45s var(--ease), transform .65s var(--ease);
  scrollbar-width: none;
}
.screen::-webkit-scrollbar { display: none; }
.screen > * { flex-shrink: 0; width: 100%; max-width: 560px; margin-inline: auto; }
.screen > .news-pill { width: auto; margin-inline: max(0px, calc((100% - 560px) / 2)) auto; }
.bar, .tabs { max-width: min(560px, 100%); margin-inline: auto; } /* 100%: на узком экране вкладки листаются, а не вылезают за край */
.tabs { margin-top: 10px; }
.sheet { max-width: 600px; margin-inline: auto; }
.screen.active { opacity: 1; pointer-events: auto; transform: none; }
.screen.leave { opacity: 0; transform: translate3d(calc(var(--dir, 1) * -36px), 0, 0); }
.screen.active > * { animation: rise .8s var(--ease) both; }
.screen.active > *:nth-child(2) { animation-delay: .05s; }
.screen.active > *:nth-child(3) { animation-delay: .1s; }
.screen.active > *:nth-child(4) { animation-delay: .15s; }
.screen.active > *:nth-child(5) { animation-delay: .2s; }
.screen.active > *:nth-child(6) { animation-delay: .25s; }
.screen.active > *:nth-child(7) { animation-delay: .3s; }
@keyframes rise { from { opacity: 0; transform: translateY(16px); } }

/* ---------- консоль ---------- */
.news-pill {
  display: inline-flex; align-items: center; gap: 10px; align-self: flex-start; max-width: 100%;
  padding: 5px 5px 5px 5px; border-radius: 99px; background: var(--surface); border: 1px solid var(--line);
}
.np-tag { padding: 5px 11px; border-radius: 99px; background: rgba(208, 35, 115,.16); color: var(--green-hi); font-size: 13px; font-weight: 600; white-space: nowrap; }
.np-text { font-size: 14px; color: var(--head); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.avatar { width: 28px; height: 28px; border-radius: 50%; flex: none; background: #2b1e24 center/cover; display: grid; place-items: center; font-size: 12px; font-weight: 700; color: var(--green-hi); }
.cta { display: flex; gap: 10px; flex-wrap: wrap; }

.btn-primary {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 54px; padding: 0 26px; border-radius: 27px; background: var(--green); color: #fff;
  font-size: 15.5px; font-weight: 700; letter-spacing: -.005em;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255,.18), 0 12px 28px -12px rgba(208, 35, 115,.9);
  transition: transform .2s var(--ease), background .25s, box-shadow .3s;
}
.btn-primary svg { width: 18px; height: 18px; transition: transform .3s var(--ease); }
.btn-primary:active { transform: scale(.97); background: var(--green-hi); }
.btn-primary:active svg { transform: translateX(3px); }
.btn-primary:disabled { opacity: .5; pointer-events: none; }
.btn-ghost {
  display: inline-flex; align-items: center; justify-content: center; height: 54px; padding: 0 24px; border-radius: 27px;
  background: rgba(25, 20, 22,.7); border: 1px solid var(--line-2); font-size: 15.5px; font-weight: 600; color: var(--text);
  transition: background .25s, transform .2s var(--ease);
}
.btn-ghost:active { background: rgba(255, 255, 255,.07); transform: scale(.97); }
.btn-primary.sm, .btn-ghost.sm { height: 40px; padding: 0 16px; font-size: 14px; border-radius: 20px; }
.cta .btn-primary { flex: 1 1 auto; }
.cta [hidden] { display: none; }
.wide { width: 100%; margin-top: 16px; }
.btn-ghost.wide { margin-top: 10px; }

.hero {
  position: relative; height: 250px; border-radius: 26px; overflow: hidden;
  background:
    radial-gradient(70% 70% at 60% 60%, rgba(208, 35, 115,.22), transparent 70%),
    linear-gradient(180deg, #181214, #0f0b0d);
  border: 1px solid var(--line);
  box-shadow: 0 30px 60px -36px rgba(208, 35, 115,.6);
  transform-style: preserve-3d; transition: transform .5s var(--ease);
}
#scene { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.hero-label { position: absolute; left: 16px; top: 14px; display: inline-flex; align-items: center; gap: 8px; padding: 6px 11px; border-radius: 99px; background: rgba(14, 10, 12,.7); border: 1px solid var(--line); font-size: 12px; color: var(--muted); }
.live-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--green-hi); animation: live 2.2s infinite; }
@keyframes live { 0% { box-shadow: 0 0 0 0 rgba(219, 74, 140,.6); } 70%, 100% { box-shadow: 0 0 0 7px rgba(219, 74, 140,0); } }

.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.stats.two { grid-template-columns: 1fr 1fr; }
.stat { display: flex; flex-wrap: wrap; align-items: center; column-gap: 8px; row-gap: 6px; text-align: left; }
.stat b { font-size: 30px; font-weight: 800; letter-spacing: -.04em; font-variant-numeric: tabular-nums; }
.stat span { font-size: 12px; line-height: 1.3; color: var(--muted); }
.stat em { font-style: normal; color: var(--green-hi); }
.hair-bar { flex-basis: 100%; height: 3px; border-radius: 3px; background: var(--line); overflow: hidden; }
.hair-bar span { display: block; height: 100%; width: 2%; border-radius: inherit; background: var(--grad); transition: width 1.2s var(--ease); }

.panel { padding: 18px; border-radius: 24px; background: var(--surface); border: 1px solid var(--line); }
.week-chart { display: flex; align-items: flex-end; gap: 8px; height: 120px; margin-top: 16px; }
.week-col { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 8px; height: 100%; justify-content: flex-end; }
.week-bar { width: 100%; height: 0; border-radius: 8px; background: rgba(255, 255, 255,.07); transition: height 1.1s var(--ease); }
.week-col:last-child .week-bar { background: var(--grad); box-shadow: 0 0 20px -6px var(--green-hi); }
.week-col span { font-size: 11px; color: var(--faint); font-weight: 500; }

/* ---------- сегменты ---------- */
.segmented { position: relative; display: grid; grid-template-columns: repeat(3, 1fr); padding: 4px; border-radius: 18px; background: var(--surface); border: 1px solid var(--line); }
.segmented.four { grid-template-columns: repeat(4, 1fr); margin-top: 16px; }
.segmented button { position: relative; z-index: 1; padding: 9px 4px; border-radius: 14px; font-size: 13.5px; font-weight: 500; color: var(--muted); transition: color .3s; }
.segmented button.on { color: var(--text); }
.seg-glider { position: absolute; top: 4px; bottom: 4px; left: 0; width: 60px; border-radius: 14px; background: rgba(255, 255, 255,.08); transition: transform .5s var(--ease), width .5s var(--ease); }

/* ---------- списки ---------- */
.list { display: flex; flex-direction: column; gap: 8px; }
.item {
  display: flex; gap: 14px; align-items: center; padding: 14px; border-radius: 20px; text-align: left;
  background: var(--surface); border: 1px solid var(--line);
  animation: itemIn .6s var(--ease) both; animation-delay: calc(var(--i, 0) * 45ms);
}
@keyframes itemIn { from { opacity: 0; transform: translateY(10px); } }
.item.removing { animation: itemOut .35s var(--ease) forwards; }
@keyframes itemOut { to { opacity: 0; transform: translateX(-30px); } }
.item-body { flex: 1; min-width: 0; }
.item-title { font-size: 15px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.item-sub { color: var(--muted); font-size: 12.5px; margin-top: 3px; }
.item-meta { display: flex; gap: 6px; margin-top: 8px; flex-wrap: wrap; }
.tag { font-size: 11px; font-weight: 600; padding: 3px 9px; border-radius: 99px; background: rgba(255, 255, 255,.06); color: var(--muted); }
.tag.ok { background: rgba(208, 35, 115,.15); color: var(--green-hi); }
.tag.run { background: rgba(234, 109, 141,.13); color: var(--lime); }
.tag.wait { background: rgba(240, 194, 94,.12); color: var(--amber); }
.tag.err { background: rgba(240, 105, 122,.13); color: var(--red); }
.tag.own { background: rgba(255, 255, 255,.08); color: var(--head); }

.ring { position: relative; width: 46px; height: 46px; flex: none; }
.ring > svg { width: 46px; height: 46px; transform: rotate(-90deg); }
.ring circle { stroke-width: 4; fill: none; }
.ring .trk { stroke: rgba(255, 255, 255,.07); }
.ring .val { stroke: url(#gv); transition: stroke-dashoffset 1.1s var(--ease); }
.ring b { position: absolute; inset: 0; display: grid; place-items: center; color: var(--green-hi); }
.ring b svg { width: 16px; height: 16px; }
.mini-btn { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; flex: none; background: rgba(255, 255, 255,.05); color: var(--muted); transition: background .25s, transform .2s; }
.mini-btn:active { transform: scale(.88); background: rgba(255, 255, 255,.1); }
.mini-btn svg { width: 16px; height: 16px; }
.empty { text-align: center; color: var(--muted); padding: 48px 20px; line-height: 1.55; font-size: 14px; }
.empty svg { width: 40px; height: 40px; stroke: url(#gv); margin-bottom: 12px; }

/* ---------- чаты ---------- */
.search { display: flex; align-items: center; gap: 10px; height: 52px; padding: 0 6px 0 16px; border-radius: 26px; background: var(--surface); border: 1px solid var(--line); transition: border-color .3s; }
.search:focus-within { border-color: rgba(219, 74, 140,.5); }
.search svg { color: var(--faint); flex: none; }
.search input { flex: 1; min-width: 0; background: none; border: 0; outline: 0; font-size: 15px; }
.search input::placeholder { color: var(--faint); }
.search-add { height: 40px; padding: 0 16px; border-radius: 20px; background: rgba(208, 35, 115,.16); color: var(--green-hi); font-weight: 600; font-size: 14px; }
.chips { display: flex; gap: 8px; overflow-x: auto; margin: 0 -18px; padding: 0 18px; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.chip { flex: none; height: 36px; padding: 0 15px; border-radius: 18px; background: var(--surface); border: 1px solid var(--line); font-size: 13.5px; font-weight: 500; color: var(--muted); transition: all .3s var(--ease); }
.chip.on { background: var(--text); border-color: var(--text); color: #0e0a0c; }
.chat-ava { width: 44px; height: 44px; border-radius: 14px; flex: none; display: grid; place-items: center; font-size: 18px; font-weight: 700; color: #fff; }
.toggle { width: 46px; height: 28px; border-radius: 14px; background: rgba(255, 255, 255,.1); position: relative; flex: none; transition: background .3s var(--ease); }
.toggle::after { content: ""; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: #fff; box-shadow: 0 2px 6px rgba(0, 0, 0,.4); transition: transform .4s var(--spring); }
.toggle.on { background: var(--green); }
.toggle.on::after { transform: translateX(18px); }
.toggle:disabled { opacity: .3; pointer-events: none; }
.item .mini-btn + .toggle { margin-left: -4px; }

/* ---------- поддержка ---------- */
.sup-ava { width: 44px; height: 44px; border-radius: 50%; flex: none; display: grid; place-items: center; background: #2b1e24 center/cover; font-weight: 700; color: var(--green-hi); }
.sup-time { font-size: 11px; color: var(--faint); }
.unread { min-width: 20px; height: 20px; padding: 0 6px; border-radius: 10px; background: var(--green); color: #fff; font-size: 11px; font-weight: 700; display: grid; place-items: center; }
.sheet-tall { height: 88vh; display: flex; flex-direction: column; }
.thread { flex: 1; overflow-y: auto; display: flex; flex-direction: column; gap: 8px; padding: 16px 0; scrollbar-width: none; }
.bubble { max-width: 82%; padding: 10px 14px; border-radius: 18px; font-size: 14px; line-height: 1.45; white-space: pre-wrap; word-wrap: break-word; animation: itemIn .35s var(--ease) both; }
.bubble small { display: block; margin-top: 4px; font-size: 10.5px; opacity: .6; }
.bubble.in { align-self: flex-start; background: var(--surface-2); border: 1px solid var(--line); border-bottom-left-radius: 6px; }
.bubble.out { align-self: flex-end; background: var(--green); color: #fff; border-bottom-right-radius: 6px; }
.composer { display: flex; align-items: flex-end; gap: 10px; padding-top: 12px; border-top: 1px solid var(--line); }
.composer textarea { flex: 1; resize: none; max-height: 120px; padding: 13px 18px; border-radius: 24px; border: 1px solid var(--line-2); background: var(--surface); outline: 0; }
.send-btn { width: 48px; height: 48px; border-radius: 50%; flex: none; display: grid; place-items: center; background: var(--green); color: #fff; }
.send-btn:disabled { opacity: .5; }

/* ---------- шторки ---------- */
.scrim { position: fixed; inset: 0; z-index: 20; background: rgba(0, 0, 0,.55); opacity: 0; pointer-events: none; transition: opacity .4s; }
.scrim.on { opacity: 1; pointer-events: auto; }
body.sheet-open #app, body.sheet-open .chrome { transform: scale(.96); } /* затемняет подложка, фильтр яркости на весь экран был слишком тяжёлым */
.sheet {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; max-height: 92vh; overflow-y: auto;
  padding: 10px 20px calc(24px + var(--safe-b));
  background: radial-gradient(90% 40% at 50% 0%, rgba(208, 35, 115,.12), transparent 70%), #140f11;
  border-radius: 28px 28px 0 0; border-top: 1px solid var(--line-2);
  box-shadow: 0 -30px 70px rgba(0, 0, 0,.7);
  transform: translateY(104%); transition: transform .6s var(--ease); scrollbar-width: none;
}
.sheet::-webkit-scrollbar { display: none; }
.sheet.on { transform: none; }
.grabber { width: 38px; height: 4px; border-radius: 4px; background: var(--line-2); margin: 0 auto 12px; }
.sheet h2 { text-align: center; margin: 4px 0 6px; font-size: 22px; font-weight: 800; letter-spacing: -.02em; }
.sheet-close { position: absolute; right: 16px; top: 16px; width: 34px; height: 34px; border-radius: 50%; background: rgba(255, 255, 255,.06); font-size: 20px; line-height: 1; color: var(--muted); }
.pane[hidden] { display: none; }

/* тариф */
.carousel { display: flex; align-items: center; gap: 8px; margin: 18px 0 6px; }
.car-arrow { width: 42px; height: 42px; border-radius: 50%; flex: none; display: grid; place-items: center; background: rgba(255, 255, 255,.05); color: var(--text); transition: transform .25s var(--spring), opacity .3s; }
.car-arrow:active { transform: scale(.88); }
.car-arrow:disabled { opacity: .25; }
.car-stage { flex: 1; height: 76px; perspective: 500px; position: relative; overflow: hidden; -webkit-mask-image: linear-gradient(90deg, transparent, #000 28%, #000 72%, transparent); mask-image: linear-gradient(90deg, transparent, #000 28%, #000 72%, transparent); }
.car-ring { position: absolute; inset: 0; transform-style: preserve-3d; transition: transform .75s var(--ease); }
.car-item { position: absolute; left: 50%; top: 4px; width: 68px; height: 68px; margin-left: -34px; border-radius: 20px; display: grid; place-items: center; font-size: 30px; font-weight: 800; color: var(--faint); backface-visibility: hidden; transition: background .4s, color .4s; }
.car-item.on { background: var(--green); color: #fff; box-shadow: 0 12px 26px -12px var(--green-hi); }
.plan-card { position: relative; overflow: hidden; margin-top: 16px; padding: 20px; border-radius: 24px; background: radial-gradient(100% 90% at 100% 0%, color-mix(in srgb, var(--tier) 22%, transparent), transparent 60%), var(--surface-2); border: 1px solid var(--line-2); transform-style: preserve-3d; }
.plan-card.flip { animation: flip .6s var(--ease); }
@keyframes flip { 45% { transform: rotateY(-12deg) scale(.97); } }
.plan-shine { position: absolute; inset: 0; pointer-events: none; background: linear-gradient(115deg, transparent 35%, rgba(255, 255, 255,.06) 48%, transparent 60%) -150% 0/250% 100% no-repeat; animation: sweep 5s var(--ease) infinite; }
@keyframes sweep { 55%, 100% { background-position: 150% 0; } }
.plan-tier { position: relative; display: inline-block; padding: 4px 11px; border-radius: 99px; background: color-mix(in srgb, var(--tier) 18%, transparent); color: var(--tier); font-size: 13px; font-weight: 700; }
.plan-price { position: relative; display: flex; align-items: baseline; gap: 8px; margin: 12px 0 2px; }
.plan-price span { font-size: 46px; font-weight: 800; letter-spacing: -.04em; font-variant-numeric: tabular-nums; }
.plan-price small { color: var(--muted); font-size: 15px; font-weight: 500; }
.plan-old { position: relative; color: var(--muted); font-size: 13px; min-height: 18px; }
.plan-old s { opacity: .7; }
.plan-old b { color: var(--green-hi); margin-left: 6px; }
.plan-feats { position: relative; list-style: none; margin: 14px 0 0; padding: 0; display: flex; flex-direction: column; gap: 11px; }
.plan-feats li { display: flex; align-items: center; gap: 11px; font-size: 14px; animation: itemIn .45s var(--ease) both; animation-delay: calc(var(--i) * 50ms); }
.plan-feats .fi { width: 30px; height: 30px; border-radius: 10px; flex: none; display: grid; place-items: center; background: color-mix(in srgb, var(--tier) 16%, transparent); color: var(--tier); }
.plan-feats .fi svg { width: 16px; height: 16px; }
.periods { display: grid; grid-template-columns: repeat(5, 1fr); gap: 4px; margin-top: 16px; padding: 18px 4px 4px; border-radius: 18px; background: var(--surface); border: 1px solid var(--line); }
.period { position: relative; padding: 8px 2px; border-radius: 13px; text-align: center; transition: background .3s; }
.period b { display: block; font-size: 13px; font-weight: 600; color: var(--muted); }
.period small { display: block; font-size: 11px; color: var(--faint); margin-top: 2px; }
.period.on { background: rgba(255, 255, 255,.08); }
.period.on b { color: var(--text); }
.period.on small { color: var(--green-hi); }
.period .disc { position: absolute; top: -15px; left: 50%; transform: translateX(-50%); white-space: nowrap; font-size: 10px; font-weight: 700; padding: 2px 6px; border-radius: 7px; background: var(--green); color: #fff; }
.currencies { display: grid; grid-template-columns: repeat(2, 1fr); gap: 6px; margin-top: 10px; }
.currencies button { display: flex; align-items: center; justify-content: center; gap: 7px; height: 46px; border-radius: 23px; background: var(--surface); border: 1px solid var(--line); font-size: 13.5px; font-weight: 600; color: var(--muted); transition: border-color .3s, color .3s; }
.currencies button.on { border-color: rgba(219, 74, 140,.6); color: var(--text); }
.cur-ico { font-style: normal; width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center; font-size: 11px; font-weight: 800; }
.cur-ico.usdt { background: #26a17b; color: #fff; } /* фирменный цвет Tether — не перекрашиваем под тему */
.cur-ico.ton { background: #0098ea; color: #fff; font-size: 9px; }
.cur-ico.star { color: #f5c542; font-size: 17px; }

/* настройки */
.presets { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin-top: 16px; }
.preset { padding: 12px 4px; border-radius: 18px; text-align: center; background: var(--surface); border: 1px solid var(--line); transition: border-color .3s, background .3s; }
.preset b { display: block; font-size: 14.5px; font-weight: 700; }
.preset small { display: block; font-size: 11px; color: var(--faint); margin-top: 3px; }
.preset.on { border-color: rgba(219, 74, 140,.6); background: rgba(208, 35, 115,.1); }
.setting { margin-top: 12px; padding: 16px; border-radius: 20px; background: var(--surface); border: 1px solid var(--line); }
.setting .row-between > span:first-child { font-size: 14px; font-weight: 600; }
.setting .muted { margin-top: 8px; }
.set-val { font-size: 18px; font-weight: 800; color: var(--green-hi); font-variant-numeric: tabular-nums; }
.range { -webkit-appearance: none; appearance: none; width: 100%; height: 6px; border-radius: 3px; margin: 16px 0 6px; outline: 0; background: var(--grad) 0 / var(--fill, 50%) 100% no-repeat, rgba(255, 255, 255,.08); }
.range::-webkit-slider-thumb { -webkit-appearance: none; width: 24px; height: 24px; border-radius: 50%; background: #fff; border: 5px solid var(--green); box-shadow: 0 3px 10px rgba(0, 0, 0,.5); cursor: grab; }
.range::-moz-range-thumb { width: 16px; height: 16px; border-radius: 50%; background: #fff; border: 5px solid var(--green); }
.range-scale { display: flex; justify-content: space-between; font-size: 11px; color: var(--faint); }
.speed-risk { display: flex; align-items: center; gap: 10px; margin: 14px 0 8px; padding: 12px 14px; border-radius: 16px; font-size: 13px; font-weight: 600; }
.speed-risk i { width: 7px; height: 7px; border-radius: 50%; background: currentColor; flex: none; }
.speed-risk.r0 { background: rgba(208, 35, 115,.1); color: var(--green-hi); }
.speed-risk.r1 { background: rgba(240, 194, 94,.1); color: var(--amber); }
.speed-risk.r2 { background: rgba(240, 105, 122,.11); color: var(--red); }

/* формы */
.field { display: flex; flex-direction: column; gap: 6px; margin-top: 14px; min-width: 0; }
.field[hidden] { display: none; }
.field > span { font-size: 12.5px; font-weight: 600; color: var(--muted); }
.field textarea, .field select, .field input { width: 100%; background: var(--surface); border: 1px solid var(--line-2); border-radius: 16px; padding: 13px 15px; outline: 0; resize: none; font-size: 15px; transition: border-color .3s; }
.field select option { background: #140f11; }
.field textarea:focus, .field select:focus, .field input:focus { border-color: rgba(219, 74, 140,.6); }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.check { display: flex; align-items: flex-start; gap: 12px; margin-top: 16px; font-size: 14px; line-height: 1.4; cursor: pointer; }
.check input { position: absolute; opacity: 0; pointer-events: none; }
.check i { width: 22px; height: 22px; flex: none; border-radius: 7px; border: 1.5px solid var(--line-2); display: grid; place-items: center; transition: background .25s, border-color .25s; }
.check i::after { content: ""; width: 10px; height: 6px; border-left: 2px solid #fff; border-bottom: 2px solid #fff; transform: rotate(-45deg) translate(1px, -1px) scale(0); transition: transform .3s var(--spring); }
.check input:checked + i { background: var(--green); border-color: var(--green); }
.check input:checked + i::after { transform: rotate(-45deg) translate(1px, -1px) scale(1); }
.ac-result { margin-top: 10px; font-size: 13px; line-height: 1.5; }
.ac-result .bad { color: var(--red); }
.ac-result .good { color: var(--green-hi); }
.file-drop { position: relative; display: flex; flex-direction: column; align-items: center; gap: 4px; margin-top: 14px; padding: 22px 16px; border-radius: 20px; border: 1.5px dashed var(--line-2); text-align: center; cursor: pointer; transition: border-color .3s, background .3s; }
.file-drop:active { background: rgba(255, 255, 255,.03); }
.file-drop.has { border-color: rgba(219, 74, 140,.6); border-style: solid; }
.file-drop input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.file-drop b { font-size: 14.5px; font-weight: 600; }
.or { display: flex; align-items: center; gap: 12px; margin-top: 14px; color: var(--faint); font-size: 12px; }
.or::before, .or::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.qr-box { width: 220px; height: 220px; margin: 18px auto 12px; padding: 12px; border-radius: 22px; background: #fff; display: grid; place-items: center; box-shadow: 0 20px 40px -20px rgba(208, 35, 115,.7); }
.qr-box svg { width: 100%; height: 100%; }
.qr-box.empty-qr { background: var(--surface); border: 1.5px dashed var(--line-2); box-shadow: none; }
.task-types { display: flex; flex-direction: column; gap: 8px; margin-top: 14px; }
.type-card { display: grid; grid-template-columns: auto 1fr; grid-template-rows: auto auto; column-gap: 14px; align-items: center; text-align: left; padding: 14px; border-radius: 20px; background: var(--surface); border: 1px solid var(--line); transition: border-color .25s; }
.type-card:active { border-color: rgba(219, 74, 140,.5); }
.type-card b { font-weight: 600; }
.type-card .glyph { grid-row: span 2; width: 44px; height: 44px; border-radius: 14px; display: grid; place-items: center; background: rgba(208, 35, 115,.15); color: var(--green-hi); }

/* ---------- журнал событий ---------- */
.title-btns { display: flex; gap: 8px; }
.log-list { flex: 1; overflow-y: auto; margin-top: 8px; scrollbar-width: none; }
.log-list::-webkit-scrollbar { display: none; }
.log-row { display: flex; gap: 12px; padding: 11px 0; border-bottom: 1px solid var(--line); content-visibility: auto; contain-intrinsic-size: 56px; }
.log-row i { width: 8px; height: 8px; margin-top: 6px; border-radius: 50%; flex: none; background: var(--faint); }
.log-row.ok i { background: var(--green-hi); }
.log-row.warn i { background: var(--amber); }
.log-row.error i { background: var(--red); }
.log-text { font-size: 14px; line-height: 1.4; }
.log-row small { display: block; margin-top: 3px; font-size: 11.5px; color: var(--faint); }

/* ---------- менеджер аккаунтов ---------- */
.acc-card { flex-direction: column; align-items: stretch; gap: 12px; }
.acc-head { display: flex; align-items: center; gap: 12px; }
.acc-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 14px; }
.acc-grid div { min-width: 0; }
.acc-grid span { display: block; font-size: 11.5px; color: var(--faint); }
.acc-grid b { display: block; margin-top: 2px; font-size: 13.5px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.acc-warn { padding: 10px 12px; border-radius: 14px; background: rgba(240, 105, 122,.1); color: var(--red); font-size: 12.5px; line-height: 1.4; }
.acc-note { padding: 10px 12px; border-radius: 14px; background: rgba(255, 255, 255,.04); color: var(--muted); font-size: 12px; line-height: 1.4; }
.acc-actions { display: flex; gap: 8px; align-items: center; }
.acc-actions .btn-ghost { flex: 1; }
.item { content-visibility: auto; contain-intrinsic-size: auto 92px; }

/* ---------- экран оплаты в сети TON ---------- */
.segmented.two { grid-template-columns: repeat(2, 1fr); margin-top: 16px; }
.pay-box { margin-top: 16px; border-radius: 22px; background: var(--surface); border: 1px solid var(--line); overflow: hidden; }
.pay-row { display: flex; align-items: center; gap: 12px; padding: 16px 16px 16px 18px; }
.pay-row + .pay-row { border-top: 1px solid var(--line); }
.pay-col { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.pay-col span { font-size: 12.5px; color: var(--muted); font-weight: 500; }
.pay-val { user-select: text; -webkit-user-select: text; font-size: 17px; font-weight: 700; line-height: 1.35; word-break: break-all; font-variant-numeric: tabular-nums; }
.copy-btn { width: 44px; height: 44px; border-radius: 14px; flex: none; display: grid; place-items: center; background: rgba(208, 35, 115,.14); color: var(--green-hi); transition: transform .2s var(--spring), background .25s; }
.copy-btn:active { transform: scale(.88); background: rgba(208, 35, 115,.28); }
.copy-btn.done { background: var(--green); color: #fff; }
.pay-status { display: flex; align-items: center; gap: 14px; margin-top: 14px; padding: 16px; border-radius: 20px; background: var(--surface-2); border: 1px solid var(--line); }
.pay-status b { display: block; font-size: 15px; }
.pay-status span { display: block; font-size: 12.5px; color: var(--muted); margin-top: 3px; line-height: 1.35; }
.pay-status.paid { border-color: rgba(219, 74, 140,.6); background: rgba(208, 35, 115,.12); }
.pay-status.late { border-color: rgba(240, 194, 94,.5); }
.spin { width: 26px; height: 26px; flex: none; border-radius: 50%; border: 3px solid rgba(255, 255, 255,.12); border-top-color: var(--green-hi); animation: rot 1s linear infinite; }
.pay-status.paid .spin { animation: none; border-color: var(--green-hi); position: relative; }
.pay-status.paid .spin::after { content: ""; position: absolute; left: 6px; top: 2px; width: 7px; height: 12px; border-right: 3px solid var(--green-hi); border-bottom: 3px solid var(--green-hi); transform: rotate(40deg); }
@keyframes rot { to { transform: rotate(1turn); } }
#payNew[hidden] { display: none; }

/* ---------- баланс ---------- */
.balance-card { display: flex; align-items: center; gap: 12px; padding: 14px 14px 14px 18px; border-radius: 22px; background: var(--surface); border: 1px solid var(--line); cursor: pointer; transition: border-color .3s; }
.balance-card:active { border-color: rgba(219, 74, 140,.5); }
.bal-info { display: flex; flex-direction: column; gap: 2px; }
.bal-num { font-size: 28px; font-weight: 800; letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.bal-hint { flex: 1; font-size: 12px; color: var(--faint); line-height: 1.3; }
.bal-big { text-align: center; font-size: 46px; font-weight: 800; letter-spacing: -.04em; margin: 14px 0 4px; font-variant-numeric: tabular-nums; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.chips.wrap { flex-wrap: wrap; overflow: visible; margin: 0; padding: 0; }
.amount-input { display: flex; align-items: center; gap: 8px; margin-top: 10px; padding: 0 16px; height: 52px; border-radius: 26px; background: var(--surface); border: 1px solid var(--line-2); transition: border-color .3s; }
.amount-input:focus-within { border-color: rgba(219, 74, 140,.6); }
.amount-input span { color: var(--muted); font-weight: 700; }
.amount-input input { flex: 1; min-width: 0; background: none; border: 0; outline: 0; font-size: 16px; font-weight: 600; }
.currencies.three { grid-template-columns: repeat(3, 1fr); }
.cur-ico.bal { background: var(--green); color: #fff; }
/* «Администратору»: отдельной строкой во всю ширину, с пометкой «Без комиссии» */
.currencies .cur-adm { grid-column: 1 / -1; }
.currencies button[hidden] { display: none; }
.cur-adm span { display: flex; align-items: baseline; gap: 8px; }
.cur-adm small { font-size: 11px; font-weight: 700; color: var(--lime); padding: 2px 8px; border-radius: 10px; background: rgba(234, 109, 141, .14); }
.cur-ico.adm { background: var(--surface-2); color: var(--text); border: 1px solid var(--line-2); font-size: 11px; }

/* ---------- профиль аккаунта ---------- */
.prof-top { display: flex; align-items: center; gap: 16px; margin-top: 6px; }
.prof-ava { position: relative; width: 84px; height: 84px; flex: none; border-radius: 50%; overflow: hidden; cursor: pointer;
  display: grid; place-items: center; font-size: 32px; font-weight: 800; color: #fff;
  background: linear-gradient(145deg, #d93781, #611538) center/cover no-repeat; }
.prof-ava input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.prof-ava em { position: absolute; left: 0; right: 0; bottom: 0; padding: 4px 0 6px; font-style: normal; font-size: 11px; font-weight: 700; text-align: center; background: rgba(0, 0, 0, .55); pointer-events: none; }
.prof-ava.busy::after { content: ""; position: absolute; inset: 0; background: rgba(0, 0, 0, .45); }
.prof-who { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.prof-who b { font-size: 18px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.prof-who span { color: var(--muted); font-size: 13.5px; }
.chat-ava.has-photo { background-size: cover !important; background-position: center !important; color: transparent; }
.acc-head .chat-ava { border-radius: 50%; }

/* ---------- журнал всех пользователей в админке ---------- */
.adm-log .log-row { cursor: pointer; }
.log-who { font-size: 12.5px; font-weight: 700; color: var(--green-hi); margin-bottom: 2px; }
.log-row.visit i { background: none; border: 1.5px solid var(--faint); }
.adm-filters { display: flex; gap: 6px; flex-wrap: wrap; margin: 10px 0 4px; }
.kv a { color: var(--green-hi); text-decoration: none; }
.adm-filter-user { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 8px 12px; margin-top: 8px; border-radius: 14px; background: var(--surface); font-size: 13.5px; }
.hist-row { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.hist-row:last-child { border-bottom: 0; }
.hist-row .item-body { min-width: 0; }
.hist-amt { font-weight: 800; font-variant-numeric: tabular-nums; white-space: nowrap; }
.hist-amt.pos { color: var(--green-hi); }

/* ---------- подключение аккаунта на видном месте ---------- */
.import-card { display: flex; align-items: center; gap: 12px; padding: 14px; border-radius: 22px; background: linear-gradient(135deg, rgba(208, 35, 115,.2), rgba(208, 35, 115,.06)); border: 1px solid rgba(219, 74, 140,.45); box-shadow: 0 18px 40px -24px rgba(208, 35, 115,.8); animation: nudge 3.2s var(--ease) infinite; }
.import-card[hidden] { display: none; }
@keyframes nudge { 0%, 85%, 100% { transform: none; } 92% { transform: translateY(-3px); } }
.ic-glyph { width: 46px; height: 46px; border-radius: 15px; flex: none; display: grid; place-items: center; background: var(--green); color: #fff; }
.ic-body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.ic-body b { font-size: 15px; font-weight: 700; line-height: 1.25; }
.ic-body span { font-size: 12px; color: var(--muted); line-height: 1.35; }
.import-card .btn-primary { flex: none; }

/* ---------- посты ---------- */
.thumb { width: 52px; height: 52px; border-radius: 14px; flex: none; background: rgba(208, 35, 115,.14) center/cover no-repeat; display: grid; place-items: center; color: var(--green-hi); overflow: hidden; }
.thumb svg { width: 22px; height: 22px; }
.post-text { color: var(--muted); font-size: 12.5px; margin-top: 3px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; line-height: 1.4; }
.p-actions { display: flex; gap: 6px; margin-top: 10px; align-items: center; }
.p-actions .btn-primary, .p-actions .btn-ghost { padding: 0 14px; }
.tag.photo { background: rgba(255, 255, 255,.08); color: var(--head); }
.counter { text-align: right; font-size: 12px; color: var(--faint); margin-top: 6px; font-variant-numeric: tabular-nums; }
.counter.over { color: var(--red); }
.photo-prev { position: relative; margin-top: 10px; border-radius: 18px; overflow: hidden; background: #000; max-height: 220px; display: grid; place-items: center; }
.photo-prev[hidden] { display: none; }
.photo-prev img { display: block; max-width: 100%; max-height: 220px; object-fit: contain; }
.photo-prev .mini-btn { position: absolute; top: 8px; right: 8px; background: rgba(14, 10, 12,.8); color: #fff; }
.field .file-drop { margin-top: 0; }
.file-drop[hidden] { display: none; }
.post-pick { display: flex; flex-direction: column; gap: 8px; max-height: 260px; overflow-y: auto; scrollbar-width: none; }
.post-pick::-webkit-scrollbar { display: none; }
.pick { display: flex; gap: 12px; align-items: center; padding: 10px; border-radius: 16px; background: var(--surface); border: 1.5px solid var(--line); text-align: left; transition: border-color .25s, background .25s; }
.pick .thumb { width: 44px; height: 44px; border-radius: 12px; }
.pick.on { border-color: rgba(219, 74, 140,.7); background: rgba(208, 35, 115,.1); }
.pick-empty { padding: 14px; border-radius: 16px; border: 1.5px dashed var(--line-2); color: var(--muted); font-size: 13px; text-align: center; }

/* ---------- админ-панель ---------- */
.adm-body { display: flex; flex-direction: column; gap: 16px; }
.tiles { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.tile { padding: 14px; border-radius: 20px; background: var(--surface); border: 1px solid var(--line); }
.tile b { display: block; font-size: 26px; font-weight: 800; letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.tile span { display: block; font-size: 12px; color: var(--muted); margin-top: 2px; }
.tile em { display: block; font-style: normal; font-size: 12px; color: var(--green-hi); margin-top: 6px; }
.tile.wide2 { grid-column: span 2; }
.adm-h { margin: 6px 2px -4px; font-size: 13px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .08em; }
.bars { display: flex; align-items: flex-end; gap: 4px; height: 70px; margin-top: 12px; }
.bars i { flex: 1; min-height: 3px; border-radius: 4px; background: rgba(255, 255, 255,.1); }
.bars i:last-child { background: var(--grad); }
.bars-legend { display: flex; justify-content: space-between; font-size: 11px; color: var(--faint); margin-top: 6px; }
.kv { display: flex; flex-direction: column; }
.kv > div { display: flex; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.kv > div:last-child { border-bottom: 0; }
.kv span { color: var(--muted); }
.kv b { font-weight: 600; text-align: right; }
.adm-row { display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: 18px; background: var(--surface); border: 1px solid var(--line); text-align: left; width: 100%; }
.adm-row + .adm-row { margin-top: 8px; }
.adm-row .item-body { min-width: 0; }
.plan-pill { padding: 3px 9px; border-radius: 99px; font-size: 11px; font-weight: 700; background: rgba(255, 255, 255,.07); color: var(--muted); white-space: nowrap; }
.plan-pill.on { background: rgba(208, 35, 115,.16); color: var(--green-hi); }
.plan-pill.adm { background: rgba(240, 194, 94,.14); color: var(--amber); }
.adm-search { margin-bottom: 0; }
.btn-danger { color: var(--red) !important; border-color: rgba(240, 105, 122,.4) !important; }
.grant { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 8px; }
.grant select { height: 48px; padding: 0 14px; border-radius: 16px; background: var(--surface); border: 1px solid var(--line-2); outline: 0; font-size: 15px; width: 100%; }
.grant select option { background: #140f11; }
.adm-grant { margin-bottom: 12px; padding: 12px 14px; }
.adm-grant summary { cursor: pointer; font-weight: 600; list-style: none; }
.adm-grant summary::-webkit-details-marker { display: none; }
.adm-grant summary::after { content: '＋'; float: right; color: var(--muted, #b3a5ac); }
.adm-grant[open] summary::after { content: '−'; }
.adm-grant .grant input { grid-column: 1 / -1; height: 48px; padding: 0 14px; border-radius: 16px; background: var(--surface); border: 1px solid var(--line-2); outline: 0; font-size: 15px; min-width: 0; }
.mini-form { display: grid; grid-template-columns: 1fr 1fr auto; gap: 6px; margin-top: 10px; }
.mini-form input { min-width: 0; height: 40px; padding: 0 12px; border-radius: 14px; background: var(--surface-2); border: 1px solid var(--line-2); outline: 0; font-size: 14px; }
.mini-form.two { grid-template-columns: 1fr 1.4fr; }
.row-btns { display: flex; gap: 8px; margin-top: 10px; }
.row-btns .btn-ghost, .row-btns .btn-primary { flex: 1; }

/* тост */
.toast { position: fixed; left: 50%; top: 16px; z-index: 50; max-width: calc(100% - 32px); padding: 12px 18px; border-radius: 18px; background: #241a1e; border: 1px solid var(--line-2); box-shadow: 0 18px 40px -12px rgba(0, 0, 0,.8); font-weight: 500; font-size: 14px; transform: translate(-50%, -150%); opacity: 0; transition: transform .5s var(--ease), opacity .4s; }
.toast.on { transform: translate(-50%, 0); opacity: 1; }

@media (max-width: 370px) {
  .headline { font-size: 34px; }
  .hl-num { font-size: 54px; }
  .stat b { font-size: 26px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
