:root {
  /* Kick Brand Colors */
  --kick-green: #53FC18;
  --kick-green-dark: #3BC900;
  --kick-green-light: #76FF4A;
  --kick-green-glow: rgba(83, 252, 24, 0.4);
  --kick-green-dim: rgba(83, 252, 24, 0.1);

  /* Neutral Palette - Deep Dark */
  --bg-dark-900: #0a0a0a;
  --bg-dark-800: #111111;
  --bg-dark-700: #1a1a1a;
  --bg-dark-600: #222222;

  /* Text */
  --text-primary: #ffffff;
  --text-secondary: #aaaaaa;
  --text-muted: #666666;

  /* Borders & Dividers */
  --border-dim: rgba(255, 255, 255, 0.05);
  --border-medium: rgba(255, 255, 255, 0.1);

  /* Glassmorphism */
  --glass-bg: rgba(17, 17, 17, 0.7);
  --glass-blur: blur(20px);
  --glass-border: rgba(255, 255, 255, 0.08);

  /* Utilities */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;

  --shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  --shadow-md: 0 10px 15px -3px rgba(0, 0, 0, 0.2);
  --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.3);
  --shadow-glow: 0 0 20px var(--kick-green-glow);

  --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-normal: 300ms cubic-bezier(0.4, 0, 0.2, 1);
}

/* Global Table Utilities */
.table-responsive {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin-bottom: 1rem;
}

.table-card {
  padding: 0 !important;
  overflow: hidden;
  background: #0e0e10 !important;
  border: 1px solid #1f2326 !important;
  box-shadow: none !important;
  backdrop-filter: none !important;
}

.modern-table {
  width: 100%;
  border-collapse: collapse;
}

.modern-table th {
  background: #18191c;
  padding: 16px 20px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  font-size: 12px;
  border-bottom: 1px solid var(--border-dim);
}

.modern-table td {
  padding: 16px 20px;
  border-bottom: 1px solid var(--border-dim);
}

.modern-table tr:last-child td {
  border-bottom: none;
}

.modern-table tr:hover td {
  background: #1f1f23;
}

.user-mention {
  color: var(--kick-green);
  font-weight: 700;
  text-decoration: none;
  transition: var(--transition-fast);
}

.user-mention:hover {
  color: var(--kick-green-light);
  text-decoration: underline;
}

.modern-table td.cell-date,
.modern-table td.cell-time {
  color: var(--text-muted);
  font-family: monospace;
  white-space: nowrap;
}

.modern-table td.cell-message {
  color: #d1d1d1;
  line-height: 1.5;
  word-break: break-word;
}

/* Stat Cards Analytics */
.stats-overview {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  margin-bottom: 32px;
}

@media (min-width: 1024px) {
  .stats-overview {
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
  }
}

@media (max-width: 480px) {
  .stats-overview {
    grid-template-columns: 1fr;
  }
}

.stat-card {
  text-align: center;
  padding: 24px;
}

.stat-label {
  display: block;
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 12px;
}

.stat-value {
  font-family: 'Outfit', sans-serif;
  font-size: 32px;
  font-weight: 800;
  color: var(--kick-green);
}

@media (max-width: 640px) {
  .stat-card {
    padding: 16px;
  }

  .stat-value {
    font-size: 24px;
  }
}

/* Core Reset */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  height: 100%;
}

body {
  background-color: var(--bg-dark-900);
  background-image:
    radial-gradient(circle at 10% 20%, rgba(83, 252, 24, 0.05) 0%, transparent 40%),
    radial-gradient(circle at 90% 80%, rgba(83, 252, 24, 0.03) 0%, transparent 40%);
  background-attachment: fixed;
  color: var(--text-primary);
  font-family: 'Inter', 'Outfit', -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 14px;
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Base Layout Components */
.container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 24px;
  width: 100%;
}

@media (max-width: 768px) {
  .container {
    padding: 0 16px;
  }
}

/* Loading Effects */
.shimmer {
  background: linear-gradient(90deg,
      rgba(255, 255, 255, 0) 0%,
      rgba(255, 255, 255, 0.05) 50%,
      rgba(255, 255, 255, 0) 100%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
  0% {
    background-position: -200% 0;
  }

  100% {
    background-position: 200% 0;
  }
}

/* Premium Card (Glassmorphism) */
.glass-card {
  background: var(--glass-bg);
  backdrop-filter: var(--glass-blur);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  transition: var(--transition-normal);
  padding: 24px;
}

.glass-card:hover {
  border-color: rgba(83, 252, 24, 0.2);
  transform: translateY(-2px);
}

/* Interactive Elements */
.btn-primary {
  background: var(--kick-green);
  color: var(--bg-dark-900);
  font-weight: 700;
  padding: 13px 24px;
  border-radius: var(--radius-md);
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: var(--transition-fast);
  text-decoration: none;
  font-size: 15px;
  margin-bottom: 2px;
}

.btn-primary:hover {
  background: var(--kick-green-light);
  box-shadow: var(--shadow-glow);
  transform: scale(1.02);
}

.btn-primary:active {
  transform: scale(0.98);
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-dark-700);
  color: var(--text-primary);
  font-weight: 600;
  padding: 12px 24px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-medium);
  cursor: pointer;
  transition: var(--transition-fast);
  text-decoration: none;
}

.btn-secondary:hover {
  background: var(--bg-dark-600);
  border-color: var(--text-muted);
}

