@import url("https://fonts.googleapis.com/css2?family=Cairo:wght@300;400;500;600;700;800;900&display=swap");
@import url("https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@300;400;500;600;700&display=swap");

/* Cross-browser compatibility fixes */
@supports (-webkit-touch-callout: none) {
  /* iOS Safari specific fixes */
  * {
    -webkit-tap-highlight-color: transparent;
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    user-select: none;
  }

  input,
  textarea,
  select,
  [contenteditable] {
    -webkit-user-select: text;
    user-select: text;
  }
}

/* Samsung Internet and Android Chrome fixes */
@supports not (-webkit-touch-callout: none) {
  /* Android specific fixes */
  .slider-btn,
  .ng-dot,
  .about-dot {
    touch-action: manipulation;
  }
}

/* Base cross-browser resets */
*,
*::before,
*::after {
  box-sizing: border-box;
  -webkit-box-sizing: border-box;
  -moz-box-sizing: border-box;
}

/* Cross-browser viewport fixes */
html {
  -webkit-text-size-adjust: 100%;
  -ms-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 6rem; /* sticky header height (h-24 = 96px) */
  overflow-x: hidden;
}

body {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  -webkit-overflow-scrolling: touch;
}

/* Cross-browser image fixes */
img {
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
  -webkit-transform: translateZ(0);
  -moz-transform: translateZ(0);
  -ms-transform: translateZ(0);
  transform: translateZ(0);
}

/* Cross-browser button fixes */
button,
.btn {
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  -webkit-tap-highlight-color: transparent;
  cursor: pointer;
}

/* Cross-browser input fixes */
input,
textarea,
select {
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  -webkit-tap-highlight-color: transparent;
}

/* Cross-browser focus fixes */
:focus {
  outline: none;
}

:focus-visible {
  outline: 2px solid var(--fd-green);
  outline-offset: 2px;
}

:root {
  --fd-green: #7ac143;
  --fd-navy: #1b2147;
  --fd-dark: #22262b;
  --fd-gray: #7c847c;
  --fd-taupe: #a78c52;
  --fd-offwhite: #f4f6f3;
  --fd-white: #ffffff;

  --background: #fafafa;
  --surface: #ffffff;
  --text-primary: #1f2937;
  --text-secondary: #4b5563;
  --border: #e5e7eb;
  --border-light: #f3f4f6;
  --card-bg: #ffffff;
  --card-shadow: rgba(0, 0, 0, 0.1);
  --focus-ring: 0 0 0 3px rgba(122, 193, 67, 0.35);

  /* Enhanced Font System */
  --font-en-primary: "Inter", ui-sans-serif, system-ui, sans-serif;
  --font-en-display:
    "Space Grotesk", "Inter", ui-sans-serif, system-ui, sans-serif;
  --font-ar-primary: "Cairo", "Arial", sans-serif;
  --font-ar-display: "Cairo", "Arial", sans-serif;
  --font-mono:
    "SF Mono", Monaco, "Cascadia Code", "Roboto Mono", Consolas, "Courier New",
    monospace;

  /* Font Weights */
  --font-light: 300;
  --font-normal: 400;
  --font-medium: 500;
  --font-semibold: 600;
  --font-bold: 700;
  --font-extrabold: 800;
  --font-black: 900;

  /* Line Heights */
  --line-height-tight: 1.1;
  --line-height-normal: 1.4;
  --line-height-relaxed: 1.6;

  /* Letter Spacing */
  --letter-spacing-tight: -0.025em;
  --letter-spacing-normal: 0;
  --letter-spacing-wide: 0.025em;
}

.dark {
  --background: #0f172a;
  --surface: #1e293b;
  --text-primary: #f1f5f9;
  --text-secondary: #cbd5e1;
  --border: #334155;
  --border-light: #475569;
  --card-bg: #1e293b;
  --card-shadow: rgba(0, 0, 0, 0.3);

  --fd-green: #7ac143;
  --fd-navy: #e2e8f0;
  --fd-dark: #f8fafc;
  --fd-gray: #94a3b8;
  --fd-taupe: #d4a574;
  --fd-offwhite: #1e293b;
  --fd-white: #f8fafc;
}

/* ── Dark mode: header + nav (Tailwind dark:bg-dark-surface / dark:text-dark-textsecondary are undefined) */
.dark #mainHeader {
  background: rgba(15, 23, 42, 0.95) !important;
  border-color: rgba(255, 255, 255, 0.1) !important;
}

.dark .nav-link {
  color: var(--text-secondary) !important;
}

.dark .nav-link:hover {
  color: #ffffff !important;
}

/* ── Language visibility ─────────────────────────────────────────────────────
   Use `display: revert` for shown elements so each tag keeps its natural
   display type (inline for <span>, block for <div>, etc.).
   The `.flex` / `.inline-flex` / `.inline` / `.inline-block` overrides below
   cover Tailwind utility classes that would otherwise be clobbered. */

html[lang="ar"] .lang-en,
html:not([lang="ar"]) .lang-ar {
  display: none !important;
  visibility: hidden !important;
}

html[lang="ar"] .lang-ar,
html:not([lang="ar"]) .lang-en {
  display: revert !important;
  visibility: visible !important;
}

/* Auto-apply Arabic font to all visible lang-ar elements — no need to add
   arabic-font class to every span individually */
html[lang="ar"] .lang-ar:not(.arabic-font) {
  font-family: var(--font-ar-primary);
}

/* Keep Tailwind layout utilities working on shown lang elements */
html[lang="ar"] .lang-ar.flex,
html:not([lang="ar"]) .lang-en.flex       { display: flex !important; }

html[lang="ar"] .lang-ar.inline-flex,
html:not([lang="ar"]) .lang-en.inline-flex { display: inline-flex !important; }

html[lang="ar"] .lang-ar.inline,
html:not([lang="ar"]) .lang-en.inline      { display: inline !important; }

html[lang="ar"] .lang-ar.inline-block,
html:not([lang="ar"]) .lang-en.inline-block { display: inline-block !important; }

html[lang="ar"] .lang-ar.block,
html:not([lang="ar"]) .lang-en.block        { display: block !important; }

html[lang="ar"] .lang-ar.grid,
html:not([lang="ar"]) .lang-en.grid         { display: grid !important; }

/* ── Mobile navigation RTL ───────────────────────────────────────────────────
   Applied via html[lang="ar"] (set by the no-flash inline script) so layout
   is correct before any JavaScript runs, preventing directional flicker. */
@media (max-width: 1023px) {
  html[lang="ar"] .mobile-nav-container {
    direction: rtl !important;
    text-align: right !important;
  }

  html[lang="ar"] .mobile-nav-container .nav-link {
    direction: rtl !important;
    text-align: right !important;
    justify-content: flex-start !important;
  }

  html[lang="ar"] .mobile-nav-container .flex.gap-3 {
    direction: rtl;
  }

  html[lang="ar"] #mobileLangToggle,
  html[lang="ar"] #mobileThemeToggle {
    flex-direction: row !important;
    justify-content: center !important;
  }
}

/* Mobile Header RTL */
@media (max-width: 1023px) {
  /* direction:rtl on the header naturally puts logo on the right and
     the hamburger button on the left — correct Arabic mobile layout. */
  .rtl #mainHeader,
  .rtl #mainHeader .container,
  .rtl #mainHeader .flex.items-center.justify-between {
    direction: rtl;
  }

  /* Icon buttons are symmetric — keep their internals ltr */
  .rtl #mainHeader .action-buttons-container {
    direction: ltr;
  }
}

/* Ensure all interactive header controls are always tappable */
#mobileMenuButton,
#langToggle,
#themeToggle,
#mobileLangToggle,
#mobileThemeToggle,
.toggle-btn {
  touch-action: manipulation;
  pointer-events: auto !important;
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
  cursor: pointer;
}

/* Mobile navigation container */
@media (max-width: 1023px) {
  .mobile-nav-container {
    background: rgba(255, 255, 255, 0.98);
    -webkit-backdrop-filter: blur(20px);
    backdrop-filter: blur(20px);
    border-top: 1px solid rgba(124, 132, 124, 0.1);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  }

  .dark .mobile-nav-container {
    background: rgba(31, 41, 55, 0.98);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
  }

  .rtl .mobile-nav-container {
    direction: rtl;
    background: rgba(255, 255, 255, 0.98);
    -webkit-backdrop-filter: blur(20px);
    backdrop-filter: blur(20px);
    border-top: 1px solid rgba(124, 132, 124, 0.1);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  }

  .dark.rtl .mobile-nav-container {
    background: rgba(31, 41, 55, 0.98);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
  }
}

/* Mobile navigation links */
@media (max-width: 1023px) {
  .mobile-nav-container .nav-link {
    margin: 0.25rem 0;
    padding: 0.9rem 1rem;
    border-radius: 0.9rem;
    background: transparent;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    justify-content: flex-start;
    text-decoration: none;
    font-weight: 500;
    color: var(--fd-gray);
  }

  .dark .mobile-nav-container .nav-link {
    color: rgba(203, 213, 225, 0.9);
  }

  .rtl .mobile-nav-container .nav-link {
    justify-content: flex-start;
    text-align: right;
    direction: rtl;
  }


  .mobile-nav-container .nav-link:hover {
    background: rgba(122, 193, 67, 0.1);
    -webkit-transform: translateX(8px);
    -moz-transform: translateX(8px);
    -ms-transform: translateX(8px);
    transform: translateX(8px);
  }

  .rtl .mobile-nav-container .nav-link:hover {
    background: rgba(122, 193, 67, 0.1);
    -webkit-transform: translateX(-8px);
    -moz-transform: translateX(-8px);
    -ms-transform: translateX(-8px);
    transform: translateX(-8px);
  }


  .mobile-nav-container .nav-link.active {
    background: var(--fd-green);
    color: #fff;
    -webkit-transform: translateX(8px);
    -moz-transform: translateX(8px);
    -ms-transform: translateX(8px);
    transform: translateX(8px);
  }

  .rtl .mobile-nav-container .nav-link.active {
    background: var(--fd-green);
    color: #fff;
    -webkit-transform: translateX(-8px);
    -moz-transform: translateX(-8px);
    -ms-transform: translateX(-8px);
    transform: translateX(-8px);
  }
}

/* Mobile toggle buttons */
@media (max-width: 1023px) {

  .mobile-nav-container .flex.gap-3 {
    display: flex;
    gap: 0.75rem;
    align-items: stretch;
  }

  /* The new .mobile-toggle-btn class replaces old inline Tailwind on those two buttons */
  .mobile-toggle-btn {
    flex: 1;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.875rem 0.75rem;
    border-radius: 1rem;
    background: rgba(243, 244, 246, 1);
    border: 1px solid rgba(0, 0, 0, 0.06);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
    min-height: 52px;
    font-size: 0.875rem;
    font-weight: 600;
    color: rgba(55, 65, 81, 1);
    cursor: pointer;
    -webkit-transition: background 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
    transition: background 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
  }

  .dark .mobile-toggle-btn {
    background: rgba(45, 55, 72, 1);
    color: rgba(226, 232, 240, 1);
    border-color: rgba(255, 255, 255, 0.08);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
  }

  .mobile-toggle-btn:hover {
    background: rgba(122, 193, 67, 0.12);
    border-color: rgba(122, 193, 67, 0.35);
    box-shadow: 0 4px 10px rgba(122, 193, 67, 0.15);
    -webkit-transform: translateY(-2px);
    transform: translateY(-2px);
  }

  .dark .mobile-toggle-btn:hover {
    background: rgba(122, 193, 67, 0.15);
    border-color: rgba(122, 193, 67, 0.3);
  }

  /* Inner spans of the language button — always flex-row centered */
  #mobileLangToggle .lang-ar,
  #mobileLangToggle .lang-en {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
  }

  /* RTL toggle buttons */
  .rtl .mobile-toggle-btn {
    flex-direction: row;
    justify-content: center;
  }

  /* Suppress old gap-4 rule that no longer applies */
  .rtl .mobile-nav-container .flex.gap-3 {
    flex-direction: row !important;
    justify-content: space-between;
    align-items: stretch;
  }

  /* Keep .rtl #mobileLangToggle .lang-ar centered */
  .rtl #mobileLangToggle .lang-ar,
  .rtl #mobileLangToggle .lang-en {
    display: flex;
    flex-direction: row !important;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    direction: rtl;
  }
}

/* Desktop navigation RTL (≥1024px) */
@media (min-width: 1024px) {
  /* RTL: let direction:rtl inherited from <html dir="rtl"> propagate so the
     flex row reverses naturally — logo ends up on the right, buttons on the
     left, which is the standard Arabic header layout. */
  .rtl #mainHeader,
  .rtl #mainHeader .container,
  .rtl #mainHeader .flex.items-center.justify-between {
    direction: rtl;
  }

  /* Nav links read RTL */
  .rtl #mainHeader nav {
    direction: rtl;
  }

  /* Action-buttons row stays visually LTR internally (icon buttons are
     symmetric so direction doesn't matter, but ltr prevents icon mirroring) */
  .rtl #mainHeader .action-buttons-container {
    direction: ltr;
  }
}

/* Desktop navigation links (≥1024px) */
@media (min-width: 1024px) {
  .hidden.lg:flex .nav-link {
    padding: 10px 0;
    margin: 0;
    position: relative;
    font-weight: 600;
    font-size: 16px;
    line-height: 1.5;
    color: var(--fd-gray);
    background: linear-gradient(to right, var(--fd-green), var(--fd-green))
      no-repeat;
    background-size: 0% 2px;
    background-position: left bottom;
    transition: all 0.3s ease;
    display: block;
    text-align: left;
  }

  .dark .hidden.lg:flex .nav-link {
    color: rgba(203, 213, 225, 0.9);
  }

  /* RTL: flip text direction and anchor the underline to the right */
  .rtl .hidden.lg:flex .nav-link {
    direction: rtl;
    text-align: right;
    background-position: right bottom;
  }

  .hidden.lg:flex .nav-link:hover,
  .hidden.lg:flex .nav-link.active {
    background-size: 100% 2px;
    color: var(--fd-green);
  }

  .dark .hidden.lg:flex .nav-link:hover,
  .dark .hidden.lg:flex .nav-link.active {
    color: var(--fd-green);
  }

  .hidden.lg:flex.items-center.gap-8 {
    gap: 2rem;
  }

  .rtl .hidden.lg:flex.items-center.gap-8 {
    gap: 2rem;
  }
}

/* Desktop toggle buttons (≥1024px) */
@media (min-width: 1024px) {
  .toggle-btn {
    width: 52px;
    height: 52px;
    min-width: 52px;
    max-width: 52px;
    min-height: 52px;
    max-height: 52px;
    border-radius: 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    background: linear-gradient(
      135deg,
      rgba(122, 193, 67, 0.2) 0%,
      rgba(122, 193, 67, 0.1) 100%
    );
    -webkit-backdrop-filter: blur(15px);
    backdrop-filter: blur(15px);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
    position: relative;
    overflow: hidden;
    cursor: pointer;
    outline: none;
  }

  .dark .toggle-btn,
  .dark .rtl .toggle-btn {
    background: linear-gradient(
      135deg,
      rgba(122, 193, 67, 0.15),
      rgba(42, 47, 58, 0.15)
    );
    border: 1px solid rgba(255, 255, 255, 0.1);
  }

  .toggle-btn i {
    font-size: 18px;
    transition: all 0.3s ease;
    flex-shrink: 0;
  }

  .toggle-btn:hover {
    transform: translateY(-2px) scale(1.05);
    box-shadow: 0 8px 20px rgba(122, 193, 67, 0.25);
    border-color: var(--fd-green);
  }

  .toggle-btn:focus-visible {
    outline: none;
    box-shadow: var(--focus-ring);
  }

  .rtl .toggle-btn:focus-visible {
    outline: none;
    box-shadow: var(--focus-ring);
  }
}

/* Desktop action buttons container (≥1024px) */
@media (min-width: 1024px) {
  .action-buttons-container {
    display: flex;
    align-items: center;
    gap: 12px;
    z-index: 100;
    /* Force LTR so button order stays left-to-right in both languages */
    direction: ltr;
  }

  .rtl .action-buttons-container {
    display: flex;
    align-items: center;
    gap: 12px;
    z-index: 100;
    direction: ltr;
  }

  .rtl #langToggle {
    direction: rtl;
  }

  .rtl #langToggle .lang-ar,
  .rtl #langToggle .lang-en {
    direction: rtl;
    text-align: center;
  }

  .flag {
    width: 20px;
    height: 15px;
    object-fit: contain;
    flex-shrink: 0;
  }

  .rtl .flag {
    width: 20px;
    height: 15px;
    object-fit: contain;
    flex-shrink: 0;
    margin: 0 2px;
  }
}

/* Desktop logo container (≥1024px) */
@media (min-width: 1024px) {
  .logo-container {
    display: flex;
    align-items: center;
  }

  .rtl .logo-container {
    display: flex;
    align-items: center;
  }

  .logo-image {
    width: auto;
    height: auto;
    max-width: 250px;
    max-height: 90px;
    object-fit: contain;
  }

  .rtl .logo-image {
    width: auto;
    height: auto;
    max-width: 250px;
    max-height: 90px;
    object-fit: contain;
  }
}

/* Tablet logo (768–1023px) */
@media (min-width: 768px) and (max-width: 1023px) {
  .logo-image,
  .rtl .logo-image {
    width: auto;
    height: auto;
    max-width: 220px;
    max-height: 78px;
    object-fit: contain;
  }
}

/* Desktop header: grid layout so nav is always truly centered */
@media (min-width: 1024px) {
  #mainHeader .flex.items-center.justify-between {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
  }

  /* Logo col: pin to the outer edge (start = left in LTR, right in RTL) */
  #mainHeader .flex.items-center.justify-between > :first-child {
    justify-self: start;
    align-self: center;
  }

  #mainHeader nav {
    justify-self: center;
    align-self: center;
  }

  /* Buttons col: pin to the opposite outer edge */
  #mainHeader .action-buttons-container {
    justify-self: end;
    align-self: center;
  }
}

/* Desktop navigation !important overrides — wins over earlier conflicting rules */
@media (min-width: 1024px) {
  .hidden.lg:flex .nav-link,
  .rtl .hidden.lg:flex .nav-link {
    padding: 10px 0 !important;
    font-weight: 600 !important;
    font-size: 16px !important;
    color: var(--fd-gray) !important;
    background: linear-gradient(to right, var(--fd-green), var(--fd-green))
      no-repeat !important;
    background-size: 0% 2px !important;
    transition: all 0.3s ease !important;
  }

  .rtl .hidden.lg:flex .nav-link {
    background-position: right bottom !important;
  }

  .toggle-btn,
  .rtl .toggle-btn {
    width: 52px !important;
    height: 52px !important;
    border-radius: 16px !important;
    border: 2px solid rgba(255, 255, 255, 0.3) !important;
    background: linear-gradient(
      135deg,
      rgba(122, 193, 67, 0.2) 0%,
      rgba(122, 193, 67, 0.1) 100%
    ) !important;
    -webkit-backdrop-filter: blur(15px) !important;
    backdrop-filter: blur(15px) !important;
    transition: all 0.35s cubic-bezier(0.34, 1.56, 0.64, 1) !important;
  }

  .dark .toggle-btn,
  .dark .rtl .toggle-btn {
    background: linear-gradient(
      135deg,
      rgba(122, 193, 67, 0.15),
      rgba(42, 47, 58, 0.15)
    ) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
  }

  .action-buttons-container,
  .rtl .action-buttons-container {
    gap: 12px !important;
    direction: ltr !important;
  }

  .hidden.lg:flex.items-center.gap-8,
  .rtl .hidden.lg:flex.items-center.gap-8 {
    gap: 2rem !important;
  }
}

/* Final desktop navigation override — must appear last to beat all earlier rules */
@media (min-width: 1024px) {
  /* Reset RTL overrides applied in the mobile-first rules above */
  .rtl #mainHeader .action-buttons-container,
  .rtl .action-buttons-container {
    order: unset !important;
    flex-direction: row !important;
    gap: 12px !important;
    direction: ltr !important;
  }

  .rtl .toggle-btn {
    transform: none !important;
  }

  .rtl .toggle-btn:hover {
    transform: translateY(-2px) scale(1.05) !important;
  }

  .rtl .action-buttons-container .toggle-btn {
    margin-left: 0 !important;
    margin-right: 0 !important;
  }

  .rtl .hidden.lg:flex .nav-link {
    justify-content: unset !important;
    transform: none !important;
  }

  .hidden.lg:flex .nav-link {
    margin: 0 !important;
    padding: 10px 0 !important;
    transform: none !important;
  }

  .rtl .hidden.lg:flex .nav-link {
    margin: 0 !important;
    padding: 10px 0 !important;
    transform: none !important;
  }

  #mobileMenuButton.lg\:hidden,
  .rtl #mobileMenuButton.lg\:hidden {
    display: none !important;
  }

  .toggle-btn.hidden.lg\:flex,
  .rtl .toggle-btn.hidden.lg\:flex {
    display: flex !important;
  }

  .toggle-btn.lg\:hidden,
  .rtl .toggle-btn.lg\:hidden {
    display: none !important;
  }

  @media (min-width: 1024px) {
    #mobileMenuButton,
    .rtl #mobileMenuButton {
      display: none !important;
    }

    .toggle-btn.hidden.lg\:flex,
    .rtl .toggle-btn.hidden.lg\:flex {
      display: flex !important;
    }

    .toggle-btn.lg\:hidden,
    .rtl .toggle-btn.lg\:hidden {
      display: none !important;
    }
  }

  @media (max-width: 1023px) {
    .toggle-btn.lg\:hidden,
    .rtl .toggle-btn.lg\:hidden {
      display: flex !important;
    }

    .toggle-btn.hidden.lg\:flex,
    .rtl .toggle-btn.hidden.lg\:flex {
      display: none !important;
    }
  }
}

/* ── RTL layout ──────────────────────────────────────────────────────────────
   .rtl .flex reverses row direction globally; the exceptions below restore
   specific containers that must stay left-to-right in Arabic layout. */
.rtl {
  direction: rtl;
}
.rtl .flex {
  flex-direction: row-reverse;
}
/* Navigation lists and flex-cols must stay vertical */
.rtl .mobile-nav-container .flex-col,
.rtl .flex.flex-col,
.rtl .mobile-nav-container .flex {
  flex-direction: column;
}
/* The toggle-button row in the mobile menu stays horizontal */
.rtl .mobile-nav-container .flex.gap-4,
.rtl .mobile-nav-container .flex[class*="gap-"] {
  flex-direction: row !important;
}
.rtl .mobile-nav-container .space-y-2 > * + * {
  margin-top: 0.5rem;
}
.rtl .toggle-btn {
  transform: none;
}
.rtl .toggle-btn:hover {
  transform: translateY(-2px) scale(1.05);
}
.flag {
  width: 20px;
  height: 15px;
  object-fit: contain;
}
.mobile-flag {
  width: 20px;
  height: 15px;
  object-fit: contain;
}
.rtl .flag {
  margin-left: 4px;
  margin-right: 0;
}
.rtl .mobile-flag {
  margin-left: 4px;
  margin-right: 0;
}
/* RTL: mobile toggle buttons — consolidated */
.rtl .mobile-toggle-btn {
  flex-direction: row;
  justify-content: center;
  align-items: center;
  min-height: 52px;
  height: auto;
}
.rtl #mobileLangToggle .lang-ar,
.rtl #mobileLangToggle .lang-en {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  white-space: nowrap;
}
.rtl .mobile-toggle-btn span {
  text-align: center;
}
.rtl .mobile-toggle-btn img,
.rtl .mobile-toggle-btn i {
  flex-shrink: 0;
}
.rtl .mobile-nav-container .flex.gap-3 {
  flex-direction: row;
  justify-content: space-between;
  align-items: stretch;
}
/* RTL action button row */
.rtl .action-buttons-container {
  flex-direction: row-reverse;
}
.rtl .action-buttons-container .toggle-btn {
  margin-left: 8px;
  margin-right: 0;
}
.rtl .text-right {
  text-align: left;
}
.rtl .text-left {
  text-align: right;
}
/* Exception: Keep mobile toggle container as row in RTL */
.rtl .mobile-nav-container .flex.gap-4,
.rtl .mobile-nav-container .flex[class*="gap-"] {
  flex-direction: row !important;
}
/* Ensure mobile navigation items stack vertically in RTL */
.rtl .mobile-nav-container .space-y-2 > * + * {
  margin-top: 0.5rem;
}

/* Mobile gallery card positioning */

/* Mobile backdrop-filter: disabled to avoid GPU overload on low-end devices */
@media (max-width: 768px) {
  .mobile-nav-container {
    /* Reduce backdrop-filter complexity on mobile */
    backdrop-filter: blur(8px) !important;
    -webkit-backdrop-filter: blur(8px) !important;
  }

  .toggle-btn {
    /* Disable backdrop-filter on mobile toggle buttons */
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    background: rgba(122, 193, 67, 0.2) !important;
  }

  .btn-primary {
    /* Simplify backdrop-filter on mobile buttons */
    backdrop-filter: blur(8px) !important;
    -webkit-backdrop-filter: blur(8px) !important;
  }

  .btn-primary:hover {
    backdrop-filter: blur(10px) !important;
    -webkit-backdrop-filter: blur(10px) !important;
  }

  /* 3D Gallery specific mobile optimizations */
  .mdw-image-gallery-3d {
    /* Disable backdrop-filter effects in gallery on mobile */
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
  }

  .gallery-card {
    /* Prevent backdrop-filter interference with gallery cards */
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
  }

  .image-slider-container {
    /* Remove backdrop-filter from slider containers */
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
  }
}

/* Override inline JavaScript positioning on mobile to center cards */
@media (max-width: 768px) {
  .gallery-card {
    left: 50% !important;
    transform: translateX(-50%);
    /* Prevent z-index conflicts during animation */
    z-index: 10 !important;
  }
}

/* RTL header/nav responsive adjustments */
@media (max-width: 640px) {
  .rtl #mainHeader .container {
    padding-left: 0.75rem;
    padding-right: 0.75rem;
  }

  .rtl .logo-image {
    width: 190px !important;
    height: 70px !important;
    object-fit: contain;
  }

  .rtl #mainHeader .action-buttons-container {
    gap: 0.25rem;
  }

  .rtl .toggle-btn {
    width: 40px !important;
    height: 40px !important;
  }

  .rtl .mobile-nav-container .py-6 {
    padding-top: 1rem;
    padding-bottom: 1rem;
  }

  .rtl .mobile-nav-container .nav-link {
    padding: 0.75rem 1rem;
    font-size: 0.9rem;
  }

  .mobile-toggle-btn {
    padding: 0.625rem 0.75rem;
    font-size: 0.8rem;
    min-height: 46px;
  }

  .mobile-nav-container .flex.gap-3 {
    gap: 0.625rem;
  }
}

@media (min-width: 641px) and (max-width: 768px) {
  .mobile-toggle-btn {
    padding: 0.75rem 1rem;
    font-size: 0.875rem;
    min-height: 50px;
  }

  .rtl .mobile-nav-container .nav-link {
    padding: 0.875rem 1rem;
    font-size: 0.95rem;
  }
}

@media (min-width: 769px) and (max-width: 1023px) {
  .rtl #mainHeader .container {
    padding-left: 1rem;
    padding-right: 1rem;
  }

  .rtl #mainHeader .action-buttons-container {
    gap: 0.5rem;
  }

  .rtl .mobile-nav-container .py-6 {
    padding-top: 1.5rem;
    padding-bottom: 1.5rem;
  }

  .rtl .mobile-nav-container .nav-link {
    padding: 1rem 1.25rem;
    font-size: 1rem;
  }

  .mobile-toggle-btn {
    padding: 0.875rem 1.125rem;
    font-size: 0.9rem;
    min-height: 52px;
  }
}

/* 3D gallery is excluded from RTL fixes to preserve its original scroll-driven behavior */
@media (max-width: 639px) {
}

/* News header RTL */
.rtl .news-header {
  direction: rtl !important;
  display: flex !important;
  justify-content: space-between !important;
  align-items: center !important;
  flex-direction: row !important;
}

.rtl .news-header .text-left {
  text-align: right !important;
  direction: rtl !important;
}

.rtl .news-header .text-left h2 {
  text-align: right !important;
  direction: rtl !important;
}

.rtl .news-header .text-left .w-16 {
  margin-left: auto !important;
  margin-right: 0 !important;
}

.rtl .news-grid {
  direction: rtl !important;
}

.rtl .news-item {
  border-left: none !important;
  border-right: 6px solid var(--fd-green) !important;
  text-align: right !important;
  direction: rtl !important;
  padding: 24px !important;
  background-color: var(--card-bg) !important;
  box-shadow: 0 4px 12px var(--card-shadow) !important;
  transition:
    transform 0.2s,
    box-shadow 0.2s !important;
  cursor: pointer !important;
}

.rtl .news-item:hover {
  transform: translateY(-4px) !important;
  box-shadow: 0 12px 24px var(--card-shadow) !important;
}

.rtl .news-item .date {
  text-align: right !important;
  direction: rtl !important;
  display: block !important;
  font-size: 0.8rem !important;
  color: var(--fd-gray) !important;
  margin-bottom: 10px !important;
  font-weight: 500 !important;
  letter-spacing: 0.3px !important;
}

.rtl .news-item p {
  text-align: right !important;
  direction: rtl !important;
  font-weight: 600 !important;
  color: var(--text-primary) !important;
  line-height: 1.5 !important;
}

/* Dark mode RTL news item fixes - OVERRIDE EXISTING STYLES */
.dark .rtl .news-item {
  border-left: none !important;
  border-right-color: var(--fd-green) !important;
  background-color: var(--card-bg) !important;
  box-shadow: 0 4px 12px var(--card-shadow) !important;
}

.dark .rtl .news-item:hover {
  box-shadow: 0 12px 24px var(--card-shadow) !important;
}

/* News Slider Controls RTL Fixes */
.rtl .slider-controls {
  direction: ltr !important; /* Keep controls LTR for intuitive operation */
}

.rtl .slider-btn {
  transform: scaleX(-1) !important; /* Flip chevron icons for RTL */
}

.rtl #news-prev i::before {
  content: "\f054" !important; /* fa-chevron-right */
}

.rtl #news-next i::before {
  content: "\f053" !important; /* fa-chevron-left */
}

/* News Gallery RTL Fixes */
.rtl .news-gallery {
  direction: rtl !important;
}

.rtl .news-gallery-grid {
  direction: rtl !important;
}

.rtl .branch-card {
  text-align: right !important;
  direction: rtl !important;
}

.rtl .branch-content {
  text-align: right !important;
  direction: rtl !important;
}

.rtl .branch-content h3 {
  text-align: right !important;
  direction: rtl !important;
}

.rtl .branch-content p {
  text-align: right !important;
  direction: rtl !important;
}

/* News section mobile RTL (<640px) */
@media (max-width: 639px) {
  .rtl .news {
    direction: rtl !important;
    padding: 48px 0 !important; /* Reduced padding for mobile */
  }

  .rtl .news .container {
    direction: rtl !important;
    width: 100% !important;
    max-width: 100% !important;
    padding: 0 1rem !important;
  }

  .rtl .news-header {
    direction: rtl !important;
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    margin-bottom: 2rem !important;
    flex-direction: row !important;
  }

  .rtl .news-header .text-left {
    direction: rtl !important;
    text-align: right !important;
    font-size: 1.75rem !important; /* Reduced for mobile */
    margin-bottom: 1rem !important;
  }

  .rtl .news-header .slider-controls {
    direction: ltr !important; /* Keep LTR for intuitive operation */
    display: flex !important;
    gap: 8px !important;
    align-self: center !important;
    flex-shrink: 0 !important;
  }

  .rtl .news-slider-container {
    direction: ltr !important; /* Keep LTR for slider mechanics */
    position: relative !important;
    overflow: hidden !important;
    width: 100% !important;
    margin: 0 -5px !important;
    padding: 0 5px !important;
    display: block !important;
    visibility: visible !important;
  }

  .rtl #news-slider {
    direction: ltr !important; /* Keep LTR for proper flex behavior */
    display: flex !important;
    -webkit-transition: transform 0.5s ease;
    -moz-transition: transform 0.5s ease;
    transition: transform 0.5s ease;
    gap: 20px !important;
    padding: 10px 0 !important;
    width: 100% !important;
    height: auto !important;
    overflow: visible !important;
  }

  /* RTL news item - fix content direction and override desktop styles */
  .rtl #news-slider .news-item {
    direction: rtl !important; /* Apply RTL only to item content */
    text-align: right !important;
    flex: 0 0 calc(100% - 0px) !important; /* Mobile: 1 item visible */
    min-width: 100% !important;
    padding: 20px !important; /* Slightly reduced for mobile */
    background-color: var(--card-bg) !important;
    border-left: none !important;
    border-right: 6px solid var(--fd-green) !important;
    box-shadow: 0 4px 12px var(--card-shadow) !important;
    transition: all 0.3s ease !important;
    cursor: pointer !important;
    display: block !important;
    visibility: visible !important;
    position: relative !important;
    overflow: visible !important;
  }

  /* RTL news item hover - fix mobile hover behavior */
  .rtl #news-slider .news-item:hover {
    -webkit-transform: translateY(-4px) scale(1.02);
    -moz-transform: translateY(-4px) scale(1.02);
    -ms-transform: translateY(-4px) scale(1.02);
    transform: translateY(-4px) scale(1.02);
    box-shadow: 0 12px 24px var(--card-shadow) !important;
    z-index: 10 !important;
  }

  /* RTL news item date - fix text direction */
  .rtl #news-slider .news-item .date {
    direction: rtl !important;
    text-align: right !important;
    display: block !important;
    font-size: 0.8rem !important;
    color: var(--fd-gray) !important;
    margin-bottom: 8px !important;
    font-weight: 500 !important;
    letter-spacing: 0.3px !important;
  }

  /* RTL news item text - fix text direction */
  .rtl #news-slider .news-item p {
    direction: rtl !important;
    text-align: right !important;
    font-weight: 600 !important;
    color: var(--text-primary) !important;
    line-height: 1.5 !important;
    margin: 0 !important;
  }

  /* RTL news slider buttons - fix styling and positioning */
  .rtl .slider-btn {
    transform: scaleX(-1) !important; /* Flip chevron icons for RTL */
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 40px !important;
    height: 40px !important;
    border-radius: 50% !important;
    background: var(--fd-green) !important;
    color: white !important;
    border: none !important;
    cursor: pointer !important;
    transition: all 0.3s ease !important;
    font-size: 14px !important;
  }

  /* RTL news slider button hover */
  .rtl .slider-btn:hover {
    background: var(--fd-green) !important;
    transform: scaleX(-1) scale(1.1) !important;
  }

  /* RTL news slider button disabled state */
  .rtl .slider-btn:disabled {
    background: var(--fd-gray) !important;
    cursor: not-allowed !important;
    opacity: 0.5 !important;
  }

  /* RTL news slider button icons - fix icon direction */
  .rtl #news-prev i::before {
    content: "\f054" !important; /* fa-chevron-right */
  }

  .rtl #news-next i::before {
    content: "\f053" !important; /* fa-chevron-left */
  }
}

/* Dark mode RTL news section mobile fixes */
@media (max-width: 639px) {
  .dark .rtl #news-slider .news-item {
    background-color: var(--card-bg) !important;
    border-right-color: var(--fd-green) !important;
    box-shadow: 0 4px 12px var(--card-shadow) !important;
  }

  .dark .rtl #news-slider .news-item:hover {
    box-shadow: 0 12px 24px var(--card-shadow) !important;
  }

  .dark .rtl #news-slider .news-item .date {
    color: var(--fd-gray) !important;
  }

  .dark .rtl #news-slider .news-item p {
    color: var(--text-primary) !important;
  }

  .dark .rtl .slider-btn {
    background: var(--fd-green) !important;
  }

  .dark .rtl .slider-btn:hover {
    background: var(--fd-green) !important;
  }

  .dark .rtl .slider-btn:disabled {
    background: var(--fd-gray) !important;
  }
}

/* News gallery mobile RTL (<640px) */
@media (max-width: 639px) {
  /* LTR mechanics preserved so translateX math works correctly even in Arabic */
  html[lang="ar"] .news-gallery-mobile-slider {
    direction: ltr !important;
    position: relative !important;
    overflow: hidden !important;
    width: 100% !important;
  }

  html[lang="ar"] #newsGalleryTrack {
    direction: ltr !important; /* Keep LTR for proper flex behavior */
    display: flex !important;
    transition: transform 0.4s cubic-bezier(0.23, 1, 0.32, 1) !important;
    width: 100% !important;
    height: auto !important;
  }

  html[lang="ar"] .news-gallery-mobile-slide {
    direction: rtl !important; /* Apply RTL only to slide content */
    flex: 0 0 100% !important;
    min-width: 100% !important;
    width: 100% !important;
    padding: 0 4px !important;
    display: block !important;
    position: relative !important;
    overflow: hidden !important;
  }

  html[lang="ar"] .news-gallery-mobile-slide .branch-card {
    direction: rtl !important;
    text-align: right !important;
    position: relative !important;
    border-radius: 12px !important;
    overflow: hidden !important;
    height: 200px !important;
    background: var(--card-bg) !important;
    box-shadow: 0 4px 12px var(--card-shadow) !important;
    transition: all 0.3s ease !important;
  }

  html[lang="ar"] .news-gallery-mobile-slide .branch-card:hover {
    transform: translateY(-4px) scale(1.02) !important;
    box-shadow: 0 12px 24px var(--card-shadow) !important;
  }

  html[lang="ar"] .news-gallery-mobile-slide .branch-content {
    direction: rtl !important;
    text-align: right !important;
    position: absolute !important;
    bottom: 0 !important;
    left: 0 !important;
    right: 0 !important;
    padding: 1rem !important;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.8)) !important;
    color: white !important;
  }

  html[lang="ar"] .news-gallery-mobile-slide .branch-content h3 {
    direction: rtl !important;
    text-align: right !important;
    font-size: 1.1rem !important;
    font-weight: 600 !important;
    margin-bottom: 0.25rem !important;
    color: white !important;
  }

  html[lang="ar"] .news-gallery-mobile-slide .branch-content p {
    direction: rtl !important;
    text-align: right !important;
    font-size: 0.85rem !important;
    font-weight: 400 !important;
    line-height: 1.4 !important;
    color: rgba(255, 255, 255, 0.9) !important;
    margin: 0 !important;
  }

  html[lang="ar"] .news-gallery-mobile-dots {
    direction: ltr !important; /* LTR so dots render left-to-right regardless of page language */
    display: flex !important;
    justify-content: center !important;
    gap: 8px !important;
    margin-top: 1rem !important;
    padding: 0 1rem !important;
  }

  html[lang="ar"] .ng-dot {
    width: 8px !important;
    height: 8px !important;
    border-radius: 50% !important;
    background: var(--border-light) !important;
    border: none !important;
    cursor: pointer !important;
    transition: all 0.3s ease !important;
    direction: ltr !important;
  }

  html[lang="ar"] .ng-dot.active {
    background: var(--fd-green) !important;
    width: 24px !important;
    border-radius: 4px !important;
  }

  html[lang="ar"] .ng-dot:hover {
    background: var(--fd-gray) !important;
  }
}

