/* ============================================
   LUPIN CLUB UNIFIED THEME
   Modern CSS with Variables - Edit to customize
   ============================================ */

/* ============================================
   THEME VARIABLES - Edit these to change theme
   ============================================ */
:root {
  /* Primary Colors - Gold */
  --primary: #d4af37;
  --primary-dark: #b8962e;
  --primary-light: #e8cc7a;
  --secondary: #10b981;
  --secondary-dark: #059669;
  
  /* Status Colors */
  --success: #22c55e;
  --danger: #ef4444;
  --warning: #f59e0b;
  --info: #3b82f6;
  
  /* Background Colors - True Black */
  --bg-primary: #0a0a0a;
  --bg-secondary: #161616;
  --bg-card: #1f1f1f;
  --bg-hover: #2a2a2a;
  --bg-input: #141414;
  
  /* Text Colors */
  --text-primary: #f8fafc;
  --text-secondary: #cbd5e1;
  --text-muted: #94a3b8;
  --text-dark: #1e293b;
  
  /* Border Colors */
  --border-color: #2e2e2e;
  --border-light: #3d3d3d;
  
  /* Border Radius */
  --radius-sm: 0.25rem;
  --radius: 0.5rem;
  --radius-lg: 0.75rem;
  --radius-xl: 1rem;
  
  /* Shadows */
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.3);
  --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.3), 0 2px 4px -2px rgba(0, 0, 0, 0.3);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.4), 0 4px 6px -4px rgba(0, 0, 0, 0.4);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.5), 0 8px 10px -6px rgba(0, 0, 0, 0.5);
  
  /* Spacing */
  --space-xs: 0.25rem;
  --space-sm: 0.5rem;
  --space: 1rem;
  --space-lg: 1.5rem;
  --space-xl: 2rem;
  --space-2xl: 3rem;
  
  /* Typography */
  --font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-size-xs: 0.75rem;
  --font-size-sm: 0.875rem;
  --font-size: 1rem;
  --font-size-lg: 1.125rem;
  --font-size-xl: 1.25rem;
  --font-size-2xl: 1.5rem;
  --font-size-3xl: 1.875rem;
  
  /* Transitions */
  --transition: all 0.2s ease;
  --transition-slow: all 0.3s ease;
}

/* ============================================
   BASE STYLES
   ============================================ */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-family);
  font-size: var(--font-size);
  line-height: 1.6;
  color: var(--text-primary);
  background: var(--bg-primary);
  min-height: 100vh;
  overflow-x: hidden;
}

/* ============================================
   SCROLLBAR
   ============================================ */
::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

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

::-webkit-scrollbar-thumb {
  background: var(--primary);
  border-radius: var(--radius);
}

::-webkit-scrollbar-thumb:hover {
  background: var(--primary-light);
}

/* ============================================
   LAYOUT
   ============================================ */
.container {
  width: 100%;
  max-width: 1680px;
  margin: 0 auto;
  padding: 0 var(--space);
}

.container-fluid {
  width: 100%;
  padding: 0 var(--space);
}

.row {
  display: flex;
  flex-wrap: wrap;
  margin: 0 calc(var(--space) * -1);
}

.col {
  flex: 1;
  padding: 0 var(--space);
}

/* Grid Columns */
.col-1 { flex: 0 0 8.333%; }
.col-2 { flex: 0 0 16.666%; }
.col-3 { flex: 0 0 25%; }
.col-4 { flex: 0 0 33.333%; }
.col-5 { flex: 0 0 41.666%; }
.col-6 { flex: 0 0 50%; }
.col-7 { flex: 0 0 58.333%; }
.col-8 { flex: 0 0 66.666%; }
.col-9 { flex: 0 0 75%; }
.col-10 { flex: 0 0 83.333%; }
.col-11 { flex: 0 0 91.666%; }
.col-12 { flex: 0 0 100%; }

/* ============================================
   HEADER & NAVIGATION
   ============================================ */
.header {
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-color);
  padding: var(--space) 0;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: var(--shadow);
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--space);
}

.logo {
  font-size: var(--font-size-2xl);
  font-weight: 700;
  color: var(--primary);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.logo:hover {
  color: var(--primary-light);
}

.nav {
  display: flex;
  gap: var(--space-sm);
  list-style: none;
}

.nav-link {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
  padding: var(--space-sm) var(--space);
  color: var(--text-secondary);
  text-decoration: none;
  border-radius: var(--radius);
  transition: var(--transition);
  font-weight: 500;
}

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

.nav-link.active {
  background: var(--primary);
  color: white;
}

/* User Info Bar */
.user-bar {
  display: flex;
  align-items: center;
  gap: var(--space);
  padding: var(--space-sm) var(--space);
  background: var(--bg-card);
  border-radius: var(--radius);
  font-size: var(--font-size-sm);
}

.user-bar-item {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
}

.user-bar-label {
  color: var(--text-muted);
}

.user-bar-value {
  color: var(--text-primary);
  font-weight: 600;
}

/* ============================================
   CARDS
   ============================================ */
.card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  padding: var(--space-lg);
  margin-bottom: var(--space);
  border: 1px solid var(--border-color);
  transition: var(--transition);
}

.card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-2px);
}

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

.card-title {
  font-size: var(--font-size-xl);
  font-weight: 600;
  color: var(--text-primary);
}

.card-body {
  color: var(--text-secondary);
}

/* ============================================
   BUTTONS
   ============================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-xs);
  padding: var(--space-sm) var(--space);
  font-size: var(--font-size-sm);
  font-weight: 500;
  border: none;
  border-radius: var(--radius);
  cursor: pointer;
  transition: var(--transition);
  text-decoration: none;
  white-space: nowrap;
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn-primary {
  background: var(--primary);
  color: white;
}

.btn-primary:hover:not(:disabled) {
  background: var(--primary-dark);
  transform: translateY(-1px);
  box-shadow: var(--shadow);
}

.btn-secondary {
  background: var(--secondary);
  color: white;
}

.btn-secondary:hover:not(:disabled) {
  background: var(--secondary-dark);
}

.btn-success {
  background: var(--success);
  color: white;
}

.btn-danger {
  background: var(--danger);
  color: white;
}

.btn-warning {
  background: var(--warning);
  color: var(--text-dark);
}

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

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

.btn-sm {
  padding: var(--space-xs) var(--space-sm);
  font-size: var(--font-size-xs);
}

.btn-lg {
  padding: var(--space) var(--space-lg);
  font-size: var(--font-size-lg);
}

.btn-block {
  width: 100%;
}

/* ============================================
   FORMS
   ============================================ */
.form-group {
  margin-bottom: var(--space);
}

.form-label {
  display: block;
  margin-bottom: var(--space-xs);
  font-weight: 500;
  color: var(--text-primary);
}

.form-control {
  width: 100%;
  padding: var(--space-sm) var(--space);
  font-size: var(--font-size);
  font-family: inherit;
  color: var(--text-primary);
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  transition: var(--transition);
}

.form-control:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.2);
}

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

textarea.form-control {
  min-height: 100px;
  resize: vertical;
}

select.form-control {
  cursor: pointer;
}

/* Form Check */
.form-check {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  margin-bottom: var(--space-sm);
}

.form-check-input {
  width: 18px;
  height: 18px;
  cursor: pointer;
}

/* ============================================
   TABLES
   ============================================ */
.table-container {
  overflow-x: auto;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-color);
}

.table {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--font-size-sm);
}

.table th,
.table td {
  padding: var(--space);
  text-align: left;
  border-bottom: 1px solid var(--border-color);
}

.table th {
  background: var(--bg-secondary);
  font-weight: 600;
  color: var(--text-primary);
  white-space: nowrap;
}

.table td {
  color: var(--text-secondary);
}

.table tbody tr {
  transition: var(--transition);
}

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

/* ============================================
   ALERTS
   ============================================ */
.alert {
  padding: var(--space);
  border-radius: var(--radius);
  margin-bottom: var(--space);
  border: 1px solid transparent;
}

.alert-success {
  background: rgba(34, 197, 94, 0.1);
  border-color: var(--success);
  color: var(--success);
}

.alert-danger {
  background: rgba(239, 68, 68, 0.1);
  border-color: var(--danger);
  color: var(--danger);
}

.alert-warning {
  background: rgba(245, 158, 11, 0.1);
  border-color: var(--warning);
  color: var(--warning);
}

.alert-info {
  background: rgba(59, 130, 246, 0.1);
  border-color: var(--info);
  color: var(--info);
}

/* ============================================
   BADGES
   ============================================ */
.badge {
  display: inline-flex;
  align-items: center;
  padding: var(--space-xs) var(--space-sm);
  font-size: var(--font-size-xs);
  font-weight: 600;
  border-radius: var(--radius-sm);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.badge-primary {
  background: var(--primary);
  color: white;
}

.badge-success {
  background: var(--success);
  color: white;
}

.badge-danger {
  background: var(--danger);
  color: white;
}

.badge-warning {
  background: var(--warning);
  color: var(--text-dark);
}

/* ============================================
   MODALS
   ============================================ */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.8);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: var(--space);
}

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

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

.modal-title {
  font-size: var(--font-size-xl);
  font-weight: 600;
}

.modal-close {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: var(--font-size-2xl);
  cursor: pointer;
  transition: var(--transition);
}

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

.modal-body {
  padding: var(--space-lg);
}

.modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: var(--space-sm);
  padding: var(--space-lg);
  border-top: 1px solid var(--border-color);
}

/* ============================================
   LOADER
   ============================================ */
.loader {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--bg-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
}

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

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

/* ============================================
   UTILITIES
   ============================================ */

/* Display */
.d-none { display: none; }
.d-block { display: block; }
.d-flex { display: flex; }
.d-grid { display: grid; }
.d-inline { display: inline; }
.d-inline-block { display: inline-block; }
.d-inline-flex { display: inline-flex; }

/* Flex */
.flex-row { flex-direction: row; }
.flex-column { flex-direction: column; }
.flex-wrap { flex-wrap: wrap; }
.justify-start { justify-content: flex-start; }
.justify-end { justify-content: flex-end; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.justify-around { justify-content: space-around; }
.align-start { align-items: flex-start; }
.align-end { align-items: flex-end; }
.align-center { align-items: center; }
.align-baseline { align-items: baseline; }
.align-stretch { align-items: stretch; }

/* Gap */
.gap-0 { gap: 0; }
.gap-1 { gap: var(--space-xs); }
.gap-2 { gap: var(--space-sm); }
.gap-3 { gap: var(--space); }
.gap-4 { gap: var(--space-lg); }
.gap-5 { gap: var(--space-xl); }

/* Margin */
.m-0 { margin: 0; }
.m-1 { margin: var(--space-xs); }
.m-2 { margin: var(--space-sm); }
.m-3 { margin: var(--space); }
.m-4 { margin: var(--space-lg); }
.m-5 { margin: var(--space-xl); }
.m-auto { margin: auto; }

.mt-0 { margin-top: 0; }
.mt-1 { margin-top: var(--space-xs); }
.mt-2 { margin-top: var(--space-sm); }
.mt-3 { margin-top: var(--space); }
.mt-4 { margin-top: var(--space-lg); }
.mt-5 { margin-top: var(--space-xl); }

.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: var(--space-xs); }
.mb-2 { margin-bottom: var(--space-sm); }
.mb-3 { margin-bottom: var(--space); }
.mb-4 { margin-bottom: var(--space-lg); }
.mb-5 { margin-bottom: var(--space-xl); }

.ml-0 { margin-left: 0; }
.ml-1 { margin-left: var(--space-xs); }
.ml-2 { margin-left: var(--space-sm); }
.ml-3 { margin-left: var(--space); }
.ml-4 { margin-left: var(--space-lg); }
.ml-5 { margin-left: var(--space-xl); }

.mr-0 { margin-right: 0; }
.mr-1 { margin-right: var(--space-xs); }
.mr-2 { margin-right: var(--space-sm); }
.mr-3 { margin-right: var(--space); }
.mr-4 { margin-right: var(--space-lg); }
.mr-5 { margin-right: var(--space-xl); }

/* Padding */
.p-0 { padding: 0; }
.p-1 { padding: var(--space-xs); }
.p-2 { padding: var(--space-sm); }
.p-3 { padding: var(--space); }
.p-4 { padding: var(--space-lg); }
.p-5 { padding: var(--space-xl); }

.pt-0 { padding-top: 0; }
.pt-1 { padding-top: var(--space-xs); }
.pt-2 { padding-top: var(--space-sm); }
.pt-3 { padding-top: var(--space); }
.pt-4 { padding-top: var(--space-lg); }
.pt-5 { padding-top: var(--space-xl); }

.pb-0 { padding-bottom: 0; }
.pb-1 { padding-bottom: var(--space-xs); }
.pb-2 { padding-bottom: var(--space-sm); }
.pb-3 { padding-bottom: var(--space); }
.pb-4 { padding-bottom: var(--space-lg); }
.pb-5 { padding-bottom: var(--space-xl); }

/* Text */
.text-left { text-align: left; }
.text-center { text-align: center; }
.text-right { text-align: right; }
.text-justify { text-align: justify; }

.text-xs { font-size: var(--font-size-xs); }
.text-sm { font-size: var(--font-size-sm); }
.text-base { font-size: var(--font-size); }
.text-lg { font-size: var(--font-size-lg); }
.text-xl { font-size: var(--font-size-xl); }
.text-2xl { font-size: var(--font-size-2xl); }
.text-3xl { font-size: var(--font-size-3xl); }

.text-primary { color: var(--primary); }
.text-secondary { color: var(--text-secondary); }
.text-muted { color: var(--text-muted); }
.text-success { color: var(--success); }
.text-danger { color: var(--danger); }
.text-warning { color: var(--warning); }
.text-white { color: white; }

.font-light { font-weight: 300; }
.font-normal { font-weight: 400; }
.font-medium { font-weight: 500; }
.font-semibold { font-weight: 600; }
.font-bold { font-weight: 700; }

.uppercase { text-transform: uppercase; }
.lowercase { text-transform: lowercase; }
.capitalize { text-transform: capitalize; }

/* Background */
.bg-primary { background: var(--primary); }
.bg-secondary { background: var(--bg-secondary); }
.bg-card { background: var(--bg-card); }
.bg-success { background: var(--success); }
.bg-danger { background: var(--danger); }
.bg-warning { background: var(--warning); }

/* Border */
.border { border: 1px solid var(--border-color); }
.border-0 { border: none; }
.border-top { border-top: 1px solid var(--border-color); }
.border-bottom { border-bottom: 1px solid var(--border-color); }
.border-left { border-left: 1px solid var(--border-color); }
.border-right { border-right: 1px solid var(--border-color); }

.rounded { border-radius: var(--radius); }
.rounded-sm { border-radius: var(--radius-sm); }
.rounded-lg { border-radius: var(--radius-lg); }
.rounded-xl { border-radius: var(--radius-xl); }
.rounded-full { border-radius: 9999px; }

/* Shadow */
.shadow-sm { box-shadow: var(--shadow-sm); }
.shadow { box-shadow: var(--shadow); }
.shadow-lg { box-shadow: var(--shadow-lg); }
.shadow-xl { box-shadow: var(--shadow-xl); }
.shadow-none { box-shadow: none; }

/* Width */
.w-full { width: 100%; }
.w-auto { width: auto; }
.w-1\/2 { width: 50%; }
.w-1\/3 { width: 33.333%; }
.w-2\/3 { width: 66.666%; }
.w-1\/4 { width: 25%; }
.w-3\/4 { width: 75%; }

/* Cursor */
.cursor-pointer { cursor: pointer; }
.cursor-default { cursor: default; }
.cursor-not-allowed { cursor: not-allowed; }

/* Overflow */
.overflow-hidden { overflow: hidden; }
.overflow-auto { overflow: auto; }
.overflow-scroll { overflow: scroll; }
.overflow-x-auto { overflow-x: auto; }
.overflow-y-auto { overflow-y: auto; }

/* Position */
.relative { position: relative; }
.absolute { position: absolute; }
.fixed { position: fixed; }
.sticky { position: sticky; }

