@import url('https://fonts.googleapis.com/css2?family=Cairo:wght@300;400;600;700;800;900&family=Tajawal:wght@400;700;900&display=swap');

/* ============ RESET & BASE ============ */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Cairo', 'Tajawal', sans-serif;
}

:root {
  --pink-1: #ff2d95;
  --pink-2: #ff6ec7;
  --pink-3: #ffb6d9;
  --purple: #c084fc;
  --lilac: #e9d5ff;
  --bg-1: #fff0f6;
  --bg-2: #fce7f3;
  --dark: #2a0a2e;
  --glass: rgba(255, 255, 255, 0.55);
  --glass-border: rgba(255, 255, 255, 0.8);
  --neon-glow: 0 0 20px rgba(255, 45, 149, 0.5), 0 0 40px rgba(255, 110, 199, 0.3);
}

html { scroll-behavior: smooth; }

body {
  background: var(--bg-1);
  color: var(--dark);
  direction: rtl;
  overflow-x: hidden;
  min-height: 100vh;
  position: relative;
}

/* ============ AURORA BACKGROUND ============ */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background:
    radial-gradient(circle at 20% 20%, rgba(255, 110, 199, 0.35), transparent 45%),
    radial-gradient(circle at 80% 30%, rgba(192, 132, 252, 0.3), transparent 45%),
    radial-gradient(circle at 50% 80%, rgba(255, 182, 217, 0.4), transparent 50%);
  z-index: -2;
  animation: aurora 20s ease-in-out infinite alternate;
}

body::after {
  content: '';
  position: fixed;
  inset: 0;
  background-image:
    radial-gradient(circle, rgba(255, 45, 149, 0.15) 1px, transparent 1px);
  background-size: 40px 40px;
  z-index: -1;
  opacity: 0.4;
}

@keyframes aurora {
  0% { transform: scale(1) rotate(0deg); }
  100% { transform: scale(1.15) rotate(8deg); }
}

/* ============ FLOATING 3D SHAPES ============ */
.floating-shapes {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  overflow: hidden;
}
.shape {
  position: absolute;
  border-radius: 50%;
  filter: blur(40px);
  opacity: 0.5;
  animation: float 15s ease-in-out infinite;
}
.shape:nth-child(1) { width: 300px; height: 300px; background: var(--pink-2); top: 10%; left: 5%; animation-delay: 0s; }
.shape:nth-child(2) { width: 250px; height: 250px; background: var(--purple); top: 60%; right: 10%; animation-delay: -5s; }
.shape:nth-child(3) { width: 200px; height: 200px; background: var(--pink-3); bottom: 10%; left: 40%; animation-delay: -10s; }

@keyframes float {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33% { transform: translate(30px, -40px) scale(1.1); }
  66% { transform: translate(-20px, 30px) scale(0.95); }
}

/* ============ NAVBAR 3D GLASS ============ */
nav {
  position: sticky;
  top: 15px;
  z-index: 1000;
  margin: 15px 5% 0;
  background: var(--glass);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid var(--glass-border);
  border-radius: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 30px;
  box-shadow:
    0 8px 32px rgba(255, 45, 149, 0.15),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
  transform-style: preserve-3d;
  transition: transform 0.4s ease;
}

.logo {
  display: flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
  transform-style: preserve-3d;
}

.logo-icon {
  width: 50px;
  height: 50px;
  background: linear-gradient(135deg, var(--pink-1), var(--purple));
  color: white;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 900;
  font-size: 1.2rem;
  box-shadow:
    0 10px 25px rgba(255, 45, 149, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.4);
  transform: rotate(-8deg);
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.logo:hover .logo-icon {
  transform: rotate(8deg) scale(1.1);
}

.logo-text h1 {
  font-size: 1.1rem;
  color: var(--dark);
  font-weight: 800;
  background: linear-gradient(135deg, var(--pink-1), var(--purple));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.logo-text p {
  font-size: 0.75rem;
  color: var(--pink-1);
  font-weight: 600;
}

.nav-links {
  display: flex;
  gap: 8px;
  list-style: none;
}

.nav-links a {
  text-decoration: none;
  color: var(--dark);
  font-size: 0.88rem;
  font-weight: 700;
  padding: 10px 18px;
  border-radius: 14px;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  position: relative;
  overflow: hidden;
}

.nav-links a::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, var(--pink-1), var(--purple));
  opacity: 0;
  transition: opacity 0.3s;
  z-index: -1;
}

