/* Global Aesthetic & Theme Variables */
:root {
  --bg-obsidian: #0A0A0E;
  --surface-color: #13131A;
  --sand-gold: #EAE0D5;
  --amber-accent: #F59E0B;
}

body {
  background-color: #0A0A0E;
  color: #EAE0D5;
  font-feature-settings: "cv02", "cv03", "cv04", "cv11";
  -webkit-tap-highlight-color: transparent;
}

/* RTL and Arabic Typography Support */
[dir="rtl"] {
  font-family: 'Tajawal', sans-serif;
}
[dir="rtl"] #affirmation-text {
  font-family: 'Tajawal', serif;
  font-weight: 500;
  line-height: 1.6;
}

/* Glassmorphism Styles */
.glass-card {
  background: rgba(19, 19, 26, 0.65);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.glass-card-subtle {
  background: rgba(255, 255, 255, 0.03);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.glass-btn {
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.glass-btn:active {
  transform: scale(0.95);
}

.glass-btn-sm {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  transition: all 0.2s cubic-bezier(0.22, 1, 0.36, 1);
}

.glass-btn-sm:active {
  transform: scale(0.96);
  background: rgba(245, 158, 11, 0.12);
  border-color: rgba(245, 158, 11, 0.3);
}

/* Film Grain Texture */
.grain-overlay {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 1;
  opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
}

/* Animations */
@keyframes pulseSubtle {
  0%, 100% { transform: scale(1); opacity: 0.2; }
  50% { transform: scale(1.08); opacity: 0.45; }
}

.animate-pulse-subtle {
  animation: pulseSubtle 4s ease-in-out infinite;
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(24px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.animate-slide-up {
  animation: slideUp 0.35s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.92);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.animate-scale-in {
  animation: scaleIn 0.3s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

/* Navigation active tab highlight */
.nav-tab.active {
  color: #FBBF24;
}

.nav-tab.active svg {
  stroke: #FBBF24;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 4px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 9999px;
}