/*
  ملف الأنماط الرئيسي لموقع سيجما - Sygma Website Main Styles
  ألوان الموقع - Site Colors (STRICT USE ONLY):
  - Primary: #4000A5
  - Dark: #1A1A1A
  - Cyan: #00C2FF
  - Teal: #2DD4BF
*/

:root {
  --primary-color: #4000A5;
  --dark-color: #1A1A1A;
  --cyan-color: #00C2FF;
  --teal-color: #2DD4BF;
  --white: #FFFFFF;
  --light-bg: #F8F9FA;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Cairo', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  color: var(--dark-color);
  line-height: 1.6;
}

/* RTL Support - دعم العربية */
body[dir="rtl"] {
  text-align: right;
}

body[dir="ltr"] {
  text-align: left;
}

/* Loading State - حالة التحميل */
.loading {
  opacity: 0;
  animation: fadeIn 0.6s ease-in forwards;
}

@keyframes fadeIn {
  to {
    opacity: 1;
  }
}

/* Sticky Header - الهيدر الثابت */
.navbar {
  background-color: var(--white);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
  position: sticky;
  top: 0;
  z-index: 9999;
}

.navbar-brand {
  font-size: 1.5rem;
  font-weight: bold;
  color: var(--primary-color) !important;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  transition: all 0.3s ease;
}

.navbar-brand:hover {
  transform: scale(1.05);
}

/* Logo Styles - أنماط اللوجو */
.navbar-brand .brand-logo {
  height: 45px;
  width: auto;
  max-width: 180px;
  object-fit: contain;
  transition: all 0.3s ease;
  filter: drop-shadow(0 2px 4px rgba(64, 0, 165, 0.2));
}

.navbar-brand:hover .brand-logo {
  filter: drop-shadow(0 4px 8px rgba(64, 0, 165, 0.3));
}

/* Brand Name - اسم الشركة */
.navbar-brand .brand-name {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--primary-color);
  margin-right: 0.5rem;
  margin-left: 0.5rem;
  transition: all 0.3s ease;
  text-shadow: 0 1px 2px rgba(64, 0, 165, 0.1);
  line-height: 1.3;
  max-width: 250px;
}

[dir="rtl"] .navbar-brand .brand-name {
  margin-right: 0.5rem;
  margin-left: 0;
}

[dir="ltr"] .navbar-brand .brand-name {
  margin-left: 0.5rem;
  margin-right: 0;
}

.navbar-brand:hover .brand-name {
  color: var(--cyan-color);
  text-shadow: 0 2px 4px rgba(0, 194, 255, 0.3);
}

/* Responsive Logo & Brand Name */
@media (max-width: 768px) {
  .navbar-brand .brand-logo {
    height: 35px;
    max-width: 120px;
  }

  .navbar-brand .brand-name {
    font-size: 1.1rem;
  }
}

@media (max-width: 480px) {
  .navbar-brand .brand-logo {
    height: 28px;
    max-width: 100px;
  }

  .navbar-brand .brand-name {
    font-size: 0.95rem;
  }
}

.nav-link {
  color: var(--dark-color) !important;
  font-weight: 500;
  transition: color 0.3s ease;
  padding: 0.5rem 1rem !important;
}

.nav-link:hover,
.nav-link.active {
  color: var(--primary-color) !important;
}

/* Language Switcher - مبدل اللغة */
.language-switcher {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.language-switcher .btn {
  padding: 0.375rem 0.75rem;
  font-size: 0.875rem;
  border-radius: 20px;
  transition: all 0.3s ease;
}

.language-switcher .btn-primary {
  background-color: var(--primary-color);
  border-color: var(--primary-color);
}

.language-switcher .btn-outline-primary {
  color: var(--primary-color);
  border-color: var(--primary-color);
}

.language-switcher .btn-outline-primary:hover {
  background-color: var(--primary-color);
  color: var(--white);
}

/* Hero Section - قسم البطل */
.hero-section {
  min-height: 90vh;
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--dark-color) 100%);
  color: var(--white);
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
}

.hero-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1200 120"><path fill="%2300C2FF" fill-opacity="0.1" d="M0,0V46.29c47.79,22.2,103.59,32.17,158,28,70.36-5.37,136.33-33.31,206.8-37.5C438.64,32.43,512.34,53.67,583,72.05c69.27,18,138.3,24.88,209.4,13.08,36.15-6,69.85-17.84,104.45-29.34C989.49,25,1113-14.29,1200,52.47V0Z" opacity=".25"/><path fill="%2300C2FF" fill-opacity="0.1" d="M0,0V15.81C13,36.92,27.64,56.86,47.69,72.05,99.41,111.27,165,111,224.58,91.58c31.15-10.15,60.09-26.07,89.67-39.8,40.92-19,84.73-46,130.83-49.67,36.26-2.85,70.9,9.42,98.6,31.56,31.77,25.39,62.32,62,103.63,73,40.44,10.79,81.35-6.69,119.13-24.28s75.16-39,116.92-43.05c59.73-5.85,113.28,22.88,168.9,38.84,30.2,8.66,59,6.17,87.09-7.5,22.43-10.89,48-26.93,60.65-49.24V0Z" opacity=".5"/><path fill="%2300C2FF" fill-opacity="0.1" d="M0,0V5.63C149.93,59,314.09,71.32,475.83,42.57c43-7.64,84.23-20.12,127.61-26.46,59-8.63,112.48,12.24,165.56,35.4C827.93,77.22,886,95.24,951.2,90c86.53-7,172.46-45.71,248.8-84.81V0Z"/></svg>') no-repeat bottom;
  background-size: cover;
  opacity: 0.3;
}

.hero-content {
  position: relative;
  z-index: 1;
  animation: slideInUp 1s ease-out;
}

.hero-section h1 {
  font-size: 3.5rem;
  font-weight: bold;
  margin-bottom: 1rem;
  animation: slideInUp 1s ease-out 0.2s both;
}

.hero-section .hero-subtitle {
  font-size: 1.5rem;
  margin-bottom: 1rem;
  color: var(--cyan-color);
  animation: slideInUp 1s ease-out 0.4s both;
}

.hero-section .hero-description {
  font-size: 1.1rem;
  margin-bottom: 2rem;
  animation: slideInUp 1s ease-out 0.6s both;
}

.btn-hero {
  padding: 0.875rem 2rem;
  font-size: 1.1rem;
  font-weight: 600;
  border-radius: 50px;
  transition: all 0.3s ease;
  background: linear-gradient(135deg, var(--cyan-color) 0%, var(--teal-color) 100%);
  border: none;
  color: var(--white);
  animation: slideInUp 1s ease-out 0.8s both;
}

.btn-hero:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 25px rgba(0, 194, 255, 0.3);
}

/* Hero Slider - سلايدر البطل */
.hero-slider-section {
  position: relative;
  overflow: hidden;
}

.hero-slider-section .carousel-item {
  height: 90vh;
  min-height: 600px;
  position: relative;
}

.hero-slide-bg {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.hero-slide-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(64, 0, 165, 0.15) 0%, rgba(15, 23, 42, 0.25) 100%);
  opacity: 1;
}

.hero-slide-content {
  position: relative;
  z-index: 2;
  color: var(--white);
  padding: 2rem 0;
  background: none !important;
  background-color: transparent !important;
  box-shadow: none !important;
  border: none !important;
}

/* Remove any box effects from carousel containers */
.carousel-item .container,
.carousel-item .row,
.carousel-item [class*="col-"] {
  background: none !important;
  background-color: transparent !important;
  box-shadow: none !important;
  border: none !important;
  border-radius: 0 !important;
  backdrop-filter: none !important;
}

/* Ensure text content has proper spacing */
.carousel-item .container {
  padding-left: 15px;
  padding-right: 15px;
}

.hero-slide-title {
  font-size: 3.5rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
  animation: slideInUp 1s ease-out;
  /* Enhanced multi-layer shadow for CRYSTAL CLEAR readability */
  text-shadow:
    0 0 20px rgba(0, 0, 0, 0.9),
    0 0 40px rgba(0, 0, 0, 0.8),
    2px 2px 10px rgba(0, 0, 0, 0.95),
    4px 4px 20px rgba(0, 0, 0, 0.85),
    -1px -1px 5px rgba(0, 0, 0, 0.7);
  color: #ffffff;
  line-height: 1.2;
  letter-spacing: -0.5px;
}

.hero-slide-subtitle {
  font-size: 1.8rem;
  margin-bottom: 1rem;
  color: #ffffff;
  font-weight: 600;
  animation: slideInUp 1s ease-out 0.2s both;
  /* Enhanced multi-layer shadow for CRYSTAL CLEAR readability */
  text-shadow:
    0 0 15px rgba(0, 0, 0, 0.9),
    0 0 30px rgba(0, 0, 0, 0.8),
    2px 2px 8px rgba(0, 0, 0, 0.95),
    3px 3px 15px rgba(0, 0, 0, 0.85),
    -1px -1px 4px rgba(0, 0, 0, 0.7);
  line-height: 1.4;
}

.hero-slide-description {
  font-size: 1.2rem;
  margin-bottom: 2rem;
  line-height: 1.8;
  animation: slideInUp 1s ease-out 0.4s both;
  /* Enhanced multi-layer shadow for CRYSTAL CLEAR readability */
  text-shadow:
    0 0 12px rgba(0, 0, 0, 0.9),
    0 0 25px rgba(0, 0, 0, 0.8),
    1px 1px 6px rgba(0, 0, 0, 0.95),
    2px 2px 12px rgba(0, 0, 0, 0.85),
    -1px -1px 3px rgba(0, 0, 0, 0.7);
  color: #ffffff;
  max-width: 800px;
}

/* Carousel Controls */
.carousel-control-prev,
.carousel-control-next {
  width: 60px;
  height: 60px;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(64, 0, 165, 0.7);
  border-radius: 50%;
  opacity: 0.8;
  transition: all 0.3s ease;
}

.carousel-control-prev {
  left: 20px;
}

.carousel-control-next {
  right: 20px;
}

/* RTL Support for Carousel Controls */
html[dir="rtl"] .carousel-control-prev {
  right: 20px;
  left: auto;
}

html[dir="rtl"] .carousel-control-next {
  left: 20px;
  right: auto;
}

.carousel-control-prev:hover,
.carousel-control-next:hover {
  opacity: 1;
  background: var(--primary-color);
}

.carousel-control-prev-icon,
.carousel-control-next-icon {
  width: 30px;
  height: 30px;
}

/* Carousel Indicators */
.carousel-indicators {
  bottom: 30px;
}

.carousel-indicators button {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.5);
  border: 2px solid var(--white);
  margin: 0 5px;
  transition: all 0.3s ease;
}

.carousel-indicators button.active {
  background-color: var(--cyan-color);
  width: 40px;
  border-radius: 6px;
}

/* Responsive Slider */
@media (max-width: 768px) {
  .hero-slider-section .carousel-item {
    height: 70vh;
    min-height: 500px;
  }

  .hero-slide-title {
    font-size: 2.2rem;
    margin-bottom: 1rem;
    line-height: 1.2;
  }

  .hero-slide-subtitle {
    font-size: 1.3rem;
    margin-bottom: 0.8rem;
  }

  .hero-slide-description {
    font-size: 1rem;
    margin-bottom: 1.5rem;
    line-height: 1.6;
  }

  .carousel-control-prev,
  .carousel-control-next {
    width: 40px;
    height: 40px;
  }

  .carousel-control-prev {
    left: 10px;
  }

  .carousel-control-next {
    right: 10px;
  }

  /* RTL Support for Responsive Carousel Controls */
  html[dir="rtl"] .carousel-control-prev {
    right: 10px;
    left: auto;
  }

  html[dir="rtl"] .carousel-control-next {
    left: 10px;
    right: auto;
  }
}

