/* ==========================================================================
   ULTRA MODERN & LUXURIOUS VIBRANT ENHANCEMENT SYSTEM (2026 EDITION)
   Adds High-End Visual Beauty, Glassmorphism, Micro-Animations & Sleek Cards
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:ital,wght@0,300;0,400;0,500;0,600;0,700;0,800;1,400;1,600&family=Inter:wght@400;500;600;700&display=swap');

:root {
  --modern-font: 'Plus Jakarta Sans', 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --primary-indigo: #6366f1;
  --primary-violet: #8b5cf6;
  --primary-gradient: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
  --success-gradient: linear-gradient(135deg, #10b981 0%, #059669 100%);
  --danger-gradient: linear-gradient(135deg, #f43f5e 0%, #e11d48 100%);
  --warning-gradient: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  --glass-light: rgba(255, 255, 255, 0.95);
  --glass-dark: rgba(15, 23, 42, 0.85);
  --card-radius: 16px;
  --input-radius: 12px;
  --btn-radius: 12px;
}

/* --- 1. GLOBAL TYPOGRAPHY BEAUTIFICATION ("SUFOCHUN") --- */
body, html {
  font-family: var(--modern-font) !important;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  color: #1e293b;
}

body.dark {
  color: #f1f5f9 !important;
  background-color: #0b0f19 !important;
}

/* Heading Typography & Gradient Accents */
h1, h2, h3, h4, h5, h6,
.h1, .h2, .h3, .h4, .h5, .h6,
.page-title, .card-title, .product-title {
  font-family: var(--modern-font) !important;
  font-weight: 700 !important;
  letter-spacing: -0.02em !important;
}

.page-title {
  font-size: 1.85rem !important;
  font-weight: 800 !important;
  background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 1.25rem !important;
}

body.dark .page-title {
  background: linear-gradient(135deg, #ffffff 0%, #a5b4fc 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* --- 2. GLASSMORPHIC CARDS & CONTAINER BOXES ("BOX SOCHUN") --- */
.card, 
.card-product, 
.card-group, 
.card-search,
.box, 
.panel, 
.content-box,
.card-retail-order,
.header-cart,
.inner-container,
.well,
.thumbnail {
  border-radius: var(--card-radius) !important;
  border: 1px solid rgba(226, 232, 240, 0.9) !important;
  box-shadow: 0 10px 30px -5px rgba(0, 0, 0, 0.07), 0 4px 12px -2px rgba(0, 0, 0, 0.03) !important;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.3s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.3s ease !important;
  background: #ffffff;
  overflow: hidden;
}

/* Light Mode Glassmorphism */
body:not(.dark) .card,
body:not(.dark) .card-product,
body:not(.dark) .box,
body:not(.dark) .panel {
  background: rgba(255, 255, 255, 0.96) !important;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

/* Dark Mode Glassmorphism */
body.dark .card,
body.dark .card-product,
body.dark .box,
body.dark .panel,
body.dark .header-cart {
  background: rgba(15, 23, 42, 0.85) !important;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-color: rgba(255, 255, 255, 0.1) !important;
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.45) !important;
}

/* Card Hover Micro-Animations */
.card:hover,
.card-product:hover,
.box:hover,
.panel:hover {
  transform: translateY(-4px) scale(1.005) !important;
  box-shadow: 0 20px 40px -10px rgba(99, 102, 241, 0.22), 0 8px 16px -4px rgba(0, 0, 0, 0.06) !important;
  border-color: rgba(99, 102, 241, 0.45) !important;
}

.card-header, .panel-heading {
  background: transparent !important;
  border-bottom: 1px solid rgba(226, 232, 240, 0.8) !important;
  padding: 1.25rem 1.5rem !important;
  font-weight: 700 !important;
}

body.dark .card-header, body.dark .panel-heading {
  border-bottom-color: rgba(255, 255, 255, 0.1) !important;
}

/* --- 3. INPUT BOXES & FORM CONTROLS --- */
.form-control,
input[type="text"],
input[type="password"],
input[type="email"],
input[type="number"],
input[type="search"],
select,
textarea {
  border-radius: var(--input-radius) !important;
  border: 1.5px solid #cbd5e1 !important;
  padding: 0.65rem 1.1rem !important;
  font-size: 0.95rem !important;
  background-color: #f8fafc !important;
  transition: all 0.25s ease !important;
  box-shadow: none !important;
}

body.dark .form-control,
body.dark input[type="text"],
body.dark input[type="password"],
body.dark input[type="email"],
body.dark input[type="number"],
body.dark input[type="search"],
body.dark select,
body.dark textarea {
  background-color: rgba(30, 41, 59, 0.85) !important;
  border-color: rgba(255, 255, 255, 0.15) !important;
  color: #f8fafc !important;
}

.form-control:focus,
input:focus,
select:focus,
textarea:focus {
  border-color: var(--primary-indigo) !important;
  background-color: #ffffff !important;
  box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.2) !important;
  outline: none !important;
}

body.dark .form-control:focus,
body.dark input:focus,
body.dark select:focus,
body.dark textarea:focus {
  background-color: rgba(15, 23, 42, 0.95) !important;
  box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.35) !important;
}

