html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Cairo', sans-serif !important;
  background: #fff;
  overflow-x: hidden;
}

html[dir="ltr"] body,
html[dir="rtl"] body {
  font-family: 'Cairo', sans-serif !important;
}

.glass {
  background: rgba(255, 255, 255, .82);
  backdrop-filter: blur(22px);
  -webkit-backdrop-filter: blur(22px);
}

.gradient-text {
  background: linear-gradient(90deg, #60317a, #00a99d);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-grid {
  background-image:
    linear-gradient(rgba(96, 49, 122, .06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(96, 49, 122, .06) 1px, transparent 1px);
  background-size: 44px 44px;
}

.floating {
  animation: floating 5s ease-in-out infinite;
}

@keyframes floating {

  0%,
  100% {
    transform: translateY(0px);
  }

  50% {
    transform: translateY(-20px);
  }
}

.spin-slow {
  animation: spin 18s linear infinite;
}

@keyframes marquee {
  0% {
    transform: translateX(0);
  }

  100% {
    transform: translateX(-50%);
  }
}

html[dir="rtl"] .marquee-track {
  animation: marqueeRtl 25s linear infinite;
}

html[dir="ltr"] .marquee-track {
  animation: marquee 25s linear infinite;
}

@keyframes marqueeRtl {
  0% {
    transform: translateX(0);
  }

  100% {
    transform: translateX(50%);
  }
}

.page {
  display: none;
}

.page.active {
  display: block;
}

.portfolio-card:hover img {
  transform: scale(1.1);
}

.portfolio-card img {
  transition: 900ms ease;
}

.mega-menu {
  opacity: 0;
  visibility: hidden;
  transform: translateY(15px);
  transition: .3s ease;
}


.nav-link.active {
  color: #60317a;
  font-weight: 900;
}


/* Header & mega menu fixes */
header.bg-white {
  overflow: visible !important;
  /* background-color: #ffffff !important; */
  color: #211129 !important;
}

header.bg-white * {
  color: #211129;
}

header.bg-white .nav-link.active,
header.bg-white .text-main,
header.bg-white i.text-main {
  color: #60317a !important;
}

header .h-20 {
  height: 88px !important;
  min-height: 88px !important;
  overflow: visible !important;
}

main {
  padding-top: 88px !important;
}

.mega-parent {
  position: static !important;
}

.mega-menu {
  position: fixed !important;
  top: 88px !important;
  left: 50% !important;
  right: auto !important;
  width: min(1100px, calc(100vw - 40px)) !important;
  max-height: calc(100vh - 110px);
  overflow-y: auto;
  z-index: 9999;
  transform: translate(-50%, 15px);
}



html[dir="rtl"] .mega-menu,
html[dir="ltr"] .mega-menu {
  left: 50% !important;
  right: auto !important;
}

html[dir="rtl"] .mega-menu .grid {
  text-align: right;
}

html[dir="ltr"] .mega-menu .grid {
  text-align: left;
}

@media (max-width: 1279px) {
  main {
    padding-top: 88px !important;
  }
}

.partner-logo {
  transition: .35s ease;
}

.partner-logo:hover {
  transform: translateY(-6px);
}

.portfolioSwiper {
  padding-bottom: 3.5rem !important;
  --swiper-pagination-color: #60317a;
  --swiper-pagination-bullet-inactive-color: #60317a;
  --swiper-pagination-bullet-inactive-opacity: 0.25;
  --swiper-pagination-bullet-size: 12px;
  --swiper-pagination-bullet-horizontal-gap: 6px;
}

.portfolioSwiper .swiper-pagination {
  bottom: 0 !important;
}

/* Fixed Contact Buttons + Chatbot + Scroll Top */
.fixed-contact-stack {
  position: fixed;
  right: 25px;
  bottom: 25px;
  z-index: 99999;
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.fixed-left-stack {
  position: fixed;
  left: 25px;
  bottom: 25px;
  z-index: 99999;
  display: flex;
  flex-direction: column;
  gap: 15px;
  align-items: flex-start;
}

/* RTL Layout adjustment to prevent overlaps with right-aligned content */
html[dir="rtl"] .fixed-contact-stack {
  left: 25px;
  right: auto;
}

html[dir="rtl"] .fixed-left-stack {
  right: 25px;
  left: auto;
  align-items: flex-end;
}

html[dir="rtl"] .fixed-action-btn::after {
  left: calc(100% + 15px);
  right: auto;
  transform: translateY(-50%) translateX(-10px);
}

html[dir="rtl"] .fixed-action-btn:hover::after {
  transform: translateY(-50%) translateX(0);
}

.fixed-action-btn {
  width: 62px;
  height: 62px;
  border-radius: 999px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 24px;
  transition: all .4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  position: relative;
  cursor: pointer;
}

/* Sonar Effect Animation */
.fixed-action-btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border-radius: 999px;
  background: inherit;
  opacity: 0.6;
  z-index: -1;
  animation: sonar-effect 2s infinite;
}

@keyframes sonar-effect {
  0% {
    transform: scale(1);
    opacity: 0.6;
  }

  100% {
    transform: scale(1.6);
    opacity: 0;
  }
}

.fixed-action-btn:hover {
  transform: translateY(-8px) scale(1.1);
}

.fixed-action-btn::after {
  content: attr(data-tooltip);
  position: absolute;
  right: calc(100% + 15px);
  top: 50%;
  transform: translateY(-50%) translateX(10px);
  background: rgba(33, 17, 41, 0.95);
  backdrop-filter: blur(8px);
  color: #fff;
  white-space: nowrap;
  padding: 10px 18px;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 700;
  opacity: 0;
  pointer-events: none;
  transition: all .3s ease;
}

.fixed-action-btn:hover::after {
  opacity: 1;
  transform: translateY(-50%) translateX(0);
}

.call-btn {
  background: #0A84FF !important;
  color: #fff;
  animation: pulse-gentle 3s infinite;
}

.whatsapp-btn {
  background: #25D366 !important;
  color: #fff;
  animation: pulse-gentle 3s infinite 1.5s;
}

@keyframes pulse-gentle {
  0% {
    transform: scale(1);
  }

  50% {
    transform: scale(1.05);
  }

  100% {
    transform: scale(1);
  }
}

.scroll-top-btn {
  background: linear-gradient(135deg, #211129, #60317a);
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px);
  width: 55px;
  height: 55px;
  font-size: 18px;
}

.scroll-top-btn.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}


.chatbot-panel {
  width: min(380px, calc(100vw - 44px));
  background: #fff;
  border: 1px solid rgba(96, 49, 122, .12);
  border-radius: 28px;
  overflow: hidden;
  transform: translateY(18px) scale(.96);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: .35s ease;
}

.chatbot-panel.open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0) scale(1);
}

.chatbot-header {
  background: linear-gradient(135deg, #60317a, #00a99d);
  color: #fff;
  padding: 18px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.chatbot-body {
  height: 310px;
  overflow-y: auto;
  padding: 18px;
  background: #fbf8fd;
}

.chat-msg {
  max-width: 85%;
  padding: 12px 14px;
  border-radius: 18px;
  margin-bottom: 10px;
  line-height: 1.7;
  font-size: 14px;
  animation: chatPop .25s ease both;
}

@keyframes chatPop {
  from {
    opacity: 0;
    transform: translateY(8px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.chat-msg.bot {
  background: #fff;
  color: #334155;
  border: 1px solid rgba(96, 49, 122, .10);
  border-top-right-radius: 4px;
  margin-left: auto;
}

.chat-msg.user {
  background: #60317a;
  color: #fff;
  border-top-left-radius: 4px;
  margin-right: auto;
}

html[dir="ltr"] .chat-msg.bot {
  margin-right: auto;
  margin-left: 0;
  border-top-left-radius: 4px;
  border-top-right-radius: 18px;
}

html[dir="ltr"] .chat-msg.user {
  margin-left: auto;
  margin-right: 0;
  border-top-right-radius: 4px;
  border-top-left-radius: 18px;
}

.chatbot-quick {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 14px 16px;
  border-top: 1px solid rgba(96, 49, 122, .10);
  background: #fff;
}

.chatbot-quick button {
  background: #f8f1fb;
  color: #60317a;
  border-radius: 999px;
  padding: 8px 12px;
  font-size: 13px;
  font-weight: 800;
  transition: .25s ease;
}

.chatbot-quick button:hover {
  background: #60317a;
  color: #fff;
}

.chatbot-input-wrap {
  display: flex;
  gap: 8px;
  padding: 14px;
  background: #fff;
  border-top: 1px solid rgba(96, 49, 122, .10);
}

.chatbot-input-wrap input {
  flex: 1;
  border: 1px solid rgba(96, 49, 122, .18);
  border-radius: 999px;
  padding: 12px 14px;
  outline: none;
  font-size: 14px;
}

.chatbot-input-wrap input:focus {
  border-color: #60317a;
}

.chatbot-input-wrap button {
  width: 46px;
  height: 46px;
  border-radius: 999px;
  background: #60317a;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: .25s ease;
}

.chatbot-input-wrap button:hover {
  transform: rotate(-12deg) scale(1.05);
  background: #00a99d;
}

@media (max-width: 640px) {
  .fixed-contact-stack {
    right: 14px;
    bottom: 18px;
  }

  .fixed-left-stack {
    left: 14px;
    bottom: 18px;
  }

  html[dir="rtl"] .fixed-contact-stack {
    left: 14px;
    right: auto;
  }

  html[dir="rtl"] .fixed-left-stack {
    right: 14px;
    left: auto;
  }

  .fixed-action-btn {
    width: 52px;
    height: 52px;
    font-size: 20px;
  }

  .fixed-action-btn::after {
    display: none;
  }

  .chatbot-panel {
    width: calc(100vw - 28px);
  }

  .chatbot-body {
    height: 280px;
  }
}

/* Mobile accordion - Our Work dropdown */
#mobileWorkDropdown {
  transition: max-height 0.4s ease;
}

#mobileWorkChevron {
  transition: transform 0.35s ease;
}

/* Mobile menu scrollable */
#mobileMenu {
  max-height: calc(100vh - 88px);
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
}

.project-input {
  width: 100%;
  border: 1px solid #e2e8f0;
  background: #f8fafc;
  border-radius: 1.25rem;
  padding: 1rem 1.25rem;
  outline: none;
  font-weight: 700;
  transition: 0.25s ease;
}

.project-input:focus {
  border-color: #60317d;
  background: #fff;
}

.project-input.input-error {
  border-color: #ef4444;
  background: #fff5f5;
}

.form-error {
  display: block;
  color: #ef4444;
  font-size: 13px;
  font-weight: 700;
  margin-top: 8px;
  min-height: 18px;
}

.project-swal {
  border-radius: 18px !important;
  font-family: 'Cairo', sans-serif !important;
  padding: 14px 18px !important;
}

.swal2-title {
  font-size: 15px !important;
  font-weight: 800 !important;
}



/* fix image rendering */
.partner-logo img {
  image-rendering: auto;
  backface-visibility: hidden;
}

/* ==================== RELATED WORKS GALLERY ==================== */
.related-works-gallery {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

@media (min-width: 768px) {
  .related-works-gallery {
    gap: 20px;
  }

  .related-works-gallery[data-count="1"] {
    grid-template-columns: 1fr;
  }

  .related-works-gallery[data-count="2"] {
    grid-template-columns: repeat(2, 1fr);
  }

  .related-works-gallery[data-count="3"] {
    grid-template-columns: repeat(3, 1fr);
  }

  .related-works-gallery:not([data-count="1"]):not([data-count="2"]):not([data-count="3"]) {
    grid-template-columns: repeat(2, 1fr);
  }

  .related-works-gallery:not([data-count="1"]):not([data-count="2"]):not([data-count="3"]) .rw-item:last-child:nth-child(odd) {
    grid-column: span 2;
  }
}

.rw-item {
  border-radius: 20px;
  overflow: hidden;
  position: relative;
  background: #1a0d24;
}

.rw-img-wrap {
  position: relative;
  width: 100%;
  height: 260px;
  overflow: hidden;
}

@media (min-width: 1024px) {
  .rw-img-wrap {
    height: 400px;
  }
}

.rw-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.rw-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(96, 49, 122, 0.7) 0%, rgba(0, 169, 157, 0.5) 100%);
  opacity: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.rw-item:hover .rw-overlay {
  opacity: 1;
}

.rw-zoom {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.95);
  color: #60317a;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  transform: scale(0.6) rotate(-15deg);
}

.rw-item:hover .rw-zoom {
  transform: scale(1) rotate(0deg);
}





/* =========================================================
   PURPLE ART AGENCY - FINAL DARK PREMIUM THEME
   تصميم ألوان فقط بدون تغيير أي بيانات أو API أو IDs
   ========================================================= */
:root {
  --pa-bg: #120719;
  --pa-bg-2: #1b0c24;
  --pa-card: #24102f;
  --pa-card-2: #2a1538;
  --pa-purple: #60317a;
  --pa-purple-2: #8b4faf;
  --pa-teal: #00c8bd;
  --pa-teal-dark: #008f89;
  --pa-terracotta: #c46046;
  --pa-text: #ffffff;
  --pa-muted: rgba(255, 255, 255, .72);
  --pa-border: rgba(255, 255, 255, .12);
  --pa-shadow: 0 30px 90px rgba(0, 0, 0, .42);
}

html,
body {
  background-color: #120719 !important;
  background-image:
    linear-gradient(180deg, rgba(12, 3, 18, .22), rgba(12, 3, 18, .36)),
    url('./images/site-bg.jpg') !important;
  background-size: cover !important;
  background-position: center top !important;
  background-repeat: no-repeat !important;
  background-attachment: fixed !important;
  color: var(--pa-text) !important;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: -1;
  background:
    radial-gradient(circle at 8% 34%, rgba(255, 255, 255, .09) 0 1px, transparent 1.5px),
    radial-gradient(circle at 88% 72%, rgba(255, 255, 255, .08) 0 1px, transparent 1.5px),
    linear-gradient(180deg, rgba(18, 7, 25, .10), rgba(18, 7, 25, .30));
  background-size: 22px 22px, 22px 22px, auto;
  opacity: .7;
}

/* Global backgrounds: remove white sections while keeping structure/data */
main,
.page,
.page.active,
.page section,
section,
.bg-white,
.bg-soft,
[class*="bg-white"],
[class*="bg-soft"],
.chatbot-body,
.chatbot-quick,
.chatbot-input-wrap {
  background-color: transparent !important;
}

section.py-28,
section.pb-24,
.stats-section,
#services section,
#portfolio section,
#case-studies section,
#contact section,
#about section,
#dynamic-service section {
  background:
    linear-gradient(135deg, rgba(18, 7, 25, .86), rgba(36, 16, 47, .72)),
    radial-gradient(circle at top right, rgba(0, 200, 189, .12), transparent 34%) !important;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

#serviceWorkCategoriesSection {
  background: #00aca0 !important;
}

