/**
 * WindowsWear — site-wide modern header v3
 */
:root {
  --ww-h-accent: #874390;
  --ww-h-accent-hover: #6d3578;
  --ww-h-accent-soft: rgba(135, 67, 144, 0.08);
  --ww-h-ink: #0f172a;
  --ww-h-muted: #64748b;
  --ww-h-border: #e2e8f0;
  --ww-h-bg: #ffffff;
  --ww-h-shadow: 0 1px 3px rgba(15, 23, 42, 0.06);
  --ww-h-height: 64px;
}

body.admin-bar.ww-site-modern .header-main-section { top: 32px !important; }
@media (max-width: 782px) {
  body.admin-bar.ww-site-modern .header-main-section { top: 46px !important; }
}

/* Collapse header wrapper only — fixed children must not push page flow */
body.ww-site-modern .home-before-login > .ww-header-wrap {
  height: 0 !important;
  min-height: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  overflow: visible !important;
  position: static !important;
}

/* ── Shell ──────────────────────────────────────────────── */
body.ww-site-modern .header-main-section {
  position: fixed !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
  z-index: 1000;
  background: var(--ww-h-bg);
  border-bottom: 1px solid var(--ww-h-border);
  box-shadow: none;
  overflow: visible !important;
}

body.ww-site-modern .header-main-section.ww-header--scrolled {
  box-shadow: var(--ww-h-shadow);
}

body.ww-site-modern .header-main-section .wrapper-1300 {
  max-width: 1320px;
  margin: 0 auto;
  padding: 0 24px;
}

body.ww-site-modern .header-main-section > .wrapper-1300 > .d-flex {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 16px;
  min-height: var(--ww-h-height);
}

/* ── Logo (never clip) ─────────────────────────────────── */
body.ww-site-modern .header-left-sec {
  display: flex !important;
  align-items: center !important;
  flex: 1 1 auto;
  min-width: 0;
  padding: 0 !important;
  gap: 20px;
  overflow: visible !important;
}

body.ww-site-modern .header-logo-sec {
  flex: 0 0 auto !important;
  width: auto !important;
  min-width: 155px;
  overflow: visible !important;
}

body.ww-site-modern .header-logo-sec a {
  display: block;
  line-height: 0;
}

body.ww-site-modern .header-logo-sec img,
body.ww-site-modern .header-logo-sec #logo_ww {
  width: auto !important;
  max-width: 200px !important;
  height: 36px !important;
  object-fit: contain !important;
  object-position: left center;
  display: block !important;
}

/* ── Nav ─────────────────────────────────────────────────── */
body.ww-site-modern .header-nav-sec {
  flex: 1 1 auto;
  min-width: 0;
  width: auto !important;
  overflow: visible !important;
}

body.ww-site-modern .header-main-nav-menus {
  margin: 0 !important;
  padding: 0 !important;
  display: block !important;
  overflow: visible !important;
}

/* Top-level nav row only — do NOT style .sub-menu ul as flex */
body.ww-site-modern .header-main-nav-menus > ul,
body.ww-site-modern .header-main-nav-menus ul.primary_login {
  display: flex !important;
  align-items: center;
  gap: 0;
  margin: 0 !important;
  padding: 0 !important;
  float: none !important;
  width: auto !important;
  flex-wrap: nowrap;
  overflow: visible !important;
}

body.ww-site-modern .header-main-nav-menus > ul > li,
body.ww-site-modern .header-main-nav-menus ul.primary_login > li {
  float: none !important;
  display: block !important;
  margin: 0 !important;
  list-style: none;
  position: relative;
}

body.ww-site-modern .header-main-nav-menus > ul > li > a,
body.ww-site-modern .header-main-nav-menus ul.primary_login > li > a {
  float: none !important;
  display: inline-flex !important;
  align-items: center;
  gap: 4px;
  font-family: 'Poppins', system-ui, sans-serif !important;
  font-size: 14px !important;
  font-weight: 500 !important;
  color: var(--ww-h-ink) !important;
  padding: 8px 14px !important;
  border-radius: 0 !important;
  background: transparent !important;
  text-decoration: none !important;
  white-space: nowrap;
  position: relative;
  transition: color 0.15s ease;
  box-shadow: none !important;
}