@media (max-width: 639px) {
  html[lang="ar"] .news-gallery-mobile-dots {
    position: relative !important;
    z-index: 10 !important;
  }
}

/* News gallery mobile RTL — slider mechanics */
@media (max-width: 639px) {
  .rtl .news-gallery-mobile-slider {
    direction: ltr !important; /* Keep LTR for slider mechanics */
    position: relative;
    overflow: hidden;
    width: 100%;
    display: block !important;
    visibility: visible !important;
  }

  .rtl .news-gallery-mobile-track {
    direction: ltr !important; /* Keep LTR for proper flex behavior */
    display: flex !important;
    -webkit-transition: transform 0.4s cubic-bezier(0.23, 1, 0.32, 1);
    -moz-transition: transform 0.4s cubic-bezier(0.23, 1, 0.32, 1);
    transition: transform 0.4s cubic-bezier(0.23, 1, 0.32, 1);
    -webkit-will-change: transform;
    will-change: transform;
    width: 100% !important;
    height: auto !important;
    overflow: visible !important;
  }

  .rtl .news-gallery-mobile-slide {
    direction: rtl !important; /* Apply RTL only to slide content */
    flex: 0 0 100% !important;
    min-width: 100% !important;
    padding: 0 4px !important;
    width: 100% !important;
    display: block !important;
    visibility: visible !important;
    overflow: visible !important;
  }

  .rtl .news-gallery-mobile-slide .branch-card {
    direction: rtl !important;
    text-align: right !important;
    position: relative !important;
    border-radius: 12px !important;
    overflow: hidden !important;
    height: 220px !important;
    width: 100% !important;
    display: block !important;
    visibility: visible !important;
    cursor: pointer !important;
    grid-row: unset !important;
    grid-column: unset !important;
    margin: 0 !important;
    padding: 0 !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    background: linear-gradient(
      135deg,
      rgba(255, 255, 255, 0.1) 0%,
      transparent 50%,
      rgba(0, 0, 0, 0.05) 100%
    ) !important;
  }

  .rtl .news-gallery-mobile-slide .branch-card img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    display: block !important;
    visibility: visible !important;
    transform: none !important;
    transition: none !important;
  }

  .rtl .news-gallery-mobile-slide .branch-overlay {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    display: block !important;
    visibility: visible !important;
    background: linear-gradient(
      to bottom,
      rgba(0, 0, 0, 0.1) 0%,
      rgba(0, 0, 0, 0.6) 100%
    ) !important;
    transition: none !important;
  }

  .rtl .news-gallery-mobile-slide .branch-content {
    direction: rtl !important;
    text-align: right !important;
    position: absolute !important;
    bottom: 0 !important;
    left: 0 !important;
    right: 0 !important;
    width: 100% !important;
    padding: 16px !important;
    color: var(--fd-white) !important;
    z-index: 2 !important;
    display: block !important;
    visibility: visible !important;
    transform: translateY(0) !important;
    transition: none !important;
  }

  .rtl .news-gallery-mobile-slide .branch-content h3 {
    direction: rtl !important;
    text-align: right !important;
    margin: 0 0 4px 0 !important;
    display: block !important;
    visibility: visible !important;
    font-size: 1.25rem !important;
    font-weight: 600 !important;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5) !important;
    color: var(--fd-white) !important;
  }

  .rtl .news-gallery-mobile-slide .branch-content .branch-date {
    direction: rtl !important;
    text-align: right !important;
    display: block !important;
    visibility: visible !important;
    font-size: 0.875rem !important;
    opacity: 0.9 !important;
    font-weight: 400 !important;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5) !important;
    color: var(--fd-white) !important;
  }

  .rtl .news-gallery-mobile-dots {
    direction: rtl !important;
    display: flex !important;
    justify-content: center !important;
    gap: 8px !important;
    margin-top: 16px !important;
    padding: 0 16px !important;
  }

  .rtl .news-gallery-mobile-dots .ng-dot {
    direction: rtl !important;
    width: 8px !important;
    height: 8px !important;
    border-radius: 50% !important;
    border: none !important;
    background: rgba(27, 33, 71, 0.25) !important;
    cursor: pointer !important;
    transition: all 0.3s ease !important;
    padding: 0 !important;
    display: block !important;
    visibility: visible !important;
  }

  /* Active dot */
  .rtl .news-gallery-mobile-dots .ng-dot.active {
    background: var(--fd-green) !important;
    width: 24px !important;
    border-radius: 4px !important;
  }

  .rtl .news-gallery-mobile-dots .ng-dot:hover {
    background: var(--fd-navy) !important;
  }

  /* Disable hover transforms on mobile — touch devices have no hover state */
  .rtl .news-gallery-mobile-slide .branch-card:hover {
    transform: none !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15) !important;
  }

  .rtl .news-gallery-mobile-slide .branch-card:hover img {
    transform: none !important;
  }

  .rtl .news-gallery-mobile-slide .branch-card:hover .branch-overlay {
    background: linear-gradient(
      to bottom,
      rgba(0, 0, 0, 0.1) 0%,
      rgba(0, 0, 0, 0.6) 100%
    ) !important;
  }

  .rtl .news-gallery-mobile-slide .branch-card:hover .branch-content {
    transform: translateY(0) !important;
  }
}

/* Dark mode RTL mobile news gallery fixes */
@media (max-width: 639px) {
  .dark .rtl .news-gallery-mobile-dots .ng-dot {
    background: rgba(226, 232, 240, 0.25) !important;
  }

  .dark .rtl .news-gallery-mobile-dots .ng-dot.active {
    background: var(--fd-green) !important;
  }

  .dark .rtl .news-gallery-mobile-dots .ng-dot:hover {
    background: var(--fd-green) !important;
  }
}

/* About carousel mobile RTL (<640px) */
@media (max-width: 639px) {
  .rtl .about-carousel-wrapper {
    direction: ltr !important; /* Keep LTR for slider mechanics */
    position: relative !important;
    overflow: hidden !important;
    width: 100% !important;
    display: block !important;
    visibility: visible !important;
  }

  .rtl .about-carousel-track {
    direction: ltr !important; /* Keep LTR for proper flex behavior */
    display: flex !important;
    transition: transform 0.4s cubic-bezier(0.23, 1, 0.32, 1) !important;
    will-change: transform !important;
    width: 100% !important;
    height: auto !important;
    overflow: visible !important;
  }

  .rtl .about-carousel-slide {
    direction: rtl !important;
    flex: 0 0 100% !important;
    min-width: 100% !important;
    padding: 0 4px !important;
    width: 100% !important;
    display: block !important;
    visibility: visible !important;
    overflow: visible !important;
  }

  .rtl .about-carousel-slide .relative {
    direction: rtl !important;
    text-align: right !important;
    position: relative !important;
    overflow: hidden !important;
    border-radius: 0.75rem !important; /* rounded-xl */
    box-shadow:
      0 10px 15px -3px rgba(0, 0, 0, 0.1),
      0 4px 6px -2px rgba(0, 0, 0, 0.05) !important;
    display: block !important;
    visibility: visible !important;
    width: 100% !important;
    height: 288px !important; /* h-72 */
  }

  .rtl .about-carousel-slide img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    display: block !important;
    visibility: visible !important;
  }

  .rtl .about-carousel-slide .absolute.inset-0 {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    display: block !important;
    visibility: visible !important;
    background: linear-gradient(
      to top,
      rgba(0, 0, 0, 0.7),
      rgba(0, 0, 0, 0.4),
      transparent
    ) !important;
  }

  .rtl .about-carousel-slide .absolute.bottom-0 {
    direction: rtl !important;
    text-align: right !important;
    position: absolute !important;
    bottom: 0 !important;
    left: 0 !important;
    right: 0 !important;
    width: 100% !important;
    padding: 1.5rem !important;
    display: block !important;
    visibility: visible !important;
  }

  .rtl .about-carousel-slide .absolute.top-4 {
    position: absolute !important;
    top: 1rem !important;
    left: auto !important;
    right: 1rem !important; /* Move to right in RTL */
    display: block !important;
    visibility: visible !important;
  }

  /* RTL about carousel title - fix text direction */
  .rtl .about-carousel-slide h3 {
    direction: rtl !important;
    text-align: right !important;
    font-size: 1.5rem !important;
    font-weight: 700 !important;
    margin: 0 0 0.5rem 0 !important;
    color: var(--fd-white) !important;
    display: block !important;
    visibility: visible !important;
  }

  /* RTL about carousel description - fix text direction */
  .rtl .about-carousel-slide p {
    direction: rtl !important;
    text-align: right !important;
    font-size: 1rem !important;
    line-height: 1.5 !important;
    margin: 0 !important;
    color: rgba(255, 255, 255, 0.9) !important;
    display: block !important;
    visibility: visible !important;
  }

  /* RTL about carousel dots container - RTL direction on mobile Arabic only */
  .rtl .about-carousel-dots {
    direction: rtl !important; /* RTL for mobile Arabic */
    display: flex !important;
    justify-content: center !important;
    gap: 8px !important;
    margin-top: 16px !important;
    padding: 0 16px !important;
  }

  /* RTL about carousel dots - fix individual dot styling */
  .rtl .about-carousel-dots .about-dot {
    direction: rtl !important; /* RTL for mobile Arabic */
    width: 8px !important;
    height: 8px !important;
    border-radius: 50% !important;
    border: none !important;
    background: rgba(27, 33, 71, 0.25) !important;
    cursor: pointer !important;
    transition: all 0.3s ease !important;
    padding: 0 !important;
    display: block !important;
    visibility: visible !important;
  }

  /* RTL active dot - fix styling */
  .rtl .about-carousel-dots .about-dot.active {
    background: var(--fd-green) !important;
    width: 24px !important;
    border-radius: 4px !important;
  }

  /* RTL hover state for dots */
  .rtl .about-carousel-dots .about-dot:hover {
    background: var(--fd-navy) !important;
  }
}

/* Dark mode RTL about carousel fixes */
@media (max-width: 639px) {
  .dark .rtl .about-carousel-dots .about-dot {
    background: rgba(226, 232, 240, 0.25) !important;
  }

  .dark .rtl .about-carousel-dots .about-dot.active {
    background: var(--fd-green) !important;
  }

  .dark .rtl .about-carousel-dots .about-dot:hover {
    background: var(--fd-green) !important;
  }
}

/* Reset the mobile-only RTL overrides above at tablet and up — these elements are hidden on desktop */
@media (min-width: 640px) {
  .rtl .news-gallery-mobile-slider,
  .rtl .news-gallery-mobile-track,
  .rtl .news-gallery-mobile-slide,
  .rtl .news-gallery-mobile-slide .branch-card,
  .rtl .news-gallery-mobile-slide .branch-card img,
  .rtl .news-gallery-mobile-slide .branch-overlay,
  .rtl .news-gallery-mobile-slide .branch-content,
  .rtl .news-gallery-mobile-slide .branch-content h3,
  .rtl .news-gallery-mobile-slide .branch-content .branch-date,
  .rtl .news-gallery-mobile-dots,
  .rtl .news-gallery-mobile-dots .ng-dot,
  .rtl .about-carousel-wrapper,
  .rtl .about-carousel-track,
  .rtl .about-carousel-slide,
  .rtl .about-carousel-slide .relative,
  .rtl .about-carousel-slide img,
  .rtl .about-carousel-slide .absolute.inset-0,
  .rtl .about-carousel-slide .absolute.bottom-0,
  .rtl .about-carousel-slide .absolute.top-4,
  .rtl .about-carousel-slide h3,
  .rtl .about-carousel-slide p,
  .rtl .about-carousel-dots,
  .rtl .about-carousel-dots .about-dot {
    all: unset !important;
    display: none !important;
  }
}

/* Same reset for English — the mobile-slider elements are Arabic-only */
html:not([lang="ar"]) .news-gallery-mobile-slider,
html:not([lang="ar"]) .news-gallery-mobile-track,
html:not([lang="ar"]) .news-gallery-mobile-slide,
html:not([lang="ar"]) .news-gallery-mobile-slide .branch-card,
html:not([lang="ar"]) .news-gallery-mobile-slide .branch-card img,
html:not([lang="ar"]) .news-gallery-mobile-slide .branch-overlay,
html:not([lang="ar"]) .news-gallery-mobile-slide .branch-content,
html:not([lang="ar"]) .news-gallery-mobile-slide .branch-content h3,
html:not([lang="ar"]) .news-gallery-mobile-slide .branch-content .branch-date,
html:not([lang="ar"]) .news-gallery-mobile-dots,
html:not([lang="ar"]) .news-gallery-mobile-dots .ng-dot,
html:not([lang="ar"]) .about-carousel-wrapper,
html:not([lang="ar"]) .about-carousel-track,
html:not([lang="ar"]) .about-carousel-slide,
html:not([lang="ar"]) .about-carousel-slide .relative,
html:not([lang="ar"]) .about-carousel-slide img,
html:not([lang="ar"]) .about-carousel-slide .absolute.inset-0,
html:not([lang="ar"]) .about-carousel-slide .absolute.bottom-0,
html:not([lang="ar"]) .about-carousel-slide .absolute.top-4,
html:not([lang="ar"]) .about-carousel-slide h3,
html:not([lang="ar"]) .about-carousel-slide p,
html:not([lang="ar"]) .about-carousel-dots,
html:not([lang="ar"]) .about-carousel-dots .about-dot,
html:not([lang="ar"]) .news,
html:not([lang="ar"]) .news .container,
html:not([lang="ar"]) .news-header,
html:not([lang="ar"]) .news-header .text-left,
html:not([lang="ar"]) .news-header .text-left h2,
html:not([lang="ar"]) .news-header .slider-controls,
html:not([lang="ar"]) .news-slider-container,
html:not([lang="ar"]) #news-slider,
html:not([lang="ar"]) #news-slider .news-item,
html:not([lang="ar"]) #news-slider .news-item .date,
html:not([lang="ar"]) #news-slider .news-item p,
html:not([lang="ar"]) .slider-btn {
  direction: ltr !important;
  text-align: left !important;
}

/* English mode mobile gallery - ensure proper LTR behavior */
@media (max-width: 639px) {
  html:not([lang="ar"]) .news-gallery-mobile-slider {
    direction: ltr !important;
    overflow: hidden !important;
    width: 100% !important;
  }

  html:not([lang="ar"]) .news-gallery-mobile-track {
    direction: ltr !important;
    display: flex !important;
  }

  html:not([lang="ar"]) .news-gallery-mobile-slide {
    direction: ltr !important;
    flex: 0 0 100% !important;
    min-width: 100% !important;
  }

  html:not([lang="ar"]) .news-gallery-mobile-slide .branch-content {
    direction: ltr !important;
    text-align: left !important;
  }

  html:not([lang="ar"]) .news-gallery-mobile-slide .branch-content h3 {
    direction: ltr !important;
    text-align: left !important;
  }

  html:not([lang="ar"])
    .news-gallery-mobile-slide
    .branch-content
    .branch-date {
    direction: ltr !important;
    text-align: left !important;
  }

  html:not([lang="ar"]) .news-gallery-mobile-dots {
    direction: ltr !important;
    justify-content: center !important;
  }

  /* English mode about carousel - ensure proper LTR behavior */
  html:not([lang="ar"]) .about-carousel-wrapper {
    direction: ltr !important;
    overflow: hidden !important;
    width: 100% !important;
  }

  html:not([lang="ar"]) .about-carousel-track {
    direction: ltr !important;
    display: flex !important;
  }

  html:not([lang="ar"]) .about-carousel-slide {
    direction: ltr !important;
    flex: 0 0 100% !important;
    min-width: 100% !important;
  }

  html:not([lang="ar"]) .about-carousel-slide .absolute.bottom-0 {
    direction: ltr !important;
    text-align: left !important;
  }

  html:not([lang="ar"]) .about-carousel-slide h3 {
    direction: ltr !important;
    text-align: left !important;
  }

  html:not([lang="ar"]) .about-carousel-slide p {
    direction: ltr !important;
    text-align: left !important;
  }

  html:not([lang="ar"]) .about-carousel-dots {
    direction: ltr !important;
    justify-content: center !important;
  }

  /* English mode news section - ensure proper LTR behavior */
  html:not([lang="ar"]) .news {
    direction: ltr !important;
  }

  html:not([lang="ar"]) .news .container {
    direction: ltr !important;
  }

  html:not([lang="ar"]) .news-header {
    direction: ltr !important;
  }

  html:not([lang="ar"]) .news-header .text-left {
    direction: ltr !important;
    text-align: left !important;
  }

  html:not([lang="ar"]) .news-header .text-left h2 {
    direction: ltr !important;
    text-align: left !important;
  }

  html:not([lang="ar"]) .news-header .slider-controls {
    direction: ltr !important;
  }

  html:not([lang="ar"]) .news-slider-container {
    direction: ltr !important;
  }

  html:not([lang="ar"]) #news-slider {
    direction: ltr !important;
    display: flex !important;
  }

  html:not([lang="ar"]) #news-slider .news-item {
    direction: ltr !important;
    text-align: left !important;
    border-left: 6px solid var(--fd-green) !important;
    border-right: none !important;
  }

  html:not([lang="ar"]) #news-slider .news-item .date {
    direction: ltr !important;
    text-align: left !important;
  }

  html:not([lang="ar"]) #news-slider .news-item p {
    direction: ltr !important;
    text-align: left !important;
  }

  html:not([lang="ar"]) .slider-btn {
    transform: none !important;
  }
}

/* Footer mobile RTL — center ltr-content elements (<640px) */
@media (max-width: 639px) {
  .rtl footer .ltr-content {
    text-align: center !important;
    direction: ltr !important;
    display: block !important;
    margin: 0 auto !important;
    width: fit-content !important;
  }

  /* RTL footer - specific fixes for different ltr-content types */
  .rtl footer .ltr-content.font-mono {
    /* Registration numbers, VAT numbers, etc. */
    text-align: center !important;
    display: inline-block !important;
    margin: 0 auto !important;
  }

  .rtl footer .ltr-content a {
    /* Phone and email links */
    text-align: center !important;
    display: block !important;
    margin: 0 auto !important;
  }

  .rtl footer .ltr-content p {
    /* Contact information paragraphs */
    text-align: center !important;
    margin: 0 auto !important;
  }

  /* RTL footer copyright section - center on mobile */
  .rtl footer .order-2.lg\\:order-1 {
    text-align: center !important;
  }

  .rtl footer .order-2.lg\\:order-1 .ltr-content {
    text-align: center !important;
    display: block !important;
    margin: 0 auto !important;
  }

  /* RTL footer payment section - center MADA logo */
  .rtl footer .ltr-content:has(span[text="MADA"]) {
    text-align: center !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
  }

  .rtl footer .ltr-content span:contains("MADA") {
    text-align: center !important;
    display: block !important;
  }
}

/* Footer desktop RTL — center ltr-content elements (≥1024px) */
@media (min-width: 1024px) {
  .rtl footer .ltr-content {
    text-align: center !important;
    direction: ltr !important;
    display: block !important;
    margin: 0 auto !important;
    width: fit-content !important;
  }

  /* RTL footer - specific fixes for different ltr-content types */
  .rtl footer .ltr-content.font-mono {
    /* Registration numbers, VAT numbers, etc. */
    text-align: center !important;
    display: inline-block !important;
    margin: 0 auto !important;
  }

  .rtl footer .ltr-content a {
    /* Phone and email links */
    text-align: center !important;
    display: block !important;
    margin: 0 auto !important;
  }

  .rtl footer .ltr-content p {
    /* Contact information paragraphs */
    text-align: center !important;
    margin: 0 auto !important;
  }

  /* RTL footer copyright section - center on desktop */
  .rtl footer .order-2.lg\\:order-1 {
    text-align: center !important;
  }

  .rtl footer .order-2.lg\\:order-1 .ltr-content {
    text-align: center !important;
    display: block !important;
    margin: 0 auto !important;
  }

  /* RTL footer payment section - center MADA logo */
  .rtl footer .ltr-content:has(span[text="MADA"]) {
    text-align: center !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
  }

  .rtl footer .ltr-content span:contains("MADA") {
    text-align: center !important;
    display: block !important;
  }
}

/* Header mobile RTL — button order and spacing (<1024px) */
@media (max-width: 1023px) {
  .rtl .action-buttons-container {
    direction: ltr !important; /* Keep container LTR for controlled layout */
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
  }

  /* RTL mobile - move menu button to left position (first in order) */
  .rtl #mobileMenuButton {
    order: 1 !important; /* First position */
  }

  /* RTL mobile - move website/profile button to right position (second in order) */
  .rtl
    .action-buttons-container
    > a[href="https://profile.familydiscount.com/"].lg:hidden {
    order: 2 !important; /* Second position */
  }

  /* RTL mobile - ensure other action buttons maintain proper order */
  .rtl .action-buttons-container > button:not(#mobileMenuButton) {
    order: 0 !important; /* Keep language/theme buttons in original position */
  }
}

/* News Section Container RTL Fixes */
.rtl .news {
  direction: rtl !important;
}

.rtl .news .container {
  direction: rtl !important;
}

/* News Slider Container RTL Fixes */
/* Keep slider container and track LTR — JS translateX mechanics assume LTR */
.rtl .news-slider-container {
  direction: ltr !important;
}

.rtl #news-slider {
  direction: ltr !important;
}

.rtl #news-slider .news-item {
  border-left: none !important;
  border-right: 6px solid var(--fd-green) !important;
  text-align: right !important;
  direction: rtl !important;
}

/* News section RTL layout (≥601px) */
@media (min-width: 601px) {
  .rtl .news-header {
    flex-direction: row !important;
    justify-content: space-between !important;
    align-items: center !important;
  }

  .rtl .news-header .text-left {
    text-align: right !important;
    width: auto !important;
    direction: rtl !important;
    order: 2;
  }

  .rtl .news-header .slider-controls {
    align-self: center !important;
    margin-top: 0 !important;
    order: 1;
  }

  /* English (LTR) Desktop Layout */
  .news-header {
    flex-direction: row !important;
    justify-content: space-between !important;
    align-items: center !important;
  }

  .news-header .text-left {
    text-align: left !important;
    width: auto !important;
    direction: ltr !important;
    order: 1;
  }

  .news-header .slider-controls {
    align-self: center !important;
    margin-top: 0 !important;
    order: 2;
  }
}

/* Responsive RTL Fixes for News Section */
@media (max-width: 992px) {
  .rtl .news-header .text-left {
    text-align: right !important;
    direction: rtl !important;
  }

  .rtl .news-item {
    border-left: none !important;
    border-right: 6px solid var(--fd-green) !important;
  }

  .rtl #news-slider .news-item {
    border-left: none !important;
    border-right: 6px solid var(--fd-green) !important;
  }
}

@media (max-width: 600px) {
  .rtl .news-header {
    flex-direction: row !important;
    justify-content: space-between !important;
    align-items: center !important;
  }

  .rtl .news-header .text-left {
    text-align: right !important;
    width: auto !important;
    direction: rtl !important;
    order: 1;
  }

  .rtl .slider-controls {
    align-self: center !important;
    margin-top: 0 !important;
    order: 2;
  }

  /* English (LTR) Mobile Layout - Both text and controls on right */
  .news-header {
    flex-direction: row !important;
    justify-content: space-between !important;
    align-items: center !important;
  }

  .news-header .text-left {
    text-align: left !important;
    width: auto !important;
    direction: ltr !important;
    order: 1;
  }

  .slider-controls {
    align-self: center !important;
    margin-top: 0 !important;
    order: 2;
  }

  .rtl .news-item {
    border-left: none !important;
    border-right: 4px solid var(--fd-green) !important;
    padding: 1rem !important;
  }

  .rtl #news-slider .news-item {
    border-left: none !important;
    border-right: 4px solid var(--fd-green) !important;
    padding: 1rem !important;
  }
}

/* 3D gallery section: RTL overrides are intentionally omitted to preserve the scroll-driven animation */
@media (max-width: 768px) {
}

@media (max-width: 480px) {
  /* RTL gallery rules removed - 3D gallery must retain original behavior */
}

/* Mobile navigation visual tweaks (<1024px) */
@media (max-width: 1023px) {
  .mobile-nav-container {
    border-top: 1px solid rgba(124, 132, 124, 0.1);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  }

  .rtl .mobile-nav-container {
    border-top: 1px solid rgba(124, 132, 124, 0.1);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  }

  .dark .mobile-nav-container,
  .dark .rtl .mobile-nav-container {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.3);
  }

  .mobile-nav-container .nav-link,
  .rtl .mobile-nav-container .nav-link {
    border-radius: 0.75rem;
  }
}


* {
  font-family: var(--font-en-primary);
  transition:
    background-color 0.3s ease,
    border-color 0.3s ease;
}

/* Enhanced Language-Specific Typography */
html[lang="ar"] * {
  font-family: var(--font-ar-primary);
}

/* Enhanced Arabic Typography */
.arabic-font {
  font-family: var(--font-ar-primary) !important;
  font-weight: var(--font-medium);
  line-height: var(--line-height-relaxed);
  letter-spacing: var(--letter-spacing-normal);
}

/* Enhanced English Typography */
.english-font {
  font-family: var(--font-en-primary) !important;
  font-weight: var(--font-normal);
  line-height: var(--line-height-normal);
  letter-spacing: var(--letter-spacing-tight);
}

/* Display Typography */
.text-display {
  font-family: var(--font-en-display);
  font-weight: var(--font-bold);
  line-height: var(--line-height-tight);
  letter-spacing: var(--letter-spacing-tight);
}

html[lang="ar"] .text-display {
  font-family: var(--font-ar-display);
  font-weight: var(--font-extrabold);
  line-height: var(--line-height-tight);
  letter-spacing: var(--letter-spacing-normal);
}

/* Monospace Typography */
.text-mono {
  font-family: var(--font-mono);
  font-weight: var(--font-normal);
  letter-spacing: var(--letter-spacing-wide);
}

/* Enhanced Typography Scale */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-en-display);
  font-weight: var(--font-bold);
  line-height: var(--line-height-tight);
  letter-spacing: var(--letter-spacing-tight);
  margin-bottom: 0.5em;
}

html[lang="ar"] h1,
html[lang="ar"] h2,
html[lang="ar"] h3,
html[lang="ar"] h4,
html[lang="ar"] h5,
html[lang="ar"] h6 {
  font-family: var(--font-ar-display);
  font-weight: var(--font-extrabold);
  line-height: var(--line-height-tight);
  letter-spacing: var(--letter-spacing-normal);
}

/* Specific Heading Sizes */
h1 {
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: var(--font-extrabold);
}

html[lang="ar"] h1 {
  font-weight: var(--font-black);
}

h2 {
  font-size: clamp(1.5rem, 4vw, 2.5rem);
  font-weight: var(--font-bold);
}

html[lang="ar"] h2 {
  font-weight: var(--font-extrabold);
}

h3 {
  font-size: clamp(1.25rem, 3vw, 1.875rem);
  font-weight: var(--font-semibold);
}

html[lang="ar"] h3 {
  font-weight: var(--font-bold);
}

/* Body Text Enhancement */
p,
span,
div {
  font-family: var(--font-en-primary);
  font-weight: var(--font-normal);
  line-height: var(--line-height-normal);
  letter-spacing: var(--letter-spacing-normal);
}

html[lang="ar"] p,
html[lang="ar"] span,
html[lang="ar"] div {
  font-family: var(--font-ar-primary);
  font-weight: var(--font-normal);
  line-height: var(--line-height-relaxed);
  letter-spacing: var(--letter-spacing-normal);
}

/* Enhanced Readability */
.text-body {
  font-size: clamp(0.875rem, 2vw, 1rem);
  line-height: var(--line-height-relaxed);
  font-weight: var(--font-normal);
}

html[lang="ar"] .text-body {
  font-weight: var(--font-medium);
  line-height: var(--line-height-relaxed);
}

/* Small Text */
.text-small {
  font-size: clamp(0.75rem, 1.5vw, 0.875rem);
  line-height: var(--line-height-normal);
  font-weight: var(--font-normal);
}

html[lang="ar"] .text-small {
  font-weight: var(--font-medium);
}

/* Navigation Typography */
.nav-link {
  font-family: var(--font-en-primary);
  font-weight: var(--font-medium);
  letter-spacing: var(--letter-spacing-tight);
  text-decoration: none;
  transition: all 0.3s ease;
}

html[lang="ar"] .nav-link {
  font-family: var(--font-ar-primary);
  font-weight: var(--font-semibold);
  letter-spacing: var(--letter-spacing-normal);
}

/* Button Typography */
.btn,
button {
  font-family: var(--font-en-primary);
  font-weight: var(--font-medium);
  letter-spacing: var(--letter-spacing-tight);
  text-decoration: none;
  transition: all 0.3s ease;
}

html[lang="ar"] .btn,
html[lang="ar"] button {
  font-family: var(--font-ar-primary);
  font-weight: var(--font-semibold);
  letter-spacing: var(--letter-spacing-normal);
}

/* ── Dark mode: content sections ────────────────────────────────────────────
   Sections that use plain Tailwind classes (text-gray-900, text-gray-700,
   text-gray-600) without dark: prefixes get overrides here so dark mode
   looks polished without editing every element in HTML. */
.dark section .text-gray-900 {
  color: #f1f5f9;
}
.dark section h2,
.dark section h3 {
  color: #f1f5f9;
}
.dark section p,
.dark section .text-gray-700 {
  color: #cbd5e1;
}
.dark section .text-gray-600 {
  color: #94a3b8;
}
.dark .prose p {
  color: #cbd5e1;
}
.dark .highlight-item .text-gray-600 {
  color: #94a3b8;
}
.dark .brand-item {
  background: rgba(30, 41, 59, 0.8);
  border-color: rgba(255, 255, 255, 0.1);
}

/* Hero Typography Enhancement */
.hero h1 {
  font-family: var(--font-en-display);
  font-weight: var(--font-extrabold);
  line-height: var(--line-height-tight);
  letter-spacing: var(--letter-spacing-tight);
  color: var(--fd-white);
}

html[lang="ar"] .hero h1 {
  font-family: var(--font-ar-display);
  font-weight: var(--font-black);
  line-height: var(--line-height-tight);
  letter-spacing: var(--letter-spacing-normal);
}

.hero p {
  font-family: var(--font-en-primary);
  font-weight: var(--font-normal);
  line-height: var(--line-height-relaxed);
  letter-spacing: var(--letter-spacing-normal);
  color: var(--fd-white);
}

html[lang="ar"] .hero p {
  font-family: var(--font-ar-primary);
  font-weight: var(--font-medium);
  line-height: var(--line-height-relaxed);
  letter-spacing: var(--letter-spacing-normal);
}

/* Hero section */
.hero {
  position: relative;
  height: 220vh;
  max-height: 1800px;
  overflow: hidden;
  background-color: var(--fd-dark);
}

.hero-video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
  filter: brightness(0.85) contrast(1.1);
  transform: scale(1.05);
}

.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    135deg,
    rgba(27, 33, 71, 0.2) 0%,
    rgba(27, 33, 71, 0.4) 50%,
    rgba(27, 33, 71, 0.3) 100%
  );
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  height: 100%;
  width: 100%;
  padding: 80px 60px;
  color: var(--fd-white);
}

/* Hero content alignment — mirror padding so Arabic content hugs the right edge */
@media (min-width: 1024px) {
  html[lang="en"] .hero-content {
    align-items: flex-start;
    text-align: left;
    padding-left: 100px;
    padding-right: 60px;
  }

  html[lang="ar"] .hero-content {
    align-items: flex-end;
    text-align: right;
    padding-left: 60px;
    padding-right: 100px;
  }
}

/* Hero Text Container */
.hero-text {
  margin-bottom: 24px;
  width: 100%;
  max-width: 600px;
}

/* Hero text margin — push text to the correct side per language */
@media (min-width: 1024px) {
  html[lang="en"] .hero-text {
    margin-right: auto;
    margin-left: 0;
  }

  html[lang="ar"] .hero-text {
    margin-left: auto;
    margin-right: 0;
  }
}

/* Hero Title */
.hero-title {
  font-size: 3.4rem;
  font-weight: 700;
  max-width: 600px;
  margin-bottom: 24px;
  color: var(--fd-white);
  line-height: 1.05;
  letter-spacing: -0.03em;
  font-family:
    "Inter",
    system-ui,
    -apple-system,
    sans-serif;
}

.light .hero-title {
  color: var(--fd-white);
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.dark .hero-title {
  color: var(--fd-white);
}

/* Hero Subtitle */
.hero-subtitle {
  font-size: 1.25rem;
  font-weight: 400;
  max-width: 580px;
  margin: 0 auto;
  opacity: 0.9;
  line-height: 1.6;
}

.light .hero-subtitle {
  color: var(--fd-white);
  opacity: 0.85;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.2);
}

.dark .hero-subtitle {
  color: var(--fd-white);
  opacity: 0.9;
}

/* DESKTOP HERO SUBTITLE ALIGNMENT */
@media (min-width: 1024px) {
  html[lang="en"] .hero-subtitle {
    margin-right: auto;
    margin-left: 0;
    text-align: left;
  }

  html[lang="ar"] .hero-subtitle {
    margin-left: auto;
    margin-right: 0;
    text-align: right;
  }
}

/* Hero Actions Container */
.hero-actions {
  display: flex;
  gap: 16px;
  margin-top: 0px;
  flex-wrap: wrap;
  width: 100%;
  max-width: 400px;
  transition: transform 0.3s ease;
}

/* Hero actions desktop (≥1024px): mirror position and hover direction per language */
@media (min-width: 1024px) {
  html[lang="en"] .hero-actions {
    justify-content: flex-start;
    margin-left: 0;
    margin-right: auto;
  }

  html[lang="en"] .hero-actions:hover {
    transform: translateX(8px);
  }

  html[lang="ar"] .hero-actions {
    justify-content: flex-end;
    margin-left: auto;
    margin-right: 0;
    padding-right: 0;
    padding-left: 200px;
  }

  html[lang="ar"] .hero-actions:hover {
    transform: translateX(-8px);
  }
}

/* Arabic hero button: reset side-margins on mobile so it aligns to the start */
@media (max-width: 767px) {
  html[lang="ar"] .hero-actions {
    justify-content: flex-start !important;
    align-items: flex-start !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
  }
}

/* Hero content responsive padding */
@media (min-width: 768px) and (max-width: 1023px) {
  .hero-content {
    padding: 60px 40px 80px;
  }

  html[lang="en"] .hero-content {
    padding-left: 40px;
    padding-right: 30px;
  }

  html[lang="ar"] .hero-content {
    padding-left: 30px;
    padding-right: 40px;
  }

  .hero-actions {
    max-width: 350px;
    gap: 14px;
  }
}

@media (min-width: 480px) and (max-width: 767px) {
  .hero-content {
    padding: 40px 24px 60px;
  }

  html[lang="en"] .hero-content {
    padding-left: 24px;
    padding-right: 20px;
  }

  html[lang="ar"] .hero-content {
    padding-left: 20px;
    padding-right: 24px;
  }

  .hero-actions {
    max-width: 100%;
    gap: 12px;
    flex-direction: column;
    align-items: stretch;
  }

  /* Mobile - Center buttons but maintain language-specific text alignment */
  html[lang="en"] .hero-actions {
    justify-content: center;
    align-items: center;
  }

  html[lang="ar"] .hero-actions {
    justify-content: center;
    align-items: center;
  }

  /* Mobile hover effects */
  html[lang="en"] .hero-actions:hover,
  html[lang="ar"] .hero-actions:hover {
    transform: none;
  }
}

@media (max-width: 479px) {
  .hero-content {
    padding: 30px 16px 50px;
  }

  html[lang="en"] .hero-content {
    padding-left: 16px;
    padding-right: 12px;
  }

  html[lang="ar"] .hero-content {
    padding-left: 12px;
    padding-right: 16px;
  }

  .hero-actions {
    gap: 10px;
  }
}

/* Hero CTA button */
.btn-primary {
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 50px;
  padding: 16px 32px;
  font-size: 16px;
  font-weight: 500;
  color: #ffffff;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  transition: all 0.2s ease;
  position: relative;
  overflow: hidden;
  min-height: 52px;
}

html[lang="ar"] .btn-primary {
  direction: rtl;
}