#serviceWorkCategoriesSection .service-work-category-card {
  background: #ffffff !important;
}

/* Header */
header.glass,
.glass {
  background: rgba(18, 7, 25, .82) !important;
  border-bottom: 1px solid var(--pa-border) !important;
  backdrop-filter: blur(24px) saturate(160%) !important;
  -webkit-backdrop-filter: blur(24px) saturate(160%) !important;
}

header .h-20 {
  height: 86px !important;
  min-height: 86px !important;
}

main {
  padding-top: 86px !important;
}

header button,
header nav button,
header span,
header i {
  color: #fff !important;
}

.nav-link.active,
header button:hover,
header .hover\:text-main:hover {
  color: var(--pa-teal) !important;
}

.nav-link.active {
  position: relative;
}

.nav-link.active::after {
  content: "";
  position: absolute;
  right: 0;
  left: 0;
  bottom: -10px;
  height: 2px;
  border-radius: 20px;
  background: linear-gradient(90deg, var(--pa-purple), var(--pa-teal));
}

/* Hero like reference */
.hero-grid {
  min-height: calc(100vh - 86px) !important;
  padding-top: 0 !important;
  background-image:
    linear-gradient(90deg, rgba(18, 7, 25, .22), rgba(18, 7, 25, .08)),
    url('./images/site-bg.jpg') !important;
  background-size: cover !important;
  background-position: center top !important;
  background-repeat: no-repeat !important;
}

.hero-grid .max-w-7xl {
  padding-top: 38px !important;
  padding-bottom: 42px !important;
}

.hero-grid::before {
  display: none !important;
}

.hero-grid>* {
  position: relative;
  z-index: 1;
}


#apiHeroSubtitle,
.hero-grid .inline-flex {
  color: #fff !important;
}

#apiHeroImage {
  min-height: 470px !important;
  object-fit: cover !important;
}

/* Text colors */
.text-slate-900,
.text-slate-800,
.text-slate-700,
.text-slate-600,
.text-slate-500,
.text-gray-900,
.text-gray-800,
.text-gray-700,
.text-gray-600,
p,
li,
span,
h1,
h2,
h3,
h4,
h5,
h6,
label,
small,
div {
  color: inherit;
}

.text-slate-600,
.text-slate-500,
.text-gray-600,
.text-gray-500,
[class*="text-slate-"],
[class*="text-gray-"] {}

h1,
h2,
h3,
h4,
h5,
h6,
.font-black {
  color: #fff !important;
}

.text-main,
[class*="text-main"] {
  color: var(--pa-teal) !important;
}

.text-white,
[class*="text-white"] {
  color: #fff !important;
}

.gradient-text {
  background: linear-gradient(90deg, #ffffff 0%, #ffffff 42%, var(--pa-teal) 100%) !important;
  -webkit-background-clip: text !important;
  background-clip: text !important;
  -webkit-text-fill-color: transparent !important;
}

/* Cards */
.rounded-\[2rem\],
.rounded-\[2\.5rem\],
.rounded-3xl,
.portfolio-card,
.partner-logo,
#apiServicesGrid>div,
#apiWorkMethodSteps>div,
#apiWhyUsPoints>div,
#services .grid>div,
#portfolio .grid>div,
#case-studies .grid>div,
#dynamic-service .grid>div {
  border-color: var(--pa-border) !important;
}

#apiServicesGrid>div,
#apiWorkMethodSteps>div,
#services .grid>div,
#portfolio .portfolio-card,
#case-studies .grid>div,
#dynamic-service .grid>div.bg-soft,
.partner-logo,
.chatbot-panel,
.project-input,
.mega-menu,
#mobileMenu,
#apiMobileMenuDropdown {
  background: linear-gradient(145deg, rgba(96, 49, 122, .45), rgba(18, 7, 25, .45)) !important;
  border: 1px solid var(--pa-border) !important;
  backdrop-filter: blur(18px) !important;
  -webkit-backdrop-filter: blur(18px) !important;
}

#apiServicesGrid>div:hover,
#services .grid>div:hover,
#dynamic-service .grid>div:hover,
.portfolio-card:hover {
  transform: translateY(-8px);
}

/* Buttons */
.bg-main,
[class~="bg-main"] {
  background: linear-gradient(135deg, var(--pa-teal), var(--pa-purple)) !important;
  color: #fff !important;
}

.border-main,
.border-main\/20,
.border-2.border-main,
[class*="border-main"] {
  border-color: rgba(0, 200, 189, .35) !important;
}



button,
a {
  transition: .28s ease !important;
}

button:hover,
a:hover {
  filter: brightness(1.08);
}

/* Mega menu: professional full width hover */
.mega-parent {
  position: static !important;
}

.mega-menu {
  position: fixed !important;
  top: 86px !important;
  left: 50% !important;
  right: auto !important;
  width: min(1180px, calc(100vw - 42px)) !important;
  max-height: calc(100vh - 110px) !important;
  overflow-y: auto !important;
  padding: 30px !important;
  border-radius: 28px !important;
  background:
    radial-gradient(circle at top right, rgba(0, 200, 189, .12), transparent 28%),
    linear-gradient(145deg, rgba(36, 16, 47, .97), rgba(18, 7, 25, .94)) !important;
  opacity: 0;
  visibility: hidden;
  transform: translate(-50%, 18px) scale(.98) !important;
  transition: .28s ease !important;
  z-index: 99999 !important;
}

.mega-parent:hover .mega-menu {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, 0) scale(1) !important;
}

#apiMegaMenuWrapper h4 {
  color: var(--pa-teal) !important;
}

#apiMegaMenuWrapper button {
  color: rgba(255, 255, 255, .78) !important;
  border-radius: 14px !important;
  padding: 10px 12px !important;
}

#apiMegaMenuWrapper button:hover {
  color: #fff !important;
  background: rgba(255, 255, 255, .07) !important;
}

/* Partners */
.partner-logo {
  background: rgba(255, 255, 255, .05) !important;
}

.partner-logo img,
#apiPartnersWrapper img {
  filter: none !important;
  opacity: 1 !important;
  mix-blend-mode: normal !important;
}

/* Forms / chatbot */
input,
textarea,
select,
.project-input,
.chatbot-input-wrap input {
  background: rgba(255, 255, 255, .06) !important;
  color: #fff !important;
  border-color: var(--pa-border) !important;
}

input::placeholder,
textarea::placeholder {
  color: rgba(255, 255, 255, .48) !important;
}

input:focus,
textarea:focus,
select:focus,
.project-input:focus {
  border-color: var(--pa-teal) !important;
}

.chat-msg.bot {
  background: rgba(255, 255, 255, .08) !important;
  color: #fff !important;
  border-color: var(--pa-border) !important;
}

.chat-msg.user {
  background: linear-gradient(135deg, var(--pa-purple), var(--pa-teal-dark)) !important;
  color: #fff !important;
}

.chatbot-header {
  background: linear-gradient(135deg, var(--pa-purple), var(--pa-teal-dark)) !important;
}

.chatbot-quick button {
  background: rgba(255, 255, 255, .07) !important;
  color: #fff !important;
}

.chatbot-quick button:hover {
  background: var(--pa-teal-dark) !important;
}

/* Marquee */

/* Footer and separators */
footer {
  background: linear-gradient(145deg, #0b0310, #1b0c24) !important;
  color: #fff !important;
  border-top: 1px solid var(--pa-border) !important;
}

hr,
.border-slate-100,
.border-slate-200,
[class*="border-slate-"] {
  border-color: var(--pa-border) !important;
}

/* Generated dynamic pages overrides */
#dynamic-service .min-h-screen,
#services .min-h-screen {
  background:
    radial-gradient(circle at top right, rgba(96, 49, 122, .32), transparent 34%),
    radial-gradient(circle at bottom left, rgba(0, 200, 189, .18), transparent 30%),
    #120719 !important;
}

#dynamic-service img,
#services img,
#portfolio img {
  border-color: rgba(255, 255, 255, .12) !important;
}

#dynamic-service .bg-black,
#dynamic-service [class*="from-black"] {
  color: #fff !important;
}

/* Mobile */
#mobileMenu {
  background: rgba(18, 7, 25, .98) !important;
  border-top: 1px solid var(--pa-border) !important;
}

#mobileMenu button {
  color: #fff !important;
  text-align: right;
}

#apiMobileMenuDropdown {
  background: rgba(255, 255, 255, .055) !important;
}

@media (max-width:1024px) {
  .hero-grid {
    min-height: calc(100vh - 86px) !important;
    padding-top: 0 !important;
    background-image:
      linear-gradient(90deg, rgba(18, 7, 25, .22), rgba(18, 7, 25, .08)),
      url('./images/site-bg.jpg') !important;
    background-size: cover !important;
    background-position: center top !important;
    background-repeat: no-repeat !important;
  }

  .hero-grid .max-w-7xl {
    padding-top: 28px !important;
  }


}


/* ==================== NO ANIMATION MODE ==================== */
*:not([class*="swiper"]):not([class*="Swiper"]):not(.swiper-slide img):not(.marquee-track),
*:not([class*="swiper"]):not([class*="Swiper"]):not(.swiper-slide img):not(.marquee-track)::before,
*:not([class*="swiper"]):not([class*="Swiper"]):not(.swiper-slide img):not(.marquee-track)::after {
  animation: none !important;
  transition: none !important;
  scroll-behavior: auto !important;
}

[data-aos],
.aos-init,
.aos-animate {
  opacity: 1 !important;
  transform: none !important;
  transition: none !important;
}

.marquee-track {
  display: flex;
  gap: 60px;
  width: max-content;
  animation: marqueeRtl 25s linear infinite !important;
  will-change: transform;
}

@keyframes marqueeRtl {
  from {
    transform: translateX(0);
  }

  to {
    transform: translateX(50%);
  }
}

.portfolio-card:hover img,
.partner-logo:hover,
.fixed-action-btn:hover,
#apiServicesGrid>div:hover,
#services .grid>div:hover,
#dynamic-service .grid>div:hover,
.portfolio-card:hover {
  transform: none !important;
}

.fixed-action-btn::before {
  display: none !important;
}



/* ==================== REQUESTED FINAL OVERRIDES: AUTOPLAY + FAST MARQUEE + FAST IMAGES ==================== */
.marquee-track {
  animation-duration: 25s !important;
  animation-timing-function: linear !important;
  animation-iteration-count: infinite !important;
  will-change: transform;
}

html[dir="rtl"] .marquee-track {
  animation-name: marqueeRtl !important;
}

html[dir="ltr"] .marquee-track {
  animation-name: marquee !important;
}

.swiper-wrapper {
  transition-property: transform !important;
  transition-duration: 850ms !important;
  transition-timing-function: ease !important;
  will-change: transform;
}

.partnersSwiper .swiper-wrapper {
  transition-timing-function: linear !important;
}

img {
  decoding: async;
}

#apiHeroImage,
.portfolio-card img,
#dynamic-service img,
#services img,
#portfolio img,
#case-studies img {
  background: #120719;
}

/* =========================================================
   PERFORMANCE FIX + HERO FIRST SECTION BACKGROUND ONLY
   المطلوب: خلفية أول سيكشن تحت النافبار فقط + تسريع الموقع
   ========================================================= */
html,
body {
  background: #120719 !important;
  background-image: none !important;
  background-attachment: scroll !important;
  overflow-x: hidden;
}

body::before {
  display: none !important;
  content: none !important;
}

/* أول سيكشن تحت النافبار */
#home>.hero-grid,
section.hero-grid {
  background-color: #120719 !important;
  background-image:
    linear-gradient(90deg, rgba(18, 7, 25, .12), rgba(18, 7, 25, .04)),
    url('./images/hero-section-bg.jpg') !important;
  background-size: cover !important;
  background-position: center center !important;
  background-repeat: no-repeat !important;
  background-attachment: scroll !important;
  will-change: auto !important;
}

/* باقي السكاشن بدون صورة fixed ثقيلة */
main,
.page,
.page.active {
  background: #120719 !important;
}

.page section:not(.hero-grid),
section.py-28:not(.hero-grid),
section.pb-24,
.stats-section,
#services section,
#portfolio section,
#case-studies section,
#contact section,
#about section,
#dynamic-service section {
  background: linear-gradient(135deg, rgba(18, 7, 25, .96), rgba(36, 16, 47, .92)) !important;
  /* backdrop-filter: none !important; */
  -webkit-backdrop-filter: none !important;
}

/* تقليل الأحمال البصرية الثقيلة التي كانت تبطئ السكروول */
header.glass,
.glass,
#apiServicesGrid>div,
#apiWorkMethodSteps>div,
#services .grid>div,
#portfolio .portfolio-card,
#case-studies .grid>div,
#dynamic-service .grid>div,
.partner-logo,
.chatbot-panel,
.project-input,
.mega-menu,
#mobileMenu,
#apiMobileMenuDropdown {
  /* backdrop-filter: none !important; */
  -webkit-backdrop-filter: none !important;
}

/* حركة أخف وأسرع بدون تهنيج */
html[dir="rtl"] .marquee-track,
html[dir="ltr"] .marquee-track {
  animation-duration: 9s !important;
  will-change: transform;
}

.swiper-wrapper {
  will-change: transform;
}


/* ===== FINAL REQUEST FIX: hero background covers the whole first viewport including navbar + speed ===== */
:root {
  --pa-hero-solid: #120719;
  --pa-hero-image: url('./images/hero-section-bg.jpg');
}

html,
body {
  background: #120719 !important;
  background-image: none !important;
  background-attachment: scroll !important;
}

body::before {
  display: none !important;
}

/* The navbar sits over the first section, so the same hero background appears behind it */
header.glass,
header.glass.scrolled,
.glass {
  background:
    linear-gradient(135deg, rgba(0, 169, 157, .95), rgba(0, 190, 176, .92)) !important;
  border-bottom: 1px solid rgba(255, 255, 255, .18) !important;
  backdrop-filter: blur(14px) !important;
  -webkit-backdrop-filter: blur(14px) !important;
}

main {
  padding-top: 0 !important;
}

/* First screen only: full hero face + navbar */
#home>.hero-grid,
.hero-grid {
  min-height: 100vh !important;
  padding-top: 86px !important;
  background-color: var(--pa-hero-solid) !important;
  background-image:
    linear-gradient(90deg, rgba(18, 7, 25, .08), rgba(18, 7, 25, .02)),
    var(--pa-hero-image) !important;
  background-size: cover !important;
  background-position: center center !important;
  background-repeat: no-repeat !important;
  background-attachment: scroll !important;
  transform: translateZ(0);
}

/* Remove heavy decorative blur on hero for faster paint */
#home>.hero-grid>.absolute.blur-3xl,
.hero-grid>.absolute.blur-3xl {
  display: none !important;
}

.hero-grid .max-w-7xl {
  margin-top: 0 !important;
  padding-top: 30px !important;
  padding-bottom: 48px !important;
}

