/* SOC-PROOF — общие стили панели (sidebar, header, base) */
* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  font-family: 'Inter', sans-serif;
  background: radial-gradient(ellipse at 20% 30%, #0b0f1c, #03050b);
  color: #f0f2fc;
  font-weight: 400;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

.dashboard { display: flex; min-height: 100vh; }

.sidebar {
  width: 280px;
  background: rgba(8, 10, 22, 0.85);
  backdrop-filter: blur(20px);
  border-right: 1px solid rgba(255,255,255,0.05);
  position: sticky;
  top: 0;
  height: 100vh;
  transition: all 0.25s ease;
  z-index: 120;
  overflow-y: auto;
}

.sidebar-header { padding: 28px 24px; border-bottom: 1px solid rgba(255,255,255,0.06); }

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 1.65rem;
  font-weight: 600;
  background: linear-gradient(130deg, #cdb4ff, #9b6eff);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-decoration: none;
}

.logo-sub { font-size: 11px; opacity: 0.7; margin-top: 4px; }

.admin-badge {
  font-size: 11px;
  background: #6d48e5;
  padding: 2px 10px;
  border-radius: 40px;
  width: fit-content;
  margin-top: 8px;
}

.nav-group { margin: 24px 16px; }

.nav-group-title {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 1.2px;
  color: #8a86b5;
  margin-bottom: 14px;
  padding-left: 12px;
}

.nav-item { list-style: none; margin-bottom: 5px; }

.nav-link {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px 16px;
  border-radius: 16px;
  font-weight: 450;
  color: #ccd0f0;
  transition: all 0.2s;
  cursor: pointer;
  text-decoration: none;
}

.nav-link i { width: 24px; font-size: 1.2rem; opacity: 0.75; }
.nav-link:hover { background: rgba(139, 92, 246, 0.18); color: white; }
.nav-item.active .nav-link {
  background: rgba(118, 70, 225, 0.25);
  border-left: 3px solid #a97dff;
  color: white;
  font-weight: 500;
}

.main-content { flex: 1; padding: 28px 36px; transition: padding 0.2s; }

.top-bar {
  background: rgba(16, 18, 35, 0.55);
  backdrop-filter: blur(16px);
  border-radius: 40px;
  padding: 14px 28px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 32px;
  border: 1px solid rgba(255,255,255,0.04);
}

.greeting h2 { font-size: 1.3rem; font-weight: 500; }
.greeting span { color: #c4aeff; font-weight: 500; }

.metrics { display: flex; flex-wrap: wrap; gap: 16px; }

.metric-pill {
  background: rgba(0,0,0,0.3);
  border-radius: 60px;
  padding: 5px 18px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.metric-pill i { font-size: 1.2rem; color: #b582ff; }
.metric-pill .label { font-size: 12px; color: #b1adcf; }
.metric-pill .value { font-weight: 500; font-size: 1rem; }

.action-btns, .admin-actions { display: flex; gap: 12px; flex-wrap: wrap; }

.outline-btn {
  background: transparent;
  border: 1px solid #4f4080;
  padding: 8px 24px;
  border-radius: 40px;
  color: #e5e0ff;
  cursor: pointer;
  transition: 0.2s;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.9rem;
}

.outline-btn:hover { background: #6946df; border-color: #6946df; color: white; }

.glass-card {
  background: rgba(16, 18, 38, 0.6);
  backdrop-filter: blur(16px);
  border: 1px solid rgba(255,255,255,0.05);
  border-radius: 36px;
  padding: 28px 32px;
  margin-bottom: 28px;
}

.card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 24px;
}

.card-header h3 {
  font-size: 1.4rem;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 12px;
}

.btn-primary {
  background: linear-gradient(100deg, #755ce6, #542ed0);
  border: none;
  padding: 14px 18px;
  border-radius: 44px;
  color: white;
  font-weight: 600;
  width: 100%;
  cursor: pointer;
  transition: 0.2s;
}

.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 12px 28px rgba(80, 50, 200, 0.4); }

.btn-filter {
  background: #2f2a5a;
  border: none;
  padding: 8px 24px;
  border-radius: 40px;
  color: white;
  cursor: pointer;
}

.btn-filter:hover { background: #4a3d8a; }

.menu-toggle {
  display: none;
  background: #2a2752;
  border: none;
  padding: 10px 20px;
  border-radius: 40px;
  color: white;
  margin-bottom: 18px;
  width: fit-content;
  cursor: pointer;
}

.status-badge {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 30px;
  font-size: 11px;
  font-weight: 500;
}

.status-completed { background: #1f3b2c; color: #a3e9c4; }
.status-processing { background: #3f2a47; color: #e2b0ff; }
.status-pending { background: #4a3e2c; color: #ffdfa5; }
.status-cancelled { background: #5a2a2a; color: #ffacac; }
.status-active { background: #1f3b2c; color: #a3e9c4; }
.status-blocked { background: #5a2a2a; color: #ffacac; }
.status-success { background: #1f3b2c; color: #a3e9c4; }

.flash-messages { position: fixed; top: 20px; right: 20px; z-index: 9999; max-width: 400px; }

.flash {
  padding: 14px 20px;
  border-radius: 16px;
  margin-bottom: 10px;
  backdrop-filter: blur(10px);
  animation: slideIn 0.3s ease;
}

.flash-success { background: rgba(31,59,44,0.95); border: 1px solid #a3e9c4; }
.flash-error { background: rgba(90,42,42,0.95); border: 1px solid #ffacac; }
.flash-info { background: rgba(47,42,90,0.95); border: 1px solid #b582ff; }

@keyframes slideIn {
  from { transform: translateX(100%); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}

@media (max-width: 1000px) {
  .main-content { padding: 20px; }
  .sidebar { position: fixed; left: -280px; top: 0; height: 100%; z-index: 200; }
  .sidebar.mobile-open { left: 0; }
  .menu-toggle { display: block; }
}

/* ——— Общие блоки панели ——— */
.panel-notice {
  margin-bottom: 20px;
  padding: 14px 20px;
  border-radius: 20px;
  font-size: 0.88rem;
  line-height: 1.5;
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.panel-notice--success {
  background: rgba(20, 83, 45, 0.25);
  border: 1px solid rgba(134, 239, 172, 0.35);
  color: #d1fae5;
}

.panel-notice--info {
  background: rgba(79, 70, 229, 0.2);
  border: 1px solid rgba(196, 181, 253, 0.25);
  color: #e9d5ff;
}

.panel-quick-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 12px;
  margin-bottom: 22px;
}

.panel-stat-chip {
  background: rgba(0, 0, 0, 0.28);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 20px;
  padding: 14px 16px;
  text-align: center;
}

.panel-stat-chip .label {
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #a9a4da;
  margin-bottom: 4px;
}

.panel-stat-chip .value {
  font-size: 1.1rem;
  font-weight: 600;
  color: #f0edff;
}

.panel-empty {
  text-align: center;
  padding: 28px 16px;
  color: #8a86b5;
  font-size: 0.9rem;
}

.panel-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  margin-bottom: 20px;
}

.status-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.status-chip {
  padding: 6px 14px;
  border-radius: 24px;
  font-size: 0.78rem;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: #d4d0f5;
  text-decoration: none;
  transition: 0.2s;
}

.status-chip:hover,
.status-chip.active {
  background: rgba(118, 70, 225, 0.35);
  border-color: rgba(196, 181, 253, 0.4);
  color: #fff;
}

.orders-mobile-list {
  display: none;
}

.order-mobile-card {
  background: #0c0e23;
  border-radius: 22px;
  padding: 16px 18px;
  margin-bottom: 12px;
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.order-mobile-card .row-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 10px;
}

.order-mobile-card .title {
  font-weight: 600;
  font-size: 0.92rem;
  line-height: 1.35;
}

.order-mobile-card .meta {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  font-size: 0.78rem;
  color: #a9a4da;
  margin-bottom: 12px;
}

.order-mobile-card .actions {
  display: flex;
  gap: 10px;
}

.copy-btn {
  background: #2f2a5a;
  border: none;
  color: #fff;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  cursor: pointer;
  flex-shrink: 0;
}

.table-desktop-only { display: table; width: 100%; }

@media (max-width: 768px) {
  .table-desktop-only,
  .orders-table-wrapper .orders-table {
    display: none;
  }

  .orders-mobile-list {
    display: block;
  }

  .orders-mini-table thead {
    display: none;
  }

  .orders-mini-table,
  .orders-mini-table tbody,
  .orders-mini-table tr,
  .orders-mini-table td {
    display: block;
    width: 100%;
  }

  .orders-mini-table tr {
    background: #0c0e23;
    border-radius: 18px;
    padding: 12px 14px;
    margin-bottom: 10px;
    border: 1px solid rgba(255, 255, 255, 0.06);
  }

  .orders-mini-table td {
    padding: 4px 0;
    border: none;
    display: flex;
    justify-content: space-between;
    gap: 12px;
  }

  .orders-mini-table td::before {
    content: attr(data-label);
    color: #8a86b5;
    font-size: 0.75rem;
  }

  .card-header h3 {
    font-size: 1.15rem;
  }

  .glass-card {
    padding: 20px 18px;
    border-radius: 28px;
  }
}
