/* Admin panel - layout like reference image */
.admin-page {
  margin: 0;
  min-height: 100vh;
}

/* Login screen */
.admin-login-screen {
  position: fixed;
  inset: 0;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  background: var(--bg-dark);
  z-index: 100000;
}

.admin-login-box {
  background: var(--bg-card);
  padding: 2rem;
  border-radius: 12px;
  border: 1px solid var(--border);
  max-width: 360px;
  width: 100%;
}

/* Hard guarantee: never show the admin UI behind the login overlay. */
#admin-dashboard[hidden] {
  display: none !important;
}

.admin-login-logo {
  display: flex;
  align-items: baseline;
  text-decoration: none;
  font-weight: 700;
  font-size: 1.75rem;
  letter-spacing: 0.02em;
  margin-bottom: 1.5rem;
  justify-content: center;
}

.admin-login-logo .logo-atg {
  color: #fff;
  margin-right: 0.2rem;
}

.admin-login-logo .logo-store {
  background: linear-gradient(90deg, var(--accent-purple), var(--accent-pink));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.admin-login-box h2 {
  margin-bottom: 1.2rem;
  color: var(--accent);
}

.admin-login-box input {
  width: 100%;
  padding: 0.7rem 1rem;
  margin-bottom: 0.8rem;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--bg-dark);
  color: var(--text);
  font-family: inherit;
}

.admin-login-box button {
  width: 100%;
  padding: 0.7rem;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: 6px;
  font-family: inherit;
  font-weight: 600;
  cursor: pointer;
  margin-top: 0.5rem;
}

.admin-login-hint {
  margin: 1rem 0 0;
  font-size: 0.82rem;
  line-height: 1.45;
  color: var(--text-muted, #64748b);
}

.admin-login-hint strong {
  font-weight: 600;
  color: var(--text);
}

.admin-login-back {
  display: block;
  text-align: center;
  margin-top: 1.25rem;
  font-size: 0.9rem;
  color: var(--accent);
  text-decoration: none;
}

.admin-login-back:hover {
  text-decoration: underline;
  color: var(--accent-hover);
}

/* Admin layout: sidebar + main */
.admin-layout {
  display: flex;
  min-height: 100vh;
}

/* Sidebar - dark blue/black (larger menu) */
.admin-sidebar {
  width: 300px;
  min-width: 300px;
  background: #1e293b;
  color: #e2e8f0;
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
}

.sidebar-brand {
  padding: 1.75rem 1.5rem;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}

.sidebar-brand strong {
  display: block;
  font-size: 1.4rem;
  color: #fff;
  letter-spacing: 0.02em;
}

.sidebar-sub {
  font-size: 0.9rem;
  color: #94a3b8;
  font-weight: 400;
  margin-top: 0.2rem;
}

.sidebar-nav {
  padding: 1rem 0;
}

.sidebar-link {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.85rem 1.5rem;
  color: #94a3b8;
  text-decoration: none;
  font-size: 1.05rem;
  transition: background 0.15s, color 0.15s;
}

.sidebar-link:hover {
  background: rgba(255,255,255,0.06);
  color: #e2e8f0;
}

.sidebar-link.active {
  background: #2563eb;
  color: #fff;
}

.sidebar-icon {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
}

.sidebar-link-disabled {
  opacity: 0.8;
}

.sidebar-badge {
  margin-left: auto;
  min-width: 24px;
  height: 24px;
  padding: 0 8px;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.sidebar-badge-yellow {
  background: #eab308;
  color: #1e293b;
}

.sidebar-badge-red {
  background: #dc2626;
  color: #fff;
}

.sidebar-tag {
  margin-left: auto;
  font-size: 0.78rem;
  padding: 0.3rem 0.6rem;
  background: #475569;
  color: #94a3b8;
  border-radius: 6px;
}

.sidebar-nav-sub .sidebar-link {
  padding: 0.7rem 1.5rem;
  font-size: 1rem;
}

.sidebar-nav-sub .sidebar-icon {
  display: none;
}

.sidebar-divider {
  height: 1px;
  background: rgba(255,255,255,0.08);
  margin: 0.6rem 0;
}

.admin-sidebar-account {
  padding: 0.75rem 1.5rem 0.25rem;
  margin: 0 0.75rem;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.admin-sidebar-account-label {
  display: block;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #64748b;
  margin-bottom: 0.35rem;
}

.admin-sidebar-account-name {
  display: block;
  font-size: 1.05rem;
  font-weight: 600;
  color: #f1f5f9;
  line-height: 1.3;
  word-break: break-word;
}

.admin-sidebar-account-meta {
  display: block;
  font-size: 0.82rem;
  color: #94a3b8;
  margin-top: 0.35rem;
  line-height: 1.35;
}

.admin-sidebar-account-meta #admin-sidebar-username {
  font-family: ui-monospace, monospace;
}

.admin-sidebar-account-sep {
  opacity: 0.7;
}

.sidebar-logout {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.9rem 1.5rem;
  margin: 0.6rem 1rem 1.25rem;
  background: transparent;
  border: none;
  color: #94a3b8;
  font-family: inherit;
  font-size: 1.05rem;
  cursor: pointer;
  transition: color 0.15s;
}

.sidebar-logout:hover {
  color: #e2e8f0;
}

/* Main content - light */
.admin-main {
  flex: 1;
  background: #f8fafc;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.admin-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.5rem;
  background: #fff;
  border-bottom: 1px solid #e2e8f0;
}

.admin-topbar-title {
  font-size: 1.35rem;
  font-weight: 700;
  color: #2563eb;
  margin: 0;
}

.admin-topbar-right {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.admin-welcome {
  font-size: 0.95rem;
  color: #475569;
}

.admin-topbar-logout {
  padding: 0.4rem 0.9rem;
  background: transparent;
  border: 1px solid #dc2626;
  color: #dc2626;
  border-radius: 6px;
  font-family: inherit;
  font-size: 0.9rem;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}

.admin-topbar-logout:hover {
  background: #dc2626;
  color: #fff;
}

.admin-content {
  flex: 1;
  padding: 1.5rem;
  overflow-y: auto;
}

/* Panels */
.admin-panel {
  display: none;
  max-width: 1200px;
}

.admin-panel.active {
  display: block;
}

.panel-title {
  font-size: 1.5rem;
  font-weight: 700;
  color: #0f172a;
  margin: 0 0 0.5rem 0;
}

.panel-welcome {
  font-size: 0.95rem;
  color: #64748b;
  margin: 0 0 1.5rem 0;
}

.panel-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.panel-date {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
  color: #64748b;
}

.panel-date svg {
  flex-shrink: 0;
  color: #94a3b8;
}

.panel-placeholder {
  color: #64748b;
  padding: 2rem 0;
}

.settings-storage-card {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 1.5rem;
  max-width: 520px;
  margin-top: 1rem;
}

.settings-card-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: #0f172a;
  margin: 0 0 0.5rem 0;
}

.settings-card-desc {
  color: #64748b;
  font-size: 0.9375rem;
  margin: 0 0 1rem 0;
  line-height: 1.5;
}

.settings-card-hint {
  color: #94a3b8;
  font-size: 0.8125rem;
  margin: 0.75rem 0 0 0;
}

.settings-currency-card {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 1.5rem;
  max-width: 520px;
  margin-top: 1rem;
}

.settings-currency-grid {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.settings-currency-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.settings-currency-row label {
  min-width: 60px;
  font-weight: 500;
  color: #334155;
}

.settings-currency-row input {
  width: 120px;
  padding: 0.5rem 0.75rem;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  font-size: 0.9375rem;
}

.settings-currency-row .settings-currency-code {
  color: #000;
  font-weight: 600;
}

.btn-save-currency-rates {
  padding: 0.6rem 1.25rem;
  background: #7c3aed;
  color: #fff;
  border: none;
  border-radius: 8px;
  font-family: inherit;
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
}

.btn-save-currency-rates:hover {
  background: #6d28d9;
}

.btn-free-storage {
  padding: 0.6rem 1.25rem;
  background: #dc2626;
  color: #fff;
  border: none;
  border-radius: 8px;
  font-family: inherit;
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
}

.btn-free-storage:hover {
  background: #b91c1c;
}

/* Wallpaper panel */
.wallpaper-card {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 1.5rem;
  margin-top: 1rem;
  max-width: 720px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
  cursor: pointer;
  transition: box-shadow 0.2s, border-color 0.2s;
}

.wallpaper-card:hover {
  border-color: #2563eb;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.15);
}

.wallpaper-card-title {
  font-size: 1.1rem;
  font-weight: 600;
  color: #0f172a;
  margin: 0 0 0.35rem 0;
}

.wallpaper-card-desc {
  font-size: 0.9rem;
  color: #64748b;
  margin: 0 0 1rem 0;
}

.wallpaper-preview {
  position: relative;
  width: 100%;
  height: 160px;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid #e2e8f0;
}

.wallpaper-preview-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.wallpaper-editor-card {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 1.5rem;
  margin-top: 1rem;
  max-width: 720px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.wallpaper-product-select-row {
  display: flex;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.wallpaper-product-select {
  flex: 1;
  padding: 0.6rem 1rem;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  font-family: inherit;
  font-size: 0.95rem;
  background: #fff;
}

.wallpaper-product-select:focus {
  outline: none;
  border-color: #2563eb;
}

.wallpaper-editor-row {
  display: flex;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.wallpaper-url-input {
  flex: 1;
  padding: 0.6rem 1rem;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  font-family: inherit;
  font-size: 0.95rem;
}

.wallpaper-url-input:focus {
  outline: none;
  border-color: #2563eb;
}

.wallpaper-save-btn {
  padding: 0.6rem 1.25rem;
  background: #2563eb;
  color: #fff;
  border: none;
  border-radius: 8px;
  font-family: inherit;
  font-weight: 600;
  cursor: pointer;
}

.wallpaper-save-btn:hover {
  background: #1d4ed8;
}

.panel-description {
  color: #64748b;
  font-size: 0.9375rem;
  margin: -0.25rem 0 1.25rem 0;
  max-width: 560px;
}

.tags-panel-header {
  margin-bottom: 1.5rem;
}

.tags-panel-header .panel-description {
  margin-bottom: 0;
}

.tags-manager {
  max-width: 840px;
  width: 100%;
}

.tags-add-card {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 1.25rem 1.5rem;
  margin-bottom: 1.5rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.tags-add-label {
  display: block;
  font-size: 0.8125rem;
  font-weight: 600;
  color: #475569;
  margin-bottom: 0.5rem;
  letter-spacing: 0.01em;
}

.tags-add-row {
  display: flex;
  gap: 0.75rem;
  align-items: center;
}

.tags-input {
  flex: 1;
  padding: 0.7rem 1rem;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  font-family: inherit;
  font-size: 0.9375rem;
  background: #fafafa;
  color: #0f172a;
  transition: border-color 0.15s, background 0.15s;
}

.tags-input:hover {
  background: #fff;
  border-color: #cbd5e1;
}

.tags-input::placeholder {
  color: #94a3b8;
}

.tags-input:focus {
  outline: none;
  border-color: #0f172a;
  background: #fff;
  box-shadow: 0 0 0 2px rgba(15, 23, 42, 0.08);
}

.btn-add-tag {
  padding: 0.7rem 1.35rem;
  background: #0f172a;
  color: #fff;
  border: none;
  border-radius: 10px;
  font-family: inherit;
  font-size: 0.9375rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s, transform 0.05s;
  flex-shrink: 0;
}

.btn-add-tag:hover {
  background: #334155;
}

.btn-add-tag:active {
  transform: scale(0.98);
}

/* Tags table */
.tags-table-wrap {
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.tags-table-wrap.hidden {
  display: none;
}

.tags-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9375rem;
  color: #0f172a;
}

.tags-table th {
  text-align: left;
  padding: 0.85rem 1.5rem;
  font-weight: 600;
  font-size: 0.8125rem;
  letter-spacing: 0.02em;
  color: #475569;
  background: #f8fafc;
  border-bottom: 1px solid #e2e8f0;
}

.tags-table td {
  padding: 0.85rem 1.5rem;
  border-bottom: 1px solid #f1f5f9;
  vertical-align: middle;
  transition: background 0.1s;
}

.tags-table tbody tr:hover td {
  background: #fafafa;
}

.tags-table tbody tr:last-child td {
  border-bottom: none;
}

.tags-table-num {
  width: 4rem;
  min-width: 4rem;
  color: #64748b;
  font-variant-numeric: tabular-nums;
}

.tags-table-name {
  color: #0f172a;
  min-width: 12rem;
  font-weight: 500;
}

.tags-table-actions-col {
  width: 8rem;
  min-width: 8rem;
  text-align: right;
  padding-right: 1.5rem;
}

.tags-action-btns {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
}

.tags-table .tag-action-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  padding: 0;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 8px;
  color: #64748b;
  cursor: pointer;
  transition: color 0.15s, background 0.15s, border-color 0.15s;
}

.tags-table .tag-action-btn svg {
  flex-shrink: 0;
}

.tags-table .tag-action-btn.tag-edit:hover {
  background: #eff6ff;
  border-color: #bfdbfe;
  color: #2563eb;
}

.tags-table .tag-action-btn.tag-remove:hover {
  background: #fef2f2;
  border-color: #fecaca;
  color: #dc2626;
}

/* Empty state */
.tags-empty {
  text-align: center;
  padding: 2.5rem 1.5rem;
  background: #f8fafc;
  border: 1px dashed #e2e8f0;
  border-radius: 12px;
  margin-top: 0;
}

.tags-empty.hidden {
  display: none;
}

.tags-empty-icon {
  display: block;
  font-size: 1.5rem;
  color: #cbd5e1;
  margin-bottom: 0.5rem;
}

.tags-empty p {
  margin: 0;
  font-size: 0.9375rem;
  color: #64748b;
}

/* ——— Product Types (Hierarchical) ——— */
.types-hier-header {
  margin-bottom: 1.5rem;
}

.types-hier-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}

.types-hier-title {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0;
}

.types-hier-icon {
  display: inline-flex;
  color: #3b82f6;
}

.types-hier-icon svg {
  width: 24px;
  height: 24px;
}

.types-hier-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.btn-seed-browse-types {
  display: inline-flex;
  align-items: center;
  padding: 0.6rem 1rem;
  background: #0f172a;
  color: #e2e8f0;
  border: 1px solid #334155;
  border-radius: 8px;
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  white-space: nowrap;
}

.btn-seed-browse-types:hover {
  background: #1e293b;
  border-color: #475569;
  color: #f8fafc;
}

.btn-seed-subtypes-all {
  display: inline-flex;
  align-items: center;
  padding: 0.6rem 1rem;
  background: #14532d;
  color: #dcfce7;
  border: 1px solid #166534;
  border-radius: 8px;
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  white-space: nowrap;
}
.btn-seed-subtypes-all:hover {
  background: #166534;
  border-color: #15803d;
  color: #f0fdf4;
}

.btn-create-type {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.6rem 1rem;
  background: #2563eb;
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 0.9375rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
}

.btn-create-type:hover {
  background: #1d4ed8;
}

.btn-create-type-plus {
  font-size: 1.1rem;
  line-height: 1;
}

.types-hier-description {
  margin: 0.75rem 0 0;
  font-size: 0.875rem;
  color: #64748b;
  line-height: 1.5;
  max-width: 56rem;
}

.types-table-wrap {
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  overflow: hidden;
  background: #fff;
}

.types-table-wrap.hidden {
  display: none;
}

.types-hier-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9375rem;
}

.types-hier-table th {
  text-align: left;
  padding: 0.85rem 1.5rem;
  font-weight: 600;
  background: #f8fafc;
  border-bottom: 1px solid #e2e8f0;
  color: #475569;
}

.types-hier-table td {
  padding: 0.85rem 1.5rem;
  border-bottom: 1px solid #f1f5f9;
  vertical-align: middle;
}

.types-hier-table tbody tr:last-child td {
  border-bottom: none;
}

.types-hier-table tbody tr:hover td {
  background: #fafafa;
}

.types-table-num {
  width: 4rem;
  min-width: 4rem;
  color: #64748b;
}

.types-table-name {
  color: #0f172a;
  min-width: 12rem;
  font-weight: 500;
}

.types-folder-icon {
  display: inline-flex;
  vertical-align: middle;
  margin-right: 0.35rem;
  color: #3b82f6;
}

.types-folder-icon svg {
  width: 18px;
  height: 18px;
}

.types-status-badge {
  display: inline-block;
  padding: 0.25rem 0.6rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
}

.types-status-active {
  background: #dcfce7;
  color: #166534;
}

.types-status-inactive {
  background: #fef2f2;
  color: #991b1b;
}

.types-sub-col {
  min-width: 10rem;
}

.types-view-subtypes-btn {
  padding: 0.35rem 0.65rem;
  background: #eff6ff;
  color: #2563eb;
  border: 1px solid #bfdbfe;
  border-radius: 6px;
  font-size: 0.8125rem;
  font-weight: 500;
  cursor: pointer;
}

.types-view-subtypes-btn:hover {
  background: #dbeafe;
  border-color: #93c5fd;
}

.types-no-subtypes {
  font-size: 0.8125rem;
  color: #64748b;
}

.types-add-subtypes-btn {
  font-weight: 600;
}

.types-empty {
  text-align: center;
  padding: 2.5rem 1.5rem;
  background: #f8fafc;
  border: 1px dashed #e2e8f0;
  border-radius: 12px;
  margin-top: 1rem;
}

.types-empty.hidden {
  display: none;
}

.types-empty-icon {
  display: block;
  font-size: 1.5rem;
  color: #cbd5e1;
  margin-bottom: 0.5rem;
}

.types-empty p {
  margin: 0;
  font-size: 0.9375rem;
  color: #64748b;
}

.types-table-actions-col {
  width: 8rem;
  min-width: 8rem;
  text-align: right;
}

.types-hier-table .tag-action-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  padding: 0;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #fff;
  color: #64748b;
  cursor: pointer;
  margin-left: 0.35rem;
}

.types-hier-table .tag-action-btn:hover {
  border-color: #cbd5e1;
}

.types-hier-table .tag-action-btn.tag-edit:hover {
  background: #eff6ff;
  border-color: #bfdbfe;
  color: #2563eb;
}

.types-hier-table .tag-action-btn.tag-remove:hover {
  background: #fef2f2;
  border-color: #fecaca;
  color: #dc2626;
}

.types-hier-table .tag-action-btn.type-move-up:hover,
.types-hier-table .tag-action-btn.type-move-down:hover,
.types-hier-table .tag-action-btn.subtype-move-up:hover,
.types-hier-table .tag-action-btn.subtype-move-down:hover {
  background: #f1f5f9;
  border-color: #94a3b8;
  color: #475569;
}

.types-drag-handle {
  display: inline-flex;
  vertical-align: middle;
  margin-right: 0.35rem;
  color: #94a3b8;
  cursor: grab;
}
.types-drag-handle:active {
  cursor: grabbing;
}
.types-draggable-row {
  cursor: grab;
}
.types-draggable-row:active {
  cursor: grabbing;
}
.types-draggable-row.types-dragging {
  opacity: 0.5;
  cursor: grabbing;
}
.types-draggable-row.types-drag-over {
  outline: 2px solid #2563eb;
  outline-offset: -2px;
  background: rgba(37, 99, 235, 0.08);
}

/* Sub-Types modal */
.types-subtypes-content .admin-modal-content {
  max-width: 560px;
}

.types-subtypes-actions {
  margin-bottom: 1rem;
}

.types-subtypes-table-wrap {
  margin-bottom: 0.5rem;
}

.types-subtypes-table-wrap.hidden {
  display: none;
}

.types-subtypes-empty {
  text-align: center;
  padding: 1.25rem;
  font-size: 0.9375rem;
  color: #64748b;
  background: #f8fafc;
  border-radius: 8px;
}

.types-subtypes-empty.hidden {
  display: none;
}

/* Inline expanded sub-types row — dark panel */
.types-sub-row {
  background: #1e293b;
}

.types-sub-row.types-sub-row-hidden {
  display: none;
}

.types-sub-row .types-expanded-cell {
  padding: 0;
  vertical-align: top;
  border-bottom: 1px solid #334155;
  background: #1e293b;
}

.types-expanded-inner {
  padding: 1rem 1.5rem 1.25rem;
}

.types-expanded-header {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 1rem;
  font-weight: 500;
  color: #e2e8f0;
}

.types-expanded-header .types-folder-icon {
  color: #93c5fd;
}

.types-expanded-header .types-view-subtypes-btn-inline {
  margin-left: 0.25rem;
}

.types-expanded-actions {
  margin-left: auto;
}

.types-expanded-actions-bar {
  margin-bottom: 0.75rem;
}

.types-sub-table-wrap {
  overflow-x: auto;
  border: 1px solid #334155;
  border-radius: 8px;
  background: #0f172a;
}

.types-sub-table {
  margin: 0;
}

.types-sub-table thead th {
  background: #334155;
  color: #94a3b8;
  font-size: 0.8125rem;
}

.types-sub-table tbody tr:nth-child(even) td {
  background: rgba(255, 255, 255, 0.03);
}

.types-sub-table tbody tr:nth-child(odd) td {
  background: #1e293b;
}

.types-sub-table tbody td {
  color: #e2e8f0;
  border-color: #334155;
}

.types-tag-icon {
  display: inline-flex;
  vertical-align: middle;
  margin-right: 0.35rem;
  color: #64748b;
}

.types-tag-icon svg {
  width: 16px;
  height: 16px;
}

.types-type-col {
  min-width: 6rem;
}

.types-type-label {
  font-size: 0.8125rem;
  color: #94a3b8;
  font-weight: 500;
}

.types-sub-row .types-tag-icon {
  color: #94a3b8;
}

/* Dark mode for Product Types */
.admin-page.admin-dark .types-table-wrap,
.admin-page.admin-dark .types-hier-table {
  background: var(--admin-dark-card);
  border-color: var(--admin-dark-border);
}

.admin-page.admin-dark .types-hier-table th {
  background: var(--admin-dark-elevated);
  color: var(--admin-dark-muted);
  border-bottom: 1px solid var(--admin-dark-border);
}

.admin-page.admin-dark .types-hier-table td {
  border-bottom: 1px solid var(--admin-dark-border);
  color: var(--admin-dark-text);
}

.admin-page.admin-dark .types-hier-table tbody tr:hover td {
  background: rgba(255, 255, 255, 0.03);
}

.admin-page.admin-dark .types-table-name,
.admin-page.admin-dark .types-folder-icon {
  color: #e2e8f0;
}

.admin-page.admin-dark .types-status-active {
  background: rgba(34, 197, 94, 0.2);
  color: #86efac;
}

.admin-page.admin-dark .types-status-inactive {
  background: rgba(239, 68, 68, 0.2);
  color: #fca5a5;
}

.admin-page.admin-dark .types-view-subtypes-btn {
  background: rgba(59, 130, 246, 0.2);
  color: #93c5fd;
  border-color: rgba(59, 130, 246, 0.4);
}

.admin-page.admin-dark .types-view-subtypes-btn:hover {
  background: rgba(59, 130, 246, 0.3);
}

.admin-page.admin-dark .btn-seed-browse-types {
  background: rgba(255, 255, 255, 0.08);
  color: #e2e8f0;
  border-color: rgba(255, 255, 255, 0.15);
}
.admin-page.admin-dark .btn-seed-browse-types:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.25);
}
.admin-page.admin-dark .btn-seed-subtypes-all {
  background: rgba(34, 197, 94, 0.2);
  color: #86efac;
  border-color: rgba(34, 197, 94, 0.4);
}
.admin-page.admin-dark .btn-seed-subtypes-all:hover {
  background: rgba(34, 197, 94, 0.3);
  border-color: rgba(34, 197, 94, 0.5);
}

.admin-page.admin-dark .types-empty,
.admin-page.admin-dark .types-subtypes-empty {
  background: rgba(255, 255, 255, 0.05);
  border-color: var(--admin-dark-border);
  color: var(--admin-dark-muted);
}

.admin-page.admin-dark .types-sub-row .types-expanded-cell {
  background: rgba(0, 0, 0, 0.2);
  border-bottom-color: var(--admin-dark-border);
}

.admin-page.admin-dark .types-expanded-header {
  color: var(--admin-dark-text);
}

.admin-page.admin-dark .types-sub-table-wrap {
  background: var(--admin-dark-card);
  border-color: var(--admin-dark-border);
}

.admin-page.admin-dark .types-sub-table thead th {
  background: var(--admin-dark-elevated);
  color: var(--admin-dark-muted);
  border-bottom: 1px solid var(--admin-dark-border);
}

.admin-page.admin-dark .types-sub-table tbody tr:nth-child(even) td {
  background: rgba(255, 255, 255, 0.02);
}

.admin-page.admin-dark .types-sub-table tbody tr:nth-child(odd) td {
  background: var(--admin-dark-card);
}

.admin-page.admin-dark .types-type-label,
.admin-page.admin-dark .types-tag-icon {
  color: var(--admin-dark-muted);
}

/* Edit tag modal */
.tags-form-row {
  margin-bottom: 1.25rem;
}

.tags-form-row label {
  display: block;
  font-size: 0.8125rem;
  font-weight: 600;
  color: #475569;
  margin-bottom: 0.4rem;
}

.tags-form-row .required {
  color: #dc2626;
}

.tags-edit-modal .admin-modal-content {
  max-width: 400px;
  border-radius: 12px;
  overflow: hidden;
}

.tags-edit-modal .tags-input {
  background: #fafafa;
}

.tags-edit-modal .tags-input:focus {
  background: #fff;
}

.tags-edit-actions {
  display: flex;
  gap: 0.75rem;
  margin-top: 1.5rem;
  padding-top: 0.25rem;
}

.btn-cancel-tag {
  padding: 0.65rem 1.15rem;
  background: #f8fafc;
  color: #475569;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  font-family: inherit;
  font-weight: 500;
  font-size: 0.9375rem;
  cursor: pointer;
  transition: background 0.15s;
}

.btn-cancel-tag:hover {
  background: #f1f5f9;
}

.btn-save-tag {
  padding: 0.65rem 1.15rem;
  background: #0f172a;
  color: #fff;
  border: none;
  border-radius: 10px;
  font-family: inherit;
  font-size: 0.9375rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s;
}

.btn-save-tag:hover {
  background: #334155;
}

/* Metric cards */
.metrics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 1.25rem;
}