.btn-primary:hover {
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(25px);
  -webkit-backdrop-filter: blur(25px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
}

.arrow-icon {
  color: #ffffff;
  padding: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.btn-primary:hover .arrow-icon {
  background: rgba(255, 255, 255, 0.95);
  color: var(--fd-green);
}

html[lang="en"] .btn-primary:hover .arrow-icon {
  transform: translateX(2px);
}

html[lang="ar"] .btn-primary:hover .arrow-icon {
  transform: translateX(-2px);
}

.hero-text {
  margin-bottom: 24px;
  width: 100%;
  max-width: 600px;
}

/* English (LTR) - Text on Left */
html[lang="en"] .hero-text {
  text-align: left;
  margin-left: 0;
  margin-right: auto;
}

/* Arabic (RTL) - Text on Right */
html[lang="ar"] .hero-text {
  text-align: right;
  margin-left: auto;
  margin-right: 0;
  direction: rtl;
}

/* Dark mode specific font optimizations */
.dark body {
  font-weight: 400; /* Slightly bolder for better contrast */
  letter-spacing: 0.01em; /* Minimal letter spacing for clarity */
}

/* Dark mode heading enhancements */
.dark h1,
.dark h2,
.dark h3,
.dark h4,
.dark h5,
.dark h6 {
  font-weight: 600; /* Reduced weight for softer appearance */
  letter-spacing: 0.02em; /* Slightly increased spacing */
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1); /* Subtle shadow for depth */
}

.dark h1 {
  font-weight: 700; /* Keep h1 bold */
  letter-spacing: -0.02em; /* Tighter spacing for large text */
}

.dark h2 {
  font-weight: 600;
  letter-spacing: -0.01em;
}

/* Dark mode paragraph and text optimizations */
.dark p,
.dark .text-content,
.dark .description {
  font-weight: 400;
  line-height: 1.65; /* Increased line height for readability */
  color: rgba(241, 245, 249, 0.95); /* Slightly reduced opacity for comfort */
}

/* Dark mode small text optimizations */
.dark small,
.dark .text-sm,
.dark .caption,
.dark .meta {
  font-weight: 500; /* Slightly bolder for small text */
  color: rgba(203, 213, 225, 0.9); /* Better contrast for small text */
}

/* Dark mode link enhancements */
.dark a {
  font-weight: 500;
  text-decoration: none;
  transition: all 0.2s ease;
}

.dark a:hover {
  font-weight: 600;
}

/* Dark mode button text optimizations */
.dark button,
.dark .btn {
  font-weight: 600;
  letter-spacing: 0.01em;
}

/* Dark mode navigation text */
.dark nav a,
.dark .nav-link {
  font-weight: 500;
  letter-spacing: 0.01em;
}

/* Dark mode card text */
.dark .card-title,
.dark .card-header {
  font-weight: 600;
  letter-spacing: 0.01em;
}

.dark .card-text,
.dark .card-content {
  font-weight: 400;
  line-height: 1.6;
}

/* Dark mode hero section specific fonts */
.dark .hero-title {
  font-weight: 800;
  letter-spacing: -0.03em;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.dark .hero-subtitle {
  font-weight: 400;
  letter-spacing: 0.02em;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

/* Dark mode brand section fonts */
.dark .brand-item {
  font-weight: 500;
}

/* Dark mode news section fonts */
.dark .news-title {
  font-weight: 600;
  letter-spacing: 0.01em;
}

.dark .news-date {
  font-weight: 400;
  color: rgba(148, 163, 184, 0.8);
}

/* Dark mode footer fonts */
.dark footer {
  font-weight: 400;
}

.dark .footer-link {
  font-weight: 400;
  color: rgba(203, 213, 225, 0.9);
}

.dark .footer-link:hover {
  font-weight: 500;
  color: var(--fd-white);
}

/* Dark mode input and form elements */
.dark input,
.dark textarea,
.dark select {
  font-weight: 400;
  letter-spacing: 0.01em;
}

/* Dark mode quote and emphasis */
.dark blockquote {
  font-weight: 400;
  font-style: italic;
  color: rgba(241, 245, 249, 0.9);
}

.dark em,
.dark .emphasis {
  font-weight: 500;
}

/* Dark mode code and pre */
.dark code,
.dark pre {
  font-weight: var(--font-normal);
  font-family: var(--font-mono);
  background: rgba(30, 41, 59, 0.5);
}

/* Dark mode list items */
.dark li,
.dark .list-item {
  font-weight: 400;
  line-height: 1.6;
}

/* Dark mode badge and tag text */
.dark .badge,
.dark .tag {
  font-weight: 600;
  letter-spacing: 0.02em;
}

/* Dark mode table text */
.dark table {
  font-weight: 400;
}

.dark th {
  font-weight: 600;
  letter-spacing: 0.01em;
}

.dark td {
  font-weight: 400;
}

/* Dark mode alert and notification text */
.dark .alert,
.dark .notification {
  font-weight: 500;
}

/* Dark mode modal text */
.dark .modal-title {
  font-weight: 600;
  letter-spacing: 0.01em;
}

.dark .modal-content {
  font-weight: 400;
  line-height: 1.6;
}

body {
  background-color: var(--background);
  color: var(--text-primary);
  overflow-x: hidden;
  max-width: 100vw;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes slideUp {
  from {
    transform: translateY(20px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

@keyframes scale {
  from {
    transform: scale(0.95);
  }
  to {
    transform: scale(1);
  }
}

@keyframes pulseGlow {
  0%,
  100% {
    box-shadow: 0 0 20px rgba(122, 193, 67, 0.3);
  }
  50% {
    box-shadow: 0 0 30px rgba(122, 193, 67, 0.6);
  }
}

/* Custom scrollbar */
::-webkit-scrollbar {
  width: 10px;
}

::-webkit-scrollbar-track {
  background: var(--border-light);
}

::-webkit-scrollbar-thumb {
  background: var(--fd-green);
  border-radius: 5px;
}

.dark ::-webkit-scrollbar-thumb {
  background: var(--fd-green);
}

/* Image modal styles */
.image-modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.9);
  z-index: 1000;
  animation: fadeIn 0.3s ease-out;
}

.modal-content {
  max-width: 90%;
  max-height: 90%;
  animation: scale 0.3s ease-out;
}

.modal-open {
  overflow: hidden;
}

/* Theme transition */
.theme-transition {
  transition:
    background-color 0.3s ease,
    color 0.3s ease;
}

/* Card styles with CSS variables */
.card {
  background-color: var(--card-bg);
  border: 1px solid var(--border);
  box-shadow: 0 4px 6px var(--card-shadow);
}

.card-hover:hover {
  transform: translateY(-5px);
  box-shadow: 0 20px 25px -5px var(--card-shadow);
}

/* Gradient backgrounds */
.gradient-bg {
  background: linear-gradient(135deg, var(--fd-green) 0%, var(--fd-navy) 100%);
}

.gradient-text {
  background: linear-gradient(135deg, var(--fd-green), var(--fd-taupe));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* Hide scrollbar for modal */
.no-scrollbar {
  -ms-overflow-style: none;
  scrollbar-width: none;
}
.no-scrollbar::-webkit-scrollbar {
  display: none;
}

/* === ENHANCED HERO (clean layout with minimal animations) === */
.hero {
  position: relative;
  height: 220vh;
  max-height: 1800px;
  overflow: hidden;
  background-color: var(--fd-dark);
}
.hero-video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
  filter: brightness(0.85) contrast(1.1);
  transform: scale(1.05);
}
.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    135deg,
    rgba(27, 33, 71, 0.2) 0%,
    rgba(27, 33, 71, 0.4) 50%,
    rgba(27, 33, 71, 0.3) 100%
  );
  z-index: 1;
}
/* REMOVED - Using comprehensive RTL/LTR fixes above */
.hero-text {
  margin-bottom: 4px;
  width: 100%;
  max-width: 600px;
}

.hero-title {
  font-size: clamp(2.5rem, 5vw, 4.5rem);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin-bottom: 1.5rem;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
  font-family:
    "Inter",
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    Roboto,
    sans-serif;
}

.light .hero-title {
  color: var(--fd-white);
  text-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}

.dark .hero-title {
  color: var(--fd-white);
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
  font-weight: 800;
  letter-spacing: -0.03em;
}

.hero-subtitle {
  font-size: clamp(1.1rem, 2vw, 1.4rem);
  font-weight: 400;
  line-height: 1.6;
  max-width: 700px;
  margin: 0 auto 2rem;
  opacity: 0.95;
  font-family:
    "Inter",
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    Roboto,
    sans-serif;
}

.light .hero-subtitle {
  color: var(--fd-white);
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
  opacity: 0.9;
}

.dark .hero-subtitle {
  color: var(--fd-white);
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.4);
  font-weight: 400;
  letter-spacing: 0.01em;
}

/* REMOVED - Using comprehensive RTL/LTR fixes above */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 2rem;
  font-size: 1rem;
  font-weight: 600;
  text-decoration: none;
  border-radius: 50px;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
  white-space: nowrap;
}

.btn-primary {
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: var(--fd-white);
  position: relative;
  overflow: hidden;
  transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
  box-shadow:
    0 8px 32px rgba(31, 38, 135, 0.12),
    0 4px 8px rgba(31, 38, 135, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    inset 0 -1px 0 rgba(122, 193, 67, 0.15);
}

/* RTL Button Content Direction */
html[lang="ar"] .btn-primary {
  direction: rtl;
}

.btn-primary::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 0%;
  height: 100%;
  background: linear-gradient(90deg, var(--fd-green), rgba(122, 193, 67, 0.8));
  transition: width 0.6s cubic-bezier(0.23, 1, 0.32, 1);
  z-index: -1;
  border-radius: 50px;
}

/* RTL Button Background Animation - REVERSE direction */
html[lang="ar"] .btn-primary::before {
  right: 0;
  left: auto;
  background: linear-gradient(
    270deg,
    /* Reverse gradient direction for RTL */ var(--fd-green),
    rgba(122, 193, 67, 0.8)
  );
}

/* Button Hover Effects - IDENTICAL visual behavior */
.btn-primary:hover {
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(25px);
  -webkit-backdrop-filter: blur(25px);
  border: 1px solid rgba(122, 193, 67, 0.25);
  transform: translateY(-3px) scale(1.02);
  box-shadow:
    0 12px 40px rgba(122, 193, 67, 0.18),
    0 6px 16px rgba(122, 193, 67, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.12),
    inset 0 -1px 0 rgba(122, 193, 67, 0.25);
}

.btn-primary:hover::before {
  width: 100%;
}

/* Arrow Icon Styling - IDENTICAL for both languages */
.btn-primary .arrow-icon {
  color: #ffffff;
  padding: 10px;
  border-radius: 50%;
  margin: 0; /* Remove margin, use gap instead */
  transition: all 0.3s ease;
  z-index: 2;
  position: relative;
  font-weight: 300;
  background: transparent;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  flex-shrink: 0;
}

.btn-primary:hover .arrow-icon {
  background: rgba(255, 255, 255, 0.95);
  color: var(--fd-green);
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.15);
}

/* English Arrow Animation - Move Right */
html[lang="en"] .btn-primary:hover .arrow-icon {
  transform: translateX(2px);
}

/* Arabic Arrow Animation - Move Left (MIRROR) */
html[lang="ar"] .btn-primary:hover .arrow-icon {
  transform: translateX(-2px);
}

/* Secondary Button */
.btn-secondary {
  background-color: transparent;
  color: var(--fd-white);
  border-color: var(--fd-white);
}

.btn-secondary:hover {
  background-color: var(--fd-white);
  color: var(--fd-navy);
}

/* Mobile-specific button text visibility - hide all by default, then show appropriate text */
.btn-primary .desktop-text,
.btn-primary .mobile-text {
  display: none !important;
}

/* Desktop - show desktop text only */
@media (min-width: 769px) {
  .btn-primary .desktop-text {
    display: block !important;
  }

  .btn-primary .mobile-text {
    display: none !important;
  }
}

/* Mobile - show mobile text only */
@media (max-width: 768px) {
  .btn-primary .desktop-text {
    display: none !important;
  }

  .btn-primary .mobile-text {
    display: block !important;
  }
}

/* Responsive fixes */
@media (max-width: 1200px) {
  .hero-title {
    font-size: clamp(2.2rem, 4.5vw, 3.8rem);
  }

  .hero-subtitle {
    font-size: clamp(1rem, 1.8vw, 1.2rem);
  }

  .btn {
    padding: 0.875rem 1.75rem;
    font-size: 0.95rem;
    min-height: 48px;
  }
}

@media (max-width: 992px) {
  .hero-title {
    font-size: clamp(2rem, 4vw, 3.2rem);
    margin-bottom: 1.25rem;
  }

  .hero-subtitle {
    font-size: clamp(0.95rem, 1.6vw, 1.1rem);
    margin-bottom: 1.75rem;
  }

  .hero-actions {
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
    margin-top: 2rem;
  }

  /* Language-specific mobile alignment */
  html[lang="en"] .hero-actions {
    align-items: flex-start;
  }

  html[lang="ar"] .hero-actions {
    align-items: flex-end;
  }

  .btn {
    width: 100%;
    max-width: 280px;
    justify-content: center;
    padding: 1rem 1.5rem;
    font-size: 1rem;
    min-height: 52px;
  }

  .btn-primary .arrow-icon {
    width: 28px;
    height: 28px;
    padding: 6px;
  }
}

@media (max-width: 768px) {
  .hero-content {
    padding: 0 16px 80px;
  }

  .hero-title {
    font-size: clamp(1.75rem, 5vw, 2.5rem);
    line-height: 1.2;
    margin-bottom: 1rem;
  }

  .hero-subtitle {
    font-size: clamp(0.9rem, 2.5vw, 1rem);
    line-height: 1.5;
    margin-bottom: 1.5rem;
  }

  .hero-actions {
    gap: 0.875rem;
    margin-top: 1.75rem;
  }

  /* Language-specific mobile alignment for 768px breakpoint */
  html[lang="en"] .hero-actions {
    align-items: flex-start;
  }

  html[lang="ar"] .hero-actions {
    align-items: flex-end;
  }

  .btn {
    padding: 0.875rem 1.25rem;
    font-size: 0.9rem;
    min-height: 48px;
    max-width: 240px;
  }

  .btn-primary .arrow-icon {
    width: 24px;
    height: 24px;
    padding: 4px;
  }
}

@media (max-width: 480px) {
  .hero-title {
    font-size: clamp(1.5rem, 6vw, 2rem);
    margin-bottom: 0.875rem;
  }

  .hero-subtitle {
    font-size: clamp(0.85rem, 3vw, 0.9rem);
    margin-bottom: 1.25rem;
  }

  .hero-actions {
    gap: 0.75rem;
    margin-top: 1.5rem;
  }

  /* Language-specific mobile alignment for 480px breakpoint */
  html[lang="en"] .hero-actions {
    align-items: flex-start;
  }

  html[lang="ar"] .hero-actions {
    align-items: flex-end;
  }

  .btn {
    padding: 0.75rem 1rem;
    font-size: 0.875rem;
    min-height: 44px;
    max-width: 200px;
  }

  .btn-primary .arrow-icon {
    width: 20px;
    height: 20px;
    padding: 3px;
  }
}
.btn-secondary {
  background-color: transparent;
  color: var(--fd-white);
  border-color: var(--fd-white);
}
.btn-secondary:hover {
  background-color: var(--fd-white);
  color: var(--fd-navy);
}
.hero-stats {
  display: flex;
  gap: 60px;
  flex-wrap: wrap;
  justify-content: center;
}
.stat-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}
.stat-number {
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--fd-green);
  margin-bottom: 8px;
}
.stat-label {
  font-size: 0.9rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 1px;
  opacity: 0.9;
}
.scroll-indicator {
  position: absolute;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 3;
  cursor: pointer;
  animation: upDown 2s ease-in-out infinite;
}
.scroll-indicator i {
  font-size: 1.5rem;
  color: var(--fd-white);
  opacity: 0.7;
}
.light .scroll-indicator i {
  opacity: 0.6;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}
.dark .scroll-indicator i {
  opacity: 0.7;
}
.scroll-indicator:hover i {
  opacity: 1;
}

@keyframes upDown {
  0%,
  100% {
    transform: translateX(-50%) translateY(0);
  }
  50% {
    transform: translateX(-50%) translateY(-10px);
  }
}

/* Hero Video Styles */
.hero-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

@media screen and (max-width: 1024px) {
  .hero-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
  }

  #hero-video {
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    aspect-ratio: 5 / 4;
  }
}

@media screen and (max-width: 767px) {
  .hero-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
  }

  #hero-video {
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    aspect-ratio: 4 / 5;
  }
}

/* Enhanced animations inspired by alfuttaim */
.hero-block-section {
  animation: fadeIn 1s ease-out;
}

.hero-media-container {
  position: relative;
  overflow: hidden;
}

.video-container {
  position: relative;
  overflow: hidden;
  border-radius: 1rem;
}

/* Hardware acceleration for smooth animations */
.hero-video,
.hero-media-container,
.video-container {
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
  transform: translateZ(0);
  will-change: transform;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Al-Futtaim Elementor button styling */
.elementor-button {
  background-color: #ffffff;
  border: none;
  border-radius: 3px;
  padding: 12px 24px;
  font-size: 13px;
  font-weight: 500;
  color: #1a1a1a;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  cursor: pointer;
  font-family: inherit;
  line-height: 1.4;
}

.elementor-button:hover {
  background-color: #f5f5f5;
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.elementor-button.elementor-size-sm {
  padding: 10px 20px;
  font-size: 12px;
}

.elementor-button-wrapper {
  display: inline-block;
}

.elementor-button-content-wrapper {
  display: flex;
  align-items: center;
  gap: 8px;
}

.elementor-button-icon {
  display: flex;
  align-items: center;
}

.elementor-button-text {
  font-weight: 500;
}

/* Responsive video aspect ratios */
@media screen and (max-width: 1024px) {
  .hero-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
  }

  #hero-video {
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    aspect-ratio: 5 / 4;
  }
}

@media screen and (max-width: 767px) {
  .hero-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
  }

  #hero-video {
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    aspect-ratio: 4 / 5;
  }

  .hero-content h1 {
    font-size: 1.75rem;
  }

  .hero-content p {
    font-size: 0.95rem;
  }
}

/* Enhanced hover effects */
.card-hover {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.card-hover:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: 0 25px 50px -12px var(--card-shadow);
}

/* Loading animation */
@keyframes shimmer {
  0% {
    background-position: -1000px 0;
  }
  100% {
    background-position: 1000px 0;
  }
}

.shimmer {
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.1),
    transparent
  );
  background-size: 1000px 100%;
  animation: shimmer 2s infinite;
}

/* Loading states for lazy loading */
.loading {
  opacity: 0.6;
  filter: blur(2px);
  transition: all 0.3s ease;
}

.loaded {
  opacity: 1;
  filter: blur(0);
  transition: all 0.3s ease;
}

/* Enhanced mobile responsiveness */
@media screen and (max-width: 768px) {
  .hero-video {
    transform: scale(1.05);
  }

  /* Move branch4 image up below hero section on mobile */
  #about .grid.grid-cols-1.lg\:grid-cols-2 {
    display: flex !important;
    flex-direction: column !important;
  }

  #about .grid.grid-cols-1.lg\:grid-cols-2 > div:nth-child(2) {
    order: -1 !important;
    margin-bottom: 2rem !important;
  }

  #about .grid.grid-cols-1.lg\:grid-cols-2 > div:first-child {
    order: 1 !important;
  }

  .card-hover:hover {
    transform: translateY(-4px) scale(1.01);
  }

  .category-card {
    transition: all 0.3s ease;
  }

  .stats-container {
    text-align: center;
  }
}

/* Touch interactions for mobile */
@media (hover: none) and (pointer: coarse) {
  .category-card:active,
  .card-hover:active {
    transform: scale(0.98);
    transition: transform 0.1s ease;
  }

  .category-card:hover,
  .card-hover:hover {
    transform: none;
  }
}

/* Enhanced accessibility */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Focus indicators */
*:focus-visible {
  outline: 2px solid var(--fd-green);
  outline-offset: 2px;
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
  .card {
    border: 2px solid var(--text-primary);
  }

  .gradient-text {
    -webkit-text-fill-color: var(--text-primary);
  }
}

/* Ripple effect for buttons */
.ripple {
  position: absolute;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.6);
  transform: scale(0);
  animation: ripple-animation 0.6s ease-out;
  pointer-events: none;
}

@keyframes ripple-animation {
  to {
    transform: scale(4);
    opacity: 0;
  }
}

/* Enhanced button styles */
button,
.btn {
  position: relative;
  overflow: hidden;
}

/* Scroll progress bar */
#scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  background: var(--fd-green);
  z-index: 9999;
  transition: width 0.2s ease;
}

/* === RESPONSIVE === */
@media (max-width: 992px) {
  .hero-title {
    font-size: 2.5rem;
  }
  .hero-subtitle {
    font-size: 1.1rem;
  }
  .hero-actions {
    flex-direction: column;
    align-items: flex-start;
    gap: 15px;
  }

  /* Language-specific mobile alignment for 992px breakpoint */
  html[lang="en"] .hero-actions {
    align-items: flex-start;
  }

  html[lang="ar"] .hero-actions {
    align-items: flex-end;
  }
  .btn {
    width: 100%;
    max-width: 250px;
  }
}
@media (max-width: 600px) {
  .header-container {
    gap: 8px;
  }
  .logo {
    font-size: 1.4rem;
  }
  .hero-title {
    font-size: 2.2rem;
  }
  .hero-subtitle {
    font-size: 1rem;
  }
  .hero-actions {
    gap: 12px;
  }
  .btn {
    padding: 14px 30px;
    font-size: 0.9rem;
  }
  .hero-stats {
    gap: 30px;
  }
  .stat-number {
    font-size: 1.8rem;
  }
  .stat-label {
    font-size: 0.8rem;
  }
  .highlights-grid {
    grid-template-columns: 1fr 1fr;
  }
}

/* Enhanced Mobile Header Styles */
.lg\:hidden nav {
  position: relative;
  background: linear-gradient(135deg, var(--surface) 0%, var(--surface) 100%);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
}

/* === NEWS SECTION === */
.news {
  padding: 80px 0;
  background-color: var(--surface);
  display: flex;
  justify-content: center;
  align-items: center;
}

.news .container {
  max-width: 1200px;
  width: 100%;
  margin: 0 auto;
}

.news-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 48px;
  gap: 24px;
  position: relative;
}

.news-header .text-left {
  text-align: left;
  margin-bottom: 0;
  flex: 1;
  width: 100%;
}

.news-header .text-left .w-16 {
  margin-left: 0;
  margin-right: auto;
}

.news-header h2 {
  font-size: 2.2rem;
  font-weight: 600;
  color: var(--fd-navy);
  text-align: left;
}

.news-header .slider-controls {
  position: static;
  transform: none;
  display: flex;
  gap: 12px;
  align-items: center;
  flex-shrink: 0;
  justify-content: flex-start;
}

/* Ensure proper alignment for news header */
.news-header .text-left h2 {
  text-align: left !important;
}

.news-header .text-left .w-16 {
  margin: 0 !important;
}

/* Responsive slider controls */
@media (max-width: 768px) {
  .news-header .slider-controls {
    position: static;
    transform: none;
    justify-content: center;
    margin-top: 16px;
  }

  .news-header {
    position: relative;
  }
}

@media (max-width: 480px) {
  .news-header .slider-controls {
    gap: 8px;
  }

  .slider-btn {
    width: 35px !important;
    height: 35px !important;
    font-size: 12px !important;
  }
}
.news-header h2 {
  font-size: 2.2rem;
  font-weight: 600;
  color: var(--fd-navy);
  text-align: center;
}
.view-more {
  text-decoration: none;
  font-weight: 600;
  color: var(--fd-green);
  border-bottom: 2px solid var(--fd-green);
  padding-bottom: 3px;
}
.news-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
}
.news-item {
  padding: 24px;
  background-color: var(--card-bg);
  border-left: 6px solid var(--fd-green);
  box-shadow: 0 4px 12px var(--card-shadow);
  transition:
    transform 0.2s,
    box-shadow 0.2s;
  cursor: pointer;
}
.news-item:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 24px var(--card-shadow);
}
.news-item .date {
  display: block;
  font-size: 0.8rem;
  color: var(--fd-gray);
  margin-bottom: 10px;
  font-weight: 500;
  letter-spacing: 0.3px;
}
.news-item p {
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.5;
}

/* News Slider */
.slider-controls {
  display: flex;
  gap: 12px;
  align-items: center;
  justify-content: center;
}

.slider-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 2px solid var(--fd-green);
  background: transparent;
  color: var(--fd-green);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  font-size: 14px;
}

.slider-btn:hover {
  background: var(--fd-green);
  color: white;
  transform: scale(1.1);
}

/* Desktop-specific Social Media Section Enhancements */
@media (min-width: 1024px) {
  /* Enhanced spacing and alignment for desktop Social Media block */
  footer .lg\\:col-span-1.sm\\:col-span-2 .lg\\:text-left {
    position: relative;
  }

  /* Ensure consistent visual hierarchy in desktop footer */
  footer .lg\\:col-span-1.sm\\:col-span-2 h3 {
    margin-bottom: 1.25rem;
  }

  /* Desktop social icons alignment refinement */
  footer .lg\\:col-span-1.sm\\:col-span-2 .lg\\:justify-start {
    justify-content: flex-start;
  }

  /* Desktop branches text alignment */
  footer .lg\\:col-span-1.sm\\:col-span-2 .lg\\:text-left {
    text-align: left;
  }
}

.slider-btn:disabled {
  opacity: 0.3;
  cursor: not-allowed;
  transform: none;
}

#news-slider {
  display: flex;
  transition: transform 0.5s ease;
  gap: 20px;
  padding: 10px 0;
}

#news-slider .news-item {
  flex: 0 0 calc(50% - 10px);
  min-width: 280px;
  position: relative;
  z-index: 1;
  transition: all 0.3s ease;
}

#news-slider .news-item:hover {
  z-index: 10;
  transform: translateY(-4px) scale(1.02);
}

@media (max-width: 600px) {
  #news-slider .news-item {
    flex: 0 0 calc(100% - 0px);
    min-width: 100%;
  }

  .news-slider-container {
    margin: 0;
    padding: 0;
  }

  .slider-btn {
    width: 35px;
    height: 35px;
    font-size: 12px;
  }
}

/* === BRANDS SECTION === */

/* CSS fallback for Tailwind flex/min-w-full on the brands slider */
#brands-slider {
  display: flex;
  width: 100%;
  transition: transform 0.5s ease;
}

#brands-slider > div {
  flex: 0 0 100%;
  width: 100%;
  min-width: 0;
}

.brand-item {
  background-color: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 0.75rem;
  padding: 1rem;
  text-align: center;
  position: relative;
  z-index: 1;
  transition: all 0.3s ease;
  cursor: pointer;
  min-height: 120px;
  height: 140px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.brand-item:hover {
  transform: translateY(-4px) scale(1.02);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.15);
  border-color: var(--fd-green);
  z-index: 10;
}

.brand-item img {
  height: 56px !important;
  width: auto !important;
  max-width: 100%;
  max-height: 56px !important;
  object-fit: contain;
  transition: all 0.3s ease;
}

.brand-item:hover img {
  transform: scale(1.05);
}

/* Ensure consistent card dimensions */
.brand-item::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(
    135deg,
    transparent 0%,
    rgba(122, 193, 67, 0.05) 100%
  );
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

.brand-item:hover::before {
  opacity: 1;
}

/* Special handling for logos with different aspect ratios */
.brand-item img[src*="sama"] {
  height: 60px !important;
  width: auto !important;
  max-height: 60px !important;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .brand-item {
    min-height: 100px;
    height: 120px;
    padding: 0.75rem;
  }

  .brand-item img {
    height: 48px !important;
    max-height: 48px !important;
  }

  .brand-item img[src*="sama"] {
    height: 36px !important;
    max-height: 36px !important;
  }

  /* Mobile brand grid layout: 3 rows x 3 columns */
  #brands-slider .min-w-full {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr) !important;
    grid-template-rows: repeat(3, auto) !important;
    gap: 0.75rem !important;
    padding: 0.75rem !important;
  }

  #brands-slider .min-w-full .brand-item {
    grid-column: auto !important;
    grid-row: auto !important;
  }

  /* Ensure only 9 items are visible per slide on mobile */
  #brands-slider .min-w-full .brand-item:nth-child(n + 10) {
    display: none !important;
  }
}

/* Brands slider navigation enhancements */
#brands-prev,
#brands-next {
  z-index: 20;
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: #ffffff;
}

.dark #brands-prev,
.dark #brands-next {
  background: #1f2937;
  border-color: rgba(255, 255, 255, 0.15);
}

#brands-prev:hover,
#brands-next:hover {
  transform: translateY(-50%) translateX(-50%) scale(1.1);
  border-color: var(--fd-green);
}

#brands-next:hover {
  transform: translateY(-50%) translateX(50%) scale(1.1);
}

#brands-prev:disabled,
#brands-next:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

#brands-prev:disabled {
  transform: translateY(-50%) translateX(-50%) scale(0.9);
}

#brands-next:disabled {
  transform: translateY(-50%) translateX(50%) scale(0.9);
}

@media (max-width: 480px) {
  /* Mobile brand grid layout for smaller screens */
  #brands-slider .min-w-full {
    grid-template-columns: repeat(3, 1fr) !important;
    grid-template-rows: repeat(3, auto) !important;
    gap: 0.5rem !important;
    padding: 0.5rem !important;
  }

  .brand-item {
    min-height: 85px !important;
    height: 100px !important;
    padding: 0.5rem !important;
  }

  .brand-item img {
    height: 40px !important;
    max-height: 40px !important;
  }

  .brand-item img[src*="sama"] {
    height: 32px !important;
    max-height: 32px !important;
  }

  .brand-item h3 {
    font-size: 0.75rem !important;
  }

  /* Hide navigation buttons on small mobile */
  #brands-prev,
  #brands-next {
    display: none;
  }
}

@media (max-width: 767px) {
  #brands-prev,
  #brands-next {
    display: none;
  }
}

/* Bottom dots styling */
#brands-dots {
  z-index: 10;
}

#brands-dots button {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

#brands-dots button:hover {
  transform: scale(1.2);
}

#brands-dots button:focus {
  outline: 2px solid var(--fd-green);
  outline-offset: 2px;
}

/* Brands slider dot pills — custom classes used by initializeBrandsSlider (no Tailwind dependency) */
#brands-dots .bd-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #d1d5db;
  border: none;
  padding: 0;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

#brands-dots .bd-dot.active {
  width: 32px;
  border-radius: 4px;
  background: var(--fd-green);
}

#brands-dots .bd-dot:hover {
  transform: scale(1.2);
  background: var(--fd-green);
}

.dark #brands-dots .bd-dot {
  background: rgba(226, 232, 240, 0.25);
}

.dark #brands-dots .bd-dot.active {
  background: var(--fd-green);
}

.dark #brands-dots .bd-dot:hover {
  background: var(--fd-green);
}

.brand-item h3 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
}

/* === HIGHLIGHTS (stats) - Enhanced Clean Layout === */
.highlight-item {
  padding: 2rem 1.5rem;
  border: 1px solid transparent;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  border-radius: 1rem;
  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.8) 0%,
    rgba(255, 255, 255, 0.4) 100%
  );
  backdrop-filter: blur(10px);
  position: relative;
  overflow: hidden;
}

.highlight-item::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--fd-green) 0%, var(--fd-navy) 100%);
  transform: scaleX(0);
  transition: transform 0.3s ease;
}

.highlight-item:hover::before {
  transform: scaleX(1);
}

.highlight-item:hover {
  border-color: var(--border);
  transform: translateY(-8px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.95) 0%,
    rgba(255, 255, 255, 0.6) 100%
  );
}

.highlight-item:hover .w-24 {
  transform: scale(1.05);
  box-shadow: 0 10px 30px rgba(122, 193, 67, 0.2);
  border-color: var(--fd-green);
}

.highlight-item:hover i {
  transform: scale(1.1);
}

.highlight-item .w-24 {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  z-index: 2;
}

.highlight-item i {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Enhanced responsive adjustments for highlights */
@media (max-width: 1024px) {
  .highlight-item {
    padding: 1.5rem;
  }
}

@media (max-width: 768px) {
  .highlight-item {
    padding: 1.25rem;
  }
  .highlight-item .text-4xl {
    font-size: 2.5rem;
  }
}

@media (max-width: 640px) {
  .highlight-item {
    padding: 1rem;
  }
  .highlight-item .text-4xl {
    font-size: 2.25rem;
  }
  .highlight-item .text-sm {
    font-size: 0.75rem;
  }
  .highlight-item .w-24 {
    width: 5rem;
    height: 5rem;
  }
}

/* Subtle animation for numbers on scroll */
@keyframes countUp {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.highlight-item .text-4xl {
  animation: countUp 0.6s ease-out;
}

/* Social Media Hover Colors */
.hover\:bg-instagram:hover {
  background: linear-gradient(
    45deg,
    #f09433 0%,
    #e6683c 25%,
    #dc2743 50%,
    #cc2366 75%,
    #bc1888 100%
  );
}

.hover\:bg-tiktok:hover {
  background: #000000;
}

.hover\:bg-snapchat:hover {
  background: #fffc00;
  color: #000000;
}

.hover\:bg-snapchat:hover i {
  color: #000000 !important;
}

/* Dark mode overrides */

.dark .highlight-item {
  background: linear-gradient(135deg, var(--surface) 0%, var(--card-bg) 100%);
  backdrop-filter: blur(10px);
  border-color: var(--border);
}

.dark .highlight-item:hover {
  background: linear-gradient(135deg, var(--card-bg) 0%, var(--surface) 100%);
  border-color: var(--fd-green);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.dark .highlight-item .w-24 {
  background-color: var(--surface) !important;
  border-color: var(--border) !important;
}

.dark .highlight-item:hover .w-24 {
  border-color: var(--fd-green) !important;
}

.dark .global-sourcing,
.dark .news-gallery {
  background-color: var(--surface) !important;
}

.dark .global-sourcing .bg-white,
.dark .news-gallery .bg-white {
  background-color: var(--card-bg) !important;
  border-color: var(--border) !important;
}

.dark .global-sourcing .border-gray-200,
.dark .news-gallery .border-gray-200 {
  border-color: var(--border) !important;
}

.dark .news-item {
  background-color: var(--card-bg);
  border-left-color: var(--fd-green);
  box-shadow: 0 4px 12px var(--card-shadow);
}

.dark .news-item:hover {
  box-shadow: 0 12px 24px var(--card-shadow);
}

.dark .brand-item {
  background-color: var(--card-bg);
  border-color: var(--border);
}

.dark .brand-item:hover {
  border-color: var(--fd-green);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.3);
}

.dark .footer,
.dark footer {
  background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%) !important;
}

.dark footer .bg-gradient-to-br {
  background: linear-gradient(135deg, #0f172a, #1e293b) !important;
}

.dark .social-link {
  background-color: var(--surface);
  border-color: var(--border);
}

.dark .social-link:hover {
  background-color: var(--card-bg);
  border-color: var(--fd-green);
}

.dark .branch-dialog-content {
  background-color: var(--surface);
  border-color: var(--border);
}

.dark .branch-option-btn {
  background-color: var(--card-bg);
  border-color: var(--border);
}

.dark .branch-option-btn:hover {
  border-color: var(--fd-green);
}

.dark .branch-option-title {
  color: var(--text-primary);
}

.dark .branch-option-description {
  color: var(--text-secondary);
}

.dark .mdw-image-gallery-3d {
  background-color: var(--surface);
}

.dark .gallery-card h2,
.dark .gallery-card h3 {
  color: var(--text-primary);
}

.dark .slider-nav {
  background: rgba(0, 0, 0, 0.7);
  color: white;
}

.dark .slider-nav:hover {
  background: var(--fd-green);
}

.dark .slider-dot {
  background: rgba(255, 255, 255, 0.3);
}

.dark .slider-dot.active {
  background: white;
}

/* Improve text contrast in dark mode */
.dark .text-gray-900,
.dark .text-gray-800,
.dark .text-gray-700 {
  color: var(--text-primary) !important;
}

.dark .text-gray-600,
.dark .text-gray-500 {
  color: var(--text-secondary) !important;
}

.dark .border-gray-300,
.dark .border-gray-200 {
  border-color: var(--border) !important;
}

.dark .bg-gray-50,
.dark .bg-gray-100 {
  background-color: var(--surface) !important;
}

.dark .bg-white {
  background-color: var(--card-bg) !important;
}

.dark .prose p {
  color: var(--text-secondary);
}

.dark .prose strong {
  color: var(--text-primary);
}

/* GALLERY CONTAINER – creates scroll length */
.mdw-image-gallery-3d {
  position: relative;
  width: 100%;
  background: var(--surface);
  margin: 20px 0;
  border-radius: 16px;
  height: auto;
  overflow: visible;
}

/* inner fixed panel – holds 3D cards */
.mdw-image-gallery-inner {
  position: relative;
  width: 100%;
  height: 60vh;
  transform-style: preserve-3d;
  perspective: 1000px;
  backface-visibility: hidden;
  will-change: transform;
  padding: 40px 20px;
}

/* BACKGROUND LAYER – covers gallery area only */
.mdw-image-gallery-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  opacity: 0.6;
  pointer-events: none;
  z-index: 1;
}
.mdw-image-gallery-bg img {
  position: absolute;
  left: 0;
  top: 0;
  filter: blur(50px);
  transform: scale(1.125);
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 1.5s;
  will-change: opacity;
}

/* CARD STYLES */
.gallery-card {
  position: absolute;
  left: 50%;
  top: 55%;
  transform: translate(-50%, -50%) translateZ(0px);
  width: 420px;
  text-align: center;
  will-change: transform, opacity;
  z-index: 10;
  backface-visibility: hidden;
  transition: transform 0.8s cubic-bezier(0.23, 1, 0.32, 1);
  padding: 20px;
}
.gallery-card:nth-child(even) {
  left: 30%;
}
.gallery-card:nth-child(odd) {
  left: 70%;
}
.gallery-card h2 {
  font-size: 2.25rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  color: var(--text-primary);
  line-height: 1.2;
}
.gallery-card h3 {
  font-size: 1.125rem;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  opacity: 0.8;
}
.gallery-card img {
  width: 100%;
  height: 280px;
  object-fit: cover;
  border-radius: 16px;
  display: block;
  transition: transform 0.3s ease;
}
.gallery-card:hover img {
  transform: scale(1.02);
}

/* Image Slider Styles */
.image-slider-container {
  position: relative;
  width: 100%;
  height: 280px;
  border-radius: 16px;
  overflow: visible;
  margin: 0 25px;
}

.image-slider {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.image-slider-track {
  display: flex;
  width: 100%;
  height: 100%;
  transition: transform 0.3s ease-in-out;
}

.slider-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 16px;
  flex-shrink: 0;
  display: block;
}

/* Slider navigation - Fixed z-index stacking on mobile */
.slider-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0, 0, 0, 0.7);
  color: white;
  border: none;
  border-radius: 50%;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  z-index: 15; /* Fixed z-index - prevents jumping */
  font-size: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
  /* Prevent z-index changes during animation */
  will-change: transform, background, box-shadow;
}

.slider-nav:hover {
  background: rgba(122, 193, 67, 0.9);
  transform: translateY(-50%) scale(1.1);
  box-shadow: 0 4px 12px rgba(122, 193, 67, 0.4);
  /* Keep z-index stable during hover */
  z-index: 15 !important;
}

.slider-nav-prev {
  left: -18px;
}

.slider-nav-next {
  right: -18px;
}

/* Slider dots - Fixed z-index positioning */
.slider-dots {
  position: absolute;
  bottom: 15px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  z-index: 12; /* Fixed z-index - below nav buttons */
  pointer-events: none; /* Prevent interference with slider */
}

.slider-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  border: none;
  background: rgba(255, 255, 255, 0.5);
  cursor: pointer;
  transition: all 0.3s ease;
  pointer-events: auto; /* Re-enable for dots */
  z-index: 13; /* Ensure dots are clickable */
}

.slider-dot.active {
  background: white;
  width: 24px;
  border-radius: 4px;
}

.slider-dot:hover {
  background: rgba(255, 255, 255, 0.8);
}

/* Responsive improvements for 3D gallery */
@media (max-width: 1024px) {
  .mdw-image-gallery-inner {
    height: 50vh;
    padding: 30px 15px;
  }
  .gallery-card {
    width: 360px;
    padding: 15px;
  }
  .gallery-card:nth-child(even) {
    left: 35%;
  }
  .gallery-card:nth-child(odd) {
    left: 65%;
  }
  .gallery-card h2 {
    font-size: 2rem;
  }
  .gallery-card h3 {
    font-size: 1rem;
  }
  .gallery-card img {
    height: 240px;
  }
  .image-slider-container {
    height: 240px;
  }
}

@media (max-width: 768px) {
  section[class*="pt-"][class*="pb-"] {
    padding-top: 60px;
    padding-bottom: 40px;
    margin: 40px 0 15px 0;
  }
  .mdw-image-gallery-inner {
    height: 45vh;
    padding: 20px 10px;
  }
  .gallery-card {
    width: 320px;
    padding: 12px;
  }
  .gallery-card:nth-child(even),
  .gallery-card:nth-child(odd) {
    left: 50%;
  }
  .gallery-card h2 {
    font-size: 1.75rem;
  }
  .gallery-card h3 {
    font-size: 0.875rem;
    margin-bottom: 1rem;
  }
  .gallery-card img {
    height: 200px;
  }
  .image-slider-container {
    height: 200px;
  }
}

