/* ============================================================
   saver. mini app — token system
   Palette derived from the bot's own avatar (pure black #000 /
   pure white wordmark). The one deliberate device: a recovered
   message doesn't dim or hide — it inverts to a solid white
   block, like a negative developing. Nothing else gets color.
   ============================================================ */
:root {
  --ink:        #0a0a0a;   /* base background — softer than pure #000 on large fields */
  --ink-solid:  #000000;   /* header/nav — exact avatar black */
  --surface:    #151513;   /* bubble / row surface, one step off ink */
  --surface-2:  #1c1c1a;   /* hover / pressed surface */
  --line:       #232320;   /* hairline dividers */
  --bone:       #ffffff;   /* primary text — exact avatar white */
  --dim:        #8c8b86;   /* secondary text, warm gray */
  --faint:      #56554f;   /* placeholders, disabled */
  --recovered-bg: #f5f4ef; /* the one inversion — warm paper white */
  --recovered-fg: #0a0a0a;

  --font-display: -apple-system, "SF Pro Display", "Inter", "Segoe UI", Roboto, Arial, sans-serif;
  --font-mono: ui-monospace, "SF Mono", "Roboto Mono", Menlo, Consolas, monospace;

  --radius: 14px;
  --radius-sm: 8px;
  --tabbar-h: 58px;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

html, body {
  height: 100%;
  margin: 0;
  background: var(--ink);
  color: var(--bone);
  font-family: var(--font-display);
  overscroll-behavior-y: none;
}

body {
  display: flex;
  flex-direction: column;
}

#app {
  position: relative;
  height: 100dvh;
  overflow: hidden;
}

.screen {
  position: absolute;
  inset: 0;
  bottom: calc(var(--tabbar-h) + env(safe-area-inset-bottom, 0px));
  display: flex;
  flex-direction: column;
  background: var(--ink);
  opacity: 0;
  pointer-events: none;
  transform: translateX(16px);
  transition: opacity .22s ease, transform .22s ease;
}
/* диалог читается во весь экран — таб-бар на нём скрыт */
#screen-dialog { bottom: 0; }
.screen--active {
  opacity: 1;
  pointer-events: auto;
  transform: translateX(0);
}

/* ---------- header bar ---------- */
.bar {
  flex: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: calc(env(safe-area-inset-top, 0px) + 14px) 18px 14px;
  background: var(--ink-solid);
  border-bottom: 1px solid var(--line);
}

.wordmark {
  margin: 0;
  font-size: 21px;
  font-weight: 800;
  letter-spacing: -0.02em;
  text-transform: lowercase;
}
.wordmark .dot { color: var(--dim); }

.icon-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: none;
  background: transparent;
  color: var(--bone);
  padding: 0;
  cursor: pointer;
}
.icon-btn:active { background: var(--surface-2); }

.bar--dialog { gap: 10px; }
.dialog-title { flex: 1; min-width: 0; text-align: center; }
.dialog-name {
  font-size: 15px;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.dialog-sub {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--dim);
  margin-top: 2px;
}

/* ---------- search bar (shared pattern) ---------- */
.search-bar {
  flex: none;
  display: none;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  background: var(--ink-solid);
  border-bottom: 1px solid var(--line);
}
.search-bar.search-bar--open { display: flex; }
.search-bar input {
  flex: 1;
  min-width: 0;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 9px 14px;
  color: var(--bone);
  font-family: var(--font-display);
  font-size: 14px;
  outline: none;
}
.search-bar input::placeholder { color: var(--faint); }
.search-bar input:focus { border-color: var(--dim); }

/* ---------- list screen ---------- */
.list-body {
  flex: 1;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 6px 0 24px;
}

.row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 18px;
  border-bottom: 1px solid var(--line);
  cursor: pointer;
  animation: rise .28s ease backwards;
}
.row:active { background: var(--surface-2); }

.avatar {
  flex: none;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--surface);
  border: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 16px;
  color: var(--bone);
}

