/* ============================================================
   Overlay-menu search — the single-rule field and its motion.
   Injected by site-search.js after site.css, so at equal
   specificity these rules are the later ones and win.

   The "Search" line in the menu and the field it opens are one
   object: a magnifier, a word, a hairline. Opening search does
   not swap one for the other. The line travels up and extends
   (site-search.js measures and plays that), while the rest of
   the menu clears around it.
   ============================================================ */

/* ---- the line in the menu: its hairline is a layer that can be drawn ---- */
.menu-search-trigger{position:relative;}
@media not (forced-colors:active){
  .menu-search-trigger,.menu-search-trigger:hover,.menu-search-trigger:focus-visible,.menu-search-trigger:active{border-bottom-color:transparent;}
}
.menu-search-trigger::after{content:"";position:absolute;left:0;right:0;bottom:-1px;height:1px;background:currentColor;opacity:.48;
  transform-origin:left center;transition:opacity .25s ease;}
.menu-search-trigger:hover::after,.menu-search-trigger:focus-visible::after,.menu-search-trigger:active::after{opacity:1;}
@media (forced-colors:active){.menu-search-trigger::after{display:none;}}

/* ---- the field: the same hairline, no box ---- */
.menu-search-form{gap:12px;padding-inline:2px 0;border:0;border-radius:0;background:transparent;}
.menu-search-form:focus-within{border-color:transparent;}
.menu-search-glyph{flex:none;width:17px;height:17px;fill:none;stroke:currentColor;stroke-width:1.5;
  color:rgba(255,255,255,.7);transform-origin:0 0;transition:color .3s ease;}
.menu-search-rule{position:absolute;left:0;right:0;bottom:0;height:1px;background:#fff;opacity:.42;
  transform-origin:left center;pointer-events:none;transition:opacity .3s ease;}