/* Typography Helpers */
.gradient-text {
  background: linear-gradient(135deg, var(--kick-green) 0%, var(--kick-green-light) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Animation Orbs */
.orb {
  position: fixed;
  border-radius: 50%;
  filter: blur(100px);
  z-index: -1;
  opacity: 0.15;
  pointer-events: none;
}

.orb-primary {
  width: 500px;
  height: 500px;
  background: var(--kick-green);
  top: -250px;
  left: -250px;
}

.orb-secondary {
  width: 400px;
  height: 400px;
  background: var(--kick-green-dark);
  bottom: -200px;
  right: -200px;
}


/* =============================== */
/* Loading Skeletons */
/* =============================== */

.skeleton {
  background: linear-gradient(90deg,
      var(--bg-dark-800) 25%,
      var(--bg-dark-700) 50%,
      var(--bg-dark-800) 75%);
  background-size: 200% 100%;
  animation: skeleton-loading 1.5s infinite;
  border-radius: var(--radius-sm);
}

.skeleton-text {
  height: 1em;
  margin-bottom: 0.5em;
  width: 100%;
}

.skeleton-text.small {
  width: 60%;
  height: 0.8em;
}

.skeleton-text.large {
  width: 80%;
  height: 1.2em;
}

@keyframes skeleton-loading {
  0% {
    background-position: 200% 0;
  }

  100% {
    background-position: -200% 0;
  }
}

/* =============================== */

@media (prefers-reduced-motion: reduce) {

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  html {
    scroll-behavior: auto;
  }
}

/* =============================== */
/* Enhanced Form Inputs */
/* =============================== */

.input-container input,
.input-container textarea,
.input-container select {
  transition: all var(--transition-fast);
  border-radius: var(--radius-sm);
}

.input-container input:focus,
.input-container textarea:focus,
.input-container select:focus {
  border-color: var(--kick-green);
  box-shadow: 0 0 0 2px rgba(83, 252, 24, 0.2);
}

/* =============================== */
/* Improved Table Accessibility */
/* =============================== */

.modern-table th {
  position: sticky;
  top: 0;
  z-index: 10;
}

.modern-table tr:focus-within td {
  background: var(--bg-dark-700);
}

/* =============================== */
/* Better Contrast for Text */
/* =============================== */

.text-muted-high-contrast {
  color: #999999;
}

/* For critical info that needs better contrast */
.text-important {
  color: #e0e0e0;
}

/* =============================== */
/* Search Enhancement */
/* =============================== */

.search-input-loading,
.search-input-loading:focus {
  background-image: url("data:image/svg+xml,%3Csvg width='20' height='20' viewBox='0 0 20 20' xmlns='http://www.w3.org/2000/svg'%3E%3Ccircle cx='10' cy='10' r='8' stroke='%2353FC18' stroke-width='2' fill='none'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 40px;
}

/* ==========================================================================
   Layout - Header, Navigation, Footer (moved from base.html for performance)
   ========================================================================== */

/* Header */
.main-header {
  padding: 16px 0;
  margin-bottom: 32px;
  border-bottom: 1px solid var(--border-dim);
  background: rgba(10, 10, 10, 0.8);
  backdrop-filter: blur(12px);
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo-area {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}

.logo-icon {
  width: 36px;
  height: 36px;
  background: var(--kick-green);
  color: var(--bg-dark-900);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 18px;
  border-radius: 8px;
  box-shadow: 0 0 15px var(--kick-green-dim);
}

.logo-area h1,
.logo-area .logo-text {
  font-family: 'Outfit', sans-serif;
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin: 0;
}

.logo-area h1 span,
.logo-area .logo-text span {
  color: var(--text-primary);
  -webkit-text-fill-color: var(--text-primary);
}

.main-nav {
  display: flex;
  gap: 24px;
}

.nav-link {
  color: var(--text-secondary);
  text-decoration: none;
  font-weight: 600;
  font-size: 14px;
  transition: var(--transition-fast);
  position: relative;
  padding: 4px 0;
}

.nav-link:hover {
  color: var(--kick-green);
}

.nav-link.active {
  color: var(--text-primary);
}

.nav-link.active::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--kick-green);
  border-radius: 2px;
}

.nav-link-external {
  display: flex;
  align-items: center;
  gap: 6px;
}

.nav-link-external svg {
  opacity: 0.7;
}

.main-content {
  flex: 1;
  padding-bottom: 50px;
}

/* Footer */
.main-footer {
  padding: 40px 0;
  border-top: 1px solid var(--border-dim);
  color: var(--text-muted);
  font-size: 13px;
  text-align: center;
}

.footer-links {
  display: flex;
  justify-content: center;
  gap: 24px;
  margin-bottom: 12px;
}

.footer-links a {
  color: var(--text-muted);
  text-decoration: none;
  transition: var(--transition-fast);
}

.footer-links a:hover {
  color: var(--kick-green);
}

/* Burger menu */
.burger-btn {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}

.burger-btn span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text-secondary);
  border-radius: 2px;
  transition: all 0.3s ease;
}

.burger-btn.open span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.burger-btn.open span:nth-child(2) {
  opacity: 0;
}

.burger-btn.open span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* Responsive Header/Footer */
@media (max-width: 640px) {
  .main-header {
    padding: 12px 0;
    margin-bottom: 24px;
  }

  .logo-area h1 {
    font-size: 20px;
  }

  .logo-icon {
    width: 32px;
    height: 32px;
    font-size: 16px;
  }

  .main-nav {
    gap: 16px;
  }

  .nav-link {
    font-size: 13px;
  }

  .burger-btn {
    display: flex;
  }

  .main-nav {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    left: 0;
    background: rgba(10, 10, 10, 0.97);
    backdrop-filter: blur(12px);
    border-top: 1px solid var(--border-dim);
    flex-direction: column;
    padding: 16px 24px;
    gap: 16px;
    z-index: 99;
  }

  .main-nav.open {
    display: flex;
  }

  .main-header {
    position: relative;
  }
}