/**
 * Кнопки управления анкетой в ЛК ([uz_model_actions]).
 * Редизайн под фирменный стиль UZFeya (итерация Claude Design).
 * Токены — scoped к .uz-actions (самодостаточно, без коллизий с темой).
 * Раскладка: статус + кнопки в один столбец на всю ширину карточки.
 * Поддержка светлой и тёмной (body.dark-mode) темы.
 */

.uz-actions {
  /* --- Токены компонента (бренд UZFeya) --- */
  --uz-pink-grad:     linear-gradient(180deg, #ff4f9f 0%, #e5006d 100%);
  --uz-gold-grad:     linear-gradient(180deg, #e9c877 0%, #c89b53 100%);
  --uz-graphite-grad: linear-gradient(180deg, #4a4a52 0%, #2b2b31 100%);
  --uz-green-grad:    linear-gradient(180deg, #33d17a 0%, #1faa59 100%);
  --uz-green:         #1faa59;
  --uz-red:           #d92d20;
  --uz-amber:         #b06a00;
  --uz-ink:           #1f2430;
  --uz-ink-muted:     #5b6170;
  --uz-surface:       #ffffff;
  --uz-border:        rgba(20, 22, 30, .14);
  --uz-radius-btn:    11px;
  --uz-radius-pill:   999px;
  --uz-shadow:        0 4px 12px rgba(225, 0, 103, .18);

  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 2px 16px 16px;   /* боковые гаттеры + нижний отступ под кнопками */
  font-family: "Nunito", system-ui, sans-serif;
}

/* Тёмная тема сайта */
body.dark-mode .uz-actions {
  --uz-ink:       #f7f2f6;
  --uz-ink-muted: #b9aeb8;
  --uz-surface:   rgba(255, 255, 255, .08);
  --uz-border:    rgba(255, 255, 255, .22);
}

/* ----- Статус ----- */
.uz-actions__status {
  align-self: flex-start;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  max-width: 100%;
  padding: 5px 11px;
  border-radius: var(--uz-radius-pill);
  font-size: 12.5px;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: .1px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.uz-actions__status::before {
  content: "";
  flex: 0 0 auto;
  width: 7px; height: 7px;
  border-radius: 50%;
  background: currentColor;
  opacity: .9;
}
.uz-actions__status.is-pending { background: #fff4e1; color: var(--uz-amber); }
.uz-actions__status.is-active  { background: #e7f7ec; color: var(--uz-green); }
.uz-actions__status.is-expired { background: #fdecec; color: var(--uz-red); }
.uz-actions__status.is-unpaid  { background: #eef0f3; color: var(--uz-ink-muted); }

body.dark-mode .uz-actions__status.is-pending { background: rgba(176,106,0,.20);   color: #ffce85; }
body.dark-mode .uz-actions__status.is-active  { background: rgba(31,170,89,.22);   color: #7ee29a; }
body.dark-mode .uz-actions__status.is-expired { background: rgba(217,45,32,.22);   color: #ff9b91; }
body.dark-mode .uz-actions__status.is-unpaid  { background: rgba(255,255,255,.12); color: var(--uz-ink-muted); }

/* ----- Кнопки: один столбец на всю ширину карточки ----- */
.uz-actions__buttons {
  display: flex;
  flex-direction: column;
  flex-wrap: nowrap;
  align-items: stretch;
  gap: 6px;
}

/* Все кнопки — одинаковая полная ширина. width/appearance с !important,
   чтобы перебить глобальные стили кнопок темы и нормализовать <a> и <button>. */
.uz-actions .uz-btn {
  width: 100% !important;
  max-width: 100% !important;
  min-width: 0 !important;
  margin: 0 !important;
  box-sizing: border-box !important;
  -webkit-appearance: none;
  appearance: none;
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 11px 14px;
  font-family: "Nunito", system-ui, sans-serif;
  font-size: 13.5px;
  font-weight: 700;
  line-height: 1;
  white-space: nowrap;
  border: 1px solid transparent;
  border-radius: var(--uz-radius-btn);
  cursor: pointer;
  text-decoration: none;
  text-align: center;
  transition: transform .12s ease, box-shadow .15s ease, background .15s ease, opacity .15s ease;
}
.uz-actions .uz-btn:hover  { transform: translateY(-1px); }
.uz-actions .uz-btn:active { transform: translateY(0); }

/* Цвета задаём с !important — тема перебивает .uz-btn своими !important (особенно в тёмной). */

/* Нейтральные ghost: сплошной белый + тонкий бордер — контраст на белом/серебре/золоте */
.uz-actions .uz-btn--view,
.uz-actions .uz-btn--edit {
  background: #ffffff !important;
  background-image: none !important;
  color: var(--uz-ink) !important;
  border-color: var(--uz-border) !important;
  box-shadow: 0 1px 2px rgba(20, 22, 30, .07) !important;
}
.uz-actions .uz-btn--view:hover,
.uz-actions .uz-btn--edit:hover { background: #f6f6f8 !important; }

/* Оплата: иерархия Base → Premium → Top */
.uz-actions .uz-btn--activate { background: var(--uz-pink-grad) !important;     color: #fff !important;    border-color: transparent !important; box-shadow: var(--uz-shadow) !important; }
.uz-actions .uz-btn--premium  { background: var(--uz-graphite-grad) !important; color: #fff !important;    border-color: transparent !important; box-shadow: 0 4px 12px rgba(0,0,0,.22) !important; }
.uz-actions .uz-btn--top      { background: var(--uz-gold-grad) !important;     color: #3a2c0a !important; border-color: rgba(120,90,30,.35) !important; box-shadow: 0 4px 12px rgba(200,155,83,.30) !important; }

/* Видимость */
.uz-actions .uz-btn--hide {
  background: transparent !important;
  background-image: none !important;
  color: var(--uz-red) !important;
  border-color: rgba(217, 45, 32, .45) !important;
  box-shadow: none !important;
}
.uz-actions .uz-btn--hide:hover { background: rgba(217, 45, 32, .08) !important; }
.uz-actions .uz-btn--show { background: var(--uz-green-grad) !important; color: #fff !important; border-color: transparent !important; box-shadow: 0 4px 12px rgba(31, 170, 89, .25) !important; }

/* Тёмная тема: ghost-кнопки — морозное стекло поверх тёмной карточки */
body.dark-mode .uz-actions .uz-btn--view,
body.dark-mode .uz-actions .uz-btn--edit {
  background: rgba(255, 255, 255, .10) !important;
  color: var(--uz-ink) !important;
  border-color: var(--uz-border) !important;
  box-shadow: none !important;
  backdrop-filter: blur(2px);
}
body.dark-mode .uz-actions .uz-btn--view:hover,
body.dark-mode .uz-actions .uz-btn--edit:hover { background: rgba(255, 255, 255, .16) !important; }
body.dark-mode .uz-actions .uz-btn--hide       { color: #ff9b91 !important; border-color: rgba(255, 155, 145, .45) !important; }
body.dark-mode .uz-actions .uz-btn--hide:hover { background: rgba(255, 155, 145, .12) !important; }
body.dark-mode .uz-actions .uz-btn--top        { border-color: rgba(255, 220, 150, .30) !important; }

/* Состояния */
.uz-btn.is-disabled,
.uz-btn:disabled {
  opacity: .45;
  cursor: not-allowed;
  pointer-events: none;
  box-shadow: none;
  transform: none;
}
.uz-btn.is-loading { opacity: .75; pointer-events: none; }
.uz-btn.is-loading::after {
  content: "";
  width: 13px; height: 13px;
  border: 2px solid rgba(255,255,255,.5);
  border-top-color: #fff;
  border-radius: 50%;
  animation: uz-spin .6s linear infinite;
}
@keyframes uz-spin { to { transform: rotate(360deg); } }

/* Скромная ссылка «Удалить анкету» — без большой кнопки */
.uz-actions .uz-actions__delete,
.uz-actions .uz-actions__delete:hover,
.uz-actions .uz-actions__delete:focus {
  align-self: center;
  margin: 4px 0 0 !important;
  padding: 4px 8px !important;
  width: auto !important;
  border: 0 !important;
  background: transparent !important;
  background-image: none !important;
  box-shadow: none !important;
  color: var(--uz-ink-muted, #8a8f9a) !important;
  -webkit-text-fill-color: currentColor !important;
  font-family: "Nunito", system-ui, sans-serif;
  font-size: 13px;
  font-weight: 600;
  text-decoration: underline !important;
  text-underline-offset: 2px;
  cursor: pointer;
  transform: none !important;
  transition: color .15s ease, opacity .15s ease;
}
.uz-actions .uz-actions__delete:hover { color: #d92d20 !important; }
.uz-actions__delete.is-loading { opacity: .6; pointer-events: none; }

/*
 * MVP: скрыть тариф Top (оставлено открытым для проверки 250$).
 * После проверки раскомментировать:
 */
.uz-btn--top { display: none !important; } /* UZ-MVP: Top-250 скрыт, вернуть = закомментировать */
