/* The menu in the header below 1000 px, the same on the home, the 14 guides and the 404 (the guides and the 404 had
   none before, so on a phone there was no way to another part of the site or to another language from their header). The home's
   menu lists its own parts; the guides' and the 404's list the home's parts. The languages are added by tools/site-i18n.mjs.
   The variables have the 404's names as fallbacks (it has its own smaller style) */
.site-menu{display:none}
@media (max-width:999px){
  .top nav .hide-s,.top nav>.btn-ghost{display:none}
  .top nav .get-top{order:-1}
  /* gaps in px, not rem: with the text at 200 % a rem gap pushed the guides' header 15 px past a 390 px phone */
  .top>.wrap{gap:min(.5rem,8px)}
  .top nav{gap:min(.5rem,8px)}
  .site-menu{display:block;position:static;border:0!important;counter-increment:none}
  .site-menu summary{display:grid;place-items:center;width:44px;height:44px;padding:0;border:1px solid var(--line2,var(--t-line-strong));border-radius:50%;color:var(--ink);font:500 .85rem/1 var(--sans);list-style:none;cursor:pointer}
  .site-menu summary::-webkit-details-marker{display:none}
  .site-menu summary::before,.site-menu summary::after{display:none}
  .site-menu summary svg{width:20px;height:20px}
  .site-menu[open] summary{background:var(--t-surface3);color:var(--t-accent-light)}
  .site-menu::details-content{transition:none;overflow:visible}
  .site-menu:not([open]) .menu-links{display:none}
  .site-menu .menu-links{position:absolute;z-index:60;top:calc(100% + .5rem);right:var(--gutter,var(--g));left:var(--gutter,var(--g));max-height:calc(100dvh - var(--top-h,4rem) - 1.5rem);overflow:auto;overscroll-behavior:contain;display:grid;grid-template-columns:minmax(0,1fr);gap:0;padding:1rem;border:1px solid var(--line2,var(--t-line-strong));border-radius:16px;background:var(--t-bg);box-shadow:0 18px 45px rgb(0 0 0/.5)}
  /* the menu is a <details>: padding 0 so the FAQ's "details p" leaves no empty row under the title */
  .menu-links p{grid-column:1/-1;margin:0 0 .25rem;padding:0 .75rem;max-width:none;color:var(--ink3);font:500 .75rem/1.4 var(--sans);letter-spacing:0}
  /* the parts one per row, each 48 px with a hairline (in two columns a name on two lines, Как это работает, made rows of
     different heights); the languages stay two columns */
  .top nav .menu-links a{display:flex;align-items:center;min-height:48px;padding:.6rem .75rem;border-radius:6px;white-space:normal;color:var(--ink2);font:500 1rem/1.3 var(--sans);text-decoration:none}
  .top nav .menu-links>a{border-bottom:1px solid var(--line,var(--t-line));border-radius:0}
  .top nav .menu-links>a:last-of-type{border-bottom:0}
  .menu-links .menu-langs{align-items:start}
  @media (hover:hover){.top nav .menu-links a:hover{background:var(--t-surface);color:var(--ink)}}
  .site-menu :is(a,summary):focus-visible{outline:2px solid var(--t-accent-light);outline-offset:2px}
  body:has(.site-menu[open]) :is(.where,.pause,.gw-ctl){visibility:hidden}
}
