:root {
  --theme-accent: #8b5cf6;
  --theme-accent-glow: rgba(139, 92, 246, 0.35);
  --theme-accent-hover: #7c3aed;
  --bg-base: #0a0d14;
  --card-bg: rgba(17, 24, 39, 0.75);
  --border-color: rgba(255, 255, 255, 0.08);

  /* Atmospheric Bottom Ambient Glow */
  --bottom-accent-color: #8b5cf6;
  --bottom-accent-glow: rgba(139, 92, 246, 0.45);
  --bottom-accent-subtle: rgba(139, 92, 246, 0.12);
}

body {
  background-color: var(--bg-base);
  color: #f3f4f6;
  font-family: 'Inter', 'Cairo', -apple-system, BlinkMacSystemFont, sans-serif;
  overflow-x: hidden;
}

/* Custom Scrollbars */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
::-webkit-scrollbar-track {
  background: rgba(10, 13, 20, 0.8);
}
::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.18);
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--theme-accent);
}

/* Dynamic Accent Utilities */
.accent-bg {
  background-color: var(--theme-accent) !important;
}
.accent-text {
  color: var(--theme-accent) !important;
}
.accent-border {
  border-color: var(--theme-accent) !important;
}
.accent-glow {
  box-shadow: 0 0 25px var(--theme-accent-glow);
}
.accent-hover:hover {
  background-color: var(--theme-accent-hover) !important;
}

/* Glassmorphism & 3D Spatial Containers */
.glass-panel {
  background: var(--card-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border-color);
  box-shadow: inset 0 1px 1px 0 rgba(255, 255, 255, 0.08), 0 12px 30px -8px rgba(0, 0, 0, 0.65);
}

.glass-card {
  background: rgba(20, 29, 47, 0.68);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: inset 0 1px 1px 0 rgba(255, 255, 255, 0.12), 0 10px 24px -6px rgba(0, 0, 0, 0.65);
  transform-style: preserve-3d;
  transition: transform 0.26s cubic-bezier(0.34, 1.56, 0.64, 1),
              box-shadow 0.26s cubic-bezier(0.34, 1.56, 0.64, 1),
              border-color 0.22s ease;
}

.glass-card:hover {
  border-color: rgba(168, 85, 247, 0.35);
  transform: translateY(-4px) translateZ(8px);
  box-shadow: inset 0 1px 2px 0 rgba(255, 255, 255, 0.2),
              0 20px 38px -8px rgba(0, 0, 0, 0.8),
              0 0 20px rgba(168, 85, 247, 0.18);
}

/* Tactical HUD Hero Banner */
.hud-banner-glass {
  background: linear-gradient(135deg, rgba(24, 18, 43, 0.8) 0%, rgba(13, 17, 28, 0.9) 100%);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-radius: 1.5rem;
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: inset 0 1px 1px 0 rgba(255, 255, 255, 0.15), 0 16px 40px -10px rgba(0, 0, 0, 0.75);
  transform-style: preserve-3d;
}

/* Checkmarks pill styling */
.check-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 2px 8px;
  border-radius: 9999px;
  background: rgba(16, 185, 129, 0.18);
  color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.35);
  font-weight: 700;
  letter-spacing: 2px;
}

/* Button glow and transitions */
.btn-action {
  transition: all 0.2s ease-in-out;
}
.btn-action:active {
  transform: scale(0.95);
}

/* Animation utilities */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

.animate-fade-in {
  animation: fadeIn 0.25s ease-out forwards;
}

