

/* =========================================================
   V11 FINAL FIXES: READABLE THEME + SERVICES MENU + DETAILS
   ========================================================= */
html[data-theme="light"], html[data-theme="light"] body{
  background:#f4f6f9 !important;
  color:#111318 !important;
}
html[data-theme="dark"], html[data-theme="dark"] body{
  background:#050608 !important;
  color:#ffffff !important;
}

/* make every common page area follow the active theme */
html[data-theme="light"] .site-header,
html[data-theme="light"] .desktop-nav,
html[data-theme="light"] .mobile-menu,
html[data-theme="light"] .mobile-menu-content,
html[data-theme="light"] .atlas-services-panel,
html[data-theme="light"] .atlas-footer,
html[data-theme="light"] .footer-column,
html[data-theme="light"] .section,
html[data-theme="light"] .content-card,
html[data-theme="light"] .service-card,
html[data-theme="light"] .eco-card,
html[data-theme="light"] .glass-card,
html[data-theme="light"] .center-panel,
html[data-theme="light"] .atlas-center-card,
html[data-theme="light"] .center-summary,
html[data-theme="light"] .booking-card,
html[data-theme="light"] .contact-card,
html[data-theme="light"] .warranty-card,
html[data-theme="light"] .franchise-card,
html[data-theme="light"] .form-card,
html[data-theme="light"] .review-card{
  background:#ffffff !important;
  color:#111318 !important;
  border-color:rgba(0,0,0,.12) !important;
  box-shadow:0 18px 45px rgba(0,0,0,.08) !important;
}
html[data-theme="dark"] .site-header,
html[data-theme="dark"] .desktop-nav,
html[data-theme="dark"] .mobile-menu,
html[data-theme="dark"] .mobile-menu-content,
html[data-theme="dark"] .atlas-services-panel,
html[data-theme="dark"] .atlas-footer,
html[data-theme="dark"] .section,
html[data-theme="dark"] .content-card,
html[data-theme="dark"] .service-card,
html[data-theme="dark"] .eco-card,
html[data-theme="dark"] .glass-card,
html[data-theme="dark"] .center-panel,
html[data-theme="dark"] .atlas-center-card,
html[data-theme="dark"] .center-summary,
html[data-theme="dark"] .booking-card,
html[data-theme="dark"] .contact-card,
html[data-theme="dark"] .warranty-card,
html[data-theme="dark"] .franchise-card,
html[data-theme="dark"] .form-card,
html[data-theme="dark"] .review-card{
  background:rgba(8,10,15,.94) !important;
  color:#ffffff !important;
  border-color:rgba(255,255,255,.12) !important;
}

