/* --- theme.css --- */
/* Radiant Core v2 - Global Design System */
:root {
  --brand-violet: #8b5cf6;
  --brand-cyan: #06b6d4;
  --brand-diamond: #f8fafc;
  --brand-amber: #f59e0b;
  --brand-gold: #fbbf24;
  --brand-emerald: #10b981;

  --deep-slate: #020617;
  --glass-white: rgba(255, 255, 255, 0.03);
  --glass-border: rgba(255, 255, 255, 0.08);
  --glass-vip-border: rgba(251, 191, 36, 0.15);

  /* Sovereign Architecture - Global Navbar Height */
  --header-height: 5.5rem; /* 88px - Increased for absolute clearance */

  /* Sovereign Fixed Dimensions - Desktop Override */
  --footer-height: calc(64px + var(--safe-area-bottom));
  --nav-height: calc(64px + var(--safe-area-bottom));

  /* Unified Gradients */
  --grad-radiant: linear-gradient(
    135deg,
    var(--brand-violet),
    var(--brand-cyan)
  );
  --grad-silver: linear-gradient(to top, #94a3b8, #f8fafc, #ffffff);
  --grad-sunset: linear-gradient(135deg, #f59e0b, #ef4444);

  --shadow-radiant: 0 20px 50px -12px rgba(139, 92, 246, 0.3);
}

body {
  background-color: var(--deep-slate);
  color: #fff;
  min-height: 100vh;
  font-family: var(--site-font, 'Cairo', sans-serif);
  overflow-x: hidden;
}

/* The Mesh Gradient Background */
.gradient-bg,
body.gradient-bg {
  background-color: var(--deep-slate);
  background-image:
    radial-gradient(at 0% 0%, hsla(271, 91%, 65%, 0.1) 0px, transparent 50%),
    radial-gradient(at 100% 0%, hsla(242, 91%, 65%, 0.1) 0px, transparent 50%),
    radial-gradient(
      at 100% 100%,
      hsla(199, 81%, 60%, 0.1) 0px,
      transparent 50%
    ),
    radial-gradient(at 0% 100%, hsla(271, 91%, 60%, 0.1) 0px, transparent 50%);
  background-attachment: fixed;
}

/* Premium Glass Card */
.glass-card {
  background: var(--glass-white);
  -webkit-backdrop-filter: blur(24px);
  backdrop-filter: blur(24px);
  border: 1px solid var(--glass-border);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow:
    0 4px 6px -1px rgba(0, 0, 0, 0.1),
    0 2px 4px -2px rgba(0, 0, 0, 0.1);
}

.glass-card:hover {
  border-color: rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.05);
  transform: translateY(-4px);
  box-shadow: 0 20px 40px -20px rgba(0, 0, 0, 0.6);
}

/* 💎 Elite Radiant Card Token */
.card-radiant {
  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.03) 0%,
    rgba(255, 255, 255, 0) 100%
  );
  -webkit-backdrop-filter: blur(20px);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.05);
  position: relative;
  overflow: hidden;
  transition: all 0.5s cubic-bezier(0.23, 1, 0.32, 1);
}

.card-radiant::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(
    circle at var(--mouse-x, 50%) var(--mouse-y, 50%),
    rgba(139, 92, 246, 0.1) 0%,
    transparent 50%
  );
  opacity: 0;
  transition: opacity 0.5s;
  pointer-events: none;
}

.card-radiant:hover::before {
  opacity: 1;
}

.card-radiant:hover {
  border-color: rgba(139, 92, 246, 0.3);
  transform: translateY(-8px) scale(1.01);
  box-shadow:
    0 30px 60px -12px rgba(0, 0, 0, 0.4),
    0 18px 36px -18px rgba(139, 92, 246, 0.3);
}

/* Typography Enhancements */
.text-radiant {
  background: var(--grad-radiant);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  display: inline-block;
}

.brand-text {
  background: var(--grad-silver);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 0 15px rgba(255, 255, 255, 0.1));
  padding-bottom: 0.25rem;
  line-height: 1.4;
}

/* Button System */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  border-radius: 1.25rem;
  font-weight: 700;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  padding: 0.85rem 1.75rem;
  cursor: pointer;
  text-decoration: none;
}

.btn-primary {
  background: var(--grad-radiant) !important;
  color: #ffffff !important;
  box-shadow: var(--shadow-radiant);
}
.btn-primary * {
  color: #ffffff !important;
}

.btn-radiant,
button.btn-radiant,
a.btn-radiant {
  background: var(--grad-radiant) !important;
  color: #ffffff !important;
  border: 1px solid rgba(255, 255, 255, 0.2) !important;
  box-shadow: 0 10px 25px -5px rgba(139, 92, 246, 0.4) !important;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
  cursor: pointer !important;
  display: inline-flex;
  align-items: center !important;
  justify-content: center !important;
  font-weight: 700 !important;
  text-decoration: none !important;
}

.btn-radiant.hidden,
.hidden.btn-radiant {
  display: none !important;
}

.btn-radiant *,
button.btn-radiant *,
a.btn-radiant * {
  color: #ffffff !important;
}

.btn-radiant:hover,
button.btn-radiant:hover,
a.btn-radiant:hover {
  transform: translateY(-2px) scale(1.02) !important;
  box-shadow: 0 20px 35px -5px rgba(139, 92, 246, 0.6) !important;
  color: #ffffff !important;
  filter: brightness(1.1) !important;
}

.btn-primary:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 25px 60px -12px rgba(139, 92, 246, 0.5);
  filter: brightness(1.15);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: white !important;
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}

html.light .btn-secondary {
  background: rgba(15, 23, 42, 0.05);
  border: 1px solid rgba(15, 23, 42, 0.1);
  color: #0f172a !important;
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.2);
}

html.light .btn-secondary:hover {
  background: rgba(15, 23, 42, 0.1);
  border-color: rgba(15, 23, 42, 0.2);
}

/* Icon Containers */
.icon-box {
  width: 3.5rem;
  height: 3.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 1.15rem;
  position: relative;
  background: rgba(255, 255, 255, 0.05);
}

.icon-box-radiant {
  background: var(--grad-radiant);
  color: white;
}
.icon-box-violet {
  background: rgba(139, 92, 246, 0.15);
  color: #a78bfa;
}
.icon-box-cyan {
  background: rgba(6, 182, 212, 0.15);
  color: #22d3ee;
}
.icon-box-amber {
  background: rgba(245, 158, 11, 0.15);
  color: #fbbf24;
}

/* Utilities */
.scrollbar-hide::-webkit-scrollbar {
  display: none;
}
.scrollbar-hide {
  -ms-overflow-style: none;
}
@supports (scrollbar-width: none) {
  .scrollbar-hide {
    scrollbar-width: none;
  }
}

/* Light Mode Overrides (Elite Revamp) */
html.light body {
  background-color: #ffffff;
  background-image:
    radial-gradient(at 0% 0%, hsla(271, 91%, 95%, 0.6) 0px, transparent 50%),
    radial-gradient(at 100% 0%, hsla(199, 81%, 95%, 0.6) 0px, transparent 50%);
  color: #0f172a;
}

html.light .glass-card {
  background: rgba(255, 255, 255, 0.85);
  -webkit-backdrop-filter: blur(24px);
  backdrop-filter: blur(24px);
  border: 1px solid rgba(139, 92, 246, 0.1);
  box-shadow: 
    0 10px 30px -10px rgba(139, 92, 246, 0.08),
    0 4px 6px -2px rgba(0, 0, 0, 0.02);
}

/* New Radiant Card Light Mode */
html.light .card-radiant {
  background: rgba(255, 255, 255, 0.95);
  border: 1px solid rgba(139, 92, 246, 0.15);
  box-shadow: 0 10px 25px -5px rgba(139, 92, 246, 0.08);
}
html.light .card-radiant:hover {
  border-color: rgba(139, 92, 246, 0.4);
  box-shadow: 0 20px 40px -10px rgba(139, 92, 246, 0.15);
  background: #ffffff;
  transform: translateY(-8px) scale(1.01);
}