/* Badges for Ranking #1, #2, #3 */
.rank-badge-gold {
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: #000;
  font-weight: 900;
  box-shadow: 0 0 12px rgba(245, 158, 11, 0.4);
}
.rank-badge-silver {
  background: linear-gradient(135deg, #cbd5e1, #94a3b8);
  color: #0f172a;
  font-weight: 900;
  box-shadow: 0 0 10px rgba(203, 213, 225, 0.3);
}
.rank-badge-bronze {
  background: linear-gradient(135deg, #b45309, #78350f);
  color: #fff;
  font-weight: 900;
  box-shadow: 0 0 10px rgba(180, 83, 9, 0.3);
}
.rank-badge-default {
  background: rgba(255, 255, 255, 0.08);
  color: #94a3b8;
  font-weight: 700;
}

/* Atmospheric Bottom Ambient Glow */
.gang-bottom-glow-ambient {
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 90% 70% at 50% 100%, var(--bottom-accent-glow, rgba(139, 92, 246, 0.45)) 0%, var(--bottom-accent-subtle, rgba(139, 92, 246, 0.12)) 45%, transparent 75%);
  filter: blur(24px);
  -webkit-filter: blur(24px);
  animation: atmosphericGlowBreath 6s ease-in-out infinite alternate;
  pointer-events: none;
  transform-origin: bottom center;
}

@keyframes atmosphericGlowBreath {
  0% {
    opacity: 0.45;
    transform: scaleY(0.9) scaleX(0.96);
  }
  50% {
    opacity: 0.75;
    transform: scaleY(1.02) scaleX(1.01);
  }
  100% {
    opacity: 0.95;
    transform: scaleY(1.1) scaleX(1.04);
  }
}


.custom-scroll::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
.custom-scroll::-webkit-scrollbar-track {
  background: rgba(10, 13, 20, 0.4);
}
.custom-scroll::-webkit-scrollbar-thumb {
  background: rgba(139, 92, 246, 0.3);
  border-radius: 4px;
}
.custom-scroll::-webkit-scrollbar-thumb:hover {
  background: rgba(139, 92, 246, 0.6);
}

/* ========================================================================= */
/* FUTURISTIC FLOATING COMMAND BAR & MODERN MENUS                            */
/* ========================================================================= */

.floating-command-header {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.command-bar-shell {
  background: rgba(13, 17, 26, 0.85);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 10px 40px -10px rgba(0, 0, 0, 0.7), 0 0 20px -5px var(--theme-accent-glow);
  transition: all 0.3s ease;
}

.command-bar-shell:hover {
  border-color: rgba(255, 255, 255, 0.18);
  box-shadow: 0 14px 45px -10px rgba(0, 0, 0, 0.8), 0 0 25px -4px var(--theme-accent-glow);
}

/* Nav Track Capsule */
.nav-track-capsule {
  background: rgba(6, 9, 15, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(12px);
}

/* Modern Nav Item */
.nav-link-modern {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.9rem;
  border-radius: 0.9rem;
  font-size: 0.8rem;
  font-weight: 700;
  color: #94a3b8;
  border: 1px solid transparent;
  transition: all 0.22s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
  user-select: none;
}

.nav-link-modern:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.07);
  border-color: rgba(255, 255, 255, 0.1);
  transform: translateY(-1px);
}

.nav-link-modern.active-nav {
  color: #ffffff;
  background: linear-gradient(135deg, rgba(139, 92, 246, 0.95), rgba(99, 102, 241, 0.95));
  border-color: rgba(167, 139, 250, 0.6);
  box-shadow: 0 4px 18px rgba(139, 92, 246, 0.4), inset 0 1px 1px rgba(255, 255, 255, 0.3);
  transform: translateY(-1px);
}

.nav-link-modern .nav-icon-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 1.6rem;
  height: 1.6rem;
  border-radius: 0.6rem;
  background: rgba(255, 255, 255, 0.06);
  transition: all 0.2s ease;
  font-size: 0.75rem;
}

.nav-link-modern:hover .nav-icon-badge {
  background: rgba(255, 255, 255, 0.15);
  transform: scale(1.08);
}

.nav-link-modern.active-nav .nav-icon-badge {
  background: rgba(255, 255, 255, 0.22);
  color: #ffffff;
  box-shadow: 0 0 10px rgba(255, 255, 255, 0.4);
}

