/* V6.11 — Compact floating capsule navigation */
:root {
  --header-height: 82px;
}

html {
  scroll-padding-top: calc(var(--header-height) + 20px);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  height: auto;
  min-height: var(--header-height);
  padding: 10px 0 0;
  border: 0;
  background: transparent;
  box-shadow: none;
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
}

.site-header .nav-wrap {
  box-sizing: border-box;
  width: min(calc(100% - 40px), 1120px);
  height: auto;
  min-height: 62px;
  margin: 0 auto;
  padding: 6px 10px 6px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: clamp(12px, 1.8vw, 24px);
  border: 1px solid rgba(255, 255, 255, .84);
  border-radius: 999px;
  background: linear-gradient(112deg,
    rgba(255, 249, 241, .91) 0%,
    rgba(255, 247, 249, .87) 52%,
    rgba(246, 239, 255, .89) 100%);
  box-shadow: 0 12px 32px rgba(102, 69, 85, .10),
              0 2px 8px rgba(102, 69, 85, .04),
              inset 0 1px 0 rgba(255, 255, 255, .92);
  -webkit-backdrop-filter: blur(22px) saturate(1.16);
  backdrop-filter: blur(22px) saturate(1.16);
}

.site-header .brand {
  flex: 0 0 auto;
  gap: 8px;
  min-width: max-content;
}

.site-header .brand-logo {
  width: 44px;
  height: 44px;
  flex-basis: 44px;
}

.site-header .brand-text strong {
  font-size: 18px;
  letter-spacing: -.025em;
}

.site-header .brand-text span {
  margin-top: 1px;
  font-size: 9px;
  letter-spacing: .13em;
}

.site-header .nav-links {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2px;
  padding: 4px;
  border: 1px solid rgba(255, 255, 255, .56);
  border-radius: 999px;
  background: rgba(255, 255, 255, .27);
}

.site-header .nav-links a {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  white-space: nowrap;
  padding: 8px 12px;
  border: 1px solid transparent;
  border-radius: 999px;
  color: #6c5965;
  font-size: 13px;
  font-weight: 550;
  line-height: 1.2;
  background: transparent;
  transition: color .18s ease, background .18s ease, box-shadow .18s ease, border-color .18s ease;
}

.site-header .nav-links a::after {
  display: none !important;
  content: none !important;
}

.site-header .nav-links a:hover,
.site-header .nav-links a.active,
.site-header .nav-links a[aria-current="page"] {
  color: #5f3e68;
  border-color: rgba(255, 255, 255, .88);
  background: linear-gradient(120deg, rgba(255, 255, 255, .82), rgba(242, 226, 247, .75));
  box-shadow: 0 3px 10px rgba(111, 75, 117, .07), inset 0 1px 0 rgba(255, 255, 255, .9);
}

.site-header .nav-actions {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 8px;
}

.site-header .nav-actions .btn {
  min-height: 40px;
  padding: 8px 15px;
  border: 1px solid rgba(255, 255, 255, .38);
  border-radius: 999px;
  color: #fff;
  font-size: 13px;
  white-space: nowrap;
  background: linear-gradient(120deg, #9675c9 0%, #b77b91 100%);
  box-shadow: 0 7px 16px rgba(139, 94, 137, .18), inset 0 1px 0 rgba(255, 255, 255, .2);
}

.site-header .mobile-toggle {
  width: 40px;
  height: 40px;
  border: 1px solid rgba(255, 255, 255, .9);
  border-radius: 50%;
  color: #674c72;
  background: rgba(255, 255, 255, .68);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .9);
}

@media (max-width: 1180px) {
  :root {
    --header-height: 76px;
  }

  .site-header {
    padding-top: 8px;
    min-height: var(--header-height);
  }

  .site-header .nav-wrap {
    width: calc(100% - 32px);
    min-height: 58px;
    padding: 5px 8px 5px 12px;
    gap: 10px;
  }

  .site-header .nav-links {
    display: none;
  }

  .site-header .nav-links.open {
    position: fixed;
    inset: calc(var(--header-height) + 4px) 16px auto;
    z-index: 92;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: stretch;
    justify-content: stretch;
    gap: 8px;
    max-height: calc(100svh - var(--header-height) - 24px);
    padding: 13px;
    overflow-y: auto;
    border: 1px solid rgba(255, 255, 255, .88);
    border-radius: 24px;
    background: linear-gradient(125deg, rgba(255, 249, 242, .97), rgba(250, 240, 250, .97));
    box-shadow: 0 24px 60px rgba(78, 54, 81, .19), inset 0 1px 0 rgba(255, 255, 255, .9);
    -webkit-backdrop-filter: blur(24px);
    backdrop-filter: blur(24px);
  }

  .site-header .nav-links.open a {
    min-height: 44px;
    padding: 12px 13px;
    border: 1px solid rgba(255, 255, 255, .8);
    border-radius: 999px;
    text-align: center;
    background: rgba(255, 255, 255, .56);
  }

  .site-header .nav-links.open a:hover,
  .site-header .nav-links.open a.active,
  .site-header .nav-links.open a[aria-current="page"] {
    background: rgba(239, 224, 247, .88);
  }

  .site-header .nav-links.open a::after {
    display: none !important;
  }
}

@media (max-width: 780px) {
  :root {
    --header-height: 70px;
  }

  .site-header .nav-wrap {
    width: calc(100% - 24px);
    min-height: 54px;
    padding: 4px 6px 4px 10px;
  }

  .site-header .brand-logo {
    width: 40px;
    height: 40px;
    flex-basis: 40px;
  }

  .site-header .brand-text strong {
    font-size: 16px;
  }

  .site-header .brand-text span {
    display: none;
  }

  .site-header .mobile-toggle {
    width: 38px;
    height: 38px;
  }

  .site-header .nav-actions .btn {
    display: none;
  }

  .site-header .nav-links.open {
    inset: calc(var(--header-height) + 4px) 12px auto;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 380px) {
  .site-header .nav-wrap {
    width: calc(100% - 16px);
    gap: 6px;
    padding-left: 7px;
  }

  .site-header .brand {
    gap: 5px;
  }

  .site-header .brand-logo {
    width: 36px;
    height: 36px;
    flex-basis: 36px;
  }

  .site-header .brand-text strong {
    font-size: 15px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .site-header .nav-links a {
    transition: none;
  }
}