.nav-links a:hover, .nav-links a.active {
  color: white;
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 10px 25px rgba(255, 45, 149, 0.4);
}

.nav-links a:hover::before, .nav-links a.active::before {
  opacity: 1;
}

/* ============ HERO 3D ============ */
.hero {
  position: relative;
  padding: 100px 5% 120px;
  text-align: center;
  perspective: 1500px;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(255, 45, 149, 0.2), transparent 70%);
  transform: translate(-50%, -50%);
  border-radius: 50%;
  animation: pulse 4s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { transform: translate(-50%, -50%) scale(1); opacity: 0.6; }
  50% { transform: translate(-50%, -50%) scale(1.2); opacity: 0.9; }
}

.hero h2 {
  font-size: clamp(2rem, 5vw, 3.5rem);
  color: var(--dark);
  margin-bottom: 24px;
  line-height: 1.3;
  font-weight: 900;
  position: relative;
  transform: translateZ(50px);
}

.hero h2 span {
  background: linear-gradient(135deg, var(--pink-1), var(--purple));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  position: relative;
  display: inline-block;
}

.hero h2 span::after {
  content: '';
  position: absolute;
  bottom: -8px;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--pink-1), var(--purple));
  border-radius: 2px;
  box-shadow: var(--neon-glow);
}

.hero p {
  max-width: 700px;
  margin: 0 auto 40px;
  color: #4a2a4f;
  font-size: 1.1rem;
  line-height: 1.8;
  position: relative;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: linear-gradient(135deg, var(--pink-1), var(--purple));
  color: white;
  padding: 16px 36px;
  border-radius: 18px;
  text-decoration: none;
  font-weight: 800;
  font-size: 1rem;
  box-shadow:
    0 15px 35px rgba(255, 45, 149, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.3);
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.btn-primary::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
  transition: left 0.6s;
}

.btn-primary:hover::before { left: 100%; }

.btn-primary:hover {
  transform: translateY(-5px) scale(1.05);
  box-shadow:
    0 25px 50px rgba(255, 45, 149, 0.5),
    0 0 40px rgba(255, 110, 199, 0.4);
}

/* ============ CONTAINER & TITLES ============ */
.container {
  max-width: 1300px;
  margin: 60px auto;
  padding: 0 20px;
  position: relative;
}

.section-title {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  color: var(--dark);
  margin-bottom: 40px;
  text-align: center;
  font-weight: 900;
  position: relative;
  display: inline-block;
  width: 100%;
}

.section-title::after {
  content: '';
  display: block;
  width: 80px;
  height: 4px;
  background: linear-gradient(90deg, var(--pink-1), var(--purple));
  margin: 14px auto 0;
  border-radius: 2px;
  box-shadow: var(--neon-glow);
}

/* ============ 3D BENTO GRID ============ */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 30px;
  perspective: 2000px;
}

.card {
  background: var(--glass);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid var(--glass-border);
  border-radius: 28px;
  overflow: hidden;
  box-shadow:
    0 10px 40px rgba(255, 45, 149, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
  transition: all 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
  transform-style: preserve-3d;
  position: relative;
  cursor: pointer;
}

.card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, transparent 40%, rgba(255, 45, 149, 0.1));
  opacity: 0;
  transition: opacity 0.4s;
  z-index: 1;
  pointer-events: none;
}

.card:hover {
  transform: translateY(-12px) rotateX(5deg) rotateY(-5deg) scale(1.02);
  box-shadow:
    0 30px 60px rgba(255, 45, 149, 0.25),
    0 0 40px rgba(192, 132, 252, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 1);
  border-color: var(--pink-2);
}

.card:hover::before { opacity: 1; }

.card img, .card iframe {
  width: 100%;
  height: 220px;
  object-fit: cover;
  border: none;
  display: block;
  transition: transform 0.5s;
}

.card:hover img, .card:hover iframe {
  transform: scale(1.05);
}

.card-content {
  padding: 24px;
  position: relative;
  z-index: 2;
}

.badge {
  background: linear-gradient(135deg, var(--pink-1), var(--purple));
  color: white;
  font-size: 0.72rem;
  font-weight: 800;
  padding: 5px 14px;
  border-radius: 10px;
  display: inline-block;
  margin-bottom: 12px;
  box-shadow: 0 4px 12px rgba(255, 45, 149, 0.3);
  letter-spacing: 0.5px;
}

.card-content h3 {
  font-size: 1.15rem;
  color: var(--dark);
  margin-bottom: 10px;
  font-weight: 800;
  line-height: 1.4;
}