@keyframes slideInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Section Titles - عناوين الأقسام */
.section-title {
  font-size: 2.5rem;
  font-weight: bold;
  color: var(--dark-color);
  margin-bottom: 1rem;
  position: relative;
  display: inline-block;
}

.section-title::after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--primary-color), var(--cyan-color));
  border-radius: 2px;
}

[dir="rtl"] .section-title::after {
  right: 0;
  left: auto;
}

.section-subtitle {
  font-size: 1.2rem;
  color: var(--primary-color);
  margin-bottom: 3rem;
}

/* About Section - قسم من نحن */
.about-section {
  padding: 80px 0;
  background-color: var(--light-bg);
}

/* Service Cards - بطاقات الخدمات */
.service-card {
  background: var(--white);
  border-radius: 15px;
  padding: 2rem;
  transition: all 0.3s ease;
  border: 2px solid transparent;
  height: 100%;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  display: block;
}

.service-card:hover {
  transform: translateY(-10px);
  border-color: var(--primary-color);
  box-shadow: 0 15px 40px rgba(64, 0, 165, 0.15);
}

.service-icon {
  width: 80px;
  height: 80px;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  border-radius: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  color: var(--white);
  margin-bottom: 1.5rem;
  transition: all 0.3s ease;
  box-shadow: 0 8px 16px rgba(102, 126, 234, 0.3);
}

/* Colorful gradient variations for service icons */
.service-card:nth-child(6n+1) .service-icon {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  box-shadow: 0 8px 16px rgba(102, 126, 234, 0.3);
}

.service-card:nth-child(6n+2) .service-icon {
  background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
  box-shadow: 0 8px 16px rgba(240, 147, 251, 0.3);
}

.service-card:nth-child(6n+3) .service-icon {
  background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
  box-shadow: 0 8px 16px rgba(79, 172, 254, 0.3);
}

.service-card:nth-child(6n+4) .service-icon {
  background: linear-gradient(135deg, #43e97b 0%, #38f9d7 100%);
  box-shadow: 0 8px 16px rgba(67, 233, 123, 0.3);
}

.service-card:nth-child(6n+5) .service-icon {
  background: linear-gradient(135deg, #fa709a 0%, #fee140 100%);
  box-shadow: 0 8px 16px rgba(250, 112, 154, 0.3);
}

.service-card:nth-child(6n+6) .service-icon {
  background: linear-gradient(135deg, #30cfd0 0%, #330867 100%);
  box-shadow: 0 8px 16px rgba(48, 207, 208, 0.3);
}

.service-card:hover .service-icon {
  transform: scale(1.1) rotate(5deg);
  box-shadow: 0 12px 24px rgba(102, 126, 234, 0.4);
}

.service-card h3 {
  color: var(--dark-color);
  font-size: 1.5rem;
  margin-bottom: 1rem;
}

.service-card p {
  color: #6c757d;
  margin-bottom: 1.5rem;
  line-height: 1.6;
}

.service-card .btn-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 24px;
  background: linear-gradient(135deg, var(--primary-color) 0%, #764ba2 100%);
  color: white !important;
  text-decoration: none;
  border-radius: 50px;
  font-weight: 600;
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px rgba(64, 0, 165, 0.3);
}

.service-card .btn-link:hover {
  transform: translateX(-5px);
  box-shadow: 0 6px 16px rgba(64, 0, 165, 0.4);
  background: linear-gradient(135deg, #764ba2 0%, var(--primary-color) 100%);
}

.service-card .btn-link i {
  transition: transform 0.3s ease;
}

.service-card .btn-link:hover i {
  transform: translateX(5px);
}

/* Portfolio/Project Cards - بطاقات المشاريع */
.project-card {
  border-radius: 15px;
  overflow: hidden;
  position: relative;
  height: 350px;
  cursor: pointer;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  display: block;
  background: var(--white);
}

.project-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.project-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(64, 0, 165, 0.95), rgba(0, 194, 255, 0.95));
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  opacity: 0;
  transition: opacity 0.5s ease;
  color: var(--white);
  text-align: center;
  padding: 2rem;
}

.project-card:hover img {
  transform: scale(1.1);
}

.project-card:hover .project-overlay {
  opacity: 1;
}

/* Statistics - الإحصائيات */
.stats-section {
  background: linear-gradient(135deg, var(--dark-color) 0%, var(--primary-color) 100%);
  color: var(--white);
  padding: 80px 0;
}

.stat-box {
  text-align: center;
  padding: 2rem;
}

.stat-number {
  font-size: 3rem;
  font-weight: bold;
  color: var(--cyan-color);
  margin-bottom: 0.5rem;
}

.stat-label {
  font-size: 1.2rem;
  color: var(--white);
}

/* Mobile Stats - 2 per row */
@media (max-width: 767px) {
  .stats-section {
    padding: 50px 0;
  }

  .stat-box {
    padding: 1rem 0.5rem;
  }

  .stat-number {
    font-size: 2rem;
  }

  .stat-label {
    font-size: 0.9rem;
  }
}

/* Testimonials - الشهادات */
.testimonial-card {
  background: var(--white);
  border-radius: 15px;
  padding: 2.5rem;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
  text-align: center;
  height: 100%;
}

.testimonial-img {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid var(--primary-color);
  margin-bottom: 1.5rem;
}

.testimonial-text {
  font-style: italic;
  margin-bottom: 1.5rem;
  color: var(--dark-color);
}

.testimonial-author {
  font-weight: bold;
  color: var(--primary-color);
}

.testimonial-position {
  color: #666;
  font-size: 0.9rem;
}

.rating {
  color: #FFD700;
  font-size: 1.2rem;
  margin-bottom: 1rem;
}

/* Partners Logos - شعارات الشركاء */
.partner-logo {
  height: 80px;
  object-fit: contain;
  filter: grayscale(100%);
  opacity: 0.6;
  transition: all 0.3s ease;
}

.partner-logo:hover {
  filter: grayscale(0%);
  opacity: 1;
}

/* Blog Cards - بطاقات المدونة */
.blog-card {
  border-radius: 15px;
  overflow: hidden;
  background: var(--white);
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease;
  height: 100%;
}

.blog-card:hover {
  transform: translateY(-5px);
}

.blog-img {
  width: 100%;
  height: 250px;
  object-fit: cover;
}

.blog-content {
  padding: 1.5rem;
}

.blog-meta {
  display: flex;
  justify-content: space-between;
  margin-bottom: 1rem;
  font-size: 0.875rem;
  color: #666;
}

.blog-title {
  font-size: 1.3rem;
  font-weight: bold;
  color: var(--dark-color);
  margin-bottom: 1rem;
}

.blog-excerpt {
  color: #666;
  margin-bottom: 1rem;
}

.btn-read-more {
  color: var(--primary-color);
  font-weight: 600;
  text-decoration: none;
  transition: color 0.3s ease;
}

.btn-read-more:hover {
  color: var(--cyan-color);
}

/* Footer - التذييل */
.footer {
  background-color: var(--dark-color);
  color: var(--white);
  padding: 60px 0 20px;
}

/* Footer Brand - العلامة التجارية في الفوتر */
.footer-brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.footer-brand .footer-logo-img {
  height: 40px;
  width: auto;
  max-width: 180px;
  object-fit: contain;
  transition: all 0.3s ease;
  filter: brightness(1.2) drop-shadow(0 2px 4px rgba(255, 255, 255, 0.1));
}

.footer-brand:hover .footer-logo-img {
  filter: brightness(1.3) drop-shadow(0 4px 8px rgba(0, 194, 255, 0.3));
  transform: scale(1.05);
}

.footer-brand .footer-brand-name {
  margin: 0;
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--white);
  text-shadow: 0 2px 4px rgba(255, 255, 255, 0.1);
  transition: all 0.3s ease;
}

.footer-brand:hover .footer-brand-name {
  color: var(--cyan-color);
  text-shadow: 0 2px 6px rgba(0, 194, 255, 0.4);
}

@media (max-width: 768px) {
  .footer-brand .footer-logo-img {
    height: 32px;
  }

  .footer-brand .footer-brand-name {
    font-size: 1.1rem;
  }

  /* Mobile footer - more compact horizontal layout */
  .footer {
    padding: 40px 0 15px;
  }

  .footer .row.g-4 {
    row-gap: 1.5rem !important;
  }

  /* First column (brand/description) - full width but more compact */
  .footer .col-lg-4.col-md-6:first-child {
    text-align: center;
  }

  .footer .col-lg-4.col-md-6:first-child .footer-brand {
    justify-content: center;
  }

  .footer .col-lg-4.col-md-6:first-child p {
    font-size: 0.85rem;
    margin-bottom: 0.5rem;
  }

  .footer .col-lg-4.col-md-6:first-child .social-links {
    margin-top: 0.75rem !important;
    justify-content: center;
    display: flex;
  }

  /* Quick Links and Services - side by side on mobile */
  .footer .col-lg-2.col-md-6,
  .footer .col-lg-3.col-md-6:not(:last-child) {
    width: 50%;
    flex: 0 0 50%;
    text-align: left;
  }

  .footer .col-lg-2.col-md-6 h5,
  .footer .col-lg-3.col-md-6 h5 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.75rem !important;
    text-align: left;
    display: block !important;
    visibility: visible !important;
    color: #fff;
    border-bottom: 1px solid rgba(255,255,255,0.2);
    padding-bottom: 0.5rem;
  }

  html[lang="ar"] .footer .col-lg-2.col-md-6 h5,
  html[lang="ar"] .footer .col-lg-3.col-md-6 h5,
  [dir="rtl"] .footer .col-lg-2.col-md-6 h5,
  [dir="rtl"] .footer .col-lg-3.col-md-6 h5 {
    text-align: right;
  }

  .footer .col-lg-2.col-md-6 .list-unstyled,
  .footer .col-lg-3.col-md-6:not(:last-child) .list-unstyled {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    padding-left: 1rem;
  }

  .footer .col-lg-2.col-md-6 .list-unstyled li,
  .footer .col-lg-3.col-md-6 .list-unstyled li {
    margin-bottom: 0.5rem !important;
    font-size: 0.85rem;
    text-align: left;
  }

  .footer .col-lg-2.col-md-6 .list-unstyled li a,
  .footer .col-lg-3.col-md-6 .list-unstyled li a {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
  }

  /* Arabic RTL footer alignment */
  html[lang="ar"] .footer .col-lg-2.col-md-6,
  html[lang="ar"] .footer .col-lg-3.col-md-6:not(:last-child),
  [dir="rtl"] .footer .col-lg-2.col-md-6,
  [dir="rtl"] .footer .col-lg-3.col-md-6:not(:last-child) {
    text-align: right;
  }

  html[lang="ar"] .footer .col-lg-2.col-md-6 .list-unstyled,
  html[lang="ar"] .footer .col-lg-3.col-md-6:not(:last-child) .list-unstyled,
  [dir="rtl"] .footer .col-lg-2.col-md-6 .list-unstyled,
  [dir="rtl"] .footer .col-lg-3.col-md-6:not(:last-child) .list-unstyled {
    align-items: flex-end;
    padding-left: 0;
    padding-right: 1rem;
  }

  html[lang="ar"] .footer .col-lg-2.col-md-6 .list-unstyled li,
  html[lang="ar"] .footer .col-lg-3.col-md-6 .list-unstyled li,
  [dir="rtl"] .footer .col-lg-2.col-md-6 .list-unstyled li,
  [dir="rtl"] .footer .col-lg-3.col-md-6 .list-unstyled li {
    text-align: right;
  }

  /* Contact Info - full width but more compact */
  .footer .col-lg-3.col-md-6:last-child {
    width: 100%;
    flex: 0 0 100%;
    text-align: center;
  }

  .footer .col-lg-3.col-md-6:last-child .list-unstyled {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem 1.5rem;
  }

  .footer .col-lg-3.col-md-6:last-child .list-unstyled li {
    margin-bottom: 0 !important;
    white-space: nowrap;
    font-size: 0.85rem;
  }

  .footer hr {
    margin: 1rem 0 !important;
    border-color: rgba(255,255,255,0.15) !important;
  }

  /* Copyright section - clear and on its own line */
  .footer .text-center p {
    font-size: 0.9rem;
    padding: 0.75rem 0;
    margin: 0;
    color: #fff;
    font-weight: 500;
    display: block;
    width: 100%;
    text-align: center;
  }

  .footer .text-center p::before {
    content: "";
    display: block;
    margin-bottom: 0.5rem;
  }
}

