@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,400;0,600;0,700;1,400&family=Inter:wght@300;400;500;600&family=Amiri:ital,wght@0,400;0,700;1,400&display=swap');

:root {
  --emerald: #006B3F;
  --dark-emerald: #00331F;
  --gold: #D4AF37;
  --deep-gold: #AA8C2C;
  --obsidian: #0A110F;
  --surface: rgba(10, 22, 18, 0.75);
  --surface-hover: rgba(15, 30, 27, 0.9);
  --text: #F0EDE5;
  --text-muted: #B3B0A6;
  --border: rgba(212, 175, 55, 0.25);
  --pattern: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23d4af37' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Inter', sans-serif;
  background-color: var(--obsidian);
  color: var(--text);
  line-height: 1.7;
  overflow-x: hidden;
  background-image: var(--pattern),
    radial-gradient(circle at 15% 50%, rgba(0, 107, 63, 0.25), transparent 60%),
    radial-gradient(circle at 85% 30%, rgba(212, 175, 55, 0.2), transparent 70%);
  background-attachment: fixed;
}

h1, h2, h3, h4 {
  font-family: 'Playfair Display', serif;
  font-weight: 600;
  line-height: 1.3;
}

.arabic {
  font-family: 'Amiri', serif;
  font-size: 1.5em;
  direction: rtl;
  color: var(--gold);
}

a {
  color: var(--gold);
  text-decoration: none;
  transition: all 0.3s ease;
}

a:hover {
  color: var(--deep-gold);
}

/* Glassmorphic Navbar */
.nav {
  position: fixed;
  top: 0;
  width: 100%;
  z-index: 1000;
  padding: 20px 0;
  background: rgba(10, 17, 15, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 4px 30px rgba(0,0,0,0.5);
}

.nav-inner {
  max-width: 1360px;
  margin: 0 auto;
  padding: 0 40px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav-logo {
  font-family: 'Playfair Display', serif;
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 12px;
}

.nav-logo svg {
  width: 32px;
  height: 32px;
  fill: var(--gold);
}

.nav-links {
  display: flex;
  gap: 32px;
  align-items: center;
}

.nav-links a {
  color: var(--text);
  font-size: 0.95rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.nav-links a:hover {
  color: var(--gold);
}

/* Page Headers / Image Banners */
.page-banner {
  width: 100%;
  height: 400px;
  background-size: cover;
  background-position: center;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  border-bottom: 2px solid var(--gold);
  margin-bottom: 60px;
}

.page-banner::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(10,17,15,0.3), var(--obsidian));
}

.page-banner-content {
  position: relative;
  z-index: 10;
  max-width: 800px;
  padding: 0 20px;
  margin-top: 80px; /* Offset for nav */
}

.page-banner-content h1 {
  font-size: clamp(3rem, 5vw, 4.5rem);
  margin-bottom: 15px;
  color: #FFF;
  text-shadow: 0 5px 20px rgba(0,0,0,0.8);
}

.page-banner-content p {
  font-size: 1.3rem;
  color: var(--text);
  text-shadow: 0 2px 10px rgba(0,0,0,0.8);
}

/* 3D Dashboard Framework */
.container {
  max-width: 1360px;
  margin: 120px auto 60px;
  padding: 0 40px;
}

/* Hero Section */
.hero {
  position: relative;
  border-radius: 24px;
  overflow: hidden;
  min-height: 600px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 60px;
  margin-bottom: 60px;
  background: linear-gradient(to bottom, rgba(10, 17, 15, 0.2), rgba(10, 17, 15, 0.7)), url('images/hero.jpg') center/cover;
  border: 1px solid var(--border);
  box-shadow: 0 20px 50px rgba(0,0,0,0.7);
}

.hero::after {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--pattern);
  opacity: 0.15;
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 10;
  max-width: 900px;
  background: rgba(10,17,15,0.6);
  padding: 50px;
  border-radius: 24px;
  backdrop-filter: blur(10px);
  border: 1px solid rgba(212,175,55,0.3);
}

