/* ============================================================================
   Личный кабинет PhotoTo3D — тёмная тема, сайдбар + main,
   карточка баланса сверху, drawer для заказов.
   ============================================================================ */

:root {
  --bg-0: #0f172a;
  --bg-1: #1e293b;
  --bg-2: #253449;
  --text-0: #f1f5f9;
  --text-1: #cbd5e1;
  --text-2: #94a3b8;
  --line: rgba(148, 163, 184, 0.18);
  --line-strong: rgba(148, 163, 184, 0.3);
  --accent-1: #38bdf8;
  --accent-2: #a78bfa;
  --accent-3: #f472b6;
  --green: #22c55e;
  --orange: #fb923c;
  --red: #f87171;
  --yellow: #fcd34d;
  --gradient: linear-gradient(135deg, #38bdf8 0%, #a78bfa 55%, #f472b6 100%);
  --radius: 14px;
  --radius-sm: 10px;
  --radius-lg: 18px;
  --shadow: 0 18px 48px rgba(0, 0, 0, 0.45);
  --shadow-sm: 0 4px 14px rgba(0, 0, 0, 0.3);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: #0f172a;
  color: var(--text-0);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  min-height: 100vh;
  line-height: 1.5;
}

.account-body { overflow-x: hidden; }

a { color: var(--accent-1); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ============================================================================
   LAYOUT
   ============================================================================ */
.account-layout {
  display: grid;
  grid-template-columns: 260px 1fr;
  min-height: 100vh;
}

/* ============================================================================
   SIDEBAR
   ============================================================================ */
.account-sidebar {
  background: linear-gradient(180deg, #0b1220 0%, #0f172a 100%);
  border-right: 1px solid var(--line);
  padding: 24px 16px;
  display: flex;
  flex-direction: column;
  gap: 24px;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
}

.sidebar-brand { padding: 0 8px; }
.brand-link {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--text-0);
}
.brand-link:hover { text-decoration: none; }
.brand-mark {
  width: 34px; height: 34px;
  border-radius: 10px;
  background: var(--gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  color: #0f172a;
  flex-shrink: 0;
}
.brand-text {
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -0.3px;
}
.brand-accent {
  background: var(--gradient);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.brand-sub {
  color: var(--text-2);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin: 8px 0 0 44px;
  font-weight: 600;
}

.sidebar-nav {
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 12px;
  border-radius: 10px;
  border: none;
  background: transparent;
  color: var(--text-1);
  font-size: 14px;
  font-weight: 500;
  font-family: inherit;
  cursor: pointer;
  transition: background .15s, color .15s;
  text-align: left;
  width: 100%;
}
.nav-item:hover {
  background: rgba(148, 163, 184, 0.08);
  color: var(--text-0);
}
.nav-item.active {
  background: linear-gradient(90deg, rgba(56,189,248,0.15), rgba(167,139,250,0.12));
  color: var(--text-0);
  box-shadow: inset 3px 0 0 var(--accent-1);
}
.nav-icon { font-size: 16px; flex-shrink: 0; width: 20px; text-align: center; }
.nav-label { flex: 1; }
.nav-badge {
  background: rgba(56, 189, 248, 0.18);
  color: var(--accent-1);
  font-size: 11px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 999px;
  min-width: 20px;
  text-align: center;
}

.sidebar-footer {
  border-top: 1px solid var(--line);
  padding-top: 16px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 13px;
}
.sidebar-link {
  color: var(--text-2);
  padding: 6px 8px;
  border-radius: 8px;
  transition: color .15s, background .15s;
}
.sidebar-link:hover {
  color: var(--text-0);
  background: rgba(148, 163, 184, 0.06);
  text-decoration: none;
}
.sidebar-user {
  color: var(--text-2);
  font-size: 12px;
  padding: 10px 8px 0;
  border-top: 1px dashed var(--line);
  margin-top: 8px;
  word-break: break-all;
  line-height: 1.4;
}
.sidebar-user a { color: var(--accent-1); }

/* ============================================================================
   MAIN
   ============================================================================ */
.account-main {
  padding: 24px 32px 60px;
  min-width: 0;
}

/* ============================================================================
   БАЛАНС СВЕРХУ
   ============================================================================ */
.account-topbar {
  margin-bottom: 24px;
}

.balance-card {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 20px 24px;
  background:
    radial-gradient(circle at 100% 0%, rgba(167, 139, 250, 0.18), transparent 50%),
    radial-gradient(circle at 0% 100%, rgba(56, 189, 248, 0.18), transparent 50%),
    rgba(30, 41, 59, 0.6);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-lg);
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow-sm);
  flex-wrap: wrap;
}

.balance-info {
  flex: 1;
  min-width: 180px;
}
.balance-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-2);
  font-weight: 600;
  margin-bottom: 4px;
}
.balance-value {
  font-size: 34px;
  font-weight: 800;
  line-height: 1.1;
  background: var(--gradient);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-feature-settings: "tnum";
}
.balance-sub {
  font-size: 12px;
  color: var(--text-2);
  margin-top: 4px;
}

