/* ─────────────────────────────────────────────
   SUCCINCT — Dark / Red Theme
   ───────────────────────────────────────────── */

:root {
  --bg-primary: #0b0b12;
  --bg-secondary: #111119;
  --bg-card: #16161f;
  --bg-card-hover: #1c1c28;
  --bg-input: #111119;
  --bg-elevated: #1a1a25;
  --border: #252530;
  --border-light: #2e2e3d;
  --border-focus: #dc2626;
  --accent: #dc2626;
  --accent-hover: #b91c1c;
  --accent-light: rgba(220, 38, 38, 0.10);
  --accent-glow: rgba(220, 38, 38, 0.20);
  --accent-soft: rgba(220, 38, 38, 0.06);
  --green: #22c55e;
  --green-light: rgba(34, 197, 94, 0.10);
  --green-bg: rgba(34, 197, 94, 0.08);
  --yellow: #eab308;
  --yellow-light: rgba(234, 179, 8, 0.10);
  --yellow-border: rgba(234, 179, 8, 0.30);
  --blue: #3b82f6;
  --blue-hover: #2563eb;
  --blue-light: rgba(59, 130, 246, 0.10);
  --blue-glow: rgba(59, 130, 246, 0.18);
  --red: #ef4444;
  --red-light: rgba(239, 68, 68, 0.10);
  --teal: #14b8a6;
  --purple: #8b5cf6;
  --indigo: #6366f1;
  --cyan: #06b6d4;
  --text-primary: #e2e4ea;
  --text-secondary: #8b8d98;
  --text-muted: #555666;
  --radius: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;
  --shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.5);
  --shadow-glow: 0 0 20px rgba(220, 38, 38, 0.12);
  --transition: 150ms ease;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  color: var(--accent-hover);
}

::selection {
  background: var(--accent);
  color: #fff;
}

::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

::-webkit-scrollbar-track {
  background: var(--bg-primary);
}

::-webkit-scrollbar-thumb {
  background: var(--border-light);
  border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--text-muted);
}

/* ─── REFUND TIMER ─── */

.refund-timer-bar {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 12px;
  margin-bottom: 16px;
  transition: opacity 0.3s ease;
}

.base-item-refund:hover {
  border-color: var(--accent);
  transition: border-color 0.15s ease;
}

.refund-check-btn:hover:not(:disabled) {
  filter: brightness(1.15);
}

/* ─── HEADER ─── */

.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(17, 17, 25, 0.85);
  backdrop-filter: blur(16px) saturate(180%);
  -webkit-backdrop-filter: blur(16px) saturate(180%);
  border-bottom: 1px solid var(--border);
}

.header-accent {
  height: 2px;
  background: linear-gradient(90deg, var(--accent) 0%, #ff4444 40%, transparent 100%);
}

.header-inner {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 24px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.header-left {
  display: flex;
  align-items: center;
  gap: 24px;
  flex-shrink: 0;
}

.header-right {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 17px;
  letter-spacing: 1.5px;
  color: var(--text-primary);
  cursor: pointer;
  flex-shrink: 0;
  text-transform: uppercase;
}

.logo-icon {
  width: 30px;
  height: 30px;
  background: var(--accent);
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 800;
  color: #fff;
  box-shadow: 0 0 12px rgba(220, 38, 38, 0.3);
}

.nav-tabs {
  display: flex;
  align-items: center;
  gap: 2px;
  padding: 0;
  background: none;
  border-radius: 0;
}

.nav-tab {
  position: relative;
  padding: 8px 14px;
  border-radius: 0;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  cursor: pointer;
  transition: color var(--transition);
  border: none;
  background: none;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 54px;
  font-family: inherit;
}

.nav-tab:hover {
  color: var(--text-primary);
  background: none;
}

.nav-tab.active {
  color: var(--accent);
  font-weight: 600;
  background: none;
  border-bottom: 2px solid var(--accent);
}

.nav-tab.active svg {
  color: var(--accent);
}

.balance-badge {
  display: flex;
  align-items: center;
  gap: 6px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 6px 12px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition);
  color: var(--text-primary);
}

.balance-badge:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow-glow);
}

.balance-badge .amount {
  color: var(--green);
  font-weight: 700;
}

.balance-badge .label {
  color: var(--text-secondary);
  font-weight: 400;
  display: none;
}

