/*
 * Marhaba Nador - Premium Modern Directory Style
 * Bootstrap 5.1.3 + Cairo Font
 */

@import url('https://fonts.googleapis.com/css2?family=Cairo:wght@400;500;600;700;800;900&display=swap');

:root {
  /* Premium Palette */
  --color-primary: #1e3a8a;
  /* Deep elegant blue */
  --color-primary-light: #3b82f6;
  --color-secondary: #059669;
  /* Rich emerald green */
  --color-secondary-light: #10b981;
  --color-accent: #f59e0b;
  /* Warm amber */
  --color-accent-light: #fbbf24;
  --color-dark: #0f172a;
  --color-gray: #64748b;
  --color-light: #f8fafc;
  --color-white: #ffffff;

  /* Gradients */
  --grad-primary: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-light) 100%);
  --grad-secondary: linear-gradient(135deg, var(--color-secondary) 0%, var(--color-secondary-light) 100%);
  --grad-accent: linear-gradient(135deg, var(--color-accent) 0%, var(--color-accent-light) 100%);
  --grad-dark: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
  --grad-glass: linear-gradient(135deg, rgba(255, 255, 255, 0.9) 0%, rgba(255, 255, 255, 0.7) 100%);

  /* Shadows */
  --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  --shadow-hover: 0 15px 35px -5px rgba(30, 58, 138, 0.15), 0 10px 15px -5px rgba(30, 58, 138, 0.1);
  --shadow-glass: 0 8px 32px 0 rgba(31, 38, 135, 0.07);

  /* Radius */
  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-xl: 28px;

  /* Transitions */
  --trans-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  --trans-normal: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --trans-bounce: 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

body {
  font-family: 'Cairo', sans-serif;
  background-color: var(--color-light);
  color: var(--color-dark);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: 'Cairo', sans-serif;
  font-weight: 700;
  color: var(--color-dark);
  letter-spacing: -0.02em;
}

.text-gradient {
  background: var(--grad-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.text-gradient-accent {
  background: var(--grad-accent);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Navbar Premium styling */
.navbar {
  background: rgba(255, 255, 255, 0.85) !important;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.3);
  box-shadow: var(--shadow-sm);
  transition: var(--trans-normal);
}

.navbar-brand img {
  transition: transform var(--trans-bounce);
}

.navbar-brand:hover img {
  transform: scale(1.05);
}

.nav-link {
  font-weight: 600 !important;
  color: var(--color-primary) !important;
  padding: 0.75rem 1rem !important;
  border-radius: 8px;
  transition: var(--trans-fast);
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-link:hover {
  background-color: rgba(59, 130, 246, 0.08);
  /* Primary color low opacity */
  color: var(--color-primary-light) !important;
  transform: translateY(-1px);
}

.nav-link img {
  transition: transform var(--trans-bounce);
}

.nav-link:hover img {
  transform: scale(1.15) rotate(5deg);
}

.dropdown-menu {
  border: none;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-xl);
  backdrop-filter: blur(10px);
  background: rgba(255, 255, 255, 0.95);
  animation: dropdownFade 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  transform-origin: top;
}

@keyframes dropdownFade {
  0% {
    opacity: 0;
    transform: scaleY(0.9) translateY(-10px);
  }

  100% {
    opacity: 1;
    transform: scaleY(1) translateY(0);
  }
}

.dropdown-item {
  font-weight: 500;
  padding: 0.6rem 1.2rem;
  transition: var(--trans-fast);
  border-radius: 6px;
  margin: 0 0.4rem;
  width: auto;
}

.dropdown-item:hover {
  background-color: var(--color-light);
  color: var(--color-primary);
  transform: translateX(-4px);
  /* RTL left translation */
}

/* Premium Cards */
.card-premium {
  border: none;
  border-radius: var(--radius-lg);
  background: var(--color-white);
  box-shadow: var(--shadow-md);
  transition: all var(--trans-bounce);
  overflow: hidden;
  position: relative;
  z-index: 1;
}

.card-premium::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border-radius: var(--radius-lg);
  background: var(--grad-primary);
  opacity: 0;
  z-index: -1;
  transition: opacity var(--trans-normal);
}

.card-premium:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-hover);
}

.card-glass {
  background: var(--grad-glass);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.4);
  box-shadow: var(--shadow-glass);
}

.card-img-wrapper {
  overflow: hidden;
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
}