/* Subtle Active Dot Indicator */
.nav-link-modern.active-nav::after {
  content: '';
  position: absolute;
  bottom: -3px;
  left: 50%;
  transform: translateX(-50%);
  width: 16px;
  height: 2.5px;
  border-radius: 9999px;
  background: #ffffff;
  box-shadow: 0 0 8px #ffffff;
}

/* AI Scanner Shimmer Button */
.btn-ai-glow {
  background: linear-gradient(135deg, #9333ea, #6366f1 50%, #ec4899);
  background-size: 200% 200%;
  animation: gradientShift 4s ease infinite;
  box-shadow: 0 4px 20px rgba(147, 51, 234, 0.45);
}

@keyframes gradientShift {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

/* Modern Tab Segmented Controller */
.tab-segmented-track {
  background: rgba(10, 13, 20, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 1.1rem;
  padding: 0.35rem;
  box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.6);
  display: inline-flex;
  gap: 0.35rem;
  backdrop-filter: blur(16px);
}

.tab-segmented-btn {
  padding: 0.6rem 1.15rem;
  border-radius: 0.85rem;
  font-size: 0.78rem;
  font-weight: 800;
  color: #94a3b8;
  border: 1px solid transparent;
  transition: all 0.22s cubic-bezier(0.4, 0, 0.2, 1);
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  user-select: none;
}

.tab-segmented-btn:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.06);
}

.tab-segmented-btn.active {
  background: linear-gradient(135deg, var(--theme-accent), var(--theme-accent-hover));
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.2);
  box-shadow: 0 4px 16px var(--theme-accent-glow);
}

/* Mobile Drawer Luxury Styling */
.mobile-drawer-glass {
  background: rgba(10, 13, 20, 0.96);
  backdrop-filter: blur(28px);
  -webkit-backdrop-filter: blur(28px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.8);
  border-radius: 1.5rem;
}

.mobile-nav-item {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.85rem 1rem;
  border-radius: 1rem;
  font-size: 0.875rem;
  font-weight: 700;
  color: #cbd5e1;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.05);
  transition: all 0.2s ease;
  width: 100%;
  text-align: right;
  cursor: pointer;
}

.mobile-nav-item:hover, .mobile-nav-item.active-nav {
  background: rgba(139, 92, 246, 0.15);
  border-color: rgba(139, 92, 246, 0.4);
  color: #ffffff;
  transform: translateX(-3px);
}

.mobile-nav-item.active-nav {
  background: linear-gradient(135deg, rgba(139, 92, 246, 0.28), rgba(99, 102, 241, 0.28));
  border-color: rgba(167, 139, 250, 0.5);
  box-shadow: 0 4px 15px rgba(139, 92, 246, 0.2);
}

/* ========================================================================= */
/* CYBER-OBSIDIAN SYNDICATE HUD & TACTICAL CARDS                             */
/* ========================================================================= */

/* Atmospheric Ambient Background Grid */
.cyber-bg-mesh {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background-image: 
    radial-gradient(circle at 50% 0%, rgba(139, 92, 246, 0.15) 0%, transparent 55%),
    radial-gradient(circle at 90% 30%, rgba(99, 102, 241, 0.1) 0%, transparent 45%),
    radial-gradient(circle at 10% 75%, rgba(220, 38, 38, 0.08) 0%, transparent 50%),
    linear-gradient(to right, rgba(255, 255, 255, 0.025) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255, 255, 255, 0.025) 1px, transparent 1px);
  background-size: 100% 100%, 100% 100%, 100% 100%, 40px 40px, 40px 40px;
}

/* Tactical KPI Cards with Luminous Top Edge */
.tactical-kpi-card {
  position: relative;
  background: rgba(14, 19, 31, 0.78);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 1.25rem;
  padding: 1.5rem;
  overflow: hidden;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 8px 30px -8px rgba(0, 0, 0, 0.65), inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.tactical-kpi-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--kpi-accent, var(--theme-accent)), transparent);
  opacity: 0.85;
  transition: opacity 0.3s ease;
}

