/* Kept outside the upstream snapshot so docs:sync preserves mobile support. */
.nav-close,.nav-backdrop{display:none}
@media (max-width:900px){
  html{scrollbar-gutter:auto;scroll-padding-top:124px}
  body{font-size:16px;line-height:26px}
  .shell{grid-template-columns:minmax(0,1fr);min-height:100svh}
  .side{position:static;height:auto;max-width:100%;font-size:14px;line-height:20px}
  .side-head{min-height:64px;padding:0 20px}
  .side-nav{padding:8px 12px}
  .sec summary,.sec li a{min-height:44px;padding-top:10px;padding-bottom:10px}
  .sec summary .sec-title,.sec li a .item-title{white-space:normal;overflow-wrap:anywhere}
  .side-foot{min-height:64px;padding-bottom:env(safe-area-inset-bottom)}
  .side-foot a{display:inline-flex;align-items:center;min-height:44px}
  .bar{flex:none;display:grid;grid-template-columns:minmax(0,1fr);gap:8px;
    padding:12px max(16px,env(safe-area-inset-right)) 12px max(16px,env(safe-area-inset-left));
    border-bottom:1px solid var(--line)}
  .menu{display:none}
  .mobile-ready .bar{grid-template-columns:44px minmax(0,1fr);column-gap:12px}
  .mobile-ready .menu{display:flex;align-items:center;justify-content:center;width:44px;height:44px;padding:0;font-size:20px;cursor:pointer}
  .crumb{font-size:14px;line-height:20px}
  .search,.search:focus-within{grid-column:1/-1;width:100%;height:44px;min-width:0;
    background:var(--bg3);box-shadow:inset 0 0 0 1px var(--line2);transition:none}
  .search input{font-size:16px;height:44px}
  .search .esc{display:none}
  .results{top:52px;width:100%;max-width:none;max-height:55vh;max-height:55dvh;overscroll-behavior:contain}
  .results a{padding:12px 16px;overflow-wrap:anywhere}
  .results small{font-size:14px;line-height:20px}
  .main{padding:24px max(20px,env(safe-area-inset-right)) 40px max(20px,env(safe-area-inset-left))}
  .doc,.pager,.foot{overflow-wrap:anywhere}
  .doc h1,.doc .hero h1{font-size:30px;line-height:36px;letter-spacing:-.6px}
  .doc h2{font-size:24px;line-height:30px;margin-top:36px}
  .doc>p:first-of-type,.doc .hero p{font-size:16px;line-height:26px}
  .doc pre{max-width:100%;padding:20px 16px;overflow-wrap:normal}
  .doc pre:has(.copy){padding-top:56px}
  .doc pre .copy{min-height:44px;min-width:56px;top:4px;right:8px;font-size:13px}
  .doc pre::after{top:16px}
  .doc pre code{font-size:14px;line-height:22px}
  .doc table{max-width:100%;font-size:14px;line-height:22px;overflow-wrap:normal}
  .doc .cards,.doc .tiers{grid-template-columns:minmax(0,1fr);gap:12px}
  .doc .cards a>span,.doc .tier p,.doc .tier a{font-size:14px;line-height:22px}
  .doc .tier a{display:flex;align-items:center;min-height:44px}
  .pager{flex-direction:column;gap:12px;margin-top:36px}
  .pager a{min-width:0;padding:16px}
  .pager a small{font-size:14px;line-height:22px}
  .foot{padding-bottom:env(safe-area-inset-bottom);font-size:13px;line-height:22px}
  .mobile-ready .side{display:none;position:fixed;inset:0 auto 0 0;z-index:50;
    width:min(360px,calc(100% - 24px));height:100vh;height:100dvh;
    padding-left:env(safe-area-inset-left);box-shadow:12px 0 48px rgba(0,0,0,.35)}
  .mobile-ready .side.open{display:flex}
  .nav-close{display:flex;align-items:center;justify-content:center;margin-left:auto;
    width:44px;height:44px;flex-shrink:0;border:1px solid var(--line2);border-radius:6px;
    background:none;color:var(--fg);font-size:24px;cursor:pointer}
  .mobile-nav-open{position:fixed;width:100%;overflow:hidden}
  .mobile-nav-open .nav-backdrop{display:block;position:fixed;inset:0;z-index:40;background:rgba(0,0,0,.65)}
  :is(a,button,input,summary):focus-visible{outline:2px solid var(--accent);outline-offset:3px}
}
@media (prefers-reduced-motion:reduce){
  .brand .cursor{animation:none}
}