/* Z-Index */
.z-0 { z-index: 0; }
.z-10 { z-index: 10; }
.z-20 { z-index: 20; }
.z-30 { z-index: 30; }
.z-40 { z-index: 40; }
.z-50 { z-index: 50; }

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 768px) {
  .header-content {
    flex-direction: column;
    gap: var(--space-sm);
  }
  
  .nav {
    flex-wrap: wrap;
    justify-content: center;
  }
  
  .user-bar {
    flex-wrap: wrap;
    justify-content: center;
  }
  
  .col-1, .col-2, .col-3, .col-4, .col-5, .col-6,
  .col-7, .col-8, .col-9, .col-10, .col-11, .col-12 {
    flex: 0 0 100%;
  }
  
  .card {
    padding: var(--space);
  }
  
  .table {
    font-size: var(--font-size-xs);
  }
  
  .table th,
  .table td {
    padding: var(--space-sm);
  }
}

@media (max-width: 480px) {
  .btn {
    width: 100%;
    justify-content: center;
  }
  
  .modal {
    margin: var(--space);
    max-width: calc(100% - 2 * var(--space));
  }
}

/* ============================================
   ANIMATIONS
   ============================================ */
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

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

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

.animate-fadeIn {
  animation: fadeIn 0.3s ease;
}

.animate-slideIn {
  animation: slideIn 0.3s ease;
}

.animate-pulse {
  animation: pulse 2s ease infinite;
}

/* ============================================
   PRINT
   ============================================ */
@media print {
  .header,
  .nav,
  .btn,
  .user-bar {
    display: none !important;
  }
  
  .card {
    box-shadow: none;
    border: 1px solid #ddd;
  }
  
  body {
    background: white;
    color: black;
  }
}

/* ============================================
   BOOTSTRAP 3.x COMPATIBILITY LAYER
   For login page and legacy components
   ============================================ */

/* Sign Wrapper */
.signwrapper {
  background: var(--bg-primary);
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space);
}

.sign-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.7);
  z-index: 1;
}

.signpanel {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url('../images/img3.jpg') no-repeat center center;
  background-size: cover;
  opacity: 0.3;
  z-index: 0;
}

/* Panel */
.signwrapper .panel {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border-color);
  position: relative;
  z-index: 2;
  max-width: 450px;
  width: 100%;
  margin: 0 auto;
}

.signwrapper .panel.signin {
  padding: 0;
}

.signwrapper .panel-body {
  padding: var(--space-xl);
}

.signwrapper .panel-heading {
  padding: var(--space-lg) var(--space-xl);
  border-bottom: 1px solid var(--border-color);
  margin-bottom: var(--space);
}

.signwrapper .panel-title {
  font-size: var(--font-size-2xl);
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
  text-align: center;
}

/* Form Group */
.form-group {
  margin-bottom: var(--space);
}

.form-group.mb10 { margin-bottom: 10px; }
.form-group.mb15 { margin-bottom: 15px; }
.form-group.mb20 { margin-bottom: 20px; }
.form-group.nomargin { margin-bottom: 0; }

/* Input Group */
.input-group {
  display: flex;
  width: 100%;
}

.input-group-addon {
  display: flex;
  align-items: center;
  padding: var(--space-sm) var(--space);
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-right: none;
  border-radius: var(--radius) 0 0 var(--radius);
  color: var(--text-muted);
}

.input-group .form-control {
  border-radius: 0 var(--radius) var(--radius) 0;
  border-left: none;
}

.input-group .form-control:focus {
  border-left: none;
}

/* Glyphicons */
.glyphicon {
  display: inline-block;
  font-family: 'Glyphicons Halflings';
  font-style: normal;
  font-weight: 400;
  line-height: 1;
  -webkit-font-smoothing: antialiased;
}

.glyphicon-user::before { content: "👤"; }
.glyphicon-lock::before { content: "🔒"; }
.glyphicon-home::before { content: "🏠"; }
.glyphicon-envelope::before { content: "✉️"; }
.glyphicon-sign-out::before { content: "🚪"; }
.glyphicon-line-chart::before { content: "📈"; }

/* Buttons */
.btn-quirk {
  border-radius: var(--radius);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: var(--space) var(--space-lg);
  transition: var(--transition);
}

.btn-block {
  display: block;
  width: 100%;
}

.btn-stroke {
  background: transparent;
  border: 2px solid;
}

.btn-stroke-thin {
  border-width: 1px;
}

.btn-stroke.btn-danger {
  border-color: var(--danger);
  color: var(--danger);
}

.btn-stroke.btn-danger:hover {
  background: var(--danger);
  color: white;
}

/* Alerts */
.alert {
  padding: var(--space);
  border-radius: var(--radius);
  margin-bottom: var(--space);
  border: 1px solid transparent;
}

.alert-dismissable {
  padding-right: calc(var(--space) + 20px);
  position: relative;
}

.alert-dismissable .close {
  position: absolute;
  top: 50%;
  right: var(--space);
  transform: translateY(-50%);
  background: none;
  border: none;
  color: inherit;
  font-size: 20px;
  cursor: pointer;
  opacity: 0.5;
}

.alert-dismissable .close:hover {
  opacity: 1;
}

.alert-danger {
  background: rgba(239, 68, 68, 0.1);
  border-color: var(--danger);
  color: var(--danger);
}

.alert-warning {
  background: rgba(245, 158, 11, 0.1);
  border-color: var(--warning);
  color: var(--warning);
}

.alert-info {
  background: rgba(59, 130, 246, 0.1);
  border-color: var(--info);
  color: var(--info);
}

.alert-success {
  background: rgba(34, 197, 94, 0.1);
  border-color: var(--success);
  color: var(--success);
}

.page-alert {
  margin: var(--space) var(--space-xl) 0;
}

/* Text Colors */
.text-danger { color: var(--danger); }
.text-warning { color: var(--warning); }
.text-info { color: var(--info); }
.text-success { color: var(--success); }
.text-muted { color: var(--text-muted); }

/* Forgot Link */
.forgot {
  display: block;
  text-align: center;
  color: var(--text-muted);
  font-size: var(--font-size-sm);
  margin: var(--space) 0;
  text-decoration: none;
}

.forgot:hover {
  color: var(--primary);
}

/* CAPTCHA */
.CAPTCHA {
  margin: var(--space) 0;
}

.CAPTCHA_input {
  margin-top: var(--space);
}

/* Signup Section */
.signup {
  display: none;
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  max-width: 900px;
  width: 100%;
  margin: var(--space) auto;
  position: relative;
  z-index: 2;
}

.signup .row {
  display: flex;
  margin: 0;
}

.signup .col-sm-5 {
  flex: 0 0 41.666%;
  padding: 0;
}

.signup .col-sm-7 {
  flex: 0 0 58.333%;
  padding: 0;
}

.sign-sidebar {
  padding: var(--space-xl);
  background: var(--bg-secondary);
  height: 100%;
  border-radius: 0 var(--radius-lg) var(--radius-lg) 0;
}

.signtitle {
  font-size: var(--font-size-2xl);
  color: var(--text-primary);
  margin-bottom: var(--space);
}

.reason {
  color: var(--primary);
  font-size: var(--font-size-lg);
  margin-top: var(--space-lg);
  margin-bottom: var(--space-sm);
}

.sign-sidebar p {
  color: var(--text-secondary);
  line-height: 1.6;
}

/* Confirm Message */
.confirmMessage {
  display: block;
  margin-top: var(--space-xs);
  font-size: var(--font-size-sm);
}

/* SSL Badge */
#ssl {
  text-align: center;
  margin-top: var(--space-lg);
  padding-top: var(--space-lg);
  border-top: 1px solid var(--border-color);
  color: var(--text-muted);
  font-size: var(--font-size-sm);
}

#ssl img {
  vertical-align: middle;
  margin-right: var(--space-xs);
}

/* Logo */
.signwrapper .panel-body img[src*="logo"] {
  max-width: 200px;
  height: auto;
  margin: 0 auto var(--space);
  display: block;
}

/* Responsive */
@media (max-width: 768px) {
  .signwrapper .panel {
    margin: var(--space);
    max-width: calc(100% - 2 * var(--space));
  }
  
  .panel-body {
    padding: var(--space);
  }
  
  .signup .row {
    flex-direction: column;
  }
  
  .signup .col-sm-5,
  .signup .col-sm-7 {
    flex: 0 0 100%;
  }
  
  .sign-sidebar {
    border-radius: 0 0 var(--radius-lg) var(--radius-lg);
  }
}

/* ============================================
   LEGACY LAYOUT BRIDGE
   Styles the rt-* header & gf-menu markup
   ============================================ */

/* Header band */
header#rt-top-surround {
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-color);
  padding: var(--space) 0;
}

#rt-header .rt-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--space);
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 var(--space);
}

.left_block .paragrafi {
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.7;
  margin: 0;
}
.left_block .paragrafi strong { color: var(--text-primary); }

.right_block {
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.7;
  text-align: right;
}
.right_block strong { color: var(--text-primary); }

/* Main navigation */
.menu-block {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 var(--space);
}

ul.gf-menu {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-sm);
  list-style: none;
  margin: var(--space) auto;
  padding: var(--space-sm);
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  max-width: 1400px;
  box-shadow: var(--shadow);
}

ul.gf-menu li {
  margin: 0;
  padding: 0;
  list-style: none;
}

ul.gf-menu li:not(.btn) a.item {
  display: inline-block;
  padding: var(--space-sm) var(--space);
  color: var(--text-secondary);
  text-decoration: none;
  border-radius: var(--radius);
  font-weight: 500;
  transition: background 0.15s ease, color 0.15s ease;
}

ul.gf-menu li:not(.btn) a.item:hover {
  background: var(--primary);
  color: #fff;
  text-decoration: none;
}

ul.gf-menu li.btn a.item {
  color: #fff;
  text-decoration: none;
}

/* ============================================
   LEGACY BRIDGE — round 2 polish
   ============================================ */

/* User info card */
.left_block .paragrafi {
  padding: var(--space-sm) var(--space);
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
}

/* Right header block: time + logout in a tidy row */
.right_block {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: var(--space-sm) var(--space);
  text-align: right;
}
.right_block > div {
  margin-bottom: 0 !important;
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

/* Readable links on dark background */
a { color: var(--primary-light); }
a:hover { color: var(--primary); }
ul.gf-menu li a.item:hover { color: #fff; }
ul.gf-menu li.btn a.item, ul.gf-menu li.btn a.item:hover { color: #fff; }

/* Home icon without the glyphicons font */
.glyphicon-home::before { content: "\2302"; }

/* Countdown/header text: natural inline flow, buttons stay in a row */
.right_block { display: block; text-align: right; }
.right_block > div { display: flex; justify-content: flex-end; align-items: center; gap: var(--space-sm); margin-top: var(--space-xs); }

/* ============================================
   SHOP COMPONENTS — Phase 1
   Product grids, price chips, filter bars,
   balance widget, pagination, empty states.
   Tokens only — recolors with :root.
   ============================================ */

/* ---------- Shop layout wrapper ---------- */
.shop-wrap {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 var(--space) var(--space-xl);
}

.shop-page-title {
  font-size: var(--font-size-2xl);
  font-weight: 700;
  color: var(--text-primary);
  margin: var(--space-lg) 0 var(--space-sm);
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.shop-page-sub {
  color: var(--text-muted);
  font-size: var(--font-size-sm);
  margin-bottom: var(--space-lg);
}

/* ---------- Stat row (balance, counts) ---------- */
.stat-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: var(--space);
  margin-bottom: var(--space-lg);
}

.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: var(--space) var(--space-lg);
  box-shadow: var(--shadow-sm);
}

.stat-card .stat-label {
  color: var(--text-muted);
  font-size: var(--font-size-xs);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.stat-card .stat-value {
  color: var(--text-primary);
  font-size: var(--font-size-2xl);
  font-weight: 700;
  margin-top: var(--space-xs);
}

.stat-card .stat-value.accent { color: var(--secondary); }

/* ---------- Filter bar ---------- */
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-sm);
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: var(--space-sm) var(--space);
  margin-bottom: var(--space-lg);
}

.filter-bar .filter-label {
  color: var(--text-muted);
  font-size: var(--font-size-sm);
  font-weight: 500;
}

.filter-bar select,
.filter-bar input[type="text"],
.filter-bar input[type="search"] {
  padding: var(--space-sm) var(--space);
  font-size: var(--font-size-sm);
  font-family: inherit;
  color: var(--text-primary);
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  transition: var(--transition);
}

.filter-bar select:focus,
.filter-bar input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.2);
}

/* ---------- Product grid ---------- */
.shop-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: var(--space);
}

.product-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  padding: var(--space-lg);
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
  transition: var(--transition);
}

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

.product-card .pc-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: var(--space-sm);
}

.product-card .pc-title {
  font-size: var(--font-size-lg);
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.3;
}

.product-card .pc-meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-xs) var(--space);
  color: var(--text-muted);
  font-size: var(--font-size-sm);
}

.product-card .pc-meta strong {
  color: var(--text-secondary);
  font-weight: 500;
}

.product-card .pc-desc {
  color: var(--text-secondary);
  font-size: var(--font-size-sm);
  line-height: 1.6;
  flex: 1;
}

.product-card .pc-foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--space-sm);
  padding-top: var(--space-sm);
  border-top: 1px solid var(--border-color);
}

/* ---------- Price chip ---------- */
.price-chip {
  display: inline-flex;
  align-items: baseline;
  gap: 2px;
  padding: var(--space-xs) var(--space-sm);
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid var(--secondary);
  color: var(--secondary);
  font-weight: 700;
  font-size: var(--font-size-lg);
  border-radius: var(--radius);
  white-space: nowrap;
}

.price-chip small {
  font-size: var(--font-size-xs);
  font-weight: 500;
}

/* ---------- Stock / status badges ---------- */
.badge-stock {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  padding: var(--space-xs) var(--space-sm);
  font-size: var(--font-size-xs);
  font-weight: 600;
  border-radius: var(--radius-sm);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.badge-stock::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: currentColor;
}

.badge-stock.in { background: rgba(34, 197, 94, 0.12); color: var(--success); }
.badge-stock.out { background: rgba(239, 68, 68, 0.12); color: var(--danger); }
.badge-stock.low { background: rgba(245, 158, 11, 0.12); color: var(--warning); }

/* ---------- Tag pills (type/country/bank) ---------- */
.tag {
  display: inline-block;
  padding: 2px var(--space-sm);
  font-size: var(--font-size-xs);
  font-weight: 500;
  color: var(--text-secondary);
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-full);
  white-space: nowrap;
}

/* ---------- Pagination ---------- */
.pagination {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-xs);
  justify-content: center;
  margin: var(--space-lg) 0;
  list-style: none;
  padding: 0;
}

.pagination a,
.pagination span,
.pagination li a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  padding: 0 var(--space-sm);
  color: var(--text-secondary);
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  text-decoration: none;
  font-size: var(--font-size-sm);
  transition: var(--transition);
}

.pagination a:hover {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

.pagination .active,
.pagination span.active {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

/* ---------- Empty state ---------- */
.empty-state {
  text-align: center;
  padding: var(--space-2xl) var(--space);
  color: var(--text-muted);
  background: var(--bg-secondary);
  border: 1px dashed var(--border-color);
  border-radius: var(--radius-lg);
}

.empty-state .empty-icon {
  font-size: 2.5rem;
  margin-bottom: var(--space);
  opacity: 0.6;
}

.empty-state .empty-title {
  font-size: var(--font-size-lg);
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: var(--space-xs);
}

/* ---------- Balance widget (header) ---------- */
.balance-widget {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-sm) var(--space);
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  font-size: var(--font-size-sm);
}

.balance-widget .bw-label { color: var(--text-muted); }
.balance-widget .bw-value { color: var(--secondary); font-weight: 700; }

/* ---------- News cards (home) ---------- */
.news-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: var(--space);
  margin-bottom: var(--space-lg);
}

.news-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.news-card:hover { box-shadow: var(--shadow); }