.tactical-kpi-card:hover {
  transform: translateY(-3px);
  border-color: rgba(255, 255, 255, 0.18);
  box-shadow: 0 16px 45px -10px rgba(0, 0, 0, 0.85), 0 0 25px -4px var(--theme-accent-glow);
}

.tactical-kpi-card:hover::before {
  opacity: 1;
}

/* Tactical Section Header */
.tactical-header-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.25rem 0.75rem;
  border-radius: 0.5rem;
  font-size: 0.7rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  background: rgba(139, 92, 246, 0.12);
  color: #c4b5fd;
  border: 1px solid rgba(139, 92, 246, 0.3);
}

/* Glowing Pulsing Status Dots */
.status-dot-live {
  width: 7px;
  height: 7px;
  border-radius: 9999px;
  background-color: #10b981;
  box-shadow: 0 0 10px #10b981;
  animation: pulseLive 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

@keyframes pulseLive {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(0.85); }
}

/* Tactical Banner Glass with Tech Corner Frame */
.hud-banner-glass {
  position: relative;
  background: linear-gradient(135deg, rgba(20, 27, 45, 0.85) 0%, rgba(10, 13, 22, 0.95) 100%);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 1.5rem;
  box-shadow: 0 20px 50px -15px rgba(0, 0, 0, 0.8), inset 0 1px 0 rgba(255, 255, 255, 0.15);
  overflow: hidden;
}

.hud-banner-glass::after {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  width: 60px;
  height: 60px;
  background: linear-gradient(135deg, transparent 50%, rgba(139, 92, 246, 0.2) 100%);
  pointer-events: none;
}

/* =========================================================================
   3D TACTICAL SIDE DECK (MODAL DOCKED TO SIDE WITH 3D PERSPECTIVE)
   ========================================================================= */
.modal-deck-backdrop {
  position: fixed;
  inset: 0;
  z-index: 60;
  background: radial-gradient(circle at center, rgba(8, 12, 24, 0.72) 0%, rgba(2, 3, 7, 0.9) 100%);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  display: flex;
  overflow: hidden;
  perspective: 1600px;
  transform-style: preserve-3d;
  transition: opacity 0.3s ease;
}

/* Default Right Dock */
.modal-deck-backdrop.dock-right {
  justify-content: flex-end;
  align-items: stretch;
}

/* Left Dock */
.modal-deck-backdrop.dock-left {
  justify-content: flex-start;
  align-items: stretch;
}

/* The 3D Tactical Deck Card */
.deck-3d-card {
  position: relative;
  width: 100%;
  max-width: 520px;
  height: calc(100vh - 2rem);
  margin: 1rem;
  background: linear-gradient(155deg, rgba(20, 26, 46, 0.97) 0%, rgba(11, 15, 27, 0.99) 55%, rgba(6, 8, 16, 1) 100%);
  backdrop-filter: blur(32px);
  -webkit-backdrop-filter: blur(32px);
  border-radius: 1.75rem;
  border: 1px solid rgba(255, 255, 255, 0.14);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transition: transform 0.45s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.45s ease;
  transform-style: preserve-3d;
}