.metric-card {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 1.25rem;
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.metric-card-featured {
  background: #2563eb;
  border-color: #2563eb;
  grid-column: 1 / -1;
  max-width: 400px;
}

.metric-card-featured .metric-label,
.metric-card-featured .metric-value {
  color: #fff;
}

.metric-icon {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.metric-icon svg {
  width: 24px;
  height: 24px;
}

.metric-icon-blue {
  background: rgba(37, 99, 235, 0.12);
  color: #2563eb;
}

.metric-icon-green {
  background: rgba(34, 197, 94, 0.12);
  color: #a855f7;
}

.metric-icon-yellow {
  background: rgba(234, 179, 8, 0.12);
  color: #eab308;
}

.metric-icon-red {
  background: rgba(220, 38, 38, 0.12);
  color: #dc2626;
}

.metric-icon-white {
  background: rgba(255,255,255,0.2);
  color: #fff;
}

.metric-body {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  min-width: 0;
}

.metric-label {
  font-size: 0.75rem;
  font-weight: 600;
  color: #64748b;
  letter-spacing: 0.02em;
}

.metric-value {
  font-size: 1.35rem;
  font-weight: 700;
  color: #0f172a;
}

/* Dashboard — top selling items */
.dashboard-top-selling {
  margin-top: 2rem;
  max-width: 1200px;
}

.dashboard-top-selling-head {
  margin-bottom: 1rem;
}

.dashboard-top-selling-title {
  margin: 0 0 0.35rem 0;
  font-size: 1.15rem;
  font-weight: 700;
  color: #0f172a;
  letter-spacing: -0.02em;
}

.dashboard-top-selling-sub {
  margin: 0;
  font-size: 0.875rem;
  color: #64748b;
  line-height: 1.45;
}

.dashboard-top-selling-sub strong {
  color: #475569;
  font-weight: 600;
}

.dashboard-top-selling-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.dashboard-top-selling-row {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.75rem 1rem;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.dashboard-top-selling-rank {
  flex-shrink: 0;
  width: 2rem;
  height: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  font-weight: 800;
  color: #2563eb;
  background: rgba(37, 99, 235, 0.1);
  border-radius: 8px;
}

.dashboard-top-selling-thumb {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  border-radius: 8px;
  object-fit: cover;
  background: #f1f5f9;
}

.dashboard-top-selling-main {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.dashboard-top-selling-name {
  font-weight: 600;
  font-size: 0.95rem;
  color: #0f172a;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dashboard-top-selling-meta {
  font-size: 0.8rem;
  color: #64748b;
}

.dashboard-top-selling-meta strong {
  color: #0f172a;
  font-weight: 600;
}

.dashboard-top-selling-empty {
  margin: 0;
  padding: 1.25rem 1rem;
  text-align: center;
  font-size: 0.9rem;
  color: #64748b;
  background: #f8fafc;
  border: 1px dashed #e2e8f0;
  border-radius: 10px;
}

/* Products panel — card toolbar (aligned with Orders panel) */
.admin-panel-products {
  --products-accent: #2563eb;
  --products-accent-dim: rgba(37, 99, 235, 0.14);
  --products-accent-border: rgba(37, 99, 235, 0.38);
}

/* Wide Products panel: full main column (no 1200px cap), slight side inset */
.admin-panel-products.admin-panel {
  max-width: min(100%, 1680px);
  width: 100%;
  margin-left: auto;
  margin-right: auto;
}

.admin-main .admin-content:has(#panel-products.active) {
  padding-left: max(1.25rem, env(safe-area-inset-left));
  padding-right: max(1.25rem, env(safe-area-inset-right));
}

.admin-panel-products .admin-products-card {
  border-radius: 12px;
  border-left: 1px solid var(--products-accent-border);
  border-right: 1px solid var(--products-accent-border);
}

.admin-products-card {
  background: var(--bg-card);
  border-radius: 14px;
  border: 1px solid var(--products-accent-border);
  overflow: hidden;
  box-shadow:
    0 0 0 1px rgba(0, 0, 0, 0.03),
    0 4px 20px rgba(0, 0, 0, 0.06),
    0 2px 8px rgba(0, 0, 0, 0.04);
}

.admin-products-header {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem 1.5rem;
  padding: 1.35rem 1.6rem;
  background: linear-gradient(
    145deg,
    var(--products-accent-dim) 0%,
    rgba(37, 99, 235, 0.05) 50%,
    rgba(0, 0, 0, 0.02) 100%
  );
  border-bottom: 2px solid var(--products-accent);
}

.admin-products-title-wrap {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  flex: 1 1 200px;
  min-width: 0;
}

.admin-products-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  background: linear-gradient(145deg, var(--products-accent-dim) 0%, rgba(37, 99, 235, 0.1) 100%);
  border-radius: 12px;
  color: var(--products-accent);
  flex-shrink: 0;
  box-shadow: 0 2px 10px rgba(37, 99, 235, 0.18);
}

.admin-products-panel-title {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.01em;
}

.admin-products-desc {
  margin: 0.35rem 0 0 0;
  font-size: 0.875rem;
  color: var(--text-muted);
  max-width: 520px;
  line-height: 1.45;
}

.admin-products-toolbar {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.admin-products-toolbar-main {
  flex: 1 1 min(100%, 380px);
  min-width: 0;
  justify-content: space-between;
  align-items: flex-end;
  gap: 1rem 1.25rem;
}

.admin-products-toolbar-buttons {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  flex-wrap: wrap;
  flex-shrink: 0;
}

.admin-products-filter-search-wrap {
  flex: 1 1 220px;
  min-width: min(100%, 180px);
}

.admin-products-toolbar-main .admin-products-filter {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  flex: 1;
  min-width: 0;
}

.admin-products-toolbar-main .admin-products-filter label {
  font-size: 0.9rem;
  color: var(--text-muted);
  font-weight: 600;
  flex-shrink: 0;
}

.admin-products-toolbar-main .admin-products-filter input[type='search'],
.admin-products-toolbar-main .admin-products-filter input[type='text'] {
  flex: 1;
  min-width: 0;
  padding: 0.55rem 0.95rem;
  background: var(--bg-dark);
  border: 1px solid var(--products-accent-border);
  border-radius: 10px;
  color: var(--text);
  font-family: inherit;
  font-size: 0.9rem;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.admin-products-toolbar-main .admin-products-filter input:focus {
  outline: none;
  border-color: var(--products-accent);
  box-shadow: 0 0 0 3px var(--products-accent-dim);
}

/* Grid keeps filters on one row on desktop; equal-width columns = aligned controls */
.admin-products-toolbar-filters.admin-products-toolbar {
  display: grid;
  width: 100%;
  margin-top: 0.15rem;
  padding-top: 1rem;
  border-top: 1px solid var(--products-accent-border);
  align-items: end;
  gap: 0.65rem 0.85rem;
  grid-template-columns: repeat(4, minmax(0, 1fr)) auto;
}

.admin-products-filter-field {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  min-width: 0;
}

.admin-products-filter-field label {
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  line-height: 1.2;
}

.admin-products-filter-field select {
  width: 100%;
  min-width: 0;
  max-width: none;
  padding: 0.5rem 2rem 0.5rem 0.75rem;
  background-color: var(--bg-dark);
  border: 1px solid var(--products-accent-border);
  border-radius: 8px;
  color: var(--text);
  font-family: inherit;
  font-size: 0.875rem;
  cursor: pointer;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' fill='none' stroke='%2394a3b8' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 6l3 3 3-3'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.6rem center;
  background-size: 14px;
}

.admin-products-filter-field select:hover,
.admin-products-filter-field select:focus {
  border-color: var(--products-accent);
}

.admin-products-filter-field select:focus {
  outline: none;
  box-shadow: 0 0 0 2px var(--products-accent-dim);
}

.admin-products-toolbar-filters .admin-products-clear-filters-btn {
  justify-self: start;
  align-self: end;
}

.admin-products-clear-filters-btn {
  padding: 0.5rem 1rem;
  margin-bottom: 1px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--bg-dark);
  color: var(--text-muted);
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  transition: color 0.15s ease, border-color 0.15s ease, background 0.15s ease;
}

.admin-products-clear-filters-btn:hover {
  color: var(--text);
  border-color: var(--products-accent);
  background: var(--products-accent-dim);
}

/* Table + pagination inside card (UNIC cyan / purple accents) */
.admin-panel-products .admin-products-card .products-table-wrap {
  background: var(--bg-dark);
  border: none;
  border-radius: 0;
  border-top: 1px solid rgba(var(--unic-cyan-rgb), 0.3);
  margin-bottom: 0;
  box-shadow: inset 0 1px 0 rgba(var(--unic-cyan-rgb), 0.12);
}

.admin-panel-products .admin-products-card .products-table th {
  background: linear-gradient(
    180deg,
    rgba(var(--unic-cyan-rgb), 0.2) 0%,
    rgba(var(--unic-purple-rgb), 0.1) 100%
  );
  color: var(--unic-cyan);
  border-bottom: 1px solid rgba(var(--unic-cyan-rgb), 0.35);
  font-size: 0.72rem;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.admin-panel-products .admin-products-card .products-table td {
  color: #e4e4ec;
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
}

.admin-panel-products .admin-products-card .products-table tbody tr:hover {
  background: rgba(var(--unic-cyan-rgb), 0.08);
}

.admin-panel-products .admin-products-card .product-cell-title .title-main {
  color: #ffffff;
}

.admin-panel-products .admin-products-card .product-cell-title .title-slug {
  color: rgba(var(--unic-cyan-rgb), 0.95);
}

.admin-panel-products .admin-products-card .product-cell-title img {
  background: rgba(var(--unic-purple-rgb), 0.12);
  box-shadow: 0 0 0 1px rgba(var(--unic-cyan-rgb), 0.35);
}

.admin-panel-products .admin-products-card .pill-platform {
  background: rgba(255, 255, 255, 0.08);
  color: #e2e8f0;
  border: 1px solid rgba(var(--unic-purple-rgb), 0.4);
  font-weight: 600;
}

.admin-panel-products .admin-products-card .pill-type {
  background: linear-gradient(135deg, var(--unic-cyan) 0%, #00b894 100%);
  color: #041016;
  font-weight: 600;
  border: none;
}

.admin-panel-products .admin-products-card .pill-status {
  background: linear-gradient(135deg, var(--unic-purple) 0%, #7c3aed 100%);
  color: #fff;
}

.admin-panel-products .admin-products-card .pill-status.inactive {
  background: rgba(148, 163, 184, 0.35);
  color: #e2e8f0;
}

.admin-panel-products .admin-products-card .btn-action-add {
  background: rgba(var(--unic-cyan-rgb), 0.16);
  color: var(--unic-cyan);
  border: 1px solid rgba(var(--unic-cyan-rgb), 0.45);
}

.admin-panel-products .admin-products-card .btn-action-edit {
  background: linear-gradient(180deg, var(--unic-cyan) 0%, #00b894 100%);
  color: #041016;
  font-weight: 700;
}

.admin-panel-products .admin-products-card .products-pagination {
  padding: 1rem 1.35rem;
  background: var(--bg-card);
  border-top: 1px solid rgba(var(--unic-cyan-rgb), 0.22);
  color: var(--text-muted);
}

.admin-panel-products .admin-products-card .pagination-controls button {
  background: var(--bg-dark);
  border-color: rgba(var(--unic-cyan-rgb), 0.25);
  color: var(--text);
}

.admin-panel-products .admin-products-card .pagination-controls button:hover {
  background: rgba(var(--unic-cyan-rgb), 0.12);
  border-color: rgba(var(--unic-cyan-rgb), 0.5);
  color: var(--unic-cyan);
}

.admin-panel-products .admin-products-card .pagination-controls button.active {
  background: linear-gradient(180deg, var(--unic-cyan) 0%, #00a88c 100%);
  border-color: var(--unic-cyan);
  color: #041016;
  font-weight: 700;
}

@media (max-width: 900px) {
  .admin-products-toolbar-filters.admin-products-toolbar {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .admin-products-toolbar-filters .admin-products-clear-filters-btn {
    grid-column: 1 / -1;
  }
}

@media (max-width: 520px) {
  .admin-products-toolbar-filters.admin-products-toolbar {
    grid-template-columns: 1fr;
  }
}

/* Only stack search + action buttons on very narrow widths (not full tablet breakpoint) */
@media (max-width: 560px) {
  .admin-products-toolbar-main {
    flex-direction: column;
    align-items: stretch;
  }

  .admin-products-toolbar-main .admin-products-filter {
    max-width: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0.35rem;
  }

  .admin-products-toolbar-main .admin-products-filter label {
    font-size: 0.8rem;
  }

  .admin-products-toolbar-buttons {
    flex-direction: column;
    align-items: stretch;
  }

  .admin-products-toolbar-buttons .btn-add-product,
  .admin-products-toolbar-buttons .btn-delete-all-products {
    width: 100%;
    justify-content: center;
  }
}

/* Neon dark admin: form controls match the panel (native selects often ignore var(--bg-dark)) */
.admin-page.admin-dark .admin-panel-products .admin-products-filter-field select,
.admin-page.admin-dark .admin-panel-products .admin-products-toolbar-main .admin-products-filter input[type='search'],
.admin-page.admin-dark .admin-panel-products .admin-products-toolbar-main .admin-products-filter input[type='text'] {
  background-color: var(--admin-dark-elevated);
  border-color: var(--admin-neon-border);
  color: var(--admin-dark-text);
}

.admin-page.admin-dark .admin-panel-products .admin-products-filter-field select:focus,
.admin-page.admin-dark .admin-panel-products .admin-products-toolbar-main .admin-products-filter input:focus {
  border-color: var(--admin-neon-cyan);
  box-shadow: 0 0 0 2px rgba(var(--admin-neon-cyan-rgb), 0.25);
}

.admin-page.admin-dark .admin-panel-products .admin-products-clear-filters-btn {
  background: rgba(255, 255, 255, 0.06);
  border-color: var(--admin-neon-border);
  color: var(--admin-neon-cyan);
}

.admin-page.admin-dark .admin-panel-products .admin-products-clear-filters-btn:hover {
  background: rgba(var(--admin-neon-cyan-rgb), 0.15);
  border-color: var(--admin-neon-cyan);
  color: #fff;
}

.admin-page.admin-dark .admin-panel-products .admin-products-header {
  background: linear-gradient(
    145deg,
    rgba(var(--admin-neon-cyan-rgb), 0.14) 0%,
    rgba(var(--admin-neon-cyan-rgb), 0.05) 55%,
    transparent 100%
  );
  border-bottom-color: var(--admin-neon-cyan);
}

.admin-page.admin-dark .admin-panel-products {
  color-scheme: dark;
}

.btn-import-steam {
  padding: 0.5rem 1rem;
  background: #0d9488;
  color: #fff;
  border: none;
  border-radius: 6px;
  font-family: inherit;
  font-weight: 600;
  cursor: pointer;
  font-size: 0.9rem;
}
.btn-import-steam:hover {
  background: #0f766e;
}

.btn-add-product {
  padding: 0.5rem 1rem;
  background: #2563eb;
  color: #fff;
  border: none;
  border-radius: 6px;
  font-family: inherit;
  font-weight: 600;
  cursor: pointer;
}

.btn-add-product:hover {
  background: #1d4ed8;
}

.btn-delete-all-products {
  padding: 0.5rem 1rem;
  background: #dc2626;
  color: #fff;
  border: none;
  border-radius: 6px;
  font-family: inherit;
  font-weight: 600;
  cursor: pointer;
  margin-left: 0.5rem;
}

.btn-delete-all-products:hover {
  background: #b91c1c;
}

/* Create New Product Listing panel - premium UI v2 */
.admin-panel-create {
  max-width: none;
  padding: 0;
  min-height: 100%;
  padding-bottom: 2rem;
  background: #f0f4f8;
  background-image:
    radial-gradient(ellipse 120% 80% at 50% -20%, rgba(37, 99, 235, 0.08), transparent),
    radial-gradient(ellipse 80% 50% at 100% 50%, rgba(124, 58, 237, 0.04), transparent),
    radial-gradient(ellipse 80% 50% at 0% 80%, rgba(5, 150, 105, 0.04), transparent);
}

.create-product-header-bar {
  position: relative;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1.5rem;
  margin-bottom: 1.75rem;
  padding: 1.75rem 2rem;
  padding-left: 2.25rem;
  background: #fff;
  border-radius: 16px;
  border: 1px solid rgba(226, 232, 240, 0.9);
  box-shadow: 0 4px 20px rgba(0,0,0,0.04), 0 1px 3px rgba(0,0,0,0.02), inset 0 1px 0 rgba(255,255,255,0.8);
  overflow: hidden;
}

.create-product-header-accent {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 5px;
  background: linear-gradient(180deg, #2563eb 0%, #3b82f6 50%, #1d4ed8 100%);
  opacity: 0.95;
}

.create-product-header-left {
  flex: 1;
  min-width: 0;
}

.create-product-title-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.35rem;
}

.create-product-main-title {
  font-size: 1.65rem;
  font-weight: 800;
  color: #0f172a;
  margin: 0;
  letter-spacing: -0.03em;
  line-height: 1.25;
}

.create-product-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.2rem 0.55rem;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #6d28d9;
  background: rgba(5, 150, 105, 0.12);
  border-radius: 6px;
  border: 1px solid rgba(5, 150, 105, 0.25);
}

.create-product-star {
  color: #f59e0b;
  font-size: 1.25rem;
  margin-left: 0.2rem;
  filter: drop-shadow(0 0 8px rgba(245, 158, 11, 0.35));
}

.create-product-instruction {
  font-size: 0.93rem;
  color: #64748b;
  margin: 0 0 1rem 0;
  line-height: 1.5;
}

.create-product-steps {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.create-step {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  font-size: 0.75rem;
  font-weight: 700;
  color: #94a3b8;
  background: #f1f5f9;
  border: 2px solid #e2e8f0;
  transition: all 0.25s ease;
}

.create-step-done {
  color: #fff;
  background: linear-gradient(135deg, #2563eb, #3b82f6);
  border-color: #2563eb;
  box-shadow: 0 2px 6px rgba(37, 99, 235, 0.3);
}

.create-step-line {
  width: 24px;
  height: 2px;
  background: linear-gradient(90deg, #cbd5e1, #e2e8f0);
  border-radius: 1px;
}

.btn-back-to-list {
  flex-shrink: 0;
  padding: 0.6rem 1.2rem;
  font-size: 0.9rem;
  color: #475569;
  text-decoration: none;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  background: #fff;
  font-family: inherit;
  font-weight: 600;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-back-to-list:hover {
  border-color: #2563eb;
  color: #2563eb;
  background: #eff6ff;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.15);
  transform: translateY(-1px);
}

.btn-back-to-list:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.25);
}

.create-product-form {
  max-width: 100%;
  width: 100%;
}

.create-product-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  align-items: start;
}

.create-product-section {
  margin-bottom: 0;
}

.create-product-card {
  background: #fff;
  border: 1px solid rgba(226, 232, 240, 0.9);
  border-radius: 16px;
  padding: 1.85rem;
  box-shadow: 0 4px 16px rgba(0,0,0,0.04), 0 1px 3px rgba(0,0,0,0.02), inset 0 1px 0 rgba(255,255,255,0.9);
  transition: box-shadow 0.3s cubic-bezier(0.4, 0, 0.2, 1), border-color 0.3s ease, transform 0.25s ease;
  position: relative;
  overflow: hidden;
}

.create-product-card::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 5px;
  border-radius: 16px 0 0 16px;
}

.create-product-card-1::before { background: linear-gradient(180deg, #2563eb 0%, #3b82f6 50%, #60a5fa 100%); }
.create-product-card-2::before { background: linear-gradient(180deg, #6d28d9 0%, #8b5cf6 50%, #a855f7 100%); }
.create-product-card-3::before { background: linear-gradient(180deg, #7c3aed 0%, #8b5cf6 50%, #a78bfa 100%); }

.create-product-card:hover {
  border-color: #cbd5e1;
  box-shadow: 0 12px 32px rgba(0,0,0,0.08), 0 4px 12px rgba(0,0,0,0.04);
  transform: translateY(-2px);
}

.create-section-title {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  font-size: 1.1rem;
  font-weight: 700;
  color: #0f172a;
  margin: 0 0 1.4rem 0;
  padding-bottom: 1rem;
  border-bottom: 2px solid #f1f5f9;
  letter-spacing: -0.02em;
  position: relative;
}

.section-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 12px;
  color: #fff;
  font-size: 0.95rem;
  font-weight: 800;
  box-shadow: 0 3px 10px rgba(0,0,0,0.2), inset 0 1px 0 rgba(255,255,255,0.25);
  text-shadow: 0 1px 1px rgba(0,0,0,0.15);
}

.create-product-card-1 .section-num { background: linear-gradient(145deg, #2563eb 0%, #3b82f6 50%, #60a5fa 100%); }
.create-product-card-2 .section-num { background: linear-gradient(145deg, #6d28d9 0%, #8b5cf6 50%, #a855f7 100%); }
.create-product-card-3 .section-num { background: linear-gradient(145deg, #7c3aed 0%, #8b5cf6 50%, #a78bfa 100%); }

.create-product-form .form-row {
  margin-bottom: 1.1rem;
}

.create-product-form .form-row:last-child {
  margin-bottom: 0;
}

.create-product-form .form-row label {
  display: block;
  font-size: 0.82rem;
  font-weight: 600;
  color: #334155;
  margin-bottom: 0.45rem;
  letter-spacing: 0.02em;
}

.create-product-form .form-row input[type="text"],
.create-product-form .form-row input[type="number"],
.create-product-form .form-row input[type="url"],
.create-product-form .form-row input[type="datetime-local"],
.create-product-form .form-row select,
.create-product-form .form-row textarea {
  width: 100%;
  padding: 0.75rem 1.05rem;
  border: 1px solid #e2e8f0;
  border-radius: 11px;
  font-family: inherit;
  font-size: 0.95rem;
  color: #0f172a;
  background: #fafbfc;
  box-shadow: inset 0 1px 2px rgba(0,0,0,0.04);
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.create-product-form .form-row input:hover,
.create-product-form .form-row select:hover,
.create-product-form .form-row textarea:hover {
  background: #fff;
  border-color: #cbd5e1;
  box-shadow: inset 0 1px 2px rgba(0,0,0,0.03);
}

.create-product-form .form-row input::placeholder,
.create-product-form .form-row textarea::placeholder {
  color: #94a3b8;
}

.create-product-form .form-row input:focus,
.create-product-form .form-row select:focus,
.create-product-form .form-row textarea:focus {
  outline: none;
  border-color: #2563eb;
  background: #fff;
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1), inset 0 1px 2px rgba(0,0,0,0.03);
}

.create-product-form .form-row input:focus-visible,
.create-product-form .form-row select:focus-visible,
.create-product-form .form-row textarea:focus-visible {
  outline: none;
}

.create-product-form .form-row textarea {
  resize: vertical;
  min-height: 100px;
  line-height: 1.5;
}

.create-product-form .form-row select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23475569' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.85rem center;
  padding-right: 2.25rem;
}

.create-product-form .required {
  color: #dc2626;
  font-weight: 700;
  margin-left: 0.1rem;
}

/* Saved tags in Create Product form — shown when Tags input is focused */
.create-product-tags-row .saved-tags-wrap {
  display: none;
  margin-top: 0.75rem;
}

.create-product-tags-row .saved-tags-wrap.has-tags.is-visible {
  display: block;
}

.create-product-tags-row .saved-tags-label {
  font-size: 0.8rem;
  font-weight: 600;
  color: #64748b;
  margin-bottom: 0.4rem;
}

.create-product-tags-row .saved-tags-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.create-product-tags-row .saved-tag-chip {
  padding: 0.35rem 0.65rem;
  font-size: 0.8125rem;
  font-family: inherit;
  color: #475569;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}

.create-product-tags-row .saved-tag-chip:hover {
  background: #e2e8f0;
  border-color: #cbd5e1;
  color: #0f172a;
}

.form-hint {
  display: block;
  font-size: 0.78rem;
  color: #94a3b8;
  margin-top: 0.3rem;
}

/* Styled file upload */
.file-upload-wrap {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-top: 0.5rem;
}

.file-input-hidden {
  position: absolute;
  width: 0.1px;
  height: 0.1px;
  opacity: 0;
  overflow: hidden;
  z-index: -1;
}

.file-upload-label {
  display: inline-flex;
  align-items: center;
  padding: 0.55rem 1.15rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: #475569;
  background: #f8fafc;
  border: 2px dashed #cbd5e1;
  border-radius: 11px;
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 1px 2px rgba(0,0,0,0.04);
}

.file-upload-label:hover {
  background: #eff6ff;
  border-color: #93c5fd;
  color: #2563eb;
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.12);
}

.file-upload-hint {
  font-size: 0.8rem;
  color: #94a3b8;
}

.create-field-hint {
  font-size: 0.8rem;
  color: #64748b;
  margin: 0 0 0.5rem 0;
  line-height: 1.4;
}

.input-url {
  background: #fafafa !important;
}

/* Price block highlight */
.price-block {
  background: linear-gradient(135deg, rgba(37, 99, 235, 0.06) 0%, rgba(59, 130, 246, 0.08) 100%);
  border-radius: 14px;
  padding: 1.15rem;
  margin-bottom: 0.5rem;
  border: 1px solid rgba(37, 99, 235, 0.15);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.5);
}

.create-product-form .two-cols {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.create-product-form .three-cols {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 1rem;
}

.create-product-form .four-cols {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr 1fr;
  gap: 1rem;
}

.create-product-section-sales {
  grid-column: 2;
}

.create-product-footer {
  margin-top: 1.85rem;
  padding: 1.6rem 2rem;
  background: #fff;
  border-radius: 16px;
  border: 1px solid rgba(226, 232, 240, 0.9);
  box-shadow: 0 4px 16px rgba(0,0,0,0.04), inset 0 1px 0 rgba(255,255,255,0.9);
  display: flex;
  justify-content: flex-end;
  align-items: center;
}

.btn-create-product {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  padding: 1rem 2.15rem;
  background: linear-gradient(145deg, #2563eb 0%, #1d4ed8 50%, #1e40af 100%);
  color: #fff;
  border: none;
  border-radius: 12px;
  font-family: inherit;
  font-size: 1.1rem;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 4px 16px rgba(37, 99, 235, 0.4), inset 0 1px 0 rgba(255,255,255,0.2);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  letter-spacing: 0.03em;
  text-shadow: 0 1px 2px rgba(0,0,0,0.1);
}

.btn-create-product:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(37, 99, 235, 0.45), inset 0 1px 0 rgba(255,255,255,0.25);
  background: linear-gradient(145deg, #3b82f6 0%, #2563eb 50%, #1d4ed8 100%);
}

.btn-create-product:active {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.4);
}

.btn-create-product:focus-visible {
  outline: none;
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.35);
}

.btn-create-icon {
  font-size: 1.4rem;
  font-weight: 400;
  line-height: 1;
  opacity: 0.95;
}

@media (max-width: 1100px) {
  .create-product-grid {
    grid-template-columns: 1fr;
  }
  .create-product-section-sales {
    grid-column: 1;
  }
}

@media (max-width: 900px) {
  .create-product-form .four-cols {
    grid-template-columns: 1fr 1fr;
  }
  .create-product-form .three-cols {
    grid-template-columns: 1fr;
  }
  .checkbox-group,
  .radio-group {
    flex-direction: column;
  }
  .create-product-header-bar {
    flex-direction: column;
    align-items: stretch;
  }
  .btn-back-to-list {
    align-self: flex-end;
  }
}

/* ========== MOBILE ADMIN — SIMPLE & EASY ========== */
.admin-menu-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  padding: 0;
  margin: 0 0.25rem 0 0;
  background: transparent;
  border: none;
  border-radius: 12px;
  color: #64748b;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
  -webkit-tap-highlight-color: transparent;
}

.admin-menu-toggle:hover {
  background: #f1f5f9;
  color: #0f172a;
}

.admin-menu-icon {
  width: 28px;
  height: 28px;
}

.admin-sidebar-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 998;
  background: rgba(0, 0, 0, 0.5);
  opacity: 0;
  transition: opacity 0.2s ease;
  pointer-events: none;
}

.admin-sidebar-overlay.is-visible {
  pointer-events: auto;
  opacity: 1;
}

@media (max-width: 768px) {
  .admin-menu-toggle {
    display: inline-flex;
  }

  .admin-sidebar-overlay {
    display: block;
  }

  .admin-layout {
    position: relative;
  }

  .admin-sidebar {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    z-index: 999;
    width: 280px;
    max-width: 88vw;
    transform: translateX(-100%);
    transition: transform 0.25s ease;
    box-shadow: none;
    padding-top: 0.5rem;
  }

  body.admin-sidebar-open .admin-sidebar {
    transform: translateX(0);
    box-shadow: 10px 0 30px rgba(0, 0, 0, 0.25);
  }

  .sidebar-brand {
    padding: 1.5rem 1.25rem;
  }

  .sidebar-link {
    padding: 0.9rem 1.5rem;
    font-size: 1.05rem;
    min-height: 56px;
    display: flex;
    align-items: center;
    gap: 1rem;
  }

  .sidebar-nav-sub .sidebar-link {
    padding: 0.75rem 1.5rem;
    min-height: 52px;
    font-size: 1rem;
  }

  .admin-sidebar-account {
    margin: 0 0.5rem;
    padding: 0.65rem 1rem 0.2rem;
  }

  .sidebar-logout {
    padding: 0.9rem 1.5rem;
    min-height: 56px;
    font-size: 1.05rem;
    margin: 0.6rem 1rem 1.25rem;
  }

  .admin-main {
    width: 100%;
    min-width: 0;
  }

  .admin-topbar {
    padding: 0.85rem 1rem;
    gap: 0.5rem;
    flex-wrap: wrap;
  }

  .admin-topbar-title {
    font-size: 1.15rem;
    flex: 1;
    min-width: 0;
  }

  .admin-topbar-right {
    gap: 0.5rem;
  }

  .admin-welcome {
    display: none;
  }

  .admin-topbar-logout {
    padding: 0.5rem 0.9rem;
    font-size: 0.9rem;
    min-height: 44px;
    border-radius: 10px;
  }

  .admin-content {
    padding: 1.25rem 1rem;
    padding-bottom: max(1.25rem, env(safe-area-inset-bottom));
  }

  .panel-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
    margin-bottom: 1.25rem;
  }

  .panel-title {
    font-size: 1.35rem;
  }

  .panel-date {
    font-size: 0.9rem;
  }

  /* Dashboard — big numbers, clear labels */
  .metrics-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
  }

  .metric-card {
    padding: 1.25rem 1rem;
    min-height: 0;
    border-radius: 14px;
  }

  .metric-card-featured {
    max-width: none;
    grid-column: 1 / -1;
    padding: 1.5rem 1.25rem;
    border-radius: 14px;
  }

  .metric-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
  }

  .metric-icon svg {
    width: 24px;
    height: 24px;
  }

  .metric-body {
    gap: 0.35rem;
  }

  .metric-label {
    font-size: 0.75rem;
    letter-spacing: 0.03em;
  }

  .metric-value {
    font-size: 1.5rem;
  }

  .metric-card-featured .metric-value {
    font-size: 1.6rem;
  }

  .btn-add-product {
    padding: 0.85rem 1.25rem;
    font-size: 1rem;
    border-radius: 12px;
  }

  .products-table-wrap {
    margin: 0 -1rem;
    border-radius: 0;
    -webkit-overflow-scrolling: touch;
  }

  .admin-products-card .products-table-wrap {
    margin: 0;
  }

  .products-table th,
  .products-table td {
    padding: 0.75rem 0.85rem;
    font-size: 0.9rem;
  }

  .product-cell-title img {
    width: 44px;
    height: 44px;
  }

  .admin-support-header,
  .admin-users-header {
    flex-direction: column;
    align-items: stretch;
    gap: 1rem;
  }

  .admin-support-toolbar,
  .admin-users-toolbar {
    flex-direction: column;
    align-items: stretch;
    gap: 0.75rem;
  }

  .admin-support-filter input[type="text"],
  .admin-users-filter input[type="text"] {
    min-width: 0;
    width: 100%;
    padding: 0.7rem 1rem;
  }

  .admin-support-refresh,
  .admin-users-refresh-btn {
    width: 100%;
    justify-content: center;
    padding: 0.75rem 1rem;
    min-height: 48px;
  }

  .admin-support-table-wrap,
  .admin-users-table-wrap {
    margin: 0 -1rem;
    -webkit-overflow-scrolling: touch;
  }

  .admin-support-table th,
  .admin-support-table td,
  .admin-users-table th,
  .admin-users-table td {
    padding: 0.75rem 0.85rem;
    font-size: 0.9rem;
  }

  .admin-modal {
    padding: 0.5rem;
    align-items: flex-end;
  }

  .admin-modal-content {
    max-height: 90vh;
    border-radius: 20px 20px 0 0;
    width: 100%;
    max-width: 100%;
    padding: 1.5rem;
  }

  .admin-modal-inventory {
    max-height: 92vh;
  }

  .admin-modal-content.add-inventory-modal {
    width: 100%;
    max-width: 100%;
    border-radius: 20px 20px 0 0;
  }

  .inventory-modal-header {
    flex-direction: column;
    align-items: stretch;
    gap: 0.5rem;
  }

  .inventory-section-head {
    flex-wrap: wrap;
    gap: 0.75rem;
  }

  .btn-add-single-item {
    width: 100%;
    justify-content: center;
    padding: 0.75rem 1rem;
    min-height: 48px;
  }

  .inventory-table-wrap {
    -webkit-overflow-scrolling: touch;
  }

  .wallpaper-product-select-row {
    flex-direction: column;
    gap: 0.75rem;
  }

  .wallpaper-save-btn {
    width: 100%;
    padding: 0.75rem 1rem;
    min-height: 48px;
  }

  .tags-add-row {
    flex-direction: column;
    gap: 0.75rem;
  }

  .btn-add-tag {
    width: 100%;
    padding: 0.75rem 1rem;
    min-height: 48px;
  }

  .create-product-header-bar {
    padding: 1.25rem 1rem;
  }

  .create-product-main-title {
    font-size: 1.4rem;
  }

  .create-product-footer {
    padding: 1.25rem 1rem;
  }

  .btn-create-product {
    width: 100%;
    justify-content: center;
    padding: 1rem 1.5rem;
    min-height: 54px;
    font-size: 1.05rem;
  }

  .pagination-controls {
    flex-wrap: wrap;
    gap: 0.35rem;
  }

  .pagination-controls button {
    min-width: 40px;
    height: 40px;
  }

  .products-pagination {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
  }
}

@media (max-width: 480px) {
  .metrics-grid {
    grid-template-columns: 1fr;
    gap: 0.75rem;
  }

  .metric-card {
    padding: 1rem 1.1rem;
  }

  .metric-value {
    font-size: 1.25rem;
  }

  .admin-topbar-title {
    font-size: 1rem;
  }

  .panel-title {
    font-size: 1.25rem;
  }

  .admin-content {
    padding: 0.75rem;
  }

  #add-product-form .two-cols {
    grid-template-columns: 1fr;
  }

  .create-product-form .four-cols {
    grid-template-columns: 1fr;
  }

  .create-product-card {
    padding: 1.35rem 1rem;
  }

  .create-section-title {
    font-size: 1rem;
  }

  .section-num {
    width: 28px;
    height: 28px;
    font-size: 0.85rem;
  }

  .add-inventory-account-cols {
    grid-template-columns: 1fr;
  }

  .admin-chat-panel {
    max-height: 320px;
    min-height: 200px;
  }

  .admin-ticket-meta-row {
    flex-direction: column;
    align-items: flex-start;
  }

  .admin-ticket-meta-row label {
    margin-left: 0;
  }
}

/* Safe area for notched devices */
@supports (padding: max(0px, env(safe-area-inset-left))) {
  .admin-sidebar {
    padding-left: env(safe-area-inset-left);
  }
  @media (max-width: 768px) {
    .admin-sidebar {
      padding-left: max(1.25rem, env(safe-area-inset-left));
    }
  }
  .admin-topbar {
    padding-left: max(1rem, env(safe-area-inset-left));
    padding-right: max(1rem, env(safe-area-inset-right));
  }
  .admin-content {
    padding-left: max(1rem, env(safe-area-inset-left));
    padding-right: max(1rem, env(safe-area-inset-right));
  }
}

.create-subsection {
  margin-top: 1.35rem;
  padding-top: 1.1rem;
  border-top: 1px solid #f1f5f9;
}

.create-subsection h4 {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.88rem;
  color: #475569;
  margin: 0 0 0.85rem 0;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.subsection-dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: linear-gradient(135deg, #94a3b8, #64748b);
  box-shadow: 0 1px 2px rgba(0,0,0,0.1);
}

.checkbox-group,
.radio-group {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  gap: 1rem 2rem;
}

.checkbox-label,
.radio-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 500;
  color: #475569;
  cursor: pointer;
  font-size: 0.9rem;
}

.checkbox-label input,
.radio-label input {
  width: 1.15em;
  height: 1.15em;
  accent-color: #2563eb;
  cursor: pointer;
}

.checkbox-label:hover,
.radio-label:hover {
  color: #0f172a;
}

.label-inline {
  margin-bottom: 0.5rem !important;
}

.products-table-wrap {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  overflow: auto;
  margin-bottom: 1rem;
}

.products-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.products-table th {
  text-align: left;
  padding: 0.75rem 1rem;
  background: #f8fafc;
  color: #64748b;
  font-weight: 600;
  border-bottom: 1px solid #e2e8f0;
}

.products-table td {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid #e2e8f0;
  color: #0f172a;
  vertical-align: middle;
}

.products-table tbody tr:hover {
  background: #f8fafc;
}

.product-cell-title {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.product-cell-title img {
  width: 48px;
  height: 48px;
  object-fit: cover;
  border-radius: 6px;
  background: #f1f5f9;
}

.product-cell-title .title-main {
  font-weight: 600;
  color: #0f172a;
}

.product-cell-title .title-slug {
  font-size: 0.8rem;
  color: #64748b;
  margin-top: 0.15rem;
}

.pill {
  display: inline-block;
  padding: 0.25rem 0.6rem;
  border-radius: 6px;
  font-size: 0.8rem;
  font-weight: 500;
  margin-right: 0.25rem;
  margin-bottom: 0.2rem;
}

.pill-platform {
  background: #475569;
  color: #fff;
}

.pill-type {
  background: #0ea5e9;
  color: #fff;
}

.pill-status {
  background: #a855f7;
  color: #fff;
}

.pill-status.inactive {
  background: #94a3b8;
  color: #fff;
}

.product-actions {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.product-actions .btn-action {
  width: 32px;
  height: 32px;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.2s;
}

.product-actions .btn-action:hover {
  opacity: 0.9;
}

.btn-action-add {
  background: #e2e8f0;
  color: #475569;
}

.btn-action-edit {
  background: #0ea5e9;
  color: #fff;
}

.btn-action-delete {
  background: #dc2626;
  color: #fff;
}

.btn-action-catalog-visibility {
  background: #64748b;
  color: #fff;
}

.btn-action-catalog-visibility.is-restore {
  background: #334155;
}

/* Text label — always visible (no dependency on Font Awesome) */
.product-actions .btn-action-catalog-text {
  width: auto;
  min-width: 2.75rem;
  padding: 0 0.4rem;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  line-height: 1;
  text-transform: uppercase;
}

.pill-catalog-hidden {
  background: rgba(251, 191, 36, 0.2);
  color: #fbbf24;
  border: 1px solid rgba(251, 191, 36, 0.35);
}

.products-pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.75rem;
  font-size: 0.9rem;
  color: #64748b;
}

.pagination-controls {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.pagination-controls button {
  min-width: 32px;
  height: 32px;
  padding: 0 0.5rem;
  border: 1px solid #e2e8f0;
  background: #fff;
  color: #0f172a;
  border-radius: 6px;
  font-family: inherit;
  cursor: pointer;
  font-size: 0.85rem;
}

.pagination-controls button:hover {
  background: #f1f5f9;
}

.pagination-controls button.active {
  background: #2563eb;
  border-color: #2563eb;
  color: #fff;
}

/* Admin modals */
.admin-modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  animation: admin-modal-backdrop-in 0.25s ease-out;
}

.admin-modal[hidden] {
  display: none !important;
}

@keyframes admin-modal-backdrop-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

.admin-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}

.admin-modal-content {
  position: relative;
  background: #fff;
  border-radius: 14px;
  padding: 1.5rem;
  max-width: 440px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow:
    0 0 0 1px rgba(0, 0, 0, 0.04),
    0 24px 48px rgba(0, 0, 0, 0.18),
    0 12px 24px rgba(0, 0, 0, 0.12);
  animation: admin-modal-content-in 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes admin-modal-content-in {
  from {
    opacity: 0;
    transform: scale(0.94) translateY(12px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

.admin-modal-content-wide {
  max-width: 520px;
}

.admin-modal-content.admin-modal-small {
  max-width: 400px;
}

/* Wallet IQD modal — dark gaming UI */
.admin-wallet-modal .admin-modal-backdrop {
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.admin-wallet-modal .admin-modal-content {
  max-width: 400px;
  background: linear-gradient(180deg, #0f0f14 0%, #0a0a0e 100%);
  border: 1px solid rgba(168, 85, 247, 0.35);
  border-radius: 16px;
  box-shadow:
    0 0 0 1px rgba(168, 85, 247, 0.08),
    0 24px 48px rgba(0, 0, 0, 0.5),
    0 0 32px rgba(168, 85, 247, 0.15);
  animation: admin-wallet-modal-in 0.3s cubic-bezier(0.34, 1.2, 0.64, 1);
}

@keyframes admin-wallet-modal-in {
  from {
    opacity: 0;
    transform: scale(0.92) translateY(-12px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

.admin-wallet-modal .admin-wallet-modal-header,
.admin-wallet-modal .admin-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  padding: 1.25rem 1.5rem;
}

.admin-wallet-modal .admin-wallet-modal-title,
.admin-wallet-modal .admin-modal-header h3 {
  color: #fafafa;
  font-size: 1.2rem;
  font-weight: 700;
  margin: 0;
}

.admin-wallet-modal .admin-wallet-modal-close,
.admin-wallet-modal .admin-modal-close {
  color: rgba(255, 255, 255, 0.5);
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  padding: 0.25rem;
  line-height: 1;
}

.admin-wallet-modal .admin-wallet-modal-close:hover,
.admin-wallet-modal .admin-modal-close:hover {
  color: #a78bfa;
}

.admin-wallet-modal .admin-wallet-modal-body,
.admin-wallet-modal .admin-modal-body {
  padding: 1.25rem 1.5rem 1.5rem;
}

.admin-wallet-modal .admin-wallet-modal-user {
  display: block;
  margin: 0.5rem 0 1.25rem;
  font-size: 0.9rem;
  color: #94a3b8;
}

.admin-wallet-modal .admin-wallet-modal-user span:last-child {
  color: #e2e8f0;
}

.admin-wallet-modal .admin-wallet-modal-field {
  margin-bottom: 1.25rem;
}

.admin-wallet-modal .admin-wallet-modal-field label {
  display: block;
  margin-bottom: 0.5rem;
  font-size: 0.875rem;
  font-weight: 600;
  color: #c4b5fd;
}

.admin-wallet-modal .admin-wallet-modal-field input {
  width: 100%;
  padding: 0.75rem 1rem;
  font-size: 1rem;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(168, 85, 247, 0.3);
  border-radius: 10px;
  color: #fafafa;
  font-family: inherit;
  box-sizing: border-box;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.admin-wallet-modal .admin-wallet-modal-field input:focus {
  outline: none;
  border-color: #a78bfa;
  box-shadow: 0 0 0 2px rgba(167, 139, 250, 0.25);
}

.admin-wallet-modal .admin-wallet-modal-field input::placeholder {
  color: rgba(255, 255, 255, 0.35);
}

.admin-wallet-modal .admin-wallet-modal-actions {
  display: flex;
  gap: 0.75rem;
  justify-content: flex-end;
  margin-top: 1.25rem;
}

.admin-wallet-modal .admin-wallet-modal-confirm {
  padding: 0.65rem 1.35rem;
  background: linear-gradient(135deg, #a78bfa 0%, #7c3aed 100%);
  color: #fff;
  border: none;
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  box-shadow: 0 0 20px rgba(167, 139, 250, 0.4);
  transition: filter 0.2s, box-shadow 0.2s;
}

.admin-wallet-modal .admin-wallet-modal-confirm:hover {
  filter: brightness(1.1);
  box-shadow: 0 0 24px rgba(167, 139, 250, 0.5);
}

.admin-wallet-modal .admin-wallet-modal-cancel {
  padding: 0.65rem 1.35rem;
  background: transparent;
  color: #94a3b8;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 10px;
  font-weight: 500;
  font-size: 0.95rem;
  cursor: pointer;
  transition: background 0.2s, color 0.2s, border-color 0.2s;
}

.admin-wallet-modal .admin-wallet-modal-cancel:hover {
  background: rgba(255, 255, 255, 0.06);
  color: #e2e8f0;
  border-color: rgba(255, 255, 255, 0.2);
}

.admin-modal-body {
  padding: 1rem 0;
}

.admin-modal-body p {
  color: #475569;
  font-size: 0.9375rem;
  line-height: 1.5;
  margin: 0 0 1.25rem 0;
}

.storage-limit-actions {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.btn-primary-storage {
  padding: 0.65rem 1.25rem;
  background: #dc2626;
  color: #fff;
  border: none;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
}

.btn-primary-storage:hover {
  background: #b91c1c;
}

.btn-secondary-storage {
  padding: 0.6rem 1.25rem;
  background: #f1f5f9;
  color: #475569;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  font-weight: 500;
  cursor: pointer;
}

.btn-secondary-storage:hover {
  background: #e2e8f0;
}

.admin-modal-inventory {
  max-width: 900px;
  padding: 0;
  overflow: hidden;
}

.inventory-modal-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid #e2e8f0;
  background: #fff;
}

.inventory-header-left {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.inventory-title {
  margin: 0;
  font-size: 1.35rem;
  font-weight: 700;
  color: #0f172a;
}

.inventory-title-suffix {
  font-weight: 600;
  color: #475569;
}

.inventory-stock-tag {
  display: inline-block;
  padding: 0.25rem 0.6rem;
  background: #dcfce7;
  color: #166534;
  font-size: 0.8rem;
  font-weight: 600;
  border-radius: 6px;
}

.btn-back-to-list-modal {
  padding: 0.5rem 0.9rem;
  background: #f1f5f9;
  color: #475569;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  font-family: inherit;
  font-weight: 500;
  cursor: pointer;
  flex-shrink: 0;
}

.btn-back-to-list-modal:hover {
  background: #e2e8f0;
}

.inventory-section {
  padding: 1rem 1.5rem 1.5rem;
}

.inventory-section-head {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
}

.inventory-menu-icon {
  font-size: 1.1rem;
  color: #64748b;
  line-height: 1;
}

.inventory-section-title {
  margin: 0;
  font-size: 1rem;
  font-weight: 700;
  color: #0f172a;
  flex: 1;
}

.btn-add-single-item {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.5rem 0.9rem;
  background: #2563eb;
  color: #fff;
  border: none;
  border-radius: 8px;
  font-family: inherit;
  font-weight: 600;
  cursor: pointer;
}

.btn-add-single-item:hover {
  background: #1d4ed8;
}

.btn-add-single-icon {
  font-size: 1.1rem;
  line-height: 1;
}

.inventory-table-wrap {
  position: relative;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
  min-height: 120px;
}

.inventory-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.inventory-table th {
  text-align: left;
  padding: 0.6rem 0.75rem;
  background: #f8fafc;
  color: #475569;
  font-weight: 600;
  border-bottom: 1px solid #e2e8f0;
}

.inventory-table td {
  padding: 0.6rem 0.75rem;
  border-bottom: 1px solid #f1f5f9;
  color: #334155;
}

.inventory-table tbody tr:last-child td {
  border-bottom: none;
}

.inventory-table .cell-placeholder {
  color: #94a3b8;
}

.inventory-table .btn-row-action {
  background: none;
  border: none;
  color: #64748b;
  cursor: pointer;
  padding: 0.25rem;
  font-size: 1rem;
}

.inventory-table .btn-row-action:hover {
  color: #dc2626;
}

.inventory-empty {
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  color: #94a3b8;
  font-size: 0.9rem;
}

.inventory-table-wrap.has-empty .inventory-table {
  display: none;
}

.inventory-empty.show {
  display: flex;
}

.inventory-empty-icon {
  font-size: 2.5rem;
  margin-bottom: 0.5rem;
  opacity: 0.7;
}

.inventory-empty p {
  margin: 0;
}

.admin-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.25rem;
}

.admin-modal-header h3 {
  margin: 0;
  font-size: 1.2rem;
  color: #0f172a;
}

.admin-modal-close {
  background: none;
  border: none;
  font-size: 1.5rem;
  color: #64748b;
  cursor: pointer;
  line-height: 1;
  padding: 0.25rem;
}

.admin-modal-close:hover {
  color: #0f172a;
}

#add-product-form .form-row {
  margin-bottom: 1rem;
}

#add-product-form label {
  display: block;
  font-size: 0.85rem;
  font-weight: 500;
  color: #475569;
  margin-bottom: 0.35rem;
}

#add-product-form input,
#add-product-form select {
  width: 100%;
  padding: 0.6rem 0.9rem;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  font-family: inherit;
  font-size: 0.95rem;
}

#add-product-form .two-cols {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
}

#add-product-form .two-cols select {
  width: 100%;
}

.btn-submit {
  width: 100%;
  padding: 0.7rem;
  margin-top: 0.5rem;
  background: #2563eb;
  color: #fff;
  border: none;
  border-radius: 6px;
  font-family: inherit;
  font-weight: 600;
  cursor: pointer;
}

.btn-submit:hover {
  background: #1d4ed8;
}

/* Legacy key-item kept for any inline use */
.key-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.4rem 0.6rem;
  background: #f8fafc;
  border-radius: 6px;
  margin-bottom: 0.35rem;
  font-size: 0.9rem;
}

/* Add Single Inventory Item — wide landscape modal */
.admin-modal-content.add-inventory-modal {
  max-width: 680px;
  width: 92%;
  padding: 0;
  overflow: hidden;
  border-radius: 12px;
  box-shadow: 0 24px 48px rgba(0, 0, 0, 0.15), 0 0 0 1px rgba(0, 0, 0, 0.06);
}

@media (min-width: 520px) {
  .admin-modal-content.add-inventory-modal {
    max-width: 720px;
  }
}

.add-inventory-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 1.5rem;
  background: linear-gradient(180deg, #f8fafc 0%, #fff 100%);
  border-bottom: 1px solid #e2e8f0;
}

.add-inventory-title {
  margin: 0;
  font-size: 1.2rem;
  font-weight: 700;
  color: #0f172a;
  letter-spacing: -0.02em;
}

.add-inventory-close {
  width: 2rem;
  height: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  color: #64748b;
  font-size: 1.4rem;
  line-height: 1;
  transition: background 0.15s, color 0.15s;
}

.add-inventory-close:hover {
  background: #f1f5f9;
  color: #0f172a;
}

.add-inventory-form {
  padding: 1.5rem 1.75rem 1.75rem;
}

.add-inventory-top-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
}

@media (max-width: 420px) {
  .add-inventory-top-row {
    grid-template-columns: 1fr;
  }
}

.add-inventory-field {
  margin-bottom: 0;
}

.add-inventory-field label {
  display: block;
  font-size: 0.8125rem;
  font-weight: 600;
  color: #475569;
  margin-bottom: 0.4rem;
  letter-spacing: 0.01em;
}

.add-inventory-input {
  width: 100%;
  padding: 0.65rem 0.85rem;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  font-family: inherit;
  font-size: 0.9375rem;
  color: #0f172a;
  background: #fff;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.add-inventory-input:hover {
  border-color: #cbd5e1;
}

.add-inventory-input:focus {
  outline: none;
  border-color: #2563eb;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}

.add-inventory-select {
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23475569' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.85rem center;
  padding-right: 2rem;
}

.input-with-hint {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.input-with-hint .add-inventory-input {
  flex: 1;
}

.input-hint-icon {
  width: 1.35rem;
  height: 1.35rem;
  border-radius: 50%;
  background: #cbd5e1;
  color: #64748b;
  font-size: 0.75rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: help;
  flex-shrink: 0;
  transition: background 0.15s, color 0.15s;
}

.input-hint-icon:hover {
  background: #94a3b8;
  color: #fff;
}

.add-inventory-divider {
  height: 1px;
  background: #e2e8f0;
  margin: 1.25rem 0 1rem;
}

.add-inventory-type-tabs {
  display: flex;
  gap: 0.25rem;
  margin-bottom: 1rem;
  padding: 0.25rem;
  background: #f1f5f9;
  border-radius: 10px;
  width: fit-content;
}

.add-inventory-tab {
  padding: 0.5rem 1.1rem;
  border: none;
  background: transparent;
  color: #475569;
  font-family: inherit;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  border-radius: 8px;
  transition: background 0.15s, color 0.15s;
}

.add-inventory-tab:hover {
  color: #0f172a;
}

.add-inventory-tab.active {
  background: #fff;
  color: #2563eb;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
}

.add-inventory-content {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 1.25rem;
  margin-bottom: 1.25rem;
}

.add-inventory-panel .add-inventory-field {
  margin-bottom: 1rem;
}

.add-inventory-panel .add-inventory-field:last-child {
  margin-bottom: 0;
}

.add-inventory-account-cols {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
}

.add-inventory-account-col .add-inventory-field {
  margin-bottom: 1rem;
}

.add-inventory-account-col .add-inventory-field:last-child {
  margin-bottom: 0;
}

@media (max-width: 480px) {
  .add-inventory-account-cols {
    grid-template-columns: 1fr;
  }
}

.add-inventory-panel.hidden {
  display: none;
}

.add-inventory-textarea {
  min-height: 4rem;
  resize: vertical;
}

.add-inventory-footer {
  padding-top: 0.25rem;
}

.btn-save-item {
  width: 100%;
  padding: 0.8rem 1.25rem;
  background: #2563eb;
  color: #fff;
  border: none;
  border-radius: 10px;
  font-family: inherit;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s, transform 0.05s;
}

.btn-save-item:hover {
  background: #1d4ed8;
}

.btn-save-item:active {
  transform: scale(0.995);
}

.add-key-product-name {
  font-weight: 600;
  color: #0f172a;
  margin-bottom: 1rem;
}

.btn-keys-in-modal {
  width: 100%;
  padding: 0.6rem;
  background: #f1f5f9;
  color: #475569;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  font-family: inherit;
  font-weight: 500;
  cursor: pointer;
}

.btn-keys-in-modal:hover {
  background: #e2e8f0;
}

/* Support panel — unique amber/orange theme (distinct from Users teal, main purple) */
.admin-panel-support {
  --support-accent: #d97706;
  --support-accent-hover: #b45309;
  --support-accent-dim: rgba(217, 119, 6, 0.14);
  --support-accent-border: rgba(217, 119, 6, 0.4);
}

.admin-support-card {
  background: var(--bg-card);
  border-radius: 14px;
  border: 1px solid var(--support-accent-border);
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.12);
}

.admin-support-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.25rem 1.5rem;
  background: linear-gradient(135deg, var(--support-accent-dim) 0%, rgba(0, 0, 0, 0.04) 100%);
  border-bottom: 2px solid var(--support-accent);
}

.admin-support-title-wrap {
  display: flex;
  align-items: flex-start;
  gap: 0.9rem;
}

.admin-support-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  background: var(--support-accent-dim);
  border-radius: 12px;
  color: var(--support-accent);
  flex-shrink: 0;
}

.admin-support-icon svg {
  width: 26px;
  height: 26px;
}

.admin-support-panel-title {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text);
}

.admin-support-desc {
  margin: 0.3rem 0 0 0;
  font-size: 0.875rem;
  color: var(--text-muted);
  max-width: 480px;
}

.admin-support-filter {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.admin-support-filter label {
  font-size: 0.9rem;
  color: var(--text-muted);
  font-weight: 500;
}

.admin-support-toolbar {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.admin-support-filter select {
  padding: 0.5rem 0.85rem;
  background: var(--bg-dark);
  border: 1px solid var(--support-accent-border);
  border-radius: 8px;
  color: var(--text);
  font-family: inherit;
  font-size: 0.9rem;
  cursor: pointer;
}

.admin-support-filter select:focus {
  outline: none;
  border-color: var(--support-accent);
  box-shadow: 0 0 0 2px var(--support-accent-dim);
}

.admin-support-filter input[type="text"] {
  padding: 0.5rem 0.85rem;
  min-width: 180px;
  background: var(--bg-dark);
  border: 1px solid var(--support-accent-border);
  border-radius: 8px;
  color: var(--text);
  font-family: inherit;
  font-size: 0.9rem;
}

.admin-support-filter input[type="text"]::placeholder {
  color: var(--text-muted);
}

.admin-support-filter input[type="text"]:focus {
  outline: none;
  border-color: var(--support-accent);
  box-shadow: 0 0 0 2px var(--support-accent-dim);
}

.admin-support-refresh {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.55rem 1.1rem;
  background: var(--support-accent);
  color: #fff;
  border: none;
  border-radius: 8px;
  font-family: inherit;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: filter 0.2s, box-shadow 0.2s;
}

.admin-support-refresh:hover {
  filter: brightness(1.1);
  box-shadow: 0 4px 14px rgba(217, 119, 6, 0.4);
}

.admin-support-refresh svg {
  flex-shrink: 0;
}

.admin-support-table-wrap {
  overflow-x: auto;
  padding: 0;
}

.admin-support-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.admin-support-table th {
  text-align: left;
  padding: 0.85rem 1.25rem;
  background: var(--support-accent-dim);
  color: var(--support-accent);
  font-weight: 600;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.admin-support-table td {
  padding: 0.9rem 1.25rem;
  border-top: 1px solid rgba(217, 119, 6, 0.12);
  color: var(--text);
}

.admin-support-table tbody tr:hover {
  background: var(--support-accent-dim);
}

.admin-support-table tbody tr:first-child td {
  border-top: none;
}

.admin-support-empty td {
  text-align: center;
  color: var(--text-muted);
  padding: 2.5rem 1.5rem;
  font-size: 0.95rem;
}

/* Users panel – unique teal theme */
.admin-panel-users {
  --users-accent: #0d9488;
  --users-accent-dim: rgba(13, 148, 136, 0.15);
  --users-accent-border: rgba(13, 148, 136, 0.4);
}

.admin-users-card {
  background: var(--bg-card);
  border-radius: 12px;
  border: 1px solid var(--users-accent-border);
  overflow: hidden;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
}

.admin-users-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.25rem 1.5rem;
  background: linear-gradient(135deg, var(--users-accent-dim) 0%, rgba(0, 0, 0, 0.03) 100%);
  border-bottom: 2px solid var(--users-accent);
}

.admin-users-title-wrap {
  display: flex;
  align-items: flex-start;
  gap: 0.85rem;
}

.admin-users-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  background: var(--users-accent-dim);
  border-radius: 10px;
  color: var(--users-accent);
  flex-shrink: 0;
}

.admin-users-panel-title {
  margin: 0;
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--text);
}

.admin-users-desc {
  margin: 0.25rem 0 0 0;
  font-size: 0.875rem;
  color: var(--text-muted);
  max-width: 420px;
}

.admin-users-toolbar {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.admin-users-filter {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.admin-users-filter label {
  font-size: 0.9rem;
  color: var(--text-muted);
  font-weight: 500;
}

.admin-users-filter input[type="text"] {
  padding: 0.5rem 0.85rem;
  min-width: 160px;
  background: var(--bg-dark);
  border: 1px solid var(--users-accent-border);
  border-radius: 8px;
  color: var(--text);
  font-family: inherit;
  font-size: 0.9rem;
}

.admin-users-filter input[type="text"]::placeholder {
  color: var(--text-muted);
}

.admin-users-filter input[type="text"]:focus {
  outline: none;
  border-color: var(--users-accent);
  box-shadow: 0 0 0 2px var(--users-accent-dim);
}

.admin-users-refresh-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.5rem 1rem;
  background: var(--users-accent);
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  transition: filter 0.2s, box-shadow 0.2s;
}

.admin-users-refresh-btn:hover {
  filter: brightness(1.1);
  box-shadow: 0 4px 12px rgba(13, 148, 136, 0.35);
}

.admin-users-refresh-btn svg {
  flex-shrink: 0;
}

.admin-users-table-wrap {
  overflow-x: auto;
}

.admin-users-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.admin-users-table th {
  text-align: left;
  padding: 0.85rem 1.25rem;
  background: var(--users-accent-dim);
  color: var(--users-accent);
  font-weight: 600;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.admin-users-table td {
  padding: 0.9rem 1.25rem;
  border-top: 1px solid rgba(13, 148, 136, 0.12);
  color: var(--text);
}

.admin-users-table tbody tr:hover {
  background: var(--users-accent-dim);
}

.admin-users-table tbody tr:first-child td {
  border-top: none;
}

.admin-users-empty {
  text-align: center;
  color: var(--text-muted);
  padding: 2.5rem 1.5rem;
  font-size: 0.95rem;
}

.admin-users-pwd-mask {
  color: var(--text-muted);
  font-family: monospace;
  letter-spacing: 0.15em;
}

.admin-users-pwd-cell {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.admin-users-pwd-value {
  font-family: monospace;
  font-size: 0.9em;
}

.admin-users-pwd-btn {
  padding: 0.2rem 0.5rem;
  font-size: 0.75rem;
  border: 1px solid var(--border);
  border-radius: 4px;
  background: var(--bg-dark);
  color: var(--text-muted);
  cursor: pointer;
  white-space: nowrap;
}

.admin-users-pwd-btn:hover:not(:disabled) {
  color: var(--text);
  border-color: var(--text-muted);
}

.admin-users-pwd-btn:disabled {
  cursor: default;
  opacity: 0.7;
}

.admin-users-status-cell {
  white-space: nowrap;
}

.admin-users-badge {
  display: inline-block;
  padding: 0.25rem 0.5rem;
  border-radius: 6px;
  font-size: 0.75rem;
  font-weight: 600;
  margin-right: 0.35rem;
}

.admin-users-badge-active {
  background: rgba(34, 197, 94, 0.2);
  color: #a855f7;
}

.admin-users-badge-banned {
  background: rgba(239, 68, 68, 0.2);
  color: #ef4444;
}

.admin-users-ban-btn {
  padding: 0.25rem 0.6rem;
  font-size: 0.8rem;
  border-radius: 6px;
  font-weight: 500;
  cursor: pointer;
  border: 1px solid var(--users-accent-border);
  background: var(--users-accent-dim);
  color: var(--users-accent);
  transition: filter 0.2s;
}

.admin-users-ban-btn:hover {
  filter: brightness(1.1);
}

.admin-user-unban-btn {
  border-color: rgba(34, 197, 94, 0.4);
  background: rgba(34, 197, 94, 0.15);
  color: #a855f7;
}

.admin-users-ip-cell {
  white-space: normal;
  vertical-align: top;
  min-width: 10.5rem;
}

.admin-users-ip-inner {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.45rem;
}

.admin-users-ip-addr {
  word-break: break-all;
  font-family: monospace;
  font-size: 0.85em;
}

.admin-users-ip-btns {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  align-items: center;
}

.admin-user-block-ip-btn {
  margin-left: 0;
  padding: 0.2rem 0.5rem;
  font-size: 0.75rem;
  border-radius: 4px;
  font-weight: 500;
  cursor: pointer;
  border: 1px solid rgba(239, 68, 68, 0.4);
  background: rgba(239, 68, 68, 0.12);
  color: #ef4444;
  transition: filter 0.2s;
}

.admin-user-block-ip-btn:hover {
  filter: brightness(1.1);
}

.admin-user-unblock-ip-btn {
  margin-left: 0;
  padding: 0.2rem 0.5rem;
  font-size: 0.75rem;
  border-radius: 4px;
  font-weight: 500;
  cursor: pointer;
  border: 1px solid rgba(34, 197, 94, 0.45);
  background: rgba(34, 197, 94, 0.12);
  color: #4ade80;
  transition: filter 0.2s;
}

.admin-user-unblock-ip-btn:hover {
  filter: brightness(1.1);
}

/* Wallets panel */
.admin-panel-wallets {
  --wallets-accent: #0d9488;
  --wallets-accent-dim: rgba(13, 148, 136, 0.15);
}

.admin-wallets-card {
  background: var(--bg-card);
  border-radius: 12px;
  border: 1px solid var(--border-color, rgba(0, 0, 0, 0.08));
  overflow: hidden;
}

.admin-wallets-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.35rem 1.6rem;
  background: linear-gradient(145deg, var(--wallets-accent-dim) 0%, rgba(13, 148, 136, 0.06) 50%, rgba(0, 0, 0, 0.02) 100%);
  border-bottom: 2px solid var(--wallets-accent);
}

.admin-wallets-title-wrap {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
}

.admin-wallets-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  background: linear-gradient(145deg, var(--wallets-accent-dim) 0%, rgba(13, 148, 136, 0.08) 100%);
  border-radius: 12px;
  color: var(--wallets-accent);
  flex-shrink: 0;
}

.admin-wallets-panel-title { margin: 0; font-size: 1.2rem; }
.admin-wallets-desc { margin: 0.25rem 0 0 0; font-size: 0.875rem; color: var(--text-muted); }

.admin-wallets-toolbar {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.admin-wallets-filter {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.admin-wallets-filter label { font-size: 0.9rem; color: var(--text-muted); }
.admin-wallets-filter input { padding: 0.5rem 0.85rem; min-width: 160px; border: 1px solid var(--border-color, #e2e8f0); border-radius: 8px; font-size: 0.9rem; }

.admin-wallets-refresh-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background: var(--wallets-accent);
  color: #fff;
  border: none;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  transition: filter 0.2s, box-shadow 0.2s;
}

.admin-wallets-refresh-btn:hover { filter: brightness(1.1); }

.admin-wallets-table-wrap { overflow-x: auto; }
.admin-wallets-table {
  width: 100%;
  border-collapse: collapse;
}

.admin-wallets-table th {
  text-align: left;
  padding: 0.85rem 1.25rem;
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--text-muted);
  background: rgba(0, 0, 0, 0.02);
}

.admin-wallets-table td {
  padding: 0.9rem 1.25rem;
  border-top: 1px solid var(--wallets-accent-dim);
}

.admin-wallets-table tbody tr:hover { background: var(--wallets-accent-dim); }
.admin-wallets-table tbody tr:first-child td { border-top: none; }

.admin-wallets-empty { text-align: center; color: var(--text-muted); padding: 2rem !important; }
.admin-wallets-balance { font-weight: 600; font-variant-numeric: tabular-nums; }

.admin-wallets-actions { white-space: nowrap; }
.admin-wallets-add-btn,
.admin-wallets-deduct-btn,
.admin-wallets-set-btn {
  padding: 0.25rem 0.6rem;
  font-size: 0.8rem;
  border-radius: 6px;
  font-weight: 500;
  cursor: pointer;
  margin-right: 0.25rem;
  border: 1px solid;
  transition: filter 0.2s;
}

.admin-wallets-add-btn {
  border-color: rgba(34, 197, 94, 0.4);
  background: rgba(34, 197, 94, 0.12);
  color: #22c55e;
}

.admin-wallets-deduct-btn {
  border-color: rgba(239, 68, 68, 0.4);
  background: rgba(239, 68, 68, 0.12);
  color: #ef4444;
}

.admin-wallets-set-btn {
  border-color: rgba(13, 148, 136, 0.4);
  background: rgba(13, 148, 136, 0.12);
  color: var(--wallets-accent);
}

.admin-wallets-add-btn:hover,
.admin-wallets-deduct-btn:hover,
.admin-wallets-set-btn:hover { filter: brightness(1.1); }

/* ========== Gift Cards Admin — New Design ========== */
.admin-panel-giftcard {
  --gc-primary: #6366f1;
  --gc-primary-hover: #4f46e5;
  --gc-accent: #f59e0b;
  --gc-bg: var(--bg-card);
  --gc-border: var(--border);
  --gc-muted: var(--text-muted);
}

.gc-dashboard {
  background: var(--gc-bg);
  border-radius: 20px;
  border: 1px solid var(--gc-border);
  overflow: hidden;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.06);
}

.gc-header {
  padding: 1.75rem 2rem;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.08) 0%, rgba(245, 158, 11, 0.04) 100%);
  border-bottom: 1px solid var(--gc-border);
}

.gc-header-main {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.gc-logo {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.gc-logo-icon {
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--gc-primary) 0%, var(--gc-primary-hover) 100%);
  color: #fff;
  border-radius: 14px;
  font-size: 1.4rem;
  box-shadow: 0 4px 14px rgba(99, 102, 241, 0.35);
}

.gc-title {
  margin: 0;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.03em;
}

.gc-subtitle {
  margin: 0.25rem 0 0 0;
  font-size: 0.9rem;
  color: var(--gc-muted);
}

.gc-refresh {
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.5);
  border: 1px solid var(--gc-border);
  border-radius: 12px;
  color: var(--gc-muted);
  cursor: pointer;
  transition: all 0.2s;
}

.gc-refresh:hover {
  background: rgba(99, 102, 241, 0.12);
  color: var(--gc-primary);
  border-color: rgba(99, 102, 241, 0.3);
}

.gc-stepper {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.gc-back {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--gc-muted);
  background: transparent;
  border: 1px solid var(--gc-border);
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.2s;
}

.gc-back:hover {
  color: var(--gc-primary);
  border-color: rgba(99, 102, 241, 0.4);
  background: rgba(99, 102, 241, 0.08);
}

.gc-steps {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex: 1;
}

.gc-step {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--gc-muted);
  border-radius: 10px;
  transition: all 0.2s;
}

.gc-step i {
  opacity: 0.7;
}

.gc-step.active {
  color: var(--gc-primary);
  background: rgba(99, 102, 241, 0.12);
}

.gc-step.done {
  color: var(--gc-primary);
  opacity: 0.8;
}

.gc-step-line {
  width: 24px;
  height: 2px;
  background: var(--gc-border);
  border-radius: 1px;
}

.gc-breadcrumb {
  font-size: 0.9rem;
  color: var(--gc-muted);
  font-weight: 500;
}

.gc-main {
  padding: 2rem;
  min-height: 280px;
}

.gc-view {
  animation: gc-fade 0.3s ease;
}

@keyframes gc-fade {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

.gc-actions {
  margin-bottom: 1.75rem;
  display: flex;
  justify-content: center;
}

.gc-add-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.7rem 1.5rem;
  background: linear-gradient(135deg, var(--gc-primary) 0%, var(--gc-primary-hover) 100%);
  color: #fff;
  border: none;
  border-radius: 12px;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 0.2s;
  box-shadow: 0 4px 14px rgba(99, 102, 241, 0.3);
}

.gc-add-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(99, 102, 241, 0.4);
}

.gc-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1.5rem;
  max-width: 1100px;
  margin: 0 auto;
}

@media (min-width: 900px) {
  .gc-grid { grid-template-columns: repeat(4, 1fr); }
}

@media (min-width: 600px) and (max-width: 899px) {
  .gc-grid { grid-template-columns: repeat(3, 1fr); }
}

.gc-card {
  display: flex;
  flex-direction: column;
  background: var(--gc-bg);
  border: 1px solid var(--gc-border);
  border-radius: 16px;
  overflow: hidden;
  cursor: pointer;
  transition: all 0.25s ease;
}

.gc-card:hover {
  border-color: rgba(99, 102, 241, 0.4);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.1);
  transform: translateY(-4px);
}

.gc-card-img {
  aspect-ratio: 1;
  min-height: 160px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(180deg, rgba(99, 102, 241, 0.06) 0%, transparent 100%);
  overflow: hidden;
}

.gc-card-img img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 1rem;
}

.gc-placeholder {
  font-size: 2.5rem;
  color: var(--gc-muted);
  opacity: 0.5;
}

.gc-card-body {
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.gc-card-title {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text);
  text-align: center;
  line-height: 1.3;
}

.gc-card-price {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--gc-accent);
  text-align: center;
  font-variant-numeric: tabular-nums;
}

.gc-card-actions {
  display: flex;
  gap: 0.5rem;
  padding-top: 0.75rem;
  border-top: 1px solid var(--gc-border);
  justify-content: center;
  flex-wrap: wrap;
}

.gc-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.45rem 0.9rem;
  font-size: 0.82rem;
  font-weight: 600;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s;
}

.gc-btn-edit {
  background: rgba(99, 102, 241, 0.1);
  border: 1px solid rgba(99, 102, 241, 0.35);
  color: #818cf8;
}

.gc-btn-edit:hover {
  background: rgba(99, 102, 241, 0.2);
  border-color: rgba(99, 102, 241, 0.5);
}

.gc-btn-del {
  background: rgba(239, 68, 68, 0.08);
  border: 1px solid rgba(239, 68, 68, 0.3);
  color: #f87171;
}

.gc-btn-del:hover {
  background: rgba(239, 68, 68, 0.15);
  border-color: rgba(239, 68, 68, 0.5);
}

.gc-empty {
  text-align: center;
  padding: 3rem 2rem;
  max-width: 420px;
  margin: 0 auto;
}

.gc-empty-icon {
  width: 80px;
  height: 80px;
  margin: 0 auto 1.25rem;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.12) 0%, rgba(245, 158, 11, 0.08) 100%);
  border-radius: 20px;
  font-size: 2rem;
  color: var(--gc-primary);
}

.gc-empty strong {
  display: block;
  font-size: 1.15rem;
  color: var(--text);
  margin-bottom: 0.5rem;
}

.gc-empty p {
  margin: 0 0 1.5rem;
  font-size: 0.95rem;
  color: var(--gc-muted);
  line-height: 1.5;
}

.gc-empty-msg {
  grid-column: 1 / -1;
  padding: 2.5rem;
  text-align: center;
  color: var(--gc-muted);
  background: rgba(99, 102, 241, 0.06);
  border: 2px dashed rgba(99, 102, 241, 0.25);
  border-radius: 16px;
  font-size: 0.95rem;
}


/* Product card */
.admin-giftcard-product-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  overflow: hidden;
  transition: box-shadow 0.2s, border-color 0.2s;
}

.admin-giftcard-product-card:hover {
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
  border-color: var(--giftcard-accent-border);
}

.admin-giftcard-product-card.admin-giftcard-disabled {
  opacity: 0.65;
}

.admin-giftcard-product-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.25rem 1.5rem;
  background: linear-gradient(180deg, rgba(0,0,0,0.02) 0%, transparent 100%);
  border-bottom: 1px solid var(--border);
}

.admin-giftcard-product-info {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.admin-giftcard-product-thumb {
  width: 56px;
  height: 56px;
  object-fit: contain;
  border-radius: 12px;
  background: var(--giftcard-accent-dim);
  padding: 4px;
}

.admin-giftcard-product-thumb-placeholder {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  font-size: 1.5rem;
  color: var(--text-muted);
  border: 2px dashed var(--border);
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.02);
}

.admin-giftcard-platform-badge {
  font-size: 0.7rem;
  padding: 0.25rem 0.6rem;
  background: var(--giftcard-accent-dim);
  color: var(--giftcard-accent);
  border-radius: 8px;
  margin-left: 0.5rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.admin-giftcard-product-meta {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 0.3rem;
}

.admin-giftcard-product-actions,
.admin-giftcard-row-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
}

.admin-giftcard-btn-edit,
.admin-giftcard-btn-del,
.admin-giftcard-btn-add-region,
.admin-giftcard-btn-add-amt {
  padding: 0.45rem 0.9rem;
  font-size: 0.82rem;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 600;
  transition: filter 0.2s;
}

.admin-giftcard-btn-add-region,
.admin-giftcard-btn-add-amt {
  border: 1px solid var(--giftcard-accent-border);
  background: var(--giftcard-accent-dim);
  color: var(--giftcard-accent);
}

.admin-giftcard-btn-add-region:hover,
.admin-giftcard-btn-add-amt:hover {
  filter: brightness(0.95);
}

.admin-giftcard-btn-edit {
  border: 1px solid rgba(59, 130, 246, 0.45);
  background: rgba(59, 130, 246, 0.12);
  color: #60a5fa;
  font-weight: 600;
  border-radius: 8px;
  transition: background 0.2s, border-color 0.2s;
}

.admin-giftcard-btn-edit:hover {
  background: rgba(59, 130, 246, 0.2);
  border-color: rgba(59, 130, 246, 0.6);
}

.admin-giftcard-btn-del {
  border: 1px solid rgba(239, 68, 68, 0.45);
  background: rgba(239, 68, 68, 0.1);
  color: #f87171;
  font-weight: 600;
  border-radius: 8px;
  transition: background 0.2s, border-color 0.2s;
}

.admin-giftcard-btn-del:hover {
  background: rgba(239, 68, 68, 0.18);
  border-color: rgba(239, 68, 68, 0.6);
}

/* Product body — clear sections */
.admin-giftcard-product-body {
  padding: 0 1.5rem 1.5rem;
}

.admin-giftcard-section {
  margin-top: 1.5rem;
}

.admin-giftcard-section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}