@media (max-width: 480px) {
  .container.mx-auto.px-6 {
    padding-left: 1rem;
    padding-right: 1rem;
  }
  .gallery-card {
    width: 280px;
  }
  .gallery-card h2 {
    font-size: 1.5rem;
  }
  .gallery-card img {
    height: 180px;
  }
  .image-slider-container {
    height: 180px;
  }
}

/* sticky classes for inner panel (used by JS) */
.gallery-sticky {
  position: fixed;
  top: 0;
  z-index: 40;
}
.gallery-sticky-end {
  position: absolute;
  bottom: 0;
  top: auto !important;
}

/* LENIS SMOOTH SCROLL STYLES */
html.lenis,
html.lenis body {
  height: auto;
}
.lenis.lenis-smooth {
  scroll-behavior: auto !important;
}
.lenis.lenis-smooth [data-lenis-prevent] {
  overscroll-behavior: contain;
}
.lenis.lenis-stopped {
  overflow: hidden;
}

/* Floating Social Media Side Panel - Compact Narrow Style */
.social-side-panel {
  position: fixed;
  right: 0;
  top: 45%;
  transform: translateY(-50%);
  z-index: 1000;
  padding: 24px 0;
  transition:
    background-color 0.6s ease,
    border-color 0.6s ease;
}

.social-item {
  position: absolute;
  right: 0;
  overflow: visible;
}

.social-item:nth-child(1) {
  top: 0;
}
.social-item:nth-child(2) {
  top: 70px;
}
.social-item:nth-child(3) {
  top: 140px;
}
.social-item:nth-child(4) {
  top: 210px;
}

.social-link {
  display: flex;
  align-items: center;
  text-decoration: none;
  color: var(--text-primary);
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: 60px 0 0 60px;
  padding: 16px 18px;
  box-shadow:
    0 12px 40px rgba(0, 0, 0, 0.15),
    0 6px 20px rgba(0, 0, 0, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.15),
    inset 0 -1px 0 rgba(0, 0, 0, 0.05);
  transition:
    all 0.5s cubic-bezier(0.23, 1, 0.32, 1),
    background-color 0.6s ease,
    border-color 0.6s ease;
  position: relative;
  overflow: hidden;
  width: 54px;
  backdrop-filter: blur(25px);
  -webkit-backdrop-filter: blur(25px);
}

.social-link::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.3),
    transparent
  );
  transition: left 0.8s cubic-bezier(0.23, 1, 0.32, 1);
  z-index: 1;
}

.social-link:hover::before {
  left: 100%;
}

.social-link::after {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  background: linear-gradient(
    135deg,
    transparent 0%,
    rgba(255, 255, 255, 0.1) 50%,
    transparent 100%
  );
  opacity: 0;
  transition: opacity 0.5s ease;
  z-index: 1;
}

.social-link:hover::after {
  opacity: 1;
}

.social-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  font-size: 22px;
  flex-shrink: 0;
  transition: all 0.5s cubic-bezier(0.23, 1, 0.32, 1);
  position: relative;
  z-index: 2;
  background: linear-gradient(135deg, var(--fd-navy) 0%, #1e293b 100%);
  color: #ffffff;
  border-radius: 50%;
  padding: 6px;
  box-shadow:
    0 4px 12px rgba(27, 33, 71, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.social-label {
  white-space: nowrap;
  font-weight: 800;
  font-size: 16px;
  position: absolute;
  left: 54px;
  top: 50%;
  transform: translateY(-50%) translateX(-40px) scale(0.7);
  opacity: 0;
  transition: all 0.5s cubic-bezier(0.23, 1, 0.32, 1);
  z-index: 2;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
  pointer-events: none;
  letter-spacing: 0.5px;
}

/* Enhanced Hover Effects - Premium animations */
.social-link:hover {
  width: 180px;
  box-shadow:
    0 20px 60px rgba(0, 0, 0, 0.25),
    0 10px 30px rgba(0, 0, 0, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.25),
    inset 0 -1px 0 rgba(0, 0, 0, 0.1);
  transform: translateX(-12px) scale(1.03);
  border-color: transparent;
  z-index: 10;
}

.social-link:hover .social-icon {
  transform: rotate(360deg) scale(1.15);
  background: linear-gradient(135deg, var(--fd-navy) 0%, #334155 100%);
  box-shadow:
    0 8px 24px rgba(27, 33, 71, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.social-link:hover .social-label {
  opacity: 1;
  transform: translateY(-50%) translateX(0) scale(1);
}

/* Simple clean hover effects with brand color icon backgrounds */
.social-item:nth-child(1) .social-link:hover {
  background: var(--surface);
  color: var(--text-primary);
  border-color: var(--border);
  box-shadow:
    0 8px 24px rgba(0, 0, 0, 0.15),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.social-item:nth-child(1) .social-link:hover .social-icon {
  background: #fffc00;
  color: #000000;
  text-shadow: none;
  box-shadow: 0 4px 12px rgba(255, 252, 0, 0.3);
}

.social-item:nth-child(2) .social-link:hover {
  background: var(--surface);
  color: var(--text-primary);
  border-color: var(--border);
  box-shadow:
    0 8px 24px rgba(0, 0, 0, 0.15),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.social-item:nth-child(2) .social-link:hover .social-icon {
  background: #000000;
  color: #ffffff;
  text-shadow: none;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.social-item:nth-child(3) .social-link:hover {
  background: var(--surface);
  color: var(--text-primary);
  border-color: var(--border);
  box-shadow:
    0 8px 24px rgba(0, 0, 0, 0.15),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.social-item:nth-child(3) .social-link:hover .social-icon {
  background: linear-gradient(
    45deg,
    #f09433 0%,
    #e6683c 25%,
    #dc2743 50%,
    #cc2366 75%,
    #bc1888 100%
  );
  color: #ffffff;
  text-shadow: none;
  box-shadow: 0 4px 12px rgba(228, 64, 95, 0.3);
}

.social-item:nth-child(4) .social-link:hover {
  background: var(--surface);
  color: var(--text-primary);
  border-color: var(--border);
  box-shadow:
    0 8px 24px rgba(0, 0, 0, 0.15),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.social-item:nth-child(4) .social-link:hover .social-icon {
  background: #25d366;
  color: #ffffff;
  text-shadow: none;
  box-shadow: 0 4px 12px rgba(37, 211, 102, 0.3);
}

/* Pulse animation for icons - removed to prevent all icons from animating */

.social-link:hover .social-icon {
  animation: none;
  transform: rotate(360deg) scale(1.1);
}

/* Section-based adaptive backgrounds */
.social-panel-adaptive {
  background-color: rgba(244, 246, 243, 0.95) !important;
  border-color: rgba(229, 231, 235, 0.8) !important;
}

.social-panel-dark {
  background-color: rgba(30, 41, 59, 0.95) !important;
  border-color: rgba(51, 65, 85, 0.8) !important;
}

.social-panel-hero {
  background-color: rgba(27, 33, 71, 0.9) !important;
  border-color: rgba(122, 193, 67, 0.3) !important;
}

.social-panel-offwhite {
  background-color: rgba(244, 246, 243, 0.95) !important;
  border-color: rgba(229, 231, 235, 0.8) !important;
}

.social-panel-white {
  background-color: rgba(255, 255, 255, 0.95) !important;
  border-color: rgba(229, 231, 235, 0.8) !important;
}

.social-panel-surface {
  background-color: rgba(248, 250, 252, 0.95) !important;
  border-color: rgba(226, 232, 240, 0.8) !important;
}

/* Enhanced Dark mode support */
.dark .social-panel-adaptive {
  background-color: rgba(30, 41, 59, 0.95) !important;
  border-color: rgba(51, 65, 85, 0.8) !important;
}

.dark .social-panel-hero {
  background-color: rgba(15, 23, 42, 0.9) !important;
  border-color: rgba(122, 193, 67, 0.4) !important;
}

.dark .social-panel-offwhite {
  background-color: rgba(30, 41, 59, 0.95) !important;
  border-color: rgba(51, 65, 85, 0.8) !important;
}

.dark .social-panel-white {
  background-color: rgba(30, 41, 59, 0.95) !important;
  border-color: rgba(51, 65, 85, 0.8) !important;
}

.dark .social-panel-surface {
  background-color: rgba(30, 41, 59, 0.95) !important;
  border-color: rgba(51, 65, 85, 0.8) !important;
}

/* Enhanced RTL support - Updated for consistency with HTML inline styles */
.rtl .social-side-panel {
  right: auto;
  left: 0;
}

.rtl .social-item {
  right: auto;
  left: 0;
}

.rtl .social-link {
  border-radius: 0 60px 60px 0;
  flex-direction: row;
  justify-content: flex-start;
}

.rtl .social-link:hover {
  transform: translateX(12px) scale(1.03);
}

.rtl .social-label {
  left: auto;
  right: 54px;
  transform: translateY(-50%) translateX(40px) scale(0.7);
  text-align: right;
  direction: rtl;
}

.rtl .social-link:hover .social-label {
  transform: translateY(-50%) translateX(0) scale(1);
}

.rtl .social-link::before {
  left: auto;
  right: -100%;
}

.rtl .social-link:hover::before {
  right: 100%;
}

.rtl .social-link::after {
  right: auto;
  left: -2px;
}

/* Enhanced Mobile responsiveness */
@media (max-width: 768px) {
  .social-side-panel {
    gap: 12px;
    padding: 20px 0;
  }

  .social-link {
    padding: 12px 14px;
    max-width: 48px;
  }

  .social-icon {
    width: 26px;
    height: 26px;
    font-size: 18px;
  }

  .social-link:hover {
    max-width: 130px;
  }

  .social-label {
    font-size: 13px;
    margin-left: 10px;
    margin-right: 6px;
  }

  /* RTL mobile social bar adjustments - Updated for consistency */
  .rtl .social-side-panel {
    left: 0;
    right: auto;
  }

  .rtl .social-link {
    border-radius: 0 60px 60px 0;
    flex-direction: row;
    justify-content: flex-start;
  }

  .rtl .social-label {
    left: auto;
    right: 54px;
    margin-left: 6px;
    margin-right: 10px;
    text-align: right;
    direction: rtl;
  }
}

@media (max-width: 480px) {
  .social-side-panel {
    gap: 10px;
    padding: 16px 0;
  }

  .social-link {
    padding: 10px 12px;
    max-width: 44px;
  }

  .social-link:hover {
    max-width: 120px;
  }

  .social-icon {
    width: 24px;
    height: 24px;
    font-size: 16px;
  }

  .social-label {
    font-size: 12px;
  }

  /* RTL mobile social bar adjustments for 480px */
  .rtl .social-side-panel {
    left: 0;
    right: auto;
  }

  .rtl .social-link {
    flex-direction: row-reverse;
  }

  .rtl .social-label {
    margin-left: 6px;
    margin-right: 10px;
  }
}

/* Additional visual enhancements */
.social-link::after {
  content: "";
  position: absolute;
  top: 50%;
  right: -2px;
  width: 4px;
  height: 0;
  background: var(--fd-green);
  border-radius: 2px;
  transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
  transform: translateY(-50%);
}

.social-link:hover::after {
  height: 60%;
}

.rtl .social-link::after {
  right: auto;
  left: -2px;
}

/* Glow effect on hover */
@keyframes glow {
  0%,
  100% {
    box-shadow:
      0 16px 48px rgba(0, 0, 0, 0.2),
      0 8px 24px rgba(0, 0, 0, 0.15),
      inset 0 1px 0 rgba(255, 255, 255, 0.2);
  }
  50% {
    box-shadow:
      0 20px 60px rgba(0, 0, 0, 0.25),
      0 10px 30px rgba(0, 0, 0, 0.2),
      inset 0 1px 0 rgba(255, 255, 255, 0.3),
      0 0 20px rgba(122, 193, 67, 0.3);
  }
}

.social-link:hover {
  animation: glow 2s ease-in-out infinite;
}

/* Branch Dialog Styles */
.branch-dialog {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(4px);
  z-index: 10000;
  animation: fadeIn 0.3s ease-out;
}

.branch-dialog.active {
  display: flex;
  align-items: center;
  justify-content: center;
}

.branch-dialog-content {
  background: var(--surface);
  border-radius: 20px;
  max-width: 520px;
  width: 90%;
  max-height: 90vh;
  overflow: auto;
  box-shadow:
    0 30px 60px rgba(0, 0, 0, 0.2),
    0 15px 30px rgba(0, 0, 0, 0.15),
    0 5px 15px rgba(0, 0, 0, 0.1);
  animation: slideUp 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  border: 1px solid var(--border);
}

.branch-dialog-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 28px 32px 20px;
  border-bottom: 1px solid var(--border-light);
}

.branch-dialog-title {
  font-size: 1.625rem;
  font-weight: 700;
  color: var(--text-primary);
  margin: 0;
  letter-spacing: -0.025em;
}

.branch-dialog-close {
  background: none;
  border: none;
  font-size: 1.375rem;
  color: var(--text-secondary);
  cursor: pointer;
  padding: 10px;
  border-radius: 10px;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
}

.branch-dialog-close:hover {
  background: var(--border-light);
  color: var(--text-primary);
  transform: scale(1.05);
}

.branch-dialog-body {
  padding: 20px 32px 32px;
}

.branch-dialog-subtitle {
  color: var(--text-secondary);
  margin: 0 0 28px 0;
  font-size: 1.0625rem;
  line-height: 1.6;
  font-weight: 400;
}

.branch-dialog-options {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.branch-option-btn {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 20px;
  background: var(--card-bg);
  border: 2px solid var(--border);
  border-radius: 16px;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  text-align: left;
  width: 100%;
  position: relative;
  overflow: hidden;
}

.branch-option-btn::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(122, 193, 67, 0.05),
    transparent
  );
  transition: left 0.6s ease;
}

.branch-option-btn:hover::before {
  left: 100%;
}

.branch-option-btn:hover {
  border-color: var(--fd-green);
  transform: translateY(-3px);
  box-shadow:
    0 12px 32px rgba(122, 193, 67, 0.15),
    0 6px 16px rgba(122, 193, 67, 0.1);
}

.branch-option-btn:focus {
  outline: none;
  border-color: var(--fd-green);
  box-shadow:
    0 0 0 4px rgba(122, 193, 67, 0.1),
    0 12px 32px rgba(122, 193, 67, 0.15);
}

.branch-option-btn:active {
  transform: translateY(-1px);
}

.branch-option-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  background: var(--fd-green);
  color: white;
  border-radius: 12px;
  font-size: 1.25rem;
  flex-shrink: 0;
  box-shadow: 0 2px 8px rgba(122, 193, 67, 0.2);
  transition: all 0.2s ease;
}

.branch-option-btn:hover .branch-option-icon {
  background: var(--fd-navy);
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(27, 33, 71, 0.3);
}

.branch-option-content {
  flex: 1;
  min-width: 0;
}

.branch-option-title {
  font-size: 1.1875rem;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0 0 6px 0;
  letter-spacing: -0.025em;
  transition: color 0.2s ease;
}

.branch-option-description {
  font-size: 0.9375rem;
  color: var(--text-secondary);
  margin: 0;
  line-height: 1.5;
  transition: color 0.2s ease;
}

.branch-option-btn:hover .branch-option-title {
  color: var(--fd-green);
}

.branch-option-btn:hover .branch-option-description {
  color: var(--text-primary);
}

/* RTL Support for Dialog */
.rtl .branch-dialog-content {
  direction: rtl;
}

.rtl .branch-dialog-header {
  flex-direction: row-reverse;
}

.rtl .branch-option-btn {
  flex-direction: row-reverse;
  text-align: right;
}

/* Mobile Responsive */
@media (max-width: 640px) {
  .branch-dialog-content {
    width: 95%;
    margin: 16px;
    border-radius: 16px;
  }

  .branch-dialog-header,
  .branch-dialog-body {
    padding: 24px;
  }

  .branch-dialog-title {
    font-size: 1.375rem;
  }

  .branch-dialog-subtitle {
    font-size: 1rem;
    margin-bottom: 24px;
  }

  .branch-option-btn {
    padding: 16px;
    gap: 16px;
    border-radius: 12px;
  }

  .branch-option-icon {
    width: 44px;
    height: 44px;
    font-size: 1.125rem;
  }

  .branch-option-title {
    font-size: 1.0625rem;
  }

  .branch-option-description {
    font-size: 0.875rem;
  }

  .branch-dialog-close {
    width: 40px;
    height: 40px;
    font-size: 1.25rem;
  }
}

@media (max-width: 480px) {
  .branch-dialog-header,
  .branch-dialog-body {
    padding: 20px;
  }

  .branch-option-btn {
    padding: 14px;
    gap: 14px;
  }

  .branch-option-icon {
    width: 40px;
    height: 40px;
    font-size: 1rem;
  }
}

/* News gallery section */
.news-gallery {
  padding: 60px 0;
  background-color: var(--surface);
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
}

.news-gallery .container {
  max-width: 1200px;
  width: 100%;
  margin: 0 auto;
}

.news-gallery-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  grid-template-rows: 1fr 1fr;
  gap: 20px;
  height: 500px;
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px;
}

/* Branch Cards for News Gallery */
.branch-card {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  cursor: pointer;
  box-shadow:
    0 10px 30px rgba(0, 0, 0, 0.15),
    inset 0 1px 0 rgba(255, 255, 255, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.1);
  transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.1) 0%,
    transparent 50%,
    rgba(0, 0, 0, 0.05) 100%
  );
}

.branch-card:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow:
    0 20px 50px rgba(0, 0, 0, 0.25),
    inset 0 1px 0 rgba(255, 255, 255, 0.3);
  z-index: 10;
}

.branch-card.featured {
  grid-row: span 2;
  grid-column: 1;
}


.branch-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s cubic-bezier(0.23, 1, 0.32, 1);
}

.branch-card:hover img {
  transform: scale(1.08);
}

.branch-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    to bottom,
    rgba(0, 0, 0, 0.1) 0%,
    rgba(0, 0, 0, 0.6) 100%
  );
  transition: background 0.4s ease;
}

.branch-card:hover .branch-overlay {
  background: linear-gradient(
    to bottom,
    rgba(0, 0, 0, 0.2) 0%,
    rgba(0, 0, 0, 0.7) 100%
  );
}

.branch-content {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 24px;
  color: var(--fd-white);
  z-index: 2;
  transform: translateY(10px);
  transition: transform 0.4s cubic-bezier(0.23, 1, 0.32, 1);
}

.branch-card:hover .branch-content {
  transform: translateY(0);
}

.branch-content h3 {
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 8px;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
  color: var(--fd-white);
}

.branch-card.featured .branch-content h3 {
  font-size: 2rem;
}

.branch-date {
  font-size: 0.875rem;
  opacity: 0.9;
  font-weight: 400;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
  color: var(--fd-white);
  display: flex;
  align-items: center;
  gap: 6px;
}

.branch-date::before {
  content: "\f133";
  font-family: "Font Awesome 6 Free";
  font-weight: 400;
  font-size: 0.75rem;
}

/* Dark mode for News Gallery */
.dark .news-gallery {
  background-color: var(--surface);
}

.dark .branch-card {
  border-color: var(--border);
  background: linear-gradient(
    135deg,
    rgba(30, 41, 59, 0.8) 0%,
    transparent 50%,
    rgba(0, 0, 0, 0.2) 100%
  );
}

.dark .branch-card:hover {
  border-color: var(--fd-green);
  box-shadow:
    0 20px 50px rgba(0, 0, 0, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

/* ── News Gallery Lightbox ─────────────────────────────────────────── */
.gallery-lightbox {
  position: fixed;
  inset: 0;
  z-index: 9000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}
.gallery-lightbox.open {
  opacity: 1;
  pointer-events: auto;
}
.gallery-lightbox-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.82);
  cursor: pointer;
}
.gallery-lightbox-panel {
  position: relative;
  z-index: 1;
  width: min(900px, 90vw);
  border-radius: 16px;
  overflow: hidden;
  background: #0d1b2a;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6);
  transform: scale(0.94);
  transition: transform 0.28s cubic-bezier(0.23, 1, 0.32, 1);
}
.gallery-lightbox.open .gallery-lightbox-panel {
  transform: scale(1);
}
.gallery-lightbox-img {
  display: block;
  width: 100%;
  max-height: 72vh;
  object-fit: cover;
}
.gallery-lightbox-info {
  padding: 20px 24px;
  background: linear-gradient(135deg, #0d1b2a 0%, #1a3050 100%);
}
.gallery-lightbox-title {
  font-size: 1.2rem;
  font-weight: 600;
  color: #fff;
  margin: 0 0 6px;
}
.gallery-lightbox-date {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.7);
  margin: 0;
  display: flex;
  align-items: center;
  gap: 6px;
}
.gallery-lightbox-date::before {
  content: "\f133";
  font-family: "Font Awesome 6 Free";
  font-weight: 400;
  font-size: 0.75rem;
}
.gallery-lightbox-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.55);
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: #fff;
  font-size: 0.95rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10;
  transition: background 0.2s;
}
.gallery-lightbox-close:hover {
  background: rgba(255, 255, 255, 0.15);
}
/* RTL: flip close button to left side */
html[lang="ar"] .gallery-lightbox-close,
.rtl .gallery-lightbox-close {
  right: auto;
  left: 14px;
}

/* News section layout */
.news-header {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 48px;
  gap: 24px;
}

.news-header .slider-controls {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-shrink: 0;
}

/* Center news grid container */
.news-slider-container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  overflow: hidden;
  position: relative;
}

/* Footer map link: center content */
footer .flex.items-start.gap-3:has(.fa-map-marker-alt) {
  justify-content: center;
  align-items: center;
}

footer .flex.items-start.gap-3:has(.fa-map-marker-alt) .flex-1 {
  text-align: center;
}

footer .flex.items-start.gap-3:has(.fa-map-marker-alt) a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

/* Alternative: Target the map section directly with class */
.map-section-center {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
}

.map-section-center .flex-1 {
  text-align: center;
}

/* Global sourcing section */
.global-sourcing {
  padding: 80px 0;
  background-color: #ffffff;
}

.global-sourcing .container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.global-sourcing .text-center {
  text-align: center;
}

.global-sourcing h2 {
  text-align: center;
  margin: 0 auto;
}

.global-sourcing .max-w-4xl {
  margin: 0 auto;
  text-align: center;
}

/* Center map container */
.global-sourcing .map-container {
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 0 auto;
  max-width: 1000px;
}

.global-sourcing .map-container img {
  margin: 0 auto;
  display: block;
}

/* Center legend */
.global-sourcing .flex.justify-center {
  display: flex;
  justify-content: center;
  width: 100%;
}

.global-sourcing .bg-white.border.rounded-lg {
  display: flex;
  justify-content: center;
  gap: 32px;
  flex-wrap: wrap;
}

/* Force theme changes */

.dark {
  color-scheme: dark !important;

  background-color: #1a1a1a !important;

  color: #ffffff !important;
}

html:not(.dark) {
  color-scheme: light !important;

  background-color: #ffffff !important;

  color: #000000 !important;
}

/* Force dark mode on all elements */

.dark body {
  background-color: #1a1a1a !important;

  color: #ffffff !important;
}

.dark header {
  background: rgba(31, 41, 55, 0.98) !important;
}

.dark .toggle-btn {
  background: linear-gradient(
    135deg,
    rgba(122, 193, 67, 0.15),
    rgba(42, 47, 58, 0.15)
  ) !important;

  border: 1px solid rgba(255, 255, 255, 0.1) !important;
}

/* ============================================



   Header & Navigation (FD Profile Match)



   ============================================ */

header {
  backdrop-filter: blur(20px) saturate(180%);

  -webkit-backdrop-filter: blur(20px) saturate(180%);

  background: rgba(255, 255, 255, 0.98) !important;

  border-bottom: 1px solid rgba(124, 132, 124, 0.1);

  transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);

  position: fixed;

  top: 0;

  width: 100%;

  z-index: 9999;
}

[dir="ltr"] header {
  left: 0;

  right: 0;
}

[dir="rtl"] header {
  right: 0;

  left: 0;
}

.dark header {
  background: rgba(31, 41, 55, 0.98) !important;

  border-bottom: 1px solid rgba(255, 255, 255, 0.15);
}

body {
  overflow-x: hidden;
  max-width: 100vw;
}


.logo-container {
  display: flex;

  align-items: center;

  gap: 0.75rem;

  color: inherit;

  text-decoration: none;

  transition: 0.25s;
}

.logo-image {
  width: 240px;

  height: 100px;

  object-fit: contain;

  transition: 0.25s;
}

.logo-container:hover .logo-image {
  transform: scale(1.06) translateY(-4px);

  opacity: 0.95;
}

.nav-link {
  position: relative;

  padding: 10px 0;

  font-weight: 600;

  color: var(--fd-gray);

  font-size: 16px;

  background: linear-gradient(to right, var(--fd-green), var(--fd-green))
    no-repeat;

  background-size: 0% 2px;

  background-position: left bottom;
}

[dir="rtl"] .nav-link {
  background-position: right bottom;
}

.nav-link:hover,
.nav-link.active {
  background-size: 100% 2px;

  color: var(--fd-green);
}

.toggle-btn {
  width: 52px;

  height: 52px;

  border-radius: 16px;

  background: linear-gradient(
    135deg,
    rgba(122, 193, 67, 0.2) 0%,

    rgba(122, 193, 67, 0.1) 100%
  );

  backdrop-filter: blur(15px);

  border: 2px solid rgba(255, 255, 255, 0.3);

  transition: all 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);

  display: flex;

  align-items: center;

  justify-content: center;

  position: relative;

  overflow: hidden;

  cursor: pointer;

  outline: none;
}

.toggle-btn i {
  font-size: 18px;

  transition: all 0.3s ease;
}

.dark .toggle-btn {
  background: linear-gradient(
    135deg,
    rgba(122, 193, 67, 0.15),
    rgba(42, 47, 58, 0.15)
  );

  border: 1px solid rgba(255, 255, 255, 0.1);
}

.toggle-btn:hover {
  transform: translateY(-2px) scale(1.05);

  box-shadow: 0 8px 20px rgba(122, 193, 67, 0.25);

  border-color: var(--fd-green);
}

.toggle-btn:focus-visible {
  outline: none;

  box-shadow: var(--focus-ring);
}

.action-buttons-container {
  display: flex;

  align-items: center;

  gap: 12px;

  z-index: 100;
}

.mobile-nav-container {
  max-height: 0;

  overflow: hidden;

  transition:
    max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1),
    opacity 0.3s ease;

  background: rgba(255, 255, 255, 0.98);

  backdrop-filter: blur(10px);

  border-top: 1px solid rgba(124, 132, 124, 0.1);

  position: relative;

  display: block;

  opacity: 0;
}

.dark .mobile-nav-container {
  background: rgba(31, 41, 55, 0.98);

  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.mobile-nav-container.active {
  max-height: 80vh;
  opacity: 1;
}

/* Ensure closed state is always collapsed */

.mobile-nav-container:not(.active) {
  max-height: 0 !important;

  overflow: hidden !important;

  opacity: 0 !important;

  border-top-width: 0 !important;

  visibility: hidden !important;
}

.mobile-nav-container .nav-link {
  margin: 0.25rem 0;

  padding: 0.9rem 1rem;

  border-radius: 0.9rem;

  background: transparent;

  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.mobile-nav-container .nav-link:hover {
  background: rgba(122, 193, 67, 0.1);

  transform: translateX(8px);
}

[dir="rtl"] .mobile-nav-container .nav-link:hover {
  transform: translateX(-8px);
}

.mobile-nav-container .nav-link.active {
  background: var(--fd-green);

  color: #fff;

  transform: translateX(8px);
}

[dir="rtl"] .mobile-nav-container .nav-link.active {
  transform: translateX(-8px);
}

.search-container {
  opacity: 0;

  visibility: hidden;

  transform: translateY(-20px) scale(0.95);

  transition: all 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);

  background: rgba(255, 255, 255, 0.98);

  backdrop-filter: blur(40px) saturate(200%);

  border: 1px solid rgba(124, 132, 124, 0.1);

  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);

  border-radius: 1.25rem;
}

.dark .search-container {
  background: rgba(31, 41, 55, 0.98);

  border: 1px solid rgba(255, 255, 255, 0.15);
}

.search-container.active {
  opacity: 1;

  visibility: visible;

  transform: translateY(0) scale(1);
}

/* Responsive Design */

/* Tablet header row height (768–1023px) */
@media (min-width: 768px) and (max-width: 1023px) {
  #mainHeader .h-24 {
    height: 80px;
  }
}

@media (max-width: 767px) {
  /* Shrink header row on mobile */
  #mainHeader .h-24 {
    height: 68px;
  }
}

@media (max-width: 479px) {
  /* Compact header row on small phones */
  #mainHeader .h-24 {
    height: 64px;
  }
}

@media (max-width: 768px) {
  body {
    padding-bottom: 64px;
  }

  #mainHeader .container {
    padding-left: 1rem;

    padding-right: 1rem;
  }

  #mainHeader .flex {
    flex-wrap: nowrap;
  }

  #mainHeader .logo-container {
    flex-shrink: 0;
  }

  #mainHeader .action-buttons-container {
    flex-shrink: 0;

    gap: 0.5rem;
  }

  /* Mobile navigation — stays in document flow (relative), not absolute */

  .mobile-nav-container {
    position: relative;

    width: 100%;

    background: rgba(255, 255, 255, 0.98);

    backdrop-filter: blur(20px);

    border-top: 1px solid rgba(124, 132, 124, 0.1);

    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  }

  .dark .mobile-nav-container {
    background: rgba(31, 41, 55, 0.98);
  }

  .mobile-nav-container .container {
    padding: 0;
  }
}

/* Extra small mobile devices */

@media (max-width: 640px) {
  #mainHeader .container {
    padding-left: 0.75rem;

    padding-right: 0.75rem;
  }

  #mainHeader .action-buttons-container {
    gap: 0.25rem;
  }

  .toggle-btn {
    width: 40px !important;

    height: 40px !important;
  }

  .logo-image {
    width: 190px !important;

    height: 70px !important;

    object-fit: contain;
  }

  .mobile-nav-container.active {
    max-height: 70vh;

    overflow-y: auto;
  }

  .mobile-nav-container .py-6 {
    padding-top: 1rem;

    padding-bottom: 1rem;
  }

  .mobile-nav-container .nav-link {
    padding: 0.75rem 1rem;

    font-size: 0.9rem;
  }
}

/* Very small phones (≤340px) — prevent logo overflow */
@media (max-width: 340px) {
  .logo-image,
  .rtl .logo-image {
    width: 150px !important;
    height: 52px !important;
    object-fit: contain;
  }

  .toggle-btn {
    width: 34px !important;
    height: 34px !important;
  }
}

/* Mobile responsive additions */

/* === HIGHLIGHTS (STATS) - 3 per row on mobile === */
@media (max-width: 767px) {
  /* Reduce section header spacing on mobile */
  .highlight-item {
    padding: 0.75rem 0.5rem;
    border-radius: 0.75rem;
  }
  /* Icon circle smaller on mobile */
  .highlight-item .w-24 {
    width: 3.5rem;
    height: 3.5rem;
  }
}

/* === ABOUT SECTION - Mobile typography === */
@media (max-width: 767px) {
  #about .container {
    padding-left: 1rem;
    padding-right: 1rem;
  }
  /* Hero content padding on mobile */
  .hero-content {
    padding: 40px 20px 80px;
    margin-left: 0;
  }
  .hero-title {
    font-size: 2rem;
  }
  .hero-subtitle {
    font-size: 0.95rem;
  }
}

/* === ABOUT CAROUSEL - Mobile slider for Vision/Mission/Commitment === */
.about-carousel-wrapper {
  position: relative;
  overflow: hidden;
  width: 100%;
}

.about-carousel-track {
  display: flex;
  transition: transform 0.4s cubic-bezier(0.23, 1, 0.32, 1);
  will-change: transform;
}

.about-carousel-slide {
  flex: 0 0 100%;
  min-width: 100%;
  padding: 0 4px;
}

/* Carousel dot indicators */
.about-carousel-dots {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 16px;
  padding-bottom: 4px;
}

.about-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  border: none;
  background: rgba(27, 33, 71, 0.25);
  cursor: pointer;
  transition: all 0.3s ease;
  padding: 0;
}

.about-dot.active {
  background: var(--fd-green);
  width: 24px;
  border-radius: 4px;
}

.about-dot:hover {
  background: var(--fd-navy);
}

/* === NEWS GALLERY DESKTOP - hide on mobile, show on sm+ === */
.news-gallery-desktop {
  display: none;
}
@media (min-width: 640px) {
  .news-gallery-desktop {
    display: grid;
  }
}

/* === NEWS GALLERY - Mobile slider (visible only on mobile <640px) === */
.news-gallery-mobile-slider {
  position: relative;
  overflow: hidden;
  width: 100%;
}
@media (min-width: 640px) {
  .news-gallery-mobile-slider {
    display: none;
  }
}

.news-gallery-mobile-track {
  display: flex;
  transition: transform 0.4s cubic-bezier(0.23, 1, 0.32, 1);
  will-change: transform;
}

.news-gallery-mobile-slide {
  flex: 0 0 100%;
  min-width: 100%;
  padding: 0 4px;
}

/* News gallery mobile dots */
.news-gallery-mobile-dots {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 14px;
}

.ng-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  border: none;
  background: rgba(27, 33, 71, 0.25);
  cursor: pointer;
  transition: all 0.3s ease;
  padding: 0;
}

.ng-dot.active {
  background: var(--fd-green);
  width: 24px;
  border-radius: 4px;
}

.ng-dot:hover {
  background: var(--fd-navy);
}

/* === BRANDS SECTION - Mobile compact layout === */
@media (max-width: 767px) {
  /* Compact brand cards on mobile */
  .brand-item {
    min-height: 80px;
    height: 90px;
    padding: 0.5rem;
    border-radius: 0.5rem;
  }

  .brand-item img {
    height: 36px !important;
    max-height: 36px !important;
  }

  /* Nav arrows hidden on small mobile, use dots only */
  #brands-prev,
  #brands-next {
    width: 32px;
    height: 32px;
    padding: 0.4rem;
  }

  /* Brands section reduced top/bottom padding */
  #brands {
    padding-top: 2.5rem;
    padding-bottom: 2.5rem;
  }

  #brands .text-center.mb-16 {
    margin-bottom: 1.5rem;
  }
}

@media (max-width: 479px) {
  /* Hide arrow buttons on very small screens — swipe + dots handle navigation */
  #brands-prev,
  #brands-next {
    display: none !important;
  }

  .brand-item {
    min-height: 80px !important;
    height: 88px !important;
    padding: 0.4rem !important;
  }

  .brand-item img {
    height: 36px !important;
    max-height: 36px !important;
  }
}

/* === GLOBAL SOURCING - Mobile responsive === */
@media (max-width: 767px) {
  .global-sourcing {
    padding: 40px 0 !important;
  }

  .global-sourcing .flex.justify-center .bg-white {
    flex-wrap: wrap;
    gap: 12px !important;
    padding: 12px;
  }
}

/* === NEWS SECTION - Mobile compact === */
@media (max-width: 767px) {
  .news {
    padding: 48px 0;
  }

  .news-header {
    flex-direction: column;
    align-items: flex-start;
    margin-bottom: 24px;
    gap: 12px;
  }

  .news-header .text-left {
    width: 100%;
  }

  .news-header .slider-controls {
    align-self: flex-end;
  }
}

/* Careers section: Arabic button alignment */
@media (min-width: 640px) {
  html[lang="ar"] #careers .flex.flex-col.sm\:flex-row {
    justify-content: flex-start !important;
    align-items: flex-start !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    margin-left: 0 !important;
    margin-right: auto !important;
  }
}

/* === CAREERS SECTION - Mobile responsive === */
@media (max-width: 767px) {
  #careers {
    padding-top: 3rem;
    padding-bottom: 3rem;
    min-height: auto;
  }

  #careers h2 {
    font-size: 1.75rem !important;
  }

  #careers p.text-lg {
    font-size: 0.9rem !important;
  }
}

/* === FOOTER - Mobile responsive === */
@media (max-width: 767px) {
  footer .flex.flex-col.lg\:flex-row {
    gap: 1.5rem;
  }

  footer .py-6 {
    padding-top: 1.5rem;
    padding-bottom: 1.5rem;
  }
}

/* === DARK MODE - about carousel and news gallery mobile dots === */
.dark .about-dot {
  background: rgba(226, 232, 240, 0.25);
}

.dark .about-dot.active {
  background: var(--fd-green);
}

.dark .ng-dot {
  background: rgba(226, 232, 240, 0.25);
}

.dark .ng-dot.active {
  background: var(--fd-green);
}

.dark .ng-dot:hover {
  background: var(--fd-green);
}