/* 3D Isometric Tilt when docked on Right */
.dock-right .deck-3d-card {
  transform: rotateY(-5deg) rotateX(1.5deg) translateZ(12px);
  box-shadow: 
    -25px 30px 70px -10px rgba(0, 0, 0, 0.95),
    -10px 10px 35px rgba(168, 85, 247, 0.22),
    0 0 0 1px rgba(255, 255, 255, 0.12),
    inset 0 2px 2px rgba(255, 255, 255, 0.35),
    inset 2px 0 3px rgba(255, 255, 255, 0.12),
    inset 0 -4px 10px rgba(0, 0, 0, 0.9);
  animation: slideInDeckRight 0.42s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

/* 3D Isometric Tilt when docked on Left */
.dock-left .deck-3d-card {
  transform: rotateY(5deg) rotateX(1.5deg) translateZ(12px);
  box-shadow: 
    25px 30px 70px -10px rgba(0, 0, 0, 0.95),
    10px 10px 35px rgba(168, 85, 247, 0.22),
    0 0 0 1px rgba(255, 255, 255, 0.12),
    inset 0 2px 2px rgba(255, 255, 255, 0.35),
    inset -2px 0 3px rgba(255, 255, 255, 0.12),
    inset 0 -4px 10px rgba(0, 0, 0, 0.9);
  animation: slideInDeckLeft 0.42s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.dock-right .deck-3d-card:hover,
.dock-left .deck-3d-card:hover {
  transform: rotateY(0deg) rotateX(0deg) translateZ(26px);
  box-shadow: 
    0 35px 80px -12px rgba(0, 0, 0, 0.98),
    0 0 50px rgba(168, 85, 247, 0.35),
    0 0 0 1px rgba(255, 255, 255, 0.22),
    inset 0 2px 4px rgba(255, 255, 255, 0.4);
}

@keyframes slideInDeckRight {
  from {
    opacity: 0;
    transform: translateX(120px) rotateY(-20deg) scale(0.9);
  }
  to {
    opacity: 1;
    transform: rotateY(-5deg) rotateX(1.5deg) translateZ(12px);
  }
}

@keyframes slideInDeckLeft {
  from {
    opacity: 0;
    transform: translateX(-120px) rotateY(20deg) scale(0.9);
  }
  to {
    opacity: 1;
    transform: rotateY(5deg) rotateX(1.5deg) translateZ(12px);
  }
}

/* Luminous Bevel along top rim */
.deck-3d-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, #ec4899, #a855f7 45%, #06b6d4 100%);
  box-shadow: 0 0 15px rgba(168, 85, 247, 0.85);
  z-index: 20;
}

/* 3D Laser Side Accent Stripe */
.deck-3d-accent-edge {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 4px;
  background: linear-gradient(180deg, #a855f7 0%, #6366f1 50%, transparent 100%);
  box-shadow: 0 0 12px rgba(168, 85, 247, 0.7);
  z-index: 15;
}
.dock-right .deck-3d-accent-edge { left: 0; }
.dock-left .deck-3d-accent-edge { right: 0; }

/* ========================================================
   1. 3D RECESSED INPUT FIELDS & CONTROLS
   ======================================================== */
.input-3d-recessed,
input[type="text"]:not(.raw-input),
input[type="number"]:not(.raw-input),
input[type="password"]:not(.raw-input),
input[type="date"]:not(.raw-input),
input[type="search"]:not(.raw-input),
select:not(.raw-input),
textarea:not(.raw-input) {
  background: #080a14 !important;
  border: 1px solid rgba(255, 255, 255, 0.12) !important;
  border-radius: 0.875rem !important;
  box-shadow: inset 0 2px 5px rgba(0, 0, 0, 0.8), 0 1px 0 rgba(255, 255, 255, 0.08) !important;
  color: #fff !important;
  transition: all 0.22s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.input-3d-recessed:focus,
input[type="text"]:not(.raw-input):focus,
input[type="number"]:not(.raw-input):focus,
input[type="password"]:not(.raw-input):focus,
input[type="date"]:not(.raw-input):focus,
input[type="search"]:not(.raw-input):focus,
select:not(.raw-input):focus,
textarea:not(.raw-input):focus {
  border-color: #a855f7 !important;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.6), 0 0 18px rgba(168, 85, 247, 0.45), 0 1px 0 rgba(255, 255, 255, 0.15) !important;
  transform: translateY(-1.5px);
}

/* ========================================================
   2. GLOBAL 3D TACTILE BUTTONS & MICRO-PHYSICS
   ======================================================== */
button:not(.carousel-arrow) {
  position: relative;
  transform-style: preserve-3d;
  transition: transform 0.16s cubic-bezier(0.34, 1.56, 0.64, 1),
              box-shadow 0.16s cubic-bezier(0.34, 1.56, 0.64, 1),
              filter 0.18s ease,
              background-color 0.2s ease,
              border-color 0.2s ease;
  will-change: transform, box-shadow;
}

/* Universal hover lift */
button:not(.nav-link-modern):not(.mobile-nav-item):not(.carousel-arrow):not(:disabled):hover {
  transform: translateY(-2px) translateZ(6px);
  filter: brightness(1.08);
}

/* Universal 3D tactile push-down click */
button:not(.carousel-arrow):not(:disabled):active {
  transform: translateY(3px) scale(0.975) !important;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.7) !important;
  filter: brightness(0.95);
  transition-duration: 0.05s !important;
}

/* Primary / Purple / Indigo 3D Shelf Buttons */
.btn-3d-primary,
button[class*="from-purple-600"],
button[class*="from-indigo-600"],
button[class*="bg-purple-600"],
button[class*="bg-indigo-600"],
button.accent-bg {
  position: relative;
  border-radius: 0.875rem;
  box-shadow: 0 4px 0 #4c1d95, 0 10px 22px rgba(147, 51, 234, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.25) !important;
}
.btn-3d-primary:hover,
button[class*="from-purple-600"]:hover,
button[class*="from-indigo-600"]:hover,
button[class*="bg-purple-600"]:hover,
button[class*="bg-indigo-600"]:hover,
button.accent-bg:hover {
  transform: translateY(-2.5px) translateZ(8px);
  box-shadow: 0 6px 0 #4c1d95, 0 16px 28px rgba(147, 51, 234, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.35) !important;
}
.btn-3d-primary:active,
button[class*="from-purple-600"]:active,
button[class*="from-indigo-600"]:active,
button[class*="bg-purple-600"]:active,
button[class*="bg-indigo-600"]:active,
button.accent-bg:active {
  transform: translateY(3px) scale(0.975) !important;
  box-shadow: 0 1px 0 #4c1d95, 0 3px 8px rgba(147, 51, 234, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.1) !important;
}

/* Red / Danger 3D Shelf Buttons */
button[class*="from-red-600"],
button[class*="bg-red-600"],
button[class*="from-rose-600"],
.btn-danger {
  position: relative;
  border-radius: 0.875rem;
  box-shadow: 0 4px 0 #7f1d1d, 0 10px 22px rgba(220, 38, 38, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.25) !important;
}
button[class*="from-red-600"]:hover,
button[class*="bg-red-600"]:hover,
button[class*="from-rose-600"]:hover,
.btn-danger:hover {
  transform: translateY(-2.5px) translateZ(8px);
  box-shadow: 0 6px 0 #7f1d1d, 0 16px 28px rgba(220, 38, 38, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.35) !important;
}
button[class*="from-red-600"]:active,
button[class*="bg-red-600"]:active,
button[class*="from-rose-600"]:active,
.btn-danger:active {
  transform: translateY(3px) scale(0.975) !important;
  box-shadow: 0 1px 0 #7f1d1d, 0 3px 8px rgba(220, 38, 38, 0.3) !important;
}

/* Emerald / Success 3D Shelf Buttons */
button[class*="from-emerald-600"],
button[class*="bg-emerald-600"],
button[class*="bg-teal-600"],
.btn-success {
  position: relative;
  border-radius: 0.875rem;
  box-shadow: 0 4px 0 #064e3b, 0 10px 22px rgba(16, 185, 129, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.25) !important;
}
button[class*="from-emerald-600"]:hover,
button[class*="bg-emerald-600"]:hover,
button[class*="bg-teal-600"]:hover,
.btn-success:hover {
  transform: translateY(-2.5px) translateZ(8px);
  box-shadow: 0 6px 0 #064e3b, 0 16px 28px rgba(16, 185, 129, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.35) !important;
}
button[class*="from-emerald-600"]:active,
button[class*="bg-emerald-600"]:active,
button[class*="bg-teal-600"]:active,
.btn-success:active {
  transform: translateY(3px) scale(0.975) !important;
  box-shadow: 0 1px 0 #064e3b, 0 3px 8px rgba(16, 185, 129, 0.3) !important;
}

/* Secondary Glass 3D Shelf Buttons */
.btn-3d-secondary,
button[class*="bg-white/10"],
button[class*="bg-white/5"] {
  position: relative;
  border-radius: 0.875rem;
  box-shadow: 0 3px 0 rgba(0, 0, 0, 0.65), 0 8px 18px rgba(0, 0, 0, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.14) !important;
}
.btn-3d-secondary:hover,
button[class*="bg-white/10"]:hover,
button[class*="bg-white/5"]:hover {
  transform: translateY(-2px) translateZ(4px);
  box-shadow: 0 5px 0 rgba(0, 0, 0, 0.65), 0 12px 24px rgba(0, 0, 0, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.22) !important;
}
.btn-3d-secondary:active,
button[class*="bg-white/10"]:active,
button[class*="bg-white/5"]:active {
  transform: translateY(2px) scale(0.975) !important;
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.65), 0 2px 4px rgba(0, 0, 0, 0.4) !important;
}

/* Side Toggle Switch Button */
.deck-side-toggle-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.35rem 0.75rem;
  border-radius: 0.75rem;
  font-size: 0.7rem;
  font-weight: 700;
  background: rgba(168, 85, 247, 0.12);
  color: #c084fc;
  border: 1px solid rgba(168, 85, 247, 0.3);
  box-shadow: 0 2px 0 rgba(0, 0, 0, 0.5);
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  user-select: none;
}
.deck-side-toggle-btn:hover {
  background: rgba(168, 85, 247, 0.25);
  color: #fff;
  border-color: rgba(168, 85, 247, 0.5);
  transform: translateY(-1px);
}
.deck-side-toggle-btn:active {
  transform: translateY(1px);
}