.admin-giftcard-section-title {
  margin: 0;
  font-size: 1rem;
  font-weight: 700;
  color: var(--text);
  letter-spacing: 0.02em;
}

.admin-giftcard-regions-section .admin-giftcard-section-header {
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--giftcard-accent-border);
}

.admin-giftcard-regions-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

/* Region card — collapsible */
.admin-giftcard-region-card {
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  background: var(--bg-card);
  transition: border-color 0.2s;
}

.admin-giftcard-region-card:hover {
  border-color: var(--giftcard-accent-border);
}

.admin-giftcard-region-card-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 1.25rem;
  background: linear-gradient(90deg, var(--giftcard-accent-dim) 0%, transparent 100%);
  cursor: default;
}

.admin-giftcard-region-toggle {
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text-muted);
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}

.admin-giftcard-region-toggle:hover {
  background: var(--giftcard-accent-dim);
  color: var(--giftcard-accent);
}

.admin-giftcard-region-toggle i {
  font-size: 0.7rem;
  transition: transform 0.2s;
}

.admin-giftcard-region-card[data-collapsed="true"] .admin-giftcard-region-toggle i {
  transform: rotate(-90deg);
}

.admin-giftcard-region-thumb {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  overflow: hidden;
  background: rgba(0, 0, 0, 0.05);
  flex-shrink: 0;
}

