:root {
  --header-height: 70px;
  --bg-color: #ffffff;
  --text-color: #222;
  --hover-color: #555;
  --border-color: #eaeaea;
  --transition: 0.3s ease-in-out;
  --mega-max-width: 1000px;
}

.custom-header * { box-sizing: border-box; margin: 0; padding: 0; }
.custom-header {
  height: var(--header-height);
  background: var(--bg-color);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 20px;
  border-bottom: 1px solid var(--border-color);
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 3000;
}

.header-logo img { height: 45px; }

.navbar { display: flex; gap: 30px; list-style: none; }
.navbar li { position: relative; }
.navbar li a {
  padding: 5px;
  color: var(--text-color);
  border: none !important;
  text-decoration: none !important;
  box-shadow: none !important;
  background: transparent !important;
  white-space: nowrap;
}
.navbar li a:hover { color: var(--hover-color); }

/* Remove underline or Divi styling globally */
#main-header,
.et_pb_menu,
.navbar li,
.navbar li a,
.navbar li::after,
.navbar li a::after {
  border: none !important;
  box-shadow: none !important;
  text-decoration: none !important;
  background: transparent !important;
}

/* Mega Menu Styling */
.navbar .mega-submenu {
  position: absolute;
  left: 0;
  top: 100%;
  background: #fff;
  padding: 20px;
  display: none;
  gap: 30px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.1);
  max-width: var(--mega-max-width);
  min-width: 400px;
  width: auto;
  white-space: nowrap;
}
.navbar li:hover > .mega-submenu { display: flex; }
.navbar .mega-submenu li {
  padding: 8px 0;
  width: auto;
}
.navbar .mega-submenu li a {
  display: block;
  padding: 5px 0;
  font-size: 15px;
  width: 100%;
}
.navbar .mega-submenu li:not(:last-child) a { border-bottom: 1px solid #eaeaea; }

.mega-submenu.columns-1,
.mega-submenu.columns-2,
.mega-submenu.columns-3,
.mega-submenu.columns-4,
.mega-submenu.columns-5,
.mega-submenu.columns-6 {
  flex-wrap: nowrap;
}

/* Desktop Icons */
.header-icons i { 
  width: 20px; 
  height: 20px; 
  stroke-width: 0.8; 
}

.hamburger { display: none; cursor: pointer; }
.hamburger i { 
  width: 28px; 
  height: 28px; 
  stroke-width: 0.8;
}

.mobile-right-icon { display: none; }
.mobile-right-icon i { 
  width: 22px; 
  height: 22px; 
  stroke-width: 0.8;
}

/* Mobile Menu */
.mobile-menu {
  position: fixed;
  top: var(--header-height);
  left: -100%;
  width: 100%;
  height: calc(100% - var(--header-height));
  background: var(--bg-color);
  transition: left var(--transition);
  padding: 20px;
  display: flex;
  flex-direction: column;
  z-index: 2000;
  overflow-y: auto;
}
.mobile-menu.open { left: 0; }
.mobile-menu-top { display: flex; justify-content: flex-end; height: 40px; margin-bottom: 10px; }
.mobile-menu-top i { width: 28px; height: 28px; cursor: pointer; stroke-width: 0.8; }

/* Main menu links in hamburger */
.mobile-navbar { list-style: none; margin: 0; padding: 0; }
.mobile-navbar li { border-bottom: 1px solid var(--border-color); }
.mobile-navbar li a { 
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 0;
  font-size: 18px;
  text-decoration: none !important;
  color: var(--text-color);
}

/* Hide ALL submenus in hamburger by default */
.mobile-navbar ul.sub-menu { display: none !important; }

.mobile-extra-html { margin-top: 60px; font-size: 14px; color: #444; }

/* Mobile submenu panel */
.mobile-submenu {
  display: none;
  flex-direction: column;
  animation: slideIn 0.3s ease forwards;
}
.mobile-submenu.active { display: flex; }

/* Submenu links */
.mobile-submenu-list { list-style: none; margin: 0; padding: 0; }
.mobile-submenu-list li {
  border-bottom: 1px solid var(--border-color);
}
.mobile-submenu-list li a {
  display: block;
  padding: 15px 0;
  font-size: 18px;
  text-decoration: none !important;
  color: var(--text-color);
}

@keyframes slideIn {
  from { transform: translateX(100%); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}

/* Desktop triggers hamburger when cramped */
@media (max-width: 1100px) {
  .navbar, .header-icons { display: none; }
  .hamburger, .mobile-right-icon { display: block; }
  .custom-header { justify-content: space-between; }
  .header-logo { position: absolute; left: 50%; transform: translateX(-50%); }
}

/* Desktop hamburger sidebar style */
@media (min-width: 1101px) {
  .mobile-menu { width: 400px; }
}

/* Make all Feather icons thinner */
.feather {
  stroke-width: 1 !important;
}

#desktop-header-placeholder,
#desktop-header-section,
#mobile-header-placeholder,
#mobile-header-section {
  display: none !important;
}

/* Button Styles */
.chs-button {
  display: inline-block;
  padding: 8px 16px;
  border: 1px solid #F1F1F1;
  border-radius: 50px;
  background-color: #F1F1F1;
  text-decoration: none !important;
  color: #000;
  font-size: 14px;
  line-height: 1;
}
.chs-button:hover {
  background-color: #fff;
}

@media (max-width: 767px) {
  .chs-button {
    font-size: 12px;
    padding: 6px 12px;
  }
}