.card-content p {
  font-size: 0.88rem;
  color: #5a3a5f;
  line-height: 1.7;
}

/* ============ CHAT WIDGET 3D ============ */
#chat-widget {
  position: fixed;
  bottom: 25px;
  left: 25px;
  z-index: 2000;
}

.chat-btn {
  background: linear-gradient(135deg, var(--pink-1), var(--purple));
  color: white;
  border: none;
  width: 65px;
  height: 65px;
  border-radius: 50%;
  cursor: pointer;
  box-shadow:
    0 10px 30px rgba(255, 45, 149, 0.5),
    0 0 0 0 rgba(255, 45, 149, 0.7);
  font-size: 1.6rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  animation: pulse-ring 2.5s infinite;
  border: 2px solid rgba(255, 255, 255, 0.3);
}

@keyframes pulse-ring {
  0% { box-shadow: 0 10px 30px rgba(255, 45, 149, 0.5), 0 0 0 0 rgba(255, 45, 149, 0.7); }
  70% { box-shadow: 0 10px 30px rgba(255, 45, 149, 0.5), 0 0 0 20px rgba(255, 45, 149, 0); }
  100% { box-shadow: 0 10px 30px rgba(255, 45, 149, 0.5), 0 0 0 0 rgba(255, 45, 149, 0); }
}

.chat-btn:hover {
  transform: scale(1.15) rotate(15deg);
}

.chat-box {
  display: none;
  width: 380px;
  max-width: calc(100vw - 50px);
  background: var(--glass);
  backdrop-filter: blur(25px) saturate(180%);
  -webkit-backdrop-filter: blur(25px) saturate(180%);
  border-radius: 28px;
  box-shadow:
    0 25px 60px rgba(255, 45, 149, 0.25),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
  border: 1px solid var(--glass-border);
  overflow: hidden;
  position: absolute;
  bottom: 85px;
  left: 0;
  animation: popUp 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes popUp {
  0% { transform: scale(0.5) translateY(30px); opacity: 0; }
  100% { transform: scale(1) translateY(0); opacity: 1; }
}

.chat-header {
  background: linear-gradient(135deg, var(--pink-1), var(--purple));
  color: white;
  padding: 18px 20px;
  font-weight: 800;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: inset 0 -1px 0 rgba(255, 255, 255, 0.2);
}

.chat-body {
  height: 300px;
  padding: 18px;
  overflow-y: auto;
  background: linear-gradient(180deg, rgba(255, 240, 246, 0.5), rgba(252, 231, 243, 0.5));
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.chat-body::-webkit-scrollbar { width: 6px; }
.chat-body::-webkit-scrollbar-track { background: transparent; }
.chat-body::-webkit-scrollbar-thumb {
  background: linear-gradient(var(--pink-2), var(--purple));
  border-radius: 3px;
}

.message {
  padding: 12px 16px;
  border-radius: 18px;
  font-size: 0.85rem;
  max-width: 85%;
  line-height: 1.5;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  animation: msgIn 0.3s ease-out;
}

@keyframes msgIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.message.user {
  background: linear-gradient(135deg, var(--pink-1), var(--purple));
  color: white;
  align-self: flex-end;
  border-bottom-right-radius: 4px;
  box-shadow: 0 6px 18px rgba(255, 45, 149, 0.3);
}

.message.admin {
  background: white;
  color: var(--dark);
  border: 1px solid var(--pink-3);
  align-self: flex-start;
  border-bottom-left-radius: 4px;
}

.chat-footer {
  display: flex;
  padding: 12px;
  background: rgba(255, 255, 255, 0.6);
  border-top: 1px solid var(--pink-3);
  gap: 8px;
}

.chat-footer input {
  flex: 1;
  padding: 11px 14px;
  border: 1px solid var(--pink-3);
  border-radius: 14px;
  outline: none;
  font-size: 0.85rem;
  background: white;
  transition: all 0.3s;
}

.chat-footer input:focus {
  border-color: var(--pink-1);
  box-shadow: 0 0 0 3px rgba(255, 45, 149, 0.15);
}

.chat-footer button {
  background: linear-gradient(135deg, var(--pink-1), var(--purple));
  color: white;
  border: none;
  padding: 11px 20px;
  border-radius: 14px;
  cursor: pointer;
  font-weight: 800;
  font-size: 0.85rem;
  transition: all 0.3s;
  box-shadow: 0 4px 12px rgba(255, 45, 149, 0.3);
}

.chat-footer button:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(255, 45, 149, 0.4);
}

/* ============ FOOTER ============ */
footer {
  background: linear-gradient(135deg, #2a0a2e, #4a1a4e);
  color: white;
  text-align: center;
  padding: 40px 20px;
  margin-top: 100px;
  border-top: 3px solid var(--pink-1);
  font-size: 0.88rem;
  position: relative;
  overflow: hidden;
}

footer::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--pink-1), var(--purple), var(--pink-1));
  background-size: 200% 100%;
  animation: shimmer 3s linear infinite;
}