.admin-giftcard-region-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.admin-giftcard-region-name {
  flex: 1;
  font-weight: 700;
  font-size: 1rem;
  color: var(--text);
}

.admin-giftcard-region-card-body {
  padding: 1rem 1.25rem 1.25rem;
  border-top: 1px solid var(--border);
}

.admin-giftcard-region-card[data-collapsed="true"] .admin-giftcard-region-card-body {
  display: none;
}

.admin-giftcard-amounts-section .admin-giftcard-section-header {
  margin-bottom: 0.75rem;
  padding-bottom: 0;
  border-bottom: none;
}

.admin-giftcard-amounts-section .admin-giftcard-section-title {
  font-size: 0.9rem;
}

.admin-giftcard-amounts-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.admin-giftcard-no-amounts {
  padding: 1rem;
  font-size: 0.9rem;
  color: var(--text-muted);
  font-style: italic;
  text-align: center;
  background: rgba(0, 0, 0, 0.02);
  border-radius: 8px;
}

.admin-giftcard-amount-row {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.6rem 1rem;
  font-size: 0.9rem;
  border-radius: 10px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  transition: border-color 0.2s, box-shadow 0.2s;
}

.admin-giftcard-amount-row:hover {
  border-color: var(--giftcard-accent-border);
  box-shadow: 0 2px 8px var(--giftcard-accent-dim);
}

