/* Header — glass pill nav (matches topa.io) */
[data-topa-header],
.topa-header {
  display: contents;
}

.topa-nav-panel,
.bg-nav__cta,
.ah-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  text-decoration: none;
  padding: 10px 18px;
  border-radius: 999px;
  background: #1d1b19;
  border: 1px solid rgba(255, 255, 255, 0.14);
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 13.5px;
  font-weight: 600;
  color: #fff;
  white-space: nowrap;
  transition: background 0.18s ease, border-color 0.18s ease;
  cursor: pointer;
}

.topa-nav-panel:hover,
.bg-nav__cta:hover,
.ah-cta:hover {
  background: #2a2724;
  border-color: rgba(255, 255, 255, 0.28);
}

.topa-nav-panel-inner {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: inherit;
  font: inherit;
  padding: 0;
  white-space: nowrap;
}

.topa-nav-panel-icon,
.topa-nav-panel-divider {
  display: none;
}

.ah-cta svg {
  width: 13px;
  height: 13px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2.2;
  flex-shrink: 0;
}

.ah-cta {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.55);
  color: #fff;
  padding: 12px 22px;
  font-size: 14px;
}

.ah-cta:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.85);
  color: #fff;
}

.topa-nav-panel--legal {
  background: transparent;
  border-color: rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.62);
  font-size: 13px;
  font-weight: 500;
}

.topa-nav-panel--legal:hover {
  background: rgba(255, 255, 255, 0.04);
  border-color: rgba(255, 255, 255, 0.16);
  color: #fff;
}

.bg-nav-wrap {
  position: sticky;
  top: calc(18px + var(--safe-top));
  z-index: 120;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 calc(28px + var(--safe-right)) 0 calc(28px + var(--safe-left));
}

.topa-logo {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  text-decoration: none;
  line-height: 1;
  flex-shrink: 0;
  margin-right: 4px;
}

.topa-logo img {
  height: 30.6px;
  width: auto;
  display: block;
}

.bg-nav {
  display: flex;
  align-items: center;
  gap: 26px;
  width: max-content;
  max-width: 100%;
  padding: 8px 12px 8px 18px;
  border-radius: 999px;
  background: rgba(18, 14, 36, 0.55);
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow:
    0 10px 40px rgba(0, 0, 0, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(18px) saturate(1.35);
  -webkit-backdrop-filter: blur(18px) saturate(1.35);
}

.bg-nav__links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2px;
  flex: 0 0 auto;
}

.bg-nav__link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 13.5px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.88);
  text-decoration: none;
  padding: 8px 12px;
  border-radius: 999px;
  transition: color 0.18s ease, background 0.18s ease;
  white-space: nowrap;
  flex-shrink: 0;
}

.bg-nav__link:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.07);
}

.bg-nav__link.is-active {
  color: #fff;
}

.bg-nav__actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.bg-nav__cta {
  margin-left: 0;
  border-radius: 999px;
  font-size: 13.5px;
  font-weight: 600;
  padding: 9px 16px;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.55);
  color: #fff;
  transition: background 0.18s ease, border-color 0.18s ease;
}

.bg-nav__cta:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.85);
  color: #fff;
}

.topa-nav-mobile-wrap,
.topa-nav-drawer,
.topa-nav-backdrop,
.topa-nav-toggle {
  display: none;
}

.topa-kb-menu {
  position: relative;
}

.topa-kb-menu__label--mobile {
  display: none;
}

.topa-kb-menu__mobile-extras {
  display: none;
}

.topa-kb-menu__chevron {
  width: 14px;
  height: 14px;
  fill: none;
  stroke: rgba(255, 255, 255, 0.55);
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: transform 0.2s ease, stroke 0.18s ease;
  flex-shrink: 0;
}

.topa-kb-menu__trigger:hover .topa-kb-menu__chevron,
.topa-kb-menu.is-open .topa-kb-menu__chevron {
  stroke: rgba(255, 255, 255, 0.9);
}

.topa-kb-menu.is-open .topa-kb-menu__chevron {
  transform: rotate(180deg);
}

.topa-kb-menu__panel {
  position: absolute;
  top: calc(100% + 12px);
  left: 0;
  right: auto;
  width: min(680px, calc(100vw - 32px));
  padding: 14px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: linear-gradient(180deg, rgba(20, 17, 36, 0.97) 0%, rgba(12, 10, 26, 0.98) 100%);
  box-shadow:
    0 10px 40px rgba(0, 0, 0, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(18px) saturate(1.35);
  -webkit-backdrop-filter: blur(18px) saturate(1.35);
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px) scale(0.98);
  transform-origin: top left;
  transition:
    opacity 0.22s ease,
    transform 0.22s ease,
    visibility 0.22s ease;
  z-index: 1100;
  pointer-events: none;
}

.topa-kb-menu__panel::before {
  content: "";
  position: absolute;
  top: -12px;
  left: 0;
  right: 0;
  height: 12px;
}

.topa-kb-menu.is-open .topa-kb-menu__panel,
.topa-kb-menu:hover .topa-kb-menu__panel {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}

.topa-kb-menu__body {
  max-height: 420px;
  overflow-y: auto;
  padding-right: 4px;
  scrollbar-width: auto;
  scrollbar-color: rgba(255, 255, 255, 0.3) rgba(255, 255, 255, 0.06);
}

.topa-kb-menu__body::-webkit-scrollbar {
  width: 12px;
}

.topa-kb-menu__body::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.06);
  border-radius: 999px;
}

.topa-kb-menu__body::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.3);
  border: 2px solid transparent;
  background-clip: padding-box;
  border-radius: 999px;
}

