/* ==========================================================================
   WARD — Header, Single-Line Navigation & Green Dropdown Menus
   ========================================================================== */

.site-header {
  position: relative;
  z-index: 150;
  background: #ffffff;
  border-bottom: 1px solid var(--border-subtle);
  box-shadow: 0 2px 10px rgba(18, 65, 22, 0.04);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 80px;
  gap: 16px;
}

/* Responsive Logo */
.brand-link {
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
}

.brand-logo-img {
  height: 48px;
  width: auto;
  max-width: 170px;
  object-fit: contain;
  display: block;
}

@media (min-width: 768px) {
  .brand-logo-img {
    height: 60px;
    max-width: 210px;
  }
}

/* Desktop Single-Line Navigation */
.desktop-nav {
  display: none;
  align-items: center;
  gap: 0;
}

@media (min-width: 1024px) {
  .desktop-nav {
    display: flex;
  }
}

.nav-item {
  position: relative;
  display: flex;
  align-items: center;
}

.nav-item + .nav-item::before {
  content: "";
  display: inline-block;
  width: 1.5px;
  height: 15px;
  background-color: #6ab04c;
  margin: 0 11px;
  flex-shrink: 0;
}

.nav-link {
  font-family: var(--font-display);
  font-size: 0.98rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: #1f2b22;
  white-space: nowrap;
  padding: 12px 2px;
  transition: color 0.18s ease;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.nav-item:hover > .nav-link,
.nav-link.active {
  color: #1c7c2c;
}

/* Green Dropdown Panel (anando-bd.org style) */
.nav-dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  background-color: #1c7c2c;
  color: #ffffff;
  min-width: 230px;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.18);
  opacity: 0;
  visibility: hidden;
  transform: translateY(6px);
  transition: opacity 0.18s ease, transform 0.18s ease, visibility 0.18s;
  z-index: 200;
  border-radius: 0 0 6px 6px;
  overflow: hidden;
}

.nav-dropdown.cols-2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(205px, 1fr));
  min-width: 420px;
}

.nav-dropdown.align-right {
  left: auto;
  right: 0;
}

.nav-item:hover > .nav-dropdown,
.nav-item:focus-within > .nav-dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.nav-dropdown a {
  display: block;
  padding: 12px 18px;
  font-size: 0.88rem;
  font-weight: 500;
  color: #ffffff;
  white-space: nowrap;
  border-bottom: 1px solid rgba(255, 255, 255, 0.14);
  transition: background-color 0.15s ease, padding-left 0.15s ease;
}

.nav-dropdown a:hover {
  background-color: #145e20;
  padding-left: 22px;
}

/* Header Right Actions */
.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.search-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid transparent;
  background: transparent;
  color: #243026;
  transition: background-color 0.15s;
}

.search-btn:hover {
  background-color: var(--bg-sage-soft);
  color: var(--brand-green);
}

.menu-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border: 1px solid var(--border-subtle);
  background: #ffffff;
  border-radius: var(--radius-sm);
  color: var(--text-main);
}

@media (min-width: 1024px) {
  .menu-toggle {
    display: none;
  }
}

/* Mobile Drawer with Accordions */
.mobile-drawer {
  position: fixed;
  inset: 0;
  z-index: 300;
  background: rgba(18, 40, 20, 0.5);
  display: none;
  justify-content: flex-end;
}

.mobile-drawer.open {
  display: flex;
}

.mobile-drawer-panel {
  width: 320px;
  max-width: 88vw;
  background: #ffffff;
  height: 100%;
  padding: 20px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
  box-shadow: -8px 0 24px rgba(0, 0, 0, 0.18);
}

.mobile-drawer-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border-subtle);
}

.mobile-nav-group {
  border-bottom: 1px solid #eef3ee;
  padding: 6px 0;
}

.mobile-nav-group summary {
  font-family: var(--font-display);
  font-size: 1.08rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--brand-green-dark);
  padding: 8px 4px;
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.mobile-nav-group summary::after {
  content: "+";
  font-size: 1.2rem;
  color: var(--brand-green);
}

.mobile-nav-group[open] summary::after {
  content: "−";
}

.mobile-sublinks {
  display: flex;
  flex-direction: column;
  padding: 4px 0 8px 12px;
  gap: 6px;
}

.mobile-sublinks a {
  font-size: 0.9rem;
  color: var(--text-muted);
  padding: 5px 0;
}

.mobile-sublinks a:hover {
  color: var(--brand-green);
}

.mobile-direct-link {
  font-family: var(--font-display);
  font-size: 1.08rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--brand-green-dark);
  padding: 10px 4px;
  border-bottom: 1px solid #eef3ee;
  display: block;
}

/* Search Modal */
.search-modal-input {
  width: 100%;
  padding: 12px 16px;
  font-size: 1rem;
  border: 1.5px solid var(--brand-green);
  border-radius: var(--radius-sm);
  margin-bottom: 14px;
  font-family: inherit;
}

.search-results-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 320px;
  overflow-y: auto;
}

.search-result-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  background: var(--bg-sage-soft);
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--brand-green-dark);
}

.search-result-item:hover {
  background: var(--bg-sage-light);
}

.search-result-cat {
  font-size: 0.75rem;
  color: var(--text-muted);
  text-transform: uppercase;
}