.balance-badge .refresh-icon {
  color: var(--text-muted);
  cursor: pointer;
  transition: color var(--transition);
}

.balance-badge .refresh-icon:hover {
  color: var(--text-primary);
}

.level-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 5px 10px;
  background: var(--yellow-light);
  border: 1px solid var(--yellow-border);
  border-radius: 6px;
  font-size: 11px;
  font-weight: 700;
  color: var(--yellow);
  cursor: default;
}

.header-cart-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 6px;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all var(--transition);
}

.header-cart-icon:hover {
  color: var(--text-primary);
  background: var(--bg-card);
}

.header-lang {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 13px;
  color: var(--text-secondary);
  cursor: pointer;
}

.user-menu {
  position: relative;
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: var(--radius);
  transition: background var(--transition);
}

.user-menu:hover {
  background: var(--bg-card);
}

.user-avatar {
  width: 30px;
  height: 30px;
  border-radius: 6px;
  background: var(--accent-light);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  color: var(--accent);
}

.user-name {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-primary);
}

.dropdown {
  display: none;
  position: absolute;
  top: 100%;
  right: 0;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  min-width: 160px;
  padding: 4px;
  z-index: 200;
  margin-top: 4px;
}

.dropdown.show {
  display: block;
}

.dropdown-item {
  display: block;
  width: 100%;
  padding: 8px 12px;
  font-size: 13px;
  color: var(--text-primary);
  background: none;
  border: none;
  cursor: pointer;
  text-align: left;
  border-radius: 4px;
  transition: background var(--transition);
  font-family: inherit;
}

.dropdown-item:hover {
  background: var(--bg-card-hover);
}

.dropdown-item.danger {
  color: var(--red);
}

.dropdown-item.danger:hover {
  background: var(--red-light);
}

/* ─── MAIN LAYOUT ─── */

.main {
  max-width: 1400px;
  margin: 0 auto;
  padding: 24px;
}

/* ─── AUTH ─── */

.auth-wrapper {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: var(--bg-primary);
}

.auth-card {
  width: 100%;
  max-width: 400px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 40px 32px;
  box-shadow: var(--shadow-lg);
}

.auth-logo {
  text-align: center;
  margin-bottom: 32px;
}

.auth-logo .logo-icon {
  width: 48px;
  height: 48px;
  font-size: 20px;
  margin: 0 auto 16px;
  border-radius: 10px;
}

.auth-logo h1 {
  font-size: 24px;
  font-weight: 800;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.auth-logo p {
  color: var(--text-secondary);
  font-size: 14px;
}

/* ─── FORM ELEMENTS ─── */

.form-group {
  margin-bottom: 16px;
}

.form-label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.form-input {
  width: 100%;
  padding: 10px 14px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text-primary);
  font-size: 14px;
  font-family: inherit;
  transition: all var(--transition);
  outline: none;
}

.form-input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-light);
}

.form-input::placeholder {
  color: var(--text-muted);
}

textarea.form-input {
  resize: vertical;
  min-height: 80px;
}

select.form-input {
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23555666' stroke-width='2'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 32px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.form-helper {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 4px;
}

.input-with-prefix {
  position: relative;
}

.input-with-prefix .prefix {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  font-size: 14px;
  font-weight: 600;
  pointer-events: none;
}

/* ─── BUTTONS ─── */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 16px;
  border: none;
  border-radius: var(--radius);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition);
  white-space: nowrap;
  font-family: inherit;
  text-decoration: none;
}

.btn-primary,
.btn-orange {
  background: var(--accent);
  color: #fff;
}

.btn-primary:hover,
.btn-orange:hover {
  background: var(--accent-hover);
  box-shadow: 0 0 16px rgba(220, 38, 38, 0.3);
}

.btn-primary:disabled,
.btn-orange:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  box-shadow: none;
}

.btn-secondary {
  background: var(--bg-elevated);
  color: var(--text-primary);
  border: 1px solid var(--border);
}

.btn-secondary:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-light);
}

.btn-ghost {
  background: transparent;
  color: var(--text-secondary);
  border: 1px solid var(--border);
}

.btn-ghost:hover {
  background: var(--bg-card);
  color: var(--text-primary);
}

.btn-danger {
  background: rgba(239, 68, 68, 0.12);
  color: var(--red);
  border: 1px solid rgba(239, 68, 68, 0.20);
}