.footer a {
  color: var(--white);
  text-decoration: none;
  transition: color 0.3s ease;
}

.footer a:hover {
  color: var(--cyan-color);
}

/* Add spacing between icons and text in footer - Global */
.footer .list-unstyled li i {
  margin-right: 0.5rem;
}

html[dir="rtl"] .footer .list-unstyled li i {
  margin-right: 0;
  margin-left: 0.5rem;
}

.social-links a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background-color: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  margin-right: 10px;
  transition: all 0.3s ease;
  color: #fff;
}

.social-links a i {
  color: #fff;
  font-size: 1rem;
  transition: all 0.3s ease;
}

[dir="rtl"] .social-links a {
  margin-right: 0;
  margin-left: 10px;
}

.social-links a:hover {
  background-color: var(--primary-color);
  border-color: var(--primary-color);
  transform: translateY(-5px);
  box-shadow: 0 8px 20px rgba(64, 0, 165, 0.4);
}

.social-links a:hover i {
  color: #fff;
  transform: scale(1.1);
}

/* Individual social icon colors on hover */
.social-links a[aria-label="Facebook"]:hover {
  background-color: #1877F2;
  border-color: #1877F2;
  box-shadow: 0 8px 20px rgba(24, 119, 242, 0.4);
}

.social-links a[aria-label="Twitter"]:hover {
  background-color: #1DA1F2;
  border-color: #1DA1F2;
  box-shadow: 0 8px 20px rgba(29, 161, 242, 0.4);
}

.social-links a[aria-label="LinkedIn"]:hover {
  background-color: #0A66C2;
  border-color: #0A66C2;
  box-shadow: 0 8px 20px rgba(10, 102, 194, 0.4);
}

.social-links a[aria-label="Instagram"]:hover {
  background: linear-gradient(45deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888);
  border-color: transparent;
  box-shadow: 0 8px 20px rgba(225, 48, 108, 0.4);
}

.social-links a[aria-label="YouTube"]:hover {
  background-color: #FF0000;
  border-color: #FF0000;
  box-shadow: 0 8px 20px rgba(255, 0, 0, 0.4);
}

/* Back to Top Button - زر العودة للأعلى */
#back-to-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 50px;
  height: 50px;
  background: linear-gradient(135deg, var(--primary-color), var(--cyan-color));
  color: var(--white);
  border: none;
  border-radius: 50%;
  display: none;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  cursor: pointer;
  transition: all 0.3s ease;
  z-index: 999;
  box-shadow: 0 5px 15px rgba(64, 0, 165, 0.3);
}

[dir="rtl"] #back-to-top {
  right: auto;
  left: 30px;
}

#back-to-top:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 25px rgba(64, 0, 165, 0.5);
}

#back-to-top.show {
  display: flex;
}

/* Responsive - الاستجابة */
@media (max-width: 768px) {
  .hero-section h1 {
    font-size: 2rem;
  }

  .hero-section .hero-subtitle {
    font-size: 1.2rem;
  }

  .section-title {
    font-size: 2rem;
  }

  .stat-number {
    font-size: 2rem;
  }
}

/* Animations for scroll effects - تأثيرات التمرير */
.fade-in-up {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.6s ease;
}

.fade-in-up.animate {
  opacity: 1;
  transform: translateY(0);
}

/* ===================================
   PAGE HEADER - رأس الصفحة
   =================================== */
.page-header {
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--dark-color) 100%);
  padding: 4rem 0 2rem;
  color: var(--white);
  position: relative;
  overflow: hidden;
}

.page-header::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url('data:image/svg+xml,<svg width="100" height="100" xmlns="http://www.w3.org/2000/svg"><rect fill="rgba(255,255,255,0.05)" width="50" height="50"/></svg>');
  opacity: 0.1;
}

.page-header h1 {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 1rem;
  position: relative;
  z-index: 1;
}

.page-header .breadcrumb {
  background: transparent;
  padding: 0;
  margin: 0;
  position: relative;
  z-index: 1;
}

.page-header .breadcrumb-item {
  color: rgba(255, 255, 255, 0.8);
}

.page-header .breadcrumb-item a {
  color: var(--white);
  text-decoration: none;
  transition: color 0.3s ease;
}

.page-header .breadcrumb-item a:hover {
  color: var(--cyan-color);
}

.page-header .breadcrumb-item.active {
  color: var(--cyan-color);
}

.page-header .breadcrumb-item + .breadcrumb-item::before {
  color: rgba(255, 255, 255, 0.6);
}

/* ===================================
   PORTFOLIO - المشاريع
   =================================== */
.category-filter {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: center;
}

.filter-btn {
  padding: 0.6rem 1.5rem;
  border: 2px solid var(--primary-color);
  background: transparent;
  color: var(--primary-color);
  border-radius: 50px;
  text-decoration: none;
  font-weight: 600;
  transition: all 0.3s ease;
  display: inline-block;
}

.filter-btn:hover,
.filter-btn.active {
  background: var(--primary-color);
  color: var(--white);
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(64, 0, 165, 0.3);
}

.project-card {
  background: var(--white);
  border-radius: 15px;
  overflow: hidden;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
  height: 100%;
}

.project-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
}

.project-card .project-image {
  position: relative;
  overflow: hidden;
  padding-top: 66.67%; /* 3:2 aspect ratio */
}

.project-card .project-image img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.project-card:hover .project-image img {
  transform: scale(1.1);
}

.project-card .project-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(64, 0, 165, 0.95), rgba(0, 194, 255, 0.95));
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.project-card:hover .project-overlay {
  opacity: 1;
}

.project-card .project-info {
  padding: 1.5rem;
}

.project-card .project-category {
  display: inline-block;
  background: var(--cyan-color);
  color: var(--white);
  padding: 0.3rem 1rem;
  border-radius: 20px;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
}

.project-card .project-info h3,
.project-card .project-info h4 {
  font-size: 1.3rem;
  margin-bottom: 0.75rem;
  color: var(--dark-color);
}

.project-card .project-info h3 a,
.project-card .project-info h4 a {
  color: var(--dark-color);
  text-decoration: none;
  transition: color 0.3s ease;
}

.project-card .project-info h3 a:hover,
.project-card .project-info h4 a:hover {
  color: var(--primary-color);
}

.project-card .project-info p {
  color: #666;
  margin-bottom: 0;
}

/* ===================================
   PROJECT DETAIL - تفاصيل المشروع
   =================================== */
.project-detail-section .sidebar-box,
.service-detail-section .sidebar-box,
.blog-sidebar .sidebar-box {
  background: var(--white);
  padding: 1.5rem;
  border-radius: 10px;
  box-shadow: 0 3px 15px rgba(0, 0, 0, 0.1);
}

.project-detail-section .sidebar-box h4,
.service-detail-section .sidebar-box h4,
.blog-sidebar .sidebar-box h4 {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--dark-color);
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 2px solid var(--cyan-color);
}

.share-buttons {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.share-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  border-radius: 5px;
  text-decoration: none;
  color: var(--white);
  font-weight: 500;
  transition: all 0.3s ease;
}

.share-btn.facebook {
  background: #1877f2;
}

.share-btn.twitter {
  background: #1da1f2;
}

.share-btn.linkedin {
  background: #0077b5;
}

.share-btn.whatsapp {
  background: #25d366;
}

.share-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
  color: var(--white);
}

.cta-box {
  background: linear-gradient(135deg, var(--primary-color), var(--cyan-color)) !important;
  color: var(--white) !important;
}

.cta-box h4 {
  color: var(--white) !important;
  border-color: rgba(255, 255, 255, 0.3) !important;
}

.cta-box p {
  color: rgba(255, 255, 255, 0.9);
}

.tech-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.tech-tag {
  display: inline-block;
  background: var(--light-bg);
  color: var(--primary-color);
  padding: 0.4rem 1rem;
  border-radius: 5px;
  font-size: 0.9rem;
  font-weight: 600;
}

/* ===================================
   SERVICE DETAIL - تفاصيل الخدمة
   =================================== */
.service-icon-large {
  width: 80px;
  height: 80px;
  background: linear-gradient(135deg, var(--primary-color), var(--cyan-color));
  color: var(--white);
  border-radius: 15px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.5rem;
  margin-bottom: 1.5rem;
  box-shadow: 0 5px 20px rgba(64, 0, 165, 0.3);
}

.feature-item {
  padding: 0.75rem;
  background: var(--light-bg);
  border-radius: 8px;
  margin-bottom: 0.5rem;
  display: flex;
  align-items: center;
}

.feature-item i {
  font-size: 1.25rem;
}

.process-timeline {
  position: relative;
  padding-left: 3rem;
}

[dir="rtl"] .process-timeline {
  padding-left: 0;
  padding-right: 3rem;
}

.process-step {
  position: relative;
  padding-bottom: 2rem;
}

.process-step:last-child {
  padding-bottom: 0;
}

.process-step::before {
  content: '';
  position: absolute;
  left: -2.25rem;
  top: 0;
  bottom: -2rem;
  width: 2px;
  background: var(--cyan-color);
}

[dir="rtl"] .process-step::before {
  left: auto;
  right: -2.25rem;
}

.process-step:last-child::before {
  display: none;
}

.step-number {
  position: absolute;
  left: -3rem;
  top: 0;
  width: 40px;
  height: 40px;
  background: linear-gradient(135deg, var(--primary-color), var(--cyan-color));
  color: var(--white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.1rem;
  box-shadow: 0 3px 10px rgba(64, 0, 165, 0.3);
}

[dir="rtl"] .step-number {
  left: auto;
  right: -3rem;
}

.step-content h5 {
  color: var(--primary-color);
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.service-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.service-list li {
  margin-bottom: 0.75rem;
}

.service-list li a {
  display: flex;
  align-items: center;
  padding: 0.75rem;
  background: var(--light-bg);
  border-radius: 8px;
  text-decoration: none;
  color: var(--dark-color);
  transition: all 0.3s ease;
  border-left: 3px solid transparent;
}

[dir="rtl"] .service-list li a {
  border-left: none;
  border-right: 3px solid transparent;
}

.service-list li a:hover,
.service-list li.active a {
  background: var(--primary-color);
  color: var(--white);
  border-left-color: var(--cyan-color);
  transform: translateX(5px);
}

[dir="rtl"] .service-list li a:hover,
[dir="rtl"] .service-list li.active a {
  border-right-color: var(--cyan-color);
  transform: translateX(-5px);
}

.support-box {
  background: linear-gradient(135deg, var(--dark-color), var(--primary-color)) !important;
  color: var(--white) !important;
  text-align: center;
}

.support-box h4,
.support-box h5 {
  color: var(--white) !important;
}

.support-icon {
  width: 60px;
  height: 60px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  margin: 0 auto 1rem;
}

.support-phone {
  display: inline-block;
  color: var(--white);
  text-decoration: none;
  font-weight: 600;
  padding: 0.75rem 1.5rem;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 30px;
  margin-top: 1rem;
  transition: all 0.3s ease;
}

.support-phone:hover {
  background: rgba(255, 255, 255, 0.3);
  color: var(--white);
}

/* ===================================
   TEAM PAGE - صفحة الفريق
   =================================== */
.team-intro {
  background: linear-gradient(135deg, rgba(64, 0, 165, 0.05), rgba(0, 194, 255, 0.05));
}

.team-card {
  background: var(--white);
  border-radius: 15px;
  overflow: hidden;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
  height: 100%;
}

.team-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
}

.team-card .team-image {
  position: relative;
  overflow: hidden;
}

.team-card .team-photo {
  width: 100%;
  height: 300px;
  object-fit: cover;
  object-position: top center;
  transition: transform 0.5s ease;
}

.team-card:hover .team-photo {
  transform: scale(1.1);
}

.team-social-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(to top, rgba(64, 0, 165, 0.95), transparent);
  padding: 1.5rem;
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  transform: translateY(100%);
  transition: transform 0.3s ease;
}