/* ============================================================================
   PAGE HEADER
   ============================================================================ */
.page-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}
.page-title {
  font-size: 24px;
  font-weight: 800;
  margin: 0 0 4px;
  letter-spacing: -0.02em;
}
.page-sub {
  color: var(--text-2);
  font-size: 13px;
  margin: 0;
}
.page-actions {
  display: flex;
  gap: 8px;
  align-items: center;
}

/* ============================================================================
   TAB PANELS
   ============================================================================ */
.tab-panel { display: none; }
.tab-panel.active { display: block; animation: fadeUp .2s ease; }
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(4px); }
  to   { opacity: 1; transform: none; }
}

/* ============================================================================
   ORDERS
   ============================================================================ */
.order-item {
  background: rgba(30, 41, 59, 0.55);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px 20px;
  margin-bottom: 14px;
  backdrop-filter: blur(10px);
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 16px;
  align-items: center;
  cursor: pointer;
  transition: border-color .15s, transform .15s;
}
.order-item:hover {
  border-color: var(--line-strong);
  transform: translateY(-1px);
}
@media (max-width: 640px) {
  .order-item { grid-template-columns: 1fr; }
}

.order-num {
  font-family: ui-monospace, Menlo, Consolas, monospace;
  font-weight: 800;
  color: var(--accent-1);
  font-size: 15px;
}
.order-meta {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  color: var(--text-2);
  font-size: 13px;
  margin-top: 6px;
}
.order-meta b { color: var(--text-1); font-weight: 600; }
.order-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
}

.preorder-hint {
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.12), rgba(251, 146, 60, 0.08));
  border: 1px solid rgba(251, 191, 36, 0.35);
  border-radius: 10px;
  padding: 10px 14px;
  margin-top: 12px;
  font-size: 13px;
  color: #fcd34d;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.preorder-hint a {
  margin-left: auto;
  color: #fcd34d;
  font-weight: 600;
}

/* ============================================================================
   BADGES
   ============================================================================ */