.news-card .news-date {
  color: var(--text-muted);
  font-size: var(--font-size-xs);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.news-card .news-title {
  font-size: var(--font-size-lg);
  font-weight: 600;
  color: var(--text-primary);
  margin: var(--space-xs) 0 var(--space-sm);
}

.news-card .news-body {
  color: var(--text-secondary);
  font-size: var(--font-size-sm);
  line-height: 1.6;
}

/* ---------- Legacy table skin (classless tables in shop content) ---------- */
.shop-wrap table {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--font-size-sm);
}

.shop-wrap table th,
.shop-wrap table td {
  padding: var(--space-sm) var(--space);
  text-align: left;
  border-bottom: 1px solid var(--border-color);
  color: var(--text-secondary);
}

.shop-wrap table th {
  background: var(--bg-secondary);
  color: var(--text-primary);
  font-weight: 600;
}

.shop-wrap table tr:hover td { background: var(--bg-hover); }

/* ---------- Section divider ---------- */
.shop-section { margin-bottom: var(--space-xl); }

.shop-section > .section-title {
  font-size: var(--font-size-xl);
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: var(--space);
  padding-bottom: var(--space-sm);
  border-bottom: 1px solid var(--border-color);
}

/* ---------- Responsive ---------- */
@media (max-width: 768px) {
  .shop-grid { grid-template-columns: 1fr; }
  .stat-row { grid-template-columns: repeat(2, 1fr); }
  .filter-bar { flex-direction: column; align-items: stretch; }
  .filter-bar select, .filter-bar input { width: 100%; }
}

/* ============================================
   SHOP SHELL — Phase 2
   Header, alert banner, footer frame
   ============================================ */

/* Slim security banner (replaces the 24px red wall) */
.shop-alert-banner {
  background: #7f1d1d;
  color: #fecaca;
  font-size: var(--font-size-sm);
  text-align: center;
  padding: var(--space-sm) var(--space);
  line-height: 1.5;
}
.shop-alert-banner strong { font-weight: 600; }
.shop-alert-banner strong + strong { display: block; margin-top: 2px; }

/* Header frame */
.shop-header {
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-color);
  box-shadow: var(--shadow);
  position: sticky;
  top: 0;
  z-index: 100;
}

.shop-header-inner {
  max-width: 1400px;
  margin: 0 auto;
  padding: var(--space) var(--space);
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-sm) var(--space-lg);
}

/* Wordmark */
.shop-logo {
  font-size: var(--font-size-2xl);
  font-weight: 800;
  letter-spacing: 0.04em;
  color: var(--text-primary);
  text-decoration: none;
}
.shop-logo span { color: var(--primary); }
.shop-logo:hover { color: var(--primary-light); text-decoration: none; }

/* User chip */
.shop-userchip {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-xs) var(--space-sm);
  padding: var(--space-sm) var(--space);
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  font-size: var(--font-size-sm);
  color: var(--text-secondary);
}
.shop-userchip strong { color: var(--text-primary); }
.shop-userchip .sep { color: var(--text-muted); }
.shop-userchip .balance { color: var(--secondary); font-weight: 700; }
.shop-userchip .pending-link { color: var(--danger); font-weight: 600; }

/* Right side: clock, countdown, actions */
.shop-head-right {
  margin-left: auto;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-sm) var(--space);
  font-size: var(--font-size-sm);
  color: var(--text-secondary);
}
.shop-head-right strong { color: var(--text-primary); }
.shop-head-actions { display: flex; gap: var(--space-sm); }

/* Nav row */
.shop-nav {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 var(--space) var(--space-sm);
}
.shop-nav ul.gf-menu { margin: 0; }

/* Footer */
.shop-footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-color);
  margin-top: var(--space-2xl);
}

.shop-footer-inner {
  max-width: 1400px;
  margin: 0 auto;
  padding: var(--space-xl) var(--space);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: var(--space-lg);
}

.shop-footer-col h3 {
  font-size: var(--font-size);
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: var(--space-sm);
}

.shop-footer-col p {
  color: var(--text-secondary);
  font-size: var(--font-size-sm);
  margin-bottom: var(--space-xs);
}

.shop-copyright {
  border-top: 1px solid var(--border-color);
  text-align: center;
  padding: var(--space);
  color: var(--text-muted);
  font-size: var(--font-size-sm);
}

@media (max-width: 900px) {
  .shop-head-right { margin-left: 0; width: 100%; }
  .shop-header-inner { flex-direction: column; align-items: stretch; }
}

/* News date group heading spans full grid width */
.news-grid-date {
  grid-column: 1 / -1;
  font-size: var(--font-size-lg);
  font-weight: 700;
  color: var(--primary-light);
  margin-top: var(--space);
}
.news-grid-date:first-child { margin-top: 0; }

/* Breadcrumb */
.breadcrumb {
  list-style: none;
  display: flex;
  gap: var(--space-sm);
  padding: 0;
  margin: var(--space) 0 0;
  font-size: var(--font-size-sm);
  color: var(--text-muted);
}
.breadcrumb li.active { color: var(--text-secondary); }

/* ============================================
   DATATABLES SKIN — jQuery DataTables UI
   ============================================ */
.dataTables_wrapper { color: var(--text-secondary); font-size: var(--font-size-sm); }
.dataTables_wrapper .dataTables_length,
.dataTables_wrapper .dataTables_filter {
  margin-bottom: var(--space);
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
}
.dataTables_wrapper .dataTables_filter { float: right; }
.dataTables_wrapper .dataTables_length select,
.dataTables_wrapper .dataTables_filter input {
  padding: var(--space-xs) var(--space-sm);
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  color: var(--text-primary);
  font-family: inherit;
}
.dataTables_wrapper .dataTables_info { color: var(--text-muted); margin-top: var(--space); }
.dataTables_wrapper .dataTables_paginate {
  display: flex;
  gap: var(--space-xs);
  justify-content: flex-end;
  margin-top: var(--space);
}
.dataTables_wrapper .paginate_button {
  display: inline-flex;
  align-items: center;
  min-width: 32px;
  justify-content: center;
  height: 32px;
  padding: 0 var(--space-sm);
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  color: var(--text-secondary) !important;
  cursor: pointer;
  text-decoration: none;
}
.dataTables_wrapper .paginate_button:hover { background: var(--primary); color: #fff !important; border-color: var(--primary); }
.dataTables_wrapper .paginate_button.current,
.dataTables_wrapper .paginate_button.current:hover { background: var(--primary); color: #fff !important; border-color: var(--primary); }
.dataTables_wrapper .paginate_button.disabled { opacity: 0.4; pointer-events: none; }
.dataTables_wrapper .dataTables_processing {
  background: rgba(15, 23, 42, 0.85);
  color: var(--text-primary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  padding: var(--space) var(--space-lg);
}
table.dataTable thead th { border-bottom: 1px solid var(--border-color); }
table.dataTable tbody td { border-bottom: 1px solid var(--border-color); }
table.dataTable.stripe tbody tr.odd, table.dataTable tbody tr.even { background: transparent; }

/* ============================================
   CARDS PAGE — filter panel & buy bar
   ============================================ */
.filter-panel {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: var(--space);
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: var(--space);
  margin-bottom: var(--space);
}

.filter-item label {
  display: block;
  color: var(--text-muted);
  font-size: var(--font-size-xs);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: var(--space-xs);
}

.filter-item select,
.filter-item input[type="text"],
.filter-item textarea {
  width: 100%;
  padding: var(--space-sm) var(--space);
  font-size: var(--font-size-sm);
  font-family: inherit;
  color: var(--text-primary);
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  transition: var(--transition);
}

.filter-item select:focus,
.filter-item input:focus,
.filter-item textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.2);
}

.filter-item textarea { resize: vertical; min-height: 90px; }

.filter-actions {
  display: flex;
  gap: var(--space-sm);
  margin-bottom: var(--space);
}

.quick-filters {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-sm);
  margin-bottom: var(--space-lg);
}

.buy-all-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--space);
  margin-top: var(--space-lg);
  padding: var(--space);
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
}

.buy-all-bar p { color: var(--text-secondary); margin: 0; }

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

/* ============================================
   PURCHASED PAGE — tabs & report view
   ============================================ */
.tab-content > .tab-pane { display: none; }
.tab-content > .tab-pane.active { display: block; }

ul.nav-tabs {
  list-style: none;
  display: flex;
  justify-content: center;
  gap: var(--space-sm);
  padding: 0;
  margin: 0 0 var(--space-lg);
  border-bottom: 1px solid var(--border-color);
}

ul.nav-tabs a { text-decoration: none; }
ul.nav-tabs a button { opacity: 0.65; transition: var(--transition); }
ul.nav-tabs a.active button { opacity: 1; box-shadow: var(--shadow); }

.buttonat { margin-bottom: var(--space); }
.buttonat .btn { margin-right: var(--space-sm); margin-bottom: var(--space-sm); }

#datatable td[onClick], #carddatatable td span[onClick] { cursor: pointer; }
#datatable td[onClick]:hover, #carddatatable td span[onClick]:hover { color: var(--primary-light); }

/* ============================================
   SELLER PANEL — nav & shared
   ============================================ */
.seller-nav {
  width: 1100px;
  max-width: 94vw;
  position: relative;
  left: 50%;
  transform: translateX(-50%);
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: var(--space);
  margin-bottom: var(--space-lg);
}

.seller-nav-title {
  text-align: center;
  font-size: var(--font-size-xl);
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: var(--space);
}

.seller-pills {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-sm);
  padding: 0;
  margin: 0;
}

.seller-pills a {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  padding: var(--space-sm) var(--space);
  color: var(--text-secondary);
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  text-decoration: none;
  font-weight: 500;
  font-size: var(--font-size-sm);
  transition: var(--transition);
}

.seller-pills a:hover { background: var(--primary); color: #fff; border-color: var(--primary); }
.seller-pills li.accent a { background: var(--danger); color: #fff; border-color: var(--danger); }
.seller-pills li.accent a:hover { background: #dc2626; }
.seller-pills li.success a { background: var(--secondary); color: #fff; border-color: var(--secondary); }
.seller-pills li.success a:hover { background: var(--secondary-dark); }

.seller-extract {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-sm);
  margin-top: var(--space);
  padding-top: var(--space);
  border-top: 1px solid var(--border-color);
}

.seller-extract a {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  padding: var(--space-sm) var(--space);
  color: #fff;
  background: var(--danger);
  border-radius: var(--radius);
  text-decoration: none;
  font-size: var(--font-size-sm);
  font-weight: 500;
}
.seller-extract a:hover { background: #dc2626; }

/* ============================================
   SELLER STATISTICS — widget grid
   ============================================ */
#statistics .row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space);
  margin-bottom: var(--space);
}

#statistics .row > [class*="col-"] {
  flex: 1 1 200px;
  min-width: 0;
}

.widget-inline-box {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: var(--space) var(--space-lg);
  box-shadow: var(--shadow-sm);
  text-align: center;
  height: 100%;
}

.widget-inline-box h3 {
  color: var(--text-primary);
  font-size: var(--font-size-2xl);
  font-weight: 700;
  margin: 0;
}

.widget-inline-box h4 {
  color: var(--text-muted);
  font-size: var(--font-size-xs);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin: var(--space-xs) 0 0;
}

#statistics .buttonat h3,
#statistics h3.text-center {
  color: var(--text-primary);
}

/* Google Charts container */
#chart_div, .chart-container {
  background: #fff;
  border-radius: var(--radius-lg);
  padding: var(--space);
  margin-bottom: var(--space-lg);
}

/* ============================================
   SELLER PAGE — unified content width
   All seller pages share one 1100px column
   ============================================ */
.seller-page .content .container {
  width: 1100px !important;
  max-width: 94vw !important;
  margin-left: auto !important;
  margin-right: auto !important;
  float: none !important;
}

/* card-boxes fill the column naturally — never force fixed width on nested boxes */
.seller-page .card-box {
  width: 100% !important;
  max-width: 100% !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
  float: none !important;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: var(--space);
  margin-bottom: var(--space-lg);
  box-sizing: border-box;
}

/* Seller panels — full width, theme card (login panels stay scoped to .signwrapper) */
.seller-page .panel {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  margin-bottom: var(--space);
}
.seller-page .panel-heading {
  padding: var(--space) var(--space-lg);
  border-bottom: 1px solid var(--border-color);
}
.seller-page .panel-title {
  font-size: var(--font-size-xl);
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
  text-align: center;
}
.seller-page .panel-body { padding: var(--space-lg); }

/* Cap legacy columns inside seller pages — stops flex/min-content overflow */
.seller-page .row [class*="col-"] {
  max-width: 100% !important;
  box-sizing: border-box;
}

/* Neutralize grid gutters inside seller pages — legacy cols have no padding compensation */
.seller-page .row {
  margin-left: 0 !important;
  margin-right: 0 !important;
}

/* ============================================
   SELLER PAGES — FULL SCREEN, NO BOXES
   Everything spans the viewport; frames removed
   ============================================ */

/* full-bleed wrapper for seller pages */
.seller-page main.shop-wrap {
  max-width: 100%;
  padding: 0 var(--space);
}

/* nav panel: full width, no box frame */
.seller-nav {
  width: 100% !important;
  max-width: 100% !important;
  left: 0 !important;
  transform: none !important;
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  padding: var(--space) 0 !important;
  margin-bottom: var(--space) !important;
}

/* content column: full width */
.seller-page .content .container {
  width: 100% !important;
  max-width: 100% !important;
  padding: 0 !important;
}

/* card-box: content stays full width, frame removed */
.seller-page .card-box {
  width: 100% !important;
  max-width: 100% !important;
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  padding: 0 !important;
}

/* Flatten legacy grid inside seller pages — block layout, no shrink-wrap */
.seller-page .row {
  display: block !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
}

.seller-page [class*="col-"] {
  width: 100% !important;
  max-width: 100% !important;
  flex: none !important;
  float: none !important;
  display: block !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
}

/* …but keep the statistics widget grid as a real flex grid */
.seller-page #statistics .row {
  display: flex !important;
  flex-wrap: wrap !important;
  gap: var(--space) !important;
}

.seller-page #statistics .row > [class*="col-"] {
  flex: 1 1 0 !important;
  width: auto !important;
  min-width: 200px !important;
}

/* Profile rows */
.profile-rows { display: flex; flex-direction: column; gap: var(--space-sm); }
.profile-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: var(--space);
  padding-bottom: var(--space-sm);
  border-bottom: 1px solid var(--border-color);
}
.profile-row:last-child { border-bottom: none; }
.profile-row span { color: var(--text-muted); font-size: var(--font-size-sm); }
.profile-row strong { color: var(--text-primary); font-weight: 500; text-align: right; }
.profile-row strong.balance { color: var(--secondary); font-weight: 700; }

/* ============================================
   TICKET THREAD — support page panels
   ============================================ */
.ticket-wrap { width: 100%; }

main.shop-wrap .panel {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  margin-bottom: var(--space);
  box-shadow: var(--shadow-sm);
}

main.shop-wrap .panel-heading {
  padding: var(--space-sm) var(--space);
  border-bottom: 1px solid var(--border-color);
}

main.shop-wrap .panel-title {
  color: var(--text-primary);
  font-size: var(--font-size);
  font-weight: 600;
  margin: 0;
}

main.shop-wrap .panel-body { padding: var(--space); }

main.shop-wrap .panel-body pre {
  font-family: inherit;
  color: var(--text-secondary);
  margin: 0;
  background: none;
  border: none;
  padding: 0;
}

.ticket-meta {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: var(--space);
  margin-bottom: var(--space-lg);
}

.ticket-meta .grid-container {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  padding: var(--space);
  text-align: center;
  color: var(--text-secondary);
}

/* ============================================
   LOGIN PAGE — polish
   ============================================ */
.login-wordmark {
  font-size: 2.2rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  color: var(--text-primary);
}
.login-wordmark span { color: var(--primary); }

/* Captcha input full width */
.CAPTCHA_input {
  width: 100% !important;
  float: none !important;
  margin-top: var(--space-sm) !important;
}

/* Input group icons without the glyphicons font */
.signwrapper .glyphicon-user::before { content: "@"; }
.signwrapper .glyphicon-lock::before { content: "*"; }

