/* Compact header for phones and small tablets.
   Below 900px the six links used to stack into a right-aligned column 150px
   tall with 20px tap targets, and between 768px and 820px they crowded the
   logo. The bar is now 62px: logo, a Call button and a toggle that drops a
   full-width panel. Desktop (900px and up) is untouched. */

.nk-call,
.nk-nav-toggle,
.nk-panel-foot { display: none; }

@media screen and (max-width: 899px) {
  .navigation { min-height: 62px; padding: 0 12px; align-items: center; }
  .logo { width: 46px; height: auto; margin: 6px 0 6px -2px; }
  .navbar { flex: 1 1 auto; }
  .navbar .w-container {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 10px;
    max-width: none;
    margin: 0;
  }

  /* The highest-value tap on a phone, so it stays visible in the bar. */
  .nk-call {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    min-height: 44px;
    padding: 0 18px;
    border-radius: 999px;
    background: var(--w-mint-text, #458a78);
    color: #fff;
    font-family: Recoleta, Georgia, serif;
    font-size: 17px;
    font-weight: 700;
    text-decoration: none;
  }
  .nk-call:hover,
  .nk-call:focus { color: #fff; }

  .nk-nav-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 46px;
    height: 44px;
    padding: 0;
    background: #fff;
    border: 1.5px solid rgba(69, 138, 120, .4);
    border-radius: 12px;
    cursor: pointer;
  }
  .nk-nav-toggle > span,
  .nk-nav-toggle > span::before,
  .nk-nav-toggle > span::after {
    width: 20px;
    height: 2px;
    border-radius: 2px;
    background: var(--w-mint-text, #458a78);
  }
  .nk-nav-toggle > span { display: block; position: relative; }
  .nk-nav-toggle > span::before,
  .nk-nav-toggle > span::after {
    content: "";
    position: absolute;
    left: 0;
    transition: transform .18s ease;
  }
  .nk-nav-toggle > span::before { top: -6px; }
  .nk-nav-toggle > span::after { top: 6px; }
  .nk-nav-toggle[aria-expanded="true"] > span { background: none; }
  .nk-nav-toggle[aria-expanded="true"] > span::before { transform: translateY(6px) rotate(45deg); }
  .nk-nav-toggle[aria-expanded="true"] > span::after { transform: translateY(-6px) rotate(-45deg); }

  /* Fixed rather than absolute: the panel spans the window, not the navbar,
     and it never adds to the height of the bar behind it. */
  .navigation .navbar .nav-menu.w-nav-menu {
    display: none;
    position: fixed;
    top: var(--nk-nav-h, 62px);
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    max-height: calc(100vh - var(--nk-nav-h, 62px));
    overflow-y: auto;
    padding: 0 0 6px;
    background: #fff;
    border-top: 1px solid rgba(69, 138, 120, .18);
    box-shadow: 0 14px 28px rgba(35, 30, 60, .16);
  }
  .navigation.nk-open .navbar .nav-menu.w-nav-menu { display: flex; }

  .navigation .navigation-item {
    display: flex;
    align-items: center;
    min-height: 54px;
    margin: 0;
    padding: 0 20px;
    font-size: 19px;
    color: var(--w-mint-text, #458a78);
    border-top: 1px solid rgba(69, 138, 120, .13);
  }
  .navigation .navigation-item:first-child { border-top: 0; }
  /* The Call button covers this one. */
  .navigation .navigation-item[href^="tel:"] { display: none; }

  .navigation .nk-panel-foot {
    display: block;
    margin: 4px 0 0;
    padding: 12px 20px 4px;
    border-top: 1px solid rgba(69, 138, 120, .13);
    font-family: Recoleta, Georgia, serif;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.7;
    color: #6f6f6f;
  }
  .navigation .nk-panel-foot a {
    color: var(--w-cornflower-blue, #517df0);
    text-decoration: none;
  }
}