.badge {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 600;
  background: rgba(148, 163, 184, 0.15);
  color: var(--text-1);
  white-space: nowrap;
}
.badge.draft     { background: rgba(251, 191, 36, 0.18);  color: #fcd34d; }
.badge.pending   { background: rgba(251, 146, 60, 0.18);  color: #fdba74; }
.badge.paid      { background: rgba(56, 189, 248, 0.18);  color: #7dd3fc; }
.badge.printing  { background: rgba(167, 139, 250, 0.18); color: #c4b5fd; }
.badge.shipped   { background: rgba(34, 197, 94, 0.18);   color: #86efac; }
.badge.cancelled { background: rgba(248, 113, 113, 0.18); color: #fca5a5; }

/* ============================================================================
   TABLE (для транзакций)
   ============================================================================ */
.table-wrap {
  background: rgba(30, 41, 59, 0.45);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  backdrop-filter: blur(10px);
}
table.table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}
.table th {
  text-align: left;
  padding: 13px 16px;
  color: var(--text-2);
  font-weight: 600;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-bottom: 1px solid var(--line);
  background: rgba(15, 23, 42, 0.5);
  white-space: nowrap;
}
.table td {
  padding: 13px 16px;
  border-bottom: 1px solid var(--line);
  color: var(--text-1);
  vertical-align: middle;
}
.table tbody tr:last-child td { border-bottom: none; }
.table-empty {
  text-align: center;
  padding: 40px 20px !important;
  color: var(--text-2);
}
.tx-amount {
  font-family: ui-monospace, Menlo, Consolas, monospace;
  font-weight: 700;
  text-align: right;
}
.tx-amount.plus  { color: #86efac; }
.tx-amount.minus { color: #fca5a5; }
.tx-balance {
  font-family: ui-monospace, Menlo, Consolas, monospace;
  color: var(--text-2);
  text-align: right;
  font-size: 12px;
}

/* ============================================================================
   REFERRAL
   ============================================================================ */
.referral-hero {
  display: flex;
  align-items: flex-start;
  gap: 18px;
  padding: 20px 24px;
  background:
    radial-gradient(circle at 100% 0%, rgba(244, 114, 182, 0.15), transparent 55%),
    rgba(30, 41, 59, 0.5);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  margin-bottom: 16px;
}
.referral-icon {
  width: 56px;
  height: 56px;
  border-radius: 14px;
  background: rgba(244, 114, 182, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  flex-shrink: 0;
}
.referral-body h3 {
  margin: 0 0 4px;
  font-size: 16px;
  color: var(--text-0);
}
.referral-body p {
  margin: 0;
  font-size: 13px;
  color: var(--text-2);
  line-height: 1.5;
}

.ref-link-box {
  display: flex;
  gap: 10px;
  align-items: center;
  padding: 12px 16px;
  background: rgba(15, 23, 42, 0.7);
  border: 1px solid var(--line);
  border-radius: 12px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}
.ref-link-text {
  flex: 1;
  min-width: 200px;
  font-family: ui-monospace, Menlo, Consolas, monospace;
  font-size: 13px;
  color: var(--accent-1);
  word-break: break-all;
}

.referral-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 12px;
}
.ref-stat {
  background: rgba(30, 41, 59, 0.5);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
}
.ref-stat-label {
  font-size: 11px;
  color: var(--text-2);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 600;
  margin-bottom: 6px;
}
.ref-stat-value {
  font-size: 22px;
  font-weight: 800;
  color: var(--text-0);
  line-height: 1.1;
}
.ref-stat-value.ref-money { color: #86efac; }

/* ============================================================================
   PROFILE
   ============================================================================ */
.profile-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 16px;
}
@media (max-width: 800px) {
  .profile-grid { grid-template-columns: 1fr; }
}
.profile-card {
  background: rgba(30, 41, 59, 0.5);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px;
}
.profile-card-title {
  margin: 0 0 14px;
  font-size: 14px;
  color: var(--text-0);
  font-weight: 700;
}
.profile-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px dashed rgba(148, 163, 184, 0.1);
  font-size: 13px;
  align-items: center;
}
.profile-row:last-child { border-bottom: none; padding-bottom: 0; }
.profile-row .k { color: var(--text-2); }
.profile-row .v { color: var(--text-0); font-weight: 500; text-align: right; word-break: break-all; }
.profile-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

/* ============================================================================
   BUTTONS
   ============================================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 20px;
  border-radius: 10px;
  border: none;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all .15s;
  font-family: inherit;
  white-space: nowrap;
}
.btn:disabled { opacity: .55; cursor: not-allowed; }
.btn:not(:disabled):hover { transform: translateY(-1px); }
.btn-primary {
  background: var(--gradient);
  color: #0f172a;
  box-shadow: 0 4px 14px rgba(167, 139, 250, 0.25);
}
.btn-primary:hover:not(:disabled) {
  box-shadow: 0 6px 20px rgba(167, 139, 250, 0.4);
}
.btn-ghost {
  background: transparent;
  color: var(--text-0);
  border: 1px solid var(--line);
}
.btn-ghost:hover:not(:disabled) {
  background: rgba(148, 163, 184, 0.08);
  border-color: var(--line-strong);
}
.btn-sm { padding: 7px 12px; font-size: 12px; }

/* ============================================================================
   DRAWER
   ============================================================================ */
.drawer-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  z-index: 1000;
  animation: fadeIn .15s ease;
}
.drawer-backdrop[hidden] { display: none; }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

.drawer {
  position: fixed;
  top: 0; right: 0;
  width: min(640px, 100vw);
  height: 100vh;
  background: #1e293b;
  border-left: 1px solid var(--line-strong);
  box-shadow: -20px 0 60px rgba(0, 0, 0, 0.5);
  z-index: 1001;
  display: flex;
  flex-direction: column;
  animation: slideIn .22s cubic-bezier(0.22, 1, 0.36, 1);
}
.drawer[hidden] { display: none; }
@keyframes slideIn {
  from { transform: translateX(30px); opacity: 0; }
  to   { transform: none; opacity: 1; }
}

.drawer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 20px 24px;
  border-bottom: 1px solid var(--line);
  flex-shrink: 0;
  background: rgba(15, 23, 42, 0.4);
}
.drawer-title {
  font-size: 20px;
  font-weight: 800;
  font-family: ui-monospace, Menlo, Consolas, monospace;
  color: var(--accent-1);
}
.drawer-sub {
  font-size: 13px;
  color: var(--text-2);
  margin-top: 4px;
}
.drawer-close {
  width: 36px; height: 36px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--text-1);
  font-size: 14px;
  cursor: pointer;
  transition: all .15s;
  font-family: inherit;
  flex-shrink: 0;
}
.drawer-close:hover {
  border-color: var(--accent-1);
  color: var(--accent-1);
  background: rgba(56, 189, 248, 0.08);
}
.drawer-body {
  flex: 1;
  overflow-y: auto;
  padding: 24px;
}
.drawer-empty {
  text-align: center;
  color: var(--text-2);
  padding: 60px 20px;
}

.detail-block {
  background: rgba(15, 23, 42, 0.5);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 16px;
  margin-bottom: 16px;
}
.detail-block h4 {
  font-size: 11px;
  text-transform: uppercase;
  color: var(--text-2);
  margin: 0 0 12px;
  letter-spacing: 0.06em;
  font-weight: 700;
}
.detail-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 0;
  border-bottom: 1px dashed rgba(148, 163, 184, 0.1);
  font-size: 13px;
  align-items: center;
}
.detail-row:last-child { border-bottom: none; padding-bottom: 0; }
.detail-row .k { color: var(--text-2); flex-shrink: 0; }
.detail-row .v { color: var(--text-0); font-weight: 500; text-align: right; word-break: break-word; }
.detail-row .v.money { color: #86efac; font-weight: 700; font-family: ui-monospace, Menlo, Consolas, monospace; }
.detail-row .v.accent { color: var(--accent-1); font-weight: 700; font-family: ui-monospace, Menlo, Consolas, monospace; }

.preview-box {
  width: 100%;
  max-width: 200px;
  aspect-ratio: 1;
  background: #0f172a;
  border: 1px solid var(--line);
  border-radius: 12px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 8px;
}
.preview-box img { width: 100%; height: 100%; object-fit: contain; }
.preview-box .empty { color: var(--text-2); font-size: 12px; }

.model-links {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 8px;
}
.model-links a {
  font-size: 12px;
  word-break: break-all;
  color: var(--accent-1);
}

/* ============================================================================
   MODAL
   ============================================================================ */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.75);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  animation: fadeIn .15s ease;
}
.modal-backdrop[hidden] { display: none; }
.modal {
  background: #1e293b;
  border: 1px solid var(--line-strong);
  border-radius: 16px;
  padding: 26px;
  max-width: 460px;
  width: 100%;
  box-shadow: var(--shadow);
}
.modal h3 {
  margin: 0 0 8px;
  font-size: 18px;
  color: var(--text-0);
}
.modal-hint {
  color: var(--text-2);
  font-size: 13px;
  margin: 0 0 16px;
}

.topup-presets {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(90px, 1fr));
  gap: 8px;
  margin-bottom: 16px;
}
.topup-preset {
  background: rgba(15, 23, 42, 0.75);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 12px 10px;
  color: var(--text-0);
  font-size: 14px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: all .15s;
}
.topup-preset:hover {
  border-color: var(--accent-1);
  background: rgba(56, 189, 248, 0.08);
}
.topup-preset.active {
  border-color: var(--accent-1);
  background: rgba(56, 189, 248, 0.15);
  color: var(--accent-1);
}