.admin-giftcard-amount-thumb {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  overflow: hidden;
  background: rgba(0, 0, 0, 0.05);
  flex-shrink: 0;
}

.admin-giftcard-amount-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.admin-giftcard-thumb-placeholder {
  font-size: 1rem;
  color: var(--text-muted);
}

.admin-giftcard-amount-value {
  flex: 1;
  min-width: 0;
  font-weight: 700;
  color: var(--text);
}

.admin-giftcard-amount-price {
  font-weight: 700;
  color: var(--giftcard-accent);
  font-variant-numeric: tabular-nums;
}

/* Modals */
.admin-giftcard-modal {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
}
.admin-giftcard-modal[hidden] {
  display: none !important;
}
.admin-giftcard-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(6px);
}
.admin-giftcard-modal-box {
  position: relative;
  background: var(--bg-card);
  border-radius: 18px;
  padding: 2rem;
  max-width: 460px;
  width: 100%;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.25), 0 0 0 1px var(--border);
  border: 1px solid rgba(99, 102, 241, 0.25);
  animation: admin-giftcard-modal-in 0.25s ease;
}
@keyframes admin-giftcard-modal-in {
  from { opacity: 0; transform: scale(0.97) translateY(8px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}
.admin-giftcard-modal-box h3 {
  margin: 0 0 0.5rem;
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.02em;
}
.admin-giftcard-modal-hint {
  margin: 0 0 1.5rem;
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.55;
}
.admin-giftcard-form-row {
  margin-bottom: 1.1rem;
}
.admin-giftcard-form-row label:not(.admin-giftcard-toggle-label) {
  display: block;
  margin-bottom: 0.4rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text);
}
.admin-giftcard-form-row input:not([type="checkbox"]):not([type="radio"]),
.admin-giftcard-form-row select {
  width: 100%;
  padding: 0.6rem 1rem;
  border: 1px solid var(--border);
  border-radius: 10px;
  font-size: 1rem;
  transition: border-color 0.2s;
}
.admin-giftcard-form-row input[type="checkbox"],
.admin-giftcard-form-row input[type="radio"] {
  width: auto;
  margin: 0;
  flex-shrink: 0;
}
.admin-giftcard-form-row input:not([type="checkbox"]):not([type="radio"]):focus,
.admin-giftcard-form-row select:focus {
  outline: none;
  border-color: var(--gc-primary, #6366f1);
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.15);
}
.admin-giftcard-image-upload-wrap {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.admin-giftcard-image-preview {
  width: 88px;
  height: 88px;
  border: 2px dashed var(--border);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: rgba(99, 102, 241, 0.08);
}
.admin-giftcard-image-preview img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}
.admin-giftcard-image-placeholder {
  font-size: 0.75rem;
  color: var(--text-muted);
  text-align: center;
  padding: 0 0.5rem;
}
.admin-giftcard-image-actions {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.admin-giftcard-upload-btn {
  display: inline-block;
  padding: 0.5rem 1rem;
  font-size: 0.85rem;
  background: rgba(99, 102, 241, 0.1);
  color: #818cf8;
  border: 1px solid rgba(99, 102, 241, 0.3);
  border-radius: 10px;
  cursor: pointer;
  font-weight: 600;
  transition: background 0.2s;
}
.admin-giftcard-upload-btn:hover {
  background: rgba(99, 102, 241, 0.18);
}
.admin-giftcard-upload-btn input {
  display: none;
}
.admin-giftcard-image-url-input {
  width: 100%;
  padding: 0.5rem 0.85rem;
  font-size: 0.9rem;
  border: 1px solid var(--border);
  border-radius: 8px;
}
.admin-giftcard-image-clear {
  align-self: flex-start;
  padding: 0.35rem 0.75rem;
  font-size: 0.8rem;
  color: var(--text-muted);
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 8px;
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s;
}
.admin-giftcard-image-clear:hover {
  color: #dc2626;
  border-color: #dc2626;
}
.admin-giftcard-modal-actions {
  display: flex;
  gap: 0.75rem;
  margin-top: 1.5rem;
  justify-content: flex-end;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
}
.admin-giftcard-btn-cancel {
  padding: 0.55rem 1.25rem;
  font-size: 0.9rem;
  font-weight: 600;
  background: transparent;
  color: var(--text-muted);
  border: 1px solid var(--border);
  border-radius: 10px;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}
.admin-giftcard-btn-cancel:hover {
  background: rgba(0, 0, 0, 0.04);
  color: var(--text);
}
.admin-giftcard-btn-save {
  padding: 0.55rem 1.5rem;
  font-size: 0.9rem;
  font-weight: 600;
  background: linear-gradient(135deg, #6366f1 0%, #4f46e5 100%);
  color: #fff;
  border: none;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.2s;
}
.admin-giftcard-btn-save:hover {
  filter: brightness(1.08);
  box-shadow: 0 4px 16px rgba(99, 102, 241, 0.4);
}
.admin-giftcard-toggle-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
  cursor: pointer;
  font-weight: 500;
  margin-bottom: 0;
}
.admin-giftcard-form-row .admin-giftcard-toggle-label {
  display: flex;
}

/* Orders panel */
.admin-panel-orders {
  --orders-accent: #d97706;
  --orders-accent-dim: rgba(217, 119, 6, 0.15);
  --orders-accent-border: rgba(217, 119, 6, 0.4);
}

.admin-panel-orders.admin-panel {
  max-width: min(100%, 1700px);
  width: 100%;
}

.admin-orders-card {
  background: var(--bg-card);
  border-radius: 14px;
  border: 1px solid var(--orders-accent-border);
  overflow: hidden;
  box-shadow:
    0 0 0 1px rgba(0, 0, 0, 0.03),
    0 4px 20px rgba(0, 0, 0, 0.06),
    0 2px 8px rgba(0, 0, 0, 0.04);
}

.admin-orders-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.35rem 1.6rem;
  background: linear-gradient(145deg, var(--orders-accent-dim) 0%, rgba(217, 119, 6, 0.06) 50%, rgba(0, 0, 0, 0.02) 100%);
  border-bottom: 2px solid var(--orders-accent);
}

.admin-orders-title-wrap {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
}

.admin-orders-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  background: linear-gradient(145deg, var(--orders-accent-dim) 0%, rgba(217, 119, 6, 0.08) 100%);
  border-radius: 12px;
  color: var(--orders-accent);
  flex-shrink: 0;
  box-shadow: 0 2px 8px rgba(217, 119, 6, 0.15);
}

.admin-orders-panel-title {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.01em;
}

.admin-orders-desc {
  margin: 0.35rem 0 0 0;
  font-size: 0.875rem;
  color: var(--text-muted);
  max-width: 480px;
  line-height: 1.45;
}