.topa-kb-menu__section + .topa-kb-menu__section {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.topa-kb-menu__panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 2px 4px 10px;
  margin-bottom: 8px;
  text-decoration: none;
  border-radius: 8px;
  transition: background 0.18s ease;
}

.topa-kb-menu__panel-head:hover,
.topa-kb-menu__panel-head:focus-visible {
  background: rgba(255, 255, 255, 0.06);
  outline: none;
}

.topa-kb-menu__panel-title {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: #fff;
}

.topa-kb-menu__panel-count {
  font-size: 11px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.45);
  white-space: nowrap;
}

.topa-kb-menu__list {
  column-count: 2;
  column-gap: 4px;
}

.topa-kb-menu__item {
  display: block;
  width: 100%;
  min-width: 0;
  break-inside: avoid;
  -webkit-column-break-inside: avoid;
  margin-bottom: 4px;
  padding: 9px 10px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 500;
  line-height: 1.35;
  color: rgba(255, 255, 255, 0.78);
  text-decoration: none;
  border: 1px solid transparent;
  position: relative;
  transition:
    color 0.18s ease,
    background 0.18s ease,
    border-color 0.18s ease;
}

.topa-kb-menu__item:hover,
.topa-kb-menu__item:focus-visible {
  color: #fff;
  background: rgba(255, 255, 255, 0.07);
  border-color: rgba(255, 255, 255, 0.16);
  outline: none;
}

.topa-kb-menu__item-title {
  display: block;
}

.topa-kb-menu__item-desc {
  display: block;
  margin-top: 2px;
  font-size: 11px;
  font-weight: 400;
  line-height: 1.3;
  color: rgba(255, 255, 255, 0.48);
}

.topa-kb-menu.is-open .topa-kb-menu__item,
.topa-kb-menu:hover .topa-kb-menu__item {
  animation: topa-kb-item-in 0.35s ease both;
}

@keyframes topa-kb-item-in {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.topa-kb-menu__all {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 10px;
  padding: 10px 14px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.55);
  background: transparent;
  font-size: 13px;
  font-weight: 600;
  color: #fff;
  text-decoration: none;
  transition: background 0.18s ease, border-color 0.18s ease, color 0.18s ease;
}

.topa-kb-menu__all:hover,
.topa-kb-menu__all:focus-visible {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.85);
  color: #fff;
  outline: none;
}

@media (hover: none) and (min-width: 769px) {
  .topa-kb-menu:hover .topa-kb-menu__panel {
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px) scale(0.98);
    pointer-events: none;
  }

  .topa-kb-menu.is-open .topa-kb-menu__panel {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
    pointer-events: auto;
  }
}

@media (max-width: 1200px) {
  .bg-nav__link {
    padding: 8px 8px;
    font-size: 13px;
  }

  .bg-nav__cta {
    padding: 8px 12px;
    font-size: 13px;
  }
}

@media (max-width: 1080px) {
  .bg-nav__cta--book {
    display: none;
  }
}

@media (max-width: 900px) {
  .bg-nav__links {
    display: flex;
    flex: 0 0 auto;
    justify-content: flex-start;
    gap: 2px;
  }

  .bg-nav__link {
    padding: 7px 8px;
    font-size: 12.5px;
  }

  .bg-nav {
    width: auto;
    max-width: 100%;
    padding: 6px 8px 6px 12px;
    gap: 6px;
  }

  .bg-nav__cta {
    padding: 8px 14px;
    font-size: 13px;
  }

  .bg-nav__cta--login,
  .bg-nav__cta--book {
    display: none;
  }

  .bg-nav__cta--trial {
    padding: 8px 10px;
  }

  .bg-nav-wrap {
    padding: 0 14px;
    padding-left: calc(14px + var(--safe-left));
    padding-right: calc(14px + var(--safe-right));
    top: calc(12px + var(--safe-top));
  }

  .topa-kb-menu__label--desktop {
    display: none;
  }

  .topa-kb-menu__label--mobile {
    display: inline;
  }

  .topa-kb-menu__mobile-extras {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
  }

  .topa-kb-menu__mobile-link {
    display: block;
    padding: 10px 12px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.1);
  }

  .topa-kb-menu__mobile-link:hover,
  .topa-kb-menu__mobile-link:focus-visible {
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
    outline: none;
  }

  .topa-kb-menu__panel {
    position: fixed;
    top: calc(12px + var(--safe-top, 0px) + 56px);
    left: 12px;
    right: 12px;
    width: auto;
    max-height: min(70vh, 520px);
    overflow: auto;
    transform-origin: top center;
  }

  .topa-kb-menu__body,
  .topa-kb-menu__all {
    display: none;
  }

  .topa-kb-menu:hover .topa-kb-menu__panel {
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px) scale(0.98);
    pointer-events: none;
  }

  .topa-kb-menu.is-open .topa-kb-menu__panel {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
    pointer-events: auto;
  }

  .topa-kb-menu:hover .topa-kb-menu__item {
    animation: none;
  }

  .topa-kb-menu.is-open .topa-kb-menu__item {
    animation: topa-kb-item-in 0.35s ease both;
  }
}

@media (max-width: 768px) {
  .topa-logo img {
    height: 20.16px;
  }

  .bg-nav-wrap {
    padding: 0 14px;
    padding-left: calc(14px + var(--safe-left));
    padding-right: calc(14px + var(--safe-right));
    top: calc(12px + var(--safe-top));
  }

  .bg-nav__cta--trial {
    display: none;
  }

  .bg-nav__links > a.bg-nav__link {
    display: none;
  }
}

@media (max-width: 640px) {
  .bg-nav__link {
    padding: 7px 7px;
    font-size: 12px;
  }
}