.team-card:hover .team-social-overlay {
  transform: translateY(0);
}

.team-social-overlay a {
  width: 40px;
  height: 40px;
  background: var(--white);
  color: var(--primary-color);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  transition: all 0.3s ease;
}

.team-social-overlay a:hover {
  background: var(--cyan-color);
  color: var(--white);
  transform: scale(1.1);
}

.team-card .team-info {
  padding: 1.5rem;
  text-align: center;
}

.team-card .team-info h4 {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--dark-color);
  margin-bottom: 0.5rem;
}

.team-card .team-position {
  color: var(--primary-color);
  font-weight: 600;
  margin-bottom: 0.75rem;
}

.team-card .team-bio {
  color: #666;
  font-size: 0.9rem;
  margin-bottom: 0;
}

.join-team.bg-gradient {
  background: linear-gradient(135deg, var(--primary-color), var(--cyan-color));
}

.value-card {
  padding: 2rem;
  background: var(--white);
  border-radius: 15px;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
}

.value-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
}

.value-icon {
  width: 70px;
  height: 70px;
  background: linear-gradient(135deg, var(--primary-color), var(--cyan-color));
  color: var(--white);
  border-radius: 15px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  margin: 0 auto 1.5rem;
  box-shadow: 0 5px 15px rgba(64, 0, 165, 0.3);
}

.value-card h4 {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--dark-color);
  margin-bottom: 1rem;
}

.value-card p {
  color: #666;
  margin-bottom: 0;
}

/* ===================================
   BLOG - المدونة
   =================================== */
.blog-card {
  background: var(--white);
  border-radius: 15px;
  overflow: hidden;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
}

.blog-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
}

.blog-card .blog-image {
  position: relative;
  overflow: hidden;
  height: 250px;
}

.blog-card .blog-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.blog-card:hover .blog-image img {
  transform: scale(1.1);
}

.blog-date {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: linear-gradient(135deg, var(--primary-color), var(--cyan-color));
  color: var(--white);
  padding: 0.75rem;
  border-radius: 10px;
  text-align: center;
  min-width: 60px;
}

[dir="rtl"] .blog-date {
  right: auto;
  left: 1rem;
}

.blog-date .day {
  display: block;
  font-size: 1.5rem;
  font-weight: 700;
  line-height: 1;
}

.blog-date .month {
  display: block;
  font-size: 0.85rem;
  text-transform: uppercase;
}

.blog-card .blog-content {
  padding: 1.5rem;
}

.blog-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  font-size: 0.85rem;
  color: #666;
}

.blog-meta .meta-item {
  display: flex;
  align-items: center;
}

.blog-category {
  color: var(--primary-color) !important;
  font-weight: 600;
}

.blog-title {
  font-size: 1.3rem;
  margin-bottom: 0.75rem;
}

.blog-title a {
  color: var(--dark-color);
  text-decoration: none;
  transition: color 0.3s ease;
}

.blog-title a:hover {
  color: var(--primary-color);
}

.blog-excerpt {
  color: #666;
  margin-bottom: 1rem;
}

.blog-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 1rem;
  border-top: 1px solid #eee;
}

.read-more {
  color: var(--primary-color);
  text-decoration: none;
  font-weight: 600;
  transition: all 0.3s ease;
}

.read-more:hover {
  color: var(--cyan-color);
  gap: 0.5rem;
}

.reading-time {
  color: #999;
  font-size: 0.85rem;
}

/* ===================================
   BLOG DETAIL - تفاصيل المقال
   =================================== */
.post-meta {
  padding: 1rem;
  background: var(--light-bg);
  border-radius: 10px;
}

.post-meta .meta-item {
  color: #666;
  font-size: 0.95rem;
}

.post-content {
  font-size: 1.1rem;
  line-height: 1.8;
  color: var(--dark-color);
}

.post-content h2,
.post-content h3,
.post-content h4 {
  color: var(--primary-color);
  margin-top: 2rem;
  margin-bottom: 1rem;
}

.post-content p {
  margin-bottom: 1.5rem;
}

.post-content img {
  max-width: 100%;
  height: auto;
  border-radius: 10px;
  margin: 2rem 0;
}

.post-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
}

.tag-item {
  display: inline-block;
  background: var(--light-bg);
  color: var(--primary-color);
  padding: 0.4rem 1rem;
  border-radius: 20px;
  font-size: 0.9rem;
  font-weight: 600;
}

.author-bio {
  border-left: 4px solid var(--primary-color);
}

[dir="rtl"] .author-bio {
  border-left: none;
  border-right: 4px solid var(--primary-color);
}

.recent-posts {
  list-style: none;
  padding: 0;
  margin: 0;
}

.recent-posts li {
  margin-bottom: 1rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid #eee;
}

.recent-posts li:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.recent-post-item {
  display: flex;
  gap: 1rem;
}

.recent-post-item img {
  width: 70px;
  height: 70px;
  object-fit: cover;
  border-radius: 8px;
  flex-shrink: 0;
}

.recent-post-content h6 {
  font-size: 0.95rem;
  margin-bottom: 0.25rem;
}

.recent-post-content h6 a {
  color: var(--dark-color);
  text-decoration: none;
  transition: color 0.3s ease;
}

.recent-post-content h6 a:hover {
  color: var(--primary-color);
}

.category-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.category-list li {
  margin-bottom: 0.5rem;
}

.category-list li a {
  display: block;
  padding: 0.5rem 0;
  color: var(--dark-color);
  text-decoration: none;
  transition: all 0.3s ease;
  border-bottom: 1px solid #eee;
}

.category-list li a:hover {
  color: var(--primary-color);
  padding-left: 0.5rem;
}

[dir="rtl"] .category-list li a:hover {
  padding-left: 0;
  padding-right: 0.5rem;
}

.newsletter-box {
  background: linear-gradient(135deg, var(--primary-color), var(--cyan-color)) !important;
  color: var(--white) !important;
}

.newsletter-box h4 {
  color: var(--white) !important;
}

.newsletter-box p {
  color: rgba(255, 255, 255, 0.9);
}

/* ===================================
   PAGINATION - الترقيم
   =================================== */
.pagination {
  gap: 0.5rem;
}

.pagination .page-link {
  border: 2px solid var(--primary-color);
  color: var(--primary-color);
  border-radius: 8px;
  padding: 0.6rem 1rem;
  font-weight: 600;
  transition: all 0.3s ease;
}

.pagination .page-link:hover {
  background: var(--primary-color);
  color: var(--white);
  transform: translateY(-2px);
}

.pagination .page-item.active .page-link {
  background: var(--primary-color);
  border-color: var(--primary-color);
  color: var(--white);
  box-shadow: 0 5px 15px rgba(64, 0, 165, 0.3);
}

.pagination .page-item.disabled .page-link {
  border-color: #ddd;
  color: #999;
}

/* ===================================
   CONTACT INFO BOX - صندوق معلومات الاتصال
   =================================== */
.contact-info-box {
  padding: 1.5rem;
  background: var(--light-bg);
  border-radius: 10px;
  text-align: center;
  transition: all 0.3s ease;
}

.contact-info-box:hover {
  background: var(--white);
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
  transform: translateY(-5px);
}

.contact-info-box i {
  font-size: 2.5rem;
  color: var(--primary-color);
  margin-bottom: 1rem;
}

.contact-info-box h5 {
  font-weight: 700;
  color: var(--dark-color);
  margin-bottom: 0.75rem;
}

.contact-info-box p,
.contact-info-box a {
  color: #666;
  margin-bottom: 0;
}

.contact-info-box a {
  text-decoration: none;
  transition: color 0.3s ease;
}

.contact-info-box a:hover {
  color: var(--primary-color);
}

/* ===================================
   RESPONSIVE UPDATES
   =================================== */
@media (max-width: 768px) {
  .page-header h1 {
    font-size: 2rem;
  }

  .team-card .team-photo {
    height: 250px;
  }

  .blog-card .blog-image {
    height: 200px;
  }

  .process-timeline {
    padding-left: 2rem;
  }

  [dir="rtl"] .process-timeline {
    padding-right: 2rem;
  }

  .step-number {
    left: -2rem;
    width: 35px;
    height: 35px;
    font-size: 1rem;
  }

  [dir="rtl"] .step-number {
    right: -2rem;
  }

  .navbar-brand .brand-logo {
    height: 35px;
  }

  .navbar-brand .brand-name {
    font-size: 1.1rem;
  }
}

@media (max-width: 480px) {
  .page-header h1 {
    font-size: 1.75rem;
  }

  .category-filter {
    gap: 0.5rem;
  }

  .filter-btn {
    padding: 0.5rem 1rem;
    font-size: 0.9rem;
  }

  .share-buttons {
    flex-direction: column;
  }

  .share-btn {
    justify-content: center;
  }

  .navbar-brand .brand-logo {
    height: 28px;
  }

  .navbar-brand .brand-name {
    font-size: 0.95rem;
  }
}

/* ===============================================
   TEAM MEMBER PROFILE PAGE - صفحة البروفايل
   =============================================== */

.team-member-profile {
  background: var(--light-bg);
}

/* Profile Card */
.profile-card {
  background: var(--white);
  border-radius: 20px;
  padding: 2rem;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  top: 100px;
}

.profile-photo-wrapper {
  position: relative;
  margin-bottom: 1.5rem;
}

.profile-photo {
  width: 100%;
  height: auto;
  aspect-ratio: 1/1;
  object-fit: cover;
  border-radius: 20px;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.15);
}

.profile-info {
  text-align: center;
}

.profile-name {
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--dark-color);
  margin-bottom: 0.5rem;
}

.profile-position {
  font-size: 1.1rem;
  color: var(--primary-color);
  font-weight: 600;
  margin-bottom: 0;
}

/* Contact Information */
.profile-contact h5,
.profile-social h5 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--dark-color);
  margin-bottom: 1rem;
  text-align: start;
}

.contact-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem;
  background: var(--light-bg);
  border-radius: 10px;
  margin-bottom: 0.5rem;
  transition: all 0.3s ease;
}

.contact-item:hover {
  background: var(--primary-color);
  transform: translateX(-5px);
}

.contact-item i {
  color: var(--primary-color);
  font-size: 1.1rem;
  min-width: 20px;
}

.contact-item:hover i {
  color: var(--white);
}

.contact-item a {
  color: var(--dark-color);
  text-decoration: none;
  font-size: 0.95rem;
  transition: all 0.3s ease;
}

.contact-item:hover a {
  color: var(--white);
}

/* Social Links */
.social-links-list {
  display: flex;
  gap: 0.75rem;
  justify-content: flex-start;
  flex-wrap: wrap;
}

.social-link {
  width: 45px;
  height: 45px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  color: var(--white);
  text-decoration: none;
  transition: all 0.3s ease;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.15);
}