.admin-orders-toolbar {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.admin-orders-toolbar-main {
  justify-content: space-between;
}

.admin-orders-toolbar-buttons {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  flex-wrap: wrap;
}

.admin-orders-toolbar-filters {
  width: 100%;
  margin-top: 0.35rem;
  padding-top: 0.85rem;
  border-top: 1px solid var(--orders-accent-border);
  align-items: flex-end;
}

.admin-orders-filter-field {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.admin-orders-filter-field label {
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
}

.admin-orders-filter-field select,
.admin-orders-filter-field input[type='date'] {
  padding: 0.45rem 0.65rem;
  min-width: 132px;
  background: var(--bg-dark);
  border: 1px solid var(--orders-accent-border);
  border-radius: 8px;
  color: var(--text);
  font-family: inherit;
  font-size: 0.875rem;
}

.admin-orders-clear-filters-btn {
  padding: 0.45rem 0.9rem;
  margin-bottom: 1px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text-muted);
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
}

.admin-orders-clear-filters-btn:hover {
  color: var(--text);
  border-color: var(--orders-accent);
}

.admin-orders-payment {
  display: inline-block;
  max-width: 200px;
  font-weight: 600;
  font-size: 0.85rem;
  line-height: 1.3;
  word-break: break-word;
}

.admin-orders-filter {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.admin-orders-filter label {
  font-size: 0.9rem;
  color: var(--text-muted);
  font-weight: 500;
}

.admin-orders-filter input[type="text"] {
  padding: 0.5rem 0.85rem;
  min-width: 180px;
  background: var(--bg-dark);
  border: 1px solid var(--orders-accent-border);
  border-radius: 8px;
  color: var(--text);
  font-family: inherit;
  font-size: 0.9rem;
}

.admin-orders-refresh-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.55rem 1.1rem;
  background: linear-gradient(180deg, var(--orders-accent) 0%, #b45309 100%);
  color: #fff;
  border: none;
  border-radius: 10px;
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(217, 119, 6, 0.25);
  transition: filter 0.2s ease, box-shadow 0.2s ease, transform 0.15s ease;
}

.admin-orders-manual-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.55rem 1.1rem;
  background: linear-gradient(180deg, #a855f7 0%, #7c3aed 100%);
  color: #fff;
  border: none;
  border-radius: 10px;
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  box-shadow: 0 2px 8px rgba(34, 197, 94, 0.3);
  transition: filter 0.2s ease, box-shadow 0.2s ease, transform 0.15s ease;
}

.admin-orders-manual-btn:hover {
  filter: brightness(1.06);
  box-shadow: 0 4px 12px rgba(34, 197, 94, 0.4);
  transform: translateY(-1px);
}

.admin-orders-manual-btn:active {
  transform: translateY(0);
}

.admin-orders-refresh-btn:hover {
  filter: brightness(1.08);
  box-shadow: 0 4px 14px rgba(217, 119, 6, 0.35);
  transform: translateY(-1px);
}

.admin-orders-refresh-btn:active {
  transform: translateY(0);
}

.admin-orders-table-wrap {
  overflow-x: auto;
}

.admin-orders-table {
  width: 100%;
  min-width: 1380px;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.admin-orders-table th {
  text-align: left;
  padding: 0.85rem 1.25rem;
  background: var(--orders-accent-dim);
  color: var(--orders-accent);
  font-weight: 600;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.admin-orders-table td {
  padding: 0.9rem 1.25rem;
  border-top: 1px solid var(--border);
  color: var(--text);
  transition: background 0.15s ease;
  vertical-align: top;
}

.admin-orders-table tbody tr:hover {
  background: rgba(255, 255, 255, 0.02);
}

.admin-orders-empty {
  text-align: center;
  color: var(--text-muted);
  padding: 2rem 1rem !important;
}

.admin-orders-status {
  display: inline-flex;
  align-items: center;
  padding: 0.4rem 0.85rem;
  border-radius: 8px;
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  border: 1px solid transparent;
}

.admin-orders-status-completed {
  background: rgba(34, 197, 94, 0.15);
  color: #7c3aed;
  border-color: rgba(34, 197, 94, 0.3);
}

.admin-orders-status-pending {
  background: rgba(234, 179, 8, 0.15);
  color: #ca8a04;
  border-color: rgba(234, 179, 8, 0.3);
}

.admin-orders-status-sent {
  background: rgba(34, 197, 94, 0.15);
  color: #7c3aed;
  border-color: rgba(34, 197, 94, 0.3);
}

.admin-orders-status-pending-send {
  background: rgba(234, 179, 8, 0.15);
  color: #ca8a04;
  border-color: rgba(234, 179, 8, 0.3);
}

.admin-order-detail-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.4rem;
  padding-bottom: 1.4rem;
  border-bottom: 1px solid var(--border);
}

.admin-order-mark-sent-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.5rem 1rem;
  background: #a855f7;
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  transition: filter 0.2s;
}

.admin-order-mark-sent-btn:hover {
  filter: brightness(1.1);
}

.admin-order-sent-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.8rem;
  margin: 0;
  padding: 0.9rem 1.4rem;
  background: linear-gradient(145deg, rgba(34, 197, 94, 0.22) 0%, rgba(34, 197, 94, 0.09) 100%);
  border: 1px solid rgba(34, 197, 94, 0.5);
  border-radius: 14px;
  color: #166534;
  font-size: 0.9rem;
  font-weight: 600;
  box-shadow:
    0 0 0 1px rgba(34, 197, 94, 0.12) inset,
    0 4px 14px rgba(34, 197, 94, 0.12);
  animation: admin-order-sent-badge-in 0.35s ease-out backwards;
}

@keyframes admin-order-sent-badge-in {
  from {
    opacity: 0;
    transform: scale(0.98);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.admin-order-sent-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: linear-gradient(180deg, rgba(34, 197, 94, 0.45) 0%, rgba(34, 197, 94, 0.22) 100%);
  color: #fff;
  font-size: 1rem;
  font-weight: 800;
  flex-shrink: 0;
  box-shadow: 0 2px 8px rgba(34, 197, 94, 0.35);
  animation: admin-order-sent-icon-in 0.4s cubic-bezier(0.34, 1.2, 0.64, 1) 0.1s backwards;
}

@keyframes admin-order-sent-icon-in {
  from {
    opacity: 0;
    transform: scale(0.6);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.admin-order-sent-time {
  opacity: 0.92;
  font-weight: 500;
  font-size: 0.875rem;
}

.admin-orders-view-btn {
  padding: 0.5rem 1rem;
  background: linear-gradient(180deg, var(--orders-accent-dim) 0%, rgba(217, 119, 6, 0.08) 100%);
  color: var(--orders-accent);
  border: 1px solid var(--orders-accent-border);
  border-radius: 10px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: filter 0.2s ease, box-shadow 0.2s ease, transform 0.15s ease;
}

.admin-orders-view-btn:hover {
  filter: brightness(1.08);
  box-shadow: 0 3px 10px rgba(217, 119, 6, 0.22);
  transform: translateY(-1px);
}

.admin-orders-view-btn:active {
  transform: translateY(0);
}

.admin-order-detail-modal-inner {
  max-width: 980px;
  width: 96%;
  max-height: 90vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  padding: 0;
  border-radius: 22px;
  box-shadow:
    0 0 0 1px rgba(0, 0, 0, 0.06),
    0 4px 6px rgba(0, 0, 0, 0.04),
    0 28px 56px rgba(0, 0, 0, 0.1),
    0 56px 112px rgba(0, 0, 0, 0.07);
}

.admin-order-detail-modal-inner .admin-modal-header {
  margin: 0;
  padding: 1.85rem 2.5rem 1.5rem;
  border-bottom: 1px solid var(--border);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.04) 0%, rgba(255, 255, 255, 0.01) 50%, transparent 100%);
}

.admin-order-detail-modal-inner .admin-modal-title {
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.admin-order-detail-modal-inner .admin-modal-close {
  padding: 0.4rem;
  border-radius: 10px;
  transition: background 0.2s ease, color 0.2s ease;
}

.admin-order-detail-modal-inner .admin-modal-close:hover {
  background: rgba(0, 0, 0, 0.06);
  color: var(--text);
}

.admin-order-detail-id-pill {
  display: inline-block;
  padding: 0.4rem 1rem;
  font-family: ui-monospace, "Cascadia Code", "SF Mono", Monaco, monospace;
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: var(--orders-accent, #d97706);
  background: linear-gradient(180deg, rgba(217, 119, 6, 0.14) 0%, rgba(217, 119, 6, 0.07) 100%);
  border: 1px solid rgba(217, 119, 6, 0.35);
  border-radius: 10px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.admin-order-detail-id-pill:hover {
  transform: scale(1.02);
  box-shadow: 0 2px 8px rgba(217, 119, 6, 0.2);
}

.admin-order-detail-modal-inner .admin-modal-body {
  padding: 1.6rem 2.5rem 1.85rem;
  overflow-y: auto;
  overflow-x: hidden;
  scroll-behavior: smooth;
  background: linear-gradient(180deg, transparent 0%, rgba(0, 0, 0, 0.01) 100%);
}

.admin-order-detail-modal-inner .admin-modal-body::-webkit-scrollbar {
  width: 8px;
}

.admin-order-detail-modal-inner .admin-modal-body::-webkit-scrollbar-track {
  background: transparent;
}

.admin-order-detail-modal-inner .admin-modal-body::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: 4px;
}

.admin-order-detail-modal-inner .admin-modal-body::-webkit-scrollbar-thumb:hover {
  background: var(--text-muted);
}

.admin-order-detail-modal-inner .admin-modal-body > * {
  animation: admin-order-detail-fade-in 0.4s ease-out backwards;
}

.admin-order-detail-modal-inner .admin-order-detail-actions { animation-delay: 0.05s; }
.admin-order-detail-modal-inner .admin-order-manual-badge { animation-delay: 0.08s; }
.admin-order-detail-modal-inner .admin-order-detail-summary { animation-delay: 0.1s; }
.admin-order-detail-modal-inner .admin-order-detail-section:nth-of-type(2) { animation-delay: 0.14s; }
.admin-order-detail-modal-inner .admin-order-detail-keys { animation-delay: 0.18s; }
.admin-order-detail-modal-inner .admin-order-detail-accounts { animation-delay: 0.22s; }

@keyframes admin-order-detail-fade-in {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.admin-order-detail-modal-inner .admin-modal-body p {
  margin: 0.45rem 0 0.8rem;
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.5;
}

/* Order detail sections */
.admin-order-detail-section {
  margin-top: 1.5rem;
  padding-top: 1.35rem;
  border-top: none;
  position: relative;
}

.admin-order-detail-section::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent 0%, var(--border) 8%, var(--border) 92%, transparent 100%);
}

.admin-order-detail-summary {
  margin-top: 1.1rem;
  padding-top: 0;
  border-top: none;
}

.admin-order-detail-summary::before {
  display: none;
}

.admin-order-detail-section-title {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  margin: 0 0 1.1rem;
  padding: 0.5rem 0 0.5rem 0.95rem;
  font-size: 1rem;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.02em;
  border-left: 3px solid var(--orders-accent, rgba(217, 119, 6, 0.6));
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.03) 0%, transparent 100%);
  border-radius: 0 8px 8px 0;
}

.admin-order-detail-keys .admin-order-detail-section-title {
  border-left-color: rgba(34, 197, 94, 0.6);
}

.admin-order-detail-accounts .admin-order-detail-section-title {
  border-left-color: rgba(59, 130, 246, 0.6);
}

.admin-order-detail-status .admin-order-detail-section-title {
  border-left-color: rgba(168, 85, 247, 0.6);
}

.admin-order-detail-status-hint {
  font-size: 0.85rem;
  color: var(--text-muted, rgba(255, 255, 255, 0.5));
  margin: -0.5rem 0 0.9rem;
  padding: 0 0 0 0.95rem;
}

.admin-order-detail-status-wrap {
  padding: 0 0 0 0.95rem;
}

.admin-order-status-select {
  min-width: 180px;
  padding: 0.5rem 2rem 0.5rem 0.75rem;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text);
  background: #000;
  border: 1px solid var(--border);
  border-radius: 8px;
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12' fill='%23888'%3E%3Cpath d='M6 8L2 4h8z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.6rem center;
}

.admin-order-status-select:hover,
.admin-order-status-select:focus {
  border-color: var(--orders-accent, rgba(217, 119, 6, 0.5));
  outline: none;
}

.admin-order-detail-section-icon {
  font-size: 1.1rem;
  opacity: 0.9;
  margin-left: -0.05rem;
}

/* Summary block (Placed / Customer / Total) */
.admin-order-detail-summary-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem 1.75rem;
  padding: 1.5rem 1.75rem;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.06) 0%, rgba(255, 255, 255, 0.02) 100%);
  border: 1px solid var(--border);
  border-radius: 16px;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.03) inset,
    0 2px 8px rgba(0, 0, 0, 0.04);
}

@media (min-width: 380px) {
  .admin-order-detail-summary-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 480px) {
  .admin-order-detail-summary-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.admin-order-detail-summary-item:has(.admin-order-detail-total) {
  grid-column: 1 / -1;
  padding-top: 0.5rem;
  margin-top: 0.25rem;
  border-top: 1px solid var(--border);
}

@media (min-width: 480px) {
  .admin-order-detail-summary-item:has(.admin-order-detail-total) {
    grid-column: auto;
    padding-top: 0;
    margin-top: 0;
    border-top: none;
  }
}

.admin-order-detail-summary-item {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.admin-order-detail-summary-label {
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
}

.admin-order-detail-summary-label::before {
  content: "";
  display: inline-block;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--text-muted);
  opacity: 0.6;
  margin-right: 0.5rem;
  vertical-align: middle;
}

.admin-order-detail-summary-value {
  font-size: 1.02rem;
  font-weight: 500;
  color: var(--text);
}

.admin-order-detail-email {
  word-break: break-all;
}

.admin-order-detail-total {
  font-weight: 800;
  color: var(--orders-accent, #d97706);
  font-size: 1.2rem;
  letter-spacing: 0.02em;
}

.admin-order-detail-summary-item:has(.admin-order-detail-total) .admin-order-detail-summary-value {
  padding: 0.4rem 0.6rem;
  margin-top: 0.15rem;
  background: linear-gradient(135deg, rgba(217, 119, 6, 0.1) 0%, rgba(217, 119, 6, 0.05) 100%);
  border-radius: 8px;
  display: inline-block;
  width: fit-content;
}

/* Items list */
.admin-order-detail-section .admin-order-detail-items {
  margin: 0;
  padding: 1.35rem 1.6rem 1.35rem 1.85rem;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.04) 0%, rgba(255, 255, 255, 0.01) 100%);
  border: 1px solid var(--border);
  border-radius: 14px;
  line-height: 1.75;
  list-style: none;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.02);
}

.admin-order-detail-item-row {
  display: block;
  margin-bottom: 0.65rem;
  padding: 0.5rem 0;
  color: var(--text);
  font-size: 1.02rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.admin-order-detail-item-main {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: baseline;
  gap: 0.75rem;
}

.admin-order-detail-item-name {
  grid-column: 1;
  min-width: 0;
}

.admin-order-detail-item-price {
  grid-column: 2;
  justify-self: center;
}

.admin-order-detail-item-meta {
  margin-top: 6px;
  font-size: 12px;
  opacity: 0.86;
}

.admin-order-detail-item-row:last-child {
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: none;
}

.admin-order-detail-item-price {
  flex-shrink: 0;
  font-weight: 700;
  font-size: 1rem;
  color: var(--orders-accent, #d97706);
}

/* Delivered keys */
.admin-order-detail-keys {
  margin-top: 1.35rem;
}

.admin-order-detail-key-cards {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.admin-order-detail-key-card {
  padding: 1.15rem 1.35rem;
  background: linear-gradient(180deg, rgba(34, 197, 94, 0.06) 0%, rgba(255, 255, 255, 0.03) 100%);
  border: 1px solid var(--border);
  border-radius: 14px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
  animation: admin-order-key-card-in 0.35s ease-out backwards;
}

.admin-order-detail-key-card:nth-child(1) { animation-delay: 0.05s; }
.admin-order-detail-key-card:nth-child(2) { animation-delay: 0.1s; }
.admin-order-detail-key-card:nth-child(3) { animation-delay: 0.15s; }
.admin-order-detail-key-card:nth-child(n+4) { animation-delay: 0.2s; }

@keyframes admin-order-key-card-in {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.admin-order-detail-key-card:hover {
  border-color: rgba(34, 197, 94, 0.35);
  border-left-width: 3px;
  border-left-color: rgba(34, 197, 94, 0.5);
  padding-left: calc(1.35rem - 2px);
  box-shadow: 0 4px 16px rgba(34, 197, 94, 0.1);
}

.admin-order-detail-key-product {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 0.75rem;
  padding-bottom: 0.55rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.admin-order-detail-key-block {
  margin-top: 0.25rem;
}

.admin-order-detail-key-label {
  display: block;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  margin-bottom: 0.4rem;
}

.admin-order-detail-key-row {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  flex-wrap: wrap;
}

.admin-order-detail-key-value {
  flex: 1;
  min-width: 0;
  padding: 0.65rem 1rem;
  background: rgba(0, 0, 0, 0.22);
  border-radius: 10px;
  font-family: ui-monospace, "Cascadia Code", "SF Mono", Monaco, monospace;
  font-size: 0.875rem;
  word-break: break-all;
  color: var(--text);
  border: 1px solid var(--border);
  letter-spacing: 0.03em;
  line-height: 1.5;
  user-select: all;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.admin-order-detail-key-value:focus {
  outline: none;
  border-color: rgba(34, 197, 94, 0.5);
  box-shadow: 0 0 0 2px rgba(34, 197, 94, 0.15);
}

.admin-order-detail-key-value:focus-visible {
  border-color: rgba(34, 197, 94, 0.55);
  box-shadow: 0 0 0 2px rgba(34, 197, 94, 0.2);
}

.admin-order-detail-copy-key-btn {
  position: relative;
  flex-shrink: 0;
  padding: 0.52rem 1.05rem;
  min-width: 76px;
  background: linear-gradient(180deg, rgba(34, 197, 94, 0.28) 0%, rgba(34, 197, 94, 0.16) 100%);
  color: #a855f7;
  border: 1px solid rgba(34, 197, 94, 0.5);
  border-radius: 10px;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.25s ease, color 0.25s ease, border-color 0.25s ease, transform 0.15s ease, box-shadow 0.2s ease;
}

.admin-order-detail-copy-key-btn:hover {
  background: linear-gradient(180deg, rgba(34, 197, 94, 0.38) 0%, rgba(34, 197, 94, 0.26) 100%);
  border-color: rgba(34, 197, 94, 0.65);
  transform: translateY(-1px);
}

.admin-order-detail-copy-key-btn:focus-visible {
  outline: none;
  box-shadow: 0 0 0 2px rgba(34, 197, 94, 0.4);
}

.admin-order-detail-copy-key-btn:active {
  transform: translateY(0);
}

.admin-order-detail-copy-key-btn .admin-order-copy-icon,
.admin-order-detail-copy-key-btn .admin-order-copy-done-icon {
  display: inline-block;
  transition: opacity 0.2s ease;
}

.admin-order-detail-copy-key-btn .admin-order-copy-done-icon {
  display: none;
}

.admin-order-detail-copy-key-btn.admin-order-detail-copy-key-done .admin-order-copy-icon {
  display: none;
}

.admin-order-detail-copy-key-btn.admin-order-detail-copy-key-done .admin-order-copy-done-icon {
  display: inline-block;
}

.admin-order-detail-copy-key-btn.admin-order-detail-copy-key-done {
  background: linear-gradient(180deg, #a855f7 0%, #7c3aed 100%);
  color: #fff;
  border-color: #a855f7;
  box-shadow: 0 2px 8px rgba(34, 197, 94, 0.4);
}

/* Account credentials section */
.admin-order-detail-accounts .admin-order-detail-section-title {
  margin-bottom: 0.8rem;
}

.admin-order-detail-acc {
  margin-bottom: 1rem;
  padding: 1.2rem 1.35rem;
  background: linear-gradient(180deg, rgba(59, 130, 246, 0.05) 0%, rgba(255, 255, 255, 0.03) 100%);
  border: 1px solid var(--border);
  border-radius: 14px;
  font-size: 0.9rem;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.admin-order-detail-acc:hover {
  border-color: rgba(59, 130, 246, 0.25);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
}

.admin-order-detail-acc:last-child {
  margin-bottom: 0;
}

.admin-order-detail-acc-product {
  display: block;
  margin-bottom: 0.75rem;
  padding-bottom: 0.5rem;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.admin-order-detail-acc-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 0.85rem;
  margin-bottom: 0.45rem;
  font-size: 0.875rem;
}

.admin-order-detail-acc-row:last-child {
  margin-bottom: 0;
}

.admin-order-detail-acc-label {
  flex: 0 0 5.5rem;
  color: var(--text-muted);
  font-weight: 600;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.admin-order-detail-acc-value {
  flex: 1;
  min-width: 0;
  word-break: break-all;
  color: var(--text);
  font-weight: 500;
}

.admin-order-manual-badge {
  margin: 0 0 0.75rem;
  padding: 0.35rem 0.75rem;
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.14) 0%, rgba(34, 197, 94, 0.08) 100%);
  color: #a855f7;
  font-size: 0.78rem;
  font-weight: 600;
  border-radius: 8px;
  display: inline-block;
  border: 1px solid rgba(34, 197, 94, 0.3);
  letter-spacing: 0.02em;
}

/* Manual order & Fulfill order modals */
.admin-manual-order-inner {
  max-width: 580px;
  padding: 1.75rem 2rem;
  border-radius: 14px;
}

.admin-manual-order-inner .admin-modal-header {
  margin-bottom: 1.25rem;
  padding-bottom: 1.15rem;
  border-bottom: 1px solid var(--border);
}

.admin-manual-order-inner .admin-modal-title {
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #0f172a;
}

.admin-manual-order-hint {
  margin: 0 0 1.5rem;
  padding: 1rem 1.2rem;
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.55;
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.08) 0%, rgba(34, 197, 94, 0.03) 100%);
  border: 1px solid rgba(34, 197, 94, 0.2);
  border-radius: 12px;
  border-left: 4px solid #a855f7;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
}

.admin-manual-order-field {
  margin-bottom: 1.25rem;
}

.admin-manual-order-field > label {
  display: block;
  margin-bottom: 0.5rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text);
}

.admin-manual-order-input {
  width: 100%;
  padding: 0.65rem 1rem;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--bg-dark);
  color: var(--text);
  font-family: inherit;
  font-size: 0.9rem;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.admin-manual-order-input:hover {
  border-color: rgba(34, 197, 94, 0.25);
}

.admin-manual-order-input:focus {
  outline: none;
  border-color: #a855f7;
  box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.18);
  background: #fff;
}

select.admin-manual-order-input {
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12' fill='none' stroke='%2364748b' stroke-width='2'%3E%3Cpath d='M2 4l4 4 4-4'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.85rem center;
  padding-right: 2.25rem;
}

.manual-order-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.65rem;
  padding: 0.5rem 0;
}

.manual-order-row .manual-order-product {
  flex: 1;
  min-width: 0;
}

.manual-order-row .manual-order-qty {
  font-size: 0.9rem;
  color: var(--text-muted);
  white-space: nowrap;
}

#fulfill-order-rows {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.fulfill-order-row {
  display: flex;
  align-items: center;
  gap: 1.1rem;
  padding: 0.9rem 1.15rem;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.04) 0%, rgba(255, 255, 255, 0.02) 100%);
  border: 1px solid var(--border);
  border-radius: 12px;
  margin-bottom: 0;
  transition: background 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
  animation: fulfill-row-in 0.35s ease-out backwards;
}