/* Keep other sections professional without forcing the heavy full-page image */
section.py-28,
section.pb-24,
.stats-section,
#services section,
#portfolio section,
#case-studies section,
#contact section,
#about section,
#dynamic-service section {
  background: linear-gradient(135deg, rgba(18, 7, 25, .94), rgba(36, 16, 47, .86)) !important;
  /* backdrop-filter: none !important; */
  -webkit-backdrop-filter: none !important;
}

/* Marquee: clearly active and faster */
html[dir="rtl"] .marquee-track {
  animation: marqueeRtl 25s linear infinite !important;
}

html[dir="ltr"] .marquee-track {
  animation: marquee 25s linear infinite !important;
}

.marquee-track {
  will-change: transform;
}

/* Speed: reduce costly continuous animations */
.floating,
.spin-slow {
  animation: none !important;
}

.portfolio-card img {
  transition: 450ms ease !important;
}

@media (max-width: 768px) {

  #home>.hero-grid,
  .hero-grid {
    padding-top: 86px !important;
    background-position: center top !important;
  }

  .hero-grid .max-w-7xl {
    padding-top: 18px !important;
  }
}


/* =========================================================
   FINAL CLIENT FIX: NO CYAN/TEAL UI + PURPLE ACTIVE LINKS/BUTTONS + AUTOPLAY SAFE
   المطلوب: إزالة اللون اللبني، الاكتيف والأزرار Purple، والسلايدرات تتحرك تلقائياً
   ========================================================= */
:root {
  --pa-teal: #60317a !important;
  --pa-teal-dark: #4b2464 !important;
  --pa-purple: #60317a !important;
  --pa-purple-2: #8b4faf !important;
}

/* كل العناصر التي كانت لبني/فيروزي تتحول لأرجواني */
.text-main,
[class*="text-main"],
.text-teal,
[class*="text-teal"],
.nav-link.active,
header button:hover,
header .hover\:text-main:hover,
#apiMegaMenuWrapper h4,
#apiHeroSubtitle i,
.hero-grid .inline-flex i {
  color: #60317a !important;
}

.bg-main,
[class~="bg-main"],
.bg-teal,
[class~="bg-teal"],
.fixed-action-btn,
#apiHeroButton1,
button.bg-main,
a.bg-main {
  background: #60317a !important;
  color: #fff !important;
}

/* أزرار النافبار والهيدر بدون لبني */
header .bg-main,
header button.bg-main,
header a.bg-main,
header [class~="bg-main"] {
  background: #8b4faf !important;
  color: #fff !important;
}

.border-main,
.border-teal,
.border-main\/20,
.border-main\/10,
.border-main\/5,
.border-2.border-main,
[class*="border-main"],
[class*="border-teal"] {
  border-color: rgba(96, 49, 122, .58) !important;
}

.nav-link.active::after {
  background: linear-gradient(90deg, #60317a, #8b4faf) !important;
}

.gradient-text {
  background: linear-gradient(90deg, #ffffff 0%, #ffffff 48%, #60317a 100%) !important;
  -webkit-background-clip: text !important;
  background-clip: text !important;
  -webkit-text-fill-color: transparent !important;
}



.hero-grid .inline-flex {
  border-color: rgba(96, 49, 122, .62) !important;
}

#apiHeroSubtitle {
  border-color: transparent !important;

}



/* Hover cards without cyan */
#apiServicesGrid>div:hover,
#services .grid>div:hover,
#dynamic-service .grid>div:hover,
.portfolio-card:hover {
  background: rgba(96, 49, 122, .48),
}

/* Marquee شغال حتى مع وضع تقليل الأنيميشن السابق */
.marquee-track,
html[dir="rtl"] .marquee-track,
html[dir="ltr"] .marquee-track {
  animation-duration: 25s !important;
  animation-timing-function: linear !important;
  animation-iteration-count: infinite !important;
  animation-play-state: running !important;
  will-change: transform !important;
}

html[dir="rtl"] .marquee-track {
  animation-name: marqueeRtl !important;
}

html[dir="ltr"] .marquee-track {
  animation-name: marquee !important;
}

.marquee-track {
  background-color: transparent !important;
}

/* Swiper autoplay: لا توقف الحركة بسبب CSS */
.swiper-wrapper {
  transition-property: transform !important;
  transition-timing-function: linear !important;
  will-change: transform !important;
}

.partnersSwiper .swiper-wrapper {
  transition-timing-function: linear !important;
}

.portfolioSwiper .swiper-wrapper,
.relatedWorksSwiper .swiper-wrapper,
.caseStudiesSwiper .swiper-wrapper {
  transition-timing-function: ease !important;
}

.swiper-slide {
  backface-visibility: hidden;
  transform: translateZ(0);
}

/* تحسين سرعة الصور بدون تغيير الداتا */
img {
  decoding: async;
  image-rendering: auto;
}


:root {
  --teal-main: #00a99d;
}

/* أيقونات بدل البنفسجي */
.text-main,
.nav-link.active,
.fa-solid.text-main,
.fa-brands.text-main,
button.text-main,
h4.text-main {
  color: var(--teal-main) !important;
}

.bg-main {
  background-color: var(--teal-main) !important;
}

.border-main {
  border-color: var(--teal-main) !important;
}

.hover\:text-main:hover {
  color: var(--teal-main) !important;
}

/* إصلاح صور شركاء النجاح */
.partner-logo {
  background: transparent !important;
}

.partner-logo img {
  display: block !important;
  opacity: 1 !important;
  max-width: 100%;
  max-height: 100px;
  object-fit: contain;
}

/* ==================== POLISHED DARK MEGA MENU + SERVICE WORK CATEGORIES ==================== */
.mega-menu {
  background:
    radial-gradient(circle at 15% 10%, rgba(0, 169, 157, 0.16), transparent 32%),
    radial-gradient(circle at 88% 20%, rgba(244, 181, 68, 0.10), transparent 26%),
    linear-gradient(135deg, rgba(33, 17, 41, 0.97), rgba(54, 24, 68, 0.97) 52%, rgba(28, 15, 36, 0.98)) !important;
  border: 1px solid rgba(255, 255, 255, .10) !important;
  color: rgba(255, 255, 255, .78) !important;
}

.mega-menu::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  background: linear-gradient(180deg, rgba(255, 255, 255, .08), transparent 42%);
}

.mega-menu h4 {
  color: #00c7bb !important;
  font-weight: 900;
  letter-spacing: -.01em;
  position: relative;
  padding-bottom: .8rem;
}

.mega-menu h4::after {
  content: '';
  position: absolute;
  bottom: 0;
  width: 42px;
  height: 3px;
  border-radius: 999px;
  background: linear-gradient(90deg, #00a99d, #f4b544);
}

html[dir="rtl"] .mega-menu h4::after {
  right: 0;
}

html[dir="ltr"] .mega-menu h4::after {
  left: 0;
}

.mega-menu button {
  color: rgba(255, 255, 255, .78) !important;
  border-radius: 14px;
  padding-inline: 12px !important;
}

.mega-menu button:hover {
  color: #fff !important;
  background: rgba(0, 169, 157, .12);
  transform: translateX(-4px);
}

html[dir="ltr"] .mega-menu button:hover {
  transform: translateX(4px);
}

.service-work-categories {
  position: relative;
  overflow: hidden;
}

.service-work-categories::before {
  content: '';
  position: absolute;
  inset-inline: 0;
  top: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(96, 49, 122, .25), transparent);
}

.service-work-category-card {
  min-height: 230px;
  border: 1px solid rgba(96, 49, 122, .08);
}

.service-work-category-card:hover {
  border-color: rgba(0, 169, 157, .28);
}

.service-work-category-image-wrap {
  width: 128px;
  height: 128px;
}

@media (min-width: 768px) {
  .service-work-category-image-wrap {
    width: 160px;
    height: 160px;
  }
}

.service-work-card img {
  backface-visibility: hidden;
}

/* ===== Mega Menu ===== */

.mega-menu {
  background: linear-gradient(135deg,
      #c86a4b 0%,
      #b95e42 50%,
      #a95139 100%) !important;

  border: 1px solid rgba(255, 255, 255, .08);
  border-radius: 28px;

  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.service-category-card img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  object-position: center;
  display: block;
}

.service-category-card img {
  max-width: 140px;
  max-height: 140px;
  object-fit: contain;
  margin: auto;
}

.service-category-card img {
  width: 100%;
  height: 250px;
  object-fit: contain;
  background: #fff;
  padding: 25px;
}

/* ===== FINAL FIX CALL / WHATSAPP COLORS ===== */

.fixed-action-btn.call-btn,
a.fixed-action-btn.call-btn,
.call-btn {
  background: #9333ea !important;
  background-image: none !important;
  color: #fff !important;
}

.fixed-action-btn.whatsapp-btn,
a.fixed-action-btn.whatsapp-btn,
.whatsapp-btn {
  background: #40E0D0 !important;
  background-image: none !important;
  color: #fff !important;
}

.fixed-action-btn.call-btn i,
.fixed-action-btn.whatsapp-btn i {
  color: #fff !important;
}

/* إلغاء تأثير الدائرة لو واخدة لون قديم */
.fixed-action-btn.call-btn::before {
  background: #9333ea !important;
}

.fixed-action-btn.whatsapp-btn::before {
  background: #40E0D0 !important;
}

/* ===== START PROJECT SELECT FIX ===== */

select.project-input,
.project-input select,
#projectService,
select[name="service"] {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;

  width: 100%;
  height: 64px;

  background: rgba(255, 255, 255, .08) !important;
  backdrop-filter: blur(20px);

  border: 1px solid rgba(0, 200, 189, .25) !important;
  border-radius: 20px !important;

  color: #ffffff !important;
  font-size: 16px;
  font-weight: 700;

  padding: 0 22px;
  cursor: pointer;


  transition: .3s ease;
}

select.project-input:hover,
#projectService:hover {
  border-color: #00c8bd !important;
}

select.project-input:focus,
#projectService:focus {
  outline: none;
  border-color: #00c8bd !important;

}

/* القائمة المفتوحة */

select.project-input option,
#projectService option {
  background: #24102f !important;
  color: #ffffff !important;
  padding: 12px !important;
  font-weight: 700;
}

/* السهم */

.select-wrapper {
  position: relative;
}

.select-wrapper::after {
  content: "\f078";
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  color: #00c8bd;
  pointer-events: none;
  font-size: 14px;
}

/* RTL (Arabic) - Chevron on Left */
html[dir="rtl"] .select-wrapper::after {
  left: 20px;
  right: auto;
}

html[dir="rtl"] .select-wrapper select {
  padding-left: 55px !important;
  padding-right: 22px !important;
}

/* LTR (English) - Chevron on Right */
html[dir="ltr"] .select-wrapper::after {
  right: 20px;
  left: auto;
}

html[dir="ltr"] .select-wrapper select {
  padding-right: 55px !important;
  padding-left: 22px !important;
}

/* ===== Professional Toast / Success Message ===== */

.swal2-container {
  z-index: 999999 !important;
}

.swal2-popup.project-swal,
.swal2-popup {
  width: min(420px, calc(100vw - 32px)) !important;
  border-radius: 24px !important;
  padding: 26px 28px !important;

  background: linear-gradient(135deg, #ffffff 0%, #f8f4fb 100%) !important;
  color: #211129 !important;

  border: 1px solid rgba(96, 49, 122, .12) !important;

  font-family: 'Cairo', sans-serif !important;
}

.swal2-title {
  color: #211129 !important;
  font-size: 22px !important;
  font-weight: 900 !important;
  line-height: 1.5 !important;
}

.swal2-html-container {
  color: #475569 !important;
  font-size: 15px !important;
  font-weight: 700 !important;
  line-height: 1.8 !important;
}

.swal2-icon.swal2-success {
  border-color: #25D366 !important;
  color: #25D366 !important;
}

.swal2-success-ring {
  border-color: rgba(37, 211, 102, .35) !important;
}

.swal2-success-line-tip,
.swal2-success-line-long {
  background-color: #25D366 !important;
}

.swal2-confirm {
  background: linear-gradient(135deg, #60317a, #8b4faf) !important;
  color: #fff !important;
  border-radius: 999px !important;
  padding: 12px 30px !important;
  font-weight: 900 !important;
}

/* ===== HERO SWIPER SLIDER PREMIUM STYLING ===== */
.heroSwiper {
  --swiper-theme-color: #00c8bd !important;
  /* var(--pa-teal) */
  --swiper-navigation-size: 20px !important;
}

.heroSwiper .swiper-pagination-bullet {
  background: #ffffff !important;
  opacity: 0.45 !important;
  width: 10px !important;
  height: 10px !important;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.heroSwiper .swiper-pagination-bullet-active {
  background: #00c8bd !important;
  opacity: 1 !important;
  width: 32px !important;
  border-radius: 6px !important;
}

.heroSwiper .swiper-button-next,
.heroSwiper .swiper-button-prev {
  color: #ffffff !important;
  background: rgba(18, 7, 25, 0.4) !important;
  width: 46px !important;
  height: 46px !important;
  border-radius: 50% !important;
  backdrop-filter: blur(8px) !important;
  -webkit-backdrop-filter: blur(8px) !important;
  border: 1px solid rgba(255, 255, 255, 0.15) !important;
  transition: all 0.3s ease !important;
}

.heroSwiper .swiper-button-next:hover,
.heroSwiper .swiper-button-prev:hover {
  background: rgba(18, 7, 25, 0.7) !important;
  border-color: #00c8bd !important;
  transform: scale(1.1) !important;
}

.heroSwiper .swiper-button-next::after,
.heroSwiper .swiper-button-prev::after {
  font-size: 16px !important;
  font-weight: 900 !important;
}

/* ===== HERO SWIPER SLIDER RESPONSIVE HEIGHT AND FIT ===== */
.heroSwiper {
  --swiper-theme-color: #00c8bd !important;
  --swiper-navigation-size: 20px !important;
  height: 300px !important;
  min-height: 300px !important;
}

@media (min-width: 768px) {
  .heroSwiper {
    height: 380px !important;
    min-height: 380px !important;
  }
}

@media (min-width: 1024px) {
  .heroSwiper {
    min-height: 440px !important;
    height: 100% !important;
  }
}

/* Hero custom arrow buttons hover */
.hero-swiper-prev:hover,
.hero-swiper-next:hover {
  background: rgba(255, 255, 255, 0.35) !important;
  border-color: rgba(255, 255, 255, 0.6) !important;
  transform: translateY(-50%) scale(1.08);
}

.heroSwiper .swiper-slide img {
  width: 100% !important;
  height: 100% !important;
  min-height: 100% !important;
  object-fit: cover !important;
  object-position: center center !important;
  /* background: #120719; */
  transition: none !important;
  transform: none !important;
}

.heroSwiper .swiper-slide-active img {
  transform: none !important;
}

/* ===== REAL HERO MOBILE FIX ===== */
@media (max-width: 767px) {
  #home>.hero-grid {
    min-height: auto !important;
    padding-top: 88px !important;
    padding-bottom: 35px !important;
    display: block !important;
  }

  #home>.hero-grid .max-w-7xl {
    display: flex !important;
    flex-direction: column !important;
    gap: 28px !important;
    padding-top: 10px !important;
    padding-bottom: 10px !important;
  }

  #home>.hero-grid [data-aos="fade-up"] {
    text-align: center !important;
    width: 100% !important;
  }



  #home>.hero-grid p {
    max-width: 100% !important;
  }

  #home>.hero-grid .text-lg,
  #home>.hero-grid .md\:text-xl {
    font-size: 15px !important;
    line-height: 1.9 !important;
    margin-top: 16px !important;
  }

  #home>.hero-grid .flex.gap-2 {
    display: flex !important;
    flex-direction: row !important;
    justify-content: center !important;
    align-items: center !important;
    flex-wrap: wrap !important;
    gap: 10px !important;
    margin-top: 22px !important;
  }

  #apiHeroButton1,
  #apiHeroButton2 {
    width: auto !important;
    min-width: 138px !important;
    max-width: none !important;
    height: auto !important;
    padding: 13px 18px !important;
    border-radius: 999px !important;
    font-size: 13px !important;
    line-height: 1.2 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
  }

  #apiHeroStats {
    margin: 24px auto 0 !important;
    max-width: 330px !important;
    gap: 8px !important;
  }

  #apiHeroStats h3 {
    font-size: 22px !important;
  }

  #apiHeroStats p {
    font-size: 11px !important;
  }

  #home>.hero-grid .floating {
    width: 100% !important;
    height: auto !important;
    margin-top: 0 !important;
  }

  .heroSwiper {
    width: 100% !important;
    height: 240px !important;
    min-height: 240px !important;
    max-height: 240px !important;
    border-radius: 24px !important;
  }

  .heroSwiper .swiper-wrapper,
  .heroSwiper .swiper-slide {
    height: 240px !important;
  }

  .heroSwiper .swiper-slide img,
  #apiHeroImage {
    width: 100% !important;
    height: 240px !important;
    min-height: 240px !important;
    max-height: 240px !important;
    object-fit: contain !important;
    /* background: #120719; */
  }

  .heroSwiper .swiper-slide-active img {
    transform: none !important;
  }
}