/* Gradient Typography Restoration */
html.light .brand-text {
  background: linear-gradient(135deg, #6d28d9, #0284c7);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 2px 4px rgba(109, 40, 217, 0.1));
}

html.light .text-radiant {
  background: linear-gradient(135deg, #7c3aed, #0891b2);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* ==========================================================================
   Sovereign Arabic Typography & Anti-Collision Engine
   Guarantees zero overlap between lines, safe descenders, and optimal breathing room
   ========================================================================== */
h1, .h1 {
  line-height: 1.35 !important;
  margin-bottom: 1.5rem;
}
header h1, nav h1, header .brand-text, nav .brand-text {
  margin-bottom: 0 !important;
  line-height: 1.25 !important;
}
@media (min-width: 768px) {
  h1, .h1 {
    line-height: 1.45 !important;
    margin-bottom: 2rem;
  }
}

h2, .h2 {
  line-height: 1.35 !important;
  margin-bottom: 1rem;
}
@media (min-width: 768px) {
  h2, .h2 {
    line-height: 1.4 !important;
    margin-bottom: 1.25rem;
  }
}

h3, .h3 {
  line-height: 1.4 !important;
  margin-bottom: 0.75rem;
}

h4, h5, h6 {
  line-height: 1.45 !important;
  margin-bottom: 0.5rem;
}

/* Safe line height for Arabic paragraphs */
p, .prose p {
  line-height: 1.85 !important;
}

/* Prevent Arabic diacritic and dot clipping in utilities */
.leading-none {
  line-height: 1.4 !important;
  display: inline-flex;
  align-items: center;
  padding-top: 2px;
  padding-bottom: 2px;
}

.leading-tight {
  line-height: 1.38 !important;
}

.leading-snug {
  line-height: 1.5 !important;
}

.leading-normal {
  line-height: 1.65 !important;
}

.leading-relaxed {
  line-height: 1.85 !important;
}

.leading-loose {
  line-height: 2.1 !important;
}

/* Hero Section Anti-Overlap */
.hero-subtitle {
  line-height: 2 !important;
}
@media (min-width: 768px) {
  .hero-subtitle {
    line-height: 2.2 !important;
  }
}

/* ==========================================================================
   Light Mode Contrast & Readability Engine (WCAG AA & AAA Compliant)
   ========================================================================== */
/* Hero Subtitle Contrast */
html.light .hero-subtitle {
  color: #334155 !important; /* Slate-700: 8.4:1 contrast ratio */
}
html:not(.light) .hero-subtitle {
  color: #e2e8f0 !important; /* Slate-200: high contrast on dark */
}

/* Light Mode Secondary & Muted Text (Fixing all washed-out grays) */
html.light .text-gray-100,
html.light .text-gray-200,
html.light .text-gray-300,
html.light .text-slate-100,
html.light .text-slate-200,
html.light .text-slate-300,
html.light .text-zinc-100,
html.light .text-zinc-200,
html.light .text-zinc-300,
html.light .text-neutral-100,
html.light .text-neutral-200,
html.light .text-neutral-300 {
  color: #334155 !important; /* High-contrast readable slate */
}

html.light .text-gray-400,
html.light .text-slate-400,
html.light .text-zinc-400,
html.light .text-neutral-400,
html.light .text-violet-200,
html.light .text-indigo-100,
html.light .text-indigo-200,
html.light .text-cyan-100,
html.light .text-cyan-200,
html.light .text-emerald-100,
html.light .text-emerald-200 {
  color: #475569 !important; /* Slate-600: 5.87:1 contrast */
}

html.light .text-gray-500,
html.light .text-slate-500,
html.light .text-zinc-500 {
  color: #64748b !important; /* Slate-500: 4.6:1 contrast */
}

/* Transparent white text utility fixes in light mode */
html.light .text-white\/60,
html.light .text-white\/70,
html.light .text-white\/80,
html.light .text-white\/90 {
  color: #334155 !important;
}

/* Contrast Fix: Keep white text white on all buttons and colored elements in light mode */
html.light .text-white:not(button):not(button *):not(.badge):not(.badge *):not(.btn):not(.btn *):not(.btn-radiant):not(.btn-radiant *):not(.btn-primary):not(.btn-primary *):not([class*="btn-"]):not([class*="btn-"] *):not(a[class*="bg-"]):not(a[class*="bg-"] *):not([class*="bg-violet"]):not([class*="bg-indigo"]):not([class*="bg-cyan"]):not([class*="bg-blue"]):not([class*="bg-emerald"]):not([class*="bg-orange"]):not([class*="bg-amber"]):not([class*="bg-rose"]):not([class*="bg-red"]):not([class*="bg-gradient"]):not([class*="bg-slate-9"]):not([class*="bg-slate-8"]):not([class*="bg-black"]) {
  color: #1e293b;
}

/* Universal Button Contrast Guarantee: colored/gradient buttons always maintain crisp white text */
button.btn-primary, button.btn-radiant, button.btn-primary *, button.btn-radiant *,
a.btn-primary, a.btn-radiant, a.btn-primary *, a.btn-radiant *,
button[class*="bg-violet"], button[class*="bg-violet"] *,
button[class*="bg-cyan"], button[class*="bg-cyan"] *,
button[class*="bg-blue"], button[class*="bg-blue"] *,
button[class*="bg-orange"], button[class*="bg-orange"] *,
button[class*="bg-rose"], button[class*="bg-rose"] *,
button[class*="bg-red"], button[class*="bg-red"] *,
button[class*="from-"], button[class*="from-"] *,
button[class*="bg-gradient"], button[class*="bg-gradient"] *,
a[class*="bg-violet"], a[class*="bg-violet"] *,
a[class*="bg-cyan"], a[class*="bg-cyan"] *,
a[class*="bg-blue"], a[class*="bg-blue"] *,
a[class*="bg-orange"], a[class*="bg-orange"] *,
a[class*="bg-rose"], a[class*="bg-rose"] *,
a[class*="bg-red"], a[class*="bg-red"] *,
a[class*="from-"], a[class*="from-"] *,
a[class*="bg-gradient"], a[class*="bg-gradient"] * {
  color: #ffffff !important;
}

html.light h1:not([class*="text-white"]):not([class*="gradient-text"]),
html.light h2:not([class*="text-white"]):not([class*="gradient-text"]),
html.light h3:not([class*="text-white"]):not([class*="gradient-text"]),
html.light h4:not([class*="text-white"]):not([class*="gradient-text"]) {
  color: #0f172a;
}

/* Fix for icons/badges in light mode */
html.light .glass-card i:not(.btn *):not([class*="text-"]) {
  color: #334155;
}

html.light .icon-box:not(.icon-box-radiant) {
  background: rgba(139, 92, 246, 0.08);
}
html.light .icon-box-radiant {
  box-shadow: 0 4px 15px rgba(139, 92, 246, 0.2);
}

/* Accent Colors in Light Mode: Tuned to WCAG AA >= 4.5:1 on White/Light Slate */
html.light .text-cyan-400,
html.light .text-cyan-300 { color: #0e7490 !important; }

html.light .text-violet-400,
html.light .text-violet-300 { color: #6d28d9 !important; }

html.light .text-indigo-400,
html.light .text-indigo-300 { color: #4338ca !important; }

html.light .text-blue-400,
html.light .text-blue-300 { color: #1d4ed8 !important; }

html.light .text-emerald-400,
html.light .text-emerald-300 { color: #047857 !important; }

html.light .text-amber-400,
html.light .text-amber-300,
html.light .text-yellow-400,
html.light .text-yellow-300 { color: #b45309 !important; }

html.light .text-orange-400,
html.light .text-orange-300 { color: #c2410c !important; }

html.light .text-rose-400,
html.light .text-rose-300,
html.light .text-red-400,
html.light .text-red-300 { color: #be123c !important; }

/* Preserve pure white on elements with solid dark or gradient backgrounds in light mode */
html.light .btn-primary,
html.light .btn-primary *,
html.light button.btn-primary,
html.light [class*="bg-violet-6"] .text-white,
html.light [class*="bg-violet-7"] .text-white,
html.light [class*="bg-indigo-6"] .text-white,
html.light [class*="bg-indigo-7"] .text-white,
html.light [class*="bg-cyan-6"] .text-white,
html.light [class*="bg-emerald-6"] .text-white,
html.light [class*="bg-blue-6"] .text-white,
html.light [class*="bg-orange-6"] .text-white,
html.light [class*="bg-red-6"] .text-white,
html.light [class*="bg-rose-6"] .text-white,
html.light [class*="bg-gradient-to"] .text-white,
html.light [class*="bg-slate-900"] .text-white,
html.light [class*="bg-slate-800"] .text-white {
  color: #ffffff !important;
}

/* ==========================================================================
   Dark Mode Safety Net: Prevent black/dark text on dark glass cards
   ========================================================================== */
html:not(.light) .glass-card .text-gray-900,
html:not(.light) .glass-card .text-gray-800,
html:not(.light) .glass-card .text-slate-900,
html:not(.light) .glass-card .text-slate-800,
html:not(.light) .card-radiant .text-gray-900,
html:not(.light) .card-radiant .text-gray-800 {
  color: #f8fafc !important;
}

html:not(.light) .glass-card .text-gray-700,
html:not(.light) .glass-card .text-slate-700,
html:not(.light) .card-radiant .text-gray-700 {
  color: #cbd5e1 !important;
}

html:not(.light) .glass-card .text-purple-800 {
  color: #c084fc !important;
}

/* Responsive Spacing Utilities (Optimized) */
.section-gap {
  padding-top: 1.25rem;
  padding-bottom: 1.25rem;
}

@media (min-width: 768px) {
  .section-gap {
    padding-top: 2rem;
    padding-bottom: 2rem;
  }
}

@media (min-width: 1024px) {
  .section-gap {
    padding-top: 2.5rem;
    padding-bottom: 2.5rem;
  }
}

/* ==========================================================================
   FontAwesome Pro Compatibility Layer (Polyfill for Free 6.5.1 CDN)
   Ensures all Pro icon class references render legitimate Free unicode glyphs
   ========================================================================== */
.fa-grid-2:before { content: "\f009" !important; font-family: "Font Awesome 6 Free" !important; font-weight: 900 !important; }
.fa-badge-check:before { content: "\f058" !important; font-family: "Font Awesome 6 Free" !important; font-weight: 900 !important; }
.fa-shield-check:before, .fa-check-shield:before { content: "\f3ed" !important; font-family: "Font Awesome 6 Free" !important; font-weight: 900 !important; }
.fa-sparkles:before, .fa-calendar-sparkles:before { content: "\e2ca" !important; font-family: "Font Awesome 6 Free" !important; font-weight: 900 !important; }
.fa-messages:before { content: "\f086" !important; font-family: "Font Awesome 6 Free" !important; font-weight: 900 !important; }
.fa-clock-history:before { content: "\f1da" !important; font-family: "Font Awesome 6 Free" !important; font-weight: 900 !important; }
.fa-calendar-star:before { content: "\f274" !important; font-family: "Font Awesome 6 Free" !important; font-weight: 900 !important; }
.fa-steering-wheel:before { content: "\f1b9" !important; font-family: "Font Awesome 6 Free" !important; font-weight: 900 !important; }
.fa-timer:before { content: "\f2f2" !important; font-family: "Font Awesome 6 Free" !important; font-weight: 900 !important; }
.fa-users-crown:before { content: "\f0c0" !important; font-family: "Font Awesome 6 Free" !important; font-weight: 900 !important; }
.fa-link-simple:before { content: "\f0c1" !important; font-family: "Font Awesome 6 Free" !important; font-weight: 900 !important; }
.fa-chart-line-up:before { content: "\f201" !important; font-family: "Font Awesome 6 Free" !important; font-weight: 900 !important; }
.fa-radar:before { content: "\f7c0" !important; font-family: "Font Awesome 6 Free" !important; font-weight: 900 !important; }
.fa-pen-paintbrush:before { content: "\f1fc" !important; font-family: "Font Awesome 6 Free" !important; font-weight: 900 !important; }
.fa-activity:before { content: "\f556" !important; font-family: "Font Awesome 6 Free" !important; font-weight: 900 !important; }
.fa-clapperboard-play:before { content: "\e131" !important; font-family: "Font Awesome 6 Free" !important; font-weight: 900 !important; }
.fa-calendar-circle-plus:before { content: "\f271" !important; font-family: "Font Awesome 6 Free" !important; font-weight: 900 !important; }
.fa-calendar-clock:before { content: "\f073" !important; font-family: "Font Awesome 6 Free" !important; font-weight: 900 !important; }
.fa-calendar-lines-pen:before { content: "\f073" !important; font-family: "Font Awesome 6 Free" !important; font-weight: 900 !important; }
.fa-car-bolt:before { content: "\f1b9" !important; font-family: "Font Awesome 6 Free" !important; font-weight: 900 !important; }
.fa-clock-three:before { content: "\f017" !important; font-family: "Font Awesome 6 Free" !important; font-weight: 900 !important; }
.fa-flag-swirl:before { content: "\f024" !important; font-family: "Font Awesome 6 Free" !important; font-weight: 900 !important; }
.fa-headset-complete:before { content: "\f590" !important; font-family: "Font Awesome 6 Free" !important; font-weight: 900 !important; }
.fa-home-slash:before { content: "\f015" !important; font-family: "Font Awesome 6 Free" !important; font-weight: 900 !important; }
.fa-inbox-out:before { content: "\f01c" !important; font-family: "Font Awesome 6 Free" !important; font-weight: 900 !important; }
.fa-key-skeleton:before { content: "\f084" !important; font-family: "Font Awesome 6 Free" !important; font-weight: 900 !important; }
.fa-microchip-ai:before { content: "\f2db" !important; font-family: "Font Awesome 6 Free" !important; font-weight: 900 !important; }
.fa-user-tie-hair:before { content: "\f508" !important; font-family: "Font Awesome 6 Free" !important; font-weight: 900 !important; }
.fa-wifi-slash:before { content: "\f6ac" !important; font-family: "Font Awesome 6 Free" !important; font-weight: 900 !important; }
.fa-bolt-auto:before { content: "\f0e7" !important; font-family: "Font Awesome 6 Free" !important; font-weight: 900 !important; }
.fa-bell-on:before { content: "\f0f3" !important; font-family: "Font Awesome 6 Free" !important; font-weight: 900 !important; }


/* --- layout-core.css --- */
/* Shared Vibrant Theme Styles */
* {
    font-family: var(--site-font, 'Cairo', sans-serif);
}

::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: #1e293b;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #8b5cf6, #06b6d4);
    border-radius: 10px;
}

.no-scrollbar::-webkit-scrollbar { display: none; }
.no-scrollbar { -ms-overflow-style: none; }

.brand-text {
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

@keyframes heart-pop {
    0% { transform: scale(1); }
    50% { transform: scale(1.4); }
    100% { transform: scale(1); }
}
.liked i { animation: heart-pop 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275); }

:root {
    --deep-slate: #020617;
    --c-purple: #a855f7;
    --c-indigo: #6366f1;
    --c-pink: #ec4899;
    --c-orange: #f97316;
}

/* Premium Mobile Nav Transformation */
.mobile-nav-link {
    display: flex;
    align-items: center;
    padding: 1.1rem 1.25rem;
    border-radius: 1.25rem;
    color: #94a3b8;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    gap: 1.25rem;
    text-decoration: none;
    width: 100%;
    border: 1px solid transparent;
    position: relative;
    overflow: hidden;
    margin-bottom: 0.25rem;
}

.mobile-nav-link i {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    font-size: 1.1rem;
    transition: all 0.4s ease;
    flex-shrink: 0;
}

.mobile-nav-link span {
    font-weight: 700;
    font-size: 0.95rem;
    letter-spacing: -0.01em;
}

.mobile-nav-link:hover {
    background: rgba(255, 255, 255, 0.05);
    color: #fff;
    transform: translateX(-8px);
}

.mobile-nav-link:hover i {
    background: rgba(255, 255, 255, 0.08);
    transform: scale(1.1) rotate(-5deg);
}

.mobile-nav-link:active {
    scale: 0.95;
}

.mobile-nav-link.active {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.15), rgba(6, 182, 212, 0.05));
    color: #fff;
    border-color: rgba(139, 92, 246, 0.2);
    padding-right: 1.75rem;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.3);
}

.mobile-nav-link.active i {
    background: linear-gradient(135deg, #8b5cf6, #06b6d4);
    color: white;
    border-color: rgba(255, 255, 255, 0.2);
    box-shadow: 0 8px 15px rgba(139, 92, 246, 0.4);
}

.mobile-nav-section-title {
    padding: 1.75rem 1.25rem 0.75rem;
    font-size: 10px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: #475569;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.mobile-nav-section-title::after {
    content: '';
    flex: 1;
    height: 1px;
    background: linear-gradient(to left, rgba(255, 255, 255, 0.05), transparent);
}

@keyframes nav-item-slide {
    from { opacity: 0; transform: translateX(30px); }
    to { opacity: 1; transform: translateX(0); }
}

.mobile-nav-item-anim {
    opacity: 0;
    animation: nav-item-slide 0.6s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

/* Default Dark Mode (Gradient) */
body,
.gradient-bg {
    background-color: var(--deep-slate);
    background-image:
        radial-gradient(at 0% 0%, hsla(271, 91%, 65%, 0.15) 0px, transparent 50%),
        radial-gradient(at 100% 0%, hsla(242, 91%, 65%, 0.15) 0px, transparent 50%),
        radial-gradient(at 100% 100%, hsla(330, 81%, 60%, 0.15) 0px, transparent 50%),
        radial-gradient(at 0% 100%, hsla(24, 91%, 60%, 0.15) 0px, transparent 50%);
    background-attachment: fixed;
    color: #fff;
}

/* Light Mode Override */
html.light body {
    background: #f8fafc !important;
    color: #1e293b !important;
    background-image: none !important;
}

/* Glass Card */
.glass-card {
    background: rgba(255, 255, 255, 0.03);
    -webkit-backdrop-filter: blur(20px);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

html.light .glass-card {
    background: rgba(255, 255, 255, 0.8);
    border: 1px solid rgba(0, 0, 0, 0.05);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
}

/* Floating Shapes (Hidden in light mode) */
.shape {
    position: fixed;
    filter: blur(80px);
    opacity: 0.4;
    border-radius: 50%;
    z-index: -1;
    animation: shape-float 15s infinite alternate ease-in-out;
    pointer-events: none;
}

html.light .shape {
    display: none;
}

.shape-purple {
    width: 500px;
    height: 500px;
    background: var(--c-purple);
    top: -10%;
    left: -10%;
}

.shape-indigo {
    width: 450px;
    height: 450px;
    background: var(--c-indigo);
    bottom: -5%;
    right: 10%;
    animation-delay: -3s;
}

.shape-pink {
    width: 400px;
    height: 400px;
    background: var(--c-pink);
    top: 20%;
    right: -5%;
    animation-delay: -6s;
}

.shape-orange {
    width: 350px;
    height: 350px;
    background: var(--c-orange);
    bottom: 10%;
    left: 5%;
    animation-delay: -9s;
}

@keyframes shape-float {
    0% {
        transform: translate(0, 0) scale(1);
    }

    100% {
        transform: translate(50px, 50px) scale(1.1);
    }
}

@media (prefers-reduced-motion: reduce) {
    .shape {
        animation: none !important;
        display: none !important;
    }
}

.nav-link {
    display: flex;
    align-items: center;
    padding: 0.4rem 0.65rem;
    border-radius: 0.75rem;
    color: #94a3b8;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    text-decoration: none;
    gap: 0.4rem;
    white-space: nowrap;
    position: relative;
    font-weight: 700;
    font-size: 0.82rem;
}

.nav-link i {
    font-size: 0.92rem;
    color: #64748b;
    transition: all 0.25s ease;
}

@media (min-width: 1400px) {
    .nav-link {
        padding: 0.45rem 0.85rem;
        gap: 0.5rem;
        font-size: 0.88rem;
    }
    .nav-link i {
        font-size: 1rem;
    }
}

/* Header button sizing protection on mobile & desktop */
#mainHeader button {
    min-width: unset;
    min-height: unset;
}

.nav-link:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.05);
    transform: translateY(-1px);
}

.nav-link:hover i {
    color: #fff;
    transform: scale(1.1);
}

.nav-link.active {
    color: #fff;
    background: rgba(139, 92, 246, 0.1);
}

.nav-link.active i {
    color: var(--c-purple);
    filter: drop-shadow(0 0 8px rgba(139, 92, 246, 0.4));
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: linear-gradient(to right, #8b5cf6, #06b6d4);
    transition: all 0.3s ease;
    transform: translateX(-50%);
    border-radius: 10px;
    opacity: 0;
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 40%;
    opacity: 1;
}

/* Global Form & Dropdown Color Fixes */
select option {
    background-color: #1e293b;
    color: #ffffff;
}

html.light select option {
    background-color: #ffffff;
    color: #1e293b;
}

/* Standardize all inputs/selects in light mode to prevent "dark on dark" issues */
html.light input,
html.light select,
html.light textarea {
    background-color: #ffffff !important;
    color: #1e293b !important;
    border-color: #e2e8f0 !important;
}

html.light input::placeholder,
html.light textarea::placeholder {
    color: #94a3b8 !important;
}

/* Fix for elements using hardcoded dark backgrounds in light mode */
html.light .bg-slate-900,
html.light .bg-slate-800,
html.light .bg-white\/5,
html.light .card-radiant,
html.light .glass-card {
    background-color: #f8fafc !important;
    color: #1e293b !important;
    border-color: #e2e8f0 !important;
}

/* Support for custom html-light utility if used */
html.light [class*="html-light:text-slate"] {
    color: #1e293b !important;
}

/* Ensure standard browser dropdown lists have enough contrast */
@media screen and (-webkit-min-device-pixel-ratio:0) {
    select:focus {
        color: #fff;
    }
    html.light select:focus {
        color: #1e293b;
    }
}

/* Dropdown Styles */
.nav-dropdown {
    position: relative;
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    margin-top: 0.5rem;
    background: rgba(15, 23, 42, 0.95);
    -webkit-backdrop-filter: blur(20px);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 1.25rem;
    padding: 0.75rem;
    min-width: 220px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s ease;
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.25rem;
    z-index: 100;
    pointer-events: none;
}

.nav-dropdown:hover .dropdown-menu,
.nav-dropdown.active .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
}

/* Bridge to prevent closing when moving mouse from toggle to menu */
.nav-dropdown::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    height: 20px;
    z-index: 90;
}

.dropdown-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.75rem 1rem;
    color: #94a3b8;
    border-radius: 0.75rem;
    transition: all 0.2s ease;
    font-size: 13px;
    font-weight: 600;
}

.dropdown-item i {
    width: 20px;
    text-align: center;
}

.dropdown-item:hover {
    background: rgba(255, 255, 255, 0.05);
    color: white;
    padding-right: 1.25rem;
}

@media (min-width: 1440px) {
    .nav-link {
        flex-direction: row;
        gap: 0.5rem;
        padding: 0.45rem 0.85rem;
    }

    .nav-link span {
        font-size: 0.88rem;
    }
}
/* Light Mode Overrides for Mobile Nav */
html.light #mobileNav {
    background: rgba(255, 255, 255, 0.9) !important;
    border-left: 1px solid rgba(0, 0, 0, 0.1);
    box-shadow: -20px 0 50px rgba(0, 0, 0, 0.1);
}

html.light .mobile-nav-link {
    color: #475569;
    background: rgba(0, 0, 0, 0.02);
    border-color: rgba(0, 0, 0, 0.05);
}

html.light .mobile-nav-link i {
    background: rgba(0, 0, 0, 0.03);
    border-color: rgba(0, 0, 0, 0.05);
    color: #64748b;
}

html.light .mobile-nav-link:hover {
    background: rgba(0, 0, 0, 0.05);
    color: #0f172a;
}

html.light .mobile-nav-link.active {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.1), rgba(6, 182, 212, 0.05));
    color: var(--c-purple);
    border-color: rgba(139, 92, 246, 0.1);
}

html.light .mobile-nav-section-title {
    color: #cbd5e1;
}

html.light #mobileAuthContainer {
    background: rgba(0, 0, 0, 0.02);
    border-top-color: rgba(0, 0, 0, 0.05);
}

html.light .mobile-nav-link.active i {
    box-shadow: 0 8px 15px rgba(139, 92, 246, 0.2);
}


/* --- safe-area.css --- */
/**
 * iOS Safe Area & Device Support
 * دعم المنطقة الآمنة لأجهزة Apple
 */

/* ========================================
   iOS Safe Area Support
   ======================================== */

/* Viewport meta tag must include viewport-fit=cover */

:root {
  /* Safe Area Insets */
  --safe-area-top: env(safe-area-inset-top, 0px);
  --safe-area-right: env(safe-area-inset-right, 0px);
  --safe-area-bottom: env(safe-area-inset-bottom, 0px);
  --safe-area-left: env(safe-area-inset-left, 0px);

  /* Sovereign Architecture - Global Navbar Height (Coordinated with theme.css) */
  --header-height: calc(88px + var(--safe-area-top));
  --footer-height: calc(64px + var(--safe-area-bottom));
  --nav-height: calc(64px + var(--safe-area-bottom));
}

@media (min-width: 1024px) {
  :root {
    --header-height: 5.5rem; /* Explicit clearance for Desktop */
  }
}

/* ========================================
   Header with Notch Support
   ======================================== */

.app-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding-top: var(--safe-area-top);
  padding-left: var(--safe-area-left);
  padding-right: var(--safe-area-right);
}

