@view-transition {
  navigation: auto;
}

html {
  background: #07080a;
}

.topbar {
  position: relative;
  z-index: 20;
  padding: 18px clamp(18px, 7.5vw, 110px) 0;
  background: transparent;
}

.topbar .nav-wrap {
  position: relative;
  max-width: 1320px;
  height: 68px;
  margin: 0 auto;
  padding: 0 14px 0 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 20px;
  background: rgba(10,11,14,.94);
  box-shadow: 0 18px 50px rgba(0,0,0,.34), inset 0 1px rgba(255,255,255,.025);
  backdrop-filter: blur(18px);
  view-transition-name: public-topbar;
}

.topbar .brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  flex: none;
  text-decoration: none;
}

.topbar .brand-mark {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  overflow: visible;
}

.topbar .brand-mark img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 5px 12px rgba(255,255,255,.1));
}

.topbar .brand-copy {
  display: flex;
  flex-direction: column;
  line-height: 1;
}

.topbar .brand-name {
  font-size: 16px;
  font-weight: 800;
  letter-spacing: .13em;
}

.topbar .brand-tagline {
  margin-top: 6px;
  color: #70747d;
  font-size: 9px;
  font-weight: 600;
  letter-spacing: .23em;
}

.topbar .desktop-nav {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%,-50%);
  display: flex;
  align-items: center;
  gap: 4px;
  isolation: isolate;
}

.topbar .desktop-nav a {
  position: relative;
  padding: 10px 14px;
  border-radius: 9px;
  color: #a8abb3;
  background: transparent;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: .1em;
  text-decoration: none;
  white-space: nowrap;
  z-index: 1;
  transition: color .22s ease, background .22s ease;
}

.topbar .desktop-nav a:hover {
  color: #f7f7f8;
  background: rgba(255,255,255,.035);
}

.topbar .desktop-nav a[aria-current="page"] {
  color: #f7f7f8;
  background: transparent;
}

.topbar .public-nav-indicator {
  position: absolute;
  z-index: 0;
  top: 0;
  bottom: 0;
  left: 0;
  width: 0;
  border-radius: 9px;
  background: rgba(255,255,255,.07);
  pointer-events: none;
  transform: translateX(0);
  transition: width .38s cubic-bezier(.22,.8,.22,1), transform .38s cubic-bezier(.22,.8,.22,1);
  view-transition-name: public-nav-active;
}

.topbar .nav-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.topbar .dashboard-link {
  padding: 11px 17px;
  border: 1px solid rgba(255,255,255,.19);
  border-radius: 10px;
  background: rgba(255,255,255,.045);
  color: #f7f7f8;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .11em;
  text-decoration: none;
  transition: background .2s ease, border-color .2s ease, transform .2s ease;
}

.topbar .dashboard-link:hover {
  transform: translateY(-1px);
  border-color: rgba(255,255,255,.34);
  background: rgba(255,255,255,.08);
}

.topbar .menu-button {
  width: 43px;
  height: 43px;
  display: none;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(255,255,255,.11);
  border-radius: 10px;
  background: rgba(255,255,255,.035);
  cursor: pointer;
}

.topbar .menu-button svg {
  width: 20px;
  height: 20px;
}

main {
  view-transition-name: public-page-content;
}

html.public-page-leaving main {
  opacity: 0;
  transform: translateY(-7px);
  transition: opacity .16s ease, transform .16s ease;
}

html.public-page-entering main {
  animation: public-page-in .34s cubic-bezier(.22,.8,.22,1) both;
}

::view-transition-group(public-topbar),
::view-transition-group(public-nav-active) {
  animation-duration: .38s;
  animation-timing-function: cubic-bezier(.22,.8,.22,1);
}

::view-transition-old(public-topbar),
::view-transition-new(public-topbar),
::view-transition-old(public-nav-active),
::view-transition-new(public-nav-active) {
  mix-blend-mode: normal;
}

::view-transition-old(public-page-content) {
  animation: public-page-out .18s ease both;
}

::view-transition-new(public-page-content) {
  animation: public-page-in .34s cubic-bezier(.22,.8,.22,1) both;
}

@keyframes public-page-out {
  to { opacity: 0; transform: translateY(-7px); }
}

@keyframes public-page-in {
  from { opacity: 0; transform: translateY(9px); }
}

@media (max-width: 1120px) {
  .topbar .desktop-nav,
  .topbar .dashboard-link {
    display: none;
  }

  .topbar .menu-button {
    display: inline-flex;
  }
}

@media (max-width: 780px) {
  .topbar {
    padding: 12px 14px 0;
  }

  .topbar .nav-wrap {
    height: 64px;
    padding: 0 12px 0 15px;
    border-radius: 16px;
  }

  .topbar .brand-mark {
    width: 42px;
    height: 42px;
  }

  .topbar .brand-tagline {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  ::view-transition-group(*),
  ::view-transition-old(*),
  ::view-transition-new(*) {
    animation-duration: .01ms !important;
  }

  .topbar .public-nav-indicator,
  html.public-page-leaving main {
    transition-duration: .01ms !important;
  }
}