.fulfill-order-row:nth-child(1) { animation-delay: 0.05s; }
.fulfill-order-row:nth-child(2) { animation-delay: 0.1s; }
.fulfill-order-row:nth-child(3) { animation-delay: 0.15s; }
.fulfill-order-row:nth-child(4) { animation-delay: 0.2s; }
.fulfill-order-row:nth-child(5) { animation-delay: 0.25s; }
.fulfill-order-row:nth-child(n+6) { animation-delay: 0.3s; }

@keyframes fulfill-row-in {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.fulfill-order-row:hover {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.06) 0%, rgba(255, 255, 255, 0.03) 100%);
  border-color: rgba(34, 197, 94, 0.25);
}

.fulfill-order-row:focus-within {
  border-color: rgba(34, 197, 94, 0.45);
  box-shadow: 0 0 0 2px rgba(34, 197, 94, 0.12);
}

.fulfill-order-row .fulfill-order-label {
  flex: 0 0 200px;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text);
  line-height: 1.35;
}

.fulfill-order-row .fulfill-order-select {
  flex: 1;
  min-width: 0;
}

.fulfill-order-row .fulfill-order-select:focus {
  background: #fff;
}

.admin-order-fulfill-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  padding: 0.85rem 1.75rem;
  background: linear-gradient(180deg, #a855f7 0%, #7c3aed 100%);
  color: #fff;
  border: none;
  border-radius: 14px;
  font-size: 1.05rem;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  box-shadow:
    0 1px 0 rgba(0, 0, 0, 0.1) inset,
    0 2px 10px rgba(34, 197, 94, 0.4);
  transition: filter 0.2s ease, box-shadow 0.2s ease, transform 0.15s ease;
}

.admin-order-fulfill-btn:hover {
  filter: brightness(1.06);
  box-shadow:
    0 1px 0 rgba(0, 0, 0, 0.08) inset,
    0 4px 16px rgba(34, 197, 94, 0.45);
  transform: translateY(-1px);
}

.admin-order-fulfill-btn:active {
  transform: translateY(0);
  box-shadow: 0 2px 6px rgba(34, 197, 94, 0.35);
}

.admin-manual-order-add-row {
  margin-top: 0.5rem;
  padding: 0.5rem 1rem;
  background: rgba(255, 255, 255, 0.06);
  border: 1px dashed var(--border);
  border-radius: 10px;
  color: var(--text-muted);
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.2s, color 0.2s, border-color 0.2s;
}

.admin-manual-order-add-row:hover {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text);
  border-color: rgba(34, 197, 94, 0.3);
}

.admin-manual-order-total-wrap {
  margin: 1.25rem 0;
  padding: 1rem 0;
  border-top: 1px solid var(--border);
  font-size: 1.05rem;
}

.admin-manual-order-total-wrap span {
  color: var(--orders-accent);
  font-weight: 700;
  font-size: 1.15rem;
}

.admin-manual-order-actions {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  margin-top: 1.25rem;
  padding-top: 0.5rem;
}

.admin-manual-order-submit {
  padding: 0.7rem 1.4rem;
  background: linear-gradient(180deg, #a855f7 0%, #7c3aed 100%);
  color: #fff;
  border: none;
  border-radius: 12px;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  box-shadow:
    0 1px 0 rgba(0, 0, 0, 0.1) inset,
    0 2px 10px rgba(34, 197, 94, 0.4);
  transition: filter 0.2s ease, box-shadow 0.2s ease, transform 0.15s ease;
}

.admin-manual-order-submit:hover {
  filter: brightness(1.06);
  box-shadow:
    0 1px 0 rgba(0, 0, 0, 0.08) inset,
    0 4px 16px rgba(34, 197, 94, 0.45);
  transform: translateY(-1px);
}

.admin-manual-order-submit:active {
  transform: translateY(0);
}

.admin-modal-cancel-btn {
  padding: 0.55rem 1.1rem;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 10px;
  color: var(--text-muted);
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease, transform 0.15s ease;
}

.admin-modal-cancel-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--text-muted);
  color: var(--text);
}

.admin-modal-cancel-btn:active {
  transform: scale(0.98);
}

.admin-ticket-state-open {
  display: inline-block;
  padding: 0.25rem 0.65rem;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  background: var(--support-accent-dim);
  color: var(--support-accent);
}

.admin-ticket-state-pending {
  display: inline-block;
  padding: 0.25rem 0.65rem;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  background: rgba(234, 179, 8, 0.2);
  color: #eab308;
}

.admin-ticket-state-closed {
  display: inline-block;
  padding: 0.25rem 0.65rem;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  background: rgba(255, 255, 255, 0.12);
  color: var(--text-muted);
}

/* Inbox-style subject cell */
.admin-support-inbox-table .admin-support-subject-cell {
  max-width: 320px;
}

.admin-support-subject-id {
  font-weight: 600;
  color: var(--text);
}

.admin-support-subject-preview {
  color: var(--text-muted);
  font-size: 0.9em;
}

/* User cell: avatar + name */
.admin-support-user-cell {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.admin-support-user-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--support-accent);
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  font-weight: 600;
  flex-shrink: 0;
}

.admin-support-user-name {
  font-weight: 500;
  color: var(--text);
}

.admin-support-last-update {
  color: var(--text-muted);
  font-size: 0.9rem;
}

.admin-ticket-btn-reply {
  padding: 0.45rem 1.1rem;
  background: var(--support-accent);
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: filter 0.2s, box-shadow 0.2s;
}

.admin-ticket-btn-reply:hover {
  filter: brightness(1.1);
  box-shadow: 0 2px 10px rgba(217, 119, 6, 0.35);
}

/* Admin ticket modal */
.admin-ticket-modal-content {
  max-width: 520px;
}

.admin-ticket-body {
  padding: 1rem 1.25rem;
}

/* Admin ticket modal – chat style with Support theme */
.admin-modal-content.admin-chat-window {
  max-width: 720px;
  width: 92%;
  background: #2a2a30;
  padding: 0;
  overflow: hidden;
}

.admin-support-chat {
  --support-accent: #d97706;
  --support-accent-dim: rgba(217, 119, 6, 0.14);
  --support-accent-border: rgba(217, 119, 6, 0.4);
  border: 1px solid var(--support-accent-border);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4), 0 0 0 1px rgba(217, 119, 6, 0.15);
}

.admin-support-chat-header.admin-chat-header {
  background: linear-gradient(135deg, rgba(217, 119, 6, 0.25) 0%, #32323a 100%);
  border-bottom: 2px solid var(--support-accent);
}

.admin-chat-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.25rem;
  background: #32323a;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.admin-chat-header .admin-modal-close {
  color: rgba(255, 255, 255, 0.8);
}

.admin-chat-header h3 {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 700;
  color: #fff;
}

.admin-chat-body {
  padding: 1rem;
  background: #2a2a30;
}

.admin-support-chat .admin-ticket-meta-row {
  background: rgba(217, 119, 6, 0.08);
  border: 1px solid var(--support-accent-border);
}

.admin-ticket-meta-row {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 1rem;
  padding: 0.75rem 1rem;
  background: rgba(255, 255, 255, 0.04);
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.admin-ticket-meta-row #admin-ticket-detail {
  margin: 0;
  padding: 0;
  border: none;
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.admin-support-chat .admin-ticket-number {
  background: var(--support-accent-dim);
  color: var(--support-accent);
}

.admin-ticket-number {
  display: inline-flex;
  align-items: center;
  padding: 0.35rem 0.65rem;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 6px;
  font-size: 0.8rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.95);
  letter-spacing: 0.02em;
}

.admin-ticket-email {
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.85);
  word-break: break-all;
}

.admin-ticket-meta-row label {
  margin-left: auto;
  color: rgba(255, 255, 255, 0.65);
  font-size: 0.8rem;
  font-weight: 500;
}

.admin-ticket-meta-row select {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #fff;
  padding: 0.4rem 0.75rem;
  border-radius: 6px;
  font-size: 0.85rem;
}

.admin-chat-panel {
  background: #fff;
  border-radius: 8px;
  padding: 1.25rem 1.5rem;
  max-height: 460px;
  min-height: 260px;
  overflow-y: auto;
  margin-bottom: 1rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.15);
}

.admin-chat-messages {
  font-size: 0.9rem;
  line-height: 1.5;
  color: #1a1a1a;
}

.admin-chat-line {
  margin-bottom: 0.5rem;
  white-space: pre-wrap;
  word-break: break-word;
}

.admin-chat-line:last-child {
  margin-bottom: 0;
}

.admin-chat-sender {
  font-weight: 600;
  color: #1a1a1a;
}

.admin-chat-sender.admin-chat-user {
  color: var(--support-accent);
}

/* Chat images: thumbnail + click to open bigger */
.admin-chat-img {
  max-width: 180px;
  max-height: 180px;
  border-radius: 8px;
  cursor: pointer;
  vertical-align: middle;
  object-fit: contain;
  border: 1px solid var(--border);
}
.admin-chat-img:hover {
  opacity: 0.9;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

/* Admin chat image lightbox – full screen, smooth popup */
.admin-lightbox {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  height: 100%;
  z-index: 10002;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  background: #000;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s ease-out, visibility 0.2s ease-out;
}
.admin-lightbox.is-open {
  opacity: 1;
  visibility: visible;
}
.admin-lightbox[hidden] {
  display: none !important;
}
.admin-lightbox-backdrop {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: transparent;
  cursor: pointer;
}
.admin-lightbox-content {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  box-sizing: border-box;
}
.admin-lightbox-img {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  display: block;
  border-radius: 4px;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.08);
  animation: admin-lightbox-img-in 0.2s ease-out;
}
@keyframes admin-lightbox-img-in {
  from {
    opacity: 0;
    transform: scale(0.96);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}
.admin-lightbox-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  width: 2.75rem;
  height: 2.75rem;
  border: none;
  background: rgba(0, 0, 0, 0.5);
  color: #fff;
  font-size: 1.5rem;
  line-height: 1;
  padding: 0;
  border-radius: 50%;
  cursor: pointer;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s ease;
}
.admin-lightbox-close:hover {
  background: rgba(0, 0, 0, 0.75);
}
.admin-lightbox-close:focus {
  outline: 2px solid rgba(255, 255, 255, 0.5);
  outline-offset: 2px;
}

#admin-ticket-detail {
  font-size: 0.9rem;
  margin-bottom: 1rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border);
}

.admin-chat-body #admin-ticket-detail {
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: none;
}

#admin-ticket-detail p {
  margin: 0.35rem 0;
}

.admin-ticket-status-row {
  margin-bottom: 1rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.admin-ticket-status-row label {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-muted);
}

#admin-ticket-status-select {
  padding: 0.4rem 0.75rem;
  background: var(--bg-dark);
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text);
  font-family: inherit;
  font-size: 0.9rem;
  cursor: pointer;
}

.admin-ticket-replies {
  max-height: 200px;
  overflow-y: auto;
  margin-bottom: 1rem;
}

.admin-ticket-reply-item {
  padding: 0.6rem 0.9rem;
  border-radius: 8px;
  margin-bottom: 0.5rem;
  font-size: 0.9rem;
}

.admin-ticket-reply-item.admin {
  background: var(--support-accent-dim);
  border-left: 3px solid var(--support-accent);
}

.admin-ticket-reply-item.user {
  background: rgba(255, 255, 255, 0.06);
  border-left: 3px solid var(--border);
}

.admin-ticket-reply-item .reply-meta {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-bottom: 0.25rem;
}

.admin-ticket-reply-form label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 0.35rem;
}

.admin-ticket-reply-form textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  margin-bottom: 0.75rem;
  background: var(--bg-dark);
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text);
  font-family: inherit;
  font-size: 0.95rem;
  resize: vertical;
}

.admin-ticket-actions {
  display: flex;
  gap: 0.75rem;
  justify-content: flex-end;
}

.btn-close-ticket {
  padding: 0.5rem 1rem;
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.2s;
}

.btn-close-ticket:hover {
  background: rgba(255, 255, 255, 0.06);
}

.btn-submit-reply {
  padding: 0.5rem 1.25rem;
  background: var(--support-accent);
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: filter 0.2s, box-shadow 0.2s;
}

.btn-submit-reply:hover {
  filter: brightness(1.1);
}

/* ========== ADMIN DARK MODE + NEON ========== */
.admin-page {
  --admin-neon-cyan: #06b6d4;
  --admin-neon-cyan-rgb: 6, 182, 212;
  --admin-neon-purple: #a855f7;
  --admin-neon-purple-rgb: 168, 85, 247;
  --admin-neon-glow: 0 0 20px rgba(6, 182, 212, 0.35);
  --admin-neon-glow-strong: 0 0 24px rgba(6, 182, 212, 0.5);
  --admin-neon-border: rgba(6, 182, 212, 0.4);
  --admin-dark-bg: #0a0a0f;
  --admin-dark-card: #12121a;
  --admin-dark-elevated: #16161f;
  --admin-dark-border: rgba(255, 255, 255, 0.08);
  --admin-dark-text: #e2e8f0;
  --admin-dark-muted: #94a3b8;
}

/* Dark mode: apply when .admin-dark is on body */
.admin-page.admin-dark .admin-login-screen {
  background: var(--admin-dark-bg);
}

.admin-page.admin-dark .admin-login-box {
  background: var(--admin-dark-card);
  border: 1px solid var(--admin-neon-border);
  box-shadow: var(--admin-neon-glow);
}

.admin-page.admin-dark .admin-login-box h2 {
  color: var(--admin-neon-cyan);
  text-shadow: 0 0 12px rgba(var(--admin-neon-cyan-rgb), 0.4);
}

.admin-page.admin-dark .admin-login-box input {
  background: var(--admin-dark-bg);
  border: 1px solid var(--admin-dark-border);
  color: var(--admin-dark-text);
}

.admin-page.admin-dark .admin-login-box input:focus {
  outline: none;
  border-color: var(--admin-neon-cyan);
  box-shadow: 0 0 0 2px rgba(var(--admin-neon-cyan-rgb), 0.25);
}