/* ========================================================
   3. ANIMATED 3D LIGHT BEAM SHIMMER
   ======================================================== */
.shimmer-btn,
#floating-ai-scanner-btn,
#dash-btn-ai-scanner {
  position: relative;
  overflow: hidden;
}

.shimmer-btn::after,
#floating-ai-scanner-btn::after,
#dash-btn-ai-scanner::after {
  content: '';
  position: absolute;
  top: -50%;
  left: -70%;
  width: 45%;
  height: 200%;
  background: linear-gradient(
    90deg,
    rgba(255, 255, 255, 0) 0%,
    rgba(255, 255, 255, 0.3) 50%,
    rgba(255, 255, 255, 0) 100%
  );
  transform: rotate(25deg);
  animation: lightBeamShimmer 4.5s infinite ease-in-out;
  pointer-events: none;
}

@keyframes lightBeamShimmer {
  0% { transform: translateX(-150%) rotate(25deg); }
  30%, 100% { transform: translateX(550%) rotate(25deg); }
}

/* ========================================================
   4. FLOATING AI SCANNER BUTTON (3D LEVITATION PHYSICS)
   ======================================================== */
@keyframes float3D {
  0%, 100% {
    transform: translateY(0) translateZ(0);
    box-shadow: 0 12px 28px rgba(147, 51, 234, 0.5), 0 4px 0 #4c1d95;
  }
  50% {
    transform: translateY(-8px) translateZ(14px);
    box-shadow: 0 22px 38px rgba(147, 51, 234, 0.65), 0 7px 0 #4c1d95;
  }
}