.row-main { flex: 1; min-width: 0; }
.row-name {
  font-size: 15px;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.row-meta {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--dim);
  margin-top: 3px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.stamp-count {
  flex: none;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 3px;
}
.stamp-count .n {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 13px;
  background: var(--recovered-bg);
  color: var(--recovered-fg);
  padding: 2px 7px;
  border-radius: 5px;
}
.stamp-count .t {
  font-family: var(--font-mono);
  font-size: 10.5px;
  color: var(--faint);
}

/* ---------- empty / loading states ---------- */
.empty-state {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 40px 32px;
  gap: 10px;
  color: var(--dim);
}
.empty-state .glyph {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--faint);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.empty-state .msg {
  font-size: 14.5px;
  line-height: 1.5;
  max-width: 260px;
}

/* ---------- dialog screen ---------- */
.dialog-body {
  flex: 1;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 16px 14px 28px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.bubble-row {
  display: flex;
  flex-direction: column;
  max-width: 82%;
  animation: rise .24s ease backwards;
}
.bubble-row--own { align-self: flex-end; align-items: flex-end; }
.bubble-row--other { align-self: flex-start; align-items: flex-start; }

.bubble {
  padding: 9px 13px;
  border-radius: var(--radius);
  font-size: 14.5px;
  line-height: 1.42;
  word-break: break-word;
  background: var(--surface);
  border: 1px solid var(--line);
  color: var(--bone);
}
.bubble-row--own .bubble { border-bottom-right-radius: 4px; }
.bubble-row--other .bubble { border-bottom-left-radius: 4px; }

.bubble-time {
  font-family: var(--font-mono);
  font-size: 10.5px;
  color: var(--faint);
  margin: 4px 4px 0;
}

/* признанные удалёнными — единственная инверсия во всём приложении */
.bubble-row--recovered .bubble {
  background: var(--recovered-bg);
  color: var(--recovered-fg);
  border-color: var(--recovered-bg);
  animation: stamp .16s ease-out;
}
.recovered-tag {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--recovered-fg);
  opacity: 0.55;
  margin-bottom: 4px;
  display: block;
}

mark {
  background: var(--recovered-bg);
  color: var(--recovered-fg);
  border-radius: 3px;
  padding: 0 2px;
}
.bubble-row--recovered .bubble mark {
  background: var(--ink-solid);
  color: var(--bone);
}

.media-chip {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13.5px;
  margin-bottom: 4px;
}
.media-thumb {
  max-width: 100%;
  min-height: 40px;
  border-radius: var(--radius-sm);
  display: block;
  margin-bottom: 6px;
}
.media-slot {
  display: flex;
  align-items: center;
  min-height: 40px;
  margin-bottom: 6px;
  padding: 10px 12px;
  font-size: 13px;
  color: var(--faint);
  background: rgba(0, 0, 0, 0.06);
  border: 1px dashed var(--line);
  border-radius: var(--radius-sm);
}
.media-slot--tap {
  cursor: pointer;
  border-style: solid;
}
.media-slot--tap:active { opacity: 0.7; }
.media-slot--pending .media-slot__label::after {
  content: '';
  display: inline-block;
  width: 10px;
  height: 10px;
  margin-left: 8px;
  border: 1.5px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  vertical-align: -1px;
  animation: media-spin 0.8s linear infinite;
}
@keyframes media-spin { to { transform: rotate(360deg); } }

.media-audio {
  display: block;
  width: min(100%, 260px);
  height: 36px;
  margin-bottom: 6px;
}
.media-video {
  display: block;
  max-width: 100%;
  max-height: 320px;
  border-radius: var(--radius-sm);
  margin-bottom: 6px;
  background: #000;
}
.media-circle {
  display: block;
  width: 220px;
  height: 220px;
  max-width: 100%;
  border-radius: 50%;
  object-fit: cover;
  margin-bottom: 6px;
  background: #000;
}

.day-sep {
  align-self: center;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--faint);
  padding: 4px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  margin: 6px 0;
}

/* ---------- search results (global, on list screen) ---------- */
.result {
  padding: 12px 18px;
  border-bottom: 1px solid var(--line);
  cursor: pointer;
  animation: rise .22s ease backwards;
}
.result:active { background: var(--surface-2); }
.result-who {
  font-size: 13px;
  font-weight: 700;
  color: var(--dim);
  margin-bottom: 3px;
}
.result-snippet {
  font-size: 14px;
  line-height: 1.4;
}
.result-time {
  font-family: var(--font-mono);
  font-size: 10.5px;
  color: var(--faint);
  margin-top: 4px;
}

