/* Mobile menu for the static copy of the old site.
 *
 * The theme hides #site-navigation at 768px and below and relied on a jQuery "sidr" script
 * for its hamburger menu; that script was removed in the static export, so phones had no
 * navigation. This replaces it with a native <details> disclosure: no JavaScript, keyboard
 * accessible, and announced as expanded/collapsed by screen readers. The markup is in each
 * page's header (`.tkt-menu`), generated from that page's own menu.
 */

.tkt-menu {
  display: none;
}

@media screen and (max-width: 768px) {
  #masthead {
    position: relative;
  }

  .tkt-menu {
    display: block;
    text-align: left;
  }

  /* Above the theme's full-width title banner (.site-branding has z-index: 1), which would
     otherwise catch the tap; sized to fit inside the 49px header. */
  .tkt-menu > summary {
    position: absolute;
    z-index: 10;
    top: 4px;
    right: 8px;
    display: flex;
    align-items: center;
    gap: 6px;
    box-sizing: border-box;
    min-height: 41px;
    padding: 0 12px;
    border: 1px solid rgba(255, 255, 255, 0.6);
    border-radius: 4px;
    color: #fff;
    font-size: 16px;
    font-weight: 600;
    line-height: 1;
    cursor: pointer;
    list-style: none;
  }

  .tkt-menu > summary::-webkit-details-marker {
    display: none;
  }

  .tkt-menu > summary::before {
    content: "\2630"; /* ☰ */
    font-size: 20px;
  }

  .tkt-menu[open] > summary::before {
    content: "\2715"; /* ✕ */
    font-size: 16px;
  }

  .tkt-menu > summary:focus-visible {
    outline: 3px solid #fff;
    outline-offset: 2px;
  }

  .tkt-menu ul {
    margin: 12px 0 0;
    padding: 0;
    list-style: none;
    border-top: 1px solid rgba(255, 255, 255, 0.3);
  }

  .tkt-menu li {
    margin: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
  }

  .tkt-menu li a {
    display: block;
    padding: 12px 20px;
    color: #fff;
    font-size: 17px;
    line-height: 24px;
    text-decoration: none;
  }

  .tkt-menu li a:hover,
  .tkt-menu li a:focus-visible,
  .tkt-menu li a[aria-current="page"] {
    background: rgba(0, 0, 0, 0.2);
    color: #fff;
  }

  .tkt-menu li a[aria-current="page"] {
    font-weight: 700;
  }
}