#floating-ai-scanner-btn {
  animation: float3D 3.5s ease-in-out infinite !important;
  transform-style: preserve-3d;
}

#floating-ai-scanner-btn:hover {
  animation-play-state: paused;
  transform: translateY(-4px) translateZ(16px) scale(1.05) !important;
  box-shadow: 0 24px 42px rgba(147, 51, 234, 0.75), 0 6px 0 #4c1d95 !important;
}

#floating-ai-scanner-btn:active {
  animation: none !important;
  transform: translateY(4px) scale(0.95) !important;
  box-shadow: 0 2px 0 #4c1d95, 0 6px 14px rgba(147, 51, 234, 0.4) !important;
}

/* ========================================================
   5. DASHBOARD DEDICATED HUB PORTAL CARDS (3D DEPTH)
   ======================================================== */
.hub-portal-card {
  position: relative;
  background: linear-gradient(145deg, rgba(20, 29, 47, 0.85) 0%, rgba(10, 15, 26, 0.95) 100%);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.16),
              0 14px 32px -6px rgba(0, 0, 0, 0.7),
              0 4px 0 rgba(0, 0, 0, 0.5);
  transform-style: preserve-3d;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.hub-portal-card:hover {
  transform: translateY(-8px) scale(1.015) rotateX(2deg);
  border-color: rgba(168, 85, 247, 0.5);
  box-shadow: inset 0 1px 2px rgba(255, 255, 255, 0.25),
              0 24px 45px -8px rgba(0, 0, 0, 0.85),
              0 0 25px rgba(168, 85, 247, 0.25);
}