body.ww-site-modern .header-main-nav-menus > ul > li > a:hover,
body.ww-site-modern .header-main-nav-menus ul.primary_login > li > a:hover {
  color: var(--ww-h-accent) !important;
  background: transparent !important;
}

/* Active = underline, not pill */
body.ww-site-modern .header-main-nav-menus > ul > li.current-menu-item > a,
body.ww-site-modern .header-main-nav-menus > ul > li.current_page_item > a,
body.ww-site-modern .header-main-nav-menus ul.primary_login > li.current-menu-item > a,
body.ww-site-modern .header-main-nav-menus ul.primary_login > li.current_page_item > a {
  color: var(--ww-h-accent) !important;
  font-weight: 600 !important;
  background: transparent !important;
}

body.ww-site-modern .header-main-nav-menus > ul > li.current-menu-item > a::before,
body.ww-site-modern .header-main-nav-menus > ul > li.current_page_item > a::before,
body.ww-site-modern .header-main-nav-menus ul.primary_login > li.current-menu-item > a::before,
body.ww-site-modern .header-main-nav-menus ul.primary_login > li.current_page_item > a::before {
  content: '';
  position: absolute;
  bottom: 2px;
  left: 14px;
  right: 14px;
  height: 2px;
  background: var(--ww-h-accent);
  border-radius: 1px;
}

/* Kill legacy Genericons chevrons — use clean CSS arrow on parents only */
body.ww-site-modern .header-main-nav-menus .menu-item > a::after,
body.ww-site-modern .main-navigation.after_log .menu-item > a::after {
  display: none !important;
  content: none !important;
}

body.ww-site-modern .header-main-nav-menus .menu-item-has-children > a::after {
  display: inline-block !important;
  content: '' !important;
  width: 5px !important;
  height: 5px !important;
  border: none !important;
  border-right: 1.5px solid currentColor !important;
  border-bottom: 1.5px solid currentColor !important;
  transform: rotate(45deg) !important;
  position: static !important;
  margin-left: 2px !important;
  margin-top: -2px !important;
  font-family: inherit !important;
  font-size: inherit !important;
  vertical-align: middle !important;
  top: auto !important;
  right: auto !important;
}

/* ── Dropdown sub-menus (Community, News, etc.) ─────────── */
body.ww-site-modern .header-main-nav-menus .sub-menu {
  display: block !important;
  position: absolute !important;
  left: -999em !important;
  right: auto !important;
  top: calc(100% + 4px) !important;
  margin: 0 !important;
  padding: 6px 0 !important;
  min-width: 190px;
  background: #fff !important;
  border: 1px solid var(--ww-h-border) !important;
  border-radius: 10px !important;
  box-shadow: 0 8px 30px rgba(15, 23, 42, 0.12) !important;
  z-index: 1001 !important;
  float: none !important;
  width: auto !important;
  list-style: none !important;
  padding-top: 6px !important;
}

body.ww-site-modern .header-main-nav-menus .sub-menu::before,
body.ww-site-modern .header-main-nav-menus .sub-menu::after {
  display: none !important;
}

body.ww-site-modern .header-main-nav-menus li:hover > .sub-menu,
body.ww-site-modern .header-main-nav-menus li.focus > .sub-menu {
  left: 0 !important;
  right: auto !important;
}

body.ww-site-modern .header-main-nav-menus .sub-menu li {
  display: block !important;
  margin: 0 !important;
  float: none !important;
  width: 100% !important;
  border: none !important;
}

body.ww-site-modern .header-main-nav-menus .sub-menu li a {
  display: block !important;
  float: none !important;
  width: 100% !important;
  padding: 10px 16px !important;
  font-size: 13px !important;
  font-weight: 500 !important;
  color: var(--ww-h-ink) !important;
  background: transparent !important;
  border-radius: 0 !important;
  white-space: nowrap;
}

body.ww-site-modern .header-main-nav-menus .sub-menu li a:hover,
body.ww-site-modern .header-main-nav-menus .sub-menu li a:focus {
  color: #fff !important;
  background: var(--ww-h-accent) !important;
}

body.ww-site-modern .header-main-nav-menus .sub-menu li a::before {
  display: none !important;
}

