/* Global shell: header only.
 * Never styles Elementor page content and never hides/restyles the restored footer.
 */

#smouha-global-header,
#smouha-global-header * {
  box-sizing: border-box;
}

#smouha-global-header.smgh {
  position: relative;
  z-index: 9990;
  width: 100%;
  margin: 0;
  padding: 0;
  min-height: 82px;
  background: #F2F2EF;
  color: #252729;
  font-family: "Cairo", sans-serif !important;
  visibility: visible;
  opacity: 1;
}

#smouha-global-header .smgh-shell {
  width: min(calc(100% - 32px), 1350px);
  height: 82px;
  min-height: 82px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 180px minmax(0,1fr) 52px;
  align-items: center;
  gap: 20px;
  padding: 0 18px;
  border: 1px solid #DEDDD7;
  border-radius: 0 0 18px 18px;
  background: #FFFDF8;
  box-shadow: 0 8px 26px rgba(37,39,41,.055);
}

#smouha-global-header .smgh-brand {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  width: fit-content;
  text-decoration: none !important;
}

#smouha-global-header .smgh-brand img {
  display: block;
  width: auto;
  max-width: 160px;
  max-height: 56px;
  height: auto;
  object-fit: contain;
}

#smouha-global-header .smgh-nav { min-width: 0; }

#smouha-global-header .smgh-menu,
#smouha-global-header .smgh-menu ul,
#smouha-global-header .smgh-mobile-menu,
#smouha-global-header .smgh-mobile-menu ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

#smouha-global-header .smgh-menu {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
}

#smouha-global-header .smgh-menu > li {
  position: relative;
  margin: 0;
}

#smouha-global-header .smgh-menu > li > a {
  min-height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 14px;
  border-radius: 10px;
  color: #252729 !important;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.4;
  text-decoration: none !important;
  white-space: nowrap;
}

#smouha-global-header .smgh-menu > li > a:hover,
#smouha-global-header .smgh-menu > li.current-menu-item > a,
#smouha-global-header .smgh-menu > li.current_page_item > a,
#smouha-global-header .smgh-menu > li.current-menu-ancestor > a {
  background: #F3EEE4;
  color: #8D742F !important;
}

#smouha-global-header .smgh-menu .sub-menu {
  position: absolute;
  z-index: 20;
  top: calc(100% + 8px);
  right: 0;
  min-width: 230px;
  display: none;
  padding: 10px;
  border: 1px solid #DEDDD7;
  border-radius: 14px;
  background: #FFFDF8;
  box-shadow: 0 16px 34px rgba(37,39,41,.10);
}

#smouha-global-header .smgh-menu li:hover > .sub-menu,
#smouha-global-header .smgh-menu li:focus-within > .sub-menu {
  display: block;
}

#smouha-global-header .smgh-menu .sub-menu a {
  display: block;
  padding: 10px 12px;
  border-radius: 8px;
  color: #252729 !important;
  font-size: 13px;
  font-weight: 650;
  text-decoration: none !important;
}

#smouha-global-header .smgh-menu .sub-menu a:hover {
  background: #F7F4EE;
  color: #8D742F !important;
}

#smouha-global-header .smgh-toggle {
  width: 44px !important;
  height: 44px !important;
  display: none !important;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
  padding: 0 !important;
  border: 1px solid #DEDDD7 !important;
  border-radius: 11px !important;
  background: #FFFDF8 !important;
  box-shadow: none !important;
  cursor: pointer;
}

#smouha-global-header .smgh-toggle span {
  width: 20px;
  height: 2px;
  display: block;
  border-radius: 3px;
  background: #252729;
}

#smouha-global-header .smgh-mobile-panel {
  width: min(calc(100% - 16px), 1350px);
  margin: 8px auto 0;
  padding: 10px;
  border: 1px solid #DEDDD7;
  border-radius: 14px;
  background: #FFFDF8;
  box-shadow: 0 16px 34px rgba(37,39,41,.10);
}

#smouha-global-header .smgh-mobile-menu a {
  display: block;
  padding: 12px 14px;
  border-radius: 9px;
  color: #252729 !important;
  font-weight: 700;
  text-decoration: none !important;
}