html[data-theme="light"] h1,
html[data-theme="light"] h2,
html[data-theme="light"] h3,
html[data-theme="light"] h4,
html[data-theme="light"] h5,
html[data-theme="light"] h6,
html[data-theme="light"] p,
html[data-theme="light"] span,
html[data-theme="light"] li,
html[data-theme="light"] a:not(.primary-btn):not(.glass-btn):not(.ghost-btn),
html[data-theme="light"] label,
html[data-theme="light"] button:not(.primary-btn),
html[data-theme="light"] strong,
html[data-theme="light"] b,
html[data-theme="light"] small{
  color:#111318 !important;
}
html[data-theme="dark"] h1,
html[data-theme="dark"] h2,
html[data-theme="dark"] h3,
html[data-theme="dark"] h4,
html[data-theme="dark"] p,
html[data-theme="dark"] span,
html[data-theme="dark"] li,
html[data-theme="dark"] a:not(.primary-btn):not(.glass-btn):not(.ghost-btn),
html[data-theme="dark"] label,
html[data-theme="dark"] button:not(.primary-btn),
html[data-theme="dark"] strong,
html[data-theme="dark"] b,
html[data-theme="dark"] small{
  color:#ffffff !important;
}
html[data-theme="light"] .eyebrow,
html[data-theme="light"] .accent,
html[data-theme="light"] .atlas-services-panel b,
html[data-theme="light"] .mobile-services-panel strong,
html[data-theme="light"] .content-card h3{
  color:#d71920 !important;
}
html[data-theme="dark"] .eyebrow,
html[data-theme="dark"] .accent,
html[data-theme="dark"] .atlas-services-panel b,
html[data-theme="dark"] .mobile-services-panel strong,
html[data-theme="dark"] .content-card h3{
  color:#ff3333 !important;
}
html[data-theme="light"] .hero,
html[data-theme="light"] .page-hero,
html[data-theme="light"] .service-detail-hero{
  background:radial-gradient(circle at 18% 8%, rgba(227,6,19,.15), transparent 35%), linear-gradient(135deg,#ffffff,#eef1f6) !important;
  color:#111318 !important;
}
html[data-theme="dark"] .hero,
html[data-theme="dark"] .page-hero,
html[data-theme="dark"] .service-detail-hero{
  background:radial-gradient(circle at 18% 8%, rgba(227,6,19,.24), transparent 35%), linear-gradient(135deg,#050505,#11151c) !important;
  color:#ffffff !important;
}
html[data-theme="light"] input,
html[data-theme="light"] select,
html[data-theme="light"] textarea{
  background:#fff !important; color:#111318 !important; border-color:rgba(0,0,0,.18) !important;
}
html[data-theme="dark"] input,
html[data-theme="dark"] select,
html[data-theme="dark"] textarea{
  background:#11151c !important; color:#fff !important; border-color:rgba(255,255,255,.14) !important;
}
html[data-theme="light"] .primary-btn,
html[data-theme="light"] .btn-primary,
html[data-theme="light"] .reset-filters-btn,
html[data-theme="dark"] .primary-btn,
html[data-theme="dark"] .btn-primary,
html[data-theme="dark"] .reset-filters-btn{
  background:#d71920 !important; color:#fff !important; border-color:#d71920 !important;
}
html[data-theme="light"] .primary-btn *,
html[data-theme="light"] .btn-primary *,
html[data-theme="light"] .reset-filters-btn *,
html[data-theme="dark"] .primary-btn *,
html[data-theme="dark"] .btn-primary *,
html[data-theme="dark"] .reset-filters-btn *{ color:#fff !important; }

/* services must clearly show that it has submenu */
.atlas-services-dd > a{
  display:inline-flex !important;
  align-items:center !important;
  gap:8px !important;
}
.atlas-services-dd > a::after{
  content:'▾';
  width:22px;
  height:22px;
  border-radius:50%;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  font-size:12px;
  background:rgba(227,6,19,.16);
  color:#ff3333;
  transition:.2s ease;
}
.atlas-services-dd:hover > a::after,
.atlas-services-dd:focus-within > a::after{
  transform:rotate(180deg);
  background:#d71920;
  color:#fff;
}
.atlas-services-dd::after{
  content:'';
  position:absolute;
  left:0;
  right:0;
  bottom:-22px;
  height:26px;
}
.atlas-services-panel{
  top:calc(100% + 12px) !important;
}

/* theme toggle: never hidden and always readable */
#themeBtn,
.theme-toggle{
  display:inline-flex !important;
  visibility:visible !important;
  opacity:1 !important;
  align-items:center !important;
  justify-content:center !important;
  width:42px !important;
  min-width:42px !important;
  height:42px !important;
  border-radius:999px !important;
  border:1px solid currentColor !important;
}
.theme-toggle[hidden], #themeBtn[hidden]{ display:inline-flex !important; }
html[data-theme="light"] #themeBtn,
html[data-theme="light"] .theme-toggle{ background:#111318 !important; color:#fff !important; border-color:#111318 !important; }
html[data-theme="dark"] #themeBtn,
html[data-theme="dark"] .theme-toggle{ background:rgba(255,255,255,.08) !important; color:#fff !important; border-color:rgba(255,255,255,.18) !important; }
#themeBtn i,.theme-toggle i{ color:inherit !important; }

/* mobile menu and services submenu scroll */
.mobile-services-toggle{
  display:flex !important;
  justify-content:space-between !important;
}
.mobile-services-toggle::after{ content:'▾'; }
.mobile-menu.services-open .mobile-services-toggle::after{ content:'▴'; }
@media (max-width:1180px){
  .mobile-services-panel{
    display:none !important;
    max-height:45vh !important;
    overflow-y:auto !important;
    -webkit-overflow-scrolling:touch !important;
  }
  .mobile-menu.services-open .mobile-services-panel{ display:grid !important; gap:8px !important; }
  .mobile-menu-content a,
  .mobile-menu-content button{
    color:inherit !important;
  }
}

/* centers mobile scroll */
@media (max-width:900px){
  .center-panel,
  .center-panel.no-translate{
    max-height:68vh !important;
    overflow-y:auto !important;
    overflow-x:hidden !important;
    -webkit-overflow-scrolling:touch !important;
    overscroll-behavior:contain !important;
  }
  .center-summary{
    position:sticky !important;
    top:0 !important;
    z-index:20 !important;
  }
}

/* ===== V12 REQUEST FIXES ===== */
.theme-toggle[hidden], #themeBtn[hidden]{display:inline-flex!important;visibility:visible!important;opacity:1!important;}
#themeBtn,.theme-toggle{width:46px!important;height:46px!important;border-radius:50%!important;border:1px solid rgba(255,255,255,.18)!important;background:rgba(255,255,255,.08)!important;color:#fff!important;align-items:center!important;justify-content:center!important;cursor:pointer!important;position:relative!important;z-index:20!important;}
html[data-theme="light"] #themeBtn, html[data-theme="light"] .theme-toggle{background:#111!important;color:#fff!important;border-color:#111!important;box-shadow:0 10px 25px rgba(0,0,0,.14)!important;}
#themeBtn i,.theme-toggle i{color:inherit!important;font-size:16px!important;}
html[data-theme="light"], html[data-theme="light"] body, body.light{background:#f5f6f8!important;color:#111!important;}
html[data-theme="light"] .site-header, html[data-theme="light"] .desktop-nav, html[data-theme="light"] .header-actions, html[data-theme="light"] .mobile-menu, html[data-theme="light"] .atlas-services-panel, html[data-theme="light"] .mobile-services-panel, html[data-theme="light"] .atlas-footer, html[data-theme="light"] .content-card, html[data-theme="light"] .service-detail-card, html[data-theme="light"] .franchise-value-card, html[data-theme="light"] .franchise-process-card, html[data-theme="light"] .application-glass-card, html[data-theme="light"] .service-card, html[data-theme="light"] .page-card, html[data-theme="light"] .center-card, html[data-theme="light"] .atlas-center-card, html[data-theme="light"] .center-summary, html[data-theme="light"] .filter-panel, html[data-theme="light"] .booking-card, html[data-theme="light"] .contact-card{background:#fff!important;color:#111!important;border-color:rgba(0,0,0,.12)!important;box-shadow:0 16px 42px rgba(0,0,0,.08)!important;}
html[data-theme="light"] .hero, html[data-theme="light"] .page-hero, html[data-theme="light"] .service-detail-hero{background:radial-gradient(circle at 18% 5%,rgba(227,6,19,.10),transparent 34%),linear-gradient(135deg,#fff,#f1f2f5)!important;color:#111!important;}
html[data-theme="light"] h1, html[data-theme="light"] h2, html[data-theme="light"] h3, html[data-theme="light"] h4, html[data-theme="light"] h5, html[data-theme="light"] h6, html[data-theme="light"] p, html[data-theme="light"] span, html[data-theme="light"] li, html[data-theme="light"] a:not(.primary-btn):not(.book-btn):not(.primary), html[data-theme="light"] label, html[data-theme="light"] b, html[data-theme="light"] strong, body.light h1, body.light h2, body.light h3, body.light p, body.light span, body.light li, body.light a:not(.primary-btn):not(.book-btn):not(.primary){color:#111!important;}
html[data-theme="light"] .eyebrow, html[data-theme="light"] .mega-col h3, html[data-theme="light"] .atlas-services-panel b, html[data-theme="light"] .mobile-services-panel strong, html[data-theme="light"] .section-head .eyebrow{color:#d71920!important;}
html[data-theme="light"] small, html[data-theme="light"] .muted, html[data-theme="light"] .section-head p, html[data-theme="light"] .hero-content p, html[data-theme="light"] .content-card p, html[data-theme="light"] .content-card li{color:#555!important;}
html[data-theme="light"] input, html[data-theme="light"] select, html[data-theme="light"] textarea{background:#fff!important;color:#111!important;border-color:rgba(0,0,0,.16)!important;}
html[data-theme="light"] .primary-btn, html[data-theme="light"] .book-btn, html[data-theme="light"] .primary, html[data-theme="light"] .action-book{background:#d71920!important;color:#fff!important;border-color:#d71920!important;}
html[data-theme="light"] .ghost-btn, html[data-theme="light"] .glass-btn{background:#fff!important;color:#111!important;border-color:rgba(0,0,0,.14)!important;}
.atlas-services-dd>a::after{content:"\f107";font-family:"Font Awesome 6 Free";font-weight:900;margin-inline-start:8px;font-size:12px;color:#ff2b35;display:inline-block;transition:.2s ease;}
.atlas-services-dd:hover>a::after{transform:rotate(180deg)}
.atlas-services-panel a,.mobile-services-panel a{display:block!important;}
.mobile-services-toggle::after{content:"▼";float:inline-end;margin-inline-start:8px;color:#ff2b35;font-size:12px;}
.mobile-menu.services-open .mobile-services-toggle::after{content:"▲";}
@media(max-width:991px){.mobile-services-panel{max-height:62vh!important;overflow-y:auto!important;-webkit-overflow-scrolling:touch!important}.mobile-menu-content{max-height:calc(100vh - 90px)!important;overflow-y:auto!important}.atlas-services-panel{max-height:62vh!important;overflow-y:auto!important}.map-layout{display:block!important}.centers-list,.centers-results,.center-panel{max-height:70vh!important;overflow-y:auto!important;-webkit-overflow-scrolling:touch!important}.atlas-center-card,.center-card{margin-bottom:14px!important}}
.map-section{scroll-margin-top:110px!important}.section{padding-block:clamp(42px,6vw,78px)!important}.page-hero{min-height:auto!important;padding-block:clamp(110px,12vw,150px) clamp(55px,7vw,80px)!important}.content-shell{margin-block:42px!important}.franchise-hero-bg{background-image:linear-gradient(90deg,rgba(0,0,0,.78),rgba(0,0,0,.28)),url('/static/images/saudi-business-team.svg')!important;background-size:cover!important;background-position:center!important;opacity:1!important;filter:none!important;}
html[data-theme="light"] .franchise-hero-bg{background-image:linear-gradient(90deg,rgba(255,255,255,.78),rgba(255,255,255,.18)),url('/static/images/saudi-business-team.svg')!important;}


/* ===== V13 VISUAL POLISH FIXES ===== */
/* Keep hero readable in light mode because slides use dark photo backgrounds */
html[data-theme="light"] .hero-slider,
html[data-theme="light"] .hero-slide,
html[data-theme="light"] .franchise-hero,
html[data-theme="light"] .page-hero.has-bg,
html[data-theme="light"] .visual-hero{
  color:#fff !important;
}
html[data-theme="light"] .hero-slider h1,
html[data-theme="light"] .hero-slider h1 span,
html[data-theme="light"] .hero-slider p,
html[data-theme="light"] .hero-slider .eyebrow,
html[data-theme="light"] .hero-slider .hero-content *,
html[data-theme="light"] .franchise-hero h1,
html[data-theme="light"] .franchise-hero p,
html[data-theme="light"] .franchise-hero .eyebrow{
  color:#fff !important;
  text-shadow:0 10px 28px rgba(0,0,0,.55) !important;
}
html[data-theme="light"] .hero-vignette{
  background:linear-gradient(90deg,rgba(0,0,0,.82),rgba(0,0,0,.42),rgba(0,0,0,.2)) !important;
  opacity:1 !important;
}
html[dir="ltr"][data-theme="light"] .hero-vignette{
  background:linear-gradient(270deg,rgba(0,0,0,.82),rgba(0,0,0,.42),rgba(0,0,0,.2)) !important;
}

/* Metrics must be visible in both modes */
.hero-metrics,
.metrics-row,
.stats-row,
.stats-grid{
  isolation:isolate;
}
html[data-theme="light"] .hero-metrics,
html[data-theme="light"] .metrics-row,
html[data-theme="light"] .stats-row,
html[data-theme="light"] .stats-grid{
  background:rgba(255,255,255,.94) !important;
  border:1px solid rgba(0,0,0,.12) !important;
  box-shadow:0 18px 48px rgba(0,0,0,.16) !important;
  backdrop-filter:blur(16px) !important;
}
html[data-theme="light"] .hero-metrics *,
html[data-theme="light"] .metrics-row *,
html[data-theme="light"] .stats-row *,
html[data-theme="light"] .stats-grid *{
  color:#111318 !important;
  text-shadow:none !important;
}
html[data-theme="light"] .hero-metrics strong,
html[data-theme="light"] .metrics-row strong,
html[data-theme="light"] .stats-row strong,
html[data-theme="light"] .stats-grid strong{
  color:#d71920 !important;
}
html[data-theme="dark"] .hero-metrics,
html[data-theme="dark"] .metrics-row,
html[data-theme="dark"] .stats-row,
html[data-theme="dark"] .stats-grid{
  background:rgba(5,5,5,.62) !important;
  border:1px solid rgba(255,255,255,.14) !important;
  backdrop-filter:blur(16px) !important;
}

/* Light mode mobile menu visibility */
html[data-theme="light"] .mobile-menu,
html[data-theme="light"] .mobile-menu-content,
html[data-theme="light"] .mobile-services-panel{
  background:#ffffff !important;
  color:#111318 !important;
  border-color:rgba(0,0,0,.12) !important;
}
html[data-theme="light"] .mobile-menu a,
html[data-theme="light"] .mobile-menu button,
html[data-theme="light"] .mobile-services-panel a,
html[data-theme="light"] .mobile-services-panel strong{
  color:#111318 !important;
  background:#f5f6f8 !important;
  border-color:rgba(0,0,0,.12) !important;
  text-shadow:none !important;
}
html[data-theme="light"] .mobile-menu .mobile-center-btn,
html[data-theme="light"] .mobile-menu .primary-btn{
  background:#d71920 !important;
  color:#fff !important;
}
html[data-theme="light"] .menu-btn span{
  background:#111318 !important;
}
html[data-theme="light"] .menu-btn{
  border-color:rgba(0,0,0,.16) !important;
  background:#fff !important;
}

/* Desktop services dropdown: open centered under the services button in RTL/LTR */
.atlas-services-dd{
  position:relative !important;
}
.atlas-services-panel{
  left:50% !important;
  right:auto !important;
  transform:translateX(-50%) translateY(12px) !important;
  margin-inline:0 !important;
  text-align:start !important;
}
.atlas-services-dd:hover .atlas-services-panel,
.atlas-services-dd:focus-within .atlas-services-panel,
.atlas-services-panel:hover{
  transform:translateX(-50%) translateY(0) !important;
}
html[dir="rtl"] .atlas-services-panel{
  direction:rtl !important;
}
html[dir="ltr"] .atlas-services-panel{
  direction:ltr !important;
}
@media (min-width:981px){
  .atlas-services-panel{
    width:min(820px, calc(100vw - 56px)) !important;
    max-width:820px !important;
  }
}
@media (max-width:1180px) and (min-width:981px){
  .atlas-services-panel{
    width:min(720px, calc(100vw - 32px)) !important;
  }
}

/* Premium loader: dark red by default, clean light version when selected */
.site-loader{
  background:radial-gradient(circle at 50% 35%,rgba(215,25,32,.22),transparent 32%),#030303 !important;
  transition:opacity .55s ease, visibility .55s ease !important;
}
html[data-theme="light"] .site-loader{
  background:radial-gradient(circle at 50% 35%,rgba(215,25,32,.16),transparent 34%),#f7f8fa !important;
}
.loader-ring{
  width:96px !important;
  height:96px !important;
  border:2px solid rgba(215,25,32,.22) !important;
  border-top-color:#d71920 !important;
  border-right-color:#d71920 !important;
  box-shadow:0 0 34px rgba(215,25,32,.34), inset 0 0 18px rgba(215,25,32,.12) !important;
  animation:atlasLoaderSpin .9s linear infinite !important;
}
.loader-logo{
  padding:18px 22px !important;
  border-radius:22px !important;
  background:rgba(0,0,0,.48) !important;
  border:1px solid rgba(255,255,255,.12) !important;
  box-shadow:0 22px 60px rgba(0,0,0,.38) !important;
  backdrop-filter:blur(14px) !important;
}
html[data-theme="light"] .loader-logo{
  background:rgba(255,255,255,.86) !important;
  border-color:rgba(0,0,0,.10) !important;
  box-shadow:0 22px 50px rgba(0,0,0,.12) !important;
}
.loader-logo span{
  color:#d71920 !important;
  font-size:42px !important;
  font-weight:1000 !important;
  letter-spacing:-2px !important;
  text-shadow:0 0 24px rgba(215,25,32,.42) !important;
}
.loader-logo p{
  color:#fff !important;
  letter-spacing:3px !important;
  font-weight:900 !important;
}
html[data-theme="light"] .loader-logo p{
  color:#111318 !important;
}
@keyframes atlasLoaderSpin{to{transform:rotate(360deg)}}

/* Reduce remaining huge vertical gaps */
.section{padding-block:clamp(36px,5vw,66px) !important;}
.content-shell{margin-block:34px !important;}
.page-hero{padding-block:clamp(90px,10vw,128px) clamp(42px,6vw,62px) !important;}

/* Franchise Saudi visual */
.franchise-hero-bg{
  background-image:linear-gradient(90deg,rgba(0,0,0,.78),rgba(0,0,0,.25)),url('/static/images/saudi-business-team.svg') !important;
  background-size:cover !important;
  background-position:center !important;
}
html[data-theme="light"] .franchise-hero-bg{
  background-image:linear-gradient(90deg,rgba(0,0,0,.72),rgba(0,0,0,.18)),url('/static/images/saudi-business-team.svg') !important;
}