@media (max-width: 380px) {


  #apiHeroButton1,
  #apiHeroButton2 {
    width: 100% !important;
  }

  .heroSwiper,
  .heroSwiper .swiper-wrapper,
  .heroSwiper .swiper-slide,
  .heroSwiper .swiper-slide img,
  #apiHeroImage {
    height: 215px !important;
    min-height: 215px !important;
    max-height: 215px !important;
  }
}

/* =========================================================
   PALETTE FLIP THEME - COLORS ONLY
   مستوحى من الصورة المرسلة بدون تغيير الداتا أو الهيكل
   ========================================================= */
:root {
  --pa-black: #050505;
  --pa-indigo: #464fd3;
  --pa-lavender: #6d6bb5;
  --pa-cyan: #1cadc6;
  --pa-coral: #df6974;
  --pa-peach: #f8d5c5;
  --pa-cream: #f1d8bd;
  --pa-gold: #dbb057;
  --pa-pink: #c84996;
  --pa-red: #ef3825;
  --pa-blush: #f2c9c5;
  --pa-silver: #dedfe1;
  --pa-gray: #7c7f84;
  --pa-light-gray: #bfc1c8;
  --pa-charcoal: #565a59;
  --pa-teal-deep: #0c897d;
  --pa-mint: #6bc3a2;
  --pa-yellow: #ffbd1f;

  --pa-bg: #050505;
  --pa-bg-2: #171723;
  --pa-card: rgba(255, 255, 255, .08);
  --pa-card-2: rgba(248, 213, 197, .12);
  --pa-main: #464fd3;
  --pa-main-2: #6d6bb5;
  --pa-accent: #1cadc6;
  --pa-accent-2: #df6974;
  --pa-warm: #dbb057;
  --pa-soft: #f8d5c5;
  --pa-text: #ffffff;
  --pa-muted: rgba(255, 255, 255, .74);
  --pa-border: rgba(255, 255, 255, .14);
  --pa-shadow: 0 30px 90px rgba(0, 0, 0, .42);
}

html,
body {
  color: var(--pa-text) !important;
  background-color: var(--pa-black) !important;
  background-image:
    radial-gradient(circle at 8% 12%, rgba(28, 173, 198, .28), transparent 30%),
    radial-gradient(circle at 88% 8%, rgba(223, 105, 116, .24), transparent 28%),
    radial-gradient(circle at 18% 78%, rgba(219, 176, 87, .20), transparent 32%),
    radial-gradient(circle at 86% 82%, rgba(70, 79, 211, .32), transparent 34%),
    linear-gradient(135deg, #050505 0%, #171723 42%, #30233a 100%) !important;
  background-size: cover !important;
  background-position: center !important;
  background-attachment: fixed !important;
}

body::before {
  background:
    linear-gradient(120deg, rgba(248, 213, 197, .05), rgba(28, 173, 198, .06), rgba(70, 79, 211, .08)),
    radial-gradient(circle at 20% 20%, rgba(255, 255, 255, .08) 0 1px, transparent 1.5px) !important;
  background-size: auto, 26px 26px !important;
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6,
.text-slate-900,
.text-slate-800,
.text-slate-700 {
  color: #ffffff !important;
}

p,
.text-slate-600,
.text-slate-500,
.text-slate-400,
.text-gray-500,
.text-gray-600 {}

.gradient-text {
  background: linear-gradient(90deg, var(--pa-peach), var(--pa-cyan), var(--pa-indigo), var(--pa-coral)) !important;
  -webkit-background-clip: text !important;
  -webkit-text-fill-color: transparent !important;
}

/* Tailwind color aliases */
.text-main,
.hover\:text-main:hover,
.nav-link.active {
  color: var(--pa-cyan) !important;
}

.text-teal,
.hover\:text-teal:hover {
  color: var(--pa-mint) !important;
}

.text-gold,
.text-yellow-400,
.text-yellow-500 {
  color: var(--pa-yellow) !important;
}

.bg-main,
.hover\:bg-main:hover {
  background: linear-gradient(135deg, var(--pa-indigo), var(--pa-cyan)) !important;
  color: #fff !important;
}

.bg-teal,
.hover\:bg-teal:hover {
  background: linear-gradient(135deg, var(--pa-cyan), var(--pa-teal-deep)) !important;
  color: #fff !important;
}

.bg-soft,
[class*="bg-soft"] {
  background: rgba(248, 213, 197, .10) !important;
}

.border-main,
.border-main\/10,
.border-main\/20,
.border-main\/30 {
  border-color: rgba(28, 173, 198, .32) !important;
}



/* Header / menus */
.glass,
header.glass {
  background: rgba(5, 5, 5, .70) !important;
  border-color: rgba(248, 213, 197, .12) !important;
  backdrop-filter: blur(24px) saturate(150%) !important;
  -webkit-backdrop-filter: blur(24px) saturate(150%) !important;
}

.mega-menu,
#mobileMenu,
.chatbot-panel {
  background: linear-gradient(145deg, rgba(23, 23, 35, .96), rgba(48, 35, 58, .96)) !important;
  border: 1px solid var(--pa-border) !important;
}

#apiMobileMenuDropdown,
.mega-menu .bg-soft {
  background: rgba(255, 255, 255, .07) !important;
}

.nav-link,
nav button,
#mobileMenu button {
  color: #fff !important;
}

.nav-link:hover,
nav button:hover,
#mobileMenu button:hover {
  color: rgba(48, 35, 58, .96);
}

/* Sections / cards */
main,
.page,
.page.active,
.page section,
section,
.bg-white,
[class*="bg-white"] {
  background-color: transparent !important;
}

section.py-28,
section.pb-24,
.stats-section,
#services section,
#portfolio section,
#case-studies section,
#contact section,
#about section,
#dynamic-service section {
  background:
    linear-gradient(135deg, rgba(5, 5, 5, .72), rgba(23, 23, 35, .62)),
    radial-gradient(circle at 10% 0%, rgba(28, 173, 198, .13), transparent 36%),
    radial-gradient(circle at 92% 18%, rgba(223, 105, 116, .14), transparent 34%) !important;
  border-top: 1px solid rgba(255, 255, 255, .08) !important;
  border-bottom: 1px solid rgba(255, 255, 255, .06) !important;
}

.group:hover,
.portfolio-card:hover,
.service-work-category-card:hover,
.partner-logo:hover {
  border-color: rgba(28, 173, 198, .45) !important;
}

/* Hero */
.hero-grid {
  background-image:
    linear-gradient(rgba(248, 213, 197, .06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(28, 173, 198, .07) 1px, transparent 1px),
    radial-gradient(circle at top left, rgba(223, 105, 116, .16), transparent 35%),
    radial-gradient(circle at bottom right, rgba(70, 79, 211, .20), transparent 36%) !important;
  background-size: 44px 44px, 44px 44px, auto, auto !important;
}

.heroSwiper,
.heroSwiper .swiper-slide img,
#apiHeroImage {
  /* background: linear-gradient(135deg, #050505, #171723) !important; */
  height: 100% !important;
}

.heroSwiper .swiper-button-next,
.heroSwiper .swiper-button-prev {
  background: rgba(5, 5, 5, .62) !important;
  color: var(--pa-peach) !important;
  border-color: rgba(248, 213, 197, .22) !important;
}

.heroSwiper .swiper-button-next:hover,
.heroSwiper .swiper-button-prev:hover {
  background: linear-gradient(135deg, var(--pa-indigo), var(--pa-cyan)) !important;
  border-color: transparent !important;
}

.swiper-pagination-bullet {
  background: var(--pa-peach) !important;
  opacity: .45 !important;
}

.swiper-pagination-bullet-active {
  background: var(--pa-cyan) !important;
  opacity: 1 !important;
}

/* Buttons / links */
a[class*="bg-main"],
button[class*="bg-main"],
#apiHeroButton1,
#apiHeroButton2,
button[type="submit"] {
  color: #fff !important;
}

a[class*="bg-main"]:hover,
button[class*="bg-main"]:hover,
#apiHeroButton1:hover,
#apiHeroButton2:hover,
button[type="submit"]:hover {
  background: var(--pa-pink)
}

/* Forms */
input,
textarea,
select,
.project-input {
  background: rgba(255, 255, 255, .08) !important;
  color: #fff !important;
  border-color: rgba(255, 255, 255, .16) !important;
}

input::placeholder,
textarea::placeholder {
  color: rgba(255, 255, 255, .54) !important;
}

input:focus,
textarea:focus,
select:focus,
.project-input:focus {
  border-color: var(--pa-cyan) !important;
}

option {
  background: #171723 !important;
  color: #fff !important;
}

/* Chatbot and fixed buttons */
.chatbot-header {
  background: linear-gradient(135deg, var(--pa-indigo), var(--pa-cyan), var(--pa-coral)) !important;
}

.chatbot-body {
  background: rgba(5, 5, 5, .28) !important;
}

.chat-msg.bot {
  background: rgba(255, 255, 255, .10) !important;
  color: #fff !important;
  border-color: rgba(255, 255, 255, .14) !important;
}

.chat-msg.user,
.chatbot-input-wrap button {
  background: linear-gradient(135deg, var(--pa-coral), var(--pa-indigo)) !important;
  color: #fff !important;
}

.call-btn {
  background: linear-gradient(135deg, var(--pa-indigo), var(--pa-cyan)) !important;
}

.whatsapp-btn {
  background: linear-gradient(135deg, var(--pa-teal-deep), var(--pa-mint)) !important;
}

.scroll-top-btn {
  background: linear-gradient(135deg, var(--pa-coral), var(--pa-pink), var(--pa-indigo)) !important;
}

/* Works overlays */
.rw-overlay,
.portfolio-card::after {
  background: linear-gradient(135deg, rgba(70, 79, 211, .62), rgba(28, 173, 198, .48), rgba(223, 105, 116, .52)) !important;
}

/* Home portfolio cards - solid dark background */
#home-portfolio .portfolio-card {
  background: linear-gradient(145deg, rgba(26, 13, 46, 0.95), rgba(15, 35, 55, 0.92)) !important;
  border: 1px solid rgba(96, 49, 122, 0.45) !important;
  backdrop-filter: blur(12px) !important;
  -webkit-backdrop-filter: blur(12px) !important;
}

/* Alternate gradient for visual variety using nth-child */
#home-portfolio .swiper-slide:nth-child(2n) .portfolio-card {
  background: linear-gradient(145deg, rgba(10, 30, 50, 0.95), rgba(0, 60, 55, 0.92)) !important;
  border: 1px solid rgba(0, 169, 157, 0.4) !important;
}

#home-portfolio .swiper-slide:nth-child(3n) .portfolio-card {
  background: linear-gradient(145deg, rgba(30, 10, 46, 0.95), rgba(90, 30, 110, 0.92)) !important;
  border: 1px solid rgba(150, 60, 180, 0.4) !important;
}

.rw-zoom {
  background: var(--pa-peach) !important;
  color: var(--pa-black) !important;
}

/* Logos stay normal */
.partner-logo img,
#apiPartnersWrapper img {
  filter: none !important;
  opacity: 1 !important;
  mix-blend-mode: normal !important;
}


/* =========================================================
   REQUESTED FINAL FIXES - palette coordination + nav/mega/modal
   ========================================================= */
:root {
  --palette-black: #050505;
  --palette-violet: #6c6bb4;
  --palette-cyan: #20abc2;
  --palette-coral: #df6975;
  --palette-blue: #4253d3;
  --palette-peach: #f5d2bf;
  --palette-cream: #f1d9c0;
  --palette-gold: #d9ad54;
  --palette-magenta: #c94a96;
  --palette-red: #ef3928;
  --palette-pink: #f2c9c9;
  --palette-gray: #d9dadc;
  --palette-charcoal: #555857;
  --palette-teal: #10887b;
  --palette-mint: #69c4a1;
  --palette-yellow: #ffba18;
}

/* readable premium mega menu */
.mega-menu {
  background:
    linear-gradient(135deg, rgba(5, 5, 5, .94), rgba(85, 88, 87, .88)),
    radial-gradient(circle at top right, rgba(32, 171, 194, .22), transparent 38%),
    radial-gradient(circle at bottom left, rgba(201, 74, 150, .22), transparent 42%) !important;
  border: 1px solid rgba(245, 210, 191, .28) !important;
  color: #fff !important;
  backdrop-filter: blur(24px) !important;
  -webkit-backdrop-filter: blur(24px) !important;
  padding: 28px !important;
}

.mega-menu::before {
  content: "";
  position: absolute;
  inset: 10px;
  border-radius: 1.5rem;
  pointer-events: none;
  border: 1px solid rgba(255, 255, 255, .08);
}

.mega-menu h4,
.mega-menu .text-main {
  color: var(--palette-yellow) !important;
  text-shadow: 0 8px 24px rgba(0, 0, 0, .35);
}