@keyframes shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

footer span {
  background: linear-gradient(135deg, var(--pink-2), var(--purple));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-weight: 800;
}

/* ============ ADMIN DASHBOARD ============ */
.admin-login {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.login-card {
  background: var(--glass);
  backdrop-filter: blur(25px);
  border: 1px solid var(--glass-border);
  border-radius: 32px;
  padding: 50px 40px;
  max-width: 450px;
  width: 100%;
  text-align: center;
  box-shadow:
    0 25px 60px rgba(255, 45, 149, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.login-card .lock-icon {
  width: 80px;
  height: 80px;
  background: linear-gradient(135deg, var(--pink-1), var(--purple));
  border-radius: 24px;
  margin: 0 auto 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.2rem;
  box-shadow: 0 15px 35px rgba(255, 45, 149, 0.4);
  animation: floatIcon 3s ease-in-out infinite;
}

@keyframes floatIcon {
  0%, 100% { transform: translateY(0) rotate(-5deg); }
  50% { transform: translateY(-10px) rotate(5deg); }
}

.login-card h2 {
  font-size: 1.8rem;
  color: var(--dark);
  margin-bottom: 10px;
  font-weight: 900;
}

.login-card p {
  color: #5a3a5f;
  margin-bottom: 30px;
}

.login-card input {
  width: 100%;
  padding: 14px 18px;
  border: 2px solid var(--pink-3);
  border-radius: 14px;
  font-size: 1rem;
  margin-bottom: 16px;
  background: white;
  outline: none;
  transition: all 0.3s;
}

.login-card input:focus {
  border-color: var(--pink-1);
  box-shadow: 0 0 0 4px rgba(255, 45, 149, 0.15);
}

.dashboard {
  padding: 30px 5%;
  max-width: 1400px;
  margin: 0 auto;
}

.stat-card {
  background: var(--glass);
  backdrop-filter: blur(20px);
  border: 1px solid var(--glass-border);
  border-radius: 24px;
  padding: 30px;
  box-shadow:
    0 10px 30px rgba(255, 45, 149, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
  margin-bottom: 30px;
}

.stat-card h3 {
  font-size: 1.3rem;
  margin-bottom: 20px;
  color: var(--dark);
  font-weight: 800;
  display: flex;
  align-items: center;
  gap: 10px;
}

.stat-number {
  font-size: 3rem;
  font-weight: 900;
  background: linear-gradient(135deg, var(--pink-1), var(--purple));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

table {
  width: 100%;
  border-collapse: collapse;
  background: white;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(255, 45, 149, 0.08);
}

table th {
  background: linear-gradient(135deg, var(--pink-1), var(--purple));
  color: white;
  padding: 14px;
  text-align: right;
  font-weight: 700;
}

table td {
  padding: 14px;
  border-bottom: 1px solid var(--bg-2);
}

.form-group {
  margin-bottom: 18px;
}

.form-group label {
  display: block;
  margin-bottom: 8px;
  font-weight: 700;
  color: var(--dark);
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 12px 16px;
  border: 2px solid var(--pink-3);
  border-radius: 14px;
  font-size: 0.95rem;
  background: white;
  outline: none;
  transition: all 0.3s;
  font-family: inherit;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  border-color: var(--pink-1);
  box-shadow: 0 0 0 4px rgba(255, 45, 149, 0.15);
}

.form-group textarea {
  min-height: 120px;
  resize: vertical;
}

/* ============ RESPONSIVE ============ */
@media (max-width: 768px) {
  nav {
    flex-direction: column;
    gap: 12px;
    padding: 14px 20px;
    margin: 10px 15px 0;
  }
  .nav-links {
    flex-wrap: wrap;
    justify-content: center;
  }
  .nav-links a {
    padding: 8px 12px;
    font-size: 0.8rem;
  }
  .hero { padding: 60px 20px 80px; }
  .grid-3 { grid-template-columns: 1fr; gap: 20px; }
  .chat-box { width: calc(100vw - 50px); }
  #chat-widget { bottom: 15px; left: 15px; }
}

/* ============ UTILITIES ============ */
.hidden { display: none !important; }

.tilt-card {
  transform-style: preserve-3d;
  transition: transform 0.1s ease-out;
}

.tilt-card .card-content,
.tilt-card .badge {
  transform: translateZ(30px);
}
/* ============ DARK MODE ============ */
body.dark-mode {
  background: #0a0a0f;
  color: #e2e8f0;
}

body.dark-mode::before {
  background:
    radial-gradient(circle at 20% 20%, rgba(255, 45, 149, 0.15), transparent 45%),
    radial-gradient(circle at 80% 30%, rgba(192, 132, 252, 0.12), transparent 45%),
    radial-gradient(circle at 50% 80%, rgba(255, 182, 217, 0.1), transparent 50%);
}

body.dark-mode nav {
  background: rgba(20, 20, 30, 0.8);
  border-color: rgba(255, 45, 149, 0.3);
}

body.dark-mode .logo-text h1,
body.dark-mode .section-title,
body.dark-mode .card-content h3 {
  color: #f1f5f9;
}

body.dark-mode .logo-text p,
body.dark-mode .hero p,
body.dark-mode .card-content p {
  color: #cbd5e1;
}

body.dark-mode .nav-links a {
  color: #cbd5e1;
}

body.dark-mode .nav-links a:hover,
body.dark-mode .nav-links a.active {
  background: rgba(255, 45, 149, 0.2);
  color: var(--pink-2);
}

body.dark-mode .card {
  background: rgba(30, 30, 40, 0.7);
  border-color: rgba(255, 45, 149, 0.3);
  box-shadow: 0 10px 40px rgba(255, 45, 149, 0.08);
}

body.dark-mode .card:hover {
  border-color: var(--pink-1);
  box-shadow: 0 30px 60px rgba(255, 45, 149, 0.15);
}

body.dark-mode .chat-box {
  background: rgba(20, 20, 30, 0.95);
  border-color: rgba(255, 45, 149, 0.3);
}

body.dark-mode .chat-body {
  background: linear-gradient(180deg, rgba(30, 30, 40, 0.8), rgba(40, 40, 50, 0.8));
}

body.dark-mode .message.admin {
  background: rgba(40, 40, 50, 0.9);
  color: #e2e8f0;
  border-color: rgba(255, 45, 149, 0.3);
}

body.dark-mode .chat-footer {
  background: rgba(30, 30, 40, 0.9);
  border-color: rgba(255, 45, 149, 0.3);
}

body.dark-mode .chat-footer input {
  background: rgba(40, 40, 50, 0.9);
  color: #e2e8f0;
  border-color: rgba(255, 45, 149, 0.3);
}

body.dark-mode footer {
  background: linear-gradient(135deg, #0a0a0f, #1a1a2e);
}

body.dark-mode .stat-card,
body.dark-mode .login-card {
  background: rgba(30, 30, 40, 0.7);
  border-color: rgba(255, 45, 149, 0.3);
}

body.dark-mode .form-group input,
body.dark-mode .form-group select,
body.dark-mode .form-group textarea {
  background: rgba(40, 40, 50, 0.9);
  color: #e2e8f0;
  border-color: rgba(255, 45, 149, 0.3);
}

body.dark-mode table {
  background: rgba(30, 30, 40, 0.9);
}

body.dark-mode table td {
  border-color: rgba(255, 45, 149, 0.2);
  color: #cbd5e1;
}

/* Dark Mode Toggle Button */
.dark-mode-toggle {
  position: fixed;
  top: 100px;
  left: 25px;
  z-index: 1500;
  background: linear-gradient(135deg, var(--pink-1), var(--purple));
  color: white;
  border: none;
  width: 55px;
  height: 55px;
  border-radius: 50%;
  cursor: pointer;
  box-shadow: 0 8px 25px rgba(255, 45, 149, 0.4);
  font-size: 1.4rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  border: 2px solid rgba(255, 255, 255, 0.2);
}

.dark-mode-toggle:hover {
  transform: scale(1.15) rotate(180deg);
  box-shadow: 0 12px 35px rgba(255, 45, 149, 0.5);
}

body.dark-mode .dark-mode-toggle {
  background: linear-gradient(135deg, #fbbf24, #f59e0b);
}

/* ============ LOADING SCREEN ============ */
.loading-screen {
  position: fixed;
  inset: 0;
  background: linear-gradient(135deg, var(--pink-1), var(--purple));
  z-index: 9999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  transition: opacity 0.6s ease, visibility 0.6s ease;
}

.loading-screen.hidden {
  opacity: 0;
  visibility: hidden;
}

.loading-logo {
  width: 100px;
  height: 100px;
  background: white;
  border-radius: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 900;
  font-size: 2.5rem;
  color: var(--pink-1);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3);
  animation: pulse 2s ease-in-out infinite;
  margin-bottom: 30px;
}

.loading-text {
  color: white;
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: 20px;
  text-align: center;
}

.loading-spinner {
  width: 50px;
  height: 50px;
  border: 4px solid rgba(255, 255, 255, 0.3);
  border-top-color: white;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* ============ PARTICLE BACKGROUND ============ */
#particle-canvas {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .dark-mode-toggle {
    top: 80px;
    left: 15px;
    width: 48px;
    height: 48px;
    font-size: 1.2rem;
  }
}
/* ============ CURSOR EFFECTS ============ */
.custom-cursor {
  position: fixed;
  width: 20px;
  height: 20px;
  border: 2px solid var(--pink-1);
  border-radius: 50%;
  pointer-events: none;
  z-index: 9999;
  transform: translate(-50%, -50%);
  transition: all 0.15s ease;
  mix-blend-mode: difference;
}

.custom-cursor.hover {
  width: 40px;
  height: 40px;
  background: rgba(255, 45, 149, 0.2);
  border-color: var(--purple);
}

.cursor-trail {
  position: fixed;
  width: 10px;
  height: 10px;
  background: var(--pink-2);
  border-radius: 50%;
  pointer-events: none;
  z-index: 9998;
  transform: translate(-50%, -50%);
  transition: all 0.1s ease;
}

.cursor-ripple {
  position: fixed;
  width: 40px;
  height: 40px;
  border: 2px solid var(--pink-1);
  border-radius: 50%;
  pointer-events: none;
  z-index: 9997;
  transform: translate(-50%, -50%) scale(0);
  animation: cursorRipple 0.6s ease-out;
}

@keyframes cursorRipple {
  to {
    transform: translate(-50%, -50%) scale(3);
    opacity: 0;
  }
}

/* ============ SOUND TOGGLE ============ */
.sound-toggle {
  position: fixed;
  top: 170px;
  left: 25px;
  z-index: 1500;
  background: linear-gradient(135deg, var(--pink-1), var(--purple));
  color: white;
  border: none;
  width: 55px;
  height: 55px;
  border-radius: 50%;
  cursor: pointer;
  box-shadow: 0 8px 25px rgba(255, 45, 149, 0.4);
  font-size: 1.4rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  border: 2px solid rgba(255, 255, 255, 0.2);
}

.sound-toggle:hover {
  transform: scale(1.15) rotate(15deg);
  box-shadow: 0 12px 35px rgba(255, 45, 149, 0.5);
}

/* ============ RIPPLE EFFECT ============ */
.ripple {
  position: absolute;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.6);
  transform: scale(0);
  animation: rippleEffect 0.6s ease-out;
  pointer-events: none;
}

@keyframes rippleEffect {
  to {
    transform: scale(4);
    opacity: 0;
  }
}

/* ============ TEXT REVEAL ============ */
.text-reveal {
  animation: textReveal 0.8s ease-out forwards;
}

@keyframes textReveal {
  from {
    opacity: 0;
    transform: translateY(30px);
    filter: blur(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
    filter: blur(0);
  }
}

/* ============ STAGGER ANIMATION ============ */
.card {
  animation: staggerIn 0.6s ease-out forwards;
  opacity: 0;
}

@keyframes staggerIn {
  from {
    opacity: 0;
    transform: translateY(40px) scale(0.95);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* ============ FLOATING ICONS ============ */
@keyframes floatIcon {
  0%, 100% {
    transform: translateY(0) rotate(0deg);
  }
  50% {
    transform: translateY(-5px) rotate(5deg);
  }
}

/* ============ RESPONSIVE ============ */
@media (max-width: 768px) {
  .custom-cursor,
  .cursor-trail {
    display: none;
  }
  
  .sound-toggle {
    top: 140px;
    left: 15px;
    width: 48px;
    height: 48px;
    font-size: 1.2rem;
  }
}

/* Hide cursor on mobile */
@media (hover: none) {
  .custom-cursor,
  .cursor-trail {
    display: none !important;
  }
}