.card-img-wrapper img {
  transition: transform 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.card-premium:hover .card-img-wrapper img {
  transform: scale(1.08);
  /* subtle zoom on hover */
}

/* Buttons */
.btn-premium {
  font-family: 'Cairo', sans-serif;
  font-weight: 700;
  border-radius: var(--radius-md);
  padding: 0.75rem 1.5rem;
  transition: all var(--trans-normal);
  border: none;
  position: relative;
  overflow: hidden;
  z-index: 1;
}

.btn-premium::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transition: left 0.5s ease;
  z-index: -1;
}

.btn-premium:hover::before {
  left: 100%;
}

.btn-premium:active {
  transform: scale(0.96);
}

.btn-primary-gradient {
  background: var(--grad-primary);
  color: white;
  box-shadow: 0 4px 15px rgba(30, 58, 138, 0.3);
}

.btn-primary-gradient:hover {
  background: var(--grad-primary);
  color: white;
  box-shadow: 0 8px 25px rgba(30, 58, 138, 0.4);
  transform: translateY(-2px);
}

.btn-secondary-gradient {
  background: var(--grad-secondary);
  color: white;
  box-shadow: 0 4px 15px rgba(5, 150, 105, 0.3);
}

.btn-secondary-gradient:hover {
  background: var(--grad-secondary);
  color: white;
  box-shadow: 0 8px 25px rgba(5, 150, 105, 0.4);
  transform: translateY(-2px);
}

/* Sections */
.section-title {
  position: relative;
  display: inline-block;
  font-weight: 800;
  color: var(--color-primary);
  margin-bottom: 2rem;
  padding-bottom: 0.5rem;
}

.section-title::after {
  content: '';
  position: absolute;
  bottom: 0px;
  right: 0;
  width: 60px;
  height: 4px;
  background: var(--grad-accent);
  border-radius: 4px;
  transition: width var(--trans-normal);
}

.section-title:hover::after {
  width: 100%;
}

/* Header Banner / Hero */
.hero-banner {
  background: var(--grad-dark);
  border-radius: var(--radius-lg);
  color: white;
  padding: 3rem 2rem;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

.hero-banner::after {
  content: '';
  position: absolute;
  right: -10%;
  top: -50%;
  width: 50%;
  height: 200%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.05) 0%, transparent 70%);
  transform: rotate(-15deg);
  pointer-events: none;
}

.hero-banner h1 {
  color: white;
  font-weight: 900;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

/* Custom Lists */
.list-group-premium .list-group-item {
  border: none;
  background: transparent;
  padding: 1rem 1.25rem;
  margin-bottom: 0.5rem;
  border-radius: var(--radius-md) !important;
  font-weight: 600;
  transition: var(--trans-fast);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.list-group-premium .list-group-item:hover {
  background: var(--color-light);
  transform: translateX(-6px);
}

.list-group-premium .list-group-item a {
  text-decoration: none;
  color: var(--color-dark);
  flex-grow: 1;
}

.list-group-premium .list-group-item:hover a {
  color: var(--color-primary);
}

/* Badges */
.badge-soft-primary {
  background-color: rgba(59, 130, 246, 0.1);
  color: var(--color-primary-light);
  border: 1px solid rgba(59, 130, 246, 0.2);
}

.badge-soft-warning {
  background-color: rgba(245, 158, 11, 0.1);
  color: var(--color-accent);
  border: 1px solid rgba(245, 158, 11, 0.2);
}

.badge-soft-success {
  background-color: rgba(16, 185, 129, 0.1);
  color: var(--color-secondary-light);
  border: 1px solid rgba(16, 185, 129, 0.2);
}

/* Micro animations */
.hover-scale {
  transition: transform var(--trans-bounce);
}

.hover-scale:hover {
  transform: scale(1.03);
}

.hover-lift {
  transition: transform var(--trans-normal), box-shadow var(--trans-normal);
}

.hover-lift:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-hover);
}

/* Footer */
.footer-premium {
  background: var(--color-white);
  border-top: 1px solid rgba(0, 0, 0, 0.05);
  padding: 4rem 0 2rem;
  margin-top: 4rem;
}

.footer-premium h5 {
  color: var(--color-primary);
  font-weight: 800;
  margin-bottom: 1.5rem;
}

.footer-premium p {
  color: var(--color-gray);
  font-size: 0.95rem;
}

.footer-premium a {
  color: var(--color-gray);
  text-decoration: none;
  transition: var(--trans-fast);
}

.footer-premium a:hover {
  color: var(--color-primary);
  transform: translateX(-4px);
  display: inline-block;
}

/* Utilities overrides */
.gap-3 {
  gap: 1rem !important;
}

.rounded-4 {
  border-radius: var(--radius-lg) !important;
}

.rounded-5 {
  border-radius: var(--radius-xl) !important;
}