/* ---------- toast ---------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: calc(env(safe-area-inset-bottom, 0px) + 22px);
  transform: translate(-50%, 12px);
  background: var(--recovered-bg);
  color: var(--recovered-fg);
  font-size: 13.5px;
  font-weight: 600;
  padding: 10px 18px;
  border-radius: 999px;
  opacity: 0;
  pointer-events: none;
  transition: opacity .2s ease, transform .2s ease;
  z-index: 50;
  max-width: 84%;
  text-align: center;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---------- motion ---------- */
@keyframes rise {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes stamp {
  from { transform: scale(.94); opacity: .5; }
  to   { transform: scale(1); opacity: 1; }
}
@media (prefers-reduced-motion: reduce) {
  .screen, .row, .bubble-row, .result { animation: none !important; transition: none !important; }
}

/* ---------- scrollbars (desktop testing) ---------- */
.list-body::-webkit-scrollbar, .dialog-body::-webkit-scrollbar,
.scroll-body::-webkit-scrollbar { width: 0; }

/* ============================================================
   ПРОФИЛЬ / ТАРИФЫ / ОПЛАТА
   Тот же принцип, что и в архиве: цвета нет, единственный акцент —
   инверсия в тёплый бумажный белый. Здесь он достаётся ровно одному
   элементу на экране — действию, которое мы предлагаем совершить.
   ============================================================ */

.scroll-body {
  flex: 1;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 14px 16px 28px;
}

.visually-hidden {
  position: absolute; width: 1px; height: 1px;
  margin: -1px; padding: 0; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* ---------- карточка статуса ---------- */
.status-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  padding: 18px;
  animation: rise .28s ease backwards;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .04), 0 10px 28px rgba(0, 0, 0, .28);
}
.status-top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}
.status-label {
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--dim);
}
.status-days {
  display: flex;
  align-items: baseline;
  gap: 7px;
  margin-top: 10px;
}
.status-days .n {
  font-family: var(--font-mono);
  font-size: 38px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.02em;
}
.status-days .u { font-size: 14px; color: var(--dim); }
.status-until {
  font-family: var(--font-mono);
  font-size: 11.5px;
  color: var(--faint);
  margin-top: 8px;
}
.status-card--off .status-days .n { color: var(--dim); }

.pill {
  flex: none;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 4px 8px;
  border-radius: 5px;
  border: 1px solid var(--line);
  color: var(--dim);
  white-space: nowrap;
}
.pill--on { background: var(--recovered-bg); color: var(--recovered-fg); border-color: var(--recovered-bg); }

/* ---------- секции ---------- */
.section { margin-top: 26px; animation: rise .3s ease backwards; }
.section-head {
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--dim);
  margin-bottom: 10px;
  padding-left: 2px;
}

/* ---------- тарифы ---------- */
.tariffs { display: flex; flex-direction: column; gap: 8px; }

.tariff {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  min-height: 62px;
  padding: 13px 15px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--bone);
  font-family: inherit;
  text-align: left;
  cursor: pointer;
  transition: border-color .18s ease, background .18s ease;
}
.tariff:hover { border-color: var(--dim); }
.tariff:active { background: var(--surface-2); }
.tariff:focus-visible { outline: 2px solid var(--bone); outline-offset: 2px; }
.tariff[disabled] { opacity: .5; cursor: default; }

.tariff-main { flex: 1; min-width: 0; }
.tariff-title { font-size: 15.5px; font-weight: 700; }
.tariff-sub {
  font-family: var(--font-mono);
  font-size: 11.5px;
  color: var(--dim);
  margin-top: 3px;
}
.tariff-price {
  flex: none;
  font-family: var(--font-mono);
  font-size: 17px;
  font-weight: 700;
  letter-spacing: -0.01em;
}
/* Когда доступа нет, ровно одна карточка получает инверсию — чтобы на экране
   был один очевидный следующий шаг, а не пять равнозначных. */