.mega-menu button,
.mega-menu a {
  color: rgba(255, 255, 255, .86) !important;
  border-radius: 14px;
  padding-inline: 10px;
}

.mega-menu button:hover,
.mega-menu a:hover {
  color: #fff !important;
  background: linear-gradient(90deg, rgba(32, 171, 194, .22), rgba(201, 74, 150, .18));
}

#mobileWorkDropdown #apiMobileMenuDropdown {
  background: rgba(5, 5, 5, .72) !important;
  border: 1px solid rgba(245, 210, 191, .22) !important;
}

/* hero buttons after moving Start Project */
#apiHeroStartProjectBtn {
  color: #fff !important;
  border-color: rgba(255, 255, 255, .34) !important;
  background: linear-gradient(135deg, var(--palette-magenta), var(--palette-violet)) !important;
}

#apiHeroStartProjectBtn:hover {
  transform: translateY(-4px) scale(1.03);
  background: linear-gradient(135deg, var(--palette-cyan), var(--palette-blue)) !important;
}

/* How we work page */
#how-we-work .how-card {
  background: linear-gradient(145deg, rgba(255, 255, 255, .10), rgba(255, 255, 255, .045)) !important;
  border: 1px solid rgba(255, 255, 255, .14) !important;
}

#how-we-work .how-card:nth-child(1) span {
  color: var(--palette-cyan) !important;
}

#how-we-work .how-card:nth-child(2) span {
  color: var(--palette-yellow) !important;
}

#how-we-work .how-card:nth-child(3) span {
  color: var(--palette-coral) !important;
}

#how-we-work .how-card:nth-child(4) span {
  color: var(--palette-mint) !important;
}

/* clickable image modal */
.portfolio-card img,
.service-work-category-card img,
.rw-item img,
.case-study-card img,
.swiper-slide img {
  cursor: zoom-in;
}

.global-image-modal {
  position: fixed;
  inset: 0;
  z-index: 9999999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(5, 5, 5, .86);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  opacity: 0;
  visibility: hidden;
  transition: .22s ease;
}

.global-image-modal.show {
  opacity: 1;
  visibility: visible;
}

.global-image-modal-content {
  width: min(1100px, 96vw);
  max-height: 90vh;
  border-radius: 28px;
  overflow: hidden;
  background: linear-gradient(135deg, rgba(255, 255, 255, .14), rgba(255, 255, 255, .05));
  border: 1px solid rgba(255, 255, 255, .20);
  transform: scale(.96);
  transition: .22s ease;
}

.global-image-modal.show .global-image-modal-content {
  transform: scale(1);
}

.global-image-modal-content img {
  display: block;
  width: 100%;
  max-height: 90vh;
  object-fit: contain;
  background: #050505;
  cursor: default;
}

.global-image-modal-close {
  position: fixed;
  top: 22px;
  inset-inline-end: 24px;
  width: 48px;
  height: 48px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--palette-red), var(--palette-magenta));
  color: #fff;
  font-size: 34px;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
}

@media (max-width: 767px) {
  .mega-menu {
    display: none !important;
  }

  .global-image-modal {
    padding: 12px;
  }

  .global-image-modal-close {
    top: 12px;
    inset-inline-end: 12px;
  }
}


/* =========================================================
   SPEED + CONSULTATION MODAL PATCH
   ========================================================= */
html,
body {
  background-attachment: scroll !important;
}

*,
*::before,
*::after {
  scroll-behavior: auto;
}

.glass,
.mega-menu,
.chatbot-panel,
.global-image-modal,
section.py-28,
section.pb-24,
.stats-section,
#services section,
#portfolio section,
#case-studies section,
#contact section,
#about section,
#dynamic-service section {
  /* backdrop-filter: none !important; */
  -webkit-backdrop-filter: none !important;
}

.floating,
.spin-slow,
.fixed-action-btn::before {
  animation: none !important;
}

.portfolio-card img,
.service-work-category-card img,
.rw-item img,
.case-study-card img,
.swiper-slide img {
  will-change: auto !important;
}

.partner-logo:hover,
.portfolio-card:hover img {
  transform: none !important;
}

.mega-menu {
  width: min(1120px, calc(100vw - 80px)) !important;
  padding: 26px !important;
  background: rgba(18, 7, 25, .96) !important;
  border: 1px solid rgba(255, 255, 255, .18) !important;
}

.mega-menu #apiMegaMenuWrapper {
  align-items: start !important;
}

.mega-menu h4 {
  color: var(--palette-yellow, #FDB515) !important;
  border-bottom: 2px solid rgba(255, 255, 255, .16);
  padding-bottom: 10px;
}

.mega-menu button {
  line-height: 1.7 !important;
  white-space: normal !important;
  font-size: 14px !important;
}

.consultation-modal {
  position: fixed;
  inset: 0;
  z-index: 9999998;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px;
  background: rgba(5, 5, 5, .78);
}

.consultation-card {
  width: min(640px, 96vw);
  position: relative;
  overflow: hidden;
  border-radius: 32px;
  padding: 34px;
  color: #fff;
  background:
    radial-gradient(circle at top right, rgba(32, 171, 194, .28), transparent 38%),
    linear-gradient(135deg, rgba(96, 49, 122, .98), rgba(30, 12, 39, .98));
  border: 1px solid rgba(255, 255, 255, .18);
}

.consultation-close {
  position: absolute;
  top: 16px;
  inset-inline-end: 16px;
  width: 42px;
  height: 42px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .14);
  color: #fff;
  font-size: 30px;
  line-height: 1;
}

.consultation-kicker {
  display: inline-flex;
  padding: 8px 14px;
  border-radius: 999px;
  color: #221129;
  background: linear-gradient(135deg, #FDB515, #F5D2BF);
  font-weight: 900;
  margin-bottom: 18px;
}

.consultation-card h3 {
  font-size: clamp(26px, 4vw, 42px);
  line-height: 1.35;
  font-weight: 900;
  margin: 0 0 16px;
}

.consultation-card p {
  color: rgba(255, 255, 255, .82);
  font-size: 18px;
  line-height: 2;
  margin: 0;
}

.consultation-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 26px;
}

.consultation-whatsapp,
.consultation-secondary {
  border-radius: 999px;
  padding: 15px 22px;
  font-weight: 900;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
}

.consultation-whatsapp {
  background: #25D366;
  color: #fff !important;
}

.consultation-secondary {
  background: rgba(255, 255, 255, .12);
  color: #fff;
}

@media (max-width: 640px) {
  .consultation-card {
    padding: 28px 20px;
    border-radius: 24px;
  }

  .consultation-actions {
    flex-direction: column;
  }

  .consultation-whatsapp,
  .consultation-secondary {
    width: 100%;
  }
}


/* =========================================================
   FINAL TYPOGRAPHY + SPEED + SEO VISUAL PATCH
   ========================================================= */
:root {
  --pa-font-ar: 'IBM Plex Sans Arabic', 'Cairo', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

html[lang="ar"],
html[dir="rtl"],
html[dir="rtl"] body,
body {
  font-family: var(--pa-font-ar) !important;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

/* حل مشكلة العناوين الكبيرة اللازقة */
h1:not(#apiHeroTitle),
h2,
.gradient-text,
#apiWhyUsContent,
#apiCtaTitle,
#how-we-work h1,
#dynamic-service h1,
.text-4xl,
.text-5xl,
.text-6xl,
.text-7xl,
.lg\:text-6xl,
.md\:text-7xl {
  line-height: 1.22 !important;
  letter-spacing: -0.015em;
  opacity: 1 !important;
}

.gradient-text.block {
  margin-top: 16px !important;
  display: block !important;
}

#how-we-work h1,
.page h1.gradient-text,
section h2.gradient-text {
  line-height: 1.25 !important;
}

@media (max-width:767px) {

  h1:not(#apiHeroTitle),
  h2,
  .gradient-text {
    line-height: 1.32 !important;
    letter-spacing: 0 !important;
  }
}

/* تحسين سرعة العرض وتقليل الحمل الرسومي */
html,
body {
  background-attachment: scroll !important;
}

body::before {
  opacity: .35 !important;
}

.blur-3xl {
  filter: blur(28px) !important;
}



*,
*::before,
*::after {
  scroll-behavior: auto !important;
}

img {
  contain-intrinsic-size: 300px 220px;
}

img {
  display: block;
  max-width: 100%;
}

.page section {
  contain-intrinsic-size: 1px 760px;
}

.hero-grid,
.page.active section:first-child {
  content-visibility: visible !important;
}

/* شكل زر أبدأ مشروعك بدل شاهد الأعمال */
#apiHeroButton2 span,
button span[data-ar="ابدأ مشروعك"] {
  white-space: nowrap;
}

/* الفوتر - الجملة الجديدة */
footer p[data-ar*="بناء وهندسة"] {
  color: rgba(255, 255, 255, .78) !important;
  line-height: 2 !important;
  max-width: 360px;
}


/* =========================================================
   FINAL STABILITY + SPEED PATCH
   - خط عربي أوضح وأخف
   - حل فراغ/سواد السكروول الناتج عن content-visibility والـ hidden sections
   - تقليل المؤثرات الثقيلة لتحسين الأداء
   ========================================================= */
:root {
  --pa-font-ar: 'Cairo', 'Tajawal', 'Cairo', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --pa-font-en: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

html[dir="rtl"],
html[dir="rtl"] body,
body {
  font-family: var(--pa-font-ar) !important;
  text-rendering: geometricPrecision;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

html[dir="ltr"],
html[dir="ltr"] body {
  font-family: var(--pa-font-en) !important;
}

/* العناوين الكبيرة: مسافات واضحة بين السطور بدون تغيير التصميم */
h1:not(#apiHeroTitle),
h2,
h3,
.gradient-text,
#apiCtaTitle,
#how-we-work h1,
#dynamic-service h1,
.text-4xl,
.text-5xl,
.text-6xl,
.text-7xl,
.md\:text-7xl,
.lg\:text-6xl {
  line-height: 1.34 !important;
  letter-spacing: 0 !important;
  overflow: visible !important;
  padding-block: .04em !important;
}

.gradient-text.block {
  display: block !important;
  margin-block: .08em !important;
}

@media (max-width:767px) {

  h1:not(#apiHeroTitle),
  h2,
  .gradient-text {
    line-height: 1.38 !important;
  }
}

/* إصلاح الشاشة السوداء/الفراغ أثناء السكروول: لا نستخدم content-visibility مع صفحات SPA */
.page,
.page.active,
.page section,
section,
img {
  content-visibility: visible !important;
  contain-intrinsic-size: auto !important;
}

.page {
  display: none !important;
  min-height: auto !important;
}

.page.active {
  display: block !important;
  min-height: auto !important;
  opacity: 1 !important;
  visibility: visible !important;
}

main {
  background: linear-gradient(180deg, #130719 0%, #1b0d24 42%, #120719 100%) !important;
  min-height: 100vh !important;
  padding-top: 0 !important;
}

#home.active,
#home.page.active {
  display: block !important;
  min-height: auto !important;
}

#home>.hero-grid,
.hero-grid {
  min-height: 100svh !important;
  height: auto !important;
  padding-top: 110px !important;
  padding-bottom: 60px !important;
  display: flex !important;
  align-items: center !important;
  overflow: hidden !important;
  background-color: #120719 !important;
  background-attachment: scroll !important;
}

#home>.hero-grid>* {
  opacity: 1 !important;
  visibility: visible !important;
}

#home .max-w-7xl {
  position: relative !important;
  z-index: 2 !important;
}

section.py-28,
section.pb-24,
.stats-section,
#services section,
#portfolio section,
#case-studies section,
#contact section,
#dynamic-service section,
#how-we-work {
  min-height: auto !important;
}

/* تقليل الأشياء الثقيلة جداً التي تعمل Lag في السكرول */
* {
  scroll-behavior: auto !important;
}

html,
body {
  background-attachment: scroll !important;
}

body::before {
  display: none !important;
}

.blur-3xl,
.blur-2xl {
  filter: blur(18px) !important;
}

.glass,
header.glass,
.chatbot-panel,
.mega-menu {
  /* backdrop-filter: none !important; */
  -webkit-backdrop-filter: none !important;
}

.floating,
.spin-slow,
.fixed-action-btn::before {
  animation: none !important;
}

.portfolio-card img,
.rw-img-wrap img,
.service-work-category-card img {
  will-change: auto !important;
  transform: none;
}

/* زر الهيرو الثاني يصبح أبدأ مشروعك */
#apiHeroButton2 span::before {
  content: 'أبدأ مشروعك';
}

html[dir="ltr"] #apiHeroButton2 span::before {
  content: 'Start Project';
}

#apiHeroButton2 span {
  font-size: 0 !important;
}

#apiHeroButton2 span::before {
  font-size: 16px !important;
}

/* Fix for mega menu hover gap */
.mega-parent::after {
  content: "";
  position: absolute;
  width: 100%;
  height: 40px;
  bottom: -40px;
  left: 0;
}

.mega-parent {
  color: #fff !important;
}

/* Disable all scroll animations */
[data-aos] {
  opacity: 1 !important;
  transform: none !important;
  pointer-events: auto !important;
  transition: none !important;
}

/* Fix Hero Slider Image to fill container completely */
.heroSwiper,
.heroSwiper .swiper-wrapper,
.heroSwiper .swiper-slide {
  height: 100% !important;
  min-height: 100% !important;
}

.heroSwiper img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  min-height: 100% !important;
  display: block !important;
  background: transparent !important;
}

/* =========================================================
   FINAL UI FIXES: Lightbox Controls + Hero Buttons + Mega Menu
   ========================================================= */

/* ===== Lightbox controls: ثابتة وواضحة فوق أي صورة ===== */
#swiperLightbox button {
  background: linear-gradient(135deg, rgba(96, 49, 122, .96), rgba(0, 200, 189, .92)) !important;
  color: #fff !important;
  border: 1px solid rgba(255, 255, 255, .35) !important;
  backdrop-filter: blur(14px) saturate(160%) !important;
  -webkit-backdrop-filter: blur(14px) saturate(160%) !important;
  text-shadow: 0 2px 8px rgba(0, 0, 0, .45) !important;
  opacity: 1 !important;
  transition: .25s ease !important;
}

#swiperLightbox button:hover {
  transform: translateY(-50%) scale(1.08) !important;
  background: linear-gradient(135deg, #00c8bd, #60317a) !important;

}

/* زرار الإغلاق مختلف شوية عشان يبان */
#swiperLightbox button[aria-label="Close"] {
  background: rgba(15, 15, 18, .88) !important;
  color: #fff !important;
  border: 1px solid rgba(255, 255, 255, .38) !important;

}

#swiperLightbox button[aria-label="Close"]:hover {
  transform: scale(1.08) rotate(90deg) !important;
  background: linear-gradient(135deg, #60317a, #c46046) !important;
}

/* عداد الصور */
#swiperLightbox div[style*="bottom: 24px"] {
  background: rgba(12, 7, 18, .88) !important;
  color: #fff !important;
  border: 1px solid rgba(255, 255, 255, .22) !important;
}

