.site-nav {
  --nav-hover: #e5d17d;
  --nav-ink: #0e1c36;
  --nav-bg: #fafefe;
  --nav-line: 2px solid var(--nav-ink);

  position: relative;
  z-index: 20;
  background: var(--nav-bg);
  color: var(--nav-ink);
  font-family: "Libre Franklin", sans-serif;
}

.site-nav,
.site-nav * {
  box-sizing: border-box;
}

.bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 104px;
  padding: 4px 16px 4px 8px;
  background: var(--nav-bg);
}

.logo {
  display: flex;
  align-items: center;
  flex: 0 0 auto;
  line-height: 0;
  text-decoration: none;
}

.logo img,
.logo svg {
  display: block;
  height: 88px;
  width: auto;
}

.menu-button,
.balance {
  display: none;
}

.links {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 4px;
  margin-left: auto;
}

.nav-item,
.nav-work,
.mobile-link,
.mobile-label {
  color: var(--nav-ink);
  font-family: "Libre Franklin", sans-serif;
  font-style: italic;
  font-weight: 600;
  font-size: 16px;
  line-height: 20px;
  text-decoration: none;
}

.nav-item {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  padding: 20px;
  border: 0;
  border-radius: 4px;
  background: transparent;
  text-transform: uppercase;
  cursor: pointer;
}

.nav-item.is-hover,
.nav-item.is-current,
.nav-work.is-hover,
.nav-work.is-current,
.mobile-link.is-hover,
.mobile-link.is-current,
.mobile-label.is-current,
.menu-button.is-hover {
  background: var(--nav-hover);
}

.nav-item:focus-visible,
.nav-work:focus-visible,
.menu-button:focus-visible,
.logo:focus-visible {
  outline: 2px solid var(--nav-ink);
  outline-offset: 2px;
}

.dropdown {
  position: relative;
}

.chevron {
  display: block;
  flex: 0 0 auto;
  transition: transform 180ms ease;
}

.nav-item.is-open .chevron {
  transform: rotate(180deg);
}

.panel {
  position: absolute;
  top: 100%;
  left: 0;
  z-index: 30;
  padding-top: 8px;
  min-width: 100%;
}

.panel-list,
.mobile-works {
  display: flex;
  flex-direction: column;
  min-width: 280px;
  background: var(--nav-bg);
  border: var(--nav-line);
}

.nav-work {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 44px;
  padding: 14px 16px;
  background: transparent;
  text-transform: none;
}

.nav-work + .nav-work {
  border-top: var(--nav-line);
}


.mobile-panel {
  display: none;
}

.menu-button {
  width: 44px;
  height: 44px;
  align-items: center;
  justify-content: center;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 4px;
  background: transparent;
  color: var(--nav-ink);
  cursor: pointer;
}

.burger {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  width: 22px;
  height: 14px;
}

.burger span {
  display: block;
  height: 2px;
  background: currentColor;
  transform-origin: center;
  transition: transform 180ms ease, opacity 180ms ease;
}

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

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

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

@media (max-width: 900px) {
  .bar {
    display: grid;
    grid-template-columns: 44px 1fr 44px;
    align-items: center;
    min-height: 64px;
    padding: 8px 12px;
  }

  .menu-button {
    display: inline-flex;
    grid-column: 1;
    justify-self: start;
  }

  .logo {
    grid-column: 2;
    justify-self: center;
  }

  .logo img,
  .logo svg {
    height: 64px;
  }

  .balance {
    display: block;
    grid-column: 3;
  }

  .links {
    display: none;
  }

  .mobile-panel {
    display: grid;
    grid-template-rows: 0fr;
    background: var(--nav-bg);
    border-top: var(--nav-line);
    transition: grid-template-rows 240ms ease;
  }

  .mobile-panel.is-open {
    grid-template-rows: 1fr;
  }

  .mobile-panel-inner {
    overflow: hidden;
  }

  .mobile-link,
  .mobile-label {
    display: flex;
    align-items: center;
    min-height: 52px;
    margin: 0;
    padding: 16px 20px;
    border-bottom: var(--nav-line);
    background: transparent;
    text-transform: uppercase;
  }

  .mobile-works {
    min-width: 0;
    border: 0;
    border-bottom: var(--nav-line);
  }

  .mobile-works .nav-work {
    padding-left: 32px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .mobile-panel,
  .chevron,
  .burger span {
    transition: none;
  }
}

