.ortho-toggle {
  appearance: none;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--ink);
  text-align: start;
}

.ortho-toggle svg {
  flex: none;
  transition: transform 170ms ease;
}

.ortho-toggle[aria-expanded="true"] svg {
  transform: rotate(180deg);
}

.ortho-links {
  margin: 0;
  list-style: none;
}

.ortho-links[hidden] {
  display: none;
}

:is(.hdr, #en-home-header .hdr) .nav {
  align-self: stretch;
}

:is(.hdr, #en-home-header .hdr) .nav > a:not(.visit) {
  position: relative;
  border-bottom-color: transparent;
}

.ortho-disclosure--desktop {
  position: relative;
  display: flex;
  align-self: stretch;
  align-items: center;
}

.ortho-disclosure--desktop .ortho-toggle {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 40px;
  padding: 3px 0;
  font: 400 14px/1.4 var(--sans);
  white-space: nowrap;
}

:is(.hdr, #en-home-header .hdr) .nav > a:not(.visit)::after,
.ortho-disclosure--desktop .ortho-toggle::after {
  position: absolute;
  inset: auto 0 0;
  height: 1px;
  transform: scaleX(0);
  transform-origin: left;
  background: #8c7765;
  transition: transform 220ms ease;
  content: "";
}

.ortho-disclosure--desktop .ortho-toggle::after {
  inset-block-end: 3px;
}

:is(.hdr, #en-home-header .hdr) .nav > a:not(.visit):is(:hover, :focus-visible, [aria-current="page"])::after,
.ortho-disclosure--desktop .ortho-toggle:is(:hover, [aria-expanded="true"])::after {
  transform: scaleX(1);
}

.ortho-disclosure--desktop .ortho-links {
  position: absolute;
  inset-block-start: 100%;
  inset-inline-start: -16px;
  width: 232px;
  padding: 6px 15px;
  background: #fcfbf7;
  border: 1px solid #e2d9ce;
  border-top-color: #cec0b2;
  box-shadow: 0 10px 22px rgb(45 32 23 / 7%);
  animation: ortho-reveal 160ms ease-out;
}

:is(.hdr, #en-home-header .hdr) .nav .ortho-links a {
  display: flex;
  align-items: center;
  min-height: 44px;
  padding: 8px 0;
  border: none;
  font-size: 14px;
  transition: color 150ms ease;
}

:is(.hdr, #en-home-header .hdr) .nav .ortho-links li + li {
  border-top: 1px solid #eee7de;
}

:is(.hdr, #en-home-header .hdr) .nav .ortho-links a:is(:hover, :focus-visible, [aria-current="page"]) {
  color: #805452;
  border: none;
}

.ortho-disclosure--mobile {
  border-bottom: 1px solid #dcd2c7;
}

.ortho-disclosure--mobile .ortho-toggle {
  display: flex;
  width: 100%;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 44px;
  padding: 10px 2px 10px 0;
  font: 400 19px/1.35 var(--serif);
}

.ortho-disclosure--mobile .ortho-links {
  margin: 0 0 9px 1px;
  padding: 0 0 0 14px;
  border-inline-start: 1px solid #dcd2c7;
  animation: ortho-reveal 160ms ease-out;
}

.ortho-disclosure--mobile .ortho-links a {
  display: flex;
  align-items: center;
  min-height: 44px;
  color: #584d45;
  font: 400 15px/1.35 var(--sans);
  text-decoration: none;
}

.ortho-disclosure--mobile .ortho-links a:is(:hover, :focus-visible) {
  color: #805452;
}

.ortho-disclosure :is(.ortho-toggle, a):focus-visible {
  outline-offset: -2px;
}

@keyframes ortho-reveal {
  from { opacity: 0; }
  to { opacity: 1; }
}

@media (min-width: 1181px) and (max-width: 1400px) {
  .ortho-disclosure--desktop .ortho-toggle {
    font-size: 13px;
  }
}

@media (min-width: 1181px) and (max-width: 1320px) {
  .ortho-disclosure--desktop .ortho-toggle {
    font-size: 12px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .ortho-disclosure .ortho-links {
    animation: none;
  }

  :is(.hdr, #en-home-header .hdr) .nav > a:not(.visit)::after,
  .ortho-disclosure--desktop .ortho-toggle::after,
  .ortho-disclosure :is(svg, a) {
    transition: none;
  }
}

.ortho-disclosure--desktop:has(.ortho-links a[aria-current="page"]) .ortho-toggle::after {
  transform: scaleX(1);
}

.ortho-disclosure--mobile .ortho-links a[aria-current="page"] {
  color: #805452;
}

#en-home-header .ortho-disclosure :is(.ortho-toggle, a):focus-visible {
  outline-offset: -2px;
}