/* ===== Hero buttons: احجز استشارة + ابدأ مشروعك ===== */
.hero-grid button[onclick*="openConsultationModal"],
#apiHeroButton1 {
  background: #60317a !important;
  color: #fff !important;
  border: 1px solid rgba(255, 255, 255, .22) !important;

  position: relative;
  overflow: hidden;
}

.hero-grid button[onclick*="openConsultationModal"]::before,
#apiHeroButton1::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, .24);
  transform: translateX(120%);
  transition: .55s ease;
}

.hero-grid button[onclick*="openConsultationModal"]:hover::before,
#apiHeroButton1:hover::before {
  transform: translateX(-120%);
}

.hero-grid button[onclick*="openConsultationModal"]:hover,
#apiHeroButton1:hover {
  filter: brightness(1.08) !important;
}

/* زر ابدأ مشروعك */
.hero-grid #apiHeroButton2 {
  background: rgba(255, 255, 255, .94) !important;
  color: #60317a !important;

  backdrop-filter: blur(12px) !important;
  -webkit-backdrop-filter: blur(12px) !important;
}

.hero-grid #apiHeroButton2 span {
  color: #60317a !important;
}

.hero-grid #apiHeroButton2:hover {
  background: linear-gradient(135deg, #ffffff, #e9fffd) !important;
  color: #00a99d !important;
  border-color: #00c8bd !important;
  transform: translateY(-4px) scale(1.035) !important;
}

/* ===== Mega Menu: قائمة أعمالنا فوق شوية وأكتر احترافية ===== */
.mega-menu {
  top: 72px !important;
  width: min(1160px, calc(100vw - 56px)) !important;
  padding: 26px !important;
  border-radius: 26px !important;
  background:
    radial-gradient(circle at 12% 0%, rgba(0, 200, 189, .18), transparent 34%),
    radial-gradient(circle at 90% 18%, rgba(196, 96, 70, .14), transparent 30%),
    linear-gradient(145deg, rgba(28, 12, 38, .98), rgba(12, 4, 18, .96)) !important;
  border: 1px solid rgba(255, 255, 255, .14) !important;

}

/* تمنع القائمة تقفل بسبب فرق بسيط بين الناف والقائمة */
.mega-menu::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: -18px;
  height: 18px;
}

/* شكل عناوين الأعمدة */
#apiMegaMenuWrapper h4 {
  color: #00c8bd !important;
  font-size: 15px !important;
  letter-spacing: .2px;
  padding-bottom: 12px;
  margin-bottom: 12px !important;
  border-bottom: 1px solid rgba(255, 255, 255, .12);
}

/* عناصر القائمة */
#apiMegaMenuWrapper button {
  color: rgba(255, 255, 255, .78) !important;
  background: transparent !important;
  border: 1px solid transparent !important;
  border-radius: 14px !important;
  padding: 11px 13px !important;
  margin-bottom: 4px;
  font-weight: 800 !important;
  transition: .22s ease !important;
}

#apiMegaMenuWrapper button:hover {
  color: #fff !important;
  background: linear-gradient(135deg, rgba(96, 49, 122, .50), rgba(0, 200, 189, .18)) !important;
  border-color: rgba(0, 200, 189, .25) !important;
  transform: translateX(-4px);
}

html[dir="ltr"] #apiMegaMenuWrapper button:hover {
  transform: translateX(4px);
}

/* الموبايل */
@media (max-width: 768px) {
  #swiperLightbox button:hover {
    transform: scale(1.06) !important;
  }

  .hero-grid button[onclick*="openConsultationModal"],
  #apiHeroButton1,
  #apiHeroButton2 {
    width: 100% !important;
    justify-content: center !important;
  }
}

/* ===== HERO SLIDER ARROWS - BLACK BG / WHITE ICON ===== */
.hero-swiper-prev,
.hero-swiper-next,
.heroSwiper .hero-swiper-prev,
.heroSwiper .hero-swiper-next {
  width: 52px !important;
  height: 52px !important;
  border-radius: 999px !important;
  background: #111111 !important;
  color: #ffffff !important;
  border: 1px solid rgba(255, 255, 255, 0.22) !important;
  opacity: 1 !important;
  z-index: 30 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  /* backdrop-filter: none !important; */
  -webkit-backdrop-filter: none !important;
}

.hero-swiper-prev i,
.hero-swiper-next i,
.hero-swiper-prev svg,
.hero-swiper-next svg,
.heroSwiper .hero-swiper-prev i,
.heroSwiper .hero-swiper-next i {
  color: #ffffff !important;
  fill: #ffffff !important;
  stroke: #ffffff !important;
  font-size: 20px !important;
  opacity: 1 !important;
}

/* لو الزرار معمول بسهم نصي أو ::after */
.hero-swiper-prev::after,
.hero-swiper-next::after,
.hero-swiper-prev::before,
.hero-swiper-next::before {
  color: #ffffff !important;
  opacity: 1 !important;
}

/* Hover */
.hero-swiper-prev:hover,
.hero-swiper-next:hover {
  background: #000000 !important;
  color: #ffffff !important;
  transform: scale(1.08) !important;
  border-color: rgba(255, 255, 255, 0.35) !important;
}

/* امنع أي opacity من Swiper */
.hero-swiper-prev.swiper-button-disabled,
.hero-swiper-next.swiper-button-disabled {
  opacity: 1 !important;
  pointer-events: auto !important;
}

/* موبايل */
@media (max-width: 768px) {

  .hero-swiper-prev,
  .hero-swiper-next {
    width: 44px !important;
    height: 44px !important;
  }

  .hero-swiper-prev i,
  .hero-swiper-next i {
    font-size: 17px !important;
  }
}

/* ===== PROFESSIONAL FONT FIX ===== */

/* الخط الأساسي للموقع */
html,
body,
button,
input,
textarea,
select,
a,
p,
span,
div,
label,
small,
.nav-link,
.mega-menu,
.project-input {
  font-family: "Cairo", "Tajawal", system-ui, sans-serif !important;
  letter-spacing: 0 !important;
}

.mega-menu {
  font-size: 30px !important;
}

/* خط العناوين فقط بنفس إحساس الصورة */
h1:not(#apiHeroTitle),
h2,
.gradient-text {
  font-family: "Cairo", "Cairo", system-ui, sans-serif !important;
  font-weight: 400 !important;
  letter-spacing: 0 !important;
  line-height: 1.18 !important;
}

/* العناوين الفرعية والكروت تفضل مقروءة */
h3,
h4,
h5,
h6,
.font-black,
.font-bold {
  font-family: "Cairo", "Tajawal", system-ui, sans-serif !important;
  font-weight: 800 !important;
}



/* الفقرة في الهيرو */
.hero-grid p {
  font-family: "Cairo", "Tajawal", system-ui, sans-serif !important;
  font-weight: 700 !important;
  line-height: 2 !important;
}

/* النافبار يرجع مضبوط */
header nav button,
header nav span,
header button {
  font-family: "Cairo", "Tajawal", system-ui, sans-serif !important;
  font-weight: 800 !important;
  font-size: 14px !important;
}

/* ========== FIX DESKTOP MENU ICON ========== */
@media (min-width: 1280px) {

  button[onclick="toggleMobile()"],
  #mobileMenu {
    display: none !important;
  }
}

@media (max-width: 1279px) {
  button[onclick="toggleMobile()"] {
    display: flex !important;
    width: 42px !important;
    height: 42px !important;
    align-items: center !important;
    justify-content: center !important;
    border-radius: 14px !important;
    background: rgba(96, 49, 122, .12) !important;
  }

  button[onclick="toggleMobile()"] i {
    font-size: 20px !important;
    color: #60317a !important;
  }

  #mobileMenu {
    background: #211129 !important;
  }

  #mobileMenu button,
  #mobileMenu span,
  #mobileMenu i,
  #mobileWorkDropdown *,
  #apiMobileMenuDropdown * {
    color: #fff !important;
  }
}


/* ========== SERVICE WORK CATEGORIES CLEAN LIKE REFERENCE ========== */
#serviceWorkCategoriesSection {
  background: #fff !important;
  padding: 55px 0 45px !important;
  overflow: hidden !important;
}

#serviceWorkCategoriesSection h2,
#serviceWorkCategoriesSection h3,
#serviceWorkCategoriesSection p,
#serviceWorkCategoriesSection span {
  color: #211129 !important;
}

#serviceWorkCategoriesSection h2 {
  font-weight: 400 !important;
  letter-spacing: 0 !important;
}

#serviceWorkCategoriesSection .service-work-categories-slider {
  width: 100% !important;
  max-width: 1180px !important;
  margin: 28px auto 0 !important;
  overflow: hidden !important;
  padding: 0 10px !important;
}

#serviceWorkCategoriesSection .serviceWorkCategoriesSwiper {
  overflow: hidden !important;
}

#apiServiceWorkCategoriesGrid.swiper-wrapper {
  align-items: flex-start !important;
}

#apiServiceWorkCategoriesGrid .swiper-slide {
  width: 96px !important;
  height: auto !important;
  flex-shrink: 0 !important;
}

#serviceWorkCategoriesSection .service-work-category-card {
  width: 96px !important;
  min-width: 96px !important;
  height: auto !important;
  min-height: 0 !important;
  padding: 0 !important;
  margin: 0 !important;
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
  border-radius: 0 !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: flex-start !important;
  gap: 9px !important;
  text-align: center !important;
}

#serviceWorkCategoriesSection .service-work-category-card::before,
#serviceWorkCategoriesSection .service-work-category-card::after {
  display: none !important;
}

#serviceWorkCategoriesSection .service-work-category-image-wrap {
  width: 74px !important;
  height: 74px !important;
  min-width: 74px !important;
  min-height: 74px !important;
  max-width: 74px !important;
  max-height: 74px !important;
  aspect-ratio: 1 / 1 !important;
  border-radius: 50% !important;
  overflow: hidden !important;
  background: #f4f0f6 !important;
  border: 2px solid #eee6f3 !important;
  box-shadow: none !important;
  padding: 0 !important;
  margin: 0 auto !important;
  display: block !important;
}

#serviceWorkCategoriesSection .service-work-category-image-wrap img {
  width: 100% !important;
  height: 100% !important;
  max-width: none !important;
  max-height: none !important;
  object-fit: cover !important;
  object-position: center !important;
  padding: 0 !important;
  margin: 0 !important;
  border-radius: 50% !important;
  display: block !important;
  transform: none !important;
}

#serviceWorkCategoriesSection .service-work-category-title {
  display: block !important;
  width: 96px !important;
  max-width: 96px !important;
  color: #211129 !important;
  font-size: 10px !important;
  line-height: 1.25 !important;
  font-weight: 900 !important;
  text-align: center !important;
  margin: 0 auto !important;
  white-space: normal !important;
  letter-spacing: 0 !important;
  text-transform: none !important;
}

#serviceWorkCategoriesSection .service-work-category-card:hover .service-work-category-image-wrap {
  border-color: #60317a !important;
}

#serviceWorkCategoriesSection .service-work-category-card:hover .service-work-category-title {
  color: #60317a !important;
}

@media (min-width: 768px) {

  #apiServiceWorkCategoriesGrid .swiper-slide,
  #serviceWorkCategoriesSection .service-work-category-card {
    width: 112px !important;
    min-width: 112px !important;
  }

  #serviceWorkCategoriesSection .service-work-category-image-wrap {
    width: 86px !important;
    height: 86px !important;
    min-width: 86px !important;
    min-height: 86px !important;
    max-width: 86px !important;
    max-height: 86px !important;
  }

  #serviceWorkCategoriesSection .service-work-category-title {
    width: 112px !important;
    max-width: 112px !important;
    font-size: 11px !important;
  }
}

@media (max-width: 480px) {

  #apiServiceWorkCategoriesGrid .swiper-slide,
  #serviceWorkCategoriesSection .service-work-category-card {
    width: 82px !important;
    min-width: 82px !important;
  }

  #serviceWorkCategoriesSection .service-work-category-image-wrap {
    width: 62px !important;
    height: 62px !important;
    min-width: 62px !important;
    min-height: 62px !important;
    max-width: 62px !important;
    max-height: 62px !important;
  }

  #serviceWorkCategoriesSection .service-work-category-title {
    width: 82px !important;
    max-width: 82px !important;
    font-size: 9px !important;
  }
}

.serviceWorkCategoriesSwiper .swiper-wrapper {
  transition-timing-function: linear !important;
}

#serviceWorkCategoriesSection .service-work-category-card {
  cursor: pointer !important;
}

#serviceWorkCategoriesSection .service-work-category-image-wrap {
  cursor: pointer !important;
}

#serviceWorkCategoriesSection .service-work-category-title {
  cursor: pointer !important;
}

.serviceWorkCategoriesSwiper .swiper-wrapper {
  transition-timing-function: linear !important;
}

.serviceWorkCategoriesSwiper:hover .swiper-wrapper {
  transition-timing-function: linear !important;
}

.serviceWorkCategoriesSwiper .swiper-wrapper {
  transition-timing-function: linear !important;
}

.serviceWorkCategoriesSwiper:hover .swiper-wrapper {
  transition-timing-function: linear !important;
}

#serviceWorkCategoriesSection .service-work-category-card,
#serviceWorkCategoriesSection .service-work-category-image-wrap,
#serviceWorkCategoriesSection .service-work-category-title {
  cursor: pointer !important;
}

#serviceWorkCategoriesSection .service-work-category-card img {
  pointer-events: none !important;
}

/* ===== SERVICE WORK CATEGORIES - PURE CSS INFINITE MARQUEE ===== */

#serviceWorkCategoriesSection .pa-service-auto-slider {
  overflow: hidden !important;
  width: 100% !important;
  -webkit-mask-image: linear-gradient(to right, transparent 0%, black 5%, black 95%, transparent 100%);
  mask-image: linear-gradient(to right, transparent 0%, black 5%, black 95%, transparent 100%);
}

#serviceWorkCategoriesSection .pa-service-auto-track {
  display: flex !important;
  flex-wrap: nowrap !important;
  width: max-content !important;
  align-items: flex-start !important;
  gap: 16px !important;
  will-change: transform !important;
  animation: marqueeRTL 8s linear infinite !important;
  cursor: grab !important;
}

html[dir="ltr"] #serviceWorkCategoriesSection .pa-service-auto-track {
  animation-name: marqueeLTR !important;
}

@keyframes marqueeRTL {
  0% {
    transform: translateX(0);
  }

  100% {
    transform: translateX(25%);
  }
}

@keyframes marqueeLTR {
  0% {
    transform: translateX(0);
  }

  100% {
    transform: translateX(-25%);
  }
}

/* Pause on hover for interaction removed per request */
#serviceWorkCategoriesSection .pa-service-auto-track:hover {
  /* animation-play-state: paused !important; */
}

#serviceWorkCategoriesSection .pa-service-auto-track:active {
  cursor: grabbing !important;
  /* animation-play-state: paused !important; */
}