/* Mobile compact layout adjustments (≤767px) */
@media (max-width: 767px) {
  /* === GLOBAL TYPOGRAPHY REDUCTIONS === */

  /* Minimize all heading sizes */
  h1 {
    font-size: 1.5rem !important;
    line-height: 1.2 !important;
    margin-bottom: 0.75rem !important;
  }
  h2 {
    font-size: 1.25rem !important;
    line-height: 1.3 !important;
    margin-bottom: 0.625rem !important;
  }
  h3 {
    font-size: 1.1rem !important;
    line-height: 1.3 !important;
    margin-bottom: 0.5rem !important;
  }
  h4 {
    font-size: 1rem !important;
    line-height: 1.4 !important;
    margin-bottom: 0.4rem !important;
  }
  h5,
  h6 {
    font-size: 0.9rem !important;
    line-height: 1.4 !important;
    margin-bottom: 0.375rem !important;
  }

  /* Minimize paragraph and text content */
  p,
  .text-content,
  .description {
    font-size: 0.875rem !important;
    line-height: 1.5 !important;
    margin-bottom: 0.75rem !important;
  }

  /* Minimize small text and captions */
  small,
  .text-sm,
  .caption,
  .meta {
    font-size: 0.75rem !important;
    line-height: 1.4 !important;
  }

  /* === HERO SECTION ULTRA-COMPACT === */
  .hero {
    height: 85vh !important;
    max-height: 700px !important;
  }

  .hero-content {
    padding: 30px 16px 80px !important;
    margin-left: 0 !important;
  }

  .hero-title {
    font-size: 1.75rem !important;
    line-height: 1.1 !important;
    margin-bottom: 0.75rem !important;
  }

  .hero-subtitle {
    font-size: 0.875rem !important;
    line-height: 1.4 !important;
    margin-bottom: 1rem !important;
  }

  .hero-actions {
    gap: 0.625rem !important;
    margin-top: 1rem !important;
  }

  /* === BUTTON MINIMIZATION === */
  .btn {
    padding: 0.625rem 1rem !important;
    font-size: 0.8rem !important;
    min-height: 40px !important;
    border-radius: 0.5rem !important;
  }

  .btn-primary .arrow-icon {
    width: 20px !important;
    height: 20px !important;
    padding: 2px !important;
  }

  /* Elementor buttons */
  .elementor-button {
    padding: 8px 16px !important;
    font-size: 0.75rem !important;
  }

  .elementor-button.elementor-size-sm {
    padding: 6px 12px !important;
    font-size: 0.7rem !important;
  }

  /* === SECTION PADDING REDUCTIONS === */
  section[class*="pt-"][class*="pb-"],
  .py-16,
  .py-20,
  .py-24 {
    padding-top: 2rem !important;
    padding-bottom: 2rem !important;
  }

  .container {
    padding-left: 0.75rem !important;
    padding-right: 0.75rem !important;
  }

  /* === HIGHLIGHTS/STATS COMPACT === */
  .highlight-item {
    padding: 0.75rem 0.5rem !important;
    border-radius: 0.5rem !important;
  }

  /* Icon containers: let Tailwind w-14/w-20/w-24 responsive classes handle sizing */
  .highlight-item .w-24,
  .highlight-item [class*="w-"] {
    width: 3rem !important;
    height: 3rem !important;
  }

  .highlight-item .text-4xl,
  .highlight-item .text-3xl,
  .highlight-item .text-2xl {
    font-size: 1.25rem !important;
  }

  .highlight-item .text-sm {
    font-size: 0.65rem !important;
    line-height: 1.3 !important;
  }

  .highlight-item .text-xs {
    font-size: 0.6rem !important;
  }

  /* === NEWS SECTION COMPACT === */
  .news {
    padding: 2rem 0 !important;
  }

  .news-header {
    margin-bottom: 1.5rem !important;
    gap: 0.75rem !important;
  }

  .news-header h2 {
    font-size: 1.25rem !important;
    margin-bottom: 0.5rem !important;
  }

  .news-item {
    padding: 1rem !important;
    border-left-width: 3px !important;
  }

  .news-item .date {
    font-size: 0.7rem !important;
    margin-bottom: 0.5rem !important;
  }

  .news-item p {
    font-size: 0.8rem !important;
    line-height: 1.4 !important;
  }

  .slider-btn {
    width: 28px !important;
    height: 28px !important;
    font-size: 0.7rem !important;
  }

  /* === BRANDS SECTION ULTRA-COMPACT === */
  #brands {
    padding: 1.5rem 0 !important;
  }

  #brands .text-center.mb-16 {
    margin-bottom: 1rem !important;
  }

  #brands h2 {
    font-size: 1.25rem !important;
    margin-bottom: 0.5rem !important;
  }

  .brand-item {
    min-height: 85px !important;
    height: 95px !important;
    padding: 0.5rem !important;
    border-radius: 0.5rem !important;
  }

  .brand-item img {
    height: 40px !important;
    max-height: 40px !important;
  }

  .brand-item img[src*="sama"] {
    height: 32px !important;
    max-height: 32px !important;
  }

  /* === GALLERY CARDS COMPACT === */
  .gallery-card {
    width: 280px !important;
    padding: 0.75rem !important;
  }

  .gallery-card h2 {
    font-size: 1.25rem !important;
    margin-bottom: 0.375rem !important;
  }

  .gallery-card h3 {
    font-size: 0.75rem !important;
    margin-bottom: 0.75rem !important;
  }

  .gallery-card img,
  .image-slider-container {
    height: 140px !important;
  }

  .slider-nav {
    width: 28px !important;
    height: 28px !important;
    font-size: 0.6rem !important;
  }

  .slider-dot {
    width: 6px !important;
    height: 6px !important;
  }

  .slider-dot.active {
    width: 18px !important;
  }


  .branch-date {
    font-size: 0.7rem !important;
  }

  /* === GLOBAL SOURCING COMPACT === */
  .global-sourcing {
    padding: 2rem 0 !important;
  }

  .global-sourcing h2 {
    font-size: 1.25rem !important;
    margin-bottom: 0.75rem !important;
  }

  .global-sourcing .max-w-4xl {
    font-size: 0.875rem !important;
    line-height: 1.5 !important;
  }

  /* === CAREERS SECTION COMPACT === */
  #careers {
    padding: 2rem 0 !important;
  }

  #careers h2 {
    font-size: 1.25rem !important;
  }

  #careers p.text-lg {
    font-size: 0.875rem !important;
  }

  /* Hide specific careers text on mobile */
  #careers p.max-w-xl {
    display: none !important;
  }

  /* === FOOTER COMPACT === */
  footer {
    padding-top: 2rem !important;
    padding-bottom: 1rem !important;
  }

  footer .py-6 {
    padding-top: 1rem !important;
    padding-bottom: 1rem !important;
  }

  footer h3 {
    font-size: 0.9rem !important;
    margin-bottom: 0.5rem !important;
  }

  footer p,
  footer li {
    font-size: 0.75rem !important;
    line-height: 1.4 !important;
  }

  /* === DIALOG/MODAL COMPACT === */
  .branch-dialog-content {
    width: 95% !important;
    margin: 1rem !important;
    border-radius: 0.75rem !important;
  }

  .branch-dialog-header,
  .branch-dialog-body {
    padding: 1rem !important;
  }

  .branch-dialog-title {
    font-size: 1.1rem !important;
  }

  .branch-dialog-subtitle {
    font-size: 0.875rem !important;
    margin-bottom: 1rem !important;
  }

  .branch-option-btn {
    padding: 0.75rem !important;
    gap: 0.75rem !important;
    border-radius: 0.5rem !important;
  }

  .branch-option-icon {
    width: 32px !important;
    height: 32px !important;
    font-size: 0.875rem !important;
  }

  .branch-option-title {
    font-size: 0.9rem !important;
  }

  .branch-option-description {
    font-size: 0.75rem !important;
  }

  /* === SOCIAL PANEL COMPACT === */
  .social-side-panel {
    padding: 1rem 0 !important;
  }

  .social-link {
    padding: 0.625rem 0.75rem !important;
    max-width: 40px !important;
  }

  .social-icon {
    width: 20px !important;
    height: 20px !important;
    font-size: 0.75rem !important;
  }

  .social-link:hover {
    max-width: 100px !important;
  }

  .social-label {
    font-size: 0.7rem !important;
  }

  /* === GENERAL SPACING REDUCTIONS === */
  .gap-6,
  .gap-8 {
    gap: 0.75rem !important;
  }
  .gap-4,
  .gap-5 {
    gap: 0.5rem !important;
  }
  .gap-3 {
    gap: 0.375rem !important;
  }
  .gap-2 {
    gap: 0.25rem !important;
  }

  .mb-8,
  .mb-10,
  .mb-12 {
    margin-bottom: 1rem !important;
  }
  .mb-6,
  .mb-7 {
    margin-bottom: 0.75rem !important;
  }
  .mb-4,
  .mb-5 {
    margin-bottom: 0.5rem !important;
  }
  .mb-3 {
    margin-bottom: 0.375rem !important;
  }
  .mb-2 {
    margin-bottom: 0.25rem !important;
  }

  .mt-8,
  .mt-10,
  .mt-12 {
    margin-top: 1rem !important;
  }
  .mt-6,
  .mt-7 {
    margin-top: 0.75rem !important;
  }
  .mt-4,
  .mt-5 {
    margin-top: 0.5rem !important;
  }
  .mt-3 {
    margin-top: 0.375rem !important;
  }
  .mt-2 {
    margin-top: 0.25rem !important;
  }

  .py-4,
  .py-5,
  .py-6 {
    padding-top: 0.75rem !important;
    padding-bottom: 0.75rem !important;
  }

  .px-4,
  .px-5,
  .px-6 {
    padding-left: 0.75rem !important;
    padding-right: 0.75rem !important;
  }

  /* === CAROUSEL AND SLIDER COMPACT === */
  .about-carousel-dots,
  .news-gallery-mobile-dots {
    margin-top: 0.75rem !important;
    gap: 0.5rem !important;
  }

  .about-dot,
  .ng-dot {
    width: 6px !important;
    height: 6px !important;
  }

  .about-dot.active,
  .ng-dot.active {
    width: 18px !important;
  }
}

/* Very small screens (≤380px) — override the 767px block for extra-compact sizes */
@media (max-width: 380px) {
  .brand-item {
    min-height: 75px !important;
    height: 84px !important;
    padding: 0.35rem !important;
  }

  .brand-item img {
    height: 34px !important;
    max-height: 34px !important;
  }

  #brands-prev,
  #brands-next {
    display: none !important;
  }

  .highlight-item {
    padding: 0.5rem 0.25rem !important;
  }

  .highlight-item .w-24,
  .highlight-item [class*="w-"] {
    width: 2.5rem !important;
    height: 2.5rem !important;
  }

  .highlight-item .text-4xl,
  .highlight-item .text-3xl,
  .highlight-item .text-2xl {
    font-size: 1.1rem !important;
  }

  .highlight-item .text-sm,
  .highlight-item .text-xs {
    font-size: 0.55rem !important;
  }

  .hero-title {
    font-size: 1.5rem !important;
  }

  .hero-subtitle {
    font-size: 0.8rem !important;
  }
}

/* === POST-BIG-BLOCK TARGETED OVERRIDES ===
   These run AFTER the big @media (max-width: 767px) block so they win the cascade
   without needing to bloat that block further. */
@media (max-width: 767px) {
  /* Footer layout: global .gap-6→0.75rem is too tight for stacked footer sections */
  footer .flex.flex-col {
    gap: 1.5rem !important;
  }
  /* Footer inner sections grid (Quick Links / Social / Legal) */
  footer .grid {
    gap: 1.25rem !important;
  }

  /* Career hero h1: global h1→1.5rem is too small for the career page headline */
  .career-hero h1 {
    font-size: 2rem !important;
    line-height: 1.2 !important;
    margin-bottom: 1rem !important;
  }
}

@media (max-width: 479px) {
  /* Career form: 2rem horizontal padding is cramped on 320-479px screens */
  .career-form {
    padding: 1.5rem 1rem !important;
  }
}

/* About carousel mobile RTL (<640px) */
@media (max-width: 639px) {
  .rtl .about-carousel-wrapper {
    direction: rtl !important;
    position: relative !important;
    overflow: hidden !important;
    width: 100% !important;
    margin-top: 2rem !important;
  }

  /* RTL about carousel track - fix transform direction */
  .rtl #aboutCarouselTrack {
    direction: ltr !important; /* Keep LTR for proper flex behavior */
    display: flex !important;
    transition: transform 0.4s cubic-bezier(0.23, 1, 0.32, 1) !important;
    width: 100% !important;
    height: auto !important;
    overflow: visible !important;
  }

  .rtl .about-carousel-slide {
    direction: rtl !important;
    flex: 0 0 100% !important;
    min-width: 100% !important;
    width: 100% !important;
    display: block !important;
    position: relative !important;
    overflow: hidden !important;
  }

  .rtl .about-carousel-slide .absolute {
    direction: rtl !important;
    text-align: right !important;
    left: 0 !important;
    right: 0 !important;
    padding: 0 1.5rem !important;
  }

  .rtl .about-carousel-slide h3 {
    direction: rtl !important;
    text-align: right !important;
    font-size: 1.5rem !important;
    font-weight: 700 !important;
    margin-bottom: 0.5rem !important;
    color: white !important;
  }

  .rtl .about-carousel-slide p {
    direction: rtl !important;
    text-align: right !important;
    font-size: 0.95rem !important;
    font-weight: 400 !important;
    line-height: 1.5 !important;
    color: rgba(255, 255, 255, 0.9) !important;
    margin: 0 !important;
  }

  .rtl .about-carousel-dots {
    direction: ltr !important; /* LTR so dots render left-to-right regardless of page language */
    display: flex !important;
    justify-content: center !important;
    gap: 8px !important;
    margin-top: 1rem !important;
    padding: 0 1rem !important;
  }

  .rtl .about-dot {
    width: 8px !important;
    height: 8px !important;
    border-radius: 50% !important;
    background: rgba(255, 255, 255, 0.4) !important;
    border: none !important;
    cursor: pointer !important;
    transition: all 0.3s ease !important;
    direction: ltr !important;
  }

  .rtl .about-dot.active {
    background: white !important;
    width: 24px !important;
    border-radius: 4px !important;
  }

  .rtl .about-dot:hover {
    background: rgba(255, 255, 255, 0.7) !important;
  }
}

/* About carousel RTL initialization (<640px) */
@media (max-width: 639px) {
  html[lang="ar"] .about-carousel-wrapper {
    direction: rtl !important;
  }

  html[lang="ar"] #aboutCarouselTrack {
    direction: ltr !important;
  }

  html[lang="ar"] .about-carousel-slide {
    direction: rtl !important;
  }

  html[lang="ar"] .about-carousel-dots {
    direction: ltr !important;
  }

  html[lang="ar"] .about-dot {
    direction: ltr !important;
  }
}

/* Desktop footer RTL (≥1024px) */
@media (min-width: 1024px) {
  .rtl footer {
    direction: rtl;
  }

  /* Reverse the top-level flex row so brand section ends up on the right */
  .rtl footer .flex.flex-col.lg\:flex-row {
    flex-direction: row-reverse !important;
    direction: rtl;
  }

  .rtl footer .lg\:w-2\/5 {
    order: 2 !important;
    text-align: right;
    direction: rtl;
    display: flex !important;
    justify-content: flex-end !important;
    align-items: flex-start !important;
  }

  .rtl footer .lg\:w-2\/5 .text-center {
    text-align: right !important;
  }

  .rtl footer .lg\:w-2\/5 .lg\:text-right {
    text-align: right !important;
  }

  /* Logo and Vision Badge - MOVE TO RIGHT EDGE */
  .rtl footer .flex.flex-col.items-center.lg\:items-start {
    align-items: flex-end !important; /* Align to right edge */
    justify-content: flex-start !important;
    width: 100% !important;
    max-width: 100% !important;
  }

  .rtl footer .flex.flex-col.items-center.lg\:items-start .text-center {
    text-align: right !important;
    align-items: flex-end !important;
    justify-content: flex-end !important;
  }

  .rtl footer .flex.flex-col.items-center.lg\:items-start .lg\:text-right {
    text-align: right !important;
    align-items: flex-end !important;
  }

  /* Logo Container - RIGHT EDGE POSITIONING */
  .rtl
    footer
    .flex.flex-col.md\:flex-row.items-center.md\:items-center.gap-3.md\:gap-4.mb-4.md\:mb-6 {
    justify-content: flex-end !important; /* Push logo and badge to right edge */
    align-items: flex-start !important;
    width: 100% !important;
    flex-direction: row-reverse !important; /* Reverse order: badge first, then logo */
  }

  .rtl
    footer
    .flex.flex-col.md\:flex-row.items-center.md\:items-center.gap-3.md\:gap-4.mb-4.md\:mb-6
    > div {
    align-items: flex-end !important;
    justify-content: flex-end !important;
  }

  /* Logo Link - RIGHT EDGE */
  .rtl footer .flex-shrink-0 {
    margin-left: 0 !important; /* Remove auto margin */
    margin-right: 0 !important;
    order: 2 !important; /* Logo comes second (rightmost) */
  }

  .rtl footer .flex-shrink-0 img {
    margin-left: 0 !important;
    margin-right: 0 !important;
  }

  /* Vision Badge - RIGHT EDGE */
  .rtl footer .flex.items-center.gap-2.bg-white\/10.px-3.py-1\.5.rounded-full {
    margin-left: 0 !important; /* Remove left margin */
    margin-right: 0.5rem !important; /* Small space before logo */
    justify-content: flex-end !important;
    order: 1 !important; /* Badge comes first (left of logo) */
  }

  .rtl
    footer
    .flex.items-center.gap-2.bg-white\/10.px-3.py-1\.5.rounded-full
    .arabic-font {
    text-align: right !important;
  }

  /* Alternative: Stack badge below logo at right edge */
  @media (min-width: 768px) {
    .rtl
      footer
      .flex.flex-col.md\:flex-row.items-center.md\:items-center.gap-3.md\:gap-4.mb-4.md\:mb-6 {
      flex-direction: column !important; /* Stack vertically */
      align-items: flex-end !important; /* Align to right edge */
      gap: 0.5rem !important; /* Tight spacing */
    }

    .rtl
      footer
      .flex.items-center.gap-2.bg-white\/10.px-3.py-1\.5.rounded-full {
      margin-right: 0 !important;
      margin-left: 0 !important;
      order: 2 !important; /* Badge below logo */
    }

    .rtl footer .flex-shrink-0 {
      order: 1 !important; /* Logo on top */
    }
  }

  /* Mobile: Keep horizontal but right-aligned */
  @media (max-width: 767px) {
    .rtl
      footer
      .flex.flex-col.md\:flex-row.items-center.md\:items-center.gap-3.md\:gap-4.mb-4.md\:mb-6 {
      flex-direction: row-reverse !important; /* Badge first, then logo */
      justify-content: flex-end !important;
    }

    .rtl
      footer
      .flex.items-center.gap-2.bg-white\/10.px-3.py-1\.5.rounded-full {
      margin-right: 0.25rem !important; /* Minimal space on mobile */
      margin-left: 0 !important;
    }
  }

  /* Company Info - RIGHT ALIGNED */
  .rtl footer .text-center.lg\:text-right {
    text-align: right !important;
    align-items: flex-end !important;
    justify-content: flex-end !important;
  }

  .rtl footer .text-center.lg\:text-right h2 {
    text-align: right !important;
    align-items: flex-end !important;
  }

  .rtl footer .text-center.lg\:text-right p {
    text-align: right !important;
    align-items: flex-end !important;
  }

  /* Registration Info - RIGHT EDGE */
  .rtl footer .border-t.border-white\/20 {
    text-align: right !important;
    align-items: flex-end !important;
    justify-content: flex-end !important;
  }

  .rtl footer .border-t.border-white\/20 .arabic-font {
    text-align: right !important;
  }

  .rtl footer .border-t.border-white\/20 .ltr-content {
    direction: ltr;
    text-align: left;
  }

  /* Grid sections to the left, brand section to the right */
  .rtl footer .lg\:w-3\/5 {
    order: 1 !important;
  }

  .rtl footer .lg\:w-2\/5 {
    order: 2 !important;
    text-align: right;
    direction: rtl;
  }

  .rtl footer .lg\:w-2\/5 .text-center {
    text-align: right !important;
  }

  .rtl footer .lg\:w-2\/5 .lg\:text-right {
    text-align: right !important;
  }

  /* Footer sections grid - MOVE TO LEFT SIDE */
  .rtl footer .lg\:w-3\/5 {
    order: 1 !important; /* Move grid sections to left */
  }

  .rtl footer .lg\:w-3\/5 .grid.grid-cols-1.sm\:grid-cols-2.lg\:grid-cols-3 {
    direction: rtl; /* RTL for the grid content */
  }

  .rtl
    footer
    .lg\:w-3\/5
    .grid.grid-cols-1.sm\:grid-cols-2.lg\:grid-cols-3
    > div {
    direction: rtl;
    text-align: right;
  }

  /* Footer company info - RTL text alignment */
  .rtl footer h2.arabic-font {
    text-align: right !important;
    direction: rtl !important;
  }

  .rtl footer p.arabic-font {
    text-align: right !important;
    direction: rtl !important;
  }

  /* Footer section headers - RTL alignment */
  .rtl footer h3.arabic-font {
    text-align: right !important;
    direction: rtl !important;
  }

  .rtl footer h3.arabic-font .flex {
    justify-content: flex-start;
  }

  /* Quick links section - RTL fixes */
  .rtl footer .grid.grid-cols-2 {
    direction: rtl; /* RTL for the links grid */
  }

  .rtl footer .grid.grid-cols-2 > div {
    text-align: right;
  }

  .rtl footer .grid.grid-cols-2 .flex {
    justify-content: flex-start;
  }

  .rtl footer .grid.grid-cols-2 .fas.fa-chevron-left {
    transform: rotate(180deg); /* Flip chevron for RTL */
  }

  .rtl footer .grid.grid-cols-2 .fas.fa-chevron-right {
    transform: rotate(180deg); /* Flip chevron for RTL */
  }

  /* Contact info section - RTL fixes */
  .rtl footer .space-y-4 .flex {
    direction: rtl;
  }

  .rtl footer .space-y-4 .flex .flex-1 {
    text-align: right;
  }

  .rtl footer .space-y-4 .flex .ltr-content {
    direction: ltr;
    text-align: left;
  }

  /* VAT Certificate section - RTL fixes */
  .rtl footer .lg\:col-span-1.sm\:col-span-2 {
    text-align: right;
    direction: rtl;
  }

  .rtl footer .lg\:col-span-1.sm\:col-span-2 .text-center {
    text-align: right !important;
  }

  .rtl footer .lg\:col-span-1.sm\:col-span-2 .sm\:text-left {
    text-align: right !important;
  }

  .rtl footer .lg\:col-span-1.sm\:col-span-2 .lg\:text-left {
    text-align: right !important;
  }

  /* Social media section - RTL fixes */
  .rtl footer .lg\:text-left {
    text-align: right !important;
  }

  .rtl footer .lg\:text-left .text-center {
    text-align: right !important;
  }

  .rtl footer .lg\:text-left .sm\:text-left {
    text-align: right !important;
  }

  .rtl footer .lg\:text-left .lg\:text-left {
    text-align: right !important;
  }

  .rtl footer .lg\:text-left .lg\:justify-start {
    justify-content: flex-end; /* Align to right in RTL */
  }

  .rtl footer .lg\:text-left .sm\:justify-start {
    justify-content: flex-end; /* Align to right in RTL */
  }

  .rtl footer .flex.flex-col.lg\:flex-row.justify-between.items-center {
    flex-direction: row-reverse !important;
    direction: rtl;
  }

  .rtl footer .order-1.lg\:order-2 {
    order: 2 !important; /* Keep payment methods on right in RTL */
    text-align: right !important;
  }

  .rtl footer .order-1.lg\:order-2 .text-center {
    text-align: right !important;
  }

  .rtl footer .order-1.lg\:order-2 .lg\:text-right {
    text-align: right !important;
  }

  .rtl footer .order-1.lg\:order-2 .lg\:items-end {
    align-items: flex-end !important; /* Align to right in RTL */
  }

  .rtl footer .order-2.lg\:order-1 {
    order: 1 !important; /* Move copyright to left in RTL */
    text-align: left !important;
  }

  .rtl footer .order-2.lg\:order-1 .text-center {
    text-align: left !important;
  }

  .rtl footer .order-2.lg\:order-1 .lg\:text-left {
    text-align: left !important;
  }

  /* Footer divider - maintain position */
  .rtl footer .border-t {
    text-align: center;
  }

  /* Footer background elements - maintain position */
  .rtl footer .absolute.inset-0 {
    direction: ltr; /* Keep background LTR */
  }

  .rtl footer .relative.z-10 {
    direction: rtl; /* Apply RTL to content */
  }

  /* Footer logo section - RTL fixes */
  .rtl footer .flex.flex-col.md\:flex-row {
    direction: ltr; /* Keep layout LTR */
  }

  .rtl footer .flex.flex-col.md\:flex-row > div {
    direction: rtl; /* Apply RTL to content */
  }

  .rtl footer .flex.flex-col.items-center.lg\:items-start {
    align-items: flex-end !important; /* Align to right in RTL */
  }

  .rtl footer .flex.flex-col.items-center.lg\:items-start .text-center {
    text-align: right !important;
  }

  .rtl footer .flex.flex-col.items-center.lg\:items-start .lg\:text-right {
    text-align: right !important;
  }

  /* Footer vision badge - RTL fixes */
  .rtl footer .flex.items-center.gap-2 {
    direction: rtl;
  }

  .rtl footer .flex.items-center.gap-2 .arabic-font {
    text-align: right;
  }

  /* Footer registration info - RTL fixes */
  .rtl footer .border-t.border-white\/20 {
    text-align: right;
  }

  .rtl footer .border-t.border-white\/20 .arabic-font {
    text-align: right !important;
  }

  .rtl footer .border-t.border-white\/20 .ltr-content {
    direction: ltr;
    text-align: left;
  }

  /* Footer RTL hover effects */
  .rtl footer a {
    transition: all 0.3s ease;
  }

  .rtl footer a:hover {
    transform: translateX(-4px); /* Move left on hover in RTL */
  }

  .rtl footer .grid.grid-cols-2 a {
    position: relative;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  }

  .rtl footer .grid.grid-cols-2 a:hover {
    transform: translateX(-8px) scale(1.02); /* Move left and scale in RTL */
  }

  .rtl footer .grid.grid-cols-2 a:hover .fas.fa-chevron-left {
    transform: rotate(180deg) translateX(-2px); /* Enhanced chevron animation */
  }

  .rtl footer .grid.grid-cols-2 a:hover .fas.fa-chevron-right {
    transform: rotate(180deg) translateX(-2px); /* Enhanced chevron animation */
  }

  .rtl footer .space-y-4 .flex {
    transition: all 0.3s ease;
  }

  .rtl footer .space-y-4 .flex:hover {
    transform: translateX(-4px); /* Move left on hover in RTL */
  }

  .rtl footer .space-y-4 .flex:hover .w-10 {
    background-color: rgba(
      122,
      193,
      67,
      0.3
    ) !important; /* Green hover in RTL */
    transform: scale(1.1);
  }

  /* VAT Certificate - RTL Hover Effects */
  .rtl footer .rounded-lg:hover {
    transform: translateX(-4px) scale(1.02); /* Move left and scale in RTL */
    background-color: rgba(255, 255, 255, 0.15) !important;
  }

  .rtl footer .rounded-lg:hover img {
    transform: scale(1.05);
  }

  /* Social Media Icons - RTL Hover Effects */
  .rtl footer .w-12.h-12 {
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  }

  .rtl footer .w-12.h-12:hover {
    transform: translateX(-4px) translateY(-2px) scale(1.1) !important; /* Move left and up in RTL */
  }

  .rtl footer .w-12.h-12:hover i {
    transform: scale(1.2) rotate(5deg);
  }

  /* Payment Methods - RTL Hover Effects */
  .rtl footer .w-10.h-8 {
    transition: all 0.3s ease;
  }

  .rtl footer .w-10.h-8:hover {
    transform: translateX(-2px) scale(1.1) !important; /* Move left in RTL */
    background-color: rgba(122, 193, 67, 0.2) !important;
  }

  /* Logo - RTL Hover Effects */
  .rtl footer img[alt*="Family Discount"] {
    transition: all 0.3s ease;
  }

  .rtl footer img[alt*="Family Discount"]:hover {
    transform: translateX(4px) scale(1.05); /* Move right in RTL (opposite direction) */
  }

  .rtl footer .bg-white\/10 {
    transition: all 0.3s ease;
  }

  .rtl footer .bg-white\/10:hover {
    transform: translateX(-2px) scale(1.05); /* Move left in RTL */
    background-color: rgba(122, 193, 67, 0.2) !important;
  }

  /* Brands slider mobile RTL (<640px) */
  @media (max-width: 639px) {
    .rtl .brands-slider-container {
      direction: rtl !important;
      position: relative !important;
      overflow: hidden !important;
      width: 100% !important;
      margin: 0 -10px !important;
      padding: 0 10px !important;
    }

    .rtl #brands-slider {
      direction: ltr !important; /* Keep LTR for proper flex behavior */
      display: flex !important;
      transition: transform 0.5s ease !important;
      width: 100% !important;
      height: auto !important;
      overflow: visible !important;
    }

    .rtl #brands-slider > div {
      direction: rtl !important;
      flex: 0 0 100% !important;
      min-width: 100% !important;
      width: 100% !important;
      display: block !important;
      position: relative !important;
      overflow: hidden !important;
    }

    .rtl #brands-slider .brands-grid {
      direction: rtl !important;
      display: grid !important;
      grid-template-columns: repeat(2, 1fr) !important;
      gap: 16px !important;
      padding: 0 1rem !important;
      width: 100% !important;
    }

    .rtl #brands-slider .brand-card {
      direction: rtl !important;
      text-align: center !important;
      background: var(--card-bg) !important;
      border-radius: 12px !important;
      padding: 1.5rem !important;
      box-shadow: 0 4px 12px var(--card-shadow) !important;
      transition: all 0.3s ease !important;
      position: relative !important;
      overflow: hidden !important;
    }

    .rtl #brands-slider .brand-card:hover {
      transform: translateY(-4px) scale(1.02) !important;
      box-shadow: 0 12px 24px var(--card-shadow) !important;
    }

    .rtl #brands-slider .brand-logo {
      max-width: 120px !important;
      max-height: 60px !important;
      object-fit: contain !important;
      margin: 0 auto !important;
      transition: transform 0.3s ease !important;
    }

    .rtl #brands-slider .brand-card:hover .brand-logo {
      transform: scale(1.1) !important;
    }

    .rtl .brands-slider-container .slider-btn {
      position: absolute !important;
      top: 50% !important;
      transform: translateY(-50%) !important;
      z-index: 10 !important;
      width: 40px !important;
      height: 40px !important;
      border-radius: 50% !important;
      background: var(--fd-green) !important;
      color: white !important;
      border: none !important;
      cursor: pointer !important;
      transition: all 0.3s ease !important;
      display: flex !important;
      align-items: center !important;
      justify-content: center !important;
      font-size: 16px !important;
    }

    .rtl .brands-slider-container .slider-btn:hover {
      background: var(--fd-green) !important;
      transform: translateY(-50%) scale(1.1) !important;
    }

    /* In RTL, prev/next swap sides */
    .rtl .brands-slider-container #brands-prev {
      right: 10px !important;
      left: auto !important;
    }

    .rtl .brands-slider-container #brands-next {
      left: 10px !important;
      right: auto !important;
    }

    .rtl .brands-slider-container .brands-dots {
      direction: ltr !important; /* LTR so dots render left-to-right regardless of page language */
      display: flex !important;
      justify-content: center !important;
      gap: 8px !important;
      margin-top: 1rem !important;
      padding: 0 1rem !important;
    }

    .rtl .brands-slider-container .brands-dots .brands-dot {
      width: 8px !important;
      height: 8px !important;
      border-radius: 50% !important;
      background: var(--border-light) !important;
      border: none !important;
      cursor: pointer !important;
      transition: all 0.3s ease !important;
      direction: ltr !important;
    }

    .rtl .brands-slider-container .brands-dots .brands-dot.active {
      background: var(--fd-green) !important;
      width: 24px !important;
      border-radius: 4px !important;
    }

    .rtl .brands-slider-container .brands-dots .brands-dot:hover {
      background: var(--fd-gray) !important;
    }
  }

  /* Brands slider RTL initialization (<640px) */
  @media (max-width: 639px) {
    html[lang="ar"] .brands-slider-container {
      direction: rtl !important;
    }

    html[lang="ar"] #brands-slider {
      direction: ltr !important;
    }

    html[lang="ar"] #brands-slider > div {
      direction: rtl !important;
    }

    html[lang="ar"] #brands-slider .brands-grid {
      direction: rtl !important;
    }

    html[lang="ar"] #brands-slider .brand-card {
      direction: rtl !important;
    }

    html[lang="ar"] .brands-slider-container .brands-dots {
      direction: ltr !important;
    }

    html[lang="ar"] .brands-slider-container .brands-dot {
      direction: ltr !important;
    }
  }

  @media (max-width: 480px) {
    html[lang="ar"] .arabic-font {
      font-size: 0.9em !important; /* Even smaller for very small screens */
    }
  }

  /* Footer RTL animations */
  .rtl footer .animate-pulse {
    animation: pulseRTL 2s ease-in-out infinite;
  }

  @keyframes pulseRTL {
    0%,
    100% {
      opacity: 1;
      transform: scale(1);
    }
    50% {
      opacity: 0.7;
      transform: scale(1.1) translateX(-2px); /* Pulse left in RTL */
    }
  }

  .rtl footer .logo-image {
    transition: all 0.3s ease;
  }

  .rtl footer .logo-image:hover {
    transform: translateX(-4px) rotate(-2deg); /* Move left and rotate in RTL */
  }

  .rtl footer #scrollToTop {
    left: 1rem !important; /* Move to left side in RTL */
    right: auto !important;
  }

  .rtl footer #scrollToTop:hover {
    transform: translateY(-4px) scale(1.1) translateX(-2px) !important; /* Move left in RTL */
  }

  .rtl footer #scrollToTop:hover i {
    transform: rotate(180deg); /* Flip arrow in RTL */
  }

  .rtl footer a:focus-visible {
    outline: 2px solid var(--fd-green);
    outline-offset: 2px;
    transform: translateX(-2px); /* Move left on focus in RTL */
  }

  .rtl footer .rounded-lg:focus-visible,
  .rtl footer .w-12.h-12:focus-visible,
  .rtl footer .w-10.h-8:focus-visible {
    outline: 2px solid var(--fd-green);
    outline-offset: 2px;
    transform: translateX(-2px) scale(1.05); /* Move left and scale on focus in RTL */
  }

  .rtl footer .space-y-4 .w-10 i {
    transition: all 0.3s ease;
  }

  .rtl footer .space-y-4 .flex:hover .w-10 i {
    transform: scale(1.2) rotate(-5deg); /* Rotate left in RTL */
  }

  .rtl footer h3.arabic-font:hover {
    transform: translateX(-2px); /* Move left on hover in RTL */
  }

  .rtl footer h3.arabic-font:hover i {
    transform: scale(1.2) rotate(-10deg);
    color: var(--fd-green) !important;
  }

  .rtl footer .order-2.lg\:order-1 a:hover {
    transform: translateX(-2px); /* Move left in RTL */
  }

  .rtl footer .order-1.lg\:order-2:hover {
    transform: translateX(-2px); /* Move left in RTL */
  }

  /* RTL footer animations — tablet and mobile */
  @media (min-width: 768px) and (max-width: 1023px) {
    .rtl footer .grid.grid-cols-1.sm\:grid-cols-2.lg\:grid-cols-3 {
      animation: fadeInRTL 1s ease-out;
    }

    @keyframes fadeInRTL {
      from {
        opacity: 0;
        transform: translateX(-30px); /* Fade in from left in RTL */
      }
      to {
        opacity: 1;
        transform: translateX(0);
      }
    }
  }

  @media (max-width: 767px) {
    .rtl footer .space-y-4 .flex:nth-child(odd) {
      animation: slideInLeftMobile 0.6s ease-out;
    }

    .rtl footer .space-y-4 .flex:nth-child(even) {
      animation: slideInRightMobile 0.6s ease-out;
    }

    @keyframes slideInLeftMobile {
      from {
        opacity: 0;
        transform: translateX(-20px); /* From left in RTL */
      }
      to {
        opacity: 1;
        transform: translateX(0);
      }
    }

    @keyframes slideInRightMobile {
      from {
        opacity: 0;
        transform: translateX(20px); /* From right in RTL */
      }
      to {
        opacity: 1;
        transform: translateX(0);
      }
    }
  }
}

/* Mobile footer RTL (<1024px) */
@media (max-width: 1023px) {
  .rtl footer {
    direction: rtl;
  }

  /* Center all footer section headings on mobile */
  footer h3 {
    text-align: center !important;
    justify-content: center !important;
    align-items: center !important;
  }

  footer h3.arabic-font {
    text-align: center !important;
    direction: rtl;
  }

  footer h3.lang-en {
    text-align: center !important;
    direction: ltr;
  }

  /* Center header icons and text */
  footer h3 .flex {
    justify-content: center !important;
    align-items: center !important;
  }

  footer h3 i {
    margin-right: 0.5rem !important;
    margin-left: 0.5rem !important;
  }

  .rtl footer h3.arabic-font {
    text-align: center !important;
  }

  .rtl footer h3.lang-en {
    text-align: center !important;
  }

  .rtl footer h3 .flex {
    justify-content: center !important;
  }

  .rtl footer .text-center {
    text-align: center !important;
  }

  .rtl footer .arabic-font {
    text-align: center !important;
    direction: rtl;
  }

  /* Mobile footer grid - RTL content */
  .rtl footer .grid.grid-cols-1.sm\:grid-cols-2.lg\:grid-cols-3 {
    direction: rtl;
  }

  .rtl footer .grid.grid-cols-1.sm\:grid-cols-2.lg\:grid-cols-3 > div {
    text-align: right;
  }

  /* Mobile footer sections - RTL headers */
  .rtl footer h3.arabic-font {
    text-align: center !important;
    direction: rtl !important;
  }

  /* Mobile quick links - RTL fixes */
  .rtl footer .grid.grid-cols-2 {
    direction: rtl;
  }

  .rtl footer .grid.grid-cols-2 > div {
    text-align: right;
  }

  .rtl footer .grid.grid-cols-2 .fas.fa-chevron-left {
    transform: rotate(180deg);
  }

  .rtl footer .grid.grid-cols-2 .fas.fa-chevron-right {
    transform: rotate(180deg);
  }

  /* Mobile contact info - RTL fixes */
  .rtl footer .space-y-4 .flex {
    direction: rtl;
  }

  .rtl footer .space-y-4 .flex .flex-1 {
    text-align: right;
  }

  .rtl footer .space-y-4 .flex .ltr-content {
    direction: ltr;
    text-align: left;
  }

  /* Mobile social media - RTL fixes */
  .rtl footer .text-center {
    text-align: center !important;
  }

  .rtl footer .sm\:text-left {
    text-align: center !important;
  }

  .rtl footer .lg\:text-left {
    text-align: center !important;
  }

  .rtl footer .justify-center {
    justify-content: center !important;
  }

  .rtl footer .sm\:justify-start {
    justify-content: center !important;
  }

  .rtl footer .lg\:justify-start {
    justify-content: center !important;
  }

  /* Mobile footer bottom - RTL fixes */
  .rtl footer .flex.flex-col.lg\:flex-row {
    direction: rtl;
  }

  .rtl footer .flex.flex-col.lg\:flex-row > div {
    text-align: center;
  }

  .rtl footer .order-1.lg\:order-2 {
    text-align: center !important;
  }

  .rtl footer .order-1.lg\:order-2 .text-center {
    text-align: center !important;
  }

  .rtl footer .order-1.lg\:order-2 .lg\:text-right {
    text-align: center !important;
  }

  .rtl footer .order-1.lg\:order-2 .lg\:items-end {
    align-items: center !important;
  }

  .rtl footer .order-2.lg\:order-1 {
    text-align: center !important;
  }

  .rtl footer .order-2.lg\:order-1 .text-center {
    text-align: center !important;
  }

  .rtl footer .order-2.lg\:order-1 .lg\:text-left {
    text-align: center !important;
  }

  /* Mobile footer logo - RTL fixes */
  .rtl footer .flex.flex-col.md\:flex-row {
    direction: rtl;
  }

  .rtl footer .flex.flex-col.items-center {
    align-items: center;
  }

  .rtl footer .flex.flex-col.items-center .text-center {
    text-align: center !important;
  }

  /* Mobile vision badge - RTL fixes */
  .rtl footer .flex.items-center.gap-2 {
    direction: rtl;
  }

  /* Mobile registration info - RTL fixes */
  .rtl footer .border-t.border-white\/20 {
    text-align: center;
  }

  .rtl footer .border-t.border-white\/20 .arabic-font {
    text-align: center !important;
  }
}