#smouha-global-header .smgh-mobile-menu a:hover,
#smouha-global-header .smgh-mobile-menu .current-menu-item > a {
  background: #F7F4EE;
  color: #8D742F !important;
}

#smouha-global-header .smgh-mobile-menu .sub-menu {
  padding-inline-start: 12px;
}

/* Parent header is replaced by the new global header. Footer is intentionally untouched. */
body.smouha-shell-design > header.header-style-six,
body.smouha-shell-design header.header-style-six:not(#smouha-global-header),
body.smouha-shell-design .smh-header {
  display: none !important;
}

html[dir="ltr"] #smouha-global-header .smgh-shell {
  direction: ltr;
  grid-template-columns: 180px minmax(0,1fr) 52px;
}
html[dir="ltr"] #smouha-global-header .smgh-brand { justify-self: start; }
html[dir="ltr"] #smouha-global-header .smgh-menu { flex-direction: row; }
html[dir="ltr"] #smouha-global-header .smgh-menu .sub-menu { left: 0; right: auto; }

@media (max-width: 991px) {
  #smouha-global-header.smgh { min-height: 70px; }
  #smouha-global-header .smgh-shell {
    width: calc(100% - 16px);
    height: 70px;
    min-height: 70px;
    grid-template-columns: minmax(0,1fr) 52px;
    padding-inline: 12px;
    border-radius: 0 0 14px 14px;
  }
  #smouha-global-header .smgh-nav { display: none; }
  #smouha-global-header .smgh-toggle { display: inline-flex !important; }
  #smouha-global-header .smgh-brand img {
    max-width: 138px;
    max-height: 46px;
  }
}

@media (max-width: 767px) {
  #smouha-global-header .smgh-shell,
  #smouha-global-header .smgh-mobile-panel {
    width: calc(100% - 10px);
  }
  #smouha-global-header .smgh-brand img { max-width: 128px; }
}


/* Public directory title strip cleanup.
 * Hides only the parent ReLand title/breadcrumb hero above restored Elementor content.
 * Does not touch Elementor page content itself.
 */
body.page-id-298 .breadcrumb-area,
body.page-id-3562 .breadcrumb-area,
body.page-id-2090 .breadcrumb-area,
body.page-id-3572 .breadcrumb-area,
body.page-id-1808 .breadcrumb-area,
body.page-id-3576 .breadcrumb-area,
body.page-id-2046 .breadcrumb-area,
body.page-id-3579 .breadcrumb-area,
body.page-id-1131 .breadcrumb-area,
body.page-id-3543 .breadcrumb-area,
body.page-id-10 .breadcrumb-area,
body.page-id-3567 .breadcrumb-area,
body.page-id-298 .page-title-area,
body.page-id-3562 .page-title-area,
body.page-id-2090 .page-title-area,
body.page-id-3572 .page-title-area,
body.page-id-1808 .page-title-area,
body.page-id-3576 .page-title-area,
body.page-id-2046 .page-title-area,
body.page-id-3579 .page-title-area,
body.page-id-1131 .page-title-area,
body.page-id-3543 .page-title-area,
body.page-id-10 .page-title-area,
body.page-id-3567 .page-title-area {
  display: none !important;
  visibility: hidden !important;
  height: 0 !important;
  min-height: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  overflow: hidden !important;
}

body.page-id-298 .main-area-wrapper,
body.page-id-3562 .main-area-wrapper,
body.page-id-2090 .main-area-wrapper,
body.page-id-3572 .main-area-wrapper,
body.page-id-1808 .main-area-wrapper,
body.page-id-3576 .main-area-wrapper,
body.page-id-2046 .main-area-wrapper,
body.page-id-3579 .main-area-wrapper,
body.page-id-1131 .main-area-wrapper,
body.page-id-3543 .main-area-wrapper,
body.page-id-10 .main-area-wrapper,
body.page-id-3567 .main-area-wrapper {
  margin-top: 0 !important;
  padding-top: 0 !important;
}


/* Homepage footer ownership.
 * On the homepage only, hide the restored ReLand footer and show the custom footer.
 * Inner pages keep the restored ReLand footer untouched.
 */
body.home footer:not(#smouha-footer-clean),
body.home #colophon,
body.home .site-footer:not(#smouha-footer-clean) {
  display: none !important;
}

body.home #smouha-footer-clean {
  display: block !important;
}