.social-link:hover {
  transform: translateY(-3px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.social-link.linkedin {
  background: #0077B5;
}

.social-link.twitter {
  background: #1DA1F2;
}

.social-link.facebook {
  background: #1877F2;
}

.social-link.github {
  background: #333;
}

.social-link.linkedin:hover {
  background: #005885;
}

.social-link.twitter:hover {
  background: #0d8bd9;
}

.social-link.facebook:hover {
  background: #0e5fc4;
}

.social-link.github:hover {
  background: #000;
}

/* Profile Actions */
.profile-actions {
  margin-top: 1.5rem;
}

.profile-actions .btn {
  padding: 0.85rem 1.5rem;
  font-weight: 600;
  border-radius: 10px;
  transition: all 0.3s ease;
}

.profile-actions .btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(64, 0, 165, 0.3);
}

/* Profile Section */
.profile-section {
  background: var(--white);
  padding: 2.5rem;
  border-radius: 20px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  margin-bottom: 2rem;
}

.profile-section .section-title {
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--dark-color);
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 3px solid var(--primary-color);
  display: inline-block;
}

.profile-bio {
  font-size: 1.05rem;
  line-height: 1.8;
  color: #555;
}

.profile-bio p {
  margin-bottom: 1rem;
}

.profile-bio ul {
  margin-left: 2rem;
  margin-bottom: 1rem;
}

.profile-bio li {
  margin-bottom: 0.5rem;
}

.profile-bio strong {
  color: var(--primary-color);
}

/* Expertise Grid */
.expertise-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.5rem;
  margin-top: 1.5rem;
}

.expertise-item {
  text-align: center;
  padding: 1.5rem;
  background: var(--light-bg);
  border-radius: 15px;
  transition: all 0.3s ease;
}

.expertise-item:hover {
  background: var(--primary-color);
  transform: translateY(-5px);
  box-shadow: 0 10px 25px rgba(64, 0, 165, 0.2);
}

.expertise-item:hover .expertise-icon i,
.expertise-item:hover h5,
.expertise-item:hover p {
  color: var(--white);
}

.expertise-icon {
  width: 70px;
  height: 70px;
  margin: 0 auto 1rem;
  background: var(--white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
}

.expertise-icon i {
  font-size: 1.8rem;
  color: var(--primary-color);
  transition: all 0.3s ease;
}

.expertise-item h5 {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--dark-color);
  margin-bottom: 0.5rem;
  transition: all 0.3s ease;
}

.expertise-item p {
  font-size: 0.95rem;
  color: #666;
  margin: 0;
  transition: all 0.3s ease;
}

/* Related Team Section */
.related-team-section {
  background: var(--white);
  padding: 3rem;
  border-radius: 20px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.related-team-section h3 {
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--dark-color);
}

.team-card-link {
  text-decoration: none;
  color: inherit;
  display: block;
}

.team-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(180deg, transparent 0%, rgba(64, 0, 165, 0.9) 100%);
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 1.5rem;
  opacity: 0;
  transition: all 0.3s ease;
  border-radius: 15px;
}

.team-card:hover .team-overlay {
  opacity: 1;
}

.view-profile {
  color: var(--white);
  font-weight: 600;
  font-size: 1rem;
  transform: translateY(20px);
  transition: all 0.3s ease;
}

.team-card:hover .view-profile {
  transform: translateY(0);
}

/* Responsive Design */
@media (max-width: 991px) {
  .profile-card {
    position: relative !important;
    top: 0 !important;
    margin-bottom: 2rem;
  }

  .profile-name {
    font-size: 1.5rem;
  }

  .profile-section .section-title {
    font-size: 1.5rem;
  }

  .expertise-grid {
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  }
}

@media (max-width: 768px) {
  .profile-section {
    padding: 1.5rem;
  }

  .social-links-list {
    justify-content: center;
  }

  .profile-contact h5,
  .profile-social h5 {
    text-align: center;
  }

  .expertise-grid {
    grid-template-columns: 1fr;
  }

  .related-team-section {
    padding: 2rem 1rem;
  }
}

/* Team Member Link */
.team-member-link {
  color: var(--dark-color);
  text-decoration: none;
  transition: all 0.3s ease;
}

.team-member-link:hover {
  color: var(--primary-color);
  text-decoration: none;
}

.team-info .btn {
  transition: all 0.3s ease;
}

.team-info .btn:hover {
  transform: translateX(-5px);
}

/* ================================================
   Mega Dropdown Menu - القائمة المنسدلة الكبيرة
   ================================================ */

/* Prevent nav items from wrapping */
.navbar-nav .nav-item {
  white-space: nowrap;
}

.navbar-nav .nav-link {
  white-space: nowrap;
  font-size: 0.9rem;
  padding: 0.5rem 0.75rem !important;
}

.mega-dropdown {
  position: static;
}

.mega-dropdown .dropdown-toggle {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  transition: color 0.3s ease;
}

.mega-dropdown .dropdown-toggle:hover {
  color: var(--primary-color) !important;
}

/* All nav-link dropdown-toggle hover effect */
.navbar-nav .nav-item.dropdown > .nav-link.dropdown-toggle:hover {
  color: var(--primary-color) !important;
}

/* Colorful sector icons in header */
.sector-icon {
  font-size: 1.1rem;
  transition: color 0.3s ease;
}

/* All navbar icons should have transition */
.navbar-nav .nav-link i,
.navbar-nav .nav-link .nav-icon {
  transition: color 0.3s ease;
}

/* Nav icon colors for About Us and Contact */
.nav-icon-about {
  color: #8B5CF6;
}

.nav-icon-contact {
  color: #F59E0B;
}

.sector-icon-1 {
  color: #FF6B6B; /* Hospitality - Red/Orange */
}

.sector-icon-2 {
  color: #4ECDC4; /* Retail - Teal */
}

.sector-icon-3 {
  color: #45B7D1; /* Banking - Blue */
}

.sector-icon-4 {
  color: #96CEB4; /* Healthcare - Green */
}

/* All icons change to primary color on hover */
.navbar .navbar-nav .nav-item .nav-link:hover i,
.navbar .navbar-nav .nav-item .nav-link:hover i.sector-icon,
.navbar .navbar-nav .nav-item .nav-link:hover i.sector-icon-1,
.navbar .navbar-nav .nav-item .nav-link:hover i.sector-icon-2,
.navbar .navbar-nav .nav-item .nav-link:hover i.sector-icon-3,
.navbar .navbar-nav .nav-item .nav-link:hover i.sector-icon-4,
.navbar .navbar-nav .nav-item .nav-link:hover i.nav-icon,
.navbar .navbar-nav .nav-item .nav-link:hover i.nav-icon-about,
.navbar .navbar-nav .nav-item .nav-link:hover i.nav-icon-contact,
.navbar .navbar-nav .nav-item.dropdown .nav-link.dropdown-toggle:hover i,
.navbar .navbar-nav .nav-item.mega-dropdown .nav-link.dropdown-toggle:hover i {
  color: #4000A5 !important;
}

.mega-dropdown .dropdown-toggle::after {
  margin-right: 0.2em;
  margin-left: 0.2em;
  font-size: 0.7em;
}

.mega-menu {
  width: 100%;
  max-width: 900px;
  left: 50%;
  transform: translateX(-50%);
  padding: 1.5rem 2rem;
  border: none;
  border-radius: 12px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
  background: var(--white);
  animation: fadeInDown 0.3s ease;
  margin-top: 0;
}

@keyframes fadeInDown {
  from {
    opacity: 0;
    transform: translateX(-50%) translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }
}

.mega-menu .row {
  display: flex;
  flex-wrap: wrap;
}

.mega-menu-column {
  padding: 1rem 1.25rem;
  border-left: 1px solid #eee;
}

.mega-menu-column:first-child {
  border-left: none;
}

[dir="rtl"] .mega-menu-column {
  border-left: none;
  border-right: 1px solid #eee;
}

[dir="rtl"] .mega-menu-column:first-child {
  border-right: none;
}

.mega-menu-title-link {
  text-decoration: none !important;
  display: block;
}

.mega-menu-title-link:hover,
.mega-menu-title-link:focus,
.mega-menu-title-link:active {
  text-decoration: none !important;
}

.mega-menu-title-link:hover .mega-menu-title {
  color: var(--cyan-color);
}

.mega-menu-title {
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--primary-color);
  margin-bottom: 0.75rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--cyan-color);
  display: flex;
  align-items: center;
  gap: 0.5rem;
  white-space: nowrap;
  transition: color 0.3s ease;
}

.mega-menu-title i {
  color: var(--cyan-color);
  font-size: 1rem;
}

.mega-menu-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.mega-menu-list li {
  margin-bottom: 0.25rem;
}

.mega-menu-list li a {
  color: var(--dark-color);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 0.6rem;
  border-radius: 6px;
  transition: all 0.3s ease;
  font-size: 0.85rem;
  white-space: nowrap;
}

.mega-menu-list li a:hover {
  background: linear-gradient(135deg, rgba(64, 0, 165, 0.08), rgba(0, 194, 255, 0.08));
  color: var(--primary-color);
  transform: translateX(3px);
}

/* Third level menu icons change color on hover */
.mega-menu-list li a:hover i {
  color: var(--primary-color) !important;
}

[dir="rtl"] .mega-menu-list li a:hover {
  transform: translateX(-3px);
}

.mega-menu-list li a i {
  color: var(--teal-color);
  font-size: 0.8rem;
  width: 18px;
  text-align: center;
  flex-shrink: 0;
  transition: color 0.3s ease;
}

/* Mobile Mega Menu */
@media (max-width: 991px) {
  /* Navbar container - flex layout with row header */
  .navbar > .container {
    display: flex !important;
    flex-wrap: wrap !important;
    align-items: center !important;
    justify-content: space-between !important;
    position: relative;
    min-height: 56px;
    padding-top: 8px;
    padding-bottom: 8px;
  }

  /* Logo in center - stays in place using order */
  .navbar-brand {
    position: static !important;
    transform: none !important;
    margin: 0 auto !important;
    order: 2 !important;
    z-index: 1 !important;
  }

  /* Toggler button on left - LTR */
  .navbar-toggler {
    position: static !important;
    order: 1 !important;
    z-index: 100 !important;
    margin: 0 !important;
    padding: 8px !important;
    border: 1px solid rgba(0,0,0,0.15) !important;
    border-radius: 6px !important;
    background: transparent !important;
    cursor: pointer !important;
    flex-shrink: 0 !important;
    pointer-events: auto !important;
  }

  .navbar-toggler:focus {
    outline: none !important;
    box-shadow: 0 0 0 2px rgba(64, 0, 165, 0.25) !important;
  }

  .navbar-toggler-icon {
    pointer-events: none;
  }

  /* Spacer to balance the layout */
  .navbar > .container::after {
    content: '';
    order: 3;
    width: 40px;
    flex-shrink: 0;
  }

  /* RTL: Toggle button on right */
  html[dir="rtl"] .navbar-toggler {
    order: 3 !important;
  }

  html[dir="rtl"] .navbar > .container::after {
    order: 1;
  }

  /* Collapse menu - full width below header row */
  #navbarNav {
    order: 4 !important;
    flex-basis: 100% !important;
    width: 100% !important;
    z-index: 9999 !important;
  }

  /* Let Bootstrap handle collapse visibility */
  #navbarNav.collapse:not(.show) {
    display: none !important;
  }

  #navbarNav.collapse.show,
  #navbarNav.collapsing {
    display: block !important;
    background: white;
    border-radius: 0 0 16px 16px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    padding: 1rem;
    max-height: calc(100vh - 70px);
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }

  /* Style the navbar-nav inside collapsed menu */
  .navbar .navbar-collapse .navbar-nav {
    flex-direction: column;
    align-items: stretch;
  }

  /* Hide language switcher in navbar on mobile - show in collapsed menu */
  .navbar .language-switcher {
    margin: 1rem 0;
    justify-content: center;
  }

  .navbar-nav .nav-link {
    font-size: 1rem;
    padding: 0.75rem 1rem !important;
  }

  .mega-menu {
    position: static !important;
    width: 100% !important;
    max-width: 100% !important;
    left: 0 !important;
    right: 0 !important;
    transform: none !important;
    box-shadow: none !important;
    padding: 0.5rem !important;
    border-radius: 0 !important;
    border-top: 1px solid #eee;
    animation: none !important;
    background: transparent !important;
  }

  .mega-menu .container {
    padding: 0;
  }

  .mega-menu .row {
    margin: 0;
    flex-direction: column;
  }

  .mega-menu-column {
    padding: 0.75rem;
    border-left: none;
    border-right: none;
    border-bottom: 1px solid #eee;
    width: 100% !important;
    max-width: 100% !important;
    flex: none !important;
  }

  .mega-menu-column:last-child {
    border-bottom: none;
  }

  .mega-menu-title {
    font-size: 0.95rem;
    margin-bottom: 0.5rem;
    padding-bottom: 0.3rem;
  }

  /* Make title clickable and prominent when no children */
  .mega-menu-title-link {
    display: block;
    padding: 0.5rem;
    border-radius: 6px;
    transition: background 0.3s ease;
  }

  .mega-menu-title-link:hover {
    background: rgba(64, 0, 165, 0.08);
  }

  .mega-menu-list li a {
    padding: 0.4rem 0.5rem;
    font-size: 0.85rem;
    white-space: normal;
  }

  /* Fix dropdown display on mobile */
  .navbar .nav-item.dropdown > .dropdown-menu {
    position: static !important;
    float: none !important;
    width: 100% !important;
    margin-top: 0 !important;
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    display: none !important;
  }

  /* Show dropdown menu when parent has .show class */
  .navbar .nav-item.dropdown.show > .dropdown-menu,
  .navbar .nav-item.dropdown.show > .mega-menu {
    display: block !important;
  }

  /* Style dropdown items on mobile */
  .navbar .dropdown-menu .dropdown-item {
    padding: 0.75rem 1rem;
    border-radius: 8px;
    margin-bottom: 2px;
  }

  .navbar .dropdown-menu .dropdown-item:hover {
    background: rgba(64, 0, 165, 0.08);
  }
}