.hub-icon-badge {
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.3s ease;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.2), 0 6px 14px rgba(0, 0, 0, 0.4);
}

.hub-portal-card:hover .hub-icon-badge {
  transform: translateY(-4px) scale(1.15) rotate(4deg);
  box-shadow: 0 12px 24px rgba(168, 85, 247, 0.45), inset 0 1px 2px rgba(255, 255, 255, 0.4);
}

/* ========================================================
   6. 3D TABLE ROWS WITH TACTILE HOVER LIFT & RIM GLOW
   ======================================================== */
table tbody tr {
  transition: transform 0.18s cubic-bezier(0.34, 1.56, 0.64, 1),
              background 0.18s ease,
              box-shadow 0.18s ease;
  position: relative;
}

table tbody tr:hover {
  background: rgba(30, 41, 59, 0.7) !important;
  transform: translateY(-2px) scale(1.002);
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.5),
              inset 3px 0 0 #a855f7;
  z-index: 5;
}

[dir="rtl"] table tbody tr:hover,
html[dir="rtl"] table tbody tr:hover {
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.5),
              inset -3px 0 0 #a855f7;
}

/* ========================================================
   7. 3D BADGES, CHIPS & AVATARS
   ======================================================== */
.tactical-header-badge,
.check-badge,
.rank-badge-gold,
.rank-badge-silver,
.rank-badge-bronze {
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.25), 0 3px 6px rgba(0, 0, 0, 0.4);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.tactical-header-badge:hover,
.check-badge:hover,
.rank-badge-gold:hover,
.rank-badge-silver:hover,
.rank-badge-bronze:hover {
  transform: translateY(-1px) scale(1.05);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.4), 0 6px 12px rgba(0, 0, 0, 0.5);
}

td img.rounded-full,
.avatar-frame,
.user-avatar-img,
.member-avatar-container {
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.5), inset 0 0 0 2px rgba(255, 255, 255, 0.12);
  transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.25s ease;
}

td img.rounded-full:hover,
.avatar-frame:hover,
.user-avatar-img:hover,
.member-avatar-container:hover {
  transform: translateY(-2px) scale(1.12);
  box-shadow: 0 8px 22px rgba(168, 85, 247, 0.5), inset 0 0 0 2px rgba(168, 85, 247, 0.65);
}

@media (max-width: 640px) {
  .deck-3d-card {
    max-width: 100%;
    margin: 0;
    height: 100vh;
    border-radius: 0;
    transform: none !important;
  }
}