.signwrapper .input-group-addon {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-right: none;
  border-radius: var(--radius) 0 0 var(--radius);
  padding: 0 var(--space-sm);
  display: flex;
  align-items: center;
}

.signwrapper .input-group { display: flex; }
.signwrapper .input-group .form-control { border-radius: 0 var(--radius) var(--radius) 0; }

/* SSL note */
#ssl { color: var(--text-secondary) !important; font-size: var(--font-size-sm); }

/* ============================================
   CARDS PAGE — button consistency (golden-black)
   ============================================ */

/* search / clear */
.filter-actions .searchbtn {
  background: var(--primary) !important;
  color: #111 !important;
  border: 1px solid var(--primary) !important;
  border-radius: var(--radius) !important;
  padding: var(--space-sm) var(--space-lg) !important;
  font-weight: 600 !important;
}
.filter-actions .searchbtn:hover { background: var(--primary-light) !important; }

.filter-actions .clear-all {
  background: transparent !important;
  color: var(--text-secondary) !important;
  border: 1px solid var(--border-color) !important;
  border-radius: var(--radius) !important;
  padding: var(--space-sm) var(--space-lg) !important;
}
.filter-actions .clear-all:hover { border-color: var(--primary) !important; color: var(--primary) !important; }

/* quick filters — one quiet chip family, gold on hover */
.quick-filters .btn,
.quick-filters .quick-filter-btn {
  background: var(--bg-card) !important;
  color: var(--text-secondary) !important;
  border: 1px solid var(--border-color) !important;
  border-radius: var(--radius) !important;
  padding: var(--space-sm) var(--space) !important;
  font-weight: 500 !important;
  text-shadow: none !important;
  box-shadow: none !important;
}
.quick-filters .btn:hover,
.quick-filters .quick-filter-btn:hover {
  border-color: var(--primary) !important;
  color: var(--primary) !important;
  background: var(--bg-card) !important;
}

/* buy all selected — gold, rounded, confident */
.buy-all-bar button,
.buy-all-bar .btn-success {
  background: var(--primary) !important;
  color: #111 !important;
  border: 1px solid var(--primary) !important;
  border-radius: var(--radius) !important;
  padding: var(--space-sm) var(--space-xl) !important;
  font-weight: 700 !important;
  font-size: var(--font-size) !important;
}
.buy-all-bar button:hover { background: var(--primary-light) !important; }

/* ============================================
   ALERT CLOSE BUTTON — the ugly X
   ============================================ */
.alert { position: relative; }
.alert .close,
.alert button.close {
  position: absolute;
  top: var(--space-sm);
  right: var(--space-sm);
  background: transparent;
  border: none;
  color: inherit;
  opacity: 0.6;
  font-size: 1.1rem;
  line-height: 1;
  cursor: pointer;
  padding: 2px 6px;
  border-radius: var(--radius-sm);
}
.alert .close:hover { opacity: 1; background: rgba(0,0,0,0.25); }

/* ============================================
   SWEETALERT MODALS — register success, welcome
   ============================================ */
.sweet-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.65);
  z-index: 1000;
}

.sweet-alert {
  position: fixed !important;
  top: 50% !important;
  left: 50% !important;
  transform: translate(-50%, -50%) !important;
  margin-top: 0 !important;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xl);
  padding: var(--space-xl);
  max-width: 480px;
  width: calc(100% - 2 * var(--space));
  z-index: 1001;
  text-align: center;
  color: var(--text-secondary);
}

.sweet-alert h2, .sweet-alert h4 { color: var(--text-primary); margin-top: 0; }
.sweet-alert p { color: var(--text-secondary); }

.sweet-alert .sa-icon.sa-success {
  width: 80px;
  height: 80px;
  border: 4px solid var(--success);
  border-radius: 50%;
  margin: 0 auto var(--space);
  position: relative;
}
.sweet-alert .sa-icon.sa-success .sa-line,
.sweet-alert .sa-icon.sa-success .sa-placeholder,
.sweet-alert .sa-icon.sa-success .sa-fix { display: none; }
.sweet-alert .sa-icon.sa-success::after {
  content: "\2713";
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.5rem;
  color: var(--success);
}

.sweet-alert .sa-icon.sa-warning {
  width: 80px;
  height: 80px;
  border: 4px solid var(--warning);
  border-radius: 50%;
  margin: 0 auto var(--space);
  position: relative;
}
.sweet-alert .sa-icon.sa-warning .sa-body,
.sweet-alert .sa-icon.sa-warning .sa-dot { display: none; }
.sweet-alert .sa-icon.sa-warning::after {
  content: "!";
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--warning);
}

.sweet-alert .sa-confirm-button-container button,
.sweet-alert button.confirm {
  background: var(--primary) !important;
  color: #111 !important;
  border: none !important;
  border-radius: var(--radius) !important;
  padding: var(--space-sm) var(--space-xl) !important;
  font-weight: 600 !important;
  cursor: pointer;
  box-shadow: none !important;
}

/* ============================================
   GLOBAL BUTTON SYSTEM — GOLD
   Every button: solid gold fill, dark text.
   Hover: inverts to gold outline.
   Outline variants invert to solid on hover.
   ============================================ */
button,
.btn,
input[type="submit"],
input[type="button"],
a.btn {
  background: var(--primary) !important;
  color: #111 !important;
  border: 1px solid var(--primary) !important;
  border-radius: var(--radius) !important;
  padding: var(--space-sm) var(--space) !important;
  font-weight: 600 !important;
  text-shadow: none !important;
  box-shadow: none !important;
  cursor: pointer;
  transition: var(--transition) !important;
}

button:hover,
.btn:hover,
input[type="submit"]:hover,
input[type="button"]:hover,
a.btn:hover {
  background: transparent !important;
  color: var(--primary) !important;
  border-color: var(--primary) !important;
}

/* outline variants rest inverted, fill on hover */
.btn-outline,
.btn-stroke,
[class*="btn-stroke"] {
  background: transparent !important;
  color: var(--primary) !important;
  border: 1px solid var(--primary) !important;
}

.btn-outline:hover,
.btn-stroke:hover,
[class*="btn-stroke"]:hover {
  background: var(--primary) !important;
  color: #111 !important;
}

/* Gold for the stubborn specific buttons too */
.filter-actions .clear-all,
.quick-filters .btn,
.quick-filters .quick-filter-btn {
  background: var(--primary) !important;
  color: #111 !important;
  border: 1px solid var(--primary) !important;
}

.filter-actions .clear-all:hover,
.quick-filters .btn:hover,
.quick-filters .quick-filter-btn:hover {
  background: transparent !important;
  color: var(--primary) !important;
  border-color: var(--primary) !important;
}

/* ============================================
   CART — badge, flash, page
   ============================================ */
.cart-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  margin-left: var(--space-xs);
  background: var(--primary);
  color: #111;
  font-size: var(--font-size-xs);
  font-weight: 700;
  border-radius: var(--radius-full);
}

.cart-flash {
  position: fixed;
  bottom: var(--space-xl);
  left: 50%;
  transform: translateX(-50%);
  background: var(--bg-card);
  border: 1px solid var(--primary);
  color: var(--primary);
  padding: var(--space-sm) var(--space-lg);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  z-index: 1002;
  font-weight: 600;
  transition: opacity 0.4s;
}

/* ============================================
   SELECT2 — golden-black skin
   ============================================ */
.select2-container { width: 100% !important; }

.select2-container--default .select2-selection--single {
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  height: auto;
  min-height: 38px;
  padding: var(--space-xs) var(--space-sm);
  color: var(--text-primary);
  transition: var(--transition);
}

.select2-container--default .select2-selection--single .select2-selection__rendered {
  color: var(--text-primary);
  line-height: 1.6;
  padding-left: 0;
}

.select2-container--default .select2-selection--single .select2-selection__arrow {
  height: 100%;
  top: 50%;
  transform: translateY(-50%);
}

.select2-container--default .select2-selection--single .select2-selection__arrow b {
  border-color: var(--text-muted) transparent transparent transparent;
}

.select2-container--default.select2-container--open .select2-selection--single {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.2);
}

.select2-dropdown {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  z-index: 1003;
}

.select2-container--default .select2-results__option {
  color: var(--text-secondary);
  padding: var(--space-sm) var(--space);
  font-size: var(--font-size-sm);
}

.select2-container--default .select2-results__option--highlighted.select2-results__option--selectable {
  background: var(--primary);
  color: #111;
}

.select2-container--default .select2-results__option--selected {
  background: var(--bg-hover);
  color: var(--primary);
}

.select2-container--default .select2-search--dropdown .select2-search__field {
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  padding: var(--space-sm);
  outline: none;
}

.select2-container--default .select2-search--dropdown .select2-search__field:focus {
  border-color: var(--primary);
}

/* select2 base — hide the original select properly */
.select2-hidden-accessible {
  border: 0 !important;
  clip: rect(0 0 0 0) !important;
  -webkit-clip-path: inset(50%) !important;
  clip-path: inset(50%) !important;
  height: 1px !important;
  overflow: hidden !important;
  padding: 0 !important;
  position: absolute !important;
  white-space: nowrap !important;
  width: 1px !important;
}

/* ============================================
   SELECT2 — dropdown mechanics + bigger + multi
   ============================================ */
.select2-dropdown {
  position: absolute;
  top: 0;
  left: 0;
  display: block;
  box-sizing: border-box;
  width: 100%;
  min-width: 220px;
}

.select2-search--dropdown { display: block; padding: var(--space-sm); }
.select2-results { display: block; }
.select2-results__options {
  list-style: none;
  margin: 0;
  padding: 0;
  max-height: 280px;
  overflow-y: auto;
}
.select2-results__option { user-select: none; cursor: pointer; }
.select2-results__message { color: var(--text-muted); padding: var(--space-sm) var(--space); }

/* bigger filters */
.select2-container--default .select2-selection--single,
.select2-container--default .select2-selection--multiple {
  min-height: 44px;
  font-size: 0.95rem;
  display: flex;
  align-items: center;
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
}

/* multi-select pills */
.select2-container--default .select2-selection--multiple {
  padding: var(--space-xs) var(--space-sm);
  cursor: text;
}

.select2-container--default .select2-selection--multiple .select2-selection__rendered {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-xs);
  list-style: none;
  margin: 0;
  padding: 0;
}

.select2-container--default .select2-selection--multiple .select2-selection__choice {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  background: var(--primary);
  color: #111;
  border: none;
  border-radius: var(--radius-sm);
  padding: 2px var(--space-sm);
  font-size: var(--font-size-sm);
  font-weight: 600;
}

.select2-container--default .select2-selection--multiple .select2-selection__choice__remove {
  color: #111;
  font-weight: 700;
  cursor: pointer;
  margin-left: 2px;
}

.select2-container--default .select2-selection--multiple .select2-search--inline {
  display: inline-flex;
}

.select2-container--default .select2-selection--multiple .select2-search__field {
  background: transparent;
  border: none;
  outline: none;
  color: var(--text-primary);
  font-family: inherit;
  font-size: 0.95rem;
  min-width: 60px;
}

/* select2 multi — full placeholder room, wider filter cells */
.filter-panel { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
.select2-container--default .select2-selection--multiple .select2-search__field { min-width: 120px; }

/* Ticket subject line */
.ticket-subject {
  color: var(--text-secondary);
  font-size: var(--font-size);
  margin-bottom: var(--space-sm);
}
.ticket-subject strong { color: var(--text-primary); }

/* Ticket textareas — dark themed */
.ticket-wrap textarea {
  background: var(--bg-input) !important;
  border: 1px solid var(--border-color) !important;
  border-radius: var(--radius) !important;
  color: var(--text-primary) !important;
  padding: var(--space) !important;
  font-family: inherit !important;
  font-size: var(--font-size) !important;
  width: 100% !important;
  box-sizing: border-box;
}
.ticket-wrap textarea:focus {
  border-color: var(--primary) !important;
  outline: none !important;
  box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.2) !important;
}
.ticket-wrap textarea::placeholder { color: var(--text-muted); }

/* Cart toggle state — in-cart buttons go outline gold */
.add-cart-btn.in-cart {
  background: transparent !important;
  color: var(--primary) !important;
  border: 1px solid var(--primary) !important;
}
.add-cart-btn.in-cart:hover {
  background: var(--primary) !important;
  color: #111 !important;
}

/* ============================================
   CHECK COLUMN — status button states
   VALID solid gold, Invalid inverse, TIME OUT muted
   ============================================ */

/* VALID — solid gold (global rule already; restated for clarity) */
#carddatatable .btn-success {
  background: var(--primary) !important;
  color: #111 !important;
  border: 1px solid var(--primary) !important;
}

/* Invalid Card — danger: dead card, red identity */
#carddatatable .btn-default {
  background: rgba(239, 68, 68, 0.15) !important;
  color: var(--danger) !important;
  border: 1px solid var(--danger) !important;
}
#carddatatable .btn-default:hover {
  background: var(--danger) !important;
  color: #fff !important;
}

/* TIME OUT / Expired / NOT DEFINED — distinct: muted dead state */
#carddatatable .btn-danger {
  background: #232323 !important;
  color: #6b7280 !important;
  border: 1px solid #3a3a3a !important;
  text-decoration: line-through;
  cursor: default;
}
#carddatatable .btn-danger:hover {
  background: #232323 !important;
  color: #6b7280 !important;
  border-color: #3a3a3a !important;
}

/* REFUNDED / FORMAT ERROR / Manual Refund — inverse: gold outline */
#carddatatable .btn-warning {
  background: transparent !important;
  color: var(--primary) !important;
  border: 1px solid var(--primary) !important;
}
#carddatatable .btn-warning:hover {
  background: var(--primary) !important;
  color: #111 !important;
}

/* status labels are not actions — no pointer games */
#carddatatable td button[type="button"] { cursor: default; }

/* ============================================
   FRONTEND — status buttons (CHECK column)
   ============================================ */
.status-btn {
  display: inline-block;
  padding: 4px 12px;
  border-radius: var(--radius);
  font-size: var(--font-size-xs);
  font-weight: 600;
  white-space: nowrap;
}
.status-valid {
  background: var(--primary);
  color: #111;
  border: 1px solid var(--primary);
}
.status-refunded {
  background: transparent;
  color: var(--primary);
  border: 1px solid var(--primary);
}
.status-invalid {
  background: rgba(239, 68, 68, 0.15);
  color: var(--danger);
  border: 1px solid var(--danger);
}
.status-timeout {
  background: #232323;
  color: #6b7280;
  border: 1px solid #3a3a3a;
  text-decoration: line-through;
}

/* filter zone — plain block wrapper (not a grid, so children stack vertically) */
.filter-zone {
  display: block;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: var(--space);
  margin-bottom: var(--space);
}
.filter-zone .filter-panel {
  background: transparent;
  border: none;
  padding: 0;
  margin-bottom: var(--space);
}


/* brand wordmark: fancy era face ONLY here */
.wordmark-fancy, .lupin-wordmark {
  font-family: system-ui, -apple-system, sans-serif;
  font-weight: 700;
  letter-spacing: 6px;
}
.wordmark-fancy .accent, .lupin-wordmark .accent { color: #d0a832; }


/* brand wordmark ONLY */
.lupin-wordmark,
.wordmark-fancy,
.shop-logo .shop-name {
  font-family: 'Cinzel Decorative', 'Times New Roman', serif !important;
}

/* ---------- Purchased wide-table fit (16 cols, no horizontal scroller) ---------- */
#tab-content .table th,
#tab-content .table td {
  padding: 8px 6px;
  font-size: 12px;
  white-space: normal;
  word-break: break-word;
}
#tab-content .table th {
  white-space: nowrap;
}
#tab-content .table td:first-child,
#tab-content .table th:first-child {
  width: 28px;
  padding: 8px 4px;
}
/* ============================================
   LUPIN CLUB UNIFIED THEME
   Modern CSS with Variables - Edit to customize
   ============================================ */

/* ============================================
   THEME VARIABLES - Edit these to change theme
   ============================================ */