.menu-search-form:focus-within .menu-search-glyph{color:#fff;}
.menu-search-form:focus-within .menu-search-rule{opacity:1;}
@media (forced-colors:active){.menu-search-form{border-bottom:1px solid CanvasText;}.menu-search-rule{display:none;}}
@media (max-width:760px){.menu-search-form{gap:8px;}}

@media (prefers-reduced-motion:no-preference){
  /* arrival in the menu: the hairline is drawn left to right, then the word settles on it */
  .menu.open .menu-search-trigger{animation:none;}
  .menu.open .menu-search-trigger::after{animation:menuSearchRule .72s cubic-bezier(.2,.8,.2,1) .32s backwards;}
  .menu.open .menu-search-trigger>*{animation:menuSearchInk .5s ease .5s backwards;}
  /* the field's own entrance is the measured travel played by site-search.js */
  .menu.search-open .menu-search-form{animation:none;}
  /* results arrive one after another, only when the list goes from empty to filled */
  .menu-search-results.is-arriving>.menu-search-result{animation:menuSearchResult .5s cubic-bezier(.2,.8,.2,1) backwards;}
  .menu-search-results.is-arriving>:nth-child(2){animation-delay:.045s;}
  .menu-search-results.is-arriving>:nth-child(3){animation-delay:.09s;}
  .menu-search-results.is-arriving>:nth-child(4){animation-delay:.135s;}
  .menu-search-results.is-arriving>:nth-child(5){animation-delay:.18s;}
  .menu-search-results.is-arriving>:nth-child(6){animation-delay:.225s;}
  @keyframes menuSearchRule{from{transform:scaleX(0);}to{transform:none;}}
  @keyframes menuSearchInk{from{opacity:0;}to{opacity:1;}}
  @keyframes menuSearchResult{from{opacity:0;translate:0 10px;}to{opacity:1;translate:0 0;}}
}

/* ============================================================
   The room around the search line. The menu is a place, not a
   sheet laid over the page: what is behind recedes to a soft
   glow, and nothing of it stays legible under the controls.
   Kept here (not in site.css) so the shared sheet stays as is.
   ============================================================ */

/* ---- the veil: solid where the controls sit, a dim blurred glow in the middle ----
   The blur has one fixed radius and only the menu's opacity moves. What once
   stalled iOS Safari was animating the radius itself; that never happens here
   (site.css switches the blur off for phones and while leaving, so both are
   set again below). Phones get a smaller radius and a darker veil. */
.menu{background:
  linear-gradient(to bottom,#0a0a0a 14%,rgba(10,10,10,0) 36%,rgba(10,10,10,0) 50%,#0a0a0a 74%),
  rgba(10,10,10,.955);}
@supports ((backdrop-filter:blur(1px)) or (-webkit-backdrop-filter:blur(1px))){
  .menu,.menu.leaving{background:
    linear-gradient(to bottom,#0a0a0a 10%,rgba(10,10,10,0) 34%,rgba(10,10,10,0) 50%,#0a0a0a 76%),
    rgba(10,10,10,.8);
    -webkit-backdrop-filter:blur(22px) saturate(.78);backdrop-filter:blur(22px) saturate(.78);}
  @media (min-width:761px) and (hover:hover) and (pointer:fine){
    .menu,.menu.leaving{background:
      linear-gradient(to bottom,#0a0a0a 0,rgba(10,10,10,0) 30%,rgba(10,10,10,0) 52%,#0a0a0a 84%),
      rgba(10,10,10,.74);
      -webkit-backdrop-filter:blur(36px) saturate(.72);backdrop-filter:blur(36px) saturate(.72);}
  }
}
/* anyone who asked the system for less transparency keeps the plain veil */
@media (prefers-reduced-transparency:reduce){
  .menu,.menu.leaving{background:
    linear-gradient(to bottom,#0a0a0a 14%,rgba(10,10,10,0) 36%,rgba(10,10,10,0) 50%,#0a0a0a 74%),
    rgba(10,10,10,.955);
    -webkit-backdrop-filter:none;backdrop-filter:none;}
}
@media (forced-colors:active){.menu{background:Canvas;}}

/* ---- the search line, quieter until it is wanted ---- */
.menu-search-trigger{color:rgba(255,255,255,.72);letter-spacing:.01em;transition:color .35s ease;}
.menu-search-trigger::after{opacity:.34;transition:opacity .35s ease;}
.menu-search-key{color:rgba(255,255,255,.34);transition:color .35s ease;}
.menu-search-trigger:hover .menu-search-key,.menu-search-trigger:focus-visible .menu-search-key{color:rgba(255,255,255,.7);}

/* ---- Share / Web App / Language: three quiet words, no rules ---- */
.menu-utility-stack{transition:opacity .32s ease,visibility 0s linear 0s;}
.menu.search-open .menu-utility-stack{opacity:0;transition:opacity .22s ease,visibility 0s linear .22s;}
.menu-utilities-primary .menu-utility-button{color:rgba(255,255,255,.56);
  transition:color .4s cubic-bezier(.2,.7,.2,1),opacity .1s ease;}
.menu-utilities-primary .menu-utility-button:focus-visible{color:#fff;}
/* the note a tool leaves behind (e.g. when the browser cannot share) */
.menu-utility-status{bottom:calc(100% + 16px);color:rgba(255,255,255,.66);font-size:11px;line-height:1.5;letter-spacing:.01em;}

@media (hover:hover) and (pointer:fine){
  /* attention follows the pointer: the line under it stays lit, the rest fall back */
  .menu-list>a{transition:opacity .5s cubic-bezier(.2,.7,.2,1);}
  .menu-list:has(>a:hover)>a:not(:hover){opacity:.26;}
  .menu-utilities-primary .menu-utility-button:hover{color:#fff;text-decoration:none;}
  .menu-utilities-primary:has(.menu-utility-button:hover) .menu-utility-button:not(:hover){color:rgba(255,255,255,.26);}
}
html[data-input="touch"] .menu-utilities-primary .menu-utility-button{color:rgba(255,255,255,.66);}

@media (prefers-reduced-motion:no-preference){
  /* the tools arrive last, after the navigation and the search line */
  .menu.open .menu-utility-stack{animation:menuToolsIn .8s ease .62s backwards;}
  .menu-utility-status:not(:empty){animation:menuNoteIn .6s cubic-bezier(.2,.8,.2,1) backwards;}
  @keyframes menuToolsIn{from{opacity:0;}to{opacity:1;}}
  @keyframes menuNoteIn{from{opacity:0;translate:0 6px;}to{opacity:1;translate:0 0;}}
}
@media (prefers-reduced-motion:reduce){
  .menu-list>a,.menu-utility-stack,.menu-utilities-primary .menu-utility-button,.menu-search-trigger,.menu-search-trigger::after,.menu-search-key{transition:none;}
}

/* ---- Web App: a few lines of instruction, not a boxed card ----
   No frame, no rules, no panel. While it is open the whole room goes dark
   (a shade over the navigation and the glow behind it), and the instructions
   stand on that. */
.menu::after{content:"";position:absolute;inset:0;z-index:3;background:#0a0a0a;opacity:0;pointer-events:none;transition:opacity .4s ease;}
.menu.webapp-open::after{opacity:.97;}
.menu-app-sheet{padding:clamp(22px,4vw,34px);border:0;background:transparent;box-shadow:none;}
.menu-app-sheet-head{align-items:baseline;}
.menu-app-kicker{margin:0 0 14px;color:rgba(255,255,255,.5);font-size:11px;letter-spacing:.09em;}
.menu-app-sheet h2{max-width:13em;font-weight:300;font-size:clamp(24px,4.6vw,31px);line-height:1.14;letter-spacing:-.03em;text-wrap:balance;}
.menu-app-close{margin:-14px 0 0;padding:0;border-bottom:0;color:rgba(255,255,255,.62);font-size:11px;letter-spacing:.09em;
  text-align:right;transition:color .3s ease;}
.menu-app-lead{max-width:40ch;margin:22px 0 26px;color:rgba(255,255,255,.72);font-size:13.5px;line-height:1.6;}
.menu-app-steps{--app-step-index:30px;--app-step-gap:14px;--app-step-pad:11px;border-top:0;}
.menu-app-steps li{border-bottom:0;}
.menu-app-steps li::before{padding-top:3px;color:rgba(255,255,255,.4);font:400 11px/1.3 'Graphik',var(--gro);font-variant-numeric:tabular-nums;letter-spacing:.04em;}
.menu-app-step-title{font-weight:400;font-size:13.5px;line-height:1.4;}
.menu-app-step-detail{color:rgba(255,255,255,.56);font-size:12.5px;line-height:1.5;}
.menu-app-step-cue{font-size:11px;letter-spacing:.09em;transition:color .3s ease;}
.menu-app-status{font-size:11px;}
@media (forced-colors:active){.menu-app-sheet{border:1px solid CanvasText;background:Canvas;}.menu::after{display:none;}}

/* ---- Language: four words; the only line is the short one under the choice ---- */
.menu-langs{border-bottom-color:transparent;}
.menu-langs button{font-size:11px;letter-spacing:.12em;color:rgba(255,255,255,.4);transition:color .35s ease,opacity .1s ease;}
.menu-langs button:hover{color:rgba(255,255,255,.82);}
.menu-lang-thumb{bottom:6px;background:transparent;}
.menu-lang-thumb::after{content:"";position:absolute;left:50%;bottom:0;width:16px;height:1px;margin-left:-8px;background:#fff;}
.menu-language-back{color:rgba(255,255,255,.5);letter-spacing:.06em;transition:color .3s ease;}
@media (hover:hover) and (pointer:fine){.menu-language-back:hover{color:#fff;text-decoration:none;}}
@media (forced-colors:active){.menu-lang-thumb::after{background:CanvasText;}}
@media (prefers-reduced-motion:reduce){.menu::after,.menu-app-close,.menu-app-step-cue,.menu-langs button,.menu-language-back{transition:none;}}