.btn-danger:hover {
  background: rgba(239, 68, 68, 0.20);
}

.btn-sm {
  padding: 5px 12px;
  font-size: 12px;
}

.btn-lg {
  padding: 12px 24px;
  font-size: 14px;
  font-weight: 700;
}

.btn-full {
  width: 100%;
}

.btn-banner {
  padding: 8px 20px;
  background: #fff;
  color: var(--accent);
  border: none;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: all var(--transition);
  font-family: inherit;
  white-space: nowrap;
}

.btn-banner:hover {
  background: #f0f0f0;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* ─── PAGES ─── */

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

.page-title {
  font-size: 22px;
  font-weight: 800;
  color: var(--text-primary);
  letter-spacing: -0.3px;
}

.page-subtitle {
  font-size: 13px;
  color: var(--text-secondary);
  margin-top: 2px;
}

.page-two-col {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 24px;
  align-items: start;
}

@media (max-width: 900px) {
  .page-two-col {
    grid-template-columns: 1fr;
  }
}

/* ─── LOADING ─── */

.loading-page {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 80px 0;
}

.spinner {
  width: 24px;
  height: 24px;
  border: 3px solid var(--border);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* ─── WELCOME CARD ─── */

.welcome-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
  margin-bottom: 20px;
}

.welcome-card h2 {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 6px;
}

.welcome-card p {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* ─── RANDOM BUY BANNER ─── */

.random-buy-banner {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 18px 24px;
  background: linear-gradient(135deg, #1a0808 0%, #2a0a0a 50%, #1a0808 100%);
  border: 1px solid rgba(220, 38, 38, 0.25);
  border-radius: var(--radius-lg);
  margin-bottom: 24px;
  position: relative;
  overflow: hidden;
}

.random-buy-banner::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 20% 50%, rgba(220, 38, 38, 0.08) 0%, transparent 70%);
  pointer-events: none;
}

.banner-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 18px;
  flex-shrink: 0;
}

.banner-text {
  flex: 1;
  min-width: 0;
}

.banner-title {
  font-size: 15px;
  font-weight: 700;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 8px;
}

.banner-subtitle {
  font-size: 12px;
  color: var(--text-secondary);
  margin-top: 2px;
}

.discount-tag {
  display: inline-flex;
  padding: 2px 8px;
  background: var(--green);
  color: #fff;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 700;
}

/* ─── SECTION HEADINGS ─── */

.section-heading {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
  margin-top: 4px;
}

.section-heading svg {
  color: var(--accent);
}

/* ─── BASES GRID (Dashboard Cards) ─── */

.bases-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 12px;
  margin-bottom: 28px;
}

.base-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 16px;
  transition: all var(--transition);
  position: relative;
}

.base-card:hover {
  border-color: var(--border-light);
  box-shadow: var(--shadow);
  transform: translateY(-1px);
}

.base-card-header {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 8px;
}

.base-card-name {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-primary);
}

.hot-badge {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 2px 8px;
  background: rgba(220, 38, 38, 0.12);
  color: var(--accent);
  border-radius: 4px;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.card-count-badge {
  display: inline-flex;
  padding: 2px 8px;
  background: var(--blue-light);
  color: var(--blue);
  border-radius: 4px;
  font-size: 10px;
  font-weight: 600;
}

.new-badge {
  display: inline-flex;
  padding: 2px 8px;
  background: var(--green-light);
  color: var(--green);
  border-radius: 4px;
  font-size: 10px;
  font-weight: 700;
}

.refund-badge {
  display: inline-flex;
  padding: 2px 8px;
  background: rgba(139, 92, 246, 0.10);
  color: var(--purple);
  border-radius: 4px;
  font-size: 10px;
  font-weight: 600;
}

.price-tag {
  display: block;
  font-size: 20px;
  font-weight: 800;
  color: var(--accent);
  margin: 8px 0;
}

.base-card-countries {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
  margin-bottom: 8px;
}

.country-pill {
  display: inline-flex;
  padding: 3px 10px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 4px;
  font-size: 11px;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.base-card-features {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.feature-tag {
  display: inline-flex;
  padding: 3px 8px;
  border-radius: 4px;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.feature-tag.holder {
  background: var(--accent-light);
  color: var(--accent);
}

.feature-tag.addr {
  background: var(--blue-light);
  color: var(--blue);
}

.feature-tag.zip {
  background: var(--green-light);
  color: var(--green);
}

.base-card-footer {
  display: flex;
  justify-content: flex-end;
}

/* ─── QUICK ACTION BUTTONS ─── */

.quick-action-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 16px 8px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  cursor: pointer;
  transition: all var(--transition);
  color: var(--text-primary);
  font-family: inherit;
}

.quick-action-btn:hover {
  border-color: var(--border-light);
  box-shadow: var(--shadow);
  transform: translateY(-2px);
}

.qa-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.qa-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
}

@media (max-width: 600px) {
  .quick-action-btn {
    padding: 12px 6px;
  }
  .qa-icon {
    width: 34px;
    height: 34px;
  }
  .qa-label {
    font-size: 10px;
  }
}

/* ─── NOTICE / INFO CARDS ─── */

.notice-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 20px;
  margin-bottom: 16px;
}

.notice-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--accent);
  margin-bottom: 12px;
}