:root {
  /* Primary Colors - Gold */
  --primary: #d4af37;
  --primary-dark: #b8962e;
  --primary-light: #e8cc7a;
  --secondary: #10b981;
  --secondary-dark: #059669;
  
  /* Status Colors */
  --success: #22c55e;
  --danger: #ef4444;
  --warning: #f59e0b;
  --info: #3b82f6;
  
  /* Background Colors - True Black */
  --bg-primary: #0a0a0a;
  --bg-secondary: #161616;
  --bg-card: #1f1f1f;
  --bg-hover: #2a2a2a;
  --bg-input: #141414;
  
  /* Text Colors */
  --text-primary: #f8fafc;
  --text-secondary: #cbd5e1;
  --text-muted: #94a3b8;
  --text-dark: #1e293b;
  
  /* Border Colors */
  --border-color: #2e2e2e;
  --border-light: #3d3d3d;
  
  /* Border Radius */
  --radius-sm: 0.25rem;
  --radius: 0.5rem;
  --radius-lg: 0.75rem;
  --radius-xl: 1rem;
  
  /* Shadows */
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.3);
  --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.3), 0 2px 4px -2px rgba(0, 0, 0, 0.3);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.4), 0 4px 6px -4px rgba(0, 0, 0, 0.4);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.5), 0 8px 10px -6px rgba(0, 0, 0, 0.5);
  
  /* Spacing */
  --space-xs: 0.25rem;
  --space-sm: 0.5rem;
  --space: 1rem;
  --space-lg: 1.5rem;
  --space-xl: 2rem;
  --space-2xl: 3rem;
  
  /* Typography */
  --font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-size-xs: 0.75rem;
  --font-size-sm: 0.875rem;
  --font-size: 1rem;
  --font-size-lg: 1.125rem;
  --font-size-xl: 1.25rem;
  --font-size-2xl: 1.5rem;
  --font-size-3xl: 1.875rem;
  
  /* Transitions */
  --transition: all 0.2s ease;
  --transition-slow: all 0.3s ease;
}

/* ============================================
   BASE STYLES
   ============================================ */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-family);
  font-size: var(--font-size);
  line-height: 1.6;
  color: var(--text-primary);
  background: var(--bg-primary);
  min-height: 100vh;
  overflow-x: hidden;
}

/* ============================================
   SCROLLBAR
   ============================================ */
::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

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

::-webkit-scrollbar-thumb {
  background: var(--primary);
  border-radius: var(--radius);
}

::-webkit-scrollbar-thumb:hover {
  background: var(--primary-light);
}

/* ============================================
   LAYOUT
   ============================================ */
.container {
  width: 100%;
  max-width: 1680px;
  margin: 0 auto;
  padding: 0 var(--space);
}

.container-fluid {
  width: 100%;
  padding: 0 var(--space);
}

.row {
  display: flex;
  flex-wrap: wrap;
  margin: 0 calc(var(--space) * -1);
}

.col {
  flex: 1;
  padding: 0 var(--space);
}

/* Grid Columns */
.col-1 { flex: 0 0 8.333%; }
.col-2 { flex: 0 0 16.666%; }
.col-3 { flex: 0 0 25%; }
.col-4 { flex: 0 0 33.333%; }
.col-5 { flex: 0 0 41.666%; }
.col-6 { flex: 0 0 50%; }
.col-7 { flex: 0 0 58.333%; }
.col-8 { flex: 0 0 66.666%; }
.col-9 { flex: 0 0 75%; }
.col-10 { flex: 0 0 83.333%; }
.col-11 { flex: 0 0 91.666%; }
.col-12 { flex: 0 0 100%; }

/* ============================================
   HEADER & NAVIGATION
   ============================================ */
.header {
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-color);
  padding: var(--space) 0;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: var(--shadow);
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--space);
}

.logo {
  font-size: var(--font-size-2xl);
  font-weight: 700;
  color: var(--primary);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.logo:hover {
  color: var(--primary-light);
}

.nav {
  display: flex;
  gap: var(--space-sm);
  list-style: none;
}

.nav-link {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
  padding: var(--space-sm) var(--space);
  color: var(--text-secondary);
  text-decoration: none;
  border-radius: var(--radius);
  transition: var(--transition);
  font-weight: 500;
}

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

.nav-link.active {
  background: var(--primary);
  color: white;
}

/* User Info Bar */
.user-bar {
  display: flex;
  align-items: center;
  gap: var(--space);
  padding: var(--space-sm) var(--space);
  background: var(--bg-card);
  border-radius: var(--radius);
  font-size: var(--font-size-sm);
}

.user-bar-item {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
}

.user-bar-label {
  color: var(--text-muted);
}

.user-bar-value {
  color: var(--text-primary);
  font-weight: 600;
}

/* ============================================
   CARDS
   ============================================ */
.card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  padding: var(--space-lg);
  margin-bottom: var(--space);
  border: 1px solid var(--border-color);
  transition: var(--transition);
}

.card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-2px);
}

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

.card-title {
  font-size: var(--font-size-xl);
  font-weight: 600;
  color: var(--text-primary);
}

.card-body {
  color: var(--text-secondary);
}

/* ============================================
   BUTTONS
   ============================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-xs);
  padding: var(--space-sm) var(--space);
  font-size: var(--font-size-sm);
  font-weight: 500;
  border: none;
  border-radius: var(--radius);
  cursor: pointer;
  transition: var(--transition);
  text-decoration: none;
  white-space: nowrap;
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn-primary {
  background: var(--primary);
  color: white;
}

.btn-primary:hover:not(:disabled) {
  background: var(--primary-dark);
  transform: translateY(-1px);
  box-shadow: var(--shadow);
}

.btn-secondary {
  background: var(--secondary);
  color: white;
}

.btn-secondary:hover:not(:disabled) {
  background: var(--secondary-dark);
}

.btn-success {
  background: var(--success);
  color: white;
}

.btn-danger {
  background: var(--danger);
  color: white;
}

.btn-warning {
  background: var(--warning);
  color: var(--text-dark);
}

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

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

.btn-sm {
  padding: var(--space-xs) var(--space-sm);
  font-size: var(--font-size-xs);
}

.btn-lg {
  padding: var(--space) var(--space-lg);
  font-size: var(--font-size-lg);
}

.btn-block {
  width: 100%;
}

/* ============================================
   FORMS
   ============================================ */
.form-group {
  margin-bottom: var(--space);
}

.form-label {
  display: block;
  margin-bottom: var(--space-xs);
  font-weight: 500;
  color: var(--text-primary);
}

.form-control {
  width: 100%;
  padding: var(--space-sm) var(--space);
  font-size: var(--font-size);
  font-family: inherit;
  color: var(--text-primary);
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  transition: var(--transition);
}

.form-control:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.2);
}

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

textarea.form-control {
  min-height: 100px;
  resize: vertical;
}

select.form-control {
  cursor: pointer;
}

/* Form Check */
.form-check {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  margin-bottom: var(--space-sm);
}

.form-check-input {
  width: 18px;
  height: 18px;
  cursor: pointer;
}

/* ============================================
   TABLES
   ============================================ */
.table-container {
  overflow-x: auto;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-color);
}

.table {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--font-size-sm);
}

.table th,
.table td {
  padding: var(--space);
  text-align: left;
  border-bottom: 1px solid var(--border-color);
}

.table th {
  background: var(--bg-secondary);
  font-weight: 600;
  color: var(--text-primary);
  white-space: nowrap;
}

.table td {
  color: var(--text-secondary);
}

.table tbody tr {
  transition: var(--transition);
}

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

/* ============================================
   ALERTS
   ============================================ */
.alert {
  padding: var(--space);
  border-radius: var(--radius);
  margin-bottom: var(--space);
  border: 1px solid transparent;
}

.alert-success {
  background: rgba(34, 197, 94, 0.1);
  border-color: var(--success);
  color: var(--success);
}

.alert-danger {
  background: rgba(239, 68, 68, 0.1);
  border-color: var(--danger);
  color: var(--danger);
}

.alert-warning {
  background: rgba(245, 158, 11, 0.1);
  border-color: var(--warning);
  color: var(--warning);
}

.alert-info {
  background: rgba(59, 130, 246, 0.1);
  border-color: var(--info);
  color: var(--info);
}

/* ============================================
   BADGES
   ============================================ */
.badge {
  display: inline-flex;
  align-items: center;
  padding: var(--space-xs) var(--space-sm);
  font-size: var(--font-size-xs);
  font-weight: 600;
  border-radius: var(--radius-sm);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.badge-primary {
  background: var(--primary);
  color: white;
}

.badge-success {
  background: var(--success);
  color: white;
}

.badge-danger {
  background: var(--danger);
  color: white;
}

.badge-warning {
  background: var(--warning);
  color: var(--text-dark);
}

/* ============================================
   MODALS
   ============================================ */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.8);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: var(--space);
}

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

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

.modal-title {
  font-size: var(--font-size-xl);
  font-weight: 600;
}

.modal-close {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: var(--font-size-2xl);
  cursor: pointer;
  transition: var(--transition);
}

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

.modal-body {
  padding: var(--space-lg);
}

.modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: var(--space-sm);
  padding: var(--space-lg);
  border-top: 1px solid var(--border-color);
}

/* ============================================
   LOADER
   ============================================ */
.loader {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--bg-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
}

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

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

/* ============================================
   UTILITIES
   ============================================ */

/* Display */
.d-none { display: none; }
.d-block { display: block; }
.d-flex { display: flex; }
.d-grid { display: grid; }
.d-inline { display: inline; }
.d-inline-block { display: inline-block; }
.d-inline-flex { display: inline-flex; }

/* Flex */
.flex-row { flex-direction: row; }
.flex-column { flex-direction: column; }
.flex-wrap { flex-wrap: wrap; }
.justify-start { justify-content: flex-start; }
.justify-end { justify-content: flex-end; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.justify-around { justify-content: space-around; }
.align-start { align-items: flex-start; }
.align-end { align-items: flex-end; }
.align-center { align-items: center; }
.align-baseline { align-items: baseline; }
.align-stretch { align-items: stretch; }

/* Gap */
.gap-0 { gap: 0; }
.gap-1 { gap: var(--space-xs); }
.gap-2 { gap: var(--space-sm); }
.gap-3 { gap: var(--space); }
.gap-4 { gap: var(--space-lg); }
.gap-5 { gap: var(--space-xl); }

/* Margin */
.m-0 { margin: 0; }
.m-1 { margin: var(--space-xs); }
.m-2 { margin: var(--space-sm); }
.m-3 { margin: var(--space); }
.m-4 { margin: var(--space-lg); }
.m-5 { margin: var(--space-xl); }
.m-auto { margin: auto; }

.mt-0 { margin-top: 0; }
.mt-1 { margin-top: var(--space-xs); }
.mt-2 { margin-top: var(--space-sm); }
.mt-3 { margin-top: var(--space); }
.mt-4 { margin-top: var(--space-lg); }
.mt-5 { margin-top: var(--space-xl); }

.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: var(--space-xs); }
.mb-2 { margin-bottom: var(--space-sm); }
.mb-3 { margin-bottom: var(--space); }
.mb-4 { margin-bottom: var(--space-lg); }
.mb-5 { margin-bottom: var(--space-xl); }

.ml-0 { margin-left: 0; }
.ml-1 { margin-left: var(--space-xs); }
.ml-2 { margin-left: var(--space-sm); }
.ml-3 { margin-left: var(--space); }
.ml-4 { margin-left: var(--space-lg); }
.ml-5 { margin-left: var(--space-xl); }

.mr-0 { margin-right: 0; }
.mr-1 { margin-right: var(--space-xs); }
.mr-2 { margin-right: var(--space-sm); }
.mr-3 { margin-right: var(--space); }
.mr-4 { margin-right: var(--space-lg); }
.mr-5 { margin-right: var(--space-xl); }

/* Padding */
.p-0 { padding: 0; }
.p-1 { padding: var(--space-xs); }
.p-2 { padding: var(--space-sm); }
.p-3 { padding: var(--space); }
.p-4 { padding: var(--space-lg); }
.p-5 { padding: var(--space-xl); }

.pt-0 { padding-top: 0; }
.pt-1 { padding-top: var(--space-xs); }
.pt-2 { padding-top: var(--space-sm); }
.pt-3 { padding-top: var(--space); }
.pt-4 { padding-top: var(--space-lg); }
.pt-5 { padding-top: var(--space-xl); }

.pb-0 { padding-bottom: 0; }
.pb-1 { padding-bottom: var(--space-xs); }
.pb-2 { padding-bottom: var(--space-sm); }
.pb-3 { padding-bottom: var(--space); }
.pb-4 { padding-bottom: var(--space-lg); }
.pb-5 { padding-bottom: var(--space-xl); }

/* Text */
.text-left { text-align: left; }
.text-center { text-align: center; }
.text-right { text-align: right; }
.text-justify { text-align: justify; }

.text-xs { font-size: var(--font-size-xs); }
.text-sm { font-size: var(--font-size-sm); }
.text-base { font-size: var(--font-size); }
.text-lg { font-size: var(--font-size-lg); }
.text-xl { font-size: var(--font-size-xl); }
.text-2xl { font-size: var(--font-size-2xl); }
.text-3xl { font-size: var(--font-size-3xl); }

.text-primary { color: var(--primary); }
.text-secondary { color: var(--text-secondary); }
.text-muted { color: var(--text-muted); }
.text-success { color: var(--success); }
.text-danger { color: var(--danger); }
.text-warning { color: var(--warning); }
.text-white { color: white; }

.font-light { font-weight: 300; }
.font-normal { font-weight: 400; }
.font-medium { font-weight: 500; }
.font-semibold { font-weight: 600; }
.font-bold { font-weight: 700; }

.uppercase { text-transform: uppercase; }
.lowercase { text-transform: lowercase; }
.capitalize { text-transform: capitalize; }

/* Background */
.bg-primary { background: var(--primary); }
.bg-secondary { background: var(--bg-secondary); }
.bg-card { background: var(--bg-card); }
.bg-success { background: var(--success); }
.bg-danger { background: var(--danger); }
.bg-warning { background: var(--warning); }

/* Border */
.border { border: 1px solid var(--border-color); }
.border-0 { border: none; }
.border-top { border-top: 1px solid var(--border-color); }
.border-bottom { border-bottom: 1px solid var(--border-color); }
.border-left { border-left: 1px solid var(--border-color); }
.border-right { border-right: 1px solid var(--border-color); }

.rounded { border-radius: var(--radius); }
.rounded-sm { border-radius: var(--radius-sm); }
.rounded-lg { border-radius: var(--radius-lg); }
.rounded-xl { border-radius: var(--radius-xl); }
.rounded-full { border-radius: 9999px; }

/* Shadow */
.shadow-sm { box-shadow: var(--shadow-sm); }
.shadow { box-shadow: var(--shadow); }
.shadow-lg { box-shadow: var(--shadow-lg); }
.shadow-xl { box-shadow: var(--shadow-xl); }
.shadow-none { box-shadow: none; }

/* Width */
.w-full { width: 100%; }
.w-auto { width: auto; }
.w-1\/2 { width: 50%; }
.w-1\/3 { width: 33.333%; }
.w-2\/3 { width: 66.666%; }
.w-1\/4 { width: 25%; }
.w-3\/4 { width: 75%; }

/* Cursor */
.cursor-pointer { cursor: pointer; }
.cursor-default { cursor: default; }
.cursor-not-allowed { cursor: not-allowed; }

/* Overflow */
.overflow-hidden { overflow: hidden; }
.overflow-auto { overflow: auto; }
.overflow-scroll { overflow: scroll; }
.overflow-x-auto { overflow-x: auto; }
.overflow-y-auto { overflow-y: auto; }

/* Position */
.relative { position: relative; }
.absolute { position: absolute; }
.fixed { position: fixed; }
.sticky { position: sticky; }