.modal .field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 14px;
}
.modal .field label {
  font-size: 12px;
  color: var(--text-2);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.modal .field input {
  width: 100%;
  background: rgba(15, 23, 42, 0.75);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 11px 14px;
  font-size: 14px;
  color: var(--text-0);
  font-family: inherit;
  outline: none;
  transition: border-color .15s;
}
.modal .field input:focus {
  border-color: var(--accent-1);
  box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.12);
}

.topup-hint {
  font-size: 12px;
  color: var(--text-2);
  background: rgba(56, 189, 248, 0.06);
  border: 1px solid rgba(56, 189, 248, 0.15);
  border-radius: 8px;
  padding: 10px 12px;
  margin-bottom: 16px;
  line-height: 1.5;
}

.modal .modal-actions {
  display: flex;
  gap: 10px;
  justify-content: flex-end;
}

/* ============================================================================
   MISC
   ============================================================================ */
.hide { display: none !important; }
.muted { color: var(--text-2); }
.empty-state {
  text-align: center;
  padding: 50px 20px;
  color: var(--text-2);
  font-size: 14px;
}
code {
  font-family: ui-monospace, Menlo, Consolas, monospace;
  background: rgba(148, 163, 184, 0.12);
  padding: 1px 6px;
  border-radius: 4px;
  font-size: 0.9em;
  color: var(--accent-1);
}