.notice-card ul {
  list-style: none;
  padding: 0;
}

.notice-card li {
  font-size: 13px;
  color: var(--text-secondary);
  padding: 6px 0;
  padding-left: 16px;
  position: relative;
  line-height: 1.5;
}

.notice-card li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 12px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent);
  opacity: 0.6;
}

.site-info-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 20px;
}

.info-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.site-info-card p {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* ─── TABLES ─── */

.table-wrap {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.table-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  border-bottom: 1px solid var(--border);
}

.table-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-primary);
}

table {
  width: 100%;
  border-collapse: collapse;
}

thead th {
  text-align: left;
  padding: 10px 16px;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-muted);
  background: var(--bg-elevated);
  border-bottom: 1px solid var(--border);
}

tbody td {
  padding: 10px 16px;
  font-size: 13px;
  border-bottom: 1px solid var(--border);
  color: var(--text-primary);
}

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

tbody tr:hover {
  background: var(--bg-card-hover);
}

/* ─── BADGES ─── */

.badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.badge-green {
  background: var(--green-light);
  color: var(--green);
}

.badge-red {
  background: var(--red-light);
  color: var(--red);
}

.badge-blue {
  background: var(--blue-light);
  color: var(--blue);
}

.badge-yellow {
  background: var(--yellow-light);
  color: var(--yellow);
}

.badge-gray {
  background: rgba(107, 114, 128, 0.12);
  color: var(--text-secondary);
}

.badge-orange,
.badge-accent {
  background: var(--accent-light);
  color: var(--accent);
}

/* ─── SECTION CARDS ─── */

.section-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.section-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  border-bottom: 1px solid var(--border);
}

.section-card-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 8px;
}

.section-card-body {
  padding: 18px;
}

/* ─── SEARCH BAR ─── */

.search-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0 14px;
  min-width: 280px;
  transition: border-color var(--transition);
}

.search-bar:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-light);
}

.search-bar svg {
  color: var(--text-muted);
  flex-shrink: 0;
}

.search-bar input {
  border: none;
  background: transparent;
  color: var(--text-primary);
  font-size: 13px;
  padding: 10px 0;
  outline: none;
  width: 100%;
  font-family: inherit;
}

.search-bar input::placeholder {
  color: var(--text-muted);
}

/* ─── FILTER CARD ─── */

.filter-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 18px;
  margin-bottom: 20px;
}

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

.filter-card-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 8px;
}

.filter-card-actions {
  display: flex;
  gap: 8px;
}

.filter-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
}

.price-range {
  display: flex;
  align-items: center;
  gap: 8px;
}

.price-range input {
  flex: 1;
  min-width: 0;
}

.price-range .separator {
  color: var(--text-muted);
  font-weight: 600;
}

.filter-pills {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.filter-pill {
  padding: 5px 14px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 20px;
  font-size: 11px;
  font-weight: 600;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all var(--transition);
  font-family: inherit;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.filter-pill:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.filter-pill.active {
  background: var(--accent-light);
  border-color: var(--accent);
  color: var(--accent);
}

/* ─── PRODUCT CARDS ─── */

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 12px;
}

.product-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 18px;
  cursor: pointer;
  transition: all var(--transition);
}

.product-card:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow-glow);
  transform: translateY(-2px);
}