/* Hover effect for dropdown - DESKTOP ONLY */
@media (min-width: 992px) {
  .navbar .nav-item.dropdown:hover > .dropdown-menu {
    display: block;
  }
}

/* Dropdown arrow animation */
.nav-item.dropdown .dropdown-toggle::after {
  transition: transform 0.3s ease;
}

.nav-item.dropdown:hover .dropdown-toggle::after {
  transform: rotate(180deg);
}

/* Responsive adjustments for many menu items */
@media (max-width: 1400px) {
  .navbar-nav .nav-link {
    font-size: 0.85rem;
    padding: 0.5rem 0.5rem !important;
  }
}

@media (max-width: 1200px) {
  .navbar-nav .nav-link {
    font-size: 0.8rem;
    padding: 0.5rem 0.4rem !important;
  }

  .mega-dropdown .dropdown-toggle::after {
    display: none;
  }
}

/* About Us Dropdown Styles - أنماط قائمة من نحن */
.navbar .nav-item.dropdown:not(.mega-dropdown) > .dropdown-menu {
  border: none !important;
  border-radius: 12px !important;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15) !important;
  padding: 0.5rem !important;
  min-width: 200px !important;
  margin-top: 0 !important;
  background: white !important;
}

.navbar .nav-item.dropdown:not(.mega-dropdown) .dropdown-menu .dropdown-item {
  padding: 0.5rem 0.75rem !important;
  font-size: 0.9rem !important;
  color: var(--dark-color) !important;
  transition: all 0.3s ease !important;
  border-radius: 6px !important;
  display: flex !important;
  align-items: center !important;
  gap: 0.5rem !important;
  background: transparent !important;
  margin-bottom: 0.25rem !important;
}

.navbar .nav-item.dropdown:not(.mega-dropdown) .dropdown-menu .dropdown-item:last-child {
  margin-bottom: 0 !important;
}

.navbar .nav-item.dropdown:not(.mega-dropdown) .dropdown-menu .dropdown-item i {
  color: var(--teal-color) !important;
  transition: all 0.3s ease !important;
  width: 18px !important;
  font-size: 0.85rem !important;
  text-align: center !important;
}

.navbar .nav-item.dropdown:not(.mega-dropdown) .dropdown-menu .dropdown-item:hover,
.navbar .nav-item.dropdown:not(.mega-dropdown) .dropdown-menu .dropdown-item:focus {
  background: linear-gradient(135deg, rgba(64, 0, 165, 0.08), rgba(0, 194, 255, 0.08)) !important;
  color: var(--primary-color) !important;
  transform: translateX(3px) !important;
}

.navbar .nav-item.dropdown:not(.mega-dropdown) .dropdown-menu .dropdown-item:hover i,
.navbar .nav-item.dropdown:not(.mega-dropdown) .dropdown-menu .dropdown-item:focus i {
  color: var(--primary-color) !important;
}

.navbar .nav-item.dropdown:not(.mega-dropdown) .dropdown-menu .dropdown-item.active {
  background: linear-gradient(135deg, rgba(64, 0, 165, 0.12), rgba(0, 194, 255, 0.12)) !important;
  color: var(--primary-color) !important;
}

.navbar .nav-item.dropdown:not(.mega-dropdown) .dropdown-menu .dropdown-item.active i {
  color: var(--primary-color) !important;
}

/* RTL Support for About Us dropdown */
html[dir="rtl"] .navbar .nav-item.dropdown:not(.mega-dropdown) .dropdown-menu .dropdown-item:hover,
html[dir="rtl"] .navbar .nav-item.dropdown:not(.mega-dropdown) .dropdown-menu .dropdown-item:focus {
  transform: translateX(-3px) !important;
}

/* ============================================
   Mobile Viewport Fix - iPhone & All Mobile
   ============================================ */
@media (max-width: 991px) {
  /* Fix images */
  img {
    max-width: 100%;
    height: auto;
  }
}

/* ============================================
   COMPREHENSIVE MOBILE RESPONSIVENESS
   Optimized for iPhone 12/13/14/15 Pro Max, Samsung Galaxy S21/S22/S23 Ultra
   iPhone SE, iPad Mini, and all modern mobile devices
   ============================================ */

/* ===== LARGE TABLETS & SMALL DESKTOPS (991px - 1199px) ===== */
@media (max-width: 1199px) {
  .hero-slide-title {
    font-size: 3rem;
  }

  .hero-slide-subtitle {
    font-size: 1.5rem;
  }

  .mynd-main-title {
    font-size: 2rem;
  }

  .section-title {
    font-size: 2rem;
  }

  .stat-box {
    padding: 1.25rem;
  }
}

/* ===== TABLETS (768px - 991px) ===== */
@media (max-width: 991px) {
  /* Hero Slider */
  .hero-slider-section .carousel-item {
    height: 65vh;
    min-height: 450px;
  }

  .hero-slide-title {
    font-size: 2.5rem;
    line-height: 1.25;
  }

  .hero-slide-subtitle {
    font-size: 1.3rem;
  }

  .hero-slide-description {
    font-size: 1rem;
    max-width: 100%;
  }

  /* Carousel Controls */
  .carousel-control-prev,
  .carousel-control-next {
    width: 45px;
    height: 45px;
  }

  .carousel-control-prev-icon,
  .carousel-control-next-icon {
    width: 20px;
    height: 20px;
  }

  /* MYND/NASHMI Section */
  #mynd-section {
    padding: 60px 0 !important;
  }

  .mynd-main-title {
    font-size: 1.75rem;
  }

  .mynd-subtitle {
    font-size: 1rem;
  }

  .mynd-features-grid {
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
  }

  .mynd-feature-item {
    padding: 1rem;
  }

  .mynd-feature-icon {
    width: 45px;
    height: 45px;
  }

  .mynd-image-container {
    margin-bottom: 2rem;
  }

  /* Sectors Section on Home */
  .sector-image-wrapper img {
    height: 280px !important;
  }

  /* Team Cards */
  .team-card {
    margin-bottom: 1.5rem;
  }

  /* About Section */
  .about-section .row {
    text-align: center;
  }

  .about-section .section-title {
    text-align: center !important;
  }
}