/* ── Databases mega-menu panel ─────────────────────────── */
body.ww-site-modern .mega-menu-full-sec {
  z-index: 999 !important;
  top: 0 !important;
  transform: translateY(var(--ww-mega-top, 64px)) !important;
  box-shadow: 0 8px 32px rgba(15, 23, 42, 0.12) !important;
  border-top: 1px solid var(--ww-h-border);
}

/* ── Right toolbar ───────────────────────────────────────── */
body.ww-site-modern .header-right-sec {
  display: flex !important;
  align-items: center !important;
  flex: 0 0 auto;
  padding: 0 !important;
}

body.ww-site-modern .header-right-sec-menu {
  display: flex !important;
  align-items: center !important;
  gap: 4px;
  margin: 0 !important;
  padding: 0 !important;
  float: none !important;
}

body.ww-site-modern .header-right-sec-menu > li {
  display: flex !important;
  align-items: center !important;
  margin: 0 !important;
  float: none !important;
  position: relative;
  align-self: center;
}

body.ww-site-modern .header-right-sec-menu > li.membership_tab,
body.ww-site-modern .header-right-sec-menu > li.search_img {
  display: none !important;
}

/* Search */
body.ww-site-modern li.search-box-nw > a { display: none !important; }

body.ww-site-modern li.search-box-nw > span {
  background: transparent !important;
  border: none !important;
  padding: 0 !important;
  float: none !important;
  display: block !important;
  position: relative !important;
}

body.ww-site-modern .search-box-nw form {
  position: relative !important;
  margin: 0 !important;
  overflow: visible !important;
}

body.ww-site-modern li.search-box-nw {
  overflow: visible !important;
}

body.ww-site-modern .header-right-sec,
body.ww-site-modern .header-right-sec-menu {
  overflow: visible !important;
}

body.ww-site-modern .search-box-nw-input {
  width: 150px !important;
  height: 36px !important;
  padding: 0 34px 0 12px !important;
  border: 1px solid var(--ww-h-border) !important;
  border-radius: 8px !important;
  font-size: 13px !important;
  background: #f8fafc !important;
  color: var(--ww-h-ink) !important;
  box-shadow: none !important;
  float: none !important;
  text-transform: none !important;
}

body.ww-site-modern .search-box-nw-input:focus {
  outline: none !important;
  width: 180px !important;
  border-color: var(--ww-h-accent) !important;
  background: #fff !important;
  box-shadow: 0 0 0 3px var(--ww-h-accent-soft) !important;
}

body.ww-site-modern .search-box-nw-search-submit {
  position: absolute !important;
  right: 2px !important;
  top: 50% !important;
  transform: translateY(-50%) !important;
  width: 28px !important;
  height: 28px !important;
  border: none !important;
  border-left: none !important;
  background: transparent !important;
  padding: 0 !important;
  margin: 0 !important;
  float: none !important;
}

body.ww-site-modern .search-box-nw-search-submit svg {
  width: 14px !important;
  height: 14px !important;
}

/* Project button — outline pill (original style) */
body.ww-site-modern li.create_project {
  margin-right: 5px !important;
}

body.ww-site-modern .ww-header__cta,
body.ww-site-modern li.create_project > a {
  display: inline-flex !important;
  align-items: center !important;
  gap: 4px !important;
  height: auto !important;
  padding: 4px 10px !important;
  border: 1px solid var(--ww-h-accent) !important;
  border-radius: 17px !important;
  background: #fff !important;
  color: var(--ww-h-accent) !important;
  font-family: 'Poppins', sans-serif !important;
  font-size: 14px !important;
  font-weight: 600 !important;
  letter-spacing: 0.5px;
  white-space: nowrap;
  text-decoration: none !important;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1) !important;
  transform: none !important;
  transition: all 0.2s ease;
}

body.ww-site-modern .ww-header__cta:hover,
body.ww-site-modern li.create_project > a:hover {
  background: var(--ww-h-accent) !important;
  color: #fff !important;
  border-color: var(--ww-h-accent) !important;
  transform: scale(1.05) !important;
  box-shadow: 0 4px 12px rgba(135, 67, 144, 0.25) !important;
}