#serviceWorkCategoriesSection .service-work-auto-slide {
  flex: 0 0 auto !important;
  width: 96px !important;
  margin: 0 !important;
}

#serviceWorkCategoriesSection .service-work-category-card,
#serviceWorkCategoriesSection .service-work-category-image-wrap,
#serviceWorkCategoriesSection .service-work-category-title {
  cursor: pointer !important;
}

#serviceWorkCategoriesSection .service-work-category-image-wrap:hover img {
  filter: none !important;
  transform: none !important;
}

#serviceWorkCategoriesSection .service-work-category-card img {
  pointer-events: none !important;
}

@media (min-width: 768px) {
  #serviceWorkCategoriesSection .service-work-auto-slide {
    width: 112px !important;
  }
}

@media (max-width: 480px) {
  #serviceWorkCategoriesSection .service-work-auto-slide {
    width: 82px !important;
  }

  #serviceWorkCategoriesSection .pa-service-auto-track {
    animation-duration: 28s !important;
  }
}

.serviceWorkCategoriesSwiper .swiper-wrapper {
  transition-timing-function: linear !important;
}

.serviceWorkCategoriesSwiper .swiper-slide {
  height: auto !important;
}

/* ===== BACK HOME BUTTON ===== */
.back-home-btn {
  position: relative;
  overflow: hidden;
  letter-spacing: 0;
}

.back-home-btn i {
  transition: transform 0.3s ease;
}

.back-home-btn:hover i {
  transform: translateX(4px);
}

html[dir="ltr"] .back-home-btn i {
  transform: rotate(180deg);
}

html[dir="ltr"] .back-home-btn:hover i {
  transform: rotate(180deg) translateX(-4px);
}

/* ===== MEGA MENU HOVER FIX ===== */
.mega-parent {
  position: relative !important;
}

.mega-menu {
  /* Hide by default with animation */
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;

  /* Centered positioning */
  position: fixed !important;
  top: 88px !important;
  /* Below navbar */
  left: 50% !important;
  right: auto !important;
  width: min(1160px, calc(100vw - 40px)) !important;
  max-width: none !important;
  margin: 0 !important;
  transform: translate(-50%, 15px) !important;
  z-index: 9999 !important;
}

html[dir="ltr"] .mega-menu {
  left: 50% !important;
  right: auto !important;
}

/* Show only when exactly hovering over the parent button */
.mega-parent:hover .mega-menu {
  opacity: 1 !important;
  visibility: visible !important;

}

/* Bridge the gap STRICTLY directly under the button to prevent closing */
.mega-parent::after {
  content: "" !important;
  position: absolute !important;
  width: 100% !important;
  height: 40px !important;
  bottom: -40px !important;
  left: 0 !important;
}

/* REMOVE the wide invisible trigger that caused accidental opens */
.mega-menu::before {
  display: none !important;
  pointer-events: none !important;
}

/* =========================================================
   FOOTER APP SECTION - App Store & Google Play Buttons
   ========================================================= */

.footer-app-col {
  position: relative;
}

/* Coming Soon Badge */
.app-coming-soon-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: linear-gradient(135deg, rgba(168, 85, 247, 0.2), rgba(20, 184, 166, 0.2));
  border: 1px solid rgba(168, 85, 247, 0.4);
  color: #a78bfa;
  font-size: 12px;
  font-weight: 700;
  padding: 5px 14px;
  border-radius: 100px;
  margin-bottom: 20px;
  letter-spacing: 0.05em;
  backdrop-filter: blur(8px);
}

.badge-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #a855f7;
  animation: pulse-dot 1.6s ease-in-out infinite;
}

@keyframes pulse-dot {

  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }

  50% {
    opacity: 0.5;
    transform: scale(0.8);
  }
}

/* App Store Buttons Container */
.app-store-buttons {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

/* Base App Button */
.app-store-btn {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 13px 18px;
  border-radius: 16px;
  text-decoration: none;
  transition: all 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.app-store-btn::before {
  content: '';
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.app-store-btn:hover {
  transform: translateY(-3px) scale(1.02);
  border-color: rgba(255, 255, 255, 0.2);
}

.app-store-btn:hover::before {
  opacity: 1;
}

/* Apple App Store */
.app-store-apple {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.08) 0%, rgba(255, 255, 255, 0.04) 100%);
  backdrop-filter: blur(12px);
}

.app-store-apple::before {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.12) 0%, rgba(255, 255, 255, 0.06) 100%);
}

.app-store-apple:hover {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.15) 0%, rgba(255, 255, 255, 0.08) 100%);
}

/* Google Play */
.app-store-google {
  background: linear-gradient(135deg, rgba(168, 85, 247, 0.12) 0%, rgba(20, 184, 166, 0.12) 100%);
  backdrop-filter: blur(12px);
}

.app-store-google::before {
  background: linear-gradient(135deg, rgba(168, 85, 247, 0.2) 0%, rgba(20, 184, 166, 0.2) 100%);
}

.app-store-google:hover {
  background: linear-gradient(135deg, rgba(168, 85, 247, 0.2) 0%, rgba(20, 184, 166, 0.18) 100%);
}

/* Icon */
.app-btn-icon {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  transition: transform 0.3s ease;
}

.app-btn-icon svg {
  width: 28px;
  height: 28px;
}

.app-store-btn:hover .app-btn-icon {
  transform: scale(1.15) rotate(-5deg);
}

/* Text */
.app-btn-text {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.app-btn-label {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.55);
  font-weight: 500;
  line-height: 1;
  letter-spacing: 0.02em;
}

.app-btn-store {
  font-size: 17px;
  color: #ffffff;
  font-weight: 700;
  line-height: 1.2;
  font-family: 'Inter', system-ui, sans-serif;
  letter-spacing: -0.01em;
}

/* Shine animation on hover */
.app-store-btn::after {
  content: '';
  position: absolute;
  top: 0;
  left: -75%;
  width: 50%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.08), transparent);
  transform: skewX(-15deg);
  transition: left 0.5s ease;
}

.app-store-btn:hover::after {
  left: 125%;
}

/* Responsive */
@media (max-width: 768px) {
  .app-store-buttons {
    gap: 12px;
  }

  .app-btn-store {
    font-size: 15px;
  }
}

#home-contact {
  min-height: 100vh;
  display: flex;
  align-items: center;
}

.home-contact-card {
  background:
    linear-gradient(135deg,
      rgba(33, 17, 41, 0.92),
      rgba(96, 49, 122, 0.84));
  border: 1px solid rgba(255, 255, 255, 0.18);
  box-shadow: 0 35px 100px rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

#home-contact h2 {
  text-align: center;
}

#home-contact p {
  color: rgba(255, 255, 255, 0.82) !important;
  text-align: center;
}

#home-contact .project-input {
  width: 100%;
  background: rgba(255, 255, 255, 0.96) !important;
  color: #211129 !important;
  border: 1px solid rgba(255, 255, 255, 0.55) !important;
  border-radius: 999px;
  padding: 18px 24px;
  font-weight: 800;
  outline: none;
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.12);
}

#home-contact textarea.project-input {
  border-radius: 2rem;
}

#home-contact .project-input::placeholder {
  color: rgba(33, 17, 41, 0.55) !important;
}

#home-contact .project-input:focus {
  border-color: #00a99d !important;
  box-shadow: 0 0 0 4px rgba(0, 169, 157, 0.18);
}

#home-contact select.project-input {
  background-color: rgba(255, 255, 255, 0.96) !important;
}

#home-contact .form-error {
  display: block;
  color: #ffd6d6;
  font-weight: 700;
  margin-top: 8px;
  padding-inline: 8px;
}

#home-contact #projectSubmitBtn {
  box-shadow: 0 18px 45px rgba(96, 49, 122, 0.35);
}

@media (max-width: 768px) {
  #home-contact {
    min-height: auto;
  }

  .home-contact-card {
    border-radius: 2rem;
    padding: 24px 18px;
  }

  #home-contact .project-input {
    padding: 15px 18px;
  }
}

/* Navbar scroll background */
header {
  transition: background-color .3s ease, box-shadow .3s ease, border-color .3s ease, backdrop-filter .3s ease;
}

/* قبل الاسكرول: سيب شكل النافبار الحالي زي ما هو */
header:not(.navbar-scrolled) {
  background: transparent !important;

}

/* بعد الاسكرول: خلفية بيضاء */
header.navbar-scrolled {
  background: #ffffff !important;
  border-bottom: 1px solid rgba(15, 23, 42, .08) !important;
  box-shadow: 0 12px 35px rgba(15, 23, 42, .08) !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
}

/* ألوان النافبار قبل الاسكرول */
header:not(.navbar-scrolled) button,
header:not(.navbar-scrolled) nav button,
header:not(.navbar-scrolled) nav a,
header:not(.navbar-scrolled) span,
header:not(.navbar-scrolled) i {
  color: #ffffff !important;
}

/* ألوان النافبار بعد الاسكرول */
header.navbar-scrolled button,
header.navbar-scrolled nav button,
header.navbar-scrolled nav a,
header.navbar-scrolled span,
header.navbar-scrolled i {
  color: #211129 !important;
}

header.navbar-scrolled .text-main,
header.navbar-scrolled i.text-main,
header.navbar-scrolled .nav-link.active {
  color: #60317a !important;
}

header.navbar-scrolled .nav-link.active::after {
  background: linear-gradient(90deg, #60317a, #00a99d) !important;
}

/* Fix Case Study Details Button Alignment */
#caseStudiesGrid {
  align-items: stretch !important;
}

#caseStudiesGrid .case-study-card {
  height: 100% !important;
  min-height: 690px !important;
  display: flex !important;
  flex-direction: column !important;
}

#caseStudiesGrid .case-study-card-body {
  flex: 1 !important;
  display: flex !important;
  flex-direction: column !important;
  padding: 28px !important;
}

#caseStudiesGrid .case-study-card-title {
  min-height: 88px !important;
  display: block !important;
}

#caseStudiesGrid .case-study-card-desc {
  min-height: 105px !important;
  display: block !important;
}

/* الزرار يثبت تحت في آخر الكارد */
#caseStudiesGrid .case-study-details-btn {
  margin-top: auto !important;
  align-self: flex-start !important;
}

/* في العربي يخليه ناحية الشمال زي الصورة */
html[dir="rtl"] #caseStudiesGrid .case-study-details-btn {
  align-self: flex-start !important;
}

/* في الإنجليزي يخليه ناحية اليمين */
html[dir="ltr"] #caseStudiesGrid .case-study-details-btn {
  align-self: flex-end !important;
}

@media (max-width: 768px) {
  #caseStudiesGrid .case-study-card {
    min-height: auto !important;
  }

  #caseStudiesGrid .case-study-card-title,
  #caseStudiesGrid .case-study-card-desc {
    min-height: auto !important;
  }
}

#apiCtaButton.cta-contact-btn {
  background: #60317a !important;
  color: #ffffff !important;
}

#apiCtaButton.cta-contact-btn span,
#apiCtaButton.cta-contact-btn i {
  color: #ffffff !important;
}

#apiCtaButton.cta-contact-btn:hover {
  transform: translateY(-4px) scale(1.06);
  box-shadow: 0 28px 70px rgba(0, 169, 157, 0.38), 0 16px 45px rgba(96, 49, 122, 0.45) !important;
}

html[dir="ltr"] #apiCtaButton.cta-contact-btn i {
  transform: rotate(180deg);
}

.custom-share-overlay {
  position: fixed;
  inset: 0;
  z-index: 999999;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.custom-share-box {
  width: min(560px, 100%);
  background: #14081d;
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 28px;
  padding: 28px;
  position: relative;
}

.custom-share-close {
  position: absolute;
  top: 18px;
  inset-inline-end: 18px;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: #000;
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.custom-share-head {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 24px;
  padding-inline-end: 48px;
}

.custom-share-main-icon {
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: #000;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  flex-shrink: 0;
}

.custom-share-head h3 {
  font-size: 24px;
  font-weight: 900;
  margin: 0;
}

.custom-share-head p {
  color: rgba(255, 255, 255);
  margin: 6px 0 0;
  font-weight: 700;
}

.custom-share-link {
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 18px;
  padding: 12px;
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 22px;
}

.custom-share-link span {
  flex: 1;
  font-size: 14px;
  color: rgba(255, 255, 255, 0.8);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.custom-share-link button {
  width: 42px;
  height: 42px;
  border-radius: 14px;
  background: #000;
  color: #fff;
  border: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.custom-share-icons {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.custom-share-icons a,
.custom-share-icons button {
  min-height: 92px;
  border-radius: 22px;
  background: #000;
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.12);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  text-decoration: none;
  cursor: pointer;
  transition: 0.25s ease;
  font-family: inherit;
}

.custom-share-icons a:hover,
.custom-share-icons button:hover {
  transform: translateY(-4px);
  background: #60317a;
}

.custom-share-icons i {
  font-size: 24px;
  color: #fff !important;
}

.custom-share-icons span {
  font-size: 13px;
  font-weight: 800;
  color: #fff;
}

@media (max-width: 520px) {
  .custom-share-box {
    padding: 22px;
    border-radius: 24px;
  }

  .custom-share-icons {
    grid-template-columns: repeat(2, 1fr);
  }

  .custom-share-icons a,
  .custom-share-icons button {
    min-height: 86px;
  }
}

/* ===== FIX DETAILS BUTTON SAME LINE IN ALL CARDS ===== */

/* الكروت بشكل عام */
#services .grid>div,
#apiServicesGrid>div,
#dynamic-service .grid>div,
#caseStudiesGrid>*,
.service-work-category-page .grid>*,
#case-studies .grid>* {
  display: flex !important;
  flex-direction: column !important;
  height: 100% !important;
}

/* صورة الكارد تفضل فوق */
#services .grid>div>.overflow-hidden,
#apiServicesGrid>div>.overflow-hidden,
#dynamic-service .grid>div>.overflow-hidden,
#caseStudiesGrid>*>.overflow-hidden,
.service-work-category-page .grid>*>.overflow-hidden,
#case-studies .grid>*>.overflow-hidden {
  flex-shrink: 0 !important;
}

/* محتوى الكارد يتمدد */
#services .grid>div>.p-8,
#apiServicesGrid>div>.p-8,
#dynamic-service .grid>div>.p-8,
#services .grid>div>.p-6,
#apiServicesGrid>div>.p-6,
#dynamic-service .grid>div>.p-6,
#caseStudiesGrid>*>.p-8,
#caseStudiesGrid>*>.p-7,
#caseStudiesGrid>*>.p-6,
.service-work-category-page .grid>*>.p-8,
.service-work-category-page .grid>*>.p-7,
.service-work-category-page .grid>*>.p-6,
#case-studies .grid>*>.p-8,
#case-studies .grid>*>.p-7,
#case-studies .grid>*>.p-6 {
  display: flex !important;
  flex-direction: column !important;
  flex: 1 !important;
}

/* زر التفاصيل ينزل آخر الكارد (للكلاسات المعروفة أو آخر عنصر) */
#services .grid>div>.p-8>.flex.items-center.justify-between,
#apiServicesGrid>div>.p-8>.flex.items-center.justify-between,
#dynamic-service .grid>div>.p-8>.flex.items-center.justify-between,
#services .grid>div>.p-6>.flex.items-center.justify-between,
#apiServicesGrid>div>.p-6>.flex.items-center.justify-between,
#dynamic-service .grid>div>.p-6>.flex.items-center.justify-between,
#caseStudiesGrid>*>.p-8>*:last-child,
#caseStudiesGrid>*>.p-7>*:last-child,
#caseStudiesGrid>*>.p-6>*:last-child,
.service-work-category-page .grid>*>.p-8>*:last-child,
.service-work-category-page .grid>*>.p-7>*:last-child,
.service-work-category-page .grid>*>.p-6>*:last-child,
#case-studies .grid>*>.p-8>*:last-child,
#case-studies .grid>*>.p-7>*:last-child,
#case-studies .grid>*>.p-6>*:last-child {
  margin-top: auto !important;
  width: max-content !important;
}