.app-header-inner {
  height: 64px;
  display: flex;
  align-items: center;
  padding: 0 16px;
}

/* ========================================
   Bottom Navigation with Home Indicator
   ======================================== */

.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding-bottom: var(--safe-area-bottom, env(safe-area-inset-bottom, 0px));
  padding-left: var(--safe-area-left, env(safe-area-inset-left, 0px));
  padding-right: var(--safe-area-right, env(safe-area-inset-right, 0px));
  background: rgba(15, 23, 42, 0.94) !important;
  -webkit-backdrop-filter: blur(20px) !important;
  backdrop-filter: blur(20px) !important;
  border-top: 1px solid rgba(255, 255, 255, 0.1) !important;
  box-shadow: 0 -10px 25px -5px rgba(0, 0, 0, 0.5) !important;
}

html.light .bottom-nav {
  background: rgba(255, 255, 255, 0.96) !important;
  border-top: 1px solid rgba(226, 232, 240, 0.9) !important;
  box-shadow: 0 -10px 25px -5px rgba(0, 0, 0, 0.06) !important;
}

html.light .bottom-nav a:not([class*="text-violet"]):not([class*="text-cyan"]):not([class*="text-amber"]) {
  color: #64748b !important;
}

html.light .bottom-nav a:not([class*="text-violet"]):not([class*="text-cyan"]):not([class*="text-amber"]):hover,
html.light .bottom-nav a:not([class*="text-violet"]):not([class*="text-cyan"]):not([class*="text-amber"]):active {
  color: #1e293b !important;
}