.product-card-icon {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: var(--accent-light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  margin-bottom: 12px;
}

.product-card-name {
  font-size: 14px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.product-card-category {
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 12px;
}

.product-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 8px;
}

.product-card-price {
  font-size: 18px;
  font-weight: 800;
  color: var(--accent);
}

.product-card-stock {
  font-size: 12px;
  font-weight: 600;
}

.stock-available {
  color: var(--green);
}

.stock-out {
  color: var(--red);
}

/* ─── DEPOSIT PAGE ─── */

.wallet-balance-card {
  background: linear-gradient(135deg, #1a0808 0%, #2a0a0a 50%, #1a0808 100%);
  border: 1px solid rgba(220, 38, 38, 0.20);
  border-radius: var(--radius-xl);
  padding: 32px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.wallet-balance-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 0%, rgba(220, 38, 38, 0.10) 0%, transparent 60%);
  pointer-events: none;
}

.wallet-balance-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 8px;
}

.wallet-balance-amount {
  font-size: 36px;
  font-weight: 800;
  color: #fff;
  letter-spacing: -1px;
}

.crypto-selector {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 4px;
}

.crypto-option {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  cursor: pointer;
  transition: all var(--transition);
}

.crypto-option:hover {
  border-color: var(--border-light);
}

.crypto-option.selected {
  border-color: var(--accent);
  background: var(--accent-light);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

.crypto-icon {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  font-weight: 700;
  color: #fff;
}

.crypto-icon.bitcoin {
  background: #f7931a;
}

.crypto-icon.litecoin {
  background: #345d9d;
}

.crypto-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
}

.crypto-network {
  font-size: 11px;
  color: var(--text-muted);
}

.deposit-details {
  padding-top: 8px;
}

.deposit-amount-crypto {
  font-size: 22px;
  font-weight: 800;
  color: var(--accent);
  text-align: center;
  margin: 12px 0 4px;
}

.deposit-qr {
  text-align: center;
  margin: 16px 0;
}

.deposit-qr img {
  width: 180px;
  height: 180px;
  border-radius: var(--radius);
  border: 2px solid var(--border);
  background: #fff;
  padding: 8px;
}

.deposit-address {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px;
  text-align: center;
  font-size: 12px;
  font-family: 'SF Mono', monospace;
  color: var(--text-primary);
  cursor: pointer;
  word-break: break-all;
  transition: all var(--transition);
  position: relative;
}

.deposit-address:hover {
  border-color: var(--accent);
}

.copy-hint {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 6px;
  font-family: 'Inter', sans-serif;
}

.deposit-timer {
  text-align: center;
  font-size: 13px;
  font-weight: 600;
  color: var(--yellow);
  margin-top: 12px;
  padding: 8px;
  background: var(--yellow-light);
  border-radius: var(--radius);
}

/* ─── ORDER CODE ─── */

.order-code {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 8px 12px;
  font-family: 'SF Mono', monospace;
  font-size: 12px;
  color: var(--text-primary);
  cursor: pointer;
  transition: all var(--transition);
  word-break: break-all;
}

.order-code:hover {
  border-color: var(--accent);
  background: var(--accent-soft);
}

/* ─── MODAL ─── */

.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 24px;
}

.modal-overlay.hidden {
  display: none;
}

.modal {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  width: 100%;
  max-width: 480px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow-lg);
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 22px;
  border-bottom: 1px solid var(--border);
}

.modal-title {
  font-size: 16px;
  font-weight: 700;
}

.modal-close {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 22px;
  cursor: pointer;
  transition: color var(--transition);
  line-height: 1;
  padding: 0;
}

.modal-close:hover {
  color: var(--text-primary);
}

.modal-body {
  padding: 22px;
}

.modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  padding: 16px 22px;
  border-top: 1px solid var(--border);
}

/* ─── TOAST ─── */

#toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 2000;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.toast {
  padding: 12px 20px;
  border-radius: var(--radius);
  font-size: 13px;
  font-weight: 500;
  color: #fff;
  box-shadow: var(--shadow-md);
  animation: toastIn 0.2s ease-out;
  max-width: 360px;
}

.toast.success {
  background: #16a34a;
}

.toast.error {
  background: #dc2626;
}

.toast.info {
  background: #2563eb;
}

.toast-exit {
  opacity: 0;
  transform: translateX(20px);
  transition: all 0.2s ease-in;
}

@keyframes toastIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ─── EMPTY STATE ─── */

.empty-state {
  text-align: center;
  padding: 60px 24px;
}