/* --- 4. GRADIENT BUTTONS WITH GLOW & MOTION --- */
.btn, button, input[type="submit"], input[type="button"] {
  border-radius: var(--btn-radius) !important;
  font-weight: 600 !important;
  padding: 0.65rem 1.4rem !important;
  letter-spacing: -0.01em !important;
  transition: all 0.25s ease !important;
  border: none !important;
  cursor: pointer !important;
}

.btn-primary, button.btn-primary, input[type="submit"].btn-primary {
  background: var(--primary-gradient) !important;
  color: #ffffff !important;
  box-shadow: 0 4px 15px rgba(99, 102, 241, 0.35) !important;
}

.btn-primary:hover, button.btn-primary:hover {
  transform: translateY(-2px) !important;
  box-shadow: 0 8px 24px rgba(99, 102, 241, 0.5) !important;
  color: #ffffff !important;
}

.btn-success, button.btn-success {
  background: var(--success-gradient) !important;
  color: #ffffff !important;
  box-shadow: 0 4px 15px rgba(16, 185, 129, 0.35) !important;
}

.btn-success:hover, button.btn-success:hover {
  transform: translateY(-2px) !important;
  box-shadow: 0 8px 24px rgba(16, 185, 129, 0.5) !important;
}

.btn-danger, button.btn-danger {
  background: var(--danger-gradient) !important;
  color: #ffffff !important;
  box-shadow: 0 4px 15px rgba(244, 63, 94, 0.35) !important;
}

.btn-danger:hover, button.btn-danger:hover {
  transform: translateY(-2px) !important;
  box-shadow: 0 8px 24px rgba(244, 63, 94, 0.5) !important;
}

.btn:active, button:active {
  transform: scale(0.98) !important;
}

/* --- 5. TABLES BEAUTIFICATION --- */
table, .table {
  border-collapse: separate !important;
  border-spacing: 0 6px !important;
}

.table th {
  font-weight: 700 !important;
  text-transform: uppercase !important;
  font-size: 0.775rem !important;
  letter-spacing: 0.05em !important;
  color: #64748b !important;
  padding: 1rem 1.25rem !important;
}

body.dark .table th {
  color: #94a3b8 !important;
}

.table td {
  padding: 1rem 1.25rem !important;
  vertical-align: middle !important;
  background: #ffffff !important;
  transition: background 0.2s ease !important;
}

.table tr td:first-child {
  border-top-left-radius: 12px !important;
  border-bottom-left-radius: 12px !important;
}

.table tr td:last-child {
  border-top-right-radius: 12px !important;
  border-bottom-right-radius: 12px !important;
}

body.dark .table td {
  background: rgba(30, 41, 59, 0.65) !important;
}

.table tbody tr:hover td {
  background: rgba(99, 102, 241, 0.08) !important;
}

/* --- 6. BADGES, CHIPS & BALANCE --- */
.badge, .label {
  padding: 0.4em 0.9em !important;
  border-radius: 50px !important;
  font-weight: 600 !important;
  font-size: 0.775rem !important;
}

.badge-primary, .badge-info {
  background: rgba(99, 102, 241, 0.15) !important;
  color: #4f46e5 !important;
}

.badge-success {
  background: rgba(16, 185, 129, 0.15) !important;
  color: #059669 !important;
}

.user-balance {
  padding: 0.4rem 1rem !important;
  border-radius: 50px !important;
  font-weight: 700 !important;
  background: rgba(16, 185, 129, 0.12) !important;
}

.user-balance.text-success {
  color: #10b981 !important;
}

.user-balance.text-danger {
  color: #f43f5e !important;
}