.bottom-nav-inner {
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: space-around;
}

/* ========================================
   Main Content Area
   ======================================== */

.app-main {
  padding-top: var(--header-height);
  padding-bottom: var(--nav-height);
  min-height: 100vh;
}

/* Without bottom nav */
.app-main--no-nav {
  padding-bottom: var(--safe-area-bottom);
}

/* ========================================
   Full Screen Modals
   ======================================== */

.modal-fullscreen {
  padding-top: var(--safe-area-top);
  padding-bottom: var(--safe-area-bottom);
  padding-left: var(--safe-area-left);
  padding-right: var(--safe-area-right);
}

/* ========================================
   Scroll Containers
   ======================================== */

.scroll-container {
  overscroll-behavior: contain;
  scroll-behavior: smooth;
}

/* ========================================
   Touch Optimizations
   ======================================== */

/* Prevent double-tap zoom on interactive elements */
button,
a,
input,
select,
textarea,
.touchable {
  touch-action: manipulation;
}

/* Larger touch targets for mobile */
@media (max-width: 768px) {
  button,
  .btn,
  a.nav-link {
    min-height: 44px;
    min-width: 44px;
  }
}

/* ========================================
   iOS Specific Fixes
   ======================================== */

/* Prevent iOS rubber band scrolling on body */
html,
body {
  overscroll-behavior: none;
}

/* Fix iOS input zoom */
@media screen and (-webkit-min-device-pixel-ratio: 0) {
  input[type="text"],
  input[type="email"],
  input[type="tel"],
  input[type="password"],
  input[type="number"],
  input[type="search"],
  textarea,
  select {
    font-size: 16px !important;
  }
}

/* Fix iOS select styling */
select {
  -webkit-appearance: none;
  appearance: none;
}

/* ========================================
   Splash Screen Animation
   ======================================== */

.splash-screen {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #0f172a, #1e1b4b);
  padding: var(--safe-area-top) var(--safe-area-right) var(--safe-area-bottom)
    var(--safe-area-left);
  transition: opacity 0.5s ease;
}

.splash-screen.fade-out {
  opacity: 0;
  pointer-events: none;
}

.splash-logo {
  width: 100px;
  height: 100px;
  animation: pulse-glow 2s ease-in-out infinite;
}

@keyframes pulse-glow {
  0%,
  100% {
    transform: scale(1);
    filter: drop-shadow(0 0 10px rgba(139, 92, 246, 0.5));
  }
  50% {
    transform: scale(1.05);
    filter: drop-shadow(0 0 20px rgba(139, 92, 246, 0.8));
  }
}

/* ========================================
   Standalone App Styles
   ======================================== */

@media all and (display-mode: standalone) {
  /* Styles for installed PWA */
  .install-banner {
    display: none !important;
  }

  /* Add extra padding for notch */
  .app-header {
    background: var(--bg-glass);
    -webkit-backdrop-filter: blur(20px);
    backdrop-filter: blur(20px);
  }
}

/* ========================================
   Reduced Motion
   ======================================== */

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}


/* --- loading.css --- */
/**
 * أنماط التحميل والانتظار
 * Loading States Styles
 */

/* ========================================
   Loading Overlay
   ======================================== */