/* Extra-small mobile devices (≤480px) - Further minimization */
@media (max-width: 480px) {
  /* Ultra-compact typography */
  h1 {
    font-size: 1.375rem !important;
  }
  h2 {
    font-size: 1.125rem !important;
  }
  h3 {
    font-size: 1rem !important;
  }
  h4 {
    font-size: 0.9rem !important;
  }

  p,
  .text-content,
  .description {
    font-size: 0.8rem !important;
  }

  small,
  .text-sm,
  .caption,
  .meta {
    font-size: 0.7rem !important;
  }

  /* Ultra-compact hero */
  .hero-title {
    font-size: 1.5rem !important;
    margin-bottom: 0.625rem !important;
  }

  .hero-subtitle {
    font-size: 0.8rem !important;
    margin-bottom: 0.875rem !important;
  }

  /* Ultra-compact buttons */
  .btn {
    padding: 0.5rem 0.875rem !important;
    font-size: 0.75rem !important;
    min-height: 36px !important;
  }

  .btn-primary .arrow-icon {
    width: 18px !important;
    height: 18px !important;
  }

  /* Ultra-compact sections */
  section[class*="pt-"][class*="pb-"],
  .py-16,
  .py-20,
  .py-24 {
    padding-top: 1.5rem !important;
    padding-bottom: 1.5rem !important;
  }

  /* Ultra-compact highlights */
  .highlight-item {
    padding: 0.5rem 0.375rem !important;
  }

  .highlight-item .w-24 {
    width: 2rem !important;
    height: 2rem !important;
  }

  .highlight-item .text-4xl {
    font-size: 1.25rem !important;
  }

  .highlight-item .text-sm {
    font-size: 0.65rem !important;
  }

  /* Ultra-compact brands */
  .brand-item {
    min-height: 50px !important;
    height: 60px !important;
    padding: 0.25rem !important;
  }

  .brand-item img {
    height: 24px !important;
    max-height: 24px !important;
  }

  /* Ultra-compact gallery */
  .gallery-card {
    width: 260px !important;
    padding: 0.5rem !important;
  }

  .gallery-card h2 {
    font-size: 1.125rem !important;
  }

  .gallery-card h3 {
    font-size: 0.7rem !important;
  }

  .gallery-card img,
  .image-slider-container {
    height: 120px !important;
  }

  /* Ultra-compact spacing */
  .gap-6,
  .gap-8 {
    gap: 0.5rem !important;
  }
  .gap-4,
  .gap-5 {
    gap: 0.375rem !important;
  }
  .gap-3 {
    gap: 0.25rem !important;
  }

  .mb-8,
  .mb-10,
  .mb-12 {
    margin-bottom: 0.75rem !important;
  }
  .mb-6,
  .mb-7 {
    margin-bottom: 0.5rem !important;
  }
  .mb-4,
  .mb-5 {
    margin-bottom: 0.375rem !important;
  }

  .mt-8,
  .mt-10,
  .mt-12 {
    margin-top: 0.75rem !important;
  }
  .mt-6,
  .mt-7 {
    margin-top: 0.5rem !important;
  }
  .mt-4,
  .mt-5 {
    margin-top: 0.375rem !important;
  }
}

/* Font system — icon elements are excluded from the font-family overrides below */
body,
p,
span,
div,
h1,
h2,
h3,
h4,
h5,
h6,
a,
button,
input,
textarea,
select {
  font-family: var(--font-en-primary) !important;
}

html[lang="ar"] body,
html[lang="ar"] p,
html[lang="ar"] span,
html[lang="ar"] div,
html[lang="ar"] h1,
html[lang="ar"] h2,
html[lang="ar"] h3,
html[lang="ar"] h4,
html[lang="ar"] h5,
html[lang="ar"] h6,
html[lang="ar"] a,
html[lang="ar"] button,
html[lang="ar"] input,
html[lang="ar"] textarea,
html[lang="ar"] select {
  font-family: var(--font-ar-primary) !important;
}

/* Icons Preservation - CRITICAL: Do not affect icons */
i,
.fa,
.fas,
.far,
.fab,
.fad,
.fass,
.fasr,
.fasl,
.fa-solid,
.fa-regular,
.fa-brands,
.fa-duotone,
.fa-sharp,
.fa-sharp-solid,
.fa-sharp-regular,
.fa-sharp-light {
  font-family: "Font Awesome 6 Free" !important;
  font-weight: 900 !important;
}

/* Social Icons Specific Preservation */
.social-icon i,
.social-link i,
.fa-instagram,
.fa-tiktok,
.fa-snapchat-ghost,
.fa-whatsapp,
.fa-facebook,
.fa-twitter,
.fa-linkedin,
.fa-youtube,
.fa-pinterest,
.fa-reddit {
  font-family: "Font Awesome 6 Brands" !important;
  font-weight: 400 !important;
}

/* Solid Icons Preservation */
.fas,
.fa-solid {
  font-family: "Font Awesome 6 Free" !important;
  font-weight: 900 !important;
}

/* Regular Icons Preservation */
.far,
.fa-regular {
  font-family: "Font Awesome 6 Free" !important;
  font-weight: 400 !important;
}

/* Brand Icons Preservation */
.fab,
.fa-brands {
  font-family: "Font Awesome 6 Brands" !important;
  font-weight: 400 !important;
}

/* Social Icons Visibility and Styling */
.social-icon {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  visibility: visible !important;
  opacity: 1 !important;
}

.social-icon i,
.social-link i {
  display: block !important;
  visibility: visible !important;
  opacity: 1 !important;
  font-style: normal !important;
  font-variant: normal !important;
  text-rendering: auto !important;
  line-height: 1 !important;
}

/* Footer Social Icons */
footer .social-icon i,
footer .social-link i {
  color: inherit !important;
}

/* Dark Mode Social Icons */
.dark .social-icon i,
.dark .social-link i {
  color: var(--fd-green) !important;
}

/* Social Icon Hover Effects */
.social-link:hover .social-icon i {
  color: #ffffff !important;
  transform: scale(1.1) !important;
}

/* Specific Social Icon Colors */
.social-item:nth-child(1) .social-link:hover .social-icon i {
  color: #000000 !important; /* Snapchat yellow */
}

.social-item:nth-child(2) .social-link:hover .social-icon i {
  color: #ffffff !important; /* TikTok black */
}

.social-item:nth-child(3) .social-link:hover .social-icon i {
  color: #ffffff !important; /* Instagram gradient */
}

.social-item:nth-child(4) .social-link:hover .social-icon i {
  color: #ffffff !important; /* WhatsApp green */
}

/* Enhanced Arabic Typography */
.arabic-font {
  font-family: var(--font-ar-primary) !important;
  font-weight: var(--font-medium) !important;
  line-height: var(--line-height-relaxed) !important;
  letter-spacing: var(--letter-spacing-normal) !important;
}

/* Enhanced English Typography */
.english-font {
  font-family: var(--font-en-primary) !important;
  font-weight: var(--font-normal) !important;
  line-height: var(--line-height-normal) !important;
  letter-spacing: var(--letter-spacing-tight) !important;
}

/* Section Headers Enhancement */
.section-title {
  font-family: var(--font-en-display) !important;
  font-weight: var(--font-bold) !important;
  line-height: var(--line-height-tight) !important;
  letter-spacing: var(--letter-spacing-tight) !important;
}

html[lang="ar"] .section-title {
  font-family: var(--font-ar-display) !important;
  font-weight: var(--font-extrabold) !important;
  line-height: var(--line-height-tight) !important;
  letter-spacing: var(--letter-spacing-normal) !important;
}

/* Card Typography Enhancement */
.card-title {
  font-family: var(--font-en-display) !important;
  font-weight: var(--font-semibold) !important;
  line-height: var(--line-height-tight) !important;
  letter-spacing: var(--letter-spacing-tight) !important;
}

html[lang="ar"] .card-title {
  font-family: var(--font-ar-display) !important;
  font-weight: var(--font-bold) !important;
  line-height: var(--line-height-tight) !important;
  letter-spacing: var(--letter-spacing-normal) !important;
}

.card-content {
  font-family: var(--font-en-primary) !important;
  font-weight: var(--font-normal) !important;
  line-height: var(--line-height-normal) !important;
  letter-spacing: var(--letter-spacing-normal) !important;
}

html[lang="ar"] .card-content {
  font-family: var(--font-ar-primary) !important;
  font-weight: var(--font-normal) !important;
  line-height: var(--line-height-relaxed) !important;
  letter-spacing: var(--letter-spacing-normal) !important;
}

/* Navigation Typography Enhancement */
.nav-link {
  font-family: var(--font-en-primary) !important;
  font-weight: var(--font-medium) !important;
  line-height: var(--line-height-normal) !important;
  letter-spacing: var(--letter-spacing-tight) !important;
}

html[lang="ar"] .nav-link {
  font-family: var(--font-ar-primary) !important;
  font-weight: var(--font-semibold) !important;
  line-height: var(--line-height-normal) !important;
  letter-spacing: var(--letter-spacing-normal) !important;
}

/* Button Typography Enhancement - Icons Preserved */
button,
.btn,
input[type="button"],
input[type="submit"] {
  font-family: var(--font-en-primary) !important;
  font-weight: var(--font-medium) !important;
  line-height: var(--line-height-normal) !important;
  letter-spacing: var(--letter-spacing-tight) !important;
}

html[lang="ar"] button,
html[lang="ar"] .btn,
html[lang="ar"] input[type="button"],
html[lang="ar"] input[type="submit"] {
  font-family: var(--font-ar-primary) !important;
  font-weight: var(--font-semibold) !important;
  line-height: var(--line-height-normal) !important;
  letter-spacing: var(--letter-spacing-normal) !important;
}

/* Form Typography Enhancement */
input,
textarea,
select {
  font-family: var(--font-en-primary) !important;
  font-weight: var(--font-normal) !important;
  line-height: var(--line-height-normal) !important;
  letter-spacing: var(--letter-spacing-normal) !important;
}

html[lang="ar"] input,
html[lang="ar"] textarea,
html[lang="ar"] select {
  font-family: var(--font-ar-primary) !important;
  font-weight: var(--font-normal) !important;
  line-height: var(--line-height-relaxed) !important;
  letter-spacing: var(--letter-spacing-normal) !important;
}

/* Footer Typography Enhancement */
footer {
  font-family: var(--font-en-primary) !important;
  font-weight: var(--font-normal) !important;
  line-height: var(--line-height-normal) !important;
  letter-spacing: var(--letter-spacing-normal) !important;
}

html[lang="ar"] footer {
  font-family: var(--font-ar-primary) !important;
  font-weight: var(--font-normal) !important;
  line-height: var(--line-height-relaxed) !important;
  letter-spacing: var(--letter-spacing-normal) !important;
}

footer h1,
footer h2,
footer h3,
footer h4,
footer h5,
footer h6 {
  font-family: var(--font-en-display) !important;
  font-weight: var(--font-bold) !important;
  line-height: var(--line-height-tight) !important;
  letter-spacing: var(--letter-spacing-tight) !important;
}

html[lang="ar"] footer h1,
html[lang="ar"] footer h2,
html[lang="ar"] footer h3,
html[lang="ar"] footer h4,
html[lang="ar"] footer h5,
html[lang="ar"] footer h6 {
  font-family: var(--font-ar-display) !important;
  font-weight: var(--font-extrabold) !important;
  line-height: var(--line-height-tight) !important;
  letter-spacing: var(--letter-spacing-normal) !important;
}

/* News Typography Enhancement */
.news-title {
  font-family: var(--font-en-display) !important;
  font-weight: var(--font-bold) !important;
  line-height: var(--line-height-tight) !important;
  letter-spacing: var(--letter-spacing-tight) !important;
}

html[lang="ar"] .news-title {
  font-family: var(--font-ar-display) !important;
  font-weight: var(--font-extrabold) !important;
  line-height: var(--line-height-tight) !important;
  letter-spacing: var(--letter-spacing-normal) !important;
}

.news-content {
  font-family: var(--font-en-primary) !important;
  font-weight: var(--font-normal) !important;
  line-height: var(--line-height-normal) !important;
  letter-spacing: var(--letter-spacing-normal) !important;
}

html[lang="ar"] .news-content {
  font-family: var(--font-ar-primary) !important;
  font-weight: var(--font-medium) !important;
  line-height: var(--line-height-relaxed) !important;
  letter-spacing: var(--letter-spacing-normal) !important;
}

/* Monospace Enhancement - Icons Preserved */
.ltr-content,
.font-mono,
code,
pre {
  font-family: var(--font-mono) !important;
  font-weight: var(--font-normal) !important;
  letter-spacing: var(--letter-spacing-wide) !important;
}

/* Hero Title Enhancement */
.hero-title {
  font-family: var(--font-en-display) !important;
  font-weight: var(--font-extrabold) !important;
  line-height: var(--line-height-tight) !important;
  letter-spacing: var(--letter-spacing-tight) !important;
}

html[lang="ar"] .hero-title {
  font-family: var(--font-ar-display) !important;
  font-weight: var(--font-black) !important;
  line-height: var(--line-height-tight) !important;
  letter-spacing: var(--letter-spacing-normal) !important;
}

/* Responsive Font Scaling */
@media (max-width: 640px) {
  html[lang="ar"] .arabic-font {
    font-size: 0.95em !important; /* Slightly smaller for better mobile readability */
  }

  html[lang="ar"] body {
    line-height: var(--line-height-relaxed) !important;
  }

  html[lang="ar"] .section-title {
    font-size: 0.9em !important;
  }
}

@media (max-width: 480px) {
  html[lang="ar"] .arabic-font {
    font-size: 0.9em !important; /* Even smaller for very small screens */
  }
}

/* ═══ INDEX PAGE GLOBAL STYLES (extracted from inline <style>) ═══ */

      /* Immediate RTL Navigation Alignment - Prevent Flicker */
      html[lang="ar"] #mainHeader nav {
        direction: rtl !important;
        text-align: right !important;
      }
      
      html[lang="ar"] #mainHeader .hidden.lg:flex {
        direction: rtl !important;
        justify-content: flex-end !important;
      }
      
      html[lang="ar"] .nav-link {
        direction: rtl !important;
        text-align: right !important;
        background-position: right bottom !important;
      }
      
      html[lang="ar"] .mobile-nav-container {
        direction: rtl !important;
      }
      
      html[lang="ar"] .mobile-nav-container .nav-link {
        direction: rtl !important;
        text-align: right !important;
        justify-content: flex-start !important;
      }

      /* RTL support */
      .rtl {
        direction: rtl;
      }
      .rtl .flex {
        flex-direction: row-reverse;
      }
      .rtl .text-right {
        text-align: left;
      }
      .rtl .text-left {
        text-align: right;
      }

      * {
        font-family: "Inter", ui-sans-serif, system-ui, sans-serif;
        transition:
          background-color 0.3s ease,
          border-color 0.3s ease;
      }

      /* Enhanced Dark Mode Font Styling */
      .dark {
        /* Improved font rendering for dark backgrounds */
        -webkit-font-smoothing: antialiased;
        -moz-osx-font-smoothing: grayscale;
        text-rendering: optimizeLegibility;
        
        /* Enhanced contrast for better readability */
        font-variation-settings: "opsz" auto;
      }

      /* Dark mode specific font optimizations */
      .dark body {
        font-weight: 400; /* Slightly bolder for better contrast */
        letter-spacing: 0.01em; /* Minimal letter spacing for clarity */
      }

      /* Dark mode heading enhancements */
      .dark h1,
      .dark h2,
      .dark h3,
      .dark h4,
      .dark h5,
      .dark h6 {
        font-weight: 600; /* Reduced weight for softer appearance */
        letter-spacing: 0.02em; /* Slightly increased spacing */
        text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1); /* Subtle shadow for depth */
      }

      .dark h1 {
        font-weight: 700; /* Keep h1 bold */
        letter-spacing: -0.02em; /* Tighter spacing for large text */
      }

      .dark h2 {
        font-weight: 600;
        letter-spacing: -0.01em;
      }

      /* Dark mode paragraph and text optimizations */
      .dark p,
      .dark .text-content,
      .dark .description {
        font-weight: 400;
        line-height: 1.65; /* Increased line height for readability */
        color: rgba(241, 245, 249, 0.95); /* Slightly reduced opacity for comfort */
      }

      /* Dark mode small text optimizations */
      .dark small,
      .dark .text-sm,
      .dark .caption,
      .dark .meta {
        font-weight: 500; /* Slightly bolder for small text */
        color: rgba(203, 213, 225, 0.9); /* Better contrast for small text */
      }

      /* Dark mode link enhancements */
      .dark a {
        font-weight: 500;
        text-decoration: none;
        transition: all 0.2s ease;
      }

      .dark a:hover {
        font-weight: 600;
      }

      /* Dark mode button text optimizations */
      .dark button,
      .dark .btn {
        font-weight: 600;
        letter-spacing: 0.01em;
      }

      /* Dark mode navigation text */
      .dark nav a,
      .dark .nav-link {
        font-weight: 500;
        letter-spacing: 0.01em;
      }

      /* Dark mode card text */
      .dark .card-title,
      .dark .card-header {
        font-weight: 600;
        letter-spacing: 0.01em;
      }

      .dark .card-text,
      .dark .card-content {
        font-weight: 400;
        line-height: 1.6;
      }

      /* Dark mode hero section specific fonts */
      .dark .hero-title {
        font-weight: 800;
        letter-spacing: -0.03em;
        text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
      }

      .dark .hero-subtitle {
        font-weight: 400;
        letter-spacing: 0.02em;
        text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
      }

      /* Dark mode brand section fonts */
      .dark .brand-item {
        font-weight: 500;
      }

      /* Dark mode news section fonts */
      .dark .news-title {
        font-weight: 600;
        letter-spacing: 0.01em;
      }

      .dark .news-date {
        font-weight: 400;
        color: rgba(148, 163, 184, 0.8);
      }

      /* Dark mode footer fonts */
      .dark footer {
        font-weight: 400;
      }

      .dark .footer-link {
        font-weight: 400;
        color: rgba(203, 213, 225, 0.9);
      }

      .dark .footer-link:hover {
        font-weight: 500;
        color: var(--fd-white);
      }

      /* Dark mode input and form elements */
      .dark input,
      .dark textarea,
      .dark select {
        font-weight: 400;
        letter-spacing: 0.01em;
      }

      /* Dark mode quote and emphasis */
      .dark blockquote {
        font-weight: 400;
        font-style: italic;
        color: rgba(241, 245, 249, 0.9);
      }

      .dark em,
      .dark .emphasis {
        font-weight: 500;
      }

      /* Dark mode code and pre */
      .dark code,
      .dark pre {
        font-weight: 400;
        font-family: "Inter", monospace;
        background: rgba(30, 41, 59, 0.5);
      }

      /* Dark mode list items */
      .dark li,
      .dark .list-item {
        font-weight: 400;
        line-height: 1.6;
      }

      /* Dark mode badge and tag text */
      .dark .badge,
      .dark .tag {
        font-weight: 600;
        letter-spacing: 0.02em;
      }

      /* Dark mode table text */
      .dark table {
        font-weight: 400;
      }

      .dark th {
        font-weight: 600;
        letter-spacing: 0.01em;
      }

      .dark td {
        font-weight: 400;
      }

      /* Dark mode alert and notification text */
      .dark .alert,
      .dark .notification {
        font-weight: 500;
      }

      /* Dark mode modal text */
      .dark .modal-title {
        font-weight: 600;
        letter-spacing: 0.01em;
      }

      .dark .modal-content {
        font-weight: 400;
        line-height: 1.6;
      }

      body {
        background-color: var(--background);
        color: var(--text-primary);
      }

      @keyframes fadeIn {
        from {
          opacity: 0;
        }
        to {
          opacity: 1;
        }
      }

      @keyframes slideUp {
        from {
          transform: translateY(20px);
          opacity: 0;
        }
        to {
          transform: translateY(0);
          opacity: 1;
        }
      }

      @keyframes scale {
        from {
          transform: scale(0.95);
        }
        to {
          transform: scale(1);
        }
      }

      @keyframes pulseGlow {
        0%,
        100% {
          box-shadow: 0 0 20px rgba(122, 193, 67, 0.3);
        }
        50% {
          box-shadow: 0 0 30px rgba(122, 193, 67, 0.6);
        }
      }

      /* Custom scrollbar */
      ::-webkit-scrollbar {
        width: 10px;
      }

      ::-webkit-scrollbar-track {
        background: var(--border-light);
      }

      ::-webkit-scrollbar-thumb {
        background: var(--fd-green);
        border-radius: 5px;
      }

      .dark ::-webkit-scrollbar-thumb {
        background: var(--fd-green);
      }

      /* Image modal styles */
      .image-modal {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0, 0, 0, 0.9);
        z-index: 1000;
        animation: fadeIn 0.3s ease-out;
      }

      .modal-content {
        max-width: 90%;
        max-height: 90%;
        animation: scale 0.3s ease-out;
      }

      .modal-open {
        overflow: hidden;
      }

      /* Theme transition */
      .theme-transition {
        transition:
          background-color 0.3s ease,
          color 0.3s ease;
      }

      /* Card styles with CSS variables */
      .card {
        background-color: var(--card-bg);
        border: 1px solid var(--border);
        box-shadow: 0 4px 6px var(--card-shadow);
      }

      .card-hover:hover {
        transform: translateY(-5px);
        box-shadow: 0 20px 25px -5px var(--card-shadow);
      }

      /* Gradient backgrounds */
      .gradient-bg {
        background: linear-gradient(
          135deg,
          var(--fd-green) 0%,
          var(--fd-navy) 100%
        );
      }

      .gradient-text {
        background: linear-gradient(135deg, var(--fd-green), var(--fd-taupe));
        -webkit-background-clip: text;
        background-clip: text;
        -webkit-text-fill-color: transparent;
      }

      /* Hide scrollbar for modal */
      .no-scrollbar {
        -ms-overflow-style: none;
        scrollbar-width: none;
      }
      .no-scrollbar::-webkit-scrollbar {
        display: none;
      }

      /* === ENHANCED HERO (clean layout with minimal animations) === */
      .hero {
        position: relative;
        height: 90vh;
        max-height: 800px;
        overflow: hidden;
        background-color: var(--fd-dark);
      }
      .hero-video {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        object-fit: cover;
        z-index: 0;
        filter: brightness(0.85) contrast(1.1);
        transform: scale(1.05);
      }
      .hero-overlay {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: linear-gradient(
          135deg,
          rgba(27, 33, 71, 0.2) 0%,
          rgba(27, 33, 71, 0.4) 50%,
          rgba(27, 33, 71, 0.3) 100%
        );
        z-index: 1;
      }
      .hero-content {
        position: relative;
        z-index: 2;
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        justify-content: flex-end;
        height: 100%;
        text-align: left;
        color: var(--fd-white);
        padding: 80px 60px;
        margin-left: 40px;
      }

      /* English language - bottom left positioning */
      html[lang="en"] .hero-content {
        align-items: flex-start;
        text-align: left;
      }

      /* Arabic language - bottom right positioning */
      html[lang="ar"] .hero-content {
        align-items: flex-end;
        text-align: right;
      }
      .hero-text {
        margin-bottom: 4px;
        width: 100%;
        max-width: 600px;
      }
      .hero-title {
        font-size: 3.4rem;
        font-weight: 700;
        max-width: 600px;
        margin-bottom: 24px;
        color: var(--fd-white);
        line-height: 1.05;
        letter-spacing: -0.03em;
        font-family:
          "Inter",
          system-ui,
          -apple-system,
          sans-serif;
      }
      .light .hero-title {
        color: var(--fd-white);
        text-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
      }
      .dark .hero-title {
        color: var(--fd-white);
      }
      @media (min-width: 1024px) {
        .hero-title {
          white-space: nowrap;
          max-width: none;
          font-size: clamp(1.8rem, 3vw, 3.4rem) !important;
        }
        .hero-subtitle {
          white-space: nowrap;
          max-width: none !important;
          font-size: clamp(0.85rem, 1.35vw, 1.25rem) !important;
        }
      }
      .hero-subtitle {
        font-size: 1.25rem;
        font-weight: 400;
        max-width: 580px;
        margin: 0 auto;
        opacity: 0.9;
        line-height: 1.6;
      }
      .light .hero-subtitle {
        color: var(--fd-white);
        opacity: 0.85;
        text-shadow: 0 1px 4px rgba(0, 0, 0, 0.2);
      }
      .dark .hero-subtitle {
        color: var(--fd-white);
        opacity: 0.9;
      }
      .hero-actions {
        display: flex;
        gap: 16px;
        margin-top: 28px;
        flex-wrap: wrap;
        justify-content: flex-start;
        width: 100%;
        transition: transform 0.3s ease;
      }
      .hero-actions:hover {
        transform: translateX(8px);
      }

      /* English language - left aligned actions */
      html[lang="en"] .hero-actions {
        justify-content: flex-start;
      }

      /* Arabic language - right aligned actions */
      html[lang="ar"] .hero-actions {
        justify-content: flex-end;
      }
      html[lang="ar"] .hero-actions:hover {
        transform: translateX(-8px);
      }
      .btn {
        display: inline-flex;
        align-items: center;
        gap: 8px;
        padding: 18px 36px;
        border-radius: 50px;
        font-weight: 600;
        text-decoration: none;
        font-size: 1.05rem;
        border: 2px solid transparent;
        transition: all 0.2s ease;
        position: relative;
      }
      .btn-primary {
        background: rgba(255, 255, 255, 0.08);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        border: 1px solid rgba(255, 255, 255, 0.15);
        color: var(--fd-white);
        position: relative;
        overflow: hidden;
        transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
        box-shadow:
          0 8px 32px rgba(31, 38, 135, 0.12),
          0 4px 8px rgba(31, 38, 135, 0.08),
          inset 0 1px 0 rgba(255, 255, 255, 0.08),
          inset 0 -1px 0 rgba(122, 193, 67, 0.15);
      }
      .btn-primary::before {
        content: "";
        position: absolute;
        top: 0;
        left: 0;
        width: 0%;
        height: 100%;
        background: linear-gradient(
          90deg,
          var(--fd-green),
          rgba(122, 193, 67, 0.8)
        );
        transition: width 0.6s cubic-bezier(0.23, 1, 0.32, 1);
        z-index: -1;
        border-radius: 50px;
      }
      .btn-primary:hover {
        background: rgba(255, 255, 255, 0.12);
        backdrop-filter: blur(25px);
        -webkit-backdrop-filter: blur(25px);
        border: 1px solid rgba(122, 193, 67, 0.25);
        transform: translateY(-3px) scale(1.02);
        box-shadow:
          0 12px 40px rgba(122, 193, 67, 0.18),
          0 6px 16px rgba(122, 193, 67, 0.12),
          inset 0 1px 0 rgba(255, 255, 255, 0.12),
          inset 0 -1px 0 rgba(122, 193, 67, 0.25);
      }
      .btn-primary:hover::before {
        width: 100%;
      }
      .btn-primary .arrow-icon {
        color: #ffffff;
        padding: 10px;
        border-radius: 50%;
        margin-left: 12px;
        transition: all 0.3s ease;
        z-index: 2;
        position: relative;
        font-weight: 300;
        background: transparent;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 36px;
        height: 36px;
      }
      .btn-primary:hover .arrow-icon {
        background: rgba(255, 255, 255, 0.95);
        color: var(--fd-green);
        transform: translateX(2px);
        box-shadow: 0 3px 12px rgba(0, 0, 0, 0.15);
      }
      .btn-secondary {
        background-color: transparent;
        color: var(--fd-white);
        border-color: var(--fd-white);
      }
      .btn-secondary:hover {
        background-color: var(--fd-white);
        color: var(--fd-navy);
      }
      .hero-stats {
        display: flex;
        gap: 60px;
        flex-wrap: wrap;
        justify-content: center;
      }
      .stat-item {
        display: flex;
        flex-direction: column;
        align-items: center;
        text-align: center;
      }
      .stat-number {
        font-size: 2.5rem;
        font-weight: 700;
        color: var(--fd-green);
        margin-bottom: 8px;
      }
      .stat-label {
        font-size: 0.9rem;
        font-weight: 500;
        text-transform: uppercase;
        letter-spacing: 1px;
        opacity: 0.9;
      }
      .scroll-indicator {
        position: absolute;
        bottom: 30px;
        left: 50%;
        transform: translateX(-50%);
        z-index: 3;
        cursor: pointer;
        animation: upDown 2s ease-in-out infinite;
      }
      .scroll-indicator i {
        font-size: 1.5rem;
        color: var(--fd-white);
        opacity: 0.7;
      }
      .light .scroll-indicator i {
        opacity: 0.6;
        text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
      }
      .dark .scroll-indicator i {
        opacity: 0.7;
      }
      .scroll-indicator:hover i {
        opacity: 1;
      }

      @keyframes upDown {
        0%,
        100% {
          transform: translateX(-50%) translateY(0);
        }
        50% {
          transform: translateX(-50%) translateY(-10px);
        }
      }

      /* Hero Video Styles */
      .hero-video {
        width: 100%;
        height: 100%;
        object-fit: cover;
      }

      @media screen and (max-width: 1024px) {
        .hero-video {
          width: 100%;
          height: 100%;
          object-fit: cover;
        }

        #hero-video {
          width: 100%;
          height: 100%;
          display: flex;
          justify-content: center;
          align-items: center;
          overflow: hidden;
          aspect-ratio: 5 / 4;
        }
      }

      @media screen and (max-width: 767px) {
        .hero-video {
          width: 100%;
          height: 100%;
          object-fit: cover;
        }

        #hero-video {
          width: 100%;
          height: 100%;
          display: flex;
          justify-content: center;
          align-items: center;
          overflow: hidden;
          aspect-ratio: 4 / 5;
        }
      }

      /* Enhanced animations inspired by alfuttaim */
      .hero-block-section {
        animation: fadeIn 1s ease-out;
      }

      .hero-media-container {
        position: relative;
        overflow: hidden;
      }

      .video-container {
        position: relative;
        overflow: hidden;
        border-radius: 1rem;
      }

      /* Hardware acceleration for smooth animations */
      .hero-video,
      .hero-media-container,
      .video-container {
        -webkit-backface-visibility: hidden;
        backface-visibility: hidden;
        transform: translateZ(0);
        will-change: transform;
        -webkit-font-smoothing: antialiased;
        -moz-osx-font-smoothing: grayscale;
      }

      /* Al-Futtaim Elementor button styling */
      .elementor-button {
        background-color: #ffffff;
        border: none;
        border-radius: 3px;
        padding: 12px 24px;
        font-size: 13px;
        font-weight: 500;
        color: #1a1a1a;
        text-decoration: none;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        transition: all 0.3s ease;
        box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
        cursor: pointer;
        font-family: inherit;
        line-height: 1.4;
      }

      .elementor-button:hover {
        background-color: #f5f5f5;
        transform: translateY(-1px);
        box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
      }

      .elementor-button.elementor-size-sm {
        padding: 10px 20px;
        font-size: 12px;
      }

      .elementor-button-wrapper {
        display: inline-block;
      }

      .elementor-button-content-wrapper {
        display: flex;
        align-items: center;
        gap: 8px;
      }

      .elementor-button-icon {
        display: flex;
        align-items: center;
      }

      .elementor-button-text {
        font-weight: 500;
      }

      /* Responsive video aspect ratios */
      @media screen and (max-width: 1024px) {
        .hero-video {
          width: 100%;
          height: 100%;
          object-fit: cover;
        }

        #hero-video {
          width: 100%;
          height: 100%;
          display: flex;
          justify-content: center;
          align-items: center;
          overflow: hidden;
          aspect-ratio: 5 / 4;
        }
      }

      @media screen and (max-width: 767px) {
        .hero-video {
          width: 100%;
          height: 100%;
          object-fit: cover;
        }

        #hero-video {
          width: 100%;
          height: 100%;
          display: flex;
          justify-content: center;
          align-items: center;
          overflow: hidden;
          aspect-ratio: 4 / 5;
        }

        .hero-content h1 {
          font-size: 2.8rem !important;
        }

        .hero-content p {
          font-size: 1.5rem !important;
        }
      }

      /* Enhanced hover effects */
      .card-hover {
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
      }

      .card-hover:hover {
        transform: translateY(-8px) scale(1.02);
        box-shadow: 0 25px 50px -12px var(--card-shadow);
      }

      /* Loading animation */
      @keyframes shimmer {
        0% {
          background-position: -1000px 0;
        }
        100% {
          background-position: 1000px 0;
        }
      }

      .shimmer {
        background: linear-gradient(
          90deg,
          transparent,
          rgba(255, 255, 255, 0.1),
          transparent
        );
        background-size: 1000px 100%;
        animation: shimmer 2s infinite;
      }

      /* Loading states for lazy loading */
      .loading {
        opacity: 0.6;
        filter: blur(2px);
        transition: all 0.3s ease;
      }

      .loaded {
        opacity: 1;
        filter: blur(0);
        transition: all 0.3s ease;
      }

      /* Enhanced mobile responsiveness */
      @media screen and (max-width: 768px) {
        .hero-video {
          transform: scale(1.05);
        }

        .card-hover:hover {
          transform: translateY(-4px) scale(1.01);
        }

        .category-card {
          transition: all 0.3s ease;
        }

        .stats-container {
          text-align: center;
        }
      }

      /* Touch interactions for mobile */
      @media (hover: none) and (pointer: coarse) {
        .category-card:active,
        .card-hover:active {
          transform: scale(0.98);
          transition: transform 0.1s ease;
        }

        .category-card:hover,
        .card-hover:hover {
          transform: none;
        }
      }

      /* Enhanced accessibility */
      .sr-only {
        position: absolute;
        width: 1px;
        height: 1px;
        padding: 0;
        margin: -1px;
        overflow: hidden;
        clip: rect(0, 0, 0, 0);
        white-space: nowrap;
        border: 0;
      }

      /* Focus indicators */
      *:focus-visible {
        outline: 2px solid var(--fd-green);
        outline-offset: 2px;
      }

      /* Reduced motion support */
      @media (prefers-reduced-motion: reduce) {
        *,
        *::before,
        *::after {
          animation-duration: 0.01ms !important;
          animation-iteration-count: 1 !important;
          transition-duration: 0.01ms !important;
          scroll-behavior: auto !important;
        }
      }

      /* High contrast mode support */
      @media (prefers-contrast: high) {
        .card {
          border: 2px solid var(--text-primary);
        }

        .gradient-text {
          -webkit-text-fill-color: var(--text-primary);
        }
      }

      /* Ripple effect for buttons */
      .ripple {
        position: absolute;
        border-radius: 50%;
        background: rgba(255, 255, 255, 0.6);
        transform: scale(0);
        animation: ripple-animation 0.6s ease-out;
        pointer-events: none;
      }

      @keyframes ripple-animation {
        to {
          transform: scale(4);
          opacity: 0;
        }
      }

      /* Enhanced button styles */
      button,
      .btn {
        position: relative;
        overflow: hidden;
      }

      /* Scroll progress bar */
      #scroll-progress {
        position: fixed;
        top: 0;
        left: 0;
        height: 3px;
        background: var(--fd-green);
        z-index: 9999;
        transition: width 0.2s ease;
      }

      /* === RESPONSIVE === */
      @media (max-width: 992px) {
        .hero-title {
          font-size: 2.3rem;
        }
        .hero-subtitle {
          font-size: 1.1rem;
        }
        .hero-actions {
          flex-direction: column;
          align-items: center;
          gap: 15px;
        }
        .btn {
          width: 100%;
          max-width: 250px;
        }
      }
      @media (max-width: 600px) {
        .header-container {
          gap: 8px;
        }
        .logo {
          font-size: 1.4rem;
        }
        .hero-title {
          font-size: 2.3rem;
        }
        .hero-subtitle {
          font-size: 1.1rem;
        }
        .hero-actions {
          gap: 12px;
        }
        .btn {
          padding: 14px 30px;
          font-size: 0.9rem;
        }
        .hero-stats {
          gap: 30px;
        }
        .stat-number {
          font-size: 1.8rem;
        }
        .stat-label {
          font-size: 0.8rem;
        }
        .highlights-grid {
          grid-template-columns: 1fr 1fr;
        }
      }

      /* Enhanced Mobile Header Styles */
      .lg\:hidden nav {
        position: relative;
        background: linear-gradient(
          135deg,
          var(--surface) 0%,
          var(--surface) 100%
        );
        backdrop-filter: blur(20px);
        border-bottom: 1px solid var(--border);
      }

      /* === NEWS SECTION === */
      .news {
        padding: 80px 0;
        background-color: var(--surface);
      }
      .news-header {
        display: flex;
        justify-content: space-between;
        align-items: center;
        margin-bottom: 48px;
        flex-wrap: wrap;
        gap: 16px;
      }
      .news-header h2 {
        font-size: 2.2rem;
        font-weight: 600;
        color: var(--fd-navy);
      }
      .view-more {
        text-decoration: none;
        font-weight: 600;
        color: var(--fd-green);
        border-bottom: 2px solid var(--fd-green);
        padding-bottom: 3px;
      }
      .news-grid {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
        gap: 30px;
      }
      .news-item {
        padding: 24px;
        background-color: var(--card-bg);
        border-left: 6px solid var(--fd-green);
        box-shadow: 0 4px 12px var(--card-shadow);
        transition:
          transform 0.2s,
          box-shadow 0.2s;
        cursor: pointer;
      }
      .news-item:hover {
        transform: translateY(-4px);
        box-shadow: 0 12px 24px var(--card-shadow);
      }
      .news-item .date {
        display: block;
        font-size: 0.8rem;
        color: var(--fd-gray);
        margin-bottom: 10px;
        font-weight: 500;
        letter-spacing: 0.3px;
      }
      .news-item p {
        font-weight: 600;
        color: var(--text-primary);
        line-height: 1.5;
      }

      /* News Slider Styles */
      .news-slider-container {
        position: relative;
        overflow: hidden;
        margin: 0 auto;
        padding: 0;
        max-width: 1200px;
      }
      
      .slider-controls {
        display: flex;
        gap: 12px;
        align-items: center;
      }
      
      .slider-btn {
        width: 40px;
        height: 40px;
        border-radius: 50%;
        border: 2px solid var(--fd-green);
        background: transparent;
        color: var(--fd-green);
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: center;
        transition: all 0.3s ease;
        font-size: 14px;
      }
      
      .slider-btn:hover {
        background: var(--fd-green);
        color: white;
        transform: scale(1.1);
      }
      
      .slider-btn:disabled {
        opacity: 0.3;
        cursor: not-allowed;
        transform: none;
      }
      
      #news-slider {
        display: flex;
        transition: transform 0.5s ease;
        gap: 20px;
        padding: 10px 0;
      }
      
      #news-slider .news-item {
        flex: 0 0 calc(50% - 10px);
        min-width: 280px;
        position: relative;
        z-index: 1;
        transition: all 0.3s ease;
      }

      #news-slider .news-item:hover {
        z-index: 10;
        transform: translateY(-4px) scale(1.02);
      }
      
      @media (max-width: 600px) {
        #news-slider .news-item {
          flex: 0 0 calc(100% - 0px);
          min-width: 100%;
        }
        
        .news-slider-container {
          margin: 0;
          padding: 0;
        }
        
        .slider-btn {
          width: 35px;
          height: 35px;
          font-size: 12px;
        }
      }

      
      /* === BRANDS SECTION === */
      .brand-item {
        background-color: var(--card-bg);
        border: 1px solid var(--border);
        border-radius: 0.75rem;
        padding: 1rem;
        text-align: center;
        position: relative;
        z-index: 1;
        transition: all 0.3s ease;
        cursor: pointer;
        min-height: 120px;
        height: 140px;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
      }
      
      .brand-item:hover {
        transform: translateY(-4px) scale(1.02);
        box-shadow: 0 12px 24px rgba(0, 0, 0, 0.15);
        border-color: var(--fd-green);
        z-index: 10;
      }

      .brand-item img {
        height: 56px !important;
        width: auto !important;
        max-width: 100%;
        max-height: 56px !important;
        object-fit: contain;
        transition: all 0.3s ease;
      }

      .brand-item:hover img {
        transform: scale(1.05);
      }

      /* Ensure consistent card dimensions */
      .brand-item::before {
        content: "";
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: linear-gradient(
          135deg,
          transparent 0%,
          rgba(122, 193, 67, 0.05) 100%
        );
        opacity: 0;
        transition: opacity 0.3s ease;
        pointer-events: none;
      }

      .brand-item:hover::before {
        opacity: 1;
      }

      /* Special handling for logos with different aspect ratios */
      .brand-item img[src*="sama"] {
        height: 60px !important;
        width: auto !important;
        max-height: 60px !important;
      }

      /* Responsive adjustments */
      @media (max-width: 768px) {
        .brand-item {
          min-height: 100px;
          height: 120px;
          padding: 0.75rem;
        }

        .brand-item img {
          height: 48px !important;
          max-height: 48px !important;
        }

        .brand-item img[src*="sama"] {
          height: 36px !important;
          max-height: 36px !important;
        }
      }

      /* Brands slider navigation enhancements */
      #brands-prev,
      #brands-next {
        z-index: 20;
        backdrop-filter: blur(10px);
        border: 1px solid rgba(255, 255, 255, 0.2);
      }

      #brands-prev:hover,
      #brands-next:hover {
        transform: translateY(-50%) translateX(-50%) scale(1.1);
        border-color: var(--fd-green);
      }

      #brands-next:hover {
        transform: translateY(-50%) translateX(50%) scale(1.1);
      }

      #brands-prev:disabled,
      #brands-next:disabled {
        opacity: 0.3;
        cursor: not-allowed;
      }

      #brands-prev:disabled {
        transform: translateY(-50%) translateX(-50%) scale(0.9);
      }

      #brands-next:disabled {
        transform: translateY(-50%) translateX(50%) scale(0.9);
      }

      /* Bottom dots styling */
      #brands-dots {
        z-index: 10;
      }

      #brands-dots button {
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
      }

      #brands-dots button:hover {
        transform: scale(1.2);
      }

      #brands-dots button:focus {
        outline: 2px solid var(--fd-green);
        outline-offset: 2px;
      }

      .brand-item h3 {
        font-size: 1rem;
        font-weight: 600;
        color: var(--text-primary);
        margin: 0;
      }

      /* === HIGHLIGHTS (stats) - Enhanced Clean Layout === */
      .highlight-item {
        padding: 2rem 1.5rem;
        border: 1px solid transparent;
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        border-radius: 1rem;
        background: linear-gradient(
          135deg,
          rgba(255, 255, 255, 0.8) 0%,
          rgba(255, 255, 255, 0.4) 100%
        );
        backdrop-filter: blur(10px);
        position: relative;
        overflow: hidden;
      }

      .highlight-item::before {
        content: "";
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        height: 3px;
        background: linear-gradient(
          90deg,
          var(--fd-green) 0%,
          var(--fd-navy) 100%
        );
        transform: scaleX(0);
        transition: transform 0.3s ease;
      }

      .highlight-item:hover::before {
        transform: scaleX(1);
      }

      .highlight-item:hover {
        border-color: var(--border);
        transform: translateY(-8px);
        box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
        background: linear-gradient(
          135deg,
          rgba(255, 255, 255, 0.95) 0%,
          rgba(255, 255, 255, 0.6) 100%
        );
      }

      .highlight-item:hover .w-24 {
        transform: scale(1.05);
        box-shadow: 0 10px 30px rgba(122, 193, 67, 0.2);
        border-color: var(--fd-green);
      }

      .highlight-item:hover i {
        transform: scale(1.1);
      }

      .highlight-item .w-24 {
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        position: relative;
        z-index: 2;
      }

      .highlight-item i {
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
      }

      /* Enhanced responsive adjustments for highlights */
      @media (max-width: 1024px) {
        .highlight-item {
          padding: 1.5rem;
        }
      }

      @media (max-width: 768px) {
        .highlight-item {
          padding: 1.25rem;
        }
        .highlight-item .text-4xl {
          font-size: 2.5rem;
        }
      }

      @media (max-width: 640px) {
        .highlight-item {
          padding: 1rem;
        }
        .highlight-item .text-4xl {
          font-size: 2.25rem;
        }
        .highlight-item .text-sm {
          font-size: 0.75rem;
        }
        .highlight-item .w-24 {
          width: 5rem;
          height: 5rem;
        }
      }

      /* Subtle animation for numbers on scroll */
      @keyframes countUp {
        from {
          opacity: 0;
          transform: translateY(10px);
        }
        to {
          opacity: 1;
          transform: translateY(0);
        }
      }

      .highlight-item .text-4xl {
        animation: countUp 0.6s ease-out;
      }

      /* Social Media Hover Colors */
      .hover\:bg-instagram:hover {
        background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
      }
      
      .hover\:bg-tiktok:hover {
        background: #000000;
      }
      
      .hover\:bg-snapchat:hover {
        background: #fffc00;
        color: #000000;
      }
      
      .hover\:bg-snapchat:hover i {
        color: #000000 !important;
      }

      /* Dark mode overrides */
      .dark .highlight-item {
        background: linear-gradient(135deg, var(--surface) 0%, var(--card-bg) 100%);
        backdrop-filter: blur(10px);
        border-color: var(--border);
      }

      .dark .highlight-item:hover {
        background: linear-gradient(135deg, var(--card-bg) 0%, var(--surface) 100%);
        border-color: var(--fd-green);
        box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
      }

      .dark .highlight-item .w-24 {
        background-color: var(--surface) !important;
        border-color: var(--border) !important;
      }

      .dark .highlight-item:hover .w-24 {
        border-color: var(--fd-green) !important;
      }

      .dark .global-sourcing,
      .dark .news-gallery {
        background-color: var(--surface) !important;
      }

      .dark .global-sourcing .bg-white,
      .dark .news-gallery .bg-white {
        background-color: var(--card-bg) !important;
        border-color: var(--border) !important;
      }

      .dark .global-sourcing .border-gray-200,
      .dark .news-gallery .border-gray-200 {
        border-color: var(--border) !important;
      }

      .dark .news-item {
        background-color: var(--card-bg);
        border-left-color: var(--fd-green);
        box-shadow: 0 4px 12px var(--card-shadow);
      }

      .dark .news-item:hover {
        box-shadow: 0 12px 24px var(--card-shadow);
      }

      .dark .brand-item {
        background-color: var(--card-bg);
        border-color: var(--border);
      }

      .dark .brand-item:hover {
        border-color: var(--fd-green);
        box-shadow: 0 12px 24px rgba(0, 0, 0, 0.3);
      }

      .dark .footer,
      .dark footer {
        background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%) !important;
      }

      .dark footer .bg-gradient-to-br {
        background: linear-gradient(135deg, #0f172a, #1e293b) !important;
      }

      .dark .social-link {
        background-color: var(--surface);
        border-color: var(--border);
      }

      .dark .social-link:hover {
        background-color: var(--card-bg);
        border-color: var(--fd-green);
      }

      .dark .branch-dialog-content {
        background-color: var(--surface);
        border-color: var(--border);
      }

      .dark .branch-option-btn {
        background-color: var(--card-bg);
        border-color: var(--border);
      }

      .dark .branch-option-btn:hover {
        border-color: var(--fd-green);
      }

      .dark .branch-option-title {
        color: var(--text-primary);
      }

      .dark .branch-option-description {
        color: var(--text-secondary);
      }

      .dark .mdw-image-gallery-3d {
        background-color: var(--surface);
      }

      .dark .gallery-card h2,
      .dark .gallery-card h3 {
        color: var(--text-primary);
      }

      .dark .slider-nav {
        background: rgba(0, 0, 0, 0.7);
        color: white;
      }

      .dark .slider-nav:hover {
        background: var(--fd-green);
      }

      .dark .slider-dot {
        background: rgba(255, 255, 255, 0.3);
      }

      .dark .slider-dot.active {
        background: white;
      }

      /* Improve text contrast in dark mode */
      .dark .text-gray-900,
      .dark .text-gray-800,
      .dark .text-gray-700 {
        color: var(--text-primary) !important;
      }

      .dark .text-gray-600,
      .dark .text-gray-500 {
        color: var(--text-secondary) !important;
      }

      .dark .border-gray-300,
      .dark .border-gray-200 {
        border-color: var(--border) !important;
      }

      .dark .bg-gray-50,
      .dark .bg-gray-100 {
        background-color: var(--surface) !important;
      }

      .dark .bg-white {
        background-color: var(--card-bg) !important;
      }

      .dark .prose p {
        color: var(--text-secondary);
      }

      .dark .prose strong {
        color: var(--text-primary);
      }

      /* About section "clean" button: dark mode colors */
      .dark #about a[href*="profile.familydiscount.com"] {
        border-color: #6b7280 !important;
        color: #d1d5db !important;
        background-color: transparent !important;
        transition: all 0.2s ease !important;
      }

      /* Hover state for clean button in dark mode */
      .dark #about a[href*="profile.familydiscount.com"]:hover {
        background-color: var(--fd-green) !important; /* Green background on hover */
        color: #ffffff !important; /* White text on green background */
        border-color: var(--fd-green) !important;
        transform: translateY(-1px);
        box-shadow: 0 4px 12px rgba(122, 193, 67, 0.3);
      }

      /* RTL support for Clean button arrow */
      html[lang="ar"] #about a[href*="profile.familydiscount.com"] svg {
        margin-left: 0;
        margin-right: 0.5rem; /* ml-2 equivalent for RTL */
        transform: rotate(180deg); /* Flip arrow for RTL */
      }

      /* LTR support for Clean button arrow */
      html:not([lang="ar"]) #about a[href*="profile.familydiscount.com"] svg {
        margin-left: 0.5rem; /* ml-2 equivalent for LTR */
        margin-right: 0;
        transform: rotate(0deg);
      }

      /* Ensure consistent spacing for both languages */
      #about a[href*="profile.familydiscount.com"] {
        display: inline-flex;
        align-items: center;
        gap: 0.5rem; /* Consistent gap between text and arrow */
      }

      /* RTL hover animation for arrow */
      html[lang="ar"] #about a[href*="profile.familydiscount.com"]:hover svg {
        transform: rotate(180deg) translateX(-2px);
        transition: transform 0.2s ease;
      }

      /* LTR hover animation for arrow */
      html:not([lang="ar"]) #about a[href*="profile.familydiscount.com"]:hover svg {
        transform: rotate(0deg) translateX(2px);
        transition: transform 0.2s ease;
      }

      /* Mobile responsive adjustments for Clean button */
      @media (max-width: 640px) {
        .dark #about a[href*="profile.familydiscount.com"] {
          font-size: 0.875rem !important;
          padding: 0.625rem 1rem !important;
        }

        html[lang="ar"] #about a[href*="profile.familydiscount.com"] svg {
          width: 0.875rem;
          height: 0.875rem;
        }

        html:not([lang="ar"]) #about a[href*="profile.familydiscount.com"] svg {
          width: 0.875rem;
          height: 0.875rem;
        }
      }