body.ww-site-modern .ww-header__cta svg { width: 11px !important; height: 11px !important; margin: 0 !important; }

/* Icon buttons */
body.ww-site-modern .header-message-icon,
body.ww-site-modern .header-right-sec-menu a .header-message-icon {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  width: 36px !important;
  height: 36px !important;
  border-radius: 8px !important;
  background: transparent !important;
  padding: 0 !important;
  border: none !important;
  transition: background 0.15s ease;
}

body.ww-site-modern .header-message-icon:hover,
body.ww-site-modern .header-right-sec-menu a:hover .header-message-icon {
  background: #f1f5f9 !important;
}

body.ww-site-modern .header-message-image { width: 18px !important; height: 18px !important; }

body.ww-site-modern .noti_CounterDesk {
  top: 2px !important;
  right: 2px !important;
  background: var(--ww-h-accent) !important;
  font-size: 9px !important;
  min-width: 16px !important;
  height: 16px !important;
  line-height: 16px !important;
  border: 2px solid #fff;
  border-radius: 99px;
}

body.ww-site-modern .user_pro_img.user-icon-box { padding-bottom: 0 !important; padding-top: 0 !important; }

body.ww-site-modern #user_img.user_pro_img.user-pro-tour.user-icon-box {
  padding-top: 0 !important;
}

body.ww-site-modern .user_pro_img .photo {
  width: 36px !important;
  height: 36px !important;
  border-radius: 50% !important;
  object-fit: cover;
  border: 2px solid var(--ww-h-border) !important;
}

/* Profile dropdown */
body.ww-site-modern .profile-option {
  width: 200px;
  top: calc(100% + 0px) !important;
  right: 0 !important;
  border-radius: 10px;
  border: 1px solid var(--ww-h-border);
  box-shadow: 0 8px 30px rgba(15, 23, 42, 0.12);
  padding: 6px 0;
  background: #fff;
}

body.ww-site-modern .profile-option::before { display: none !important; }
body.ww-site-modern .profile-option span { border: none !important; padding: 0 !important; }
body.ww-site-modern .profile-option span a {
  display: block !important;
  padding: 9px 16px !important;
  font-size: 13px !important;
  font-family: 'Poppins', sans-serif !important;
  color: var(--ww-h-ink) !important;
  background: transparent !important;
}

body.ww-site-modern .profile-option span a:hover {
  background: var(--ww-h-accent-soft) !important;
  color: var(--ww-h-accent) !important;
}

/* Content offset — single source; reset legacy style_window top: 111px / 80px */
body.ww-site-modern .bottom-sec-full {
  top: 0 !important;
  margin-top: 0 !important;
}

@media screen and (min-width: 1261px) {
  body.ww-site-modern .bottom-sec-full {
    top: 0 !important;
    position: relative !important;
  }
}

body.ww-site-modern.logged-in .bottom-sec-full {
  padding-top: var(--ww-h-height, 64px);
}

body.admin-bar.ww-site-modern.logged-in .bottom-sec-full {
  padding-top: calc(var(--ww-h-height, 64px) + 32px);
}

@media (max-width: 782px) {
  body.admin-bar.ww-site-modern.logged-in .bottom-sec-full {
    padding-top: calc(var(--ww-h-height, 64px) + 46px);
  }
}

/* Mobile header */
body.ww-site-modern .mobile-menu {
  padding: 10px 16px;
  border-bottom: 1px solid var(--ww-h-border);
  background: var(--ww-h-bg);
}

body.ww-site-modern .mobile-header-logo-sec .logo-img {
  max-height: 34px;
  width: auto;
  max-width: 180px;
  object-fit: contain;
}

/* Logged-out */
body.ww-site-modern .fixed_header.header_site {
  background: var(--ww-h-bg);
  border-bottom: 1px solid var(--ww-h-border);
}

@media (max-width: 1200px) {
  body.ww-site-modern .header-main-nav-menus ul li a {
    padding: 8px 10px !important;
    font-size: 13px !important;
  }
  body.ww-site-modern .search-box-nw-input { width: 130px !important; }
}

@media (max-width: 1100px) {
  body.ww-site-modern li.search-box-nw { display: none !important; }
}