.admin-page.admin-dark .admin-login-box button {
  background: linear-gradient(135deg, var(--admin-neon-cyan), #0891b2);
  color: #000;
  font-weight: 700;
  box-shadow: var(--admin-neon-glow);
}

.admin-page.admin-dark .admin-login-box button:hover {
  box-shadow: var(--admin-neon-glow-strong);
  filter: brightness(1.1);
}

.admin-page.admin-dark .admin-login-back {
  color: var(--admin-neon-cyan);
}

.admin-page.admin-dark .admin-login-back:hover {
  color: #22d3ee;
  text-shadow: 0 0 8px rgba(var(--admin-neon-cyan-rgb), 0.5);
}

.admin-page.admin-dark .admin-login-hint {
  color: var(--admin-dark-muted);
}

.admin-page.admin-dark .admin-login-hint strong {
  color: var(--admin-dark-text);
}

/* Sidebar dark + neon */
.admin-page.admin-dark .admin-sidebar {
  background: var(--admin-dark-card);
  border-right: 1px solid var(--admin-dark-border);
}

.admin-page.admin-dark .sidebar-brand {
  border-bottom-color: var(--admin-dark-border);
}

.admin-page.admin-dark .sidebar-brand strong {
  color: #fff;
  text-shadow: 0 0 20px rgba(255, 255, 255, 0.15);
}

.admin-page.admin-dark .sidebar-sub {
  color: var(--admin-dark-muted);
}

.admin-page.admin-dark .sidebar-link {
  color: var(--admin-dark-muted);
}

.admin-page.admin-dark .sidebar-link:hover {
  background: rgba(255, 255, 255, 0.05);
  color: var(--admin-dark-text);
}

.admin-page.admin-dark .sidebar-link.active {
  background: rgba(var(--admin-neon-cyan-rgb), 0.15);
  color: var(--admin-neon-cyan);
  border-left: 3px solid var(--admin-neon-cyan);
  box-shadow: inset 0 0 20px rgba(var(--admin-neon-cyan-rgb), 0.08);
}

.admin-page.admin-dark .sidebar-divider {
  background: var(--admin-dark-border);
}

.admin-page.admin-dark .admin-sidebar-account {
  background: rgba(255, 255, 255, 0.04);
  border-color: var(--admin-dark-border);
}

.admin-page.admin-dark .admin-sidebar-account-label {
  color: var(--admin-dark-muted);
}

.admin-page.admin-dark .admin-sidebar-account-name {
  color: var(--admin-dark-text);
}

.admin-page.admin-dark .admin-sidebar-account-meta {
  color: var(--admin-dark-muted);
}

.admin-page.admin-dark .sidebar-logout {
  color: var(--admin-dark-muted);
}

.admin-page.admin-dark .sidebar-logout:hover {
  color: var(--admin-neon-cyan);
}

.admin-page.admin-dark .admin-menu-toggle {
  color: var(--admin-dark-muted);
}

.admin-page.admin-dark .admin-menu-toggle:hover {
  background: rgba(255, 255, 255, 0.08);
  color: var(--admin-neon-cyan);
}

.admin-page.admin-dark .admin-sidebar-overlay.is-visible {
  background: rgba(0, 0, 0, 0.65);
}

/* Main content dark */
.admin-page.admin-dark .admin-main {
  background: var(--admin-dark-bg);
}

.admin-page.admin-dark .admin-topbar {
  background: var(--admin-dark-card);
  border-bottom: 1px solid var(--admin-dark-border);
}

.admin-page.admin-dark .admin-topbar-title {
  color: var(--admin-neon-cyan);
  text-shadow: 0 0 16px rgba(var(--admin-neon-cyan-rgb), 0.4);
}

.admin-page.admin-dark .admin-welcome {
  color: var(--admin-dark-muted);
}

.admin-page.admin-dark .admin-topbar-logout {
  border-color: rgba(248, 113, 113, 0.6);
  color: #f87171;
}

.admin-page.admin-dark .admin-topbar-logout:hover {
  background: rgba(248, 113, 113, 0.2);
  color: #fca5a5;
  box-shadow: 0 0 12px rgba(248, 113, 113, 0.3);
}

/* Dark mode toggle button in topbar */
.admin-dark-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.45rem 0.9rem;
  background: var(--admin-dark-card, #1e293b);
  border: 1px solid var(--admin-dark-border, rgba(255,255,255,0.1));
  color: var(--admin-dark-muted, #94a3b8);
  border-radius: 8px;
  font-family: inherit;
  font-size: 0.9rem;
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s, box-shadow 0.2s;
}

.admin-dark-toggle:hover {
  color: var(--admin-neon-cyan);
  border-color: var(--admin-neon-cyan);
  box-shadow: 0 0 12px rgba(var(--admin-neon-cyan-rgb), 0.25);
}

.admin-page.admin-dark .admin-dark-toggle {
  background: rgba(var(--admin-neon-cyan-rgb), 0.1);
  border-color: var(--admin-neon-cyan);
  color: var(--admin-neon-cyan);
  box-shadow: 0 0 14px rgba(var(--admin-neon-cyan-rgb), 0.2);
}

.admin-page.admin-dark .admin-dark-toggle:hover {
  box-shadow: var(--admin-neon-glow);
}

.admin-dark-toggle .admin-dark-icon {
  flex-shrink: 0;
}

.admin-dark-toggle .moon-icon { display: inline-block; }
.admin-dark-toggle .sun-icon { display: none; }
.admin-page.admin-dark .admin-dark-toggle .moon-icon { display: none; }
.admin-page.admin-dark .admin-dark-toggle .sun-icon { display: inline-block; }

/* Panels & typography */
.admin-page.admin-dark .panel-title {
  color: #fff;
}

.admin-page.admin-dark .panel-welcome,
.admin-page.admin-dark .panel-description,
.admin-page.admin-dark .panel-placeholder,
.admin-page.admin-dark .panel-date {
  color: var(--admin-dark-muted);
}

.admin-page.admin-dark .panel-date svg {
  color: var(--admin-neon-cyan);
}

/* Metric cards dark + neon glow */
.admin-page.admin-dark .metric-card {
  background: var(--admin-dark-card);
  border: 1px solid var(--admin-dark-border);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.admin-page.admin-dark .metric-card:hover {
  border-color: var(--admin-neon-border);
  box-shadow: 0 0 24px rgba(var(--admin-neon-cyan-rgb), 0.15);
}

.admin-page.admin-dark .metric-label {
  color: var(--admin-dark-muted);
}

.admin-page.admin-dark .metric-value {
  color: #fff;
}

.admin-page.admin-dark .metric-icon-blue {
  background: rgba(var(--admin-neon-cyan-rgb), 0.2);
  color: var(--admin-neon-cyan);
  box-shadow: 0 0 16px rgba(var(--admin-neon-cyan-rgb), 0.3);
}

.admin-page.admin-dark .metric-icon-green {
  background: rgba(34, 197, 94, 0.2);
  color: #4ade80;
  box-shadow: 0 0 12px rgba(34, 197, 94, 0.25);
}

.admin-page.admin-dark .metric-icon-yellow {
  background: rgba(234, 179, 8, 0.2);
  color: #facc15;
  box-shadow: 0 0 12px rgba(234, 179, 8, 0.25);
}

.admin-page.admin-dark .metric-icon-red {
  background: rgba(248, 113, 113, 0.2);
  color: #f87171;
  box-shadow: 0 0 12px rgba(248, 113, 113, 0.25);
}

.admin-page.admin-dark .metric-card-featured {
  background: linear-gradient(135deg, rgba(var(--admin-neon-cyan-rgb), 0.25), rgba(var(--admin-neon-purple-rgb), 0.2));
  border-color: var(--admin-neon-cyan);
  box-shadow: var(--admin-neon-glow);
}

.admin-page.admin-dark .dashboard-top-selling-title {
  color: #fff;
}

.admin-page.admin-dark .dashboard-top-selling-sub,
.admin-page.admin-dark .dashboard-top-selling-sub strong {
  color: var(--admin-dark-muted);
}

.admin-page.admin-dark .dashboard-top-selling-row {
  background: var(--admin-dark-card);
  border-color: var(--admin-dark-border);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
}

.admin-page.admin-dark .dashboard-top-selling-row:hover {
  border-color: var(--admin-neon-border);
}

.admin-page.admin-dark .dashboard-top-selling-rank {
  color: var(--admin-neon-cyan);
  background: rgba(var(--admin-neon-cyan-rgb), 0.15);
}

.admin-page.admin-dark .dashboard-top-selling-name {
  color: var(--admin-dark-text);
}

.admin-page.admin-dark .dashboard-top-selling-meta {
  color: var(--admin-dark-muted);
}

.admin-page.admin-dark .dashboard-top-selling-meta strong {
  color: var(--admin-neon-cyan);
}

.admin-page.admin-dark .dashboard-top-selling-empty {
  background: var(--admin-dark-elevated);
  border-color: var(--admin-dark-border);
  color: var(--admin-dark-muted);
}

.admin-page.admin-dark .dashboard-top-selling-thumb {
  background: var(--admin-dark-elevated);
  box-shadow: 0 0 0 1px var(--admin-dark-border);
}

/* Cards: wallpaper, settings, tags */
.admin-page.admin-dark .wallpaper-card,
.admin-page.admin-dark .wallpaper-editor-card,
.admin-page.admin-dark .settings-storage-card,
.admin-page.admin-dark .tags-add-card {
  background: var(--admin-dark-card);
  border: 1px solid var(--admin-dark-border);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.admin-page.admin-dark .wallpaper-card:hover,
.admin-page.admin-dark .wallpaper-editor-card:hover {
  border-color: var(--admin-neon-cyan);
  box-shadow: var(--admin-neon-glow);
}

.admin-page.admin-dark .wallpaper-card-title,
.admin-page.admin-dark .settings-card-title {
  color: #fff;
}

.admin-page.admin-dark .wallpaper-card-desc,
.admin-page.admin-dark .settings-card-desc,
.admin-page.admin-dark .settings-card-hint {
  color: var(--admin-dark-muted);
}

.admin-page.admin-dark .wallpaper-preview {
  border-color: var(--admin-dark-border);
}

.admin-page.admin-dark .wallpaper-product-select,
.admin-page.admin-dark .wallpaper-url-input {
  background: var(--admin-dark-bg);
  border: 1px solid var(--admin-dark-border);
  color: var(--admin-dark-text);
}

.admin-page.admin-dark .wallpaper-product-select:focus,
.admin-page.admin-dark .wallpaper-url-input:focus {
  border-color: var(--admin-neon-cyan);
  box-shadow: 0 0 0 2px rgba(var(--admin-neon-cyan-rgb), 0.2);
}

.admin-page.admin-dark .wallpaper-save-btn {
  background: linear-gradient(135deg, var(--admin-neon-cyan), #0891b2);
  color: #000;
  font-weight: 700;
  box-shadow: var(--admin-neon-glow);
}

.admin-page.admin-dark .wallpaper-save-btn:hover {
  box-shadow: var(--admin-neon-glow-strong);
}

/* Tags */
.admin-page.admin-dark .tags-add-label {
  color: var(--admin-dark-muted);
}

.admin-page.admin-dark .tags-input {
  background: var(--admin-dark-bg);
  border: 1px solid var(--admin-dark-border);
  color: var(--admin-dark-text);
}

.admin-page.admin-dark .tags-input:focus {
  border-color: var(--admin-neon-cyan);
  box-shadow: 0 0 0 2px rgba(var(--admin-neon-cyan-rgb), 0.2);
}

.admin-page.admin-dark .tags-table-wrap {
  background: var(--admin-dark-card);
  border: 1px solid var(--admin-dark-border);
}

.admin-page.admin-dark .tags-table th {
  background: var(--admin-dark-elevated);
  color: var(--admin-dark-muted);
  border-bottom: 1px solid var(--admin-dark-border);
}

.admin-page.admin-dark .tags-table td {
  border-bottom: 1px solid var(--admin-dark-border);
  color: var(--admin-dark-text);
}

.admin-page.admin-dark .tags-table tbody tr:hover td {
  background: rgba(255, 255, 255, 0.03);
}

.admin-page.admin-dark .tags-table-num {
  color: var(--admin-dark-muted);
}

.admin-page.admin-dark .tags-table-name {
  color: #fff;
}

.admin-page.admin-dark .btn-add-tag {
  background: linear-gradient(135deg, var(--admin-neon-cyan), #0891b2);
  color: #000;
  font-weight: 600;
  box-shadow: 0 0 14px rgba(var(--admin-neon-cyan-rgb), 0.3);
}

.admin-page.admin-dark .btn-add-tag:hover {
  box-shadow: var(--admin-neon-glow);
}

.admin-page.admin-dark .tags-empty {
  background: var(--admin-dark-card);
  border-color: var(--admin-dark-border);
}

.admin-page.admin-dark .tags-empty p {
  color: var(--admin-dark-muted);
}

.admin-page.admin-dark .btn-cancel-tag {
  background: var(--admin-dark-elevated);
  color: var(--admin-dark-muted);
  border-color: var(--admin-dark-border);
}

.admin-page.admin-dark .btn-save-tag {
  background: linear-gradient(135deg, var(--admin-neon-cyan), #0891b2);
  color: #000;
  box-shadow: 0 0 12px rgba(var(--admin-neon-cyan-rgb), 0.25);
}

/* Modals */
.admin-page.admin-dark .admin-modal-backdrop {
  background: rgba(0, 0, 0, 0.75);
}

.admin-page.admin-dark .admin-modal-content {
  background: var(--admin-dark-card);
  border: 1px solid var(--admin-neon-border);
  box-shadow: var(--admin-neon-glow);
}

.admin-page.admin-dark .admin-modal-header {
  border-bottom-color: var(--admin-dark-border);
}

.admin-page.admin-dark .admin-modal-header h3 {
  color: #fff;
}

.admin-page.admin-dark .admin-modal-close {
  color: var(--admin-dark-muted);
}

.admin-page.admin-dark .admin-modal-close:hover {
  color: var(--admin-neon-cyan);
}

.admin-page.admin-dark .admin-modal-body {
  color: var(--admin-dark-text);
}

/* Create product form & add product form */
.admin-page.admin-dark .create-product-form .form-row label,
.admin-page.admin-dark #add-product-form label {
  color: var(--admin-dark-muted);
}

.admin-page.admin-dark .create-product-form .form-row input[type="text"],
.admin-page.admin-dark .create-product-form .form-row input[type="number"],
.admin-page.admin-dark .create-product-form .form-row input[type="url"],
.admin-page.admin-dark .create-product-form .form-row input[type="datetime-local"],
.admin-page.admin-dark .create-product-form .form-row select,
.admin-page.admin-dark .create-product-form .form-row textarea,
.admin-page.admin-dark #add-product-form input,
.admin-page.admin-dark #add-product-form select,
.admin-page.admin-dark #add-product-form textarea {
  background: var(--admin-dark-bg);
  border: 1px solid var(--admin-dark-border);
  color: var(--admin-dark-text);
}

.admin-page.admin-dark .create-product-form .form-row input:focus,
.admin-page.admin-dark .create-product-form .form-row select:focus,
.admin-page.admin-dark .create-product-form .form-row textarea:focus,
.admin-page.admin-dark #add-product-form input:focus,
.admin-page.admin-dark #add-product-form select:focus,
.admin-page.admin-dark #add-product-form textarea:focus {
  border-color: var(--admin-neon-cyan);
  box-shadow: 0 0 0 2px rgba(var(--admin-neon-cyan-rgb), 0.2);
}

.admin-page.admin-dark .btn-add-product {
  background: linear-gradient(135deg, var(--admin-neon-cyan), #0891b2);
  color: #000;
  font-weight: 700;
  box-shadow: 0 0 16px rgba(var(--admin-neon-cyan-rgb), 0.35);
}

.admin-page.admin-dark .btn-add-product:hover {
  box-shadow: var(--admin-neon-glow-strong);
}

.admin-page.admin-dark .btn-delete-all-products {
  background: linear-gradient(135deg, #ef4444, #dc2626);
  color: #fff;
  box-shadow: 0 0 14px rgba(239, 68, 68, 0.35);
}

.admin-page.admin-dark .btn-delete-all-products:hover {
  background: #b91c1c;
  box-shadow: 0 0 18px rgba(239, 68, 68, 0.5);
}

.admin-page.admin-dark .btn-free-storage {
  background: linear-gradient(135deg, #ef4444, #dc2626);
  color: #fff;
  box-shadow: 0 0 14px rgba(239, 68, 68, 0.35);
}

/* Product list / table cards */
.admin-page.admin-dark .product-list-card,
.admin-page.admin-dark .admin-product-card {
  background: var(--admin-dark-card);
  border: 1px solid var(--admin-dark-border);
}

.admin-page.admin-dark .product-list-card:hover,
.admin-page.admin-dark .admin-product-card:hover {
  border-color: var(--admin-neon-border);
  box-shadow: 0 0 20px rgba(var(--admin-neon-cyan-rgb), 0.12);
}

/* Support tickets */
.admin-page.admin-dark .admin-ticket-card {
  background: var(--admin-dark-card);
  border: 1px solid var(--admin-dark-border);
}

.admin-page.admin-dark .admin-ticket-reply-form textarea {
  background: var(--admin-dark-bg);
  border-color: var(--admin-dark-border);
  color: var(--admin-dark-text);
}

.admin-page.admin-dark .admin-ticket-reply-form textarea:focus {
  border-color: var(--admin-neon-cyan);
  box-shadow: 0 0 0 2px rgba(var(--admin-neon-cyan-rgb), 0.2);
}

.admin-page.admin-dark .btn-submit-reply {
  background: linear-gradient(135deg, var(--admin-neon-cyan), #0891b2);
  color: #000;
  box-shadow: 0 0 12px rgba(var(--admin-neon-cyan-rgb), 0.3);
}

/* Receipt panel (invoice yellow + charcoal theme) */
.admin-panel-receipt {
  --receipt-accent: #ffc107;
  --receipt-accent-dim: rgba(255, 193, 7, 0.18);
  --receipt-accent-border: rgba(255, 193, 7, 0.45);
  --receipt-charcoal: #1a1a1a;
}

.admin-receipt-card {
  background: var(--bg-card);
  border-radius: 14px;
  border: 1px solid var(--receipt-accent-border);
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
}

.admin-receipt-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.35rem 1.6rem;
  background: linear-gradient(145deg, var(--receipt-accent-dim) 0%, rgba(14, 165, 233, 0.05) 100%);
  border-bottom: 2px solid var(--receipt-accent);
}

.admin-receipt-title-wrap {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
}

.admin-receipt-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: var(--receipt-accent-dim);
  color: var(--receipt-accent);
  flex-shrink: 0;
}

.admin-receipt-panel-title {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 700;
}

.admin-receipt-desc {
  margin: 0.35rem 0 0;
  font-size: 0.85rem;
  color: var(--text-muted);
  max-width: 640px;
  line-height: 1.45;
}

.admin-receipt-desc code {
  font-size: 0.8em;
  padding: 0.1em 0.35em;
  border-radius: 4px;
  background: var(--bg-dark);
}

.admin-receipt-toolbar {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.admin-receipt-toolbar-main {
  justify-content: space-between;
}

.admin-receipt-toolbar-buttons {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  flex-wrap: wrap;
}

.admin-receipt-toolbar-filters {
  padding-top: 0.25rem;
  margin-top: 0.35rem;
  border-top: 1px solid var(--border);
  align-items: flex-end;
}

.admin-receipt-filter {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.admin-receipt-filter-field {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.admin-receipt-filter-field label {
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
}

.admin-receipt-filter-field select,
.admin-receipt-filter-field input[type='date'] {
  padding: 0.45rem 0.65rem;
  min-width: 140px;
  background: var(--bg-dark);
  border: 1px solid var(--receipt-accent-border);
  border-radius: 8px;
  color: var(--text);
  font-family: inherit;
  font-size: 0.875rem;
}

.admin-receipt-clear-filters-btn {
  padding: 0.45rem 0.9rem;
  margin-bottom: 1px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text-muted);
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
}

.admin-receipt-clear-filters-btn:hover {
  color: var(--text);
  border-color: var(--text-muted);
}

.admin-receipt-png-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.55rem 1.1rem;
  background: linear-gradient(180deg, #fff 0%, #f3f4f6 100%);
  color: #1a1a1a;
  border: 2px solid #1a1a1a;
  border-radius: 10px;
  font-weight: 700;
  font-size: 0.875rem;
  cursor: pointer;
  transition: box-shadow 0.2s, transform 0.15s;
}

.admin-receipt-png-btn:hover {
  box-shadow: 0 4px 14px rgba(26, 26, 26, 0.15);
}

.admin-receipt-download-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.55rem 1.1rem;
  background: #1a1a1a;
  color: #ffc107;
  border: 2px solid #ffc107;
  border-radius: 10px;
  font-weight: 700;
  font-size: 0.875rem;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}

.admin-receipt-download-btn:hover {
  background: #ffc107;
  color: #1a1a1a;
}

.admin-receipt-download-btn svg {
  flex-shrink: 0;
}

.admin-receipt-filter input[type='text'] {
  padding: 0.5rem 0.85rem;
  min-width: 200px;
  background: var(--bg-dark);
  border: 1px solid var(--receipt-accent-border);
  border-radius: 8px;
  color: var(--text);
  font-family: inherit;
}

.admin-receipt-refresh-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.55rem 1.1rem;
  background: linear-gradient(180deg, #ffc107 0%, #e6ac00 100%);
  color: #1a1a1a;
  border: none;
  border-radius: 10px;
  font-weight: 600;
  cursor: pointer;
}

.admin-receipt-warning {
  margin: 0;
  padding: 0.75rem 1.6rem;
  background: rgba(234, 179, 8, 0.15);
  color: #ca8a04;
  font-size: 0.875rem;
}

.admin-receipt-table-wrap {
  overflow-x: auto;
}

.admin-receipt-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.admin-receipt-table th,
.admin-receipt-table td {
  padding: 0.75rem 1rem;
  text-align: left;
  border-bottom: 1px solid var(--border);
}

.admin-receipt-table th {
  font-weight: 600;
  color: var(--text-muted);
  background: rgba(0, 0, 0, 0.02);
}

.admin-receipt-check-col {
  width: 44px;
  text-align: center;
  vertical-align: middle;
}

.admin-receipt-check-col input[type='checkbox'] {
  width: 1.1rem;
  height: 1.1rem;
  cursor: pointer;
  accent-color: #ffc107;
}

.admin-receipt-check-cell {
  text-align: center;
  vertical-align: middle;
}

.admin-receipt-check-cell input[type='checkbox'] {
  width: 1.1rem;
  height: 1.1rem;
  cursor: pointer;
  accent-color: #ffc107;
}

/* Off-screen render target for PNG export (html2canvas) */
#admin-receipt-capture-root {
  position: fixed;
  left: -12000px;
  top: 0;
  width: 820px;
  z-index: -1;
  pointer-events: none;
  overflow: visible;
  background: #fff;
}

#admin-receipt-capture-root .inv-receipt {
  box-shadow: none;
  margin: 0;
}

.admin-receipt-empty {
  text-align: center;
  color: var(--text-muted);
  padding: 2rem !important;
}

.admin-receipt-payment {
  display: inline-block;
  max-width: 200px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text);
  line-height: 1.3;
  word-break: break-word;
}

.admin-receipt-source {
  display: inline-block;
  padding: 0.2rem 0.5rem;
  border-radius: 6px;
  font-size: 0.8rem;
  font-weight: 600;
}

.admin-receipt-source-fib {
  background: rgba(99, 102, 241, 0.15);
  color: #6366f1;
}
.admin-receipt-source-fastpay {
  background: rgba(16, 185, 129, 0.15);
  color: #059669;
}
.admin-receipt-source-wallet,
.admin-receipt-source-store {
  background: rgba(255, 193, 7, 0.2);
  color: #b45309;
}
.admin-receipt-source-browser {
  background: rgba(107, 114, 128, 0.15);
  color: #6b7280;
}

.admin-receipt-view-btn {
  padding: 0.35rem 0.75rem;
  border-radius: 8px;
  border: 1px solid var(--receipt-accent-border);
  background: var(--bg-dark);
  color: #b45309;
  font-weight: 600;
  cursor: pointer;
}

.admin-receipt-detail-inner {
  max-width: 900px;
  width: calc(100vw - 2rem);
}

/* ——— Invoice / receipt document (modal body) ——— */
.inv-receipt {
  font-family: Montserrat, 'Segoe UI', system-ui, -apple-system, Roboto, 'Helvetica Neue', Arial, sans-serif;
  background: #fff;
  color: #333;
  padding: 0 0 0.5rem;
  line-height: 1.45;
}

.inv-receipt-header {
  position: relative;
  padding: 1.25rem 1.5rem 1rem;
  border-bottom: 1px solid #eee;
}

.inv-receipt-header-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}

.inv-receipt-brand-block {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.inv-receipt-logo-mark {
  width: 52px;
  height: 52px;
  background: #1a1a1a;
  color: #ffc107;
  font-weight: 800;
  font-size: 0.95rem;
  letter-spacing: -0.02em;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
}

.inv-receipt-store-name {
  display: block;
  font-size: 1.15rem;
  color: #1a1a1a;
  letter-spacing: 0.06em;
}

.inv-receipt-tagline {
  display: block;
  font-size: 0.8rem;
  color: #666;
  margin-top: 0.15rem;
}

.inv-receipt-title-block {
  position: relative;
  text-align: right;
  min-width: 200px;
  padding-top: 0.25rem;
}

.inv-receipt-yellow-accent {
  position: absolute;
  right: 0;
  top: 0;
  width: 72%;
  height: 10px;
  background: #ffc107;
  border-radius: 2px;
}

.inv-receipt-h1 {
  position: relative;
  margin: 0.85rem 0 0;
  font-size: 2.25rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: #1a1a1a;
  line-height: 1;
}

.inv-receipt-meta {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1.5rem;
  padding: 1.35rem 1.5rem;
  border-bottom: 1px solid #eee;
}

.inv-receipt-section-label {
  display: block;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: #888;
  margin-bottom: 0.5rem;
}

.inv-receipt-customer {
  font-weight: 700;
  font-size: 1rem;
  color: #1a1a1a;
}

.inv-receipt-address {
  margin-top: 0.5rem;
  font-size: 0.85rem;
  color: #555;
  line-height: 1.5;
}

.inv-receipt-dl {
  margin: 0;
  min-width: 220px;
}

.inv-receipt-dl-row {
  display: flex;
  justify-content: space-between;
  gap: 2rem;
  padding: 0.35rem 0;
  border-bottom: 1px solid #eee;
  font-size: 0.9rem;
}

.inv-receipt-dl-row dt {
  margin: 0;
  color: #777;
  font-weight: 500;
}

.inv-receipt-dl-row dd {
  margin: 0;
  font-weight: 700;
  color: #1a1a1a;
  text-align: right;
}

.inv-receipt-table-wrap {
  padding: 0 1.5rem;
  margin-top: 0.25rem;
}

.inv-receipt-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
}

.inv-receipt-table thead tr {
  background: #2d2d2d;
  color: #fff;
}

.inv-receipt-table th {
  padding: 0.65rem 0.75rem;
  font-weight: 600;
  text-align: left;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.inv-receipt-table th.inv-num,
.inv-receipt-table td.inv-num {
  text-align: right;
}

.inv-receipt-table tbody tr {
  border-bottom: 1px solid #e8e8e8;
}

.inv-receipt-table tbody td {
  padding: 0.7rem 0.75rem;
  color: #333;
  vertical-align: top;
}

.inv-col-sl,
.inv-sl {
  width: 44px;
  color: #666;
  font-weight: 600;
}

.inv-desc {
  font-weight: 500;
}

.inv-receipt-totals-outer {
  display: flex;
  justify-content: flex-end;
  padding: 1rem 1.5rem 0;
}

.inv-receipt-totals {
  min-width: 260px;
}

.inv-total-line {
  display: flex;
  justify-content: space-between;
  gap: 2rem;
  padding: 0.4rem 0;
  font-size: 0.9rem;
  color: #444;
}

.inv-grand-total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 2rem;
  margin-top: 0.5rem;
  padding: 0.75rem 1rem;
  background: #ffc107;
  color: #1a1a1a;
  font-weight: 800;
  font-size: 1rem;
  border-radius: 2px;
}

.inv-receipt-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1.5rem;
  padding: 1.5rem 1.5rem 1rem;
  margin-top: 0.5rem;
  border-top: 1px solid #eee;
}

.inv-thanks {
  margin: 0 0 0.75rem;
  font-weight: 600;
  color: #1a1a1a;
}

.inv-footer-heading {
  margin: 0.85rem 0 0.35rem;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #1a1a1a;
}

.inv-footer-text {
  margin: 0;
  font-size: 0.8rem;
  color: #555;
  max-width: 380px;
  line-height: 1.5;
}

.inv-receipt-sign {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  justify-content: flex-end;
  min-width: 180px;
  padding-top: 2rem;
}

.inv-sign-yellow-line {
  width: 100%;
  max-width: 200px;
  height: 4px;
  background: #ffc107;
  margin-bottom: 0.5rem;
}

.inv-sign-label {
  font-size: 0.8rem;
  color: #555;
}

.inv-receipt-footer-bar {
  margin: 1rem 1.5rem 0;
  padding: 0.65rem 1rem;
  background: #f5f5f5;
  text-align: center;
  font-size: 0.75rem;
  color: #555;
  border-radius: 2px;
}

.inv-receipt-extra {
  margin: 1rem 1.5rem 0;
  padding-top: 0.75rem;
  border-top: 1px dashed #ddd;
}

.inv-receipt-pre {
  font-size: 0.7rem;
  overflow: auto;
  max-height: 140px;
  padding: 0.5rem;
  background: #f9f9f9;
  border: 1px solid #eee;
  border-radius: 4px;
  margin-top: 0.35rem;
}

.admin-receipt-print-btn {
  margin: 1rem 0 0;
  padding: 0.65rem 1.35rem;
  border-radius: 4px;
  border: none;
  background: #ffc107;
  color: #1a1a1a;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(255, 193, 7, 0.35);
}

.admin-receipt-print-btn:hover {
  filter: brightness(1.05);
}

/* Invoice reads as a white paper doc even in admin dark theme */
.admin-page.admin-dark .admin-receipt-detail-inner {
  background: #fff;
}
.admin-page.admin-dark #admin-receipt-detail-body .inv-receipt {
  color: #333;
}

@media print {
  body * {
    visibility: hidden;
  }
  #admin-receipt-detail-modal,
  #admin-receipt-detail-modal * {
    visibility: visible;
  }
  #admin-receipt-detail-modal {
    position: fixed;
    left: 0;
    top: 0;
    width: 100%;
    height: auto;
    background: #fff !important;
    box-shadow: none !important;
  }
  .admin-receipt-detail-inner {
    max-width: none;
    width: 100%;
    box-shadow: none !important;
  }
  .admin-receipt-print-hide,
  .admin-receipt-detail-actions {
    display: none !important;
  }
  .inv-receipt {
    padding: 0.5rem;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }
  .inv-receipt-table thead tr {
    background: #2d2d2d !important;
    color: #fff !important;
  }
  .inv-grand-total {
    background: #ffc107 !important;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }
  .inv-receipt-yellow-accent,
  .inv-sign-yellow-line {
    background: #ffc107 !important;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }
}