.tariff--hero {
  background: var(--recovered-bg);
  color: var(--recovered-fg);
  border-color: var(--recovered-bg);
  box-shadow: 0 10px 26px rgba(245, 244, 239, .14);
}
.tariff--hero:hover { border-color: var(--recovered-bg); }
.tariff--hero:active { background: #e7e5dc; }
.tariff--hero .tariff-sub { color: #6b6a64; }
.tariff--hero .tariff-badge { background: var(--ink-solid); color: var(--bone); }

.tariff-badge {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: var(--recovered-bg);
  color: var(--recovered-fg);
  padding: 2px 6px;
  border-radius: 4px;
  margin-left: 8px;
  vertical-align: 1.5px;
}

/* ---------- строки-инфо ---------- */
.info-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 13px 15px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  margin-bottom: 8px;
}
.info-row .k { font-size: 14px; }
.info-row .v {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--dim);
  text-align: right;
}
.info-row--block { display: block; }
.info-row--block .k { margin-bottom: 6px; }
.info-row--block .v { text-align: left; }

.info-note--after { margin-top: 10px; }

.info-note {
  font-size: 12.5px;
  line-height: 1.5;
  color: var(--dim);
  padding: 0 2px;
}
.info-note a { color: var(--bone); }

/* ---------- кнопки ---------- */
.btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  min-height: 48px;
  padding: 13px 18px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--bone);
  font-family: inherit;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  transition: opacity .18s ease, background .18s ease, border-color .18s ease;
}
.btn:active { background: var(--surface-2); }
.btn:focus-visible { outline: 2px solid var(--bone); outline-offset: 2px; }
.btn[disabled] { opacity: .55; cursor: default; }

/* единственная инверсия на экране — главное действие */
.btn--primary {
  background: var(--recovered-bg);
  color: var(--recovered-fg);
  border-color: var(--recovered-bg);
  box-shadow: 0 8px 22px rgba(245, 244, 239, .14);
}
.btn--primary:active { background: #e7e5dc; }
.btn--primary:focus-visible { outline-color: var(--recovered-bg); }
.btn--ghost { background: transparent; border-color: transparent; color: var(--dim); min-height: 42px; }
.btn + .btn { margin-top: 8px; }

/* ---------- таб-бар ---------- */
.tabbar {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: calc(var(--tabbar-h) + env(safe-area-inset-bottom, 0px));
  padding-bottom: env(safe-area-inset-bottom, 0px);
  display: flex;
  background: var(--ink-solid);
  border-top: 1px solid var(--line);
  z-index: 20;
}
.tabbar--hidden { display: none; }

.tab {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  min-height: 44px;
  border: none;
  background: transparent;
  color: var(--faint);
  font-family: inherit;
  font-size: 10.5px;
  font-weight: 600;
  cursor: pointer;
  transition: color .18s ease;
}
.tab--active { color: var(--bone); }
.tab:focus-visible { outline: 2px solid var(--bone); outline-offset: -4px; }

/* ---------- шторки ---------- */
.sheet-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, .6);
  opacity: 0;
  pointer-events: none;
  transition: opacity .22s ease;
  z-index: 30;
}
.sheet-backdrop.show { opacity: 1; pointer-events: auto; }

.sheet {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  background: var(--ink-solid);
  border-top: 1px solid var(--line);
  border-radius: 18px 18px 0 0;
  padding: 8px 18px calc(env(safe-area-inset-bottom, 0px) + 20px);
  transform: translateY(101%);
  transition: transform .26s cubic-bezier(.32, .72, 0, 1);
  z-index: 40;
  max-height: 88%;
  overflow-y: auto;
}
.sheet.show { transform: translateY(0); }

.sheet-grip {
  width: 36px;
  height: 4px;
  border-radius: 2px;
  background: var(--line);
  margin: 4px auto 14px;
}
.sheet-title { margin: 0 0 6px; font-size: 18px; font-weight: 800; letter-spacing: -0.01em; }
.sheet-note { margin: 0 0 14px; font-size: 13.5px; line-height: 1.5; color: var(--dim); }