/* ===== MOBILE PHONES LANDSCAPE & SMALL TABLETS (576px - 767px) ===== */
@media (max-width: 767px) {
  /* Global Spacing */
  section {
    padding: 50px 0 !important;
  }

  .container {
    padding-left: 16px !important;
    padding-right: 16px !important;
  }

  /* Hero Slider - Mobile */
  .hero-slider-section .carousel-item {
    height: 60vh;
    min-height: 400px;
  }

  .hero-slide-title {
    font-size: 1.85rem;
    margin-bottom: 0.75rem;
    line-height: 1.3;
  }

  .hero-slide-subtitle {
    font-size: 1.1rem;
    margin-bottom: 0.6rem;
  }

  .hero-slide-description {
    font-size: 0.9rem;
    line-height: 1.6;
    margin-bottom: 1.25rem;
  }

  .btn-hero {
    padding: 0.75rem 1.5rem;
    font-size: 0.95rem;
  }

  /* Carousel Controls - Mobile */
  .carousel-control-prev,
  .carousel-control-next {
    width: 40px;
    height: 40px;
  }

  .carousel-control-prev {
    left: 10px;
  }

  .carousel-control-next {
    right: 10px;
  }

  html[dir="rtl"] .carousel-control-prev {
    right: 10px;
    left: auto;
  }

  html[dir="rtl"] .carousel-control-next {
    left: 10px;
    right: auto;
  }

  .carousel-indicators {
    bottom: 15px;
  }

  .carousel-indicators button {
    width: 10px;
    height: 10px;
    margin: 0 4px;
  }

  .carousel-indicators button.active {
    width: 30px;
  }

  /* MYND/NASHMI Section - Mobile */
  #mynd-section {
    padding: 50px 0 !important;
  }

  .mynd-badge {
    font-size: 0.75rem;
    padding: 0.4rem 0.8rem;
  }

  .mynd-main-title {
    font-size: 1.5rem;
    line-height: 1.4;
  }

  .mynd-subtitle {
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
  }

  .mynd-description {
    font-size: 0.9rem;
    line-height: 1.7;
  }

  .mynd-features-grid {
    grid-template-columns: 1fr;
    gap: 0.75rem;
  }

  .mynd-feature-item {
    padding: 1rem;
    flex-direction: row;
    text-align: left;
  }

  [dir="rtl"] .mynd-feature-item {
    text-align: right;
  }

  .mynd-feature-icon {
    width: 50px;
    height: 50px;
    min-width: 50px;
    font-size: 1.2rem;
  }

  .mynd-feature-text h4 {
    font-size: 1rem;
  }

  .mynd-feature-text p {
    font-size: 0.85rem;
  }

  .mynd-image-container {
    max-width: 85%;
    margin: 0 auto 2rem;
  }

  .mynd-floating-badge {
    font-size: 0.75rem;
    padding: 0.5rem 0.75rem;
  }

  .mynd-cta-btn {
    padding: 0.875rem 1.5rem;
    font-size: 0.95rem;
    width: 100%;
    justify-content: center;
  }

  /* Section Titles - Mobile */
  .section-title {
    font-size: 1.6rem;
    margin-bottom: 0.75rem;
  }

  .section-subtitle {
    font-size: 0.95rem;
  }

  /* Stats Section - Mobile (2 per row) */
  .stats-section {
    padding: 40px 0 !important;
  }

  .stat-box {
    padding: 1rem 0.75rem;
  }

  .stat-number {
    font-size: 1.75rem;
  }

  .stat-label {
    font-size: 0.85rem;
  }

  /* Sectors on Home - Mobile */
  .sector-image-wrapper {
    margin-bottom: 1.5rem;
  }

  .sector-image-wrapper img {
    height: 220px !important;
  }

  .sector-content .section-title {
    text-align: left !important;
    justify-content: flex-start;
  }

  .sector-content p {
    text-align: left;
  }

  .sector-content h4 {
    text-align: left;
  }

  .sector-content .btn-sector {
    display: flex !important;
    width: 100%;
    justify-content: center;
  }

  /* AI Solutions Tags on Home - 2 column grid */
  .ai-solutions-grid,
  .sector-content div[style*="display: flex"][style*="flex-wrap: wrap"] {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 8px !important;
  }

  .ai-solution-tag,
  .sector-content div[style*="display: flex"][style*="flex-wrap: wrap"] a {
    font-size: 0.8rem !important;
    padding: 8px 12px !important;
    justify-content: flex-start;
    text-align: left;
  }

  /* Arabic RTL for Sectors */
  html[lang="ar"] .sector-content .section-title,
  [dir="rtl"] .sector-content .section-title {
    text-align: right !important;
    justify-content: flex-end;
  }

  html[lang="ar"] .sector-content p,
  html[lang="ar"] .sector-content h4,
  [dir="rtl"] .sector-content p,
  [dir="rtl"] .sector-content h4 {
    text-align: right;
  }

  html[lang="ar"] .ai-solution-tag,
  html[lang="ar"] .sector-content div[style*="display: flex"][style*="flex-wrap: wrap"] a,
  [dir="rtl"] .ai-solution-tag,
  [dir="rtl"] .sector-content div[style*="display: flex"][style*="flex-wrap: wrap"] a {
    justify-content: flex-end;
    text-align: right;
  }

  /* Team Cards - Mobile */
  .team-card {
    margin-bottom: 1.25rem;
  }

  .team-card .team-photo,
  .team-img {
    height: 220px;
  }

  .team-name {
    font-size: 1.1rem;
  }

  .team-position {
    font-size: 0.85rem;
  }

  /* Page Header - Mobile */
  .page-header {
    padding: 2.5rem 0 1.5rem;
  }

  .page-header h1 {
    font-size: 1.6rem;
    line-height: 1.4;
  }

  .page-header .breadcrumb-item {
    font-size: 0.85rem;
  }

  /* Cards - Mobile */
  .service-card,
  .blog-card,
  .news-card,
  .project-card {
    margin-bottom: 1.25rem;
  }

  .service-icon {
    width: 65px;
    height: 65px;
    font-size: 1.6rem;
    margin-bottom: 1rem;
  }

  .blog-card .blog-image,
  .news-card .news-image {
    height: 180px;
  }

  .blog-title {
    font-size: 1.1rem;
  }

  /* Contact Form - Mobile */
  .contact-form-section {
    padding: 50px 0;
  }

  .contact-info-box {
    padding: 1.25rem;
    margin-bottom: 1rem;
  }

  .contact-info-box .icon-box {
    width: 50px;
    height: 50px;
    font-size: 1.2rem;
  }

  /* About Page - Mobile */
  .about-section {
    padding: 50px 0;
  }

  .about-content {
    font-size: 0.95rem;
    text-align: left;
  }

  .about-content p,
  .about-content ul,
  .about-content li {
    text-align: left;
  }

  .about-content ul {
    padding-left: 1.5rem;
    padding-right: 0;
  }

  /* Arabic RTL for about-content */
  html[lang="ar"] .about-content,
  [dir="rtl"] .about-content {
    text-align: right;
  }

  html[lang="ar"] .about-content p,
  html[lang="ar"] .about-content ul,
  html[lang="ar"] .about-content li,
  [dir="rtl"] .about-content p,
  [dir="rtl"] .about-content ul,
  [dir="rtl"] .about-content li {
    text-align: right;
  }

  html[lang="ar"] .about-content ul,
  [dir="rtl"] .about-content ul {
    padding-left: 0;
    padding-right: 1.5rem;
  }

  /* Portfolio Filter - Mobile */
  .category-filter {
    gap: 0.5rem;
    flex-wrap: wrap;
    justify-content: center;
  }

  .filter-btn {
    padding: 0.5rem 1rem;
    font-size: 0.85rem;
  }

  /* Process Timeline - Mobile */
  .process-timeline {
    padding-left: 1.75rem;
  }

  [dir="rtl"] .process-timeline {
    padding-left: 0;
    padding-right: 1.75rem;
  }

  .step-number {
    width: 32px;
    height: 32px;
    font-size: 0.9rem;
    left: -1.75rem;
  }

  [dir="rtl"] .step-number {
    left: auto;
    right: -1.75rem;
  }

  .process-step h4 {
    font-size: 1.1rem;
  }

  /* Back to Top Button - Mobile */
  #back-to-top {
    width: 45px;
    height: 45px;
    bottom: 20px;
    right: 20px;
    font-size: 1.25rem;
  }

  [dir="rtl"] #back-to-top {
    right: auto;
    left: 20px;
  }
}

/* ===== MOBILE PHONES PORTRAIT - iPhone 12/13/14 Pro Max, Samsung S21/S22/S23 (390px - 575px) ===== */
@media (max-width: 575px) {
  /* Global */
  .container {
    padding-left: 15px !important;
    padding-right: 15px !important;
  }

  section {
    padding: 40px 0 !important;
  }

  /* Hero Slider - Small Mobile */
  .hero-slider-section .carousel-item {
    height: 55vh;
    min-height: 350px;
  }

  .hero-slide-title {
    font-size: 1.6rem;
    margin-bottom: 0.6rem;
  }

  .hero-slide-subtitle {
    font-size: 1rem;
    margin-bottom: 0.5rem;
  }

  .hero-slide-description {
    font-size: 0.85rem;
    margin-bottom: 1rem;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }

  .btn-hero {
    padding: 0.65rem 1.25rem;
    font-size: 0.9rem;
  }

  /* Carousel Controls - Small Mobile */
  .carousel-control-prev,
  .carousel-control-next {
    width: 36px;
    height: 36px;
  }

  .carousel-control-prev-icon,
  .carousel-control-next-icon {
    width: 16px;
    height: 16px;
  }

  /* MYND Section - Small Mobile */
  .mynd-main-title {
    font-size: 1.35rem;
  }

  .mynd-gradient-text {
    font-size: 1.5rem;
  }

  .mynd-image-container {
    max-width: 90%;
  }

  .mynd-main-image {
    border-radius: 16px;
  }

  .mynd-feature-item {
    padding: 0.875rem;
  }

  .mynd-feature-icon {
    width: 44px;
    height: 44px;
    min-width: 44px;
  }

  /* Section Titles - Small Mobile */
  .section-title {
    font-size: 1.4rem;
  }

  /* Stats - Small Mobile */
  .stat-number {
    font-size: 1.5rem;
  }

  .stat-label {
    font-size: 0.8rem;
  }

  /* Sectors - Small Mobile */
  .sector-image-wrapper img {
    height: 200px !important;
  }

  /* Team - Small Mobile */
  .team-card .team-photo,
  .team-img {
    height: 200px;
  }

  /* Page Header - Small Mobile */
  .page-header h1 {
    font-size: 1.4rem;
  }

  /* Cards - Small Mobile */
  .service-icon {
    width: 55px;
    height: 55px;
    font-size: 1.4rem;
  }

  .blog-card .blog-image,
  .news-card .news-image {
    height: 160px;
  }

  /* Share Buttons - Small Mobile */
  .share-buttons {
    flex-direction: column;
    gap: 0.5rem;
  }

  .share-btn {
    width: 100%;
    justify-content: center;
  }
}

/* ===== VERY SMALL PHONES - iPhone SE, older devices (320px - 389px) ===== */
@media (max-width: 389px) {
  .container {
    padding-left: 12px !important;
    padding-right: 12px !important;
  }

  section {
    padding: 35px 0 !important;
  }

  /* Hero - Very Small */
  .hero-slider-section .carousel-item {
    height: 50vh;
    min-height: 320px;
  }

  .hero-slide-title {
    font-size: 1.4rem;
  }

  .hero-slide-subtitle {
    font-size: 0.9rem;
  }

  .hero-slide-description {
    font-size: 0.8rem;
    -webkit-line-clamp: 2;
  }

  .btn-hero {
    padding: 0.6rem 1rem;
    font-size: 0.85rem;
  }

  /* MYND - Very Small */
  .mynd-main-title {
    font-size: 1.2rem;
  }

  .mynd-subtitle {
    font-size: 0.85rem;
  }

  .mynd-feature-icon {
    width: 40px;
    height: 40px;
    min-width: 40px;
    font-size: 1rem;
  }

  .mynd-feature-text h4 {
    font-size: 0.9rem;
  }

  .mynd-feature-text p {
    font-size: 0.8rem;
  }

  /* Section Titles - Very Small */
  .section-title {
    font-size: 1.25rem;
  }

  .section-subtitle {
    font-size: 0.85rem;
  }

  /* Stats - Very Small */
  .stat-number {
    font-size: 1.35rem;
  }

  .stat-label {
    font-size: 0.75rem;
  }

  /* Page Header - Very Small */
  .page-header h1 {
    font-size: 1.25rem;
  }

  .page-header .breadcrumb-item {
    font-size: 0.8rem;
  }

  /* Cards - Very Small */
  .service-icon {
    width: 50px;
    height: 50px;
    font-size: 1.2rem;
  }

  /* Filter Buttons - Very Small */
  .filter-btn {
    padding: 0.4rem 0.8rem;
    font-size: 0.8rem;
  }
}

/* ============================================
   SECTOR DETAIL PAGE - MOBILE RESPONSIVENESS
   ============================================ */
@media (max-width: 991px) {
  /* Section Navigation */
  .section-nav-container {
    padding: 0.5rem 0.75rem;
    gap: 0.15rem;
  }

  .section-nav-link {
    padding: 0.5rem 0.75rem;
    font-size: 0.8rem;
  }

  .section-nav-link i {
    font-size: 0.8rem;
  }

  /* Sector Hero */
  .sector-hero {
    padding: 2.5rem 0;
  }

  .sector-hero h1 {
    font-size: 2rem;
    flex-direction: column;
    gap: 0.5rem;
  }

  .sector-hero h1 i {
    font-size: 1.75rem;
  }

  .sector-hero .description {
    font-size: 1rem;
  }

  /* Statistics Grid */
  .statistics-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
  }

  .stat-circle {
    width: 80px;
    height: 80px;
  }

  .stat-circle svg {
    width: 80px;
    height: 80px;
  }

  .stat-circle-content .stat-value {
    font-size: 1.15rem;
  }

  .stat-item .stat-label {
    font-size: 0.8rem;
  }

  /* Workflow Steps */
  .workflow-steps {
    flex-direction: column;
    gap: 1.5rem;
  }

  .workflow-step {
    max-width: 100%;
    flex-direction: row;
    text-align: left;
    gap: 1rem;
    padding: 0;
  }

  [dir="rtl"] .workflow-step {
    text-align: right;
  }

  .workflow-step:not(:last-child)::after {
    display: none;
  }

  .workflow-step .step-icon {
    width: 55px;
    height: 55px;
    min-width: 55px;
    font-size: 1.2rem;
    margin-bottom: 0;
  }

  .workflow-step h5 {
    font-size: 0.9rem;
    text-align: left;
  }

  [dir="rtl"] .workflow-step h5 {
    text-align: right;
  }
}