/* ═══ GALLERY 3D / LENIS STYLES (extracted from inline <style>) ═══ */
      /* GALLERY CONTAINER – creates scroll length */
      .mdw-image-gallery-3d {
        position: relative;
        width: 100%;
        background: var(--surface);
        margin: 20px 0;
        border-radius: 16px;
        height: auto;
        overflow: visible;
      }

      /* inner fixed panel – holds 3D cards */
      .mdw-image-gallery-inner {
        position: relative;
        width: 100%;
        height: 60vh;
        transform-style: preserve-3d;
        perspective: 1000px;
        backface-visibility: hidden;
        will-change: transform;
        padding: 40px 20px;
      }

      /* BACKGROUND LAYER – covers gallery area only */
      .mdw-image-gallery-bg {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        overflow: hidden;
        opacity: 0.6;
        pointer-events: none;
        z-index: 1;
      }
      .mdw-image-gallery-bg img {
        position: absolute;
        left: 0;
        top: 0;
        filter: blur(50px);
        transform: scale(1.125);
        width: 100%;
        height: 100%;
        object-fit: cover;
        opacity: 0;
        transition: opacity 1.5s;
        will-change: opacity;
      }

      /* CARD STYLES */
      .gallery-card {
        position: absolute;
        left: 50%;
        top: 55%;
        transform: translate(-50%, -50%) translateZ(0px);
        width: 420px;
        text-align: center;
        will-change: transform, opacity;
        z-index: 10;
        backface-visibility: hidden;
        transition: transform 0.8s cubic-bezier(0.23, 1, 0.32, 1);
        padding: 20px;
      }
      .gallery-card:nth-child(even) {
        left: 30%;
      }
      .gallery-card:nth-child(odd) {
        left: 70%;
      }
      .gallery-card h2 {
        font-size: 2.25rem;
        font-weight: 700;
        margin-bottom: 0.5rem;
        color: var(--text-primary);
        line-height: 1.2;
        text-align: center;
      }
      .gallery-card h3 {
        font-size: 1.125rem;
        font-weight: 500;
        color: var(--text-secondary);
        margin-bottom: 1.5rem;
        text-transform: uppercase;
        letter-spacing: 1.5px;
        opacity: 0.8;
        text-align: center;
      }
      
      /* RTL Gallery Card Text Centering */
      .rtl .gallery-card h2 {
        text-align: center !important;
        direction: rtl;
      }
      .rtl .gallery-card h3 {
        text-align: center !important;
        direction: rtl;
      }
      .gallery-card img {
        width: 100%;
        height: 280px;
        object-fit: cover;
        border-radius: 16px;
        display: block;
        transition: transform 0.3s ease;
      }
      .gallery-card:hover img {
        transform: scale(1.02);
      }

      /* Image Slider Styles */
      .image-slider-container {
        position: relative;
        width: 100%;
        height: 280px;
        border-radius: 16px;
        overflow: visible;
        margin: 0 25px;
      }

      .image-slider {
        position: relative;
        width: 100%;
        height: 100%;
        overflow: hidden;
      }

      .image-slider-track {
        display: flex;
        width: 100%;
        height: 100%;
        transition: transform 0.3s ease-in-out;
      }

      .slider-image {
        width: 100%;
        height: 100%;
        object-fit: cover;
        border-radius: 16px;
        flex-shrink: 0;
        display: block;
      }

      .slider-nav {
        position: absolute;
        top: 50%;
        transform: translateY(-50%);
        background: rgba(0, 0, 0, 0.7);
        color: white;
        border: none;
        border-radius: 50%;
        width: 36px;
        height: 36px;
        display: flex;
        align-items: center;
        justify-content: center;
        cursor: pointer;
        transition: all 0.3s ease;
        z-index: 15;
        font-size: 12px;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
      }

      .slider-nav:hover {
        background: rgba(122, 193, 67, 0.9);
        transform: translateY(-50%) scale(1.1);
        box-shadow: 0 4px 12px rgba(122, 193, 67, 0.4);
      }

      .slider-nav-prev {
        left: -18px;
      }

      .slider-nav-next {
        right: -18px;
      }

      .slider-dots {
        position: absolute;
        bottom: 15px;
        left: 50%;
        transform: translateX(-50%);
        display: flex;
        gap: 8px;
        z-index: 10;
      }

      .slider-dot {
        width: 8px;
        height: 8px;
        border-radius: 50%;
        border: none;
        background: rgba(255, 255, 255, 0.5);
        cursor: pointer;
        transition: all 0.3s ease;
      }

      .slider-dot.active {
        background: white;
        width: 24px;
        border-radius: 4px;
      }

      .slider-dot:hover {
        background: rgba(255, 255, 255, 0.8);
      }

      /* Responsive improvements for 3D gallery */
      @media (max-width: 1024px) {
        .mdw-image-gallery-inner {
          height: 50vh;
          padding: 30px 15px;
        }
        .gallery-card {
          width: 360px;
          padding: 15px;
        }
        .gallery-card:nth-child(even) {
          left: 35%;
        }
        .gallery-card:nth-child(odd) {
          left: 65%;
        }
        .gallery-card h2 {
          font-size: 2rem;
          text-align: center;
        }
        .gallery-card h3 {
          font-size: 1rem;
          text-align: center;
        }
        .gallery-card img {
          height: 240px;
        }
        .image-slider-container {
          height: 240px;
        }
        
        /* RTL responsive centering */
        .rtl .gallery-card h2 {
          text-align: center !important;
          direction: rtl;
        }
        .rtl .gallery-card h3 {
          text-align: center !important;
          direction: rtl;
        }
      }

      @media (max-width: 768px) {
        section[class*="pt-"][class*="pb-"] {
          padding-top: 60px;
          padding-bottom: 40px;
          margin: 40px 0 15px 0;
        }
        .mdw-image-gallery-3d {
          margin: 30px 0 12px 0;
          border-radius: 14px;
          overflow-x: hidden; /* Prevent horizontal overflow */
        }
        .mdw-image-gallery-inner {
          height: 45vh;
          padding: 20px 25px; /* Increased horizontal padding for card visibility */
        }
        .gallery-card {
          width: 280px; /* Reduced width for better mobile fit */
          padding: 12px;
          max-width: calc(100vw - 60px); /* Ensure card doesn't exceed viewport */
        }
        .gallery-card:nth-child(even),
        .gallery-card:nth-child(odd) {
          left: 50%;
        }
        .gallery-card h2 {
          font-size: 1.5rem;
          text-align: center;
          margin-bottom: 0.35rem;
        }
        .gallery-card h3 {
          font-size: 0.825rem;
          margin-bottom: 0.875rem;
          text-align: center;
        }
        .gallery-card img {
          height: 170px;
        }
        .image-slider-container {
          height: 170px;
          margin: 0 15px; /* Reduced margin for better fit */
        }
        .slider-nav {
          width: 32px;
          height: 32px;
          font-size: 11px;
        }
        .slider-nav-prev {
          left: 5px; /* Position inside viewport */
        }
        .slider-nav-next {
          right: 5px; /* Position inside viewport */
        }
        .slider-dots {
          bottom: 12px;
          gap: 7px;
        }
        .slider-dot {
          width: 7px;
          height: 7px;
        }
        .slider-dot.active {
          width: 20px;
        }
        
        /* RTL responsive centering */
        .rtl .gallery-card h2 {
          text-align: center !important;
          direction: rtl;
        }
        .rtl .gallery-card h3 {
          text-align: center !important;
          direction: rtl;
        }
      }

      @media (max-width: 480px) {
        .container.mx-auto.px-6 {
          padding-left: 0.75rem;
          padding-right: 0.75rem;
        }
        .mdw-image-gallery-3d {
          margin: 20px 0 10px 0;
          border-radius: 12px;
          overflow-x: hidden; /* Prevent horizontal overflow */
        }
        .mdw-image-gallery-inner {
          height: 40vh;
          padding: 15px 20px; /* Increased horizontal padding */
        }
        .gallery-card {
          width: 220px; /* Further reduced width */
          padding: 10px;
          max-width: calc(100vw - 50px); /* Ensure card fits viewport */
        }
        .gallery-card:nth-child(even),
        .gallery-card:nth-child(odd) {
          left: 50%;
        }
        .gallery-card h2 {
          font-size: 1.25rem;
          text-align: center;
          margin-bottom: 0.25rem;
        }
        .gallery-card h3 {
          font-size: 0.75rem;
          margin-bottom: 0.75rem;
          text-align: center;
        }
        .gallery-card img {
          height: 140px;
        }
        .image-slider-container {
          height: 140px;
          margin: 0 10px; /* Further reduced margin */
        }
        .slider-nav {
          width: 30px;
          height: 30px;
          font-size: 10px;
        }
        .slider-nav-prev {
          left: 3px; /* Position inside viewport */
        }
        .slider-nav-next {
          right: 3px; /* Position inside viewport */
        }
        .slider-dots {
          bottom: 10px;
          gap: 6px;
        }
        .slider-dot {
          width: 6px;
          height: 6px;
        }
        .slider-dot.active {
          width: 18px;
        }
        
        /* RTL responsive centering */
        .rtl .gallery-card h2 {
          text-align: center !important;
          direction: rtl;
        }
        .rtl .gallery-card h3 {
          text-align: center !important;
          direction: rtl;
        }
      }

      /* Extra small mobile devices (360px and below) */
      @media (max-width: 360px) {
        .container.mx-auto.px-6 {
          padding-left: 0.5rem;
          padding-right: 0.5rem;
        }
        .mdw-image-gallery-3d {
          margin: 15px 0 8px 0;
          border-radius: 10px;
          overflow-x: hidden; /* Prevent horizontal overflow */
        }
        .mdw-image-gallery-inner {
          height: 35vh;
          padding: 12px 15px; /* Increased horizontal padding */
        }
        .gallery-card {
          width: 180px; /* Further reduced width for very small screens */
          padding: 8px;
          max-width: calc(100vw - 40px); /* Ensure card fits viewport */
        }
        .gallery-card:nth-child(even),
        .gallery-card:nth-child(odd) {
          left: 50%;
        }
        .gallery-card h2 {
          font-size: 1.125rem;
          text-align: center;
          margin-bottom: 0.2rem;
        }
        .gallery-card h3 {
          font-size: 0.625rem;
          margin-bottom: 0.5rem;
          text-align: center;
        }
        .gallery-card img {
          height: 110px;
        }
        .image-slider-container {
          height: 110px;
          margin: 0 8px; /* Minimal margin for very small screens */
        }
        .slider-nav {
          width: 26px;
          height: 26px;
          font-size: 9px;
        }
        .slider-nav-prev {
          left: 2px; /* Position inside viewport */
        }
        .slider-nav-next {
          right: 2px; /* Position inside viewport */
        }
        .slider-dots {
          bottom: 8px;
          gap: 5px;
        }
        .slider-dot {
          width: 5px;
          height: 5px;
        }
        .slider-dot.active {
          width: 15px;
        }
        
        /* RTL responsive centering */
        .rtl .gallery-card h2 {
          text-align: center !important;
          direction: rtl;
        }
        .rtl .gallery-card h3 {
          text-align: center !important;
          direction: rtl;
        }
      }

      /* ── MOBILE CATEGORY SLIDER (matches FD Profile style) ── */
      .mobile-category-slider {
        position: relative;
        overflow-x: auto;
        scroll-behavior: smooth;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        -ms-overflow-style: none;
        padding: 1rem 0.5rem;
        margin: 0 -0.5rem 0.5rem;
        background: transparent;
      }
      .mobile-category-slider::-webkit-scrollbar {
        display: none;
      }
      .mobile-category-slider-track {
        display: inline-flex;
        gap: 0.75rem;
        padding: 0 0.5rem;
      }
      html[lang="ar"] .mobile-category-slider-track {
        flex-direction: row-reverse;
      }
      .mobile-category-item {
        flex: 0 0 auto;
        width: 135px;
        background: var(--surface);
        border-radius: 1rem;
        padding: 1rem;
        box-shadow: 0 2px 8px var(--card-shadow);
        cursor: pointer;
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        border: 2px solid transparent;
        position: relative;
        overflow: hidden;
        min-height: 140px;
        display: flex;
        flex-direction: column;
        align-items: flex-start;
      }
      .mobile-category-item.active {
        border-color: var(--fd-green);
        background: linear-gradient(135deg, rgba(122, 193, 67, 0.1) 0%, transparent 100%);
        box-shadow: 0 8px 20px rgba(122, 193, 67, 0.15);
        transform: translateY(-4px);
      }
      .mobile-category-icon {
        width: 42px;
        height: 42px;
        border-radius: 0.75rem;
        background: linear-gradient(135deg, rgba(122, 193, 67, 0.1) 0%, transparent 100%);
        display: flex;
        align-items: center;
        justify-content: center;
        margin-bottom: 0.75rem;
        color: var(--fd-green);
        font-size: 1.2rem;
        transition: all 0.3s ease;
      }
      .mobile-category-item.active .mobile-category-icon {
        background: linear-gradient(135deg, var(--fd-green) 0%, #9db839 100%);
        color: white;
        transform: scale(1.1);
      }
      .mobile-category-name {
        font-weight: 600;
        color: var(--text-primary);
        font-size: 0.85rem;
        line-height: 1.3;
        margin-bottom: 0.5rem;
        min-height: 2.2em;
      }
      .mobile-category-dots {
        display: flex;
        justify-content: center;
        gap: 0.5rem;
        margin: 0.5rem 0 1rem;
        padding: 0 1rem;
      }
      .mobile-category-dot {
        width: 8px;
        height: 8px;
        border-radius: 50%;
        background: #e5e7eb;
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        cursor: pointer;
        border: none;
        padding: 0;
      }
      .dark .mobile-category-dot {
        background: #475569;
      }
      .mobile-category-dot.active {
        background: var(--fd-green);
        transform: scale(1.3);
        box-shadow: 0 0 8px rgba(122, 193, 67, 0.4);
      }
      /* Mobile preview image panel */
      .mobile-gallery-preview {
        background: var(--surface);
        border-radius: 1rem;
        overflow: hidden;
        box-shadow: 0 4px 16px var(--card-shadow);
      }
      .mobile-gallery-preview-image-wrap {
        position: relative;
        width: 100%;
        height: 220px;
        overflow: hidden;
      }
      .mobile-gallery-preview-img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        transition: transform 0.4s ease;
      }
      .mobile-gallery-preview:hover .mobile-gallery-preview-img {
        transform: scale(1.03);
      }
      .mobile-gallery-preview-caption {
        padding: 1rem 1.25rem 1.25rem;
      }
      .mobile-gallery-preview-title {
        font-size: 1.15rem;
        font-weight: 700;
        color: var(--text-primary);
        margin: 0 0 0.3rem;
      }
      .mobile-gallery-preview-subtitle {
        font-size: 0.85rem;
        color: var(--fd-gray);
        margin: 0;
        letter-spacing: 0.5px;
      }
      /* Responsive tweaks for small screens */
      @media (max-width: 480px) {
        .mobile-category-item {
          width: 120px;
          min-height: 125px;
          padding: 0.875rem;
        }
        .mobile-category-icon {
          width: 38px;
          height: 38px;
          font-size: 1.05rem;
        }
        .mobile-category-name {
          font-size: 0.8rem;
        }
        .mobile-gallery-preview-image-wrap {
          height: 185px;
        }
      }
      @media (max-width: 360px) {
        .mobile-category-item {
          width: 105px;
          min-height: 115px;
          padding: 0.75rem;
        }
        .mobile-category-icon {
          width: 34px;
          height: 34px;
          font-size: 0.95rem;
        }
        .mobile-category-name {
          font-size: 0.75rem;
        }
        .mobile-gallery-preview-image-wrap {
          height: 160px;
        }
      }
      /* Touch feedback */
      @media (hover: none) and (pointer: coarse) {
        .mobile-category-item:active {
          transform: scale(0.97) !important;
        }
      }

      /* sticky classes for inner panel (used by JS) */
      .gallery-sticky {
        position: fixed;
        top: 0;
        z-index: 40;
      }
      .gallery-sticky-end {
        position: absolute;
        bottom: 0;
        top: auto !important;
      }

      /* LENIS SMOOTH SCROLL STYLES */
      html.lenis,
      html.lenis body {
        height: auto;
      }
      .lenis.lenis-smooth {
        scroll-behavior: auto !important;
      }
      .lenis.lenis-smooth [data-lenis-prevent] {
        overscroll-behavior: contain;
      }
      .lenis.lenis-stopped {
        overflow: hidden;
      }