/* يخلي كل الكروت في نفس الصف بنفس الارتفاع */
#services .grid,
#apiServicesGrid,
#dynamic-service .grid,
#caseStudiesGrid,
.service-work-category-page .grid,
#case-studies .grid {
  align-items: stretch !important;
}

/* ===== Manual Drag Slider - Service Work Categories ===== */
.pa-service-auto-slider {
  overflow-x: auto !important;
  overflow-y: hidden !important;
  cursor: grab !important;
  user-select: none !important;
  -webkit-user-select: none !important;
  scrollbar-width: none !important;
  -ms-overflow-style: none !important;
  scroll-behavior: auto !important;
  touch-action: pan-y !important;
  direction: ltr !important;
}

.pa-service-auto-slider::-webkit-scrollbar {
  display: none !important;
}

.pa-service-auto-slider.is-dragging {
  cursor: grabbing !important;
}

.pa-service-auto-track {
  display: flex !important;
  align-items: stretch !important;
  gap: 16px !important;
  width: max-content !important;
  animation: none !important;
  transform: none !important;
}

.service-work-auto-slide {
  flex: 0 0 auto !important;
  width: 280px !important;
}

.pa-service-auto-slider.is-dragging .service-work-category-card {
  pointer-events: none !important;
}

.service-work-category-card {
  width: 100% !important;
}

@media (max-width: 768px) {
  .service-work-auto-slide {
    width: 230px !important;
  }
}

/* ===== SERVICE WORK CATEGORIES SWIPER LOOP FIX ===== */
#serviceWorkCategoriesSection .serviceWorkCategoriesSwiper {
  overflow: hidden !important;
  width: 100% !important;
  cursor: grab !important;
}

#serviceWorkCategoriesSection .serviceWorkCategoriesSwiper:active {
  cursor: grabbing !important;
}

#serviceWorkCategoriesSection .serviceWorkCategoriesSwiper .swiper-wrapper {
  align-items: flex-start !important;
  transition-timing-function: linear !important;
  animation: none !important;
}

#apiServiceWorkCategoriesGrid.swiper-wrapper {
  display: flex !important;
  flex-wrap: nowrap !important;
  width: auto !important;
}

#apiServiceWorkCategoriesGrid .swiper-slide,
#serviceWorkCategoriesSection .service-work-auto-slide {
  flex-shrink: 0 !important;
  width: 96px !important;
  height: auto !important;
}

@media (min-width: 768px) {

  #apiServiceWorkCategoriesGrid .swiper-slide,
  #serviceWorkCategoriesSection .service-work-auto-slide {
    width: 112px !important;
  }
}

@media (max-width: 480px) {

  #apiServiceWorkCategoriesGrid .swiper-slide,
  #serviceWorkCategoriesSection .service-work-auto-slide {
    width: 82px !important;
  }
}

#serviceWorkCategoriesSection .service-work-category-card img {
  pointer-events: none !important;
  user-select: none !important;
  -webkit-user-drag: none !important;
}

main section h1,
main section h2,
main section h3,
main section h4,
main .section-title,
main .page-title,
main .dynamic-title,
main .service-title,
main .case-title,
main [id*="Title"],
#dynamic-service h1,
#dynamic-service h2,
#dynamic-service h3,
#dynamic-case-study h1,
#dynamic-case-study h2,
#dynamic-case-study h3 {
  font-family: 'Cairo', sans-serif !important;
  letter-spacing: 0 !important;
}

/* ===== Prevent static content flash before API/cache data ===== */
html.api-loading #home {
  pointer-events: none;
}

html.api-ready #home {
  transition: opacity .18s ease;
}

.api-page-loader {
  position: fixed;
  inset: 0;
  z-index: 999999;
  background: rgba(18, 7, 25, 0.4);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.4s ease, visibility 0.4s ease;
}

html.api-ready .api-page-loader {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.elegant-spinner {
  width: 65px;
  height: 65px;
  border: 4px solid transparent;
  border-radius: 50%;
  border-top-color: #00a99d;
  /* Teal */
  border-bottom-color: #60317a;
  /* Main Purple */
  animation: elegant-spin 1.2s cubic-bezier(0.5, 0, 0.5, 1) infinite;
  position: relative;
}

.elegant-spinner::before {
  content: "";
  position: absolute;
  inset: -12px;
  border-radius: 50%;
  border: 2px dashed rgba(244, 181, 68, 0.5);
  /* Gold */
  animation: elegant-spin 2.5s linear infinite reverse;
}

@keyframes elegant-spin {
  to {
    transform: rotate(360deg);
  }
}

/* ===== Professional Image Modal For Work Category Details ===== */
body.modal-open {
  overflow: hidden !important;
}

.professional-image-modal {
  position: fixed;
  inset: 0;
  z-index: 999999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 22px;
  opacity: 0;
  visibility: hidden;
  transition: opacity .25s ease, visibility .25s ease;
}

.professional-image-modal.show {
  opacity: 1;
  visibility: visible;
}

.professional-image-backdrop {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at top, rgba(96, 49, 122, .35), transparent 42%),
    rgba(7, 3, 11, .88);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.professional-image-content {
  position: relative;
  width: min(1120px, 96vw);
  max-height: 92vh;
  transform: translateY(18px) scale(.96);
  transition: transform .25s ease;
  z-index: 2;
}

.professional-image-modal.show .professional-image-content {
  transform: translateY(0) scale(1);
}

.professional-image-frame {
  width: 100%;
  max-height: 82vh;
  border-radius: 28px;
  overflow: hidden;
  background: #120719;
  border: 1px solid rgba(255, 255, 255, .14);
  box-shadow: 0 35px 120px rgba(0, 0, 0, .55);
}

.professional-image-frame img {
  width: 100%;
  max-height: 82vh;
  object-fit: contain;
  display: block;
  background: #120719;
}

.professional-image-close {
  position: absolute;
  top: -18px;
  inset-inline-end: -18px;
  width: 48px;
  height: 48px;
  border-radius: 999px;
  background: #ffffff;
  color: #60317a;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 3;
  font-size: 22px;
  box-shadow: 0 18px 50px rgba(0, 0, 0, .35);
  transition: .25s ease;
}

.professional-image-close:hover {
  transform: rotate(90deg) scale(1.06);
  background: #60317a;
  color: #fff;
}

.professional-image-caption {
  margin-top: 14px;
  text-align: center;
}

.professional-image-caption h3 {
  display: inline-flex;
  background: rgba(255, 255, 255, .1);
  border: 1px solid rgba(255, 255, 255, .16);
  color: #fff !important;
  padding: 10px 18px;
  border-radius: 999px;
  font-size: 15px;
  font-weight: 900;
  backdrop-filter: blur(8px);
}

@media (max-width: 640px) {
  .professional-image-modal {
    padding: 14px;
  }

  .professional-image-frame {
    border-radius: 20px;
  }

  .professional-image-close {
    top: 10px;
    inset-inline-end: 10px;
    width: 42px;
    height: 42px;
    font-size: 19px;
  }

  .professional-image-caption h3 {
    font-size: 13px;
    max-width: 92vw;
  }
}

#serviceWorkCategoriesSection h2,
#apiWhyUsTitle {
  font-family: 'Cairo', sans-serif !important;
  font-weight: 900 !important;
  font-variation-settings: "wght" 900;
}

header:not(.navbar-scrolled) {
  background: transparent !important;
}

header {
  background: #120719 !important;
  /* لون خلفية داكن */
  border-bottom: 1px solid rgba(255, 255, 255, 0.1) !important;
}

/* ألوان النافبار قبل الاسكرول (خلفية داكنة) */
header:not(.navbar-scrolled) button,
header:not(.navbar-scrolled) nav button,
header:not(.navbar-scrolled) nav a,
header:not(.navbar-scrolled) span,
header:not(.navbar-scrolled) i {
  color: #ffffff !important;
}

/* ألوان النافبار بعد الاسكرول (خلفية بيضاء) */
header.navbar-scrolled button,
header.navbar-scrolled nav button,
header.navbar-scrolled nav a,
header.navbar-scrolled span,
header.navbar-scrolled i {
  color: #211129 !important;
}

header.navbar-scrolled .text-main,
header.navbar-scrolled i.text-main,
header.navbar-scrolled .nav-link.active {
  color: #60317a !important;
}

/* =========================================================
   FIX: Make all blog cards same height
   ========================================================= */

/* الكارد الرئيسي */
#portfolioGrid .portfolio-card,
#apiPortfolioSectionItems .portfolio-card,
#home-portfolio .portfolio-card,
.portfolio-card {
  display: flex !important;
  flex-direction: column !important;
  height: 100% !important;
  min-height: 480px !important;
  /* ارتفاع ثابت للكارد */
}

/* صورة الكارد تفضل في مكانها */
#portfolioGrid .portfolio-card img,
#apiPortfolioSectionItems .portfolio-card img,
#home-portfolio .portfolio-card img,
.portfolio-card img {
  width: 100% !important;
  height: 290px !important;
  /* ارتفاع ثابت للصورة */
  object-fit: cover !important;
  flex-shrink: 0 !important;
}

/* محتوى الكارد يتمدد */
#portfolioGrid .portfolio-card .p-6,
#apiPortfolioSectionItems .portfolio-card .p-6,
#home-portfolio .portfolio-card .p-6,
.portfolio-card .p-6 {
  flex: 1 !important;
  display: flex !important;
  flex-direction: column !important;
}

/* العنوان */
#portfolioGrid .portfolio-card h3,
#apiPortfolioSectionItems .portfolio-card h3,
#home-portfolio .portfolio-card h3,
.portfolio-card h3 {
  font-size: 20px !important;
  font-weight: 900 !important;
  margin-bottom: 6px !important;
  min-height: 56px !important;
  /* ارتفاع ثابت للعنوان */
  display: -webkit-box !important;
  -webkit-line-clamp: 2 !important;
  -webkit-box-orient: vertical !important;
  overflow: hidden !important;
}

/* الوصف */
#portfolioGrid .portfolio-card p,
#apiPortfolioSectionItems .portfolio-card p,
#home-portfolio .portfolio-card p,
.portfolio-card p {
  min-height: 44px !important;
  display: -webkit-box !important;
  -webkit-line-clamp: 2 !important;
  -webkit-box-orient: vertical !important;
  overflow: hidden !important;
}

/* الزرار يثبت في آخر الكارد */
#portfolioGrid .portfolio-card .mt-auto,
#apiPortfolioSectionItems .portfolio-card .mt-auto,
#home-portfolio .portfolio-card .mt-auto,
.portfolio-card .mt-auto {
  margin-top: auto !important;
  padding-top: 12px !important;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  .portfolio-card {
    min-height: 420px !important;
  }

  .portfolio-card img {
    height: 200px !important;
  }

  .portfolio-card h3 {
    min-height: 48px !important;
    font-size: 18px !important;
  }
}

@media (max-width: 480px) {
  .portfolio-card {
    min-height: 380px !important;
  }

  .portfolio-card img {
    height: 170px !important;
  }
}

/* ===== FIX FOR MEDIUM SCREENS (768px - 1025px) ===== */
@media (min-width: 768px) and (max-width: 1025px) {

  /* تأكد من ظهور المحتوى الأساسي */
  main,
  .page,
  .page.active,
  #home,
  #home.active {
    display: block !important;
    min-height: auto !important;
    opacity: 1 !important;
    visibility: visible !important;
  }

  /* إصلاح الهيرو في الشاشات المتوسطة */
  #home>.hero-grid,
  .hero-grid {
    min-height: auto !important;
    height: auto !important;
    padding-top: 100px !important;
    padding-bottom: 40px !important;
    display: block !important;
  }

  #home>.hero-grid .max-w-7xl {
    display: flex !important;
    flex-direction: column !important;
    gap: 30px !important;
    padding-top: 20px !important;
    padding-bottom: 20px !important;
  }

  /* عرض العناصر في صفين */
  #home>.hero-grid [data-aos="fade-up"] {
    width: 100% !important;
    text-align: center !important;
  }

  #home>.hero-grid .floating {
    width: 100% !important;
    height: auto !important;
  }

  .heroSwiper {
    height: 320px !important;
    min-height: 320px !important;
    max-height: 320px !important;
  }

  .heroSwiper .swiper-wrapper,
  .heroSwiper .swiper-slide {
    height: 320px !important;
  }

  .heroSwiper .swiper-slide img,
  #apiHeroImage {
    height: 320px !important;
    min-height: 320px !important;
    max-height: 320px !important;
    object-fit: cover !important;
  }

  /* تأكد من ظهور جميع الأقسام */
  section.py-28,
  section.pb-24,
  .stats-section,
  #services section,
  #portfolio section,
  #case-studies section,
  #contact section,
  #dynamic-service section,
  #how-we-work {
    display: block !important;
    min-height: auto !important;
    padding: 50px 0 !important;
  }

  /* إصلاح الكروت */
  #apiServicesGrid,
  #apiWorkMethodSteps,
  #services .grid,
  #portfolio .grid,
  #case-studies .grid {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 20px !important;
  }

  /* إصلاح النافبار */
  header .h-20 {
    height: 80px !important;
    min-height: 80px !important;
  }

  main {
    padding-top: 80px !important;
  }

  /* إظهار زر القائمة في الشاشات المتوسطة */
  button[onclick="toggleMobile()"] {
    display: flex !important;
  }

  /* إخفاء القائمة الكبيرة */
  header nav.hidden.xl\:flex {
    display: none !important;
  }

  /* إصلاح الفوتر */
  footer .grid {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 30px !important;
  }
}

.portfolioSwiper .swiper-wrapper,
.serviceWorkCategoriesSwiper .swiper-wrapper,
.partnersSwiper .swiper-wrapper {
  transition-timing-function: linear !important;
}

/* Ensure buttons inherit font size in nav */
nav button,
.nav-link {
  font-size: inherit;
}