/* Z-Index */
.z-0 { z-index: 0; }
.z-10 { z-index: 10; }
.z-20 { z-index: 20; }
.z-30 { z-index: 30; }
.z-40 { z-index: 40; }
.z-50 { z-index: 50; }

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 768px) {
  .header-content {
    flex-direction: column;
    gap: var(--space-sm);
  }
  
  .nav {
    flex-wrap: wrap;
    justify-content: center;
  }
  
  .user-bar {
    flex-wrap: wrap;
    justify-content: center;
  }
  
  .col-1, .col-2, .col-3, .col-4, .col-5, .col-6,
  .col-7, .col-8, .col-9, .col-10, .col-11, .col-12 {
    flex: 0 0 100%;
  }
  
  .card {
    padding: var(--space);
  }
  
  .table {
    font-size: var(--font-size-xs);
  }
  
  .table th,
  .table td {
    padding: var(--space-sm);
  }
}

@media (max-width: 480px) {
  .btn {
    width: 100%;
    justify-content: center;
  }
  
  .modal {
    margin: var(--space);
    max-width: calc(100% - 2 * var(--space));
  }
}

/* ============================================
   ANIMATIONS
   ============================================ */
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

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

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

.animate-fadeIn {
  animation: fadeIn 0.3s ease;
}

.animate-slideIn {
  animation: slideIn 0.3s ease;
}

.animate-pulse {
  animation: pulse 2s ease infinite;
}

/* ============================================
   PRINT
   ============================================ */
@media print {
  .header,
  .nav,
  .btn,
  .user-bar {
    display: none !important;
  }
  
  .card {
    box-shadow: none;
    border: 1px solid #ddd;
  }
  
  body {
    background: white;
    color: black;
  }
}

/* ============================================
   BOOTSTRAP 3.x COMPATIBILITY LAYER
   For login page and legacy components
   ============================================ */

/* Sign Wrapper */
.signwrapper {
  background: var(--bg-primary);
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space);
}

.sign-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.7);
  z-index: 1;
}

.signpanel {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url('../images/img3.jpg') no-repeat center center;
  background-size: cover;
  opacity: 0.3;
  z-index: 0;
}

/* Panel */
.signwrapper .panel {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border-color);
  position: relative;
  z-index: 2;
  max-width: 450px;
  width: 100%;
  margin: 0 auto;
}

.signwrapper .panel.signin {
  padding: 0;
}

.signwrapper .panel-body {
  padding: var(--space-xl);
}

.signwrapper .panel-heading {
  padding: var(--space-lg) var(--space-xl);
  border-bottom: 1px solid var(--border-color);
  margin-bottom: var(--space);
}

.signwrapper .panel-title {
  font-size: var(--font-size-2xl);
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
  text-align: center;
}

/* Form Group */
.form-group {
  margin-bottom: var(--space);
}

.form-group.mb10 { margin-bottom: 10px; }
.form-group.mb15 { margin-bottom: 15px; }
.form-group.mb20 { margin-bottom: 20px; }
.form-group.nomargin { margin-bottom: 0; }

/* Input Group */
.input-group {
  display: flex;
  width: 100%;
}

.input-group-addon {
  display: flex;
  align-items: center;
  padding: var(--space-sm) var(--space);
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-right: none;
  border-radius: var(--radius) 0 0 var(--radius);
  color: var(--text-muted);
}

.input-group .form-control {
  border-radius: 0 var(--radius) var(--radius) 0;
  border-left: none;
}

.input-group .form-control:focus {
  border-left: none;
}

/* Glyphicons */
.glyphicon {
  display: inline-block;
  font-family: 'Glyphicons Halflings';
  font-style: normal;
  font-weight: 400;
  line-height: 1;
  -webkit-font-smoothing: antialiased;
}

.glyphicon-user::before { content: "👤"; }
.glyphicon-lock::before { content: "🔒"; }
.glyphicon-home::before { content: "🏠"; }
.glyphicon-envelope::before { content: "✉️"; }
.glyphicon-sign-out::before { content: "🚪"; }
.glyphicon-line-chart::before { content: "📈"; }

/* Buttons */
.btn-quirk {
  border-radius: var(--radius);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: var(--space) var(--space-lg);
  transition: var(--transition);
}

.btn-block {
  display: block;
  width: 100%;
}

.btn-stroke {
  background: transparent;
  border: 2px solid;
}

.btn-stroke-thin {
  border-width: 1px;
}

.btn-stroke.btn-danger {
  border-color: var(--danger);
  color: var(--danger);
}

.btn-stroke.btn-danger:hover {
  background: var(--danger);
  color: white;
}

/* Alerts */
.alert {
  padding: var(--space);
  border-radius: var(--radius);
  margin-bottom: var(--space);
  border: 1px solid transparent;
}

.alert-dismissable {
  padding-right: calc(var(--space) + 20px);
  position: relative;
}

.alert-dismissable .close {
  position: absolute;
  top: 50%;
  right: var(--space);
  transform: translateY(-50%);
  background: none;
  border: none;
  color: inherit;
  font-size: 20px;
  cursor: pointer;
  opacity: 0.5;
}

.alert-dismissable .close:hover {
  opacity: 1;
}

.alert-danger {
  background: rgba(239, 68, 68, 0.1);
  border-color: var(--danger);
  color: var(--danger);
}

.alert-warning {
  background: rgba(245, 158, 11, 0.1);
  border-color: var(--warning);
  color: var(--warning);
}

.alert-info {
  background: rgba(59, 130, 246, 0.1);
  border-color: var(--info);
  color: var(--info);
}

.alert-success {
  background: rgba(34, 197, 94, 0.1);
  border-color: var(--success);
  color: var(--success);
}

.page-alert {
  margin: var(--space) var(--space-xl) 0;
}

/* Text Colors */
.text-danger { color: var(--danger); }
.text-warning { color: var(--warning); }
.text-info { color: var(--info); }
.text-success { color: var(--success); }
.text-muted { color: var(--text-muted); }

/* Forgot Link */
.forgot {
  display: block;
  text-align: center;
  color: var(--text-muted);
  font-size: var(--font-size-sm);
  margin: var(--space) 0;
  text-decoration: none;
}

.forgot:hover {
  color: var(--primary);
}

/* CAPTCHA */
.CAPTCHA {
  margin: var(--space) 0;
}

.CAPTCHA_input {
  margin-top: var(--space);
}

/* Signup Section */
.signup {
  display: none;
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  max-width: 900px;
  width: 100%;
  margin: var(--space) auto;
  position: relative;
  z-index: 2;
}

.signup .row {
  display: flex;
  margin: 0;
}

.signup .col-sm-5 {
  flex: 0 0 41.666%;
  padding: 0;
}

.signup .col-sm-7 {
  flex: 0 0 58.333%;
  padding: 0;
}

.sign-sidebar {
  padding: var(--space-xl);
  background: var(--bg-secondary);
  height: 100%;
  border-radius: 0 var(--radius-lg) var(--radius-lg) 0;
}

.signtitle {
  font-size: var(--font-size-2xl);
  color: var(--text-primary);
  margin-bottom: var(--space);
}

.reason {
  color: var(--primary);
  font-size: var(--font-size-lg);
  margin-top: var(--space-lg);
  margin-bottom: var(--space-sm);
}

.sign-sidebar p {
  color: var(--text-secondary);
  line-height: 1.6;
}

/* Confirm Message */
.confirmMessage {
  display: block;
  margin-top: var(--space-xs);
  font-size: var(--font-size-sm);
}

/* SSL Badge */
#ssl {
  text-align: center;
  margin-top: var(--space-lg);
  padding-top: var(--space-lg);
  border-top: 1px solid var(--border-color);
  color: var(--text-muted);
  font-size: var(--font-size-sm);
}

#ssl img {
  vertical-align: middle;
  margin-right: var(--space-xs);
}

/* Logo */
.signwrapper .panel-body img[src*="logo"] {
  max-width: 200px;
  height: auto;
  margin: 0 auto var(--space);
  display: block;
}

/* Responsive */
@media (max-width: 768px) {
  .signwrapper .panel {
    margin: var(--space);
    max-width: calc(100% - 2 * var(--space));
  }
  
  .panel-body {
    padding: var(--space);
  }
  
  .signup .row {
    flex-direction: column;
  }
  
  .signup .col-sm-5,
  .signup .col-sm-7 {
    flex: 0 0 100%;
  }
  
  .sign-sidebar {
    border-radius: 0 0 var(--radius-lg) var(--radius-lg);
  }
}

/* ============================================
   LEGACY LAYOUT BRIDGE
   Styles the rt-* header & gf-menu markup
   ============================================ */

/* Header band */
header#rt-top-surround {
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-color);
  padding: var(--space) 0;
}

#rt-header .rt-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--space);
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 var(--space);
}

.left_block .paragrafi {
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.7;
  margin: 0;
}
.left_block .paragrafi strong { color: var(--text-primary); }

.right_block {
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.7;
  text-align: right;
}
.right_block strong { color: var(--text-primary); }

/* Main navigation */
.menu-block {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 var(--space);
}

ul.gf-menu {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-sm);
  list-style: none;
  margin: var(--space) auto;
  padding: var(--space-sm);
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  max-width: 1400px;
  box-shadow: var(--shadow);
}

ul.gf-menu li {
  margin: 0;
  padding: 0;
  list-style: none;
}

ul.gf-menu li:not(.btn) a.item {
  display: inline-block;
  padding: var(--space-sm) var(--space);
  color: var(--text-secondary);
  text-decoration: none;
  border-radius: var(--radius);
  font-weight: 500;
  transition: background 0.15s ease, color 0.15s ease;
}

ul.gf-menu li:not(.btn) a.item:hover {
  background: var(--primary);
  color: #fff;
  text-decoration: none;
}

ul.gf-menu li.btn a.item {
  color: #fff;
  text-decoration: none;
}

/* ============================================
   LEGACY BRIDGE — round 2 polish
   ============================================ */

/* User info card */
.left_block .paragrafi {
  padding: var(--space-sm) var(--space);
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
}

/* Right header block: time + logout in a tidy row */
.right_block {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: var(--space-sm) var(--space);
  text-align: right;
}
.right_block > div {
  margin-bottom: 0 !important;
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

/* Readable links on dark background */
a { color: var(--primary-light); }
a:hover { color: var(--primary); }
ul.gf-menu li a.item:hover { color: #fff; }
ul.gf-menu li.btn a.item, ul.gf-menu li.btn a.item:hover { color: #fff; }

/* Home icon without the glyphicons font */
.glyphicon-home::before { content: "\2302"; }

/* Countdown/header text: natural inline flow, buttons stay in a row */
.right_block { display: block; text-align: right; }
.right_block > div { display: flex; justify-content: flex-end; align-items: center; gap: var(--space-sm); margin-top: var(--space-xs); }

/* ============================================
   SHOP COMPONENTS — Phase 1
   Product grids, price chips, filter bars,
   balance widget, pagination, empty states.
   Tokens only — recolors with :root.
   ============================================ */

/* ---------- Shop layout wrapper ---------- */
.shop-wrap {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 var(--space) var(--space-xl);
}

.shop-page-title {
  font-size: var(--font-size-2xl);
  font-weight: 700;
  color: var(--text-primary);
  margin: var(--space-lg) 0 var(--space-sm);
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.shop-page-sub {
  color: var(--text-muted);
  font-size: var(--font-size-sm);
  margin-bottom: var(--space-lg);
}

/* ---------- Stat row (balance, counts) ---------- */
.stat-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: var(--space);
  margin-bottom: var(--space-lg);
}

.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: var(--space) var(--space-lg);
  box-shadow: var(--shadow-sm);
}

.stat-card .stat-label {
  color: var(--text-muted);
  font-size: var(--font-size-xs);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.stat-card .stat-value {
  color: var(--text-primary);
  font-size: var(--font-size-2xl);
  font-weight: 700;
  margin-top: var(--space-xs);
}

.stat-card .stat-value.accent { color: var(--secondary); }

/* ---------- Filter bar ---------- */
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-sm);
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: var(--space-sm) var(--space);
  margin-bottom: var(--space-lg);
}

.filter-bar .filter-label {
  color: var(--text-muted);
  font-size: var(--font-size-sm);
  font-weight: 500;
}

.filter-bar select,
.filter-bar input[type="text"],
.filter-bar input[type="search"] {
  padding: var(--space-sm) var(--space);
  font-size: var(--font-size-sm);
  font-family: inherit;
  color: var(--text-primary);
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  transition: var(--transition);
}

.filter-bar select:focus,
.filter-bar input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.2);
}

/* ---------- Product grid ---------- */
.shop-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: var(--space);
}

.product-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  padding: var(--space-lg);
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
  transition: var(--transition);
}

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

.product-card .pc-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: var(--space-sm);
}

.product-card .pc-title {
  font-size: var(--font-size-lg);
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.3;
}

.product-card .pc-meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-xs) var(--space);
  color: var(--text-muted);
  font-size: var(--font-size-sm);
}

.product-card .pc-meta strong {
  color: var(--text-secondary);
  font-weight: 500;
}

.product-card .pc-desc {
  color: var(--text-secondary);
  font-size: var(--font-size-sm);
  line-height: 1.6;
  flex: 1;
}

.product-card .pc-foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--space-sm);
  padding-top: var(--space-sm);
  border-top: 1px solid var(--border-color);
}

/* ---------- Price chip ---------- */
.price-chip {
  display: inline-flex;
  align-items: baseline;
  gap: 2px;
  padding: var(--space-xs) var(--space-sm);
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid var(--secondary);
  color: var(--secondary);
  font-weight: 700;
  font-size: var(--font-size-lg);
  border-radius: var(--radius);
  white-space: nowrap;
}

.price-chip small {
  font-size: var(--font-size-xs);
  font-weight: 500;
}

/* ---------- Stock / status badges ---------- */
.badge-stock {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  padding: var(--space-xs) var(--space-sm);
  font-size: var(--font-size-xs);
  font-weight: 600;
  border-radius: var(--radius-sm);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.badge-stock::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: currentColor;
}

.badge-stock.in { background: rgba(34, 197, 94, 0.12); color: var(--success); }
.badge-stock.out { background: rgba(239, 68, 68, 0.12); color: var(--danger); }
.badge-stock.low { background: rgba(245, 158, 11, 0.12); color: var(--warning); }

/* ---------- Tag pills (type/country/bank) ---------- */
.tag {
  display: inline-block;
  padding: 2px var(--space-sm);
  font-size: var(--font-size-xs);
  font-weight: 500;
  color: var(--text-secondary);
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-full);
  white-space: nowrap;
}

/* ---------- Pagination ---------- */
.pagination {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-xs);
  justify-content: center;
  margin: var(--space-lg) 0;
  list-style: none;
  padding: 0;
}

.pagination a,
.pagination span,
.pagination li a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  padding: 0 var(--space-sm);
  color: var(--text-secondary);
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  text-decoration: none;
  font-size: var(--font-size-sm);
  transition: var(--transition);
}

.pagination a:hover {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

.pagination .active,
.pagination span.active {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

/* ---------- Empty state ---------- */
.empty-state {
  text-align: center;
  padding: var(--space-2xl) var(--space);
  color: var(--text-muted);
  background: var(--bg-secondary);
  border: 1px dashed var(--border-color);
  border-radius: var(--radius-lg);
}

.empty-state .empty-icon {
  font-size: 2.5rem;
  margin-bottom: var(--space);
  opacity: 0.6;
}

.empty-state .empty-title {
  font-size: var(--font-size-lg);
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: var(--space-xs);
}

/* ---------- Balance widget (header) ---------- */
.balance-widget {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-sm) var(--space);
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  font-size: var(--font-size-sm);
}

.balance-widget .bw-label { color: var(--text-muted); }
.balance-widget .bw-value { color: var(--secondary); font-weight: 700; }

/* ---------- News cards (home) ---------- */
.news-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: var(--space);
  margin-bottom: var(--space-lg);
}

.news-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.news-card:hover { box-shadow: var(--shadow); }

.news-card .news-date {
  color: var(--text-muted);
  font-size: var(--font-size-xs);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.news-card .news-title {
  font-size: var(--font-size-lg);
  font-weight: 600;
  color: var(--text-primary);
  margin: var(--space-xs) 0 var(--space-sm);
}

.news-card .news-body {
  color: var(--text-secondary);
  font-size: var(--font-size-sm);
  line-height: 1.6;
}

/* ---------- Legacy table skin (classless tables in shop content) ---------- */
.shop-wrap table {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--font-size-sm);
}