/* ═══ SOCIAL PANEL & BRANCH DIALOG STYLES (extracted from inline <style>) ═══ */
      /* Floating Social Media Side Panel - Desktop Fixed Position */
      .social-side-panel {
        position: fixed;
        right: 0;
        top: 50%;
        transform: translateY(-50%);
        z-index: 1000;
        width: 54px;
        display: flex;
        flex-direction: column;
        gap: 8px;
        padding: 12px 0;
        transition: background-color 0.6s ease, border-color 0.6s ease, transform 0.3s ease, opacity 0.3s ease;
        overflow: visible;
      }

      /* RTL positioning - mirror to left side */
      html[lang="ar"] .social-side-panel {
        right: auto;
        left: 0;
      }

      /* Desktop-specific positioning - ensure fixed vertical position */
      @media (min-width: 769px) {
        .social-side-panel {
          right: 0 !important;
          top: 50% !important;
          transform: translateY(-50%) !important;
          position: fixed !important;
          bottom: auto !important;
          left: auto !important;
          width: 54px !important;
          min-width: 54px !important;
          flex-direction: column !important;
          padding: 12px 0 !important;
        }
        
        /* RTL desktop positioning */
        html[lang="ar"] .social-side-panel {
          right: auto !important;
          left: 0 !important;
        }
        
        /* Desktop animation - slide from right */
        .social-side-panel.hidden {
          transform: translateX(100%) translateY(-50%) !important;
          opacity: 0;
          visibility: hidden;
        }
        
        .social-side-panel.visible {
          transform: translateX(0) translateY(-50%) !important;
          opacity: 1;
          visibility: visible;
        }
        
        /* RTL desktop animation - slide from left */
        html[lang="ar"] .social-side-panel.hidden {
          transform: translateX(-100%) translateY(-50%) !important;
        }
        
        html[lang="ar"] .social-side-panel.visible {
          transform: translateX(0) translateY(-50%) !important;
        }
      }

      .social-item {
        position: absolute;
        right: 0;
        overflow: visible;
      }
      
      /* RTL social item positioning */
      html[lang="ar"] .social-item {
        right: auto;
        left: 0;
      }
      
      .social-item:nth-child(1) {
        top: 0;
      }
      
      .social-item:nth-child(2) {
        top: 70px;
      }
      
      .social-item:nth-child(3) {
        top: 140px;
      }
      
      .social-item:nth-child(4) {
        top: 210px;
      }

      .social-link {
        display: flex;
        align-items: center;
        text-decoration: none;
        color: var(--text-primary);
        background: var(--surface);
        border: 2px solid var(--border);
        border-radius: 60px 0 0 60px;
        padding: 16px 18px;
        box-shadow: 
          0 12px 40px rgba(0, 0, 0, 0.15),
          0 6px 20px rgba(0, 0, 0, 0.1),
          inset 0 1px 0 rgba(255, 255, 255, 0.15),
          inset 0 -1px 0 rgba(0, 0, 0, 0.05);
        transition: all 0.5s cubic-bezier(0.23, 1, 0.32, 1), background-color 0.6s ease, border-color 0.6s ease;
        position: relative;
        overflow: hidden;
        width: 54px;
        backdrop-filter: blur(25px);
        -webkit-backdrop-filter: blur(25px);
        flex-direction: row;
        justify-content: flex-start;
      }
      
      /* RTL social link structure - maintain visual order */
      html[lang="ar"] .social-link {
        border-radius: 0 60px 60px 0;
        flex-direction: row;
        justify-content: flex-start;
      }

      .social-link::before {
        content: "";
        position: absolute;
        top: 0;
        left: -100%;
        width: 100%;
        height: 100%;
        background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
        transition: left 0.8s cubic-bezier(0.23, 1, 0.32, 1);
        z-index: 1;
      }

      .social-link:hover::before {
        left: 100%;
      }
      
      /* RTL shimmer animation */
      html[lang="ar"] .social-link::before {
        left: auto;
        right: -100%;
      }
      
      html[lang="ar"] .social-link:hover::before {
        right: 100%;
      }

      .social-link::after {
        content: "";
        position: absolute;
        top: 0;
        right: 0;
        bottom: 0;
        left: 0;
        background: linear-gradient(135deg, transparent 0%, rgba(255, 255, 255, 0.1) 50%, transparent 100%);
        opacity: 0;
        transition: opacity 0.5s ease;
        z-index: 1;
      }

      .social-link:hover::after {
        opacity: 1;
      }

      .social-icon {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 32px;
        height: 32px;
        font-size: 22px;
        flex-shrink: 0;
        transition: all 0.5s cubic-bezier(0.23, 1, 0.32, 1);
        position: relative;
        z-index: 2;
        background: linear-gradient(135deg, var(--fd-navy) 0%, #1e293b 100%);
        color: #ffffff;
        border-radius: 50%;
        padding: 6px;
        box-shadow: 
          0 4px 12px rgba(27, 33, 71, 0.3),
          inset 0 1px 0 rgba(255, 255, 255, 0.1);
      }

      .social-label {
        white-space: nowrap;
        font-weight: 800;
        font-size: 16px;
        position: absolute;
        left: 54px;
        top: 50%;
        transform: translateY(-50%) translateX(-40px) scale(0.7);
        opacity: 0;
        transition: all 0.5s cubic-bezier(0.23, 1, 0.32, 1);
        z-index: 2;
        text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
        pointer-events: none;
        letter-spacing: 0.5px;
        text-align: left;
      }
      
      /* RTL social label positioning and text alignment */
      html[lang="ar"] .social-label {
        left: auto;
        right: 54px;
        transform: translateY(-50%) translateX(40px) scale(0.7);
        text-align: right;
        direction: rtl;
      }
      
      html[lang="ar"] .social-link:hover .social-label {
        transform: translateY(-50%) translateX(0) scale(1);
      }

      .social-link::after {
        content: "";
        position: absolute;
        top: 50%;
        right: -2px;
        width: 4px;
        height: 0;
        background: var(--fd-green);
        border-radius: 2px;
        transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
        transform: translateY(-50%);
      }

      .social-link:hover::after {
        height: 60%;
      }

      /* RTL accent bar positioning */
      html[lang="ar"] .social-link::after {
        right: auto;
        left: -2px;
      }

      /* Enhanced Hover Effects - Premium animations */
      .social-link:hover {
        width: 180px;
        box-shadow: 
          0 20px 60px rgba(0, 0, 0, 0.25),
          0 10px 30px rgba(0, 0, 0, 0.2),
          inset 0 1px 0 rgba(255, 255, 255, 0.25),
          inset 0 -1px 0 rgba(0, 0, 0, 0.1);
        transform: translateX(-12px) scale(1.03);
        border-color: transparent;
        z-index: 10;
      }
      
      /* RTL hover transform */
      html[lang="ar"] .social-link:hover {
        transform: translateX(12px) scale(1.03);
      }

      .social-link:hover .social-icon {
        transform: rotate(360deg) scale(1.15);
        background: linear-gradient(135deg, var(--fd-navy) 0%, #334155 100%);
        box-shadow: 
          0 8px 24px rgba(27, 33, 71, 0.4),
          inset 0 1px 0 rgba(255, 255, 255, 0.2);
      }

      .social-link:hover .social-label {
        opacity: 1;
        transform: translateY(-50%) translateX(0) scale(1);
      }

      /* Simple clean hover effects with brand color icon backgrounds */
      .social-item:nth-child(1) .social-link:hover {
        background: var(--surface);
        color: var(--text-primary);
        border-color: var(--border);
        box-shadow: 
          0 8px 24px rgba(0, 0, 0, 0.15),
          inset 0 1px 0 rgba(255, 255, 255, 0.1);
      }

      .social-item:nth-child(1) .social-link:hover .social-icon {
        background: #fffc00;
        color: #000000;
        text-shadow: none;
        box-shadow: 
          0 4px 12px rgba(255, 252, 0, 0.3);
      }

      .social-item:nth-child(2) .social-link:hover {
        background: var(--surface);
        color: var(--text-primary);
        border-color: var(--border);
        box-shadow: 
          0 8px 24px rgba(0, 0, 0, 0.15),
          inset 0 1px 0 rgba(255, 255, 255, 0.1);
      }

      .social-item:nth-child(2) .social-link:hover .social-icon {
        background: #000000;
        color: #ffffff;
        text-shadow: none;
        box-shadow: 
          0 4px 12px rgba(0, 0, 0, 0.3);
      }

      .social-item:nth-child(3) .social-link:hover {
        background: var(--surface);
        color: var(--text-primary);
        border-color: var(--border);
        box-shadow: 
          0 8px 24px rgba(0, 0, 0, 0.15),
          inset 0 1px 0 rgba(255, 255, 255, 0.1);
      }

      .social-item:nth-child(3) .social-link:hover .social-icon {
        background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
        color: #ffffff;
        text-shadow: none;
        box-shadow: 
          0 4px 12px rgba(228, 64, 95, 0.3);
      }

      .social-item:nth-child(4) .social-link:hover {
        background: var(--surface);
        color: var(--text-primary);
        border-color: var(--border);
        box-shadow: 
          0 8px 24px rgba(0, 0, 0, 0.15),
          inset 0 1px 0 rgba(255, 255, 255, 0.1);
      }

      .social-item:nth-child(4) .social-link:hover .social-icon {
        background: #25d366;
        color: #ffffff;
        text-shadow: none;
        box-shadow: 
          0 4px 12px rgba(37, 211, 102, 0.3);
      }

      /* Glow animation for social links */
      .social-link:hover {
        animation: glow 2s ease-in-out infinite;
      }

      @keyframes glow {
        0%, 100% {
          box-shadow: 
            0 20px 60px rgba(0, 0, 0, 0.25),
            0 10px 30px rgba(0, 0, 0, 0.2),
            inset 0 1px 0 rgba(255, 255, 255, 0.25),
            inset 0 -1px 0 rgba(0, 0, 0, 0.1);
        }
        50% {
          box-shadow: 
            0 25px 70px rgba(122, 193, 67, 0.3),
            0 12px 35px rgba(122, 193, 67, 0.2),
            inset 0 1px 0 rgba(255, 255, 255, 0.3),
            inset 0 -1px 0 rgba(122, 193, 67, 0.1);
        }
      }

      /* Section-based adaptive backgrounds */
      .social-panel-adaptive {
        background-color: rgba(244, 246, 243, 0.95) !important;
        border-color: rgba(229, 231, 235, 0.8) !important;
      }

      .social-panel-dark {
        background-color: rgba(30, 41, 59, 0.95) !important;
        border-color: rgba(51, 65, 85, 0.8) !important;
      }

      .social-panel-hero {
        background-color: rgba(27, 33, 71, 0.9) !important;
        border-color: rgba(122, 193, 67, 0.3) !important;
      }

      .social-panel-offwhite {
        background-color: rgba(244, 246, 243, 0.95) !important;
        border-color: rgba(229, 231, 235, 0.8) !important;
      }

      .social-panel-white {
        background-color: rgba(255, 255, 255, 0.95) !important;
        border-color: rgba(229, 231, 235, 0.8) !important;
      }

      .social-panel-surface {
        background-color: rgba(248, 250, 252, 0.95) !important;
        border-color: rgba(226, 232, 240, 0.8) !important;
      }

      /* Enhanced Dark mode support */
      .dark .social-panel-adaptive {
        background-color: rgba(30, 41, 59, 0.95) !important;
        border-color: rgba(51, 65, 85, 0.8) !important;
      }

      .dark .social-panel-hero {
        background-color: rgba(15, 23, 42, 0.9) !important;
        border-color: rgba(122, 193, 67, 0.4) !important;
      }

      .dark .social-panel-offwhite {
        background-color: rgba(30, 41, 59, 0.95) !important;
        border-color: rgba(51, 65, 85, 0.8) !important;
      }

      .dark .social-panel-white {
        background-color: rgba(30, 41, 59, 0.95) !important;
        border-color: rgba(51, 65, 85, 0.8) !important;
      }

      .dark .social-panel-surface {
        background-color: rgba(30, 41, 59, 0.95) !important;
        border-color: rgba(51, 65, 85, 0.8) !important;
      }

      /* Enhanced RTL support */
      .rtl .social-side-panel {
        right: auto;
        left: 0;
      }

      /* RTL support for desktop positioning */
      @media (min-width: 769px) {
        .rtl .social-side-panel {
          right: auto !important;
          left: 0 !important;
        }
        
        .rtl .social-side-panel.hidden {
          transform: translateX(-100%) translateY(-50%) !important;
        }
        
        .rtl .social-side-panel.visible {
          transform: translateX(0) translateY(-50%) !important;
        }
      }

      .rtl .social-link {
        border-radius: 0 60px 60px 0;
        flex-direction: row-reverse;
      }

      .rtl .social-link:hover {
        transform: translateX(8px) scale(1.02);
      }

      .rtl .social-label {
        margin-left: 8px;
        margin-right: 12px;
        transform: translateX(30px) scale(0.8);
      }

      .rtl .social-link:hover .social-label {
        transform: translateX(0) scale(1);
      }

      .rtl .social-link::after {
        right: auto;
        left: -2px;
      }

      /* Mobile footer: extra bottom padding for the social panel */
      @media (max-width: 768px) {
        footer {
          position: relative;
          padding-bottom: 80px;
        }
        
        .footer {
          background: linear-gradient(135deg, var(--fd-navy) 0%, var(--fd-dark) 100%) !important;
        }
        
        /* Mobile footer layout improvements */
        footer .container {
          padding-left: 16px;
          padding-right: 16px;
        }
        
        /* Mobile brand section */
        footer .lg\:w-2\/5 {
          width: 100%;
          margin-bottom: 2rem;
        }
        
        /* Mobile grid layout */
        footer .grid-cols-1.sm\:grid-cols-2.lg\:grid-cols-3 {
          grid-template-columns: 1fr;
          gap: 1.5rem;
        }
        
        /* Mobile logo sizing */
        footer img[alt*="Family Discount"] {
          height: 48px;
        }
        
        /* Mobile text sizing */
        footer h2 {
          font-size: 1.25rem;
          line-height: 1.4;
        }
        
        footer p {
          font-size: 0.875rem;
          line-height: 1.6;
        }
        
        /* Mobile links spacing */
        footer .grid.grid-cols-2 {
          grid-template-columns: repeat(2, 1fr);
          gap: 0.5rem;
        }
        
        footer .grid.grid-cols-2 > div {
          display: inline-block;
        }
        
        /* Mobile contact info */
        footer .space-y-4 > div {
          padding: 0.75rem;
          background: rgba(255, 255, 255, 0.05);
          border-radius: 0.5rem;
          margin-bottom: 0.75rem;
        }
        
        /* Mobile payment methods */
        footer .flex.gap-2 {
          justify-content: center;
          flex-wrap: wrap;
        }
        
        footer .w-10.h-8 {
          width: 2.5rem;
          height: 2rem;
        }
        
        /* Mobile copyright section */
        footer .flex.flex-col.lg\:flex-row {
          text-align: center;
          gap: 1rem;
        }
        
        /* Mobile scroll to top button */
        footer #scrollToTop {
          bottom: 100px; /* Position above social panel */
          right: 16px;
        }
        
        /* RTL support for Arabic */
        html[lang="ar"] footer {
          direction: rtl;
        }
        
        html[lang="ar"] footer .text-center {
          text-align: center;
        }
        
        html[lang="ar"] footer .lg\:text-left {
          text-align: center;
        }
        
        /* Mobile touch targets */
        footer a {
          padding: 0.5rem;
          display: block;
          border-radius: 0.25rem;
          transition: background-color 0.2s ease;
        }
        
        footer a:hover {
          background-color: rgba(122, 193, 67, 0.1);
        }
        
        /* Mobile footer divider */
        footer .border-t {
          margin: 1.5rem 0;
        }
      }

      /* Responsive map image */
      .map-container {
        width: 100%;
        overflow: hidden;
        position: relative;
      }
      
      .map-container img,
      .map-image {
        width: 100%;
        height: auto;
        display: block;
        object-fit: contain;
      }

      /* Tablet adjustments */
      @media (max-width: 1024px) {
        .map-container {
          max-width: 100%;
          margin: 0 auto;
        }
        
        .map-container img,
        .map-image {
          width: 100%;
          height: auto;
        }
      }

      /* Mobile adjustments */
      @media (max-width: 768px) {
        .map-container {
          width: 100%;
          padding: 0 1rem;
        }
        
        .map-container img,
        .map-image {
          width: 100%;
          height: auto;
          max-width: 100%;
          object-fit: contain;
        }
      }

      /* Small mobile adjustments */
      @media (max-width: 480px) {
        .map-container {
          padding: 0 0.5rem;
        }
        
        .map-container img,
        .map-image {
          width: 100%;
          height: auto;
        }
      }

      /* Enhanced Mobile Navigation Container */
      @media (max-width: 768px) {
        .mobile-nav-container {
          background: linear-gradient(135deg, 
            rgba(255, 255, 255, 0.95) 0%, 
            rgba(248, 250, 252, 0.9) 100%
          );
          backdrop-filter: blur(20px) saturate(180%);
          -webkit-backdrop-filter: blur(20px) saturate(180%);
          border: 1px solid rgba(255, 255, 255, 0.3);
          border-top: 2px solid var(--fd-green);
          box-shadow: 
            0 10px 40px rgba(0, 0, 0, 0.08),
            0 4px 20px rgba(0, 0, 0, 0.04),
            inset 0 1px 0 rgba(255, 255, 255, 0.6);
          border-radius: 0 0 24px 24px;
          margin: 0;
          overflow: hidden;
          position: relative;
        }
        
        .mobile-nav-container::before {
          content: '';
          position: absolute;
          top: 0;
          left: 0;
          right: 0;
          height: 2px;
          background: linear-gradient(90deg, 
            transparent 0%, 
            var(--fd-green) 50%, 
            transparent 100%
          );
          animation: shimmer 3s ease-in-out infinite;
        }
        
        .dark .mobile-nav-container {
          background: linear-gradient(135deg, 
            rgba(30, 41, 59, 0.95) 0%, 
            rgba(15, 23, 42, 0.9) 100%
          );
          border-color: rgba(255, 255, 255, 0.1);
          border-top-color: var(--fd-green);
          box-shadow: 
            0 10px 40px rgba(0, 0, 0, 0.3),
            0 4px 20px rgba(0, 0, 0, 0.2),
            inset 0 1px 0 rgba(255, 255, 255, 0.1);
        }
        
        .mobile-nav-container .nav-link {
          background: rgba(255, 255, 255, 0.4);
          border: 1px solid rgba(255, 255, 255, 0.2);
          margin: 4px 8px;
          border-radius: 16px;
          font-weight: 600;
          letter-spacing: 0.02em;
          transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
          position: relative;
          overflow: hidden;
        }
        
        .mobile-nav-container .nav-link::before {
          content: '';
          position: absolute;
          top: 0;
          left: -100%;
          width: 100%;
          height: 100%;
          background: linear-gradient(90deg, 
            transparent 0%, 
            rgba(122, 193, 67, 0.1) 50%, 
            transparent 100%
          );
          transition: left 0.6s ease;
        }
        
        .mobile-nav-container .nav-link:hover::before {
          left: 100%;
        }
        
        .mobile-nav-container .nav-link:hover {
          background: rgba(122, 193, 67, 0.1);
          border-color: var(--fd-green);
          color: var(--fd-green);
          transform: translateX(4px);
          box-shadow: 
            0 4px 16px rgba(122, 193, 67, 0.15),
            0 2px 8px rgba(122, 193, 67, 0.1);
        }
        
        .dark .mobile-nav-container .nav-link {
          background: rgba(255, 255, 255, 0.05);
          border-color: rgba(255, 255, 255, 0.1);
          color: rgba(241, 245, 249, 0.9);
        }
        
        .dark .mobile-nav-container .nav-link:hover {
          background: rgba(122, 193, 67, 0.15);
          border-color: var(--fd-green);
          color: var(--fd-green);
          box-shadow: 
            0 4px 16px rgba(122, 193, 67, 0.2),
            0 2px 8px rgba(122, 193, 67, 0.15);
        }
        
        @keyframes shimmer {
          0%, 100% { opacity: 0.6; transform: translateX(-100%); }
          50% { opacity: 1; transform: translateX(100%); }
        }
      }

      /* Mobile social panel: compact glass bottom bar (≤768px) */
      @media (max-width: 768px) {
        .social-side-panel {
          position: fixed;
          bottom: 20px;
          left: 50%;
          transform: translateX(-50%) translateY(100px);
          top: auto;
          width: auto;
          min-width: 200px;
          flex-direction: row;
          justify-content: center;
          align-items: center;
          gap: 8px;
          padding: 6px 12px;
          background: rgba(255, 255, 255, 0.7);
          border: 1px solid rgba(255, 255, 255, 0.3);
          border-radius: 20px;
          box-shadow: 
            0 4px 20px rgba(0, 0, 0, 0.08),
            0 2px 10px rgba(0, 0, 0, 0.05),
            inset 0 1px 0 rgba(255, 255, 255, 0.4);
          backdrop-filter: blur(15px) saturate(150%);
          -webkit-backdrop-filter: blur(15px) saturate(150%);
          z-index: 1001;
          overflow: hidden;
          transition: all 0.3s ease;
          opacity: 0;
          visibility: hidden;
        }

        /* Show social bar after scrolling past hero */
        .social-side-panel.visible {
          transform: translateX(-50%) translateY(0);
          opacity: 1;
          visibility: visible;
        }

        /* Mobile social-item positioning - override desktop absolute positioning */
        .social-item {
          position: relative !important;
          top: auto !important;
          right: auto !important;
        }

        /* Light mode glass styling */
        .social-side-panel {
          background: rgba(255, 255, 255, 0.7);
          border: 1px solid rgba(255, 255, 255, 0.3);
          box-shadow: 
            0 4px 20px rgba(0, 0, 0, 0.08),
            0 2px 10px rgba(0, 0, 0, 0.05),
            inset 0 1px 0 rgba(255, 255, 255, 0.4);
        }

        /* Dark mode glass styling */
        .dark .social-side-panel {
          background: rgba(30, 41, 59, 0.7);
          border: 1px solid rgba(255, 255, 255, 0.1);
          box-shadow: 
            0 4px 20px rgba(0, 0, 0, 0.2),
            0 2px 10px rgba(0, 0, 0, 0.15),
            inset 0 1px 0 rgba(255, 255, 255, 0.1);
        }

        /* Each item */
        .social-item {
          flex: none;
          width: auto;
          overflow: visible;
          position: relative;
          top: auto;
        }

        /* Compact circular icon button */
        .social-link {
          display: flex !important;
          align-items: center;
          justify-content: center;
          width: 36px;
          height: 36px;
          border-radius: 50%;
          margin: 0;
          border: 1px solid rgba(122, 193, 67, 0.2);
          background: rgba(122, 193, 67, 0.08);
          backdrop-filter: none;
          -webkit-backdrop-filter: none;
          position: relative;
          transition: all 0.2s ease;
        }

        /* Light mode hover effects */
        .social-link:hover {
          background: rgba(122, 193, 67, 0.15);
          border-color: rgba(122, 193, 67, 0.3);
          transform: scale(1.05);
          box-shadow: 
            0 4px 15px rgba(122, 193, 67, 0.2),
            0 2px 8px rgba(122, 193, 67, 0.15);
        }

        .social-link:active {
          background: rgba(122, 193, 67, 0.2);
          border-color: rgba(122, 193, 67, 0.4);
          transform: scale(0.98);
          box-shadow: 
            0 2px 8px rgba(122, 193, 67, 0.15),
            inset 0 1px 2px rgba(0, 0, 0, 0.05);
        }

        /* Dark mode hover effects */
        .dark .social-link:hover {
          background: rgba(122, 193, 67, 0.2);
          border-color: rgba(122, 193, 67, 0.4);
          box-shadow: 
            0 4px 15px rgba(122, 193, 67, 0.3),
            0 2px 8px rgba(122, 193, 67, 0.2);
        }

        .dark .social-link:active {
          background: rgba(122, 193, 67, 0.25);
          border-color: rgba(122, 193, 67, 0.5);
          box-shadow: 
            0 2px 8px rgba(122, 193, 67, 0.2),
            inset 0 1px 2px rgba(0, 0, 0, 0.1);
        }

        /* Compact icon styling */
        .social-icon {
          width: 18px;
          height: 18px;
          font-size: 16px;
          padding: 0;
          border-radius: 50%;
          background: transparent;
          color: var(--fd-green);
          box-shadow: none;
          transition: all 0.2s ease;
          position: relative;
          z-index: 2;
        }

        /* Icon hover effects */
        .social-link:hover .social-icon {
          color: #ffffff;
          transform: scale(1.1);
        }

        /* Dark mode icon adjustments */
        .dark .social-icon {
          color: var(--fd-green);
        }

        /* Hide labels completely */
        .social-label {
          display: none !important;
        }

        /* Simplified brand colors for active states */
        .social-item:nth-child(1) .social-link:active .social-icon { 
          color: #fffc00; 
        }
        .social-item:nth-child(2) .social-link:active .social-icon { 
          color: #ffffff; 
        }
        .social-item:nth-child(3) .social-link:active .social-icon {
          color: #e4405f;
        }
        .social-item:nth-child(4) .social-link:active .social-icon { 
          color: #25d366; 
        }

        /* Simplified glow effect for container */
        .social-side-panel::before {
          content: '';
          position: absolute;
          top: -1px;
          left: -1px;
          right: -1px;
          bottom: -1px;
          background: linear-gradient(45deg, 
            rgba(122, 193, 67, 0.2) 0%,
            rgba(122, 193, 67, 0.1) 25%,
            rgba(122, 193, 67, 0.2) 50%,
            rgba(122, 193, 67, 0.1) 75%,
            rgba(122, 193, 67, 0.2) 100%
          );
          border-radius: 21px;
          z-index: -1;
          opacity: 0;
          transition: opacity 0.2s ease;
        }

        .social-side-panel:hover::before {
          opacity: 1;
        }

        /* Remove all animations */
        .social-icon {
          animation: none !important;
        }

        /* Simple smooth transition instead of floating */
        .social-side-panel {
          animation: none;
        }

        .social-side-panel:hover {
          transform: translateX(-50%) translateY(-1px);
        }

        /* RTL mobile social panel: center the panel that desktop offsets to the left */
        html[lang="ar"] .social-side-panel {
          left: 50% !important;
          right: auto !important;
          transform: translateX(-50%) translateY(100px) !important;
        }

        html[lang="ar"] .social-side-panel.visible {
          transform: translateX(-50%) translateY(0) !important;
        }

        html[lang="ar"] .social-link {
          border-radius: 50% !important;
          flex-direction: row !important;
          justify-content: center !important;
          align-items: center !important;
          width: 36px !important;
          height: 36px !important;
          margin: 0 !important;
          transform: none !important;
        }

        html[lang="ar"] .social-link:hover {
          transform: scale(1.05) !important;
          background: rgba(122, 193, 67, 0.15) !important;
          border-color: rgba(122, 193, 67, 0.3) !important;
        }

        html[lang="ar"] .social-icon {
          position: relative !important;
          transform: none !important;
          margin: 0 !important;
          left: auto !important;
          right: auto !important;
        }

        html[lang="ar"] .social-link:hover .social-icon {
          transform: scale(1.1) !important;
          color: #ffffff !important;
        }

        /* Hide RTL accent bar on mobile (not needed for circular icons) */
        html[lang="ar"] .social-link::after {
          display: none !important;
        }

        html[lang="ar"] .social-item {
          position: relative !important;
          top: auto !important;
          right: auto !important;
          left: auto !important;
          transform: none !important;
        }

        /* Fix RTL social panel hover for mobile */
        html[lang="ar"] .social-side-panel:hover {
          transform: translateX(-50%) translateY(-1px) !important;
        }

        /* Light mode specific adjustments */
        @media (prefers-color-scheme: light) {
          .social-side-panel:not(.dark) {
            background: rgba(255, 255, 255, 0.7);
            border: 1px solid rgba(255, 255, 255, 0.3);
          }
        }

        /* Dark mode specific adjustments */
        @media (prefers-color-scheme: dark) {
          .social-side-panel.dark {
            background: rgba(30, 41, 59, 0.7);
            border: 1px solid rgba(255, 255, 255, 0.1);
          }
        }
      }

      /* Additional visual enhancements */
      .social-link::after {
        content: "";
        position: absolute;
        top: 50%;
        right: -2px;
        width: 4px;
        height: 0;
        background: var(--fd-green);
        border-radius: 2px;
        transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
        transform: translateY(-50%);
      }

      .social-link:hover::after {
        height: 60%;
      }

      .rtl .social-link::after {
        right: auto;
        left: -2px;
      }

      /* Glow effect on hover */
      @keyframes glow {
        0%, 100% {
          box-shadow: 
            0 16px 48px rgba(0, 0, 0, 0.2),
            0 8px 24px rgba(0, 0, 0, 0.15),
            inset 0 1px 0 rgba(255, 255, 255, 0.2);
        }
        50% {
          box-shadow: 
            0 20px 60px rgba(0, 0, 0, 0.25),
            0 10px 30px rgba(0, 0, 0, 0.2),
            inset 0 1px 0 rgba(255, 255, 255, 0.3),
            0 0 20px rgba(122, 193, 67, 0.3);
        }
      }

      .social-link:hover {
        animation: glow 2s ease-in-out infinite;
      }

      /* Branch Dialog Styles */
      .branch-dialog {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0, 0, 0, 0.5);
        backdrop-filter: blur(4px);
        z-index: 10000;
        animation: fadeIn 0.3s ease-out;
      }

      .branch-dialog.active {
        display: flex;
        align-items: center;
        justify-content: center;
      }

      .branch-dialog-content {
        background: var(--surface);
        border-radius: 20px;
        max-width: 520px;
        width: 90%;
        max-height: 90vh;
        overflow: auto;
        box-shadow: 
          0 30px 60px rgba(0, 0, 0, 0.2),
          0 15px 30px rgba(0, 0, 0, 0.15),
          0 5px 15px rgba(0, 0, 0, 0.1);
        animation: slideUp 0.4s cubic-bezier(0.16, 1, 0.3, 1);
        border: 1px solid var(--border);
      }

      .branch-dialog-header {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 28px 32px 20px;
        border-bottom: 1px solid var(--border-light);
      }

      .branch-dialog-title {
        font-size: 1.625rem;
        font-weight: 700;
        color: var(--text-primary);
        margin: 0;
        letter-spacing: -0.025em;
      }

      .branch-dialog-close {
        background: none;
        border: none;
        font-size: 1.375rem;
        color: var(--text-secondary);
        cursor: pointer;
        padding: 10px;
        border-radius: 10px;
        transition: all 0.2s ease;
        display: flex;
        align-items: center;
        justify-content: center;
        width: 44px;
        height: 44px;
      }

      .branch-dialog-close:hover {
        background: var(--border-light);
        color: var(--text-primary);
        transform: scale(1.05);
      }

      .branch-dialog-body {
        padding: 20px 32px 32px;
      }

      .branch-dialog-subtitle {
        color: var(--text-secondary);
        margin: 0 0 28px 0;
        font-size: 1.0625rem;
        line-height: 1.6;
        font-weight: 400;
      }

      .branch-dialog-options {
        display: flex;
        flex-direction: column;
        gap: 16px;
      }

      .branch-option-btn {
        display: flex;
        align-items: center;
        gap: 20px;
        padding: 20px;
        background: var(--card-bg);
        border: 2px solid var(--border);
        border-radius: 16px;
        cursor: pointer;
        transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
        text-align: left;
        width: 100%;
        position: relative;
        overflow: hidden;
      }

      .branch-option-btn::before {
        content: '';
        position: absolute;
        top: 0;
        left: -100%;
        width: 100%;
        height: 100%;
        background: linear-gradient(90deg, transparent, rgba(122, 193, 67, 0.05), transparent);
        transition: left 0.6s ease;
      }

      .branch-option-btn:hover::before {
        left: 100%;
      }

      .branch-option-btn:hover {
        border-color: var(--fd-green);
        transform: translateY(-3px);
        box-shadow: 
          0 12px 32px rgba(122, 193, 67, 0.15),
          0 6px 16px rgba(122, 193, 67, 0.1);
      }

      .branch-option-btn:focus {
        outline: none;
        border-color: var(--fd-green);
        box-shadow: 
          0 0 0 4px rgba(122, 193, 67, 0.1),
          0 12px 32px rgba(122, 193, 67, 0.15);
      }

      .branch-option-btn:active {
        transform: translateY(-1px);
      }

      .branch-option-icon {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 48px;
        height: 48px;
        background: var(--fd-green);
        color: white;
        border-radius: 12px;
        font-size: 1.25rem;
        flex-shrink: 0;
        box-shadow: 0 2px 8px rgba(122, 193, 67, 0.2);
        transition: all 0.2s ease;
      }

      .branch-option-btn:hover .branch-option-icon {
        background: var(--fd-navy);
        transform: scale(1.05);
        box-shadow: 0 4px 12px rgba(27, 33, 71, 0.3);
      }

      .branch-option-content {
        flex: 1;
        min-width: 0;
      }

      .branch-option-title {
        font-size: 1.1875rem;
        font-weight: 600;
        color: var(--text-primary);
        margin: 0 0 6px 0;
        letter-spacing: -0.025em;
        transition: color 0.2s ease;
      }

      .branch-option-description {
        font-size: 0.9375rem;
        color: var(--text-secondary);
        margin: 0;
        line-height: 1.5;
        transition: color 0.2s ease;
      }

      .branch-option-btn:hover .branch-option-title {
        color: var(--fd-green);
      }

      .branch-option-btn:hover .branch-option-description {
        color: var(--text-primary);
      }

      /* RTL Support for Dialog */
      .rtl .branch-dialog-content {
        direction: rtl;
      }

      .rtl .branch-dialog-header {
        flex-direction: row-reverse;
      }

      .rtl .branch-option-btn {
        flex-direction: row-reverse;
        text-align: right;
      }

      /* Mobile Responsive */
      @media (max-width: 640px) {
        .branch-dialog-content {
          width: 95%;
          margin: 16px;
          border-radius: 16px;
        }

        .branch-dialog-header,
        .branch-dialog-body {
          padding: 24px;
        }

        .branch-dialog-title {
          font-size: 1.375rem;
        }

        .branch-dialog-subtitle {
          font-size: 1rem;
          margin-bottom: 24px;
        }

        .branch-option-btn {
          padding: 16px;
          gap: 16px;
          border-radius: 12px;
        }

        .branch-option-icon {
          width: 44px;
          height: 44px;
          font-size: 1.125rem;
        }

        .branch-option-title {
          font-size: 1.0625rem;
        }

        .branch-option-description {
          font-size: 0.875rem;
        }

        .branch-dialog-close {
          width: 40px;
          height: 40px;
          font-size: 1.25rem;
        }
      }

      @media (max-width: 480px) {
        .branch-dialog-header,
        .branch-dialog-body {
          padding: 20px;
        }

        .branch-option-btn {
          padding: 14px;
          gap: 14px;
        }

        .branch-option-icon {
          width: 40px;
          height: 40px;
          font-size: 1rem;
        }
      }
/* ═══ CAREER PAGE STYLES (extracted from career.css) ═══ */
/* ═══════════════════════════════════════════════════════════
   career.css — Career page specific styles
   Uses design-system tokens from career.html <style> block
   ═══════════════════════════════════════════════════════════ */

/* ── Hero ── */
.career-hero {
  min-height: 420px;
  display: flex;
  align-items: center;
}

/* ── Primary CTA button ── */
.career-btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  background-color: var(--fd-green);
  color: #ffffff;
  font-weight: 700;
  font-size: 1rem;
  padding: 0.875rem 2rem;
  border-radius: 0.75rem;
  border: 2px solid transparent;
  cursor: pointer;
  text-decoration: none;
  transition: background-color 0.25s ease, transform 0.2s ease, box-shadow 0.25s ease;
  box-shadow: 0 4px 15px rgba(122, 193, 67, 0.35);
  line-height: 1.2;
}

.career-btn-primary:hover {
  background-color: #69ad38;
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(122, 193, 67, 0.45);
  color: #ffffff;
}

.career-btn-primary:active {
  transform: translateY(0);
}

/* ── Perk cards ── */
.career-perk-card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 1rem;
  padding: 2rem 1.5rem;
  text-align: center;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  box-shadow: 0 2px 8px var(--card-shadow);
}

.career-perk-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px var(--card-shadow);
}

.career-perk-icon {
  width: 3.5rem;
  height: 3.5rem;
  background: linear-gradient(135deg, rgba(122, 193, 67, 0.15), rgba(122, 193, 67, 0.05));
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.25rem;
  font-size: 1.4rem;
  color: var(--fd-green);
}

.career-perk-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 0.6rem;
}

.career-perk-text {
  font-size: 0.875rem;
  color: var(--text-secondary);
  line-height: 1.7;
}

/* ── Form container ── */
.career-form {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 1.25rem;
  padding: 2.5rem 2rem;
  box-shadow: 0 4px 24px var(--card-shadow);
}

@media (min-width: 640px) {
  .career-form {
    padding: 3rem 2.5rem;
  }
}

/* ── Two-column row ── */
.career-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
  margin-bottom: 1.25rem;
}

@media (min-width: 560px) {
  .career-row {
    grid-template-columns: 1fr 1fr;
  }
}

/* ── Individual field ── */
.career-field {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  margin-bottom: 0;
}

.career-field--full {
  margin-bottom: 1.25rem;
}

/* ── Label ── */
.career-label {
  display: block;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.4;
}

.required {
  color: #ef4444;
  margin-inline-start: 0.1rem;
}

/* ── Text / email inputs ── */
.career-input {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1.5px solid var(--border);
  border-radius: 0.625rem;
  background: var(--background);
  color: var(--text-primary);
  font-size: 1rem;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  appearance: none;
  -webkit-appearance: none;
}

.career-input:focus {
  border-color: var(--fd-green);
  box-shadow: 0 0 0 3px rgba(122, 193, 67, 0.18);
}

.career-input.is-invalid {
  border-color: #ef4444;
  box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.12);
}

.career-input::placeholder {
  color: var(--text-secondary);
  opacity: 0.6;
}

/* ── Select ── */
.career-select-wrap {
  position: relative;
}

.career-select {
  width: 100%;
  padding: 0.75rem 2.5rem 0.75rem 1rem;
  border: 1.5px solid var(--border);
  border-radius: 0.625rem;
  background: var(--background);
  color: var(--text-primary);
  font-size: 1rem;
  outline: none;
  appearance: none;
  -webkit-appearance: none;
  cursor: pointer;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.career-select:focus {
  border-color: var(--fd-green);
  box-shadow: 0 0 0 3px rgba(122, 193, 67, 0.18);
}

.career-select.is-invalid {
  border-color: #ef4444;
}

.career-select-arrow {
  position: absolute;
  right: 0.9rem;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
  color: var(--text-secondary);
  font-size: 0.75rem;
  transition: transform 0.2s ease;
}

/* RTL: arrow on left */
.rtl .career-select {
  padding-inline-start: 2.5rem;
  padding-inline-end: 1rem;
}

.rtl .career-select-arrow {
  right: auto;
  left: 0.9rem;
}

/* ── Radio group ── */
.career-radio-group {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 0.25rem;
}

.career-radio-label {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  cursor: pointer;
  padding: 0.6rem 1.1rem;
  border: 1.5px solid var(--border);
  border-radius: 2rem;
  background: var(--background);
  font-size: 0.875rem;
  color: var(--text-primary);
  font-weight: 500;
  transition: border-color 0.2s ease, background 0.2s ease, color 0.2s ease;
  user-select: none;
}

.career-radio-label:hover {
  border-color: var(--fd-green);
  background: rgba(122, 193, 67, 0.06);
}

/* Hide the native radio */
.career-radio {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
  pointer-events: none;
}

/* Custom radio circle */
.career-radio-custom {
  display: inline-flex;
  flex-shrink: 0;
  width: 1.1rem;
  height: 1.1rem;
  border-radius: 50%;
  border: 2px solid var(--border);
  background: var(--background);
  position: relative;
  transition: border-color 0.2s ease, background 0.2s ease;
}

.career-radio:checked ~ .career-radio-custom {
  border-color: var(--fd-green);
  background: var(--fd-green);
}

.career-radio:checked ~ .career-radio-custom::after {
  content: '';
  position: absolute;
  inset: 2px;
  border-radius: 50%;
  background: #ffffff;
}

/* Pill highlight when selected */
.career-radio:checked ~ * {
  color: var(--fd-green);
}

.career-radio-label:has(.career-radio:checked) {
  border-color: var(--fd-green);
  background: rgba(122, 193, 67, 0.09);
  color: var(--fd-green);
}

/* Radio error state */
.career-radio-group.is-invalid .career-radio-label {
  border-color: rgba(239, 68, 68, 0.5);
}

/* ── Textarea ── */
.career-textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1.5px solid var(--border);
  border-radius: 0.625rem;
  background: var(--background);
  color: var(--text-primary);
  font-size: 1rem;
  line-height: 1.6;
  resize: vertical;
  min-height: 130px;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  font-family: inherit;
}

.career-textarea:focus {
  border-color: var(--fd-green);
  box-shadow: 0 0 0 3px rgba(122, 193, 67, 0.18);
}

.career-textarea.is-invalid {
  border-color: #ef4444;
}

/* ── Char counter ── */
.career-char-counter {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 0.3rem;
  min-height: 1.4rem;
}

.career-char-count {
  font-size: 0.8125rem;
  color: var(--text-secondary);
  margin-inline-start: auto;
  white-space: nowrap;
}

.career-char-count.near-limit {
  color: #f59e0b;
}

.career-char-count.at-limit {
  color: #ef4444;
}

/* ── Upload zone ── */
.career-upload-zone {
  position: relative;
  border: 2px dashed var(--border);
  border-radius: 0.875rem;
  background: var(--background);
  padding: 2.25rem 1.5rem;
  text-align: center;
  cursor: pointer;
  transition: border-color 0.25s ease, background 0.25s ease;
  outline: none;
}

.career-upload-zone:hover,
.career-upload-zone:focus-within,
.career-upload-zone.drag-over {
  border-color: var(--fd-green);
  background: rgba(122, 193, 67, 0.04);
}

.career-upload-zone.drag-over {
  background: rgba(122, 193, 67, 0.09);
}

.career-upload-input {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: pointer;
}

.career-upload-icon {
  font-size: 2.5rem;
  color: var(--fd-green);
  margin-bottom: 0.75rem;
  line-height: 1;
}

.career-upload-text {
  font-size: 0.9375rem;
  color: var(--text-primary);
  margin-bottom: 0.35rem;
}

.career-upload-hint {
  font-size: 0.8125rem;
  color: var(--text-secondary);
  margin: 0;
}

/* ── File info row ── */
.career-file-info {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-top: 0.75rem;
  padding: 0.6rem 0.9rem;
  background: rgba(122, 193, 67, 0.08);
  border: 1px solid rgba(122, 193, 67, 0.25);
  border-radius: 0.5rem;
}

.career-file-info.hidden {
  display: none;
}

.career-remove-file {
  margin-inline-start: auto;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text-secondary);
  padding: 0.15rem 0.35rem;
  border-radius: 0.25rem;
  font-size: 0.85rem;
  transition: color 0.2s ease;
  line-height: 1;
}

.career-remove-file:hover {
  color: #ef4444;
}

/* ── Validation errors ── */
.career-error {
  display: none;
  font-size: 0.8rem;
  color: #ef4444;
  margin-top: 0.25rem;
  line-height: 1.4;
}

.career-error.visible {
  display: block;
}

/* ── Submit button ── */
.career-submit-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  background-color: var(--fd-green);
  color: #ffffff;
  font-weight: 700;
  font-size: 1.0625rem;
  padding: 0.9375rem 3rem;
  border-radius: 0.75rem;
  border: none;
  cursor: pointer;
  transition: background-color 0.25s ease, transform 0.2s ease, box-shadow 0.25s ease;
  box-shadow: 0 4px 18px rgba(122, 193, 67, 0.35);
  min-width: 220px;
  position: relative;
}

.career-submit-btn:hover:not(:disabled) {
  background-color: #69ad38;
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(122, 193, 67, 0.45);
}

.career-submit-btn:active:not(:disabled) {
  transform: translateY(0);
}

.career-submit-btn:disabled {
  opacity: 0.7;
  cursor: not-allowed;
}

.submit-loading {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.submit-loading.hidden {
  display: none;
}

/* ── Success state ── */
.career-success {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 1.25rem;
  padding: 3.5rem 2rem;
  text-align: center;
  box-shadow: 0 4px 24px var(--card-shadow);
}

.career-success.hidden {
  display: none;
}

.career-success-icon {
  font-size: 4rem;
  color: var(--fd-green);
  margin-bottom: 1.25rem;
  animation: successPop 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

@keyframes successPop {
  0%   { transform: scale(0.4); opacity: 0; }
  70%  { transform: scale(1.1); opacity: 1; }
  100% { transform: scale(1); }
}

.career-success-title {
  font-size: 1.625rem;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 0.75rem;
}

.career-success-text {
  font-size: 0.9375rem;
  color: var(--text-secondary);
  line-height: 1.75;
  max-width: 480px;
  margin: 0 auto;
}

/* ═══════════════════════ DARK MODE ═══════════════════════ */

.dark .career-form {
  background: var(--surface);
  border-color: var(--border);
}

.dark .career-input,
.dark .career-select,
.dark .career-textarea {
  background: rgba(255, 255, 255, 0.04);
  border-color: var(--border);
  color: var(--text-primary);
}

.dark .career-input:focus,
.dark .career-select:focus,
.dark .career-textarea:focus {
  border-color: var(--fd-green);
  box-shadow: 0 0 0 3px rgba(122, 193, 67, 0.2);
}

.dark .career-upload-zone {
  background: rgba(255, 255, 255, 0.03);
  border-color: var(--border);
}

.dark .career-upload-zone:hover,
.dark .career-upload-zone:focus-within,
.dark .career-upload-zone.drag-over {
  background: rgba(122, 193, 67, 0.07);
  border-color: var(--fd-green);
}

.dark .career-radio-label {
  background: rgba(255, 255, 255, 0.04);
  border-color: var(--border);
  color: var(--text-primary);
}

.dark .career-radio-label:has(.career-radio:checked) {
  background: rgba(122, 193, 67, 0.12);
  border-color: var(--fd-green);
  color: var(--fd-green);
}

.dark .career-radio-custom {
  background: rgba(255, 255, 255, 0.05);
  border-color: var(--border-light);
}

.dark .career-perk-card {
  background: var(--card-bg);
  border-color: var(--border);
}

.dark .career-success {
  background: var(--surface);
  border-color: var(--border);
}

.dark .career-file-info {
  background: rgba(122, 193, 67, 0.1);
  border-color: rgba(122, 193, 67, 0.3);
}

/* ═══════════════════════ RTL OVERRIDES ═══════════════════════ */

.rtl .career-char-counter {
  flex-direction: row-reverse;
}

.rtl .career-char-count {
  margin-inline-start: 0;
  margin-inline-end: auto;
}

.rtl .career-radio-group {
  flex-direction: row-reverse;
  justify-content: flex-end;
}

.rtl .career-file-info {
  flex-direction: row-reverse;
}

.rtl .career-upload-zone {
  direction: rtl;
}

.rtl .career-remove-file {
  margin-inline-start: 0;
  margin-inline-end: auto;
}

/* ═══════════════════════ CAREER FORM — RTL ADDITIONS ═══════════════════════ */

/* Labels: right-align in RTL for reliable cross-browser behaviour */
.rtl .career-label {
  text-align: right;
  display: block;
}

/* Inputs and textarea: explicit RTL direction so Arabic text enters correctly */
.rtl .career-input,
.rtl .career-textarea {
  direction: rtl;
  text-align: right;
}

/* Error messages under fields */
.rtl .career-error {
  text-align: right;
  direction: rtl;
}

/* Section heading inside the form */
.rtl .career-form h2 {
  text-align: right;
}

/* ═══════════════════════ ABOUT SECTION — RTL BUTTON ARROW ═══════════════════════ */

/* "View Our Journey / شاهد مسيرتنا" button: flip the right-pointing arrow
   and swap margin so the gap is between the arrow and the text */
html[lang="ar"] #about .inline-flex.items-center > svg {
  transform: scaleX(-1);
  margin-left: 0;
  margin-right: 0.5rem;
}

/* ═══════════════════════ CAREERS SECTION (INDEX) — RTL CONTENT BOX ═══════════════════════ */

/* In LTR the box has mr-auto / lg:ml-8 to push it left.
   In RTL it should be pushed to the right side of the image. */
html[lang="ar"] #careers .max-w-2xl {
  margin-right: 0;
  margin-left: auto;
}

@media (min-width: 1024px) {
  html[lang="ar"] #careers .max-w-2xl {
    margin-left: 0;
    margin-right: 2rem; /* equivalent to lg:mr-8 */
  }
}
