/* veylox.uk — the menu a phone gets.
 *
 * WHY THIS FILE EXISTS. Until 2026-11-09 a phone got no menu at all. The
 * header's five text links are hidden below 880px by `.nav-links a.plain
 * {display:none}`, which has been true on every page of this site since the
 * breakpoint was written, so a phone showed the logo and "Open the app" and
 * nothing else. Tools, Pricing, Blog and both audience pages were unreachable
 * from the header on a phone. Marco asked for Tools back, at the bottom of the
 * menu; there was no menu for it to sit at the bottom of, so this is the menu.
 *
 * The button and the sheet are drawn ONLY below 880px. Above it the ordinary
 * `.nav-links` row is unchanged and neither of these elements renders, so
 * nothing about the desktop header moves.
 *
 * The colours are the site's own tokens. The fallbacks are the literal values
 * those tokens hold in site.css, blog.css and the inline <style> of the pages
 * that have one, so a page that somehow loads this file without them still
 * draws a legible menu rather than black on black.
 */

.nav-burger { display: none; }
.nav-sheet { display: none; }

@media (max-width: 880px) {
  /* `margin-left:auto` is what seats the button beside "Open the app" rather
     than halfway across the bar: .nav is `justify-content:space-between`, and
     a third child would otherwise be spread to the middle. */
  .nav-burger {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 4px;
    width: 44px;
    height: 44px;
    padding: 0 10px;
    margin-left: auto;
    margin-right: 10px;
    background: transparent;
    border: 0;
    cursor: pointer;
  }
  .nav-burger span {
    display: block;
    height: 2px;
    background: var(--head, #13243f);
    border-radius: 2px;
  }

  .nav-sheet {
    display: block;
    border-top: 1px solid var(--line, #e5eaf3);
  }
  /* The sheet starts closed. `[hidden]` has to beat the rule above, which is
     why it is spelled out rather than left to the browser default. */
  .nav-sheet[hidden] { display: none; }

  .nav-sheet a {
    display: block;
    padding: 13px 0;
    color: var(--body, #46586f);
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    border-bottom: 1px solid var(--line, #e5eaf3);
  }
  .nav-sheet a:last-child { border-bottom: 0; }
  .nav-sheet a:hover { color: var(--head, #13243f); }

  /* The keyboard ring, spelled out (CTO-審 2026-11-09, N2). Nothing on this
     site switches the browser default off, so this is not a repair; it is
     that the default ring on a transparent, borderless button is faint, and
     the button is the only way into this menu without a mouse. :focus-visible
     so a tap does not leave a ring behind it. */
  .nav-burger:focus-visible,
  .nav-sheet a:focus-visible {
    outline: 2px solid var(--blue, #2f80ed);
    outline-offset: 2px;
    border-radius: 4px;
  }
}

/* 🩸 320px, AND THE BUTTON THIS MENU PUSHED ONTO TWO LINES.
   A 44px button plus its margin is 54px taken out of a 284px bar, and at
   320px that was exactly the margin "Open the app" had: measured, the call to
   action came back 133px wide and 81px tall, which is a label wrapped in half.
   On origin/main at the same width it is one line. So the menu paid for
   itself out of the one control that was already there, and this buys the
   space back rather than leaving the regression to a screenshot nobody takes
   at 320.

   ⛔ Scoped to `.nav`, not to `.btn`: every other button on the site keeps
   the padding it has. */
@media (max-width: 400px) {
  .nav-burger { width: 38px; padding: 0 8px; margin-right: 4px; }
  .nav .logo { width: 104px; }
  .nav-links .btn { padding: 11px 14px; font-size: 15px; white-space: nowrap; }
}