.shop-wrap table th,
.shop-wrap table td {
  padding: var(--space-sm) var(--space);
  text-align: left;
  border-bottom: 1px solid var(--border-color);
  color: var(--text-secondary);
}

.shop-wrap table th {
  background: var(--bg-secondary);
  color: var(--text-primary);
  font-weight: 600;
}

.shop-wrap table tr:hover td { background: var(--bg-hover); }

/* ---------- Section divider ---------- */
.shop-section { margin-bottom: var(--space-xl); }

.shop-section > .section-title {
  font-size: var(--font-size-xl);
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: var(--space);
  padding-bottom: var(--space-sm);
  border-bottom: 1px solid var(--border-color);
}

/* ---------- Responsive ---------- */
@media (max-width: 768px) {
  .shop-grid { grid-template-columns: 1fr; }
  .stat-row { grid-template-columns: repeat(2, 1fr); }
  .filter-bar { flex-direction: column; align-items: stretch; }
  .filter-bar select, .filter-bar input { width: 100%; }
}

/* ============================================
   SHOP SHELL — Phase 2
   Header, alert banner, footer frame
   ============================================ */

/* Slim security banner (replaces the 24px red wall) */
.shop-alert-banner {
  background: #7f1d1d;
  color: #fecaca;
  font-size: var(--font-size-sm);
  text-align: center;
  padding: var(--space-sm) var(--space);
  line-height: 1.5;
}
.shop-alert-banner strong { font-weight: 600; }
.shop-alert-banner strong + strong { display: block; margin-top: 2px; }

/* Header frame */
.shop-header {
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-color);
  box-shadow: var(--shadow);
  position: sticky;
  top: 0;
  z-index: 100;
}

.shop-header-inner {
  max-width: 1400px;
  margin: 0 auto;
  padding: var(--space) var(--space);
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-sm) var(--space-lg);
}

/* Wordmark */
.shop-logo {
  font-size: var(--font-size-2xl);
  font-weight: 800;
  letter-spacing: 0.04em;
  color: var(--text-primary);
  text-decoration: none;
}
.shop-logo span { color: var(--primary); }
.shop-logo:hover { color: var(--primary-light); text-decoration: none; }

/* User chip */
.shop-userchip {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-xs) var(--space-sm);
  padding: var(--space-sm) var(--space);
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  font-size: var(--font-size-sm);
  color: var(--text-secondary);
}
.shop-userchip strong { color: var(--text-primary); }
.shop-userchip .sep { color: var(--text-muted); }
.shop-userchip .balance { color: var(--secondary); font-weight: 700; }
.shop-userchip .pending-link { color: var(--danger); font-weight: 600; }

/* Right side: clock, countdown, actions */
.shop-head-right {
  margin-left: auto;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-sm) var(--space);
  font-size: var(--font-size-sm);
  color: var(--text-secondary);
}
.shop-head-right strong { color: var(--text-primary); }
.shop-head-actions { display: flex; gap: var(--space-sm); }

/* Nav row */
.shop-nav {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 var(--space) var(--space-sm);
}
.shop-nav ul.gf-menu { margin: 0; }

/* Footer */
.shop-footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-color);
  margin-top: var(--space-2xl);
}

.shop-footer-inner {
  max-width: 1400px;
  margin: 0 auto;
  padding: var(--space-xl) var(--space);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: var(--space-lg);
}

.shop-footer-col h3 {
  font-size: var(--font-size);
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: var(--space-sm);
}

.shop-footer-col p {
  color: var(--text-secondary);
  font-size: var(--font-size-sm);
  margin-bottom: var(--space-xs);
}

.shop-copyright {
  border-top: 1px solid var(--border-color);
  text-align: center;
  padding: var(--space);
  color: var(--text-muted);
  font-size: var(--font-size-sm);
}

@media (max-width: 900px) {
  .shop-head-right { margin-left: 0; width: 100%; }
  .shop-header-inner { flex-direction: column; align-items: stretch; }
}

/* News date group heading spans full grid width */
.news-grid-date {
  grid-column: 1 / -1;
  font-size: var(--font-size-lg);
  font-weight: 700;
  color: var(--primary-light);
  margin-top: var(--space);
}
.news-grid-date:first-child { margin-top: 0; }

/* Breadcrumb */
.breadcrumb {
  list-style: none;
  display: flex;
  gap: var(--space-sm);
  padding: 0;
  margin: var(--space) 0 0;
  font-size: var(--font-size-sm);
  color: var(--text-muted);
}
.breadcrumb li.active { color: var(--text-secondary); }

/* ============================================
   DATATABLES SKIN — jQuery DataTables UI
   ============================================ */
.dataTables_wrapper { color: var(--text-secondary); font-size: var(--font-size-sm); }
.dataTables_wrapper .dataTables_length,
.dataTables_wrapper .dataTables_filter {
  margin-bottom: var(--space);
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
}
.dataTables_wrapper .dataTables_filter { float: right; }
.dataTables_wrapper .dataTables_length select,
.dataTables_wrapper .dataTables_filter input {
  padding: var(--space-xs) var(--space-sm);
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  color: var(--text-primary);
  font-family: inherit;
}
.dataTables_wrapper .dataTables_info { color: var(--text-muted); margin-top: var(--space); }
.dataTables_wrapper .dataTables_paginate {
  display: flex;
  gap: var(--space-xs);
  justify-content: flex-end;
  margin-top: var(--space);
}
.dataTables_wrapper .paginate_button {
  display: inline-flex;
  align-items: center;
  min-width: 32px;
  justify-content: center;
  height: 32px;
  padding: 0 var(--space-sm);
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  color: var(--text-secondary) !important;
  cursor: pointer;
  text-decoration: none;
}
.dataTables_wrapper .paginate_button:hover { background: var(--primary); color: #fff !important; border-color: var(--primary); }
.dataTables_wrapper .paginate_button.current,
.dataTables_wrapper .paginate_button.current:hover { background: var(--primary); color: #fff !important; border-color: var(--primary); }
.dataTables_wrapper .paginate_button.disabled { opacity: 0.4; pointer-events: none; }
.dataTables_wrapper .dataTables_processing {
  background: rgba(15, 23, 42, 0.85);
  color: var(--text-primary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  padding: var(--space) var(--space-lg);
}
table.dataTable thead th { border-bottom: 1px solid var(--border-color); }
table.dataTable tbody td { border-bottom: 1px solid var(--border-color); }
table.dataTable.stripe tbody tr.odd, table.dataTable tbody tr.even { background: transparent; }

/* ============================================
   CARDS PAGE — filter panel & buy bar
   ============================================ */
.filter-panel {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: var(--space);
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: var(--space);
  margin-bottom: var(--space);
}

.filter-item label {
  display: block;
  color: var(--text-muted);
  font-size: var(--font-size-xs);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: var(--space-xs);
}

.filter-item select,
.filter-item input[type="text"],
.filter-item textarea {
  width: 100%;
  padding: var(--space-sm) var(--space);
  font-size: var(--font-size-sm);
  font-family: inherit;
  color: var(--text-primary);
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  transition: var(--transition);
}

.filter-item select:focus,
.filter-item input:focus,
.filter-item textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.2);
}

.filter-item textarea { resize: vertical; min-height: 90px; }

.filter-actions {
  display: flex;
  gap: var(--space-sm);
  margin-bottom: var(--space);
}

.quick-filters {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-sm);
  margin-bottom: var(--space-lg);
}

.buy-all-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--space);
  margin-top: var(--space-lg);
  padding: var(--space);
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
}

.buy-all-bar p { color: var(--text-secondary); margin: 0; }

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

/* ============================================
   PURCHASED PAGE — tabs & report view
   ============================================ */
.tab-content > .tab-pane { display: none; }
.tab-content > .tab-pane.active { display: block; }

ul.nav-tabs {
  list-style: none;
  display: flex;
  justify-content: center;
  gap: var(--space-sm);
  padding: 0;
  margin: 0 0 var(--space-lg);
  border-bottom: 1px solid var(--border-color);
}

ul.nav-tabs a { text-decoration: none; }
ul.nav-tabs a button { opacity: 0.65; transition: var(--transition); }
ul.nav-tabs a.active button { opacity: 1; box-shadow: var(--shadow); }

.buttonat { margin-bottom: var(--space); }
.buttonat .btn { margin-right: var(--space-sm); margin-bottom: var(--space-sm); }

#datatable td[onClick], #carddatatable td span[onClick] { cursor: pointer; }
#datatable td[onClick]:hover, #carddatatable td span[onClick]:hover { color: var(--primary-light); }

/* ============================================
   SELLER PANEL — nav & shared
   ============================================ */
.seller-nav {
  width: 1100px;
  max-width: 94vw;
  position: relative;
  left: 50%;
  transform: translateX(-50%);
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: var(--space);
  margin-bottom: var(--space-lg);
}

.seller-nav-title {
  text-align: center;
  font-size: var(--font-size-xl);
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: var(--space);
}

.seller-pills {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-sm);
  padding: 0;
  margin: 0;
}

.seller-pills a {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  padding: var(--space-sm) var(--space);
  color: var(--text-secondary);
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  text-decoration: none;
  font-weight: 500;
  font-size: var(--font-size-sm);
  transition: var(--transition);
}

.seller-pills a:hover { background: var(--primary); color: #fff; border-color: var(--primary); }
.seller-pills li.accent a { background: var(--danger); color: #fff; border-color: var(--danger); }
.seller-pills li.accent a:hover { background: #dc2626; }
.seller-pills li.success a { background: var(--secondary); color: #fff; border-color: var(--secondary); }
.seller-pills li.success a:hover { background: var(--secondary-dark); }

.seller-extract {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-sm);
  margin-top: var(--space);
  padding-top: var(--space);
  border-top: 1px solid var(--border-color);
}

.seller-extract a {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  padding: var(--space-sm) var(--space);
  color: #fff;
  background: var(--danger);
  border-radius: var(--radius);
  text-decoration: none;
  font-size: var(--font-size-sm);
  font-weight: 500;
}
.seller-extract a:hover { background: #dc2626; }

/* ============================================
   SELLER STATISTICS — widget grid
   ============================================ */
#statistics .row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space);
  margin-bottom: var(--space);
}

#statistics .row > [class*="col-"] {
  flex: 1 1 200px;
  min-width: 0;
}

.widget-inline-box {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: var(--space) var(--space-lg);
  box-shadow: var(--shadow-sm);
  text-align: center;
  height: 100%;
}

.widget-inline-box h3 {
  color: var(--text-primary);
  font-size: var(--font-size-2xl);
  font-weight: 700;
  margin: 0;
}

.widget-inline-box h4 {
  color: var(--text-muted);
  font-size: var(--font-size-xs);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin: var(--space-xs) 0 0;
}

#statistics .buttonat h3,
#statistics h3.text-center {
  color: var(--text-primary);
}

/* Google Charts container */
#chart_div, .chart-container {
  background: #fff;
  border-radius: var(--radius-lg);
  padding: var(--space);
  margin-bottom: var(--space-lg);
}

/* ============================================
   SELLER PAGE — unified content width
   All seller pages share one 1100px column
   ============================================ */
.seller-page .content .container {
  width: 1100px !important;
  max-width: 94vw !important;
  margin-left: auto !important;
  margin-right: auto !important;
  float: none !important;
}

/* card-boxes fill the column naturally — never force fixed width on nested boxes */
.seller-page .card-box {
  width: 100% !important;
  max-width: 100% !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
  float: none !important;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: var(--space);
  margin-bottom: var(--space-lg);
  box-sizing: border-box;
}

/* Seller panels — full width, theme card (login panels stay scoped to .signwrapper) */
.seller-page .panel {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  margin-bottom: var(--space);
}
.seller-page .panel-heading {
  padding: var(--space) var(--space-lg);
  border-bottom: 1px solid var(--border-color);
}
.seller-page .panel-title {
  font-size: var(--font-size-xl);
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
  text-align: center;
}
.seller-page .panel-body { padding: var(--space-lg); }

/* Cap legacy columns inside seller pages — stops flex/min-content overflow */
.seller-page .row [class*="col-"] {
  max-width: 100% !important;
  box-sizing: border-box;
}

/* Neutralize grid gutters inside seller pages — legacy cols have no padding compensation */
.seller-page .row {
  margin-left: 0 !important;
  margin-right: 0 !important;
}

/* ============================================
   SELLER PAGES — FULL SCREEN, NO BOXES
   Everything spans the viewport; frames removed
   ============================================ */

/* full-bleed wrapper for seller pages */
.seller-page main.shop-wrap {
  max-width: 100%;
  padding: 0 var(--space);
}

/* nav panel: full width, no box frame */
.seller-nav {
  width: 100% !important;
  max-width: 100% !important;
  left: 0 !important;
  transform: none !important;
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  padding: var(--space) 0 !important;
  margin-bottom: var(--space) !important;
}

/* content column: full width */
.seller-page .content .container {
  width: 100% !important;
  max-width: 100% !important;
  padding: 0 !important;
}

/* card-box: content stays full width, frame removed */
.seller-page .card-box {
  width: 100% !important;
  max-width: 100% !important;
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  padding: 0 !important;
}

/* Flatten legacy grid inside seller pages — block layout, no shrink-wrap */
.seller-page .row {
  display: block !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
}

.seller-page [class*="col-"] {
  width: 100% !important;
  max-width: 100% !important;
  flex: none !important;
  float: none !important;
  display: block !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
}

/* …but keep the statistics widget grid as a real flex grid */
.seller-page #statistics .row {
  display: flex !important;
  flex-wrap: wrap !important;
  gap: var(--space) !important;
}

.seller-page #statistics .row > [class*="col-"] {
  flex: 1 1 0 !important;
  width: auto !important;
  min-width: 200px !important;
}

/* Profile rows */
.profile-rows { display: flex; flex-direction: column; gap: var(--space-sm); }
.profile-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: var(--space);
  padding-bottom: var(--space-sm);
  border-bottom: 1px solid var(--border-color);
}
.profile-row:last-child { border-bottom: none; }
.profile-row span { color: var(--text-muted); font-size: var(--font-size-sm); }
.profile-row strong { color: var(--text-primary); font-weight: 500; text-align: right; }
.profile-row strong.balance { color: var(--secondary); font-weight: 700; }

/* ============================================
   TICKET THREAD — support page panels
   ============================================ */
.ticket-wrap { width: 100%; }

main.shop-wrap .panel {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  margin-bottom: var(--space);
  box-shadow: var(--shadow-sm);
}

main.shop-wrap .panel-heading {
  padding: var(--space-sm) var(--space);
  border-bottom: 1px solid var(--border-color);
}

main.shop-wrap .panel-title {
  color: var(--text-primary);
  font-size: var(--font-size);
  font-weight: 600;
  margin: 0;
}

main.shop-wrap .panel-body { padding: var(--space); }

main.shop-wrap .panel-body pre {
  font-family: inherit;
  color: var(--text-secondary);
  margin: 0;
  background: none;
  border: none;
  padding: 0;
}

.ticket-meta {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: var(--space);
  margin-bottom: var(--space-lg);
}

.ticket-meta .grid-container {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  padding: var(--space);
  text-align: center;
  color: var(--text-secondary);
}

/* ============================================
   LOGIN PAGE — polish
   ============================================ */
.login-wordmark {
  font-size: 2.2rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  color: var(--text-primary);
}
.login-wordmark span { color: var(--primary); }

/* Captcha input full width */
.CAPTCHA_input {
  width: 100% !important;
  float: none !important;
  margin-top: var(--space-sm) !important;
}

/* Input group icons without the glyphicons font */
.signwrapper .glyphicon-user::before { content: "@"; }
.signwrapper .glyphicon-lock::before { content: "*"; }

.signwrapper .input-group-addon {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-right: none;
  border-radius: var(--radius) 0 0 var(--radius);
  padding: 0 var(--space-sm);
  display: flex;
  align-items: center;
}

.signwrapper .input-group { display: flex; }
.signwrapper .input-group .form-control { border-radius: 0 var(--radius) var(--radius) 0; }

