@import url('https://fonts.googleapis.com/css2?family=Nunito:wght@400;500;600;700;800&display=swap');

html, body {
  font-family: 'Nunito', sans-serif;
}

/* ── Site-wide header ─────────────────────────────────────────────────────── */

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 52px;
  background: #0b1d12;
  border-bottom: 1px solid rgba(126, 207, 154, 0.1);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1.5rem;
  z-index: 1000;

}

.site-header-logo {
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.5px;
  color: #fff;
  line-height: 1;
  transition: opacity 0.15s ease;
}

.site-header-logo:hover {
  opacity: 0.8;
}

/* Right side grouping */

.site-header-right {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

/* User section */

.site-header-user {
  position: relative;
}

.site-header-user-btn {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: none;
  border: none;
  padding: 0.3rem 0.5rem;
  border-radius: 6px;
  cursor: pointer;
  color: rgba(255, 255, 255, 0.85);
  font-size: 0.875rem;
  font-weight: 500;
  transition: background 0.15s ease, color 0.15s ease;
}

.site-header-user-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
}

.site-header-initial {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: #1e4a2e;
  border: 1px solid rgba(126, 207, 154, 0.35);
  color: #7ecf9a;
  font-size: 0.75rem;
  font-weight: 700;
  flex-shrink: 0;
  line-height: 1;
}

.site-header-username {
  max-width: 120px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.site-header-caret {
  font-size: 0.7rem;
  opacity: 0.6;
  margin-left: -0.1rem;
}

/* Dropdown */

.site-header-dropdown {
  position: absolute;
  top: calc(100% + 0.5rem);
  right: 0;
  background: #0f2116;
  border: 1px solid rgba(126, 207, 154, 0.18);
  border-radius: 8px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
  min-width: 160px;
  overflow: hidden;
  animation: headerDropdown 0.15s ease-out;
}

@keyframes headerDropdown {
  from { opacity: 0; transform: translateY(-4px); }
  to   { opacity: 1; transform: translateY(0); }
}

.site-header-dropdown-name {
  padding: 0.65rem 1rem 0.4rem;
  font-size: 0.78rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.4);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.site-header-dropdown-item {
  display: block;
  width: 100%;
  padding: 0.75rem 1rem;
  background: none;
  border: none;
  text-align: left;
  cursor: pointer;
  color: rgba(255, 255, 255, 0.75);
  font-size: 0.875rem;
  font-weight: 500;
  transition: background 0.15s ease, color 0.15s ease;
}

.site-header-dropdown-item:hover {
  background: rgba(255, 255, 255, 0.06);
  color: #fff;
}

/* ── Burger button ─────────────────────────────────────────────────────────── */

.site-header-nav {
  position: relative;
}

.site-header-burger {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 36px;
  height: 36px;
  background: none;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  padding: 0;
  transition: background 0.15s ease;
}

.site-header-burger:hover {
  background: rgba(255, 255, 255, 0.08);
}

.site-header-burger span {
  display: block;
  width: 18px;
  height: 2px;
  background: rgba(255, 255, 255, 0.85);
  border-radius: 2px;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.site-header-burger--open span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.site-header-burger--open span:nth-child(2) {
  opacity: 0;
}

.site-header-burger--open span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* ── Mobile nav menu ───────────────────────────────────────────────────────── */

.site-header-nav-menu {
  position: fixed;
  top: 52px;
  left: 0;
  right: 0;
  background: #0b1d12;
  border-bottom: 1px solid rgba(126, 207, 154, 0.15);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
  display: flex;
  flex-direction: column;
  z-index: 999;
  animation: navMenuIn 0.18s ease-out;
}

@keyframes navMenuIn {
  from { opacity: 0; transform: translateY(-6px); }
  to   { opacity: 1; transform: translateY(0); }
}

.site-header-nav-item {
  display: block;
  width: 100%;
  padding: 0.9rem 1.5rem;
  background: none;
  border: none;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  text-align: left;
  cursor: pointer;
  color: rgba(255, 255, 255, 0.8);
  font-size: 1rem;
  font-weight: 500;

  transition: background 0.15s ease, color 0.15s ease;
}

.site-header-nav-item:hover:not(:disabled) {
  background: rgba(255, 255, 255, 0.05);
  color: #fff;
}

.site-header-nav-item--active {
  color: #7ecf9a;
  font-weight: 600;
  cursor: default;
}

.site-header-nav-divider {
  height: 1px;
  background: rgba(255, 255, 255, 0.1);
  margin: 0.25rem 0;
}

.site-header-nav-item--signout {
  color: rgba(255, 255, 255, 0.5);
  font-size: 0.9rem;
}

.site-header-nav-item--signout:hover {
  color: rgba(255, 255, 255, 0.8);
}

/* ── Responsive ────────────────────────────────────────────────────────────── */

@media (max-width: 639px) {
  .site-header-burger {
    display: flex;
  }

  .site-header-username,
  .site-header-caret {
    display: none;
  }
}