.empty-state-icon {
  font-size: 36px;
  color: var(--text-muted);
  margin-bottom: 12px;
}

.empty-state-icon svg {
  width: 36px;
  height: 36px;
}

.empty-state-text {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 4px;
}

.empty-state-sub {
  font-size: 13px;
  color: var(--text-muted);
}

/* ─── STAT GRID (Admin Dashboard) ─── */

.stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 12px;
  margin-bottom: 24px;
}

.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 18px;
}

.stat-label {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 6px;
}

.stat-value {
  font-size: 24px;
  font-weight: 800;
  color: var(--text-primary);
}

.stat-value.green {
  color: var(--green);
}

.stat-value.red {
  color: var(--red);
}

.stat-value.yellow {
  color: var(--yellow);
}

/* ─── ADMIN LAYOUT ─── */

.admin-layout {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 24px;
  min-height: 60vh;
}

.admin-sidebar {
  display: flex;
  flex-direction: column;
  gap: 2px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 8px;
  align-self: start;
  position: sticky;
  top: 80px;
}

.admin-nav-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border: none;
  background: none;
  border-radius: var(--radius);
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all var(--transition);
  font-family: inherit;
  text-align: left;
}

.admin-nav-item:hover {
  background: var(--bg-card-hover);
  color: var(--text-primary);
}

.admin-nav-item.active {
  background: var(--accent-light);
  color: var(--accent);
  font-weight: 600;
}

.admin-content {
  min-width: 0;
}

@media (max-width: 768px) {
  .admin-layout {
    grid-template-columns: 1fr;
  }

  .admin-sidebar {
    flex-direction: row;
    overflow-x: auto;
    position: static;
  }
}

/* ─── DIVIDER ─── */

.divider {
  height: 1px;
  background: var(--border);
  margin: 16px 0;
}

/* ─── LINK ─── */

.link {
  color: var(--accent);
  cursor: pointer;
  font-weight: 500;
  transition: color var(--transition);
}

.link:hover {
  color: var(--accent-hover);
  text-decoration: underline;
}

/* ─── UTILITY CLASSES ─── */

.flex {
  display: flex;
}

.items-center {
  align-items: center;
}

.justify-between {
  justify-content: space-between;
}

.gap-4 { gap: 4px; }
.gap-8 { gap: 8px; }
.gap-12 { gap: 12px; }
.gap-16 { gap: 16px; }

.mt-4 { margin-top: 4px; }
.mt-8 { margin-top: 8px; }
.mt-12 { margin-top: 12px; }
.mt-16 { margin-top: 16px; }
.mt-20 { margin-top: 20px; }
.mb-8 { margin-bottom: 8px; }
.mb-12 { margin-bottom: 12px; }
.mb-16 { margin-bottom: 16px; }
.mb-20 { margin-bottom: 20px; }

.text-center { text-align: center; }
.text-sm { font-size: 13px; }
.text-xs { font-size: 12px; }
.text-secondary { color: var(--text-secondary); }
.text-muted { color: var(--text-muted); }
.text-green { color: var(--green); }
.text-red { color: var(--red); }
.font-mono { font-family: 'SF Mono', 'Fira Code', monospace; }

.hidden { display: none !important; }

/* ─── RESPONSIVE ─── */

@media (max-width: 900px) {
  .header-inner {
    padding: 0 16px;
    gap: 8px;
  }

  .nav-tabs {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  .nav-tab {
    padding: 8px 10px;
    font-size: 12px;
  }

  .header-lang {
    display: none;
  }

  .main {
    padding: 16px;
  }

  .filter-grid {
    grid-template-columns: 1fr 1fr;
  }

  .search-bar {
    min-width: 0;
    flex: 1;
  }
}

@media (max-width: 640px) {
  .header-inner {
    flex-wrap: wrap;
    height: auto;
    padding: 8px 16px;
  }

  .nav-tabs {
    order: 3;
    width: 100%;
    overflow-x: auto;
    padding-bottom: 4px;
  }

  .page-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .filter-grid {
    grid-template-columns: 1fr;
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .crypto-selector {
    grid-template-columns: 1fr;
  }

  .stat-grid {
    grid-template-columns: 1fr 1fr;
  }

  .bases-grid {
    grid-template-columns: 1fr;
  }

  .product-grid {
    grid-template-columns: 1fr;
  }

  .level-badge {
    display: none;
  }
}
