/* Shared mobile menu and line arrows. Loaded after each page's own stylesheet. */

/* Drawn arrow that replaces the ↗ glyph, which iOS renders as an emoji. */
.arrow-ne {
  display: inline-block;
  width: .78em;
  height: .78em;
  margin-left: .12em;
  vertical-align: -.04em;
  background: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='black' stroke-width='1.3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3.5 12.5 12.5 3.5M5.5 3.5h7v7'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='black' stroke-width='1.3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3.5 12.5 12.5 3.5M5.5 3.5h7v7'/%3E%3C/svg%3E") center / contain no-repeat;
}

.menu-toggle,
.site-menu {
  display: none;
}

@media (max-width: 800px) {
  /* The inline links move into the menu on small screens. */
  .nav nav,
  .site-header nav {
    display: none !important;
  }

  .menu-toggle {
    position: fixed;
    top: 14px;
    right: max(14px, 4.5vw);
    z-index: 1001;
    display: grid;
    place-items: center;
    width: 46px;
    height: 46px;
    padding: 0;
    border: 1px solid rgba(25, 27, 30, .14);
    border-radius: 50%;
    background: rgba(243, 241, 235, .82);
    -webkit-backdrop-filter: blur(10px);
            backdrop-filter: blur(10px);
    color: #191B1E;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    transition: background .3s, border-color .3s;
  }

  .menu-toggle span {
    position: absolute;
    left: 14px;
    width: 18px;
    height: 1px;
    background: currentColor;
    transition: transform .4s cubic-bezier(.7, 0, .2, 1), top .4s cubic-bezier(.7, 0, .2, 1);
  }

  .menu-toggle span:first-child { top: 19px; }
  .menu-toggle span:last-child { top: 26px; }

  .menu-open .menu-toggle {
    background: transparent;
    border-color: rgba(190, 145, 96, .5);
  }

  .menu-open .menu-toggle span:first-child { top: 22.5px; transform: rotate(45deg); }
  .menu-open .menu-toggle span:last-child { top: 22.5px; transform: rotate(-45deg); }

  .site-menu {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    padding: 92px 9% 34px;
    overflow-y: auto;
    background: #F3F1EB;
    color: #191B1E;
    font-family: Manrope, sans-serif;
    opacity: 0;
    visibility: hidden;
    transition: opacity .35s ease, visibility 0s linear .35s;
  }

  .menu-open .site-menu {
    opacity: 1;
    visibility: visible;
    transition: opacity .35s ease;
  }

  .menu-open,
  .menu-open body {
    overflow: hidden;
  }

  .site-menu::before {
    content: "";
    position: absolute;
    right: -38%;
    top: 7%;
    width: 92%;
    aspect-ratio: 1;
    border: 1px solid rgba(190, 145, 96, .2);
    border-radius: 50%;
    pointer-events: none;
  }

  .site-menu-label {
    margin: 0 0 22px;
    color: #8A5F2C;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .2em;
  }

  .site-menu ol {
    margin: 0;
    padding: 0;
    list-style: none;
  }

  .site-menu li {
    border-bottom: 1px solid #D3D0C9;
    opacity: 0;
    transform: translateY(10px);
    transition: opacity .45s ease, transform .45s ease;
  }

  .menu-open .site-menu li {
    opacity: 1;
    transform: none;
  }

  .site-menu ol a {
    display: flex;
    align-items: baseline;
    gap: 18px;
    padding: 15px 0;
    color: inherit;
    text-decoration: none;
    font: 400 clamp(29px, 8.4vw, 38px)/1.15 Lora, serif;
    letter-spacing: -.02em;
  }

  .site-menu ol a small {
    min-width: 20px;
    color: #8A5F2C;
    font: 500 10px Manrope, sans-serif;
    letter-spacing: .12em;
  }

  .site-menu ol a[aria-current="page"] {
    color: #8A5F2C;
    font-style: italic;
  }

  .site-menu-talk {
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    align-self: flex-start;
    margin-top: 34px;
    padding: 17px 26px;
    border-radius: 3px;
    background: #BE9160;
    color: #191B1E;
    text-decoration: none;
    font-size: 15px;
    font-weight: 600;
  }

  .site-menu-social {
    display: flex;
    gap: 22px;
    margin-top: auto;
    padding-top: 40px;
    font-size: 12px;
    letter-spacing: .08em;
  }

  .site-menu-social a {
    color: #555752;
    text-decoration: none;
  }
}

@media (max-width: 800px) and (prefers-reduced-motion: reduce) {
  .site-menu,
  .site-menu li,
  .menu-toggle span {
    transition: none !important;
  }
}

/* Hero ring on the homepage: stop it where Jan's portrait fades out, so it never peeks out below him. */
@media (max-width: 800px) {
  .hero .orbit {
    clip-path: inset(-40px -40px calc(100% - 254px) -40px);
  }
}

@media (max-width: 420px) {
  .hero .orbit {
    clip-path: inset(-40px -40px calc(100% - 217px) -40px);
  }
}