.loading-overlay {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(15, 23, 42, 0.95);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.loading-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.loading-content {
    text-align: center;
}

.loading-logo {
    position: relative;
    width: 80px;
    height: 80px;
    margin: 0 auto 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.loading-logo i {
    font-size: 32px;
    color: #8b5cf6;
    z-index: 1;
}

.loading-ring {
    position: absolute;
    inset: 0;
    border: 3px solid rgba(139, 92, 246, 0.2);
    border-top-color: #8b5cf6;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.loading-text {
    color: #94a3b8;
    font-size: 14px;
}

/* ========================================
   Button Loading
   ======================================== */

.btn-loading {
    position: relative;
    pointer-events: none;
    opacity: 0.8;
}

.btn-spinner {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.7s linear infinite;
    margin-left: 8px;
}

/* ========================================
   Skeleton Loaders
   ======================================== */

.skeleton-container {
    display: grid;
    gap: 16px;
}

.skeleton-card,
.skeleton-list-item,
.skeleton-table-row,
.skeleton-stat {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 16px;
    overflow: hidden;
}

/* Card Skeleton */
.skeleton-card {
    padding: 0;
}

.skeleton-image {
    width: 100%;
    height: 160px;
    background: linear-gradient(90deg, rgba(255,255,255,0.05) 25%, rgba(255,255,255,0.1) 50%, rgba(255,255,255,0.05) 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
}

.skeleton-content {
    padding: 16px;
}

.skeleton-line {
    height: 12px;
    background: linear-gradient(90deg, rgba(255,255,255,0.05) 25%, rgba(255,255,255,0.1) 50%, rgba(255,255,255,0.05) 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: 6px;
    margin-bottom: 10px;
}

.skeleton-title {
    width: 70%;
    height: 16px;
}

.skeleton-text {
    width: 100%;
}

.skeleton-text.short {
    width: 50%;
}

/* List Skeleton */
.skeleton-list-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px;
}

.skeleton-avatar {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: linear-gradient(90deg, rgba(255,255,255,0.05) 25%, rgba(255,255,255,0.1) 50%, rgba(255,255,255,0.05) 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    flex-shrink: 0;
}

.skeleton-list-content {
    flex: 1;
}

/* Table Skeleton */
.skeleton-table-row {
    display: flex;
    gap: 16px;
    padding: 16px;
}

.skeleton-cell {
    flex: 1;
    height: 16px;
    background: linear-gradient(90deg, rgba(255,255,255,0.05) 25%, rgba(255,255,255,0.1) 50%, rgba(255,255,255,0.05) 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: 4px;
}

/* Stats Skeleton */
.skeleton-stat {
    padding: 20px;
    text-align: center;
}

.skeleton-circle {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    margin: 0 auto 12px;
    background: linear-gradient(90deg, rgba(255,255,255,0.05) 25%, rgba(255,255,255,0.1) 50%, rgba(255,255,255,0.05) 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
}

.skeleton-number {
    width: 60%;
    height: 24px;
    margin: 0 auto 8px;
}

@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

/* ========================================
   Progress Bar
   ======================================== */

.progress-bar-top {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    z-index: 100000;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.progress-bar-top.active {
    opacity: 1;
}

.progress-value {
    height: 100%;
    background: linear-gradient(90deg, #8b5cf6, #06b6d4);
    transition: width 0.3s ease;
    border-radius: 0 3px 3px 0;
}

/* ========================================
   Lazy Images
   ======================================== */

.lazy-image {
    opacity: 0;
    transition: opacity 0.3s ease;
}

.lazy-image.loaded {
    opacity: 1;
}

/* ========================================
   Content Placeholder
   ======================================== */

.content-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
    color: #64748b;
    text-align: center;
}

.content-placeholder i {
    font-size: 48px;
    margin-bottom: 16px;
    opacity: 0.5;
}

.content-placeholder p {
    font-size: 16px;
}

/* ========================================
   Pull to Refresh
   ======================================== */

.pull-indicator {
    position: fixed;
    top: 0;
    left: 50%;
    transform: translateX(-50%) translateY(-100%);
    padding: 12px 24px;
    background: linear-gradient(135deg, #1e1b4b, #0f172a);
    border-radius: 0 0 20px 20px;
    z-index: 9999;
    transition: transform 0.3s ease;
}

.pull-indicator.visible {
    transform: translateX(-50%) translateY(0);
}

.pull-indicator i {
    animation: spin 1s linear infinite;
}


/* --- accessibility.css --- */
/**
 * أنماط إمكانية الوصول
 * Accessibility Styles
 */

/* ========================================
   Screen Reader Only
   ======================================== */

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ========================================
   Skip Links
   ======================================== */

.skip-link {
  position: fixed;
  top: -100px;
  right: 50%;
  transform: translateX(50%);
  padding: 12px 24px;
  background: linear-gradient(135deg, #8b5cf6, #06b6d4);
  color: white;
  text-decoration: none;
  border-radius: 0 0 12px 12px;
  z-index: 100001;
  font-weight: 600;
  transition: top 0.3s ease;
}

.skip-link:focus {
  top: 0;
}

/* ========================================
   Focus Indicators
   ======================================== */

.keyboard-nav *:focus {
  outline: 3px solid #8b5cf6 !important;
  outline-offset: 2px !important;
}

.a11y-focus-visible *:focus-visible {
  outline: 3px solid #8b5cf6 !important;
  outline-offset: 2px !important;
}

/* ========================================
   Reduced Motion
   ======================================== */

.a11y-reduced-motion *,
.a11y-reduced-motion *::before,
.a11y-reduced-motion *::after {
  animation-duration: 0.01ms !important;
  animation-iteration-count: 1 !important;
  transition-duration: 0.01ms !important;
  scroll-behavior: auto !important;
}

/* ========================================
   High Contrast
   ======================================== */

.a11y-high-contrast {
  --bg-primary: #000000;
  --bg-secondary: #1a1a1a;
  --text-primary: #ffffff;
  --text-secondary: #e0e0e0;
  --border-color: #ffffff;
}

.a11y-high-contrast .glass-card {
  background: #1a1a1a;
  border: 2px solid #ffffff;
}

.a11y-high-contrast a {
  color: #00ffff !important;
  text-decoration: underline;
}

.a11y-high-contrast button:not(.btn-loading) {
  border: 2px solid currentColor !important;
}

/* ========================================
   Large Text
   ======================================== */

.a11y-large-text {
  font-size: 120%;
}

.a11y-large-text .text-xs {
  font-size: 0.875rem;
}
.a11y-large-text .text-sm {
  font-size: 1rem;
}
.a11y-large-text .text-base {
  font-size: 1.125rem;
}
.a11y-large-text .text-lg {
  font-size: 1.25rem;
}
.a11y-large-text .text-xl {
  font-size: 1.5rem;
}
.a11y-large-text .text-2xl {
  font-size: 1.875rem;
}
.a11y-large-text .text-3xl {
  font-size: 2.25rem;
}

/* ========================================
   Accessibility Panel
   ======================================== */

.a11y-panel {
  position: fixed;
  bottom: 90px;
  left: 20px;
  z-index: 9999;
}

.a11y-toggle {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: linear-gradient(135deg, #1e1b4b, #0f172a);
  border: 2px solid rgba(139, 92, 246, 0.5);
  color: #8b5cf6;
  font-size: 22px;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.a11y-toggle:hover {
  transform: scale(1.1);
  background: linear-gradient(135deg, #8b5cf6, #06b6d4);
  color: white;
}

.a11y-menu {
  position: absolute;
  bottom: 60px;
  left: 0;
  min-width: 220px;
  background: linear-gradient(135deg, #1e1b4b, #0f172a);
  border: 1px solid rgba(139, 92, 246, 0.3);
  border-radius: 16px;
  padding: 16px;
  opacity: 0;
  transform: scale(0.9) translateY(10px);
  pointer-events: none;
  transition: all 0.3s ease;
}

.a11y-panel.active .a11y-menu {
  opacity: 1;
  transform: scale(1) translateY(0);
  pointer-events: auto;
}

.a11y-menu h4 {
  font-size: 14px;
  font-weight: 700;
  color: white;
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.a11y-menu h4 i {
  margin-left: 8px;
  color: #8b5cf6;
}

.a11y-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 0;
  cursor: pointer;
  color: #94a3b8;
  transition: color 0.2s ease;
}

.a11y-option:hover {
  color: white;
}

.a11y-option input[type="checkbox"] {
  width: 18px;
  height: 18px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.1);
  border: 2px solid rgba(255, 255, 255, 0.2);
  cursor: pointer;
  accent-color: #8b5cf6;
}

.a11y-option span {
  font-size: 14px;
}

/* ========================================
   Touch Targets (WCAG 2.5.5)
   Temporarily disabled due to layout conflicts
   ======================================== */

/* 
@media (pointer: coarse) {
  .touchable,
  .btn,
  .button,
  [role="button"] {
    min-height: 44px;
    min-width: 44px;
  }
}
*/

/* ========================================
   Color Blind Friendly
   ======================================== */

/* Add patterns/icons alongside colors */
.status-success::before {
  content: "✓ ";
}
.status-error::before {
  content: "✗ ";
}
.status-warning::before {
  content: "⚠ ";
}
.status-info::before {
  content: "ℹ ";
}

/* ========================================
   Responsive Text Spacing
   ======================================== */

.a11y-large-text p,
.a11y-large-text li {
  line-height: 1.8;
  letter-spacing: 0.02em;
  word-spacing: 0.1em;
}

/* ========================================
   Enhanced Color Contrast (WCAG AA)
   ======================================== */

/* Improve gray text contrast - minimum 4.5:1 ratio */
.text-gray-400 {
  color: #a8b5c7;
}
.text-gray-500 {
  color: #8b9bb0;
}
.text-gray-600 {
  color: #6b7b8f;
}

/* Light mode contrast improvements */
html.light .text-gray-400 {
  color: #5a6570;
}
html.light .text-gray-500 {
  color: #4a5560;
}
html.light .text-gray-600 {
  color: #3a4550;
}

/* Placeholder text with better contrast */
::placeholder {
  color: #8b9bb0;
  opacity: 1;
}

html.light ::placeholder {
  color: #6b7b8f;
}

/* Link contrast in different contexts */
.glass-card a:not(.btn-radiant):not(.nav-link) {
  color: #a78bfa;
}

.glass-card a:not(.btn-radiant):not(.nav-link):hover {
  color: #c4b5fd;
}

html.light .glass-card a:not(.btn-radiant):not(.nav-link) {
  color: #7c3aed;
}

/* Status badges with sufficient contrast */
.badge-pending {
  background: #fef3c7;
  color: #92400e;
}
.badge-success {
  background: #d1fae5;
  color: #065f46;
}
.badge-error {
  background: #fee2e2;
  color: #991b1b;
}
.badge-info {
  background: #dbeafe;
  color: #1e40af;
}

/* Improved button contrast */
.btn-secondary {
  background: rgba(139, 155, 176, 0.2);
  color: #e2e8f0;
  border: 1px solid rgba(139, 155, 176, 0.3);
}

html.light .btn-secondary {
  background: rgba(59, 65, 80, 0.1);
  color: #334155;
  border: 1px solid rgba(59, 65, 80, 0.2);
}

/* Form label contrast */
label,
.form-label {
  color: #cbd5e1;
}

html.light label,
html.light .form-label {
  color: #334155;
}

/* Table header contrast */
th {
  color: #e2e8f0 !important;
}

html.light th {
  color: #1e293b !important;
}


/* --- interactive.css --- */
/**
 * أنماط الميزات التفاعلية
 * Interactive Features Styles
 */

/* ========================================
   Pull to Refresh
   ======================================== */

.pull-indicator {
  position: fixed;
  top: 0;
  left: 50%;
  transform: translateX(-50%) translateY(-60px);
  padding: 12px 20px;
  background: linear-gradient(135deg, #1e1b4b, #0f172a);
  border: 1px solid rgba(139, 92, 246, 0.3);
  border-radius: 0 0 16px 16px;
  color: white;
  font-size: 14px;
  z-index: 9998;
  transition: transform 0.3s ease;
  display: flex;
  align-items: center;
  gap: 8px;
}

.pull-indicator.visible {
  transform: translateX(-50%) translateY(0);
}

.pull-indicator i {
  color: #8b5cf6;
}

/* ========================================
   Ripple Effect
   ======================================== */

.ripple {
  position: relative;
  overflow: hidden;
}

.ripple-effect {
  position: absolute;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.3);
  transform: scale(0);
  animation: ripple-animation 0.6s linear;
  pointer-events: none;
  width: 100px;
  height: 100px;
  margin-left: -50px;
  margin-top: -50px;
}

@keyframes ripple-animation {
  to {
    transform: scale(4);
    opacity: 0;
  }
}

/* ========================================
   Long Press
   ======================================== */

.long-press-active {
  transform: scale(0.95);
  opacity: 0.8;
}

/* ========================================
   Scroll Reveal
   ======================================== */

.reveal-hidden {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal-hidden.revealed {
  opacity: 1;
  transform: translateY(0);
}

/* Reveal variants */
[data-reveal="fade"] {
  opacity: 0;
}

[data-reveal="slide-up"] {
  transform: translateY(50px);
}

[data-reveal="slide-down"] {
  transform: translateY(-50px);
}

[data-reveal="slide-right"] {
  transform: translateX(-50px);
}

[data-reveal="slide-left"] {
  transform: translateX(50px);
}

[data-reveal="zoom"] {
  transform: scale(0.8);
}

.revealed[data-reveal] {
  opacity: 1;
  transform: none;
}

/* ========================================
   Tilt Effect
   ======================================== */

.tilt {
  transition: transform 0.3s ease;
  transform-style: preserve-3d;
}

.tilt:hover {
  box-shadow: 0 20px 40px rgba(139, 92, 246, 0.2);
}

/* ========================================
   Action Toast
   ======================================== */

.action-toast {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 16px;
  background: linear-gradient(135deg, #1e1b4b, #0f172a);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  color: white;
  font-size: 14px;
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.3s ease;
  margin-bottom: 12px;
}

.action-toast.show {
  opacity: 1;
  transform: translateY(0);
}

.toast-actions {
  display: flex;
  gap: 8px;
}

.toast-actions button {
  padding: 6px 12px;
  border-radius: 6px;
  border: none;
  font-size: 13px;
  cursor: pointer;
  transition: all 0.2s ease;
  background: rgba(255, 255, 255, 0.1);
  color: white;
}

.toast-actions button.primary {
  background: linear-gradient(135deg, #8b5cf6, #06b6d4);
}

.toast-actions button:hover {
  transform: scale(1.05);
}

/* ========================================
   Swipe Card
   ======================================== */

.swipe-card {
  position: relative;
  transition: transform 0.3s ease;
  touch-action: pan-y;
}

.swipe-card-actions {
  position: absolute;
  inset: 0;
  display: flex;
  z-index: -1;
}

.swipe-action-left,
.swipe-action-right {
  flex: 1;
  display: flex;
  align-items: center;
  padding: 20px;
}

.swipe-action-left {
  background: #10b981;
  justify-content: flex-start;
}

.swipe-action-right {
  background: #ef4444;
  justify-content: flex-end;
}

/* ========================================
   Infinite Scroll
   ======================================== */

.infinite-scroll-loader {
  display: flex;
  justify-content: center;
  padding: 20px;
}

.infinite-scroll-end {
  text-align: center;
  padding: 20px;
  color: #64748b;
  font-size: 14px;
}

/* ========================================
   Floating Action Button
   ======================================== */

.fab-btn {
  position: fixed;
  bottom: 90px;
  right: 20px;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: linear-gradient(135deg, #8b5cf6, #06b6d4);
  border: none;
  color: white;
  font-size: 24px;
  cursor: pointer;
  box-shadow: 0 10px 30px rgba(139, 92, 246, 0.4);
  transition: all 0.3s ease;
  z-index: 1000;
}

.fab-btn:hover {
  transform: scale(1.1);
}

.fab-btn:active {
  transform: scale(0.95);
}

.fab-menu {
  position: absolute;
  bottom: 70px;
  right: 0;
  display: flex;
  flex-direction: column-reverse;
  gap: 12px;
  opacity: 0;
  pointer-events: none;
  transition: all 0.3s ease;
}

.fab-btn.active .fab-menu {
  opacity: 1;
  pointer-events: auto;
}

.fab-menu-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: linear-gradient(135deg, #1e1b4b, #0f172a);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 25px;
  color: white;
  font-size: 14px;
  text-decoration: none;
  white-space: nowrap;
  transform: translateX(20px);
  opacity: 0;
  transition: all 0.3s ease;
}

.fab-btn.active .fab-menu-item {
  transform: translateX(0);
  opacity: 1;
}

.fab-btn.active .fab-menu-item:nth-child(1) {
  transition-delay: 0.05s;
}
.fab-btn.active .fab-menu-item:nth-child(2) {
  transition-delay: 0.1s;
}
.fab-btn.active .fab-menu-item:nth-child(3) {
  transition-delay: 0.15s;
}
.fab-btn.active .fab-menu-item:nth-child(4) {
  transition-delay: 0.2s;
}

/* ========================================
   Parallax
   ======================================== */

[data-parallax] {
  will-change: transform;
}

/* ========================================
   Smooth Scroll Indicator
   ======================================== */

.scroll-indicator {
  position: fixed;
  top: 64px;
  left: 0;
  right: 0;
  height: 3px;
  background: rgba(255, 255, 255, 0.1);
  z-index: 999;
}

.scroll-indicator-value {
  height: 100%;
  background: linear-gradient(90deg, #8b5cf6, #06b6d4);
  width: 0;
  transition: width 0.1s linear;
}

/* ========================================
   Card Hover Effects
   ======================================== */

.hover-lift {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hover-lift:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 40px rgba(139, 92, 246, 0.2);
}

.hover-glow:hover {
  box-shadow: 0 0 30px rgba(139, 92, 246, 0.4);
}

.hover-border:hover {
  border-color: rgba(139, 92, 246, 0.5);
}

/* ========================================
   Pulse Notification Toast
   ======================================== */
.pulse-toast {
  position: fixed;
  bottom: 20px;
  left: 20px;
  width: 320px;
  background: rgba(15, 23, 42, 0.9);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(139, 92, 246, 0.3);
  border-radius: 16px;
  color: white;
  z-index: 10001;
  transform: translateX(-120%);
  transition: all 0.5s cubic-bezier(0.68, -0.55, 0.27, 1.55);
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
}

.pulse-toast.show {
  transform: translateX(0);
}

.pulse-toast-content {
  display: flex;
  align-items: center;
  gap: 15px;
  padding: 15px;
  cursor: pointer;
}

.pulse-toast-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: linear-gradient(135deg, #8b5cf6, #06b6d4);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  color: white;
  box-shadow: 0 4px 15px rgba(139, 92, 246, 0.4);
}

.pulse-toast-text strong {
  display: block;
  font-size: 14px;
  color: #c084fc;
  margin-bottom: 4px;
}

.pulse-toast-text p {
  font-size: 13px;
  color: #94a3b8;
  margin: 0;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}


/* --- search.css --- */
/**
 * أنماط البحث المتقدم
 * Advanced Search Styles
 */

/* ========================================
   Search Modal
   ======================================== */

.search-modal {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding-top: 10vh;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
}

.search-modal.active {
    opacity: 1;
    pointer-events: auto;
}

.search-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.8);
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
}

.search-modal-content {
    position: relative;
    width: 100%;
    max-width: 640px;
    max-height: 70vh;
    margin: 0 16px;
    background: linear-gradient(135deg, #1e1b4b, #0f172a);
    border: 1px solid rgba(139, 92, 246, 0.3);
    border-radius: 24px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transform: scale(0.95) translateY(-10px);
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.search-modal.active .search-modal-content {
    transform: scale(1) translateY(0);
}

/* ========================================
   Search Input
   ======================================== */

.search-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    padding: 16px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.search-icon {
    font-size: 20px;
    color: #8b5cf6;
    margin-left: 12px;
}

.search-input-wrapper input {
    flex: 1;
    background: transparent;
    border: none;
    font-size: 18px;
    color: white;
    outline: none;
}

.search-input-wrapper input::placeholder {
    color: #64748b;
}

.search-voice-btn {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    background: rgba(139, 92, 246, 0.2);
    border: none;
    color: #8b5cf6;
    cursor: pointer;
    transition: all 0.2s ease;
}

.search-voice-btn:hover {
    background: rgba(139, 92, 246, 0.3);
}

.search-voice-btn.listening {
    background: #ef4444;
    color: white;
    animation: pulse-voice 1s ease-in-out infinite;
}

@keyframes pulse-voice {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

.search-shortcut {
    margin-right: 10px;
    padding: 4px 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 6px;
    font-size: 12px;
    color: #94a3b8;
}

/* ========================================
   Search Filters
   ======================================== */

.search-filters {
    display: flex;
    gap: 8px;
    padding: 12px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    overflow-x: auto;
}

.search-filter {
    padding: 8px 16px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #94a3b8;
    font-size: 14px;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.2s ease;
}

.search-filter:hover {
    background: rgba(255, 255, 255, 0.1);
}

.search-filter.active {
    background: linear-gradient(135deg, #8b5cf6, #06b6d4);
    border-color: transparent;
    color: white;
}

/* ========================================
   Search Results
   ======================================== */

.search-results {
    flex: 1;
    overflow-y: auto;
    padding: 12px;
}

.search-section {
    margin-bottom: 16px;
}

.search-section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 12px;
    font-size: 12px;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.search-section-header i {
    margin-left: 6px;
}

.search-clear-btn {
    background: none;
    border: none;
    color: #ef4444;
    cursor: pointer;
    font-size: 12px;
}

.search-result-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border-radius: 12px;
    text-decoration: none;
    color: white;
    transition: all 0.2s ease;
}

.search-result-item:hover,
.search-result-item.selected {
    background: rgba(139, 92, 246, 0.2);
}

.search-result-item img {
    width: 48px;
    height: 48px;
    border-radius: 10px;
    object-fit: cover;
}

.search-result-icon {
    width: 48px;
    height: 48px;
    border-radius: 10px;
    background: linear-gradient(135deg, #8b5cf6, #06b6d4);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
}

.search-result-info {
    flex: 1;
    min-width: 0;
}

.search-result-info h4 {
    font-size: 15px;
    font-weight: 600;
    margin-bottom: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.search-result-info h4 mark {
    background: rgba(139, 92, 246, 0.4);
    color: white;
    padding: 0 2px;
    border-radius: 2px;
}

.search-result-info p {
    font-size: 13px;
    color: #64748b;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.search-result-price {
    font-weight: 700;
    color: #06b6d4;
}

.search-history-item i {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #64748b;
}

/* ========================================
   Search States
   ======================================== */

.search-empty,
.search-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 48px 20px;
    color: #64748b;
}

.search-empty i,
.search-loading i {
    font-size: 48px;
    margin-bottom: 16px;
    opacity: 0.5;
}

.search-spinner {
    width: 32px;
    height: 32px;
    border: 3px solid rgba(139, 92, 246, 0.2);
    border-top-color: #8b5cf6;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    margin-bottom: 16px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ========================================
   Search Footer
   ======================================== */

.search-footer {
    padding: 12px 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    text-align: center;
}

.search-hint {
    font-size: 12px;
    color: #64748b;
}

.search-hint kbd {
    display: inline-block;
    padding: 2px 6px;
    margin: 0 4px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    font-size: 11px;
}

/* ========================================
   Responsive
   ======================================== */

@media (max-width: 640px) {
    .search-modal-content {
        max-height: 80vh;
        border-radius: 20px 20px 0 0;
        margin: 0;
        margin-top: auto;
    }
    
    .hide-mobile {
        display: none;
    }
    
    .search-footer {
        display: none;
    }
}


/* --- maps-notifications.css --- */
/**
 * أنماط الخرائط والإشعارات
 * Maps & Notifications Styles
 */

/* ========================================
   Map Container
   ======================================== */

.map-container {
    width: 100%;
    height: 400px;
    border-radius: 16px;
    overflow: hidden;
    background: #1e293b;
}

.map-container.fullscreen {
    position: fixed;
    inset: 0;
    z-index: 9999;
    height: 100vh;
    border-radius: 0;
}

/* Map Placeholder */
.map-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    color: #64748b;
}

.map-placeholder i {
    font-size: 48px;
    margin-bottom: 16px;
    opacity: 0.5;
}

/* Locate Button */
.map-locate-btn {
    width: 40px;
    height: 40px;
    margin: 10px;
    background: white;
    border: none;
    border-radius: 8px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
    cursor: pointer;
    color: #333;
    font-size: 18px;
}

.map-locate-btn:hover {
    background: #f5f5f5;
}

/* Info Window */
.map-info-window {
    max-width: 250px;
    font-family: 'Cairo', sans-serif;
    direction: rtl;
}

.map-info-window img {
    width: 100%;
    height: 120px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 8px;
}

.map-info-window h4 {
    font-size: 14px;
    font-weight: 700;
    margin-bottom: 4px;
    color: #333;
}

.map-info-window p {
    font-size: 12px;
    color: #666;
    margin-bottom: 8px;
}

.map-info-window .price {
    display: inline-block;
    padding: 4px 8px;
    background: #8b5cf6;
    color: white;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 700;
}

.map-info-window .info-link {
    display: block;
    margin-top: 8px;
    padding: 8px;
    background: #0f172a;
    color: white;
    text-align: center;
    border-radius: 6px;
    text-decoration: none;
    font-size: 12px;
}

/* ========================================
   Notification Button
   ======================================== */

.notifications-btn {
    position: relative;
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: white;
    font-size: 18px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.notifications-btn:hover {
    background: rgba(255, 255, 255, 0.15);
}

.notification-badge {
    position: absolute;
    top: -4px;
    right: -4px;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    background: #ef4444;
    border-radius: 9px;
    font-size: 10px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
}

.notification-badge.hidden {
    display: none;
}

/* ========================================
   Notification Center
   ======================================== */

.notification-center {
    position: fixed;
    top: 70px;
    left: 20px;
    width: 360px;
    max-width: calc(100vw - 40px);
    max-height: calc(100vh - 100px);
    background: linear-gradient(135deg, #1e1b4b, #0f172a);
    border: 1px solid rgba(139, 92, 246, 0.3);
    border-radius: 20px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    z-index: 9000;
    opacity: 0;
    transform: translateY(-10px) scale(0.95);
    pointer-events: none;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.notification-center.active {
    opacity: 1;
    transform: translateY(0) scale(1);
    pointer-events: auto;
}

/* Header */
.notification-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.notification-header h4 {
    font-size: 16px;
    font-weight: 700;
    color: white;
}

.mark-all-btn {
    background: none;
    border: none;
    color: #8b5cf6;
    font-size: 12px;
    cursor: pointer;
}

.mark-all-btn:hover {
    text-decoration: underline;
}

/* List */
.notification-list {
    flex: 1;
    overflow-y: auto;
    max-height: 400px;
}

.notification-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 14px 20px;
    text-decoration: none;
    color: white;
    transition: background 0.2s ease;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.notification-item:hover {
    background: rgba(139, 92, 246, 0.1);
}

.notification-item.unread {
    background: rgba(139, 92, 246, 0.1);
}

.notification-item.unread::before {
    content: '';
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 4px;
    height: 40%;
    background: #8b5cf6;
    border-radius: 0 2px 2px 0;
}

.notification-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    background: rgba(139, 92, 246, 0.2);
    color: #8b5cf6;
}

.notification-icon.type-like { background: rgba(239, 68, 68, 0.2); color: #ef4444; }
.notification-icon.type-comment { background: rgba(59, 130, 246, 0.2); color: #3b82f6; }
.notification-icon.type-follow { background: rgba(16, 185, 129, 0.2); color: #10b981; }
.notification-icon.type-message { background: rgba(6, 182, 212, 0.2); color: #06b6d4; }
.notification-icon.type-order { background: rgba(245, 158, 11, 0.2); color: #f59e0b; }

.notification-content {
    flex: 1;
    min-width: 0;
}

.notification-text {
    font-size: 14px;
    line-height: 1.5;
    margin-bottom: 4px;
}

.notification-time {
    font-size: 12px;
    color: #64748b;
}

/* Empty */
.notification-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 48px 20px;
    color: #64748b;
}

.notification-empty i {
    font-size: 40px;
    margin-bottom: 12px;
    opacity: 0.5;
}

/* Footer */
.notification-footer {
    display: block;
    padding: 14px 20px;
    text-align: center;
    color: #8b5cf6;
    text-decoration: none;
    font-size: 14px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.notification-footer:hover {
    background: rgba(139, 92, 246, 0.1);
}

/* ========================================
   Toast Notifications
   ======================================== */

.toast-container {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10000;
    display: flex;
    flex-direction: column;
    gap: 10px;
    pointer-events: none;
}

.toast {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 20px;
    background: linear-gradient(135deg, #1e1b4b, #0f172a);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    color: white;
    font-size: 14px;
    pointer-events: auto;
    opacity: 0;
    transform: translateY(-20px);
    transition: all 0.3s ease;
}

.toast.show {
    opacity: 1;
    transform: translateY(0);
}

.toast i {
    font-size: 18px;
}

.toast-success { border-color: rgba(16, 185, 129, 0.5); }
.toast-success i { color: #10b981; }

.toast-error { border-color: rgba(239, 68, 68, 0.5); }
.toast-error i { color: #ef4444; }

.toast-warning { border-color: rgba(245, 158, 11, 0.5); }
.toast-warning i { color: #f59e0b; }

.toast-info { border-color: rgba(59, 130, 246, 0.5); }
.toast-info i { color: #3b82f6; }

.toast button {
    background: none;
    border: none;
    color: #64748b;
    cursor: pointer;
    padding: 4px;
}

.toast button:hover {
    color: white;
}

/* ========================================
   Responsive
   ======================================== */

@media (max-width: 640px) {
    .notification-center {
        left: 10px;
        right: 10px;
        width: auto;
    }
    
    .toast-container {
        left: 10px;
        right: 10px;
        transform: none;
    }
    
    .toast {
        width: 100%;
    }
}


/* --- chatbot.css --- */
/**
 * أنماط روبوت المحادثة
 * Chatbot Styles
 */

/* ========================================
   Container
   ======================================== */

#chatbot-container {
    position: fixed;
    bottom: 20px;
    left: 20px;
    z-index: 9000;
    font-family: 'Cairo', sans-serif;
}

/* ========================================
   Toggle Button
   ======================================== */

.chatbot-toggle {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(135deg, #8b5cf6, #06b6d4);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 24px;
    box-shadow: 0 5px 25px rgba(139, 92, 246, 0.4);
    transition: all 0.3s ease;
    position: relative;
}

.chatbot-toggle:hover {
    transform: scale(1.1);
}

.chatbot-toggle .chatbot-icon-close {
    display: none;
}

#chatbot-container.open .chatbot-toggle .chatbot-icon-open {
    display: none;
}

#chatbot-container.open .chatbot-toggle .chatbot-icon-close {
    display: block;
}

.chatbot-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    width: 22px;
    height: 22px;
    background: #ef4444;
    border-radius: 50%;
    font-size: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.chatbot-badge.hidden {
    display: none;
}

/* ========================================
   Chat Window
   ======================================== */

.chatbot-window {
    position: absolute;
    bottom: 80px;
    left: 0;
    width: 360px;
    max-width: calc(100vw - 40px);
    height: 500px;
    max-height: calc(100vh - 120px);
    background: linear-gradient(135deg, #1e1b4b, #0f172a);
    border: 1px solid rgba(139, 92, 246, 0.3);
    border-radius: 24px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
    opacity: 0;
    transform: scale(0.8) translateY(20px);
    pointer-events: none;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    overflow: hidden;
}

#chatbot-container.open .chatbot-window {
    opacity: 1;
    transform: scale(1) translateY(0);
    pointer-events: auto;
}

/* ========================================
   Header
   ======================================== */

.chatbot-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px;
    background: rgba(139, 92, 246, 0.1);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.chatbot-avatar {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: linear-gradient(135deg, #8b5cf6, #06b6d4);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: white;
}

.chatbot-info {
    flex: 1;
}

.chatbot-info h4 {
    font-size: 15px;
    font-weight: 700;
    color: white;
    margin: 0;
}

.chatbot-status {
    font-size: 12px;
    color: #10b981;
}

.chatbot-close {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: #94a3b8;
    cursor: pointer;
    transition: all 0.2s ease;
}

.chatbot-close:hover {
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
}

/* ========================================
   Messages
   ======================================== */

.chatbot-messages {
    flex: 1;
    overflow-y: auto;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.chatbot-message {
    max-width: 85%;
    animation: message-in 0.3s ease;
}

@keyframes message-in {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.chatbot-message.bot {
    align-self: flex-start;
}

.chatbot-message.user {
    align-self: flex-end;
}

.chatbot-message-content {
    padding: 12px 16px;
    border-radius: 16px;
    font-size: 14px;
    line-height: 1.6;
}

.chatbot-message.bot .chatbot-message-content {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border-bottom-right-radius: 4px;
}

.chatbot-message.user .chatbot-message-content {
    background: linear-gradient(135deg, #8b5cf6, #06b6d4);
    color: white;
    border-bottom-left-radius: 4px;
}

.chatbot-message-content a {
    color: #06b6d4;
    text-decoration: underline;
}

.chatbot-message-time {
    font-size: 11px;
    color: #64748b;
    margin-top: 4px;
    padding: 0 8px;
}

/* Typing Indicator */
.chatbot-typing {
    display: flex;
    gap: 4px;
    padding: 16px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    width: fit-content;
}

.chatbot-typing span {
    width: 8px;
    height: 8px;
    background: #8b5cf6;
    border-radius: 50%;
    animation: typing-bounce 1.4s ease-in-out infinite;
}

.chatbot-typing span:nth-child(2) { animation-delay: 0.2s; }
.chatbot-typing span:nth-child(3) { animation-delay: 0.4s; }

@keyframes typing-bounce {
    0%, 60%, 100% { transform: translateY(0); }
    30% { transform: translateY(-8px); }
}

/* ========================================
   Quick Actions
   ======================================== */

.chatbot-quick-actions {
    display: flex;
    gap: 8px;
    padding: 12px 16px;
    overflow-x: auto;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.chatbot-quick-actions button {
    padding: 8px 14px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: white;
    font-size: 12px;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.2s ease;
}

.chatbot-quick-actions button:hover {
    background: rgba(139, 92, 246, 0.3);
    border-color: rgba(139, 92, 246, 0.5);
}

/* ========================================
   Input Area
   ======================================== */

.chatbot-input-area {
    display: flex;
    gap: 8px;
    padding: 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.chatbot-input-area input {
    flex: 1;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 12px 16px;
    color: white;
    font-size: 14px;
    outline: none;
    transition: border-color 0.2s ease;
}

.chatbot-input-area input::placeholder {
    color: #64748b;
}

.chatbot-input-area input:focus {
    border-color: rgba(139, 92, 246, 0.5);
}

.chatbot-input-area button {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: linear-gradient(135deg, #8b5cf6, #06b6d4);
    border: none;
    color: white;
    cursor: pointer;
    transition: all 0.2s ease;
}

.chatbot-input-area button:hover {
    transform: scale(1.05);
}

/* ========================================
   Responsive
   ======================================== */

@media (max-width: 480px) {
    #chatbot-container {
        bottom: 10px;
        left: 10px;
    }
    
    .chatbot-window {
        width: calc(100vw - 20px);
        height: calc(100vh - 100px);
        bottom: 70px;
        border-radius: 20px;
    }
}


/* --- tour.css --- */
/* Cinema Tour - "Spotlight" Mode */
.tour-active {
    overflow: hidden !important;
}

.cinema-spotlight {
    position: absolute;
    border-radius: 12px;
    box-shadow: 0 0 0 9999px rgba(2, 6, 23, 0.85); /* Deep slate backdrop */
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    border: 2px solid rgba(139, 92, 246, 0.8); /* Violet border */
    z-index: 10001;
    pointer-events: none;
    animation: spotlightPulse 2s infinite;
}

@keyframes spotlightPulse {
    0%, 100% { border-color: rgba(139, 92, 246, 0.4); box-shadow: 0 0 0 9999px rgba(2, 6, 23, 0.85), 0 0 20px rgba(139, 92, 246, 0.2); }
    50% { border-color: rgba(139, 92, 246, 0.8); box-shadow: 0 0 0 9999px rgba(2, 6, 23, 0.85), 0 0 40px rgba(139, 92, 246, 0.4); }
}

.tour-card {
    background: rgba(15, 23, 42, 0.95);
    -webkit-backdrop-filter: blur(20px);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: white;
    padding: 24px;
    border-radius: 24px;
    width: 340px;
    max-width: calc(100vw - 40px);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    position: absolute;
    z-index: 10002;
    transition: opacity 0.4s ease, transform 0.4s ease, top 0.4s ease, left 0.4s ease;
    direction: rtl;
    text-align: right;
}

.tour-title {
    font-weight: 900;
    font-size: 1.3rem;
    margin-bottom: 12px;
    background: linear-gradient(135deg, #a78bfa, #22d3ee);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.tour-desc {
    color: #94a3b8;
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 24px;
}

.tour-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    padding-top: 16px;
}

.tour-btn-next {
    background: linear-gradient(135deg, #8b5cf6, #6366f1);
    color: white;
    padding: 10px 24px;
    border-radius: 14px;
    font-weight: 800;
    font-size: 0.9rem;
    border: none;
    cursor: pointer;
    box-shadow: 0 10px 20px -5px rgba(139, 92, 246, 0.4);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    items-center: center;
    gap: 8px;
}

.tour-btn-next:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 25px -5px rgba(139, 92, 246, 0.5);
    filter: brightness(1.1);
}

.tour-btn-next:active {
    transform: translateY(0);
}

.tour-btn-skip {
    color: #64748b;
    background: none;
    border: none;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: color 0.3s;
}

.tour-btn-skip:hover {
    color: #ef4444;
}

@media (max-width: 640px) {
    .tour-card {
        padding: 20px;
    }
}


/* --- charts.css --- */
/**
 * أنماط تصور البيانات
 * Charts & Data Visualization Styles
 */

/* ========================================
   Progress Ring
   ======================================== */

.progress-ring-container {
    position: relative;
    display: inline-block;
}

.progress-ring {
    transform: rotate(-90deg);
}

.progress-ring-label {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.progress-ring-value-text {
    font-size: 24px;
    font-weight: 700;
    color: white;
}

.progress-ring-label-text {
    font-size: 12px;
    color: #64748b;
}

/* ========================================
   Bar Chart
   ======================================== */

.bar-chart {
    display: flex;
    align-items: flex-end;
    justify-content: space-around;
    gap: 8px;
    padding-bottom: 30px;
    position: relative;
}

.bar-chart-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    height: 100%;
}

.bar-chart-bar {
    width: 100%;
    max-width: 40px;
    border-radius: 8px 8px 0 0;
    position: relative;
    transition: height 1s ease;
}

.bar-chart-value {
    position: absolute;
    top: -24px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 12px;
    font-weight: 600;
    color: white;
    white-space: nowrap;
}

.bar-chart-label {
    position: absolute;
    bottom: 0;
    font-size: 11px;
    color: #64748b;
    text-align: center;
    max-width: 60px;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ========================================
   Donut Chart
   ======================================== */

.donut-chart-wrapper {
    display: flex;
    align-items: center;
    gap: 24px;
    flex-wrap: wrap;
}

.donut-chart {
    position: relative;
}

.donut-chart-center {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    font-weight: 700;
    color: white;
}

.donut-chart-legend {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: #94a3b8;
}

.legend-color {
    width: 12px;
    height: 12px;
    border-radius: 4px;
    flex-shrink: 0;
}

.legend-label {
    flex: 1;
}

.legend-value {
    font-weight: 600;
    color: white;
}

/* ========================================
   Sparkline
   ======================================== */

.sparkline-container {
    display: inline-block;
    vertical-align: middle;
}

.sparkline {
    display: block;
}

/* ========================================
   Stat Cards with Charts
   ======================================== */

.stat-card-chart {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.stat-card-info h4 {
    font-size: 28px;
    font-weight: 700;
    color: white;
    margin-bottom: 4px;
}

.stat-card-info p {
    font-size: 14px;
    color: #64748b;
}

.stat-card-trend {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    margin-top: 8px;
}

.stat-card-trend.up {
    color: #10b981;
}

.stat-card-trend.down {
    color: #ef4444;
}

/* ========================================
   Animated Count
   ======================================== */

[data-animate-count] {
    transition: opacity 0.3s ease;
}

/* ========================================
   Real-time Indicator
   ======================================== */

.realtime-indicator {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    color: #10b981;
}

.realtime-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #10b981;
    animation: pulse-dot 2s ease-in-out infinite;
}

@keyframes pulse-dot {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(1.2); }
}

/* ========================================
   Data Grid
   ======================================== */

.data-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
}

.data-grid-item {
    padding: 20px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.data-grid-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 30px rgba(139, 92, 246, 0.2);
}

.data-grid-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    margin-bottom: 12px;
}

.data-grid-value {
    font-size: 28px;
    font-weight: 700;
    color: white;
    margin-bottom: 4px;
}

.data-grid-label {
    font-size: 14px;
    color: #64748b;
}

/* ========================================
   Chart Container
   ======================================== */

.chart-container {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 24px;
}

.chart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.chart-title {
    font-size: 18px;
    font-weight: 700;
    color: white;
}

.chart-actions {
    display: flex;
    gap: 8px;
}

.chart-action-btn {
    padding: 8px 12px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: #94a3b8;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.chart-action-btn:hover,
.chart-action-btn.active {
    background: linear-gradient(135deg, #8b5cf6, #06b6d4);
    color: white;
}


/* --- errors.css --- */
/**
 * أنماط معالجة الأخطاء
 * Error Handling Styles
 */

/* ========================================
   Error Modal
   ======================================== */

.error-modal {
    position: fixed;
    inset: 0;
    z-index: 100000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.error-modal.active {
    opacity: 1;
    pointer-events: auto;
}

.error-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.8);
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
}

.error-modal-content {
    position: relative;
    max-width: 400px;
    width: 100%;
    background: linear-gradient(135deg, #1e1b4b, #0f172a);
    border: 1px solid rgba(239, 68, 68, 0.3);
    border-radius: 24px;
    padding: 32px;
    text-align: center;
    transform: scale(0.9) translateY(20px);
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.error-modal.active .error-modal-content {
    transform: scale(1) translateY(0);
}

.error-icon {
    width: 72px;
    height: 72px;
    margin: 0 auto 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
}

.error-icon.error-network {
    background: rgba(245, 158, 11, 0.2);
    color: #f59e0b;
}

.error-icon.error-auth {
    background: rgba(139, 92, 246, 0.2);
    color: #8b5cf6;
}

.error-icon.error-validation {
    background: rgba(59, 130, 246, 0.2);
    color: #3b82f6;
}

.error-title {
    font-size: 20px;
    font-weight: 700;
    color: white;
    margin-bottom: 8px;
}

.error-message {
    color: #94a3b8;
    font-size: 14px;
    margin-bottom: 20px;
    line-height: 1.6;
}

.error-details {
    background: rgba(0, 0, 0, 0.3);
    border-radius: 12px;
    padding: 12px;
    margin-bottom: 20px;
    text-align: left;
    direction: ltr;
}

.error-details code {
    font-family: monospace;
    font-size: 12px;
    color: #ef4444;
    word-break: break-all;
}

.error-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
}

.error-btn-retry,
.error-btn-close {
    padding: 12px 24px;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
}

.error-btn-retry {
    background: linear-gradient(135deg, #8b5cf6, #06b6d4);
    color: white;
}

.error-btn-retry:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(139, 92, 246, 0.3);
}

.error-btn-close {
    background: rgba(255, 255, 255, 0.1);
    color: white;
}

.error-btn-close:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* ========================================
   Field Errors
   ======================================== */

.input-error {
    border-color: #ef4444 !important;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.2) !important;
}

.field-error-message {
    display: block;
    color: #ef4444;
    font-size: 12px;
    margin-top: 6px;
}

.field-error-message i {
    margin-left: 4px;
}

/* ========================================
   Inline Alerts
   ======================================== */

.inline-alert {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    border-radius: 12px;
    margin-bottom: 16px;
    font-size: 14px;
    animation: slide-in 0.3s ease;
}

@keyframes slide-in {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.inline-alert i:first-child {
    font-size: 18px;
}

.inline-alert span {
    flex: 1;
}

.inline-alert button {
    background: none;
    border: none;
    color: inherit;
    opacity: 0.7;
    cursor: pointer;
    padding: 4px;
}

.inline-alert button:hover {
    opacity: 1;
}

.inline-alert-success {
    background: rgba(16, 185, 129, 0.15);
    border: 1px solid rgba(16, 185, 129, 0.3);
    color: #10b981;
}

.inline-alert-error {
    background: rgba(239, 68, 68, 0.15);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #ef4444;
}

.inline-alert-warning {
    background: rgba(245, 158, 11, 0.15);
    border: 1px solid rgba(245, 158, 11, 0.3);
    color: #f59e0b;
}

.inline-alert-info {
    background: rgba(59, 130, 246, 0.15);
    border: 1px solid rgba(59, 130, 246, 0.3);
    color: #3b82f6;
}

/* ========================================
   Offline Banner
   ======================================== */

.offline-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 12px 20px;
    background: linear-gradient(135deg, #dc2626, #b91c1c);
    color: white;
    text-align: center;
    z-index: 99999;
    transform: translateY(100%);
    transition: transform 0.3s ease;
}

.offline-banner.visible {
    transform: translateY(0);
}

.offline-banner i {
    margin-left: 8px;
}

/* ========================================
   Floating Support Action Button
   ======================================== */
.floating-support-btn {
  position: fixed !important;
  bottom: calc(72px + var(--safe-area-bottom, env(safe-area-inset-bottom, 0px))) !important;
  left: 1rem !important;
  width: 3.25rem !important;
  height: 3.25rem !important;
  z-index: 1040 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  border-radius: 9999px !important;
  background: linear-gradient(135deg, #7c3aed, #06b6d4) !important;
  color: #ffffff !important;
  box-shadow: 0 10px 25px -5px rgba(124, 58, 237, 0.5), 0 8px 10px -6px rgba(6, 182, 212, 0.4) !important;
  border: 2px solid rgba(255, 255, 255, 0.25) !important;
  cursor: pointer !important;
  touch-action: manipulation !important;
  transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.2s ease !important;
}

.floating-support-btn:hover {
  transform: scale(1.08) !important;
  box-shadow: 0 15px 30px -5px rgba(124, 58, 237, 0.7), 0 10px 12px -5px rgba(6, 182, 212, 0.5) !important;
}

.floating-support-btn:active {
  transform: scale(0.92) !important;
}

@media (min-width: 1024px) {
  .floating-support-btn {
    bottom: 1.5rem !important;
    left: 1.5rem !important;
    width: 3.5rem !important;
    height: 3.5rem !important;
  }
}

/* ========================================
   Cookie Consent Banner Responsive Position
   ======================================== */
#cookieBanner,
.cookie-consent-banner {
  position: fixed !important;
  bottom: calc(72px + var(--safe-area-bottom, env(safe-area-inset-bottom, 0px))) !important;
  right: 1rem !important;
  left: 1rem !important;
  z-index: 1030 !important;
}

@media (min-width: 768px) {
  #cookieBanner,
  .cookie-consent-banner {
    bottom: 1.5rem !important;
    right: 1.5rem !important;
    left: auto !important;
    width: 24rem !important;
  }
}

/* ========================================
   Support Modal Mobile Optimization
   ======================================== */
#supportModal {
  z-index: 1050 !important;
}

#supportContent {
  background: rgba(15, 23, 42, 0.96) !important;
  -webkit-backdrop-filter: blur(20px) !important;
  backdrop-filter: blur(20px) !important;
  border: 1px solid rgba(255, 255, 255, 0.15) !important;
  max-height: 88vh !important;
  overflow-y: auto !important;
}