.spinner {
  width: 16px;
  height: 16px;
  border: 2px solid rgba(148, 163, 184, 0.25);
  border-top-color: var(--accent-1);
  border-radius: 50%;
  animation: spin .9s linear infinite;
  display: inline-block;
}
@keyframes spin { to { transform: rotate(360deg); } }

.toast {
  position: fixed;
  bottom: 24px; right: 24px;
  padding: 14px 20px;
  border-radius: 12px;
  background: rgba(30, 41, 59, 0.98);
  border: 1px solid var(--line-strong);
  box-shadow: var(--shadow);
  color: var(--text-0);
  font-size: 14px;
  max-width: 360px;
  z-index: 10000;
  animation: toastIn .25s ease;
}
.toast.error { border-color: rgba(244, 114, 182, 0.6); }
.toast.ok    { border-color: rgba(56, 189, 248, 0.6); }
@keyframes toastIn {
  from { transform: translateY(10px); opacity: 0; }
  to   { transform: none; opacity: 1; }
}

/* ============================================================================
   RESPONSIVE
   ============================================================================ */
@media (max-width: 900px) {
  .account-layout { grid-template-columns: 1fr; }
  .account-sidebar {
    position: relative;
    height: auto;
    flex-direction: row;
    align-items: center;
    padding: 12px 16px;
    gap: 16px;
    border-right: none;
    border-bottom: 1px solid var(--line);
  }
  .sidebar-brand { padding: 0; }
  .brand-sub { display: none; }
  .sidebar-nav {
    flex-direction: row;
    flex: 1;
    overflow-x: auto;
    gap: 4px;
  }
  .nav-item { padding: 8px 12px; flex-shrink: 0; }
  .nav-label { display: none; }
  .nav-icon { font-size: 18px; }
  .nav-badge { display: none; }
  .sidebar-footer {
    border-top: none;
    padding: 0;
    flex-direction: row;
    align-items: center;
  }
  .sidebar-link { display: none; }
  .sidebar-user {
    padding: 0;
    border-top: none;
    margin: 0;
    font-size: 11px;
  }

  .account-main { padding: 20px 16px 40px; }
  .balance-card { padding: 16px 18px; }
  .balance-value { font-size: 28px; }
}
/* ============================================================================
   КНОПКИ СКАЧИВАНИЯ И ОПЛАТЫ В КАРТОЧКЕ ЗАКАЗА
   ============================================================================ */
.order-downloads {
  display: flex;
  gap: 10px;
  margin-top: 12px;
  flex-wrap: wrap;
}
.btn-dl {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border-radius: 10px;
  background: rgba(34, 197, 94, 0.12);
  border: 1px solid rgba(34, 197, 94, 0.35);
  color: #86efac;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  transition: all .15s;
}
.btn-dl:hover {
  background: rgba(34, 197, 94, 0.22);
  border-color: rgba(34, 197, 94, 0.55);
  text-decoration: none;
  transform: translateY(-1px);
}

.order-pay {
  margin-top: 12px;
}
.btn-pay {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: 10px;
  background: var(--gradient);
  color: #0f172a;
  font-size: 13px;
  font-weight: 700;
  border: none;
  cursor: pointer;
  font-family: inherit;
  box-shadow: 0 4px 14px rgba(167, 139, 250, 0.25);
  transition: all .15s;
}
.btn-pay:hover:not(:disabled) {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(167, 139, 250, 0.4);
}
.btn-pay:disabled { opacity: .6; cursor: progress; }

/* ============================================================================
   БЛОК ДЕЙСТВИЙ В DRAWER
   ============================================================================ */
.download-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.download-actions .btn {
  flex: 1;
  min-width: 180px;
  justify-content: center;
}
.order-views { margin-top: 12px; }
.order-views-label {
  font-size: 12px;
  color: var(--text-2);
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.order-views-grid {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.order-view-thumb {
  width: 64px; height: 64px;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid var(--line);
  display: block;
  transition: border-color .15s, transform .15s;
}
.order-view-thumb:hover {
  border-color: var(--accent-1);
  transform: translateY(-1px);
}
.order-view-thumb img {
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
}