@media (max-width: 767px) {
  /* Section Navigation */
  .section-nav {
    position: sticky;
    top: 0;
  }

  .section-nav-container {
    justify-content: flex-start;
    padding: 0.5rem;
    -webkit-overflow-scrolling: touch;
  }

  .section-nav-link {
    padding: 0.45rem 0.65rem;
    font-size: 0.75rem;
    border-radius: 6px;
  }

  .section-nav-link span {
    display: none;
  }

  .section-nav-link i {
    font-size: 0.9rem;
  }

  /* Sector Hero */
  .sector-hero {
    padding: 2rem 0;
  }

  .sector-hero h1 {
    font-size: 1.6rem;
  }

  .sector-hero h1 i {
    font-size: 1.4rem;
  }

  .sector-hero .description {
    font-size: 0.9rem;
    line-height: 1.6;
  }

  .sector-hero .breadcrumb-nav ol li {
    font-size: 0.8rem;
  }

  /* Content Section */
  .sector-content {
    padding: 1.5rem;
  }

  .content-section {
    padding: 1.5rem 0;
  }

  .section-header h2 {
    font-size: 1.4rem;
  }

  .section-header h2 i {
    font-size: 1.2rem;
  }

  /* Statistics Grid - Mobile */
  .statistics-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
  }

  .stat-item {
    padding: 1rem 0.75rem;
  }

  .stat-circle {
    width: 70px;
    height: 70px;
    margin-bottom: 0.75rem;
  }

  .stat-circle svg {
    width: 70px;
    height: 70px;
  }

  .stat-circle .bg-circle,
  .stat-circle .progress-circle {
    stroke-width: 5;
  }

  .stat-circle-content .stat-icon {
    font-size: 0.9rem;
  }

  .stat-circle-content .stat-value {
    font-size: 1rem;
  }

  .stat-item .stat-label {
    font-size: 0.75rem;
    line-height: 1.3;
  }

  /* Feature Items */
  .feature-item {
    padding: 1rem 1.25rem;
  }

  .feature-item .feature-title h4 {
    font-size: 0.95rem;
  }

  .feature-item p {
    font-size: 0.85rem;
    padding-right: 0;
    padding-left: 0;
  }

  /* Workflow */
  .workflow-container {
    padding: 1.25rem;
  }

  .workflow-step .step-icon {
    width: 50px;
    height: 50px;
    min-width: 50px;
    font-size: 1.1rem;
  }

  .workflow-step .step-number {
    width: 20px;
    height: 20px;
    font-size: 0.65rem;
  }

  /* Benefits */
  .benefit-item {
    padding: 0.875rem 1rem;
    gap: 0.75rem;
  }

  .benefit-item .benefit-icon {
    width: 35px;
    height: 35px;
    min-width: 35px;
    font-size: 0.9rem;
  }

  .benefit-item .benefit-text h5 {
    font-size: 0.9rem;
  }

  .benefit-item .benefit-text p {
    font-size: 0.8rem;
  }
}

@media (max-width: 575px) {
  /* Statistics - Very Small */
  .statistics-grid {
    gap: 0.5rem;
  }

  .stat-item {
    padding: 0.875rem 0.5rem;
  }

  .stat-circle {
    width: 60px;
    height: 60px;
    margin-bottom: 0.5rem;
  }

  .stat-circle svg {
    width: 60px;
    height: 60px;
  }

  .stat-circle-content .stat-icon {
    font-size: 0.8rem;
    margin-bottom: 0.15rem;
  }

  .stat-circle-content .stat-value {
    font-size: 0.9rem;
  }

  .stat-item .stat-label {
    font-size: 0.7rem;
  }
}

/* ============================================
   FOOTER - MOBILE RESPONSIVENESS
   ============================================ */
@media (max-width: 767px) {
  .footer {
    padding: 35px 0 15px;
  }

  .footer h5 {
    font-size: 1rem;
    margin-bottom: 0.75rem !important;
  }

  .footer .list-unstyled li {
    font-size: 0.85rem;
    margin-bottom: 0.35rem !important;
  }

  .footer .list-unstyled li a {
    font-size: 0.85rem;
  }

  .footer p {
    font-size: 0.85rem;
  }

  /* Footer Brand */
  .footer-brand {
    justify-content: center;
    margin-bottom: 0.75rem;
  }

  .footer-brand .footer-logo-img {
    height: 35px;
  }

  .footer-brand .footer-brand-name {
    font-size: 1.1rem;
  }

  /* Social Links */
  .social-links {
    justify-content: center !important;
    display: flex !important;
    gap: 0.5rem;
  }

  .social-links a {
    width: 38px;
    height: 38px;
    font-size: 1rem;
  }

  /* Copyright */
  .footer .border-top {
    padding-top: 1rem !important;
    margin-top: 1.25rem !important;
  }

  .footer .border-top p {
    font-size: 0.8rem;
    text-align: center;
  }
}

@media (max-width: 575px) {
  .footer {
    padding: 30px 0 12px;
  }

  .footer h5 {
    font-size: 0.95rem;
  }

  .footer .list-unstyled li {
    font-size: 0.8rem;
  }

  .social-links a {
    width: 36px;
    height: 36px;
    font-size: 0.9rem;
  }

  .footer-brand .footer-logo-img {
    height: 30px;
  }

  .footer-brand .footer-brand-name {
    font-size: 1rem;
  }
}

/* ============================================
   NAVIGATION - MOBILE MEGA MENU IMPROVEMENTS
   ============================================ */
@media (max-width: 991px) {
  /* Navbar container */
  .navbar {
    padding: 0.5rem 0;
  }

  .navbar > .container {
    padding-left: 15px;
    padding-right: 15px;
    position: relative;
  }

  /* Navbar Brand */
  .navbar-brand {
    max-width: 200px;
  }

  .navbar-brand .brand-logo {
    height: 38px;
  }

  .navbar-brand .brand-name {
    font-size: 0.9rem;
    max-width: 120px;
    line-height: 1.2;
  }

  /* Navbar Toggler */
  .navbar-toggler {
    padding: 0.4rem 0.6rem;
    border: 2px solid var(--primary-color);
    border-radius: 8px;
    z-index: 1001;
  }

  .navbar-toggler:focus {
    box-shadow: 0 0 0 3px rgba(64, 0, 165, 0.25);
  }

  .navbar-toggler-icon {
    width: 1.3em;
    height: 1.3em;
  }

  /* Mobile menu nav items styling */
  .navbar-nav {
    gap: 0.25rem;
    padding-bottom: 0;
  }

  .navbar-nav .nav-item {
    border-bottom: 1px solid #f0f0f0;
    padding: 0.25rem 0;
  }

  .navbar-nav .nav-item:last-child {
    border-bottom: none;
  }

  .navbar-nav .nav-link {
    padding: 0.75rem 1rem !important;
    font-size: 0.95rem !important;
    border-radius: 8px;
  }

  .navbar-nav .nav-link:hover,
  .navbar-nav .nav-link:focus {
    background: #f8f9fa;
  }

  /* Dropdown on Mobile - Click to open */
  .navbar-nav .nav-item.dropdown > .dropdown-menu,
  .navbar-nav .nav-item.mega-dropdown > .dropdown-menu {
    position: static !important;
    float: none !important;
    width: 100% !important;
    margin-top: 0 !important;
    background: #f8f9fa !important;
    border: none !important;
    box-shadow: none !important;
    border-radius: 8px;
    padding: 0.5rem;
    display: none;
  }

  .navbar-nav .nav-item.dropdown.show > .dropdown-menu,
  .navbar-nav .nav-item.mega-dropdown.show > .dropdown-menu {
    display: block !important;
  }

  /* Mega Menu on Mobile */
  .mega-menu {
    position: static !important;
    transform: none !important;
    width: 100% !important;
    max-width: 100% !important;
    border-radius: 8px;
    margin-top: 0.5rem;
    padding: 0.75rem;
    box-shadow: none;
    background: #f8f9fa !important;
  }

  .mega-menu .row {
    flex-direction: column;
  }

  .mega-menu .container {
    padding: 0 !important;
  }

  .mega-menu-column {
    border-left: none !important;
    border-right: none !important;
    border-bottom: 1px solid #e0e0e0;
    padding: 0.75rem 0 !important;
  }

  .mega-menu-column:last-child {
    border-bottom: none;
  }

  .mega-menu-title {
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
  }

  .mega-menu-list li a {
    padding: 0.5rem 0.75rem;
    font-size: 0.85rem;
  }

  /* Regular Dropdown Items on Mobile */
  .navbar .nav-item.dropdown:not(.mega-dropdown) > .dropdown-menu {
    position: static !important;
    width: 100% !important;
    border-radius: 8px !important;
    background: #f8f9fa !important;
    box-shadow: none !important;
    margin-top: 0.5rem !important;
    padding: 0.5rem !important;
  }

  .navbar .nav-item.dropdown:not(.mega-dropdown) .dropdown-menu .dropdown-item {
    padding: 0.6rem 1rem !important;
    border-radius: 6px !important;
    margin-bottom: 0.25rem !important;
  }

  /* Language Switcher */
  .language-switcher {
    margin-top: 0.75rem;
    justify-content: center;
    padding-top: 0.75rem;
    padding-bottom: 0.5rem;
    border-top: 1px solid #e0e0e0;
  }
}

@media (max-width: 767px) {
  .navbar-brand .brand-logo {
    height: 34px;
  }

  .navbar-brand .brand-name {
    font-size: 0.85rem;
    max-width: 100px;
  }

  .navbar-nav .nav-link {
    padding: 0.65rem 0.875rem !important;
    font-size: 0.9rem !important;
  }

  .mega-menu {
    padding: 0.75rem;
  }

  .mega-menu-title {
    font-size: 0.85rem;
  }

  .mega-menu-list li a {
    padding: 0.4rem 0.5rem;
    font-size: 0.8rem;
  }
}

@media (max-width: 389px) {
  .navbar-brand .brand-logo {
    height: 28px;
  }

  .navbar-brand .brand-name {
    font-size: 0.8rem;
    max-width: 85px;
  }
}

/* ============================================
   iOS SPECIFIC FIXES (Safe Areas, Notch)
   ============================================ */
@supports (padding-top: env(safe-area-inset-top)) {
  .navbar {
    padding-top: calc(0.5rem + env(safe-area-inset-top));
  }

  .footer {
    padding-bottom: calc(20px + env(safe-area-inset-bottom));
  }

  #back-to-top {
    bottom: calc(20px + env(safe-area-inset-bottom));
  }

  [dir="rtl"] #back-to-top {
    left: calc(20px + env(safe-area-inset-left));
  }

  [dir="ltr"] #back-to-top {
    right: calc(20px + env(safe-area-inset-right));
  }
}

/* ============================================
   TOUCH DEVICE OPTIMIZATIONS
   ============================================ */
@media (hover: none) and (pointer: coarse) {
  /* Remove hover effects that don't work on touch */
  .service-card:hover,
  .blog-card:hover,
  .news-card:hover,
  .team-card:hover,
  .project-card:hover {
    transform: none;
  }

  /* Make touch targets larger */
  .btn,
  .nav-link,
  .filter-btn,
  .social-links a {
    min-height: 44px;
    min-width: 44px;
  }

  /* Improve tap targets in footer */
  .footer .list-unstyled li a {
    display: block;
    padding: 0.5rem 0;
  }

  /* Better scrolling */
  .section-nav-container,
  .mega-menu {
    -webkit-overflow-scrolling: touch;
  }
}

/* ============================================
   LANDSCAPE MODE FIXES
   ============================================ */
@media (max-height: 500px) and (orientation: landscape) {
  .hero-slider-section .carousel-item {
    height: 80vh;
    min-height: 280px;
  }

  .hero-slide-title {
    font-size: 1.5rem;
  }

  .hero-slide-subtitle {
    font-size: 0.95rem;
  }

  .hero-slide-description {
    display: none;
  }

  #mynd-section {
    padding: 40px 0 !important;
  }

  .mynd-main-title {
    font-size: 1.3rem;
  }

  .mynd-features-grid {
    grid-template-columns: repeat(4, 1fr);
  }

  .mynd-feature-item {
    flex-direction: column;
    text-align: center;
  }
}

/* ============================================
   DARK MODE SUPPORT (if system prefers)
   ============================================ */
@media (prefers-color-scheme: dark) {
  /* This is a placeholder - implement if needed */
}

/* ============================================
   REDUCED MOTION (Accessibility)
   ============================================ */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .carousel {
    transition: none;
  }

  .fade-in-up {
    opacity: 1;
    transform: none;
  }
}