/* SSL note */
#ssl { color: var(--text-secondary) !important; font-size: var(--font-size-sm); }

/* ============================================
   CARDS PAGE — button consistency (golden-black)
   ============================================ */

/* search / clear */
.filter-actions .searchbtn {
  background: var(--primary) !important;
  color: #111 !important;
  border: 1px solid var(--primary) !important;
  border-radius: var(--radius) !important;
  padding: var(--space-sm) var(--space-lg) !important;
  font-weight: 600 !important;
}
.filter-actions .searchbtn:hover { background: var(--primary-light) !important; }

.filter-actions .clear-all {
  background: transparent !important;
  color: var(--text-secondary) !important;
  border: 1px solid var(--border-color) !important;
  border-radius: var(--radius) !important;
  padding: var(--space-sm) var(--space-lg) !important;
}
.filter-actions .clear-all:hover { border-color: var(--primary) !important; color: var(--primary) !important; }

/* quick filters — one quiet chip family, gold on hover */
.quick-filters .btn,
.quick-filters .quick-filter-btn {
  background: var(--bg-card) !important;
  color: var(--text-secondary) !important;
  border: 1px solid var(--border-color) !important;
  border-radius: var(--radius) !important;
  padding: var(--space-sm) var(--space) !important;
  font-weight: 500 !important;
  text-shadow: none !important;
  box-shadow: none !important;
}
.quick-filters .btn:hover,
.quick-filters .quick-filter-btn:hover {
  border-color: var(--primary) !important;
  color: var(--primary) !important;
  background: var(--bg-card) !important;
}

/* buy all selected — gold, rounded, confident */
.buy-all-bar button,
.buy-all-bar .btn-success {
  background: var(--primary) !important;
  color: #111 !important;
  border: 1px solid var(--primary) !important;
  border-radius: var(--radius) !important;
  padding: var(--space-sm) var(--space-xl) !important;
  font-weight: 700 !important;
  font-size: var(--font-size) !important;
}
.buy-all-bar button:hover { background: var(--primary-light) !important; }

/* ============================================
   ALERT CLOSE BUTTON — the ugly X
   ============================================ */
.alert { position: relative; }
.alert .close,
.alert button.close {
  position: absolute;
  top: var(--space-sm);
  right: var(--space-sm);
  background: transparent;
  border: none;
  color: inherit;
  opacity: 0.6;
  font-size: 1.1rem;
  line-height: 1;
  cursor: pointer;
  padding: 2px 6px;
  border-radius: var(--radius-sm);
}
.alert .close:hover { opacity: 1; background: rgba(0,0,0,0.25); }

/* ============================================
   SWEETALERT MODALS — register success, welcome
   ============================================ */
.sweet-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.65);
  z-index: 1000;
}

.sweet-alert {
  position: fixed !important;
  top: 50% !important;
  left: 50% !important;
  transform: translate(-50%, -50%) !important;
  margin-top: 0 !important;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xl);
  padding: var(--space-xl);
  max-width: 480px;
  width: calc(100% - 2 * var(--space));
  z-index: 1001;
  text-align: center;
  color: var(--text-secondary);
}

.sweet-alert h2, .sweet-alert h4 { color: var(--text-primary); margin-top: 0; }
.sweet-alert p { color: var(--text-secondary); }

.sweet-alert .sa-icon.sa-success {
  width: 80px;
  height: 80px;
  border: 4px solid var(--success);
  border-radius: 50%;
  margin: 0 auto var(--space);
  position: relative;
}
.sweet-alert .sa-icon.sa-success .sa-line,
.sweet-alert .sa-icon.sa-success .sa-placeholder,
.sweet-alert .sa-icon.sa-success .sa-fix { display: none; }
.sweet-alert .sa-icon.sa-success::after {
  content: "\2713";
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.5rem;
  color: var(--success);
}

.sweet-alert .sa-icon.sa-warning {
  width: 80px;
  height: 80px;
  border: 4px solid var(--warning);
  border-radius: 50%;
  margin: 0 auto var(--space);
  position: relative;
}
.sweet-alert .sa-icon.sa-warning .sa-body,
.sweet-alert .sa-icon.sa-warning .sa-dot { display: none; }
.sweet-alert .sa-icon.sa-warning::after {
  content: "!";
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--warning);
}

.sweet-alert .sa-confirm-button-container button,
.sweet-alert button.confirm {
  background: var(--primary) !important;
  color: #111 !important;
  border: none !important;
  border-radius: var(--radius) !important;
  padding: var(--space-sm) var(--space-xl) !important;
  font-weight: 600 !important;
  cursor: pointer;
  box-shadow: none !important;
}

/* ============================================
   GLOBAL BUTTON SYSTEM — GOLD
   Every button: solid gold fill, dark text.
   Hover: inverts to gold outline.
   Outline variants invert to solid on hover.
   ============================================ */
button,
.btn,
input[type="submit"],
input[type="button"],
a.btn {
  background: var(--primary) !important;
  color: #111 !important;
  border: 1px solid var(--primary) !important;
  border-radius: var(--radius) !important;
  padding: var(--space-sm) var(--space) !important;
  font-weight: 600 !important;
  text-shadow: none !important;
  box-shadow: none !important;
  cursor: pointer;
  transition: var(--transition) !important;
}

button:hover,
.btn:hover,
input[type="submit"]:hover,
input[type="button"]:hover,
a.btn:hover {
  background: transparent !important;
  color: var(--primary) !important;
  border-color: var(--primary) !important;
}

/* outline variants rest inverted, fill on hover */
.btn-outline,
.btn-stroke,
[class*="btn-stroke"] {
  background: transparent !important;
  color: var(--primary) !important;
  border: 1px solid var(--primary) !important;
}

.btn-outline:hover,
.btn-stroke:hover,
[class*="btn-stroke"]:hover {
  background: var(--primary) !important;
  color: #111 !important;
}

/* Gold for the stubborn specific buttons too */
.filter-actions .clear-all,
.quick-filters .btn,
.quick-filters .quick-filter-btn {
  background: var(--primary) !important;
  color: #111 !important;
  border: 1px solid var(--primary) !important;
}

.filter-actions .clear-all:hover,
.quick-filters .btn:hover,
.quick-filters .quick-filter-btn:hover {
  background: transparent !important;
  color: var(--primary) !important;
  border-color: var(--primary) !important;
}

/* ============================================
   CART — badge, flash, page
   ============================================ */
.cart-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  margin-left: var(--space-xs);
  background: var(--primary);
  color: #111;
  font-size: var(--font-size-xs);
  font-weight: 700;
  border-radius: var(--radius-full);
}

.cart-flash {
  position: fixed;
  bottom: var(--space-xl);
  left: 50%;
  transform: translateX(-50%);
  background: var(--bg-card);
  border: 1px solid var(--primary);
  color: var(--primary);
  padding: var(--space-sm) var(--space-lg);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  z-index: 1002;
  font-weight: 600;
  transition: opacity 0.4s;
}

/* ============================================
   SELECT2 — golden-black skin
   ============================================ */
.select2-container { width: 100% !important; }

.select2-container--default .select2-selection--single {
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  height: auto;
  min-height: 38px;
  padding: var(--space-xs) var(--space-sm);
  color: var(--text-primary);
  transition: var(--transition);
}

.select2-container--default .select2-selection--single .select2-selection__rendered {
  color: var(--text-primary);
  line-height: 1.6;
  padding-left: 0;
}

.select2-container--default .select2-selection--single .select2-selection__arrow {
  height: 100%;
  top: 50%;
  transform: translateY(-50%);
}

.select2-container--default .select2-selection--single .select2-selection__arrow b {
  border-color: var(--text-muted) transparent transparent transparent;
}

.select2-container--default.select2-container--open .select2-selection--single {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.2);
}

.select2-dropdown {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  z-index: 1003;
}

.select2-container--default .select2-results__option {
  color: var(--text-secondary);
  padding: var(--space-sm) var(--space);
  font-size: var(--font-size-sm);
}

.select2-container--default .select2-results__option--highlighted.select2-results__option--selectable {
  background: var(--primary);
  color: #111;
}

.select2-container--default .select2-results__option--selected {
  background: var(--bg-hover);
  color: var(--primary);
}

.select2-container--default .select2-search--dropdown .select2-search__field {
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  padding: var(--space-sm);
  outline: none;
}

.select2-container--default .select2-search--dropdown .select2-search__field:focus {
  border-color: var(--primary);
}

/* select2 base — hide the original select properly */
.select2-hidden-accessible {
  border: 0 !important;
  clip: rect(0 0 0 0) !important;
  -webkit-clip-path: inset(50%) !important;
  clip-path: inset(50%) !important;
  height: 1px !important;
  overflow: hidden !important;
  padding: 0 !important;
  position: absolute !important;
  white-space: nowrap !important;
  width: 1px !important;
}

/* ============================================
   SELECT2 — dropdown mechanics + bigger + multi
   ============================================ */
.select2-dropdown {
  position: absolute;
  top: 0;
  left: 0;
  display: block;
  box-sizing: border-box;
  width: 100%;
  min-width: 220px;
}

.select2-search--dropdown { display: block; padding: var(--space-sm); }
.select2-results { display: block; }
.select2-results__options {
  list-style: none;
  margin: 0;
  padding: 0;
  max-height: 280px;
  overflow-y: auto;
}
.select2-results__option { user-select: none; cursor: pointer; }
.select2-results__message { color: var(--text-muted); padding: var(--space-sm) var(--space); }

/* bigger filters */
.select2-container--default .select2-selection--single,
.select2-container--default .select2-selection--multiple {
  min-height: 44px;
  font-size: 0.95rem;
  display: flex;
  align-items: center;
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
}

/* multi-select pills */
.select2-container--default .select2-selection--multiple {
  padding: var(--space-xs) var(--space-sm);
  cursor: text;
}

.select2-container--default .select2-selection--multiple .select2-selection__rendered {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-xs);
  list-style: none;
  margin: 0;
  padding: 0;
}

.select2-container--default .select2-selection--multiple .select2-selection__choice {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  background: var(--primary);
  color: #111;
  border: none;
  border-radius: var(--radius-sm);
  padding: 2px var(--space-sm);
  font-size: var(--font-size-sm);
  font-weight: 600;
}

.select2-container--default .select2-selection--multiple .select2-selection__choice__remove {
  color: #111;
  font-weight: 700;
  cursor: pointer;
  margin-left: 2px;
}

.select2-container--default .select2-selection--multiple .select2-search--inline {
  display: inline-flex;
}

.select2-container--default .select2-selection--multiple .select2-search__field {
  background: transparent;
  border: none;
  outline: none;
  color: var(--text-primary);
  font-family: inherit;
  font-size: 0.95rem;
  min-width: 60px;
}

/* select2 multi — full placeholder room, wider filter cells */
.filter-panel { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
.select2-container--default .select2-selection--multiple .select2-search__field { min-width: 120px; }

/* Ticket subject line */
.ticket-subject {
  color: var(--text-secondary);
  font-size: var(--font-size);
  margin-bottom: var(--space-sm);
}
.ticket-subject strong { color: var(--text-primary); }

/* Ticket textareas — dark themed */
.ticket-wrap textarea {
  background: var(--bg-input) !important;
  border: 1px solid var(--border-color) !important;
  border-radius: var(--radius) !important;
  color: var(--text-primary) !important;
  padding: var(--space) !important;
  font-family: inherit !important;
  font-size: var(--font-size) !important;
  width: 100% !important;
  box-sizing: border-box;
}
.ticket-wrap textarea:focus {
  border-color: var(--primary) !important;
  outline: none !important;
  box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.2) !important;
}
.ticket-wrap textarea::placeholder { color: var(--text-muted); }

/* Cart toggle state — in-cart buttons go outline gold */
.add-cart-btn.in-cart {
  background: transparent !important;
  color: var(--primary) !important;
  border: 1px solid var(--primary) !important;
}
.add-cart-btn.in-cart:hover {
  background: var(--primary) !important;
  color: #111 !important;
}

/* ============================================
   CHECK COLUMN — status button states
   VALID solid gold, Invalid inverse, TIME OUT muted
   ============================================ */

/* VALID — solid gold (global rule already; restated for clarity) */
#carddatatable .btn-success {
  background: var(--primary) !important;
  color: #111 !important;
  border: 1px solid var(--primary) !important;
}

/* Invalid Card — danger: dead card, red identity */
#carddatatable .btn-default {
  background: rgba(239, 68, 68, 0.15) !important;
  color: var(--danger) !important;
  border: 1px solid var(--danger) !important;
}
#carddatatable .btn-default:hover {
  background: var(--danger) !important;
  color: #fff !important;
}

/* TIME OUT / Expired / NOT DEFINED — distinct: muted dead state */
#carddatatable .btn-danger {
  background: #232323 !important;
  color: #6b7280 !important;
  border: 1px solid #3a3a3a !important;
  text-decoration: line-through;
  cursor: default;
}
#carddatatable .btn-danger:hover {
  background: #232323 !important;
  color: #6b7280 !important;
  border-color: #3a3a3a !important;
}

/* REFUNDED / FORMAT ERROR / Manual Refund — inverse: gold outline */
#carddatatable .btn-warning {
  background: transparent !important;
  color: var(--primary) !important;
  border: 1px solid var(--primary) !important;
}
#carddatatable .btn-warning:hover {
  background: var(--primary) !important;
  color: #111 !important;
}

/* status labels are not actions — no pointer games */
#carddatatable td button[type="button"] { cursor: default; }

/* ============================================
   FRONTEND — status buttons (CHECK column)
   ============================================ */
.status-btn {
  display: inline-block;
  padding: 4px 12px;
  border-radius: var(--radius);
  font-size: var(--font-size-xs);
  font-weight: 600;
  white-space: nowrap;
}
.status-valid {
  background: var(--primary);
  color: #111;
  border: 1px solid var(--primary);
}
.status-refunded {
  background: transparent;
  color: var(--primary);
  border: 1px solid var(--primary);
}
.status-invalid {
  background: rgba(239, 68, 68, 0.15);
  color: var(--danger);
  border: 1px solid var(--danger);
}
.status-timeout {
  background: #232323;
  color: #6b7280;
  border: 1px solid #3a3a3a;
  text-decoration: line-through;
}

/* filter zone — plain block wrapper (not a grid, so children stack vertically) */
.filter-zone {
  display: block;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: var(--space);
  margin-bottom: var(--space);
}
.filter-zone .filter-panel {
  background: transparent;
  border: none;
  padding: 0;
  margin-bottom: var(--space);
}


/* brand wordmark: fancy era face ONLY here */
.wordmark-fancy, .lupin-wordmark {
  font-family: system-ui, -apple-system, sans-serif;
  font-weight: 700;
  letter-spacing: 6px;
}
.wordmark-fancy .accent, .lupin-wordmark .accent { color: #d0a832; }


/* brand wordmark ONLY */
.lupin-wordmark,
.wordmark-fancy,
.shop-logo .shop-name {
  font-family: 'Cinzel Decorative', 'Times New Roman', serif !important;
}

/* ---------- Purchased wide-table fit (16 cols, no horizontal scroller) ---------- */
#tab-content .table th,
#tab-content .table td {
  padding: 8px 6px;
  font-size: 12px;
  white-space: normal;
  word-break: break-word;
}
#tab-content .table th {
  white-space: nowrap;
}
#tab-content .table td:first-child,
#tab-content .table th:first-child {
  width: 28px;
  padding: 8px 4px;
}

/* login-view mobile fit ? scoped to body.on-login (applies on any viewport) [LO 2026-10-28] */
body.on-login .header-content,
body.on-login .header { padding: var(--space-sm); }
body.on-login .auth-card, body.on-login .login-card, body.on-login [class*="auth"] {
  max-width: 480px !important;
  width: calc(100% - 24px);
}
body.on-login input, body.on-login select, body.on-login textarea, body.on-login .form-control {
  min-height: 44px;
  font-size: 16px; /* kills iOS auto-zoom */
}
body.on-login .btn, body.on-login button { min-height: 44px; font-size: 15px; }
body.on-login .nav a { padding: 8px 12px; }
body.on-login .card { padding: var(--space); }