.sheet textarea {
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 12px 14px;
  color: var(--bone);
  font-family: inherit;
  font-size: 15px;
  line-height: 1.45;
  resize: none;
  outline: none;
  margin-bottom: 12px;
}
.sheet textarea:focus { border-color: var(--dim); }
.sheet textarea::placeholder { color: var(--faint); }

/* сумма к оплате в шторке */
.pay-amount {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin: 2px 0 16px;
}
.pay-amount .n {
  font-family: var(--font-mono);
  font-size: 34px;
  font-weight: 700;
  line-height: 1;
}
.pay-amount .d { font-size: 13.5px; color: var(--dim); }

.pay-status {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13.5px;
  color: var(--dim);
  margin-top: 14px;
  min-height: 20px;
}
.spinner {
  flex: none;
  width: 15px; height: 15px;
  border: 2px solid var(--line);
  border-top-color: var(--bone);
  border-radius: 50%;
  animation: spin .8s linear infinite;
}
.pay-done {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: var(--recovered-bg);
  color: var(--recovered-fg);
  padding: 3px 8px;
  border-radius: 5px;
}

/* ---------- скелетон загрузки ---------- */
.skeleton-card {
  height: 128px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: linear-gradient(90deg, var(--surface) 0%, var(--surface-2) 50%, var(--surface) 100%);
  background-size: 200% 100%;
  animation: shimmer 1.3s linear infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }
@keyframes shimmer {
  from { background-position: 200% 0; }
  to   { background-position: -200% 0; }
}

@media (prefers-reduced-motion: reduce) {
  .status-card, .section, .sheet, .spinner, .skeleton-card, .tariff, .btn, .tab {
    animation: none !important;
    transition: none !important;
  }
}

.stamp-count--quiet .n { opacity: .35; }

/* ---------- тумблеры настроек ---------- */
.toggle-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  min-height: 44px;
  padding: 8px 0;
  background: none;
  border: none;
  border-bottom: 1px solid var(--line);
  color: var(--bone);
  font-family: inherit;
  font-size: 14.5px;
  text-align: left;
  cursor: pointer;
}
.toggle-row:last-of-type { border-bottom: none; }
.toggle-switch {
  position: relative;
  flex: none;
  width: 42px;
  height: 25px;
  border-radius: 999px;
  background: var(--surface-2);
  border: 1px solid var(--line);
  transition: background .18s ease, border-color .18s ease;
}
.toggle-switch::after {
  content: '';
  position: absolute;
  top: 2px; left: 2px;
  width: 19px; height: 19px;
  border-radius: 50%;
  background: var(--dim);
  transition: transform .18s ease, background .18s ease;
}
/* тот же приём, что у восстановленного сообщения: включено = сплошной белый */
.toggle-switch--on {
  background: var(--recovered-bg);
  border-color: var(--recovered-bg);
}
.toggle-switch--on::after {
  transform: translateX(17px);
  background: var(--recovered-fg);
}
.toggle-row[disabled] { opacity: .5; pointer-events: none; }

/* ---------- статистика ---------- */
.stat-numbers {
  display: flex;
  gap: 8px;
  margin-bottom: 14px;
}
.stat-num {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 10px 4px;
  border-radius: var(--radius-sm);
  background: var(--surface-2);
  text-align: center;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .05);
}
.stat-num .n { font-size: 20px; font-weight: 800; font-variant-numeric: tabular-nums; }
.stat-num .l { font-size: 10.5px; color: var(--dim); line-height: 1.25; }
.stat-chart {
  display: flex;
  align-items: flex-end;
  gap: 3px;
  height: 56px;
}
.stat-bar {
  flex: 1;
  min-height: 3px;
  border-radius: 2px 2px 0 0;
  background: var(--surface-2);
  transition: background .18s ease;
}
.stat-bar--hit { background: var(--recovered-bg); }

/* ---------- опасная зона ---------- */
.btn--danger {
  background: transparent;
  border-color: var(--danger-line, #4a2320);
  color: var(--danger, #e5484d);
}
.btn--danger:active { background: rgba(229, 72, 77, .1); }