.hero-content h1 {
  font-size: clamp(3.5rem, 6vw, 5rem);
  margin-bottom: 20px;
  background: linear-gradient(45deg, var(--gold), #FFF, var(--deep-gold));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 4px 20px rgba(212,175,55,0.3));
}

.hero-content p {
  font-size: 1.3rem;
  color: #FFF;
  margin-bottom: 40px;
  line-height: 1.8;
  text-shadow: 0 2px 10px rgba(0,0,0,0.9);
  font-weight: 500;
}

/* Image-Backed Dashboard Grid */
.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(350px, 100%), 1fr));
  gap: 35px;
  perspective: 1200px;
}

.dashboard-card {
  position: relative;
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 45px 30px;
  text-align: center;
  transform-style: preserve-3d;
  transition: transform 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.5s ease, border-color 0.5s ease;
  cursor: pointer;
  overflow: hidden;
  background-size: cover;
  background-position: center;
  min-height: 350px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.dashboard-card::before {
  content: '';
  position: absolute;
  inset: 0;
  /* Made the gradient much lighter so images are highly visible immediately */
  background: linear-gradient(to top, rgba(10,17,15,0.9) 0%, rgba(10,17,15,0.2) 100%);
  z-index: 0;
  transition: background 0.5s ease;
}

.dashboard-card:hover {
  transform: rotateX(5deg) rotateY(-3deg) translateY(-12px);
  border-color: var(--gold);
  box-shadow: 0 40px 80px rgba(0, 0, 0, 0.8), 0 0 50px rgba(212, 175, 55, 0.5);
}

.dashboard-card:hover::before {
  background: linear-gradient(to top, rgba(0,107,63,0.8) 0%, rgba(10,17,15,0.1) 100%);
}

.dashboard-card > * {
  position: relative;
  z-index: 1;
  transform: translateZ(50px);
}

.card-icon {
  width: 84px;
  height: 84px;
  margin: 0 auto 24px;
  fill: none;
  stroke: var(--gold);
  stroke-width: 1.1;
  stroke-linecap: round;
  stroke-linejoin: round;
  filter: drop-shadow(0 0 20px rgba(212,175,55,0.55));
  transition: transform 0.5s ease;
}

.dashboard-card:hover .card-icon {
  transform: scale(1.15) translateZ(60px);
  stroke: #FFF;
}

.dashboard-card h3 {
  font-size: 2rem;
  color: #FFF;
  margin-bottom: 15px;
  text-shadow: 0 4px 15px rgba(0,0,0,0.9);
}

.dashboard-card p {
  color: #FFF;
  font-size: 1.1rem;
  line-height: 1.6;
  text-shadow: 0 2px 10px rgba(0,0,0,0.9);
  font-weight: 500;
}

/* Embedded AI Section */
.ai-hero-section {
  display: flex;
  background: linear-gradient(135deg, rgba(10,17,15,0.9), rgba(0,107,63,0.3)), url('images/hadith-banner.jpg') center/cover;
  border-radius: 24px;
  border: 1px solid var(--gold);
  overflow: hidden;
  margin: 60px 0;
  box-shadow: 0 20px 60px rgba(0,0,0,0.8), 0 0 30px rgba(212,175,55,0.2);
}

.ai-hero-image {
  flex: 1;
  background: url('images/chandelier.jpg') center/cover;
  min-height: 400px;
  position: relative;
}

.ai-hero-image::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, transparent, rgba(10,17,15,0.8));
}

.ai-hero-content {
  flex: 1.5;
  padding: 50px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.ai-hero-content h2 {
  font-size: 2.5rem;
  color: var(--gold);
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 15px;
}

.ai-hero-content h2 svg {
  width: 40px;
  height: 40px;
  fill: var(--gold);
  animation: pulse 2s infinite alternate;
}

