/* A docs page: a plain ground, one face, and the green where something is chosen. The top bar holds
   the search; the row under it holds the sections; the open page stands on a tinted ground in the
   side menu. Sizes are in px on purpose: the columns are a fixed 240, 641 and 264 with 75 and 92
   between them. */
:root{--ui:'Inter',ui-sans-serif,system-ui,sans-serif;--d-ink:#17191D;--d-on:#26272B;--d-body:#3F4045;--d-soft:#505256;--d-mute:#707276;
  --d-hair:#EEF0F4;--d-line:#E2E4E9;--d-ground:#fff;--d-code:#F7F8FA;--d-wash:rgba(23,25,29,.05);
  --mark:#3F7A00;--tint:rgba(63,122,0,.1);--pop:0 0 0 1px rgba(23,25,29,.08),0 12px 32px -12px rgba(23,25,29,.25)}
:root[data-theme="dark"]{--d-ink:#F2F3F5;--d-on:#E7E8EB;--d-body:#C4C6CC;--d-soft:#A5A6AD;--d-mute:#8B8D94;
  --d-hair:#26272D;--d-line:#34353D;--d-ground:#0F1014;--d-code:#16171C;--d-wash:rgba(255,255,255,.07);
  --mark:#9BCF4A;--tint:rgba(155,207,74,.14);--pop:0 0 0 1px #34353D,0 12px 32px -12px rgba(0,0,0,.6)}
body{background:var(--d-ground);color:var(--d-body);font:400 16px/28px var(--ui)}
body::before{display:none}
.dwrap{max-width:1440px;margin:0 auto;padding-inline:48px}

/* The site's header lines up with the docs frame, and under it one row holds the sections and the search. */
#nav{--h-wrap:1440px;--h-gut:48px}
.dtop{border-bottom:1px solid var(--d-hair)}
.dsections{display:flex;align-items:center;justify-content:space-between;gap:24px}
.dsearch{flex:0 0 auto;display:flex;align-items:center;gap:8px;width:280px;height:36px;padding:0 12px 0 14px;border:0;border-radius:12px;background:var(--d-ground);color:var(--d-mute);
  font:400 14px/24px var(--ui);text-align:left;cursor:pointer;box-shadow:inset 0 0 0 1px var(--d-line);transition:box-shadow .15s,color .15s}
.dsearch:hover{color:var(--d-soft);box-shadow:inset 0 0 0 1px var(--d-mute)}
.dsearch:focus-visible{outline:0;box-shadow:inset 0 0 0 1.5px var(--mark),0 0 0 3px var(--tint)}
.dsearch svg{flex:0 0 auto;color:var(--d-on)}
.dsearch span{flex:1}
.dsearch kbd{font:500 12px/1 var(--ui);color:var(--d-mute)}

/* the search panel: it drops in under the top bar, over a dimmed page. The site's base makes every
   child of the body relative, which in the top layer means it scrolls with the page: pin it. */
.dpal{position:fixed;width:min(640px,calc(100vw - 32px));max-height:min(520px,calc(100vh - 96px));margin:54px auto 0;padding:0;border:0;border-radius:16px;background:var(--d-ground);
  color:var(--d-body);box-shadow:0 0 0 1px rgba(23,25,29,.08),0 24px 60px -16px rgba(23,25,29,.35);overflow:hidden}
.dpal[open]{display:flex;animation:dpal-in .16s cubic-bezier(.2,.8,.2,1)}
.dpal::backdrop{background:rgba(23,25,29,.36);animation:dpal-dim .16s ease-out}
:root[data-theme="dark"] .dpal{box-shadow:0 0 0 1px #34353D,0 24px 60px -16px rgba(0,0,0,.7)}
:root[data-theme="dark"] .dpal::backdrop{background:rgba(0,0,0,.6)}
@keyframes dpal-in{from{opacity:0;transform:translateY(-8px) scale(.98)}}
@keyframes dpal-dim{from{opacity:0}}
.dpal-box{display:flex;flex-direction:column;width:100%;min-height:0;padding:6px}
.dpal-in{display:flex;align-items:center;gap:10px;height:48px;padding:0 12px;color:var(--d-mute)}
.dpal-in input{flex:1;min-width:0;border:0;outline:0;background:none;color:var(--d-ink);font:400 16px/24px var(--ui)}
.dpal-in input::placeholder{color:var(--d-mute)}
.dpal-list{min-height:0;overflow-y:auto;font:14px/20px var(--ui)}
.dpal-list a{display:flex;align-items:flex-start;gap:10px;padding:8px 12px;border-radius:12px;color:var(--d-ink);scroll-margin:6px}
.dpal-list a[aria-selected="true"]{background:var(--d-wash)}
.dpal-list svg{flex:0 0 auto;margin-top:2px;color:var(--d-mute)}
.dpal-list strong{display:block;font-weight:500}
.dpal-list mark{background:none;color:var(--mark)}
.dpal-list span{display:block;font-size:13px;color:var(--d-mute)}
.dpal-list p{padding:10px 12px;color:var(--d-soft)}
.dpal-keys{display:flex;gap:16px;margin-top:6px;padding:10px 12px 6px;border-top:1px solid var(--d-hair);font:400 13px/20px var(--ui);color:var(--d-mute)}
.dpal-keys span{display:inline-flex;align-items:center;gap:4px}
.dpal-keys span:last-child{margin-left:auto}
.dpal-keys kbd{display:inline-grid;place-items:center;min-width:18px;height:18px;padding:0 4px;border-radius:5px;background:var(--d-wash);font:500 11px/1 var(--ui);color:var(--d-soft)}
.dpal-keys kbd:last-of-type{margin-right:4px}
.dtabs{flex:1;min-width:0;display:flex;align-items:stretch;gap:24px;height:48px;overflow-x:auto;scrollbar-width:none;font:500 14px/20px var(--ui);white-space:nowrap}
.dtabs a{display:inline-flex;align-items:center;gap:8px;border-bottom:1.5px solid transparent;color:var(--d-soft);transition:color .15s,border-color .15s}
.dtabs a:hover{color:var(--d-ink);border-bottom-color:var(--d-line)}
.dtabs a[aria-current]{color:var(--d-on);font-weight:600;border-bottom-color:var(--mark)}

.dgrid{display:grid;grid-template-columns:240px 75px minmax(0,641px) minmax(40px,92px) 264px;align-items:start;padding-bottom:96px}
.dmenu{grid-column:1;position:sticky;top:68px;max-height:calc(100vh - 68px);overflow-y:auto;padding:32px 0 32px 16px;margin-left:-16px;font:400 14px/24px var(--ui)}
.dpage{grid-column:3;min-width:0;padding-top:42px}
/* a page of wide tables takes the room the headings would */
.dgrid.wide .dpage{grid-column:3 / -1}
.dgrid.wide :is(.dtitle,.dsub){max-width:641px}
.dtoc{grid-column:5;position:sticky;top:68px;max-height:calc(100vh - 68px);overflow-y:auto;padding-top:40px;font:400 14px/24px var(--ui)}

/* the side menu: the open page on a tinted ground */
.dmenu-btn{display:none}
.dmenu-in{margin-left:-16px}
.dgroup+.dgroup{margin-top:32px}
.dgroup p{padding-left:16px;font-weight:600;color:var(--d-ink)}
.dgroup ul{list-style:none;margin-top:10px}
.dgroup li+li{margin-top:1px}
.dgroup a{display:block;padding:6px 12px 6px 16px;border-radius:12px;color:var(--d-body);transition:background-color .15s,color .15s}
.dgroup a:hover{background:var(--d-wash);color:var(--d-ink)}
.dgroup a[aria-current]{background:var(--tint);color:var(--mark)}

/* the page's head */
.deyebrow{font:600 14px/20px var(--ui);color:var(--mark)}
.dtitle{display:flex;align-items:center;justify-content:space-between;gap:16px;margin-top:10px}
.dtitle h1{font:600 36px/40px var(--ui);letter-spacing:-.9px;color:var(--d-ink)}
.dcopy{position:relative;display:flex;flex:0 0 auto;height:34px;border-radius:12px;background:var(--d-ground);box-shadow:inset 0 0 0 1px var(--d-line)}
.mdcopy{display:inline-flex;align-items:center;gap:8px;padding:0 12px;border-radius:12px 0 0 12px;font:500 14px/20px var(--ui);color:var(--d-on);transition:background-color .15s}
.mdcopy svg{color:var(--d-soft)}
.mdcopy:hover,.dcopy-more:hover{background:var(--d-wash)}
.mdcopy[data-done]{color:var(--mark)}
.mdcopy[data-done] svg{color:var(--mark)}
.dcopy-more{display:grid;place-items:center;width:34px;padding:0;border:0;border-left:1px solid var(--d-line);border-radius:0 12px 12px 0;background:none;color:var(--d-soft);cursor:pointer;
  transition:background-color .15s}
.dcopy-menu{position:absolute;z-index:5;top:calc(100% + 6px);right:0;min-width:240px;padding:6px;border-radius:12px;background:var(--d-ground);box-shadow:var(--pop)}
.dcopy-menu a{display:block;padding:8px 10px;border-radius:8px;font:500 14px/20px var(--ui);color:var(--d-on)}
.dcopy-menu a:hover{background:var(--d-wash)}
.dsub{margin-top:8px;font-size:18px;line-height:28px;color:var(--d-body)}

/* the words */
.md{margin-top:32px}
.md h2{margin-top:48px;font:600 24px/32px var(--ui);letter-spacing:-.6px;color:var(--d-ink);scroll-margin-top:92px}
.md h3{margin-top:32px;font:600 20px/28px var(--ui);letter-spacing:-.3px;color:var(--d-ink);scroll-margin-top:92px}
.md p,.md ul,.md ol,.md table,.md pre,.code{margin-top:20px}
.md h2+p,.md h3+p{margin-top:16px}
.md ul,.md ol{padding-left:26px}
.md li+li{margin-top:8px}
.md li::marker{color:var(--d-mute)}
.md strong{font-weight:600;color:var(--d-ink)}
.md a{font-weight:500;color:var(--d-ink);text-decoration:underline;text-decoration-thickness:1px;text-underline-offset:4px;text-decoration-color:var(--mark);transition:text-decoration-thickness .15s}
.md a:hover{text-decoration-thickness:2px}
.md code{font-family:var(--mono);font-size:14px;padding:2px 6px;border-radius:6px;background:var(--d-code);color:var(--d-ink);box-shadow:inset 0 0 0 1px var(--d-hair);overflow-wrap:anywhere}
.md h2 code{font-size:.85em}

/* a command to copy, and what a tool printed */
.md pre{padding:16px 19px;border-radius:16px;background:var(--d-code);color:var(--d-ink);font:400 14px/24px var(--mono);overflow-x:auto;white-space:pre;tab-size:2;
  box-shadow:inset 0 0 0 1px var(--d-hair)}
.md pre code{padding:0;background:none;box-shadow:none;font:inherit;color:inherit}
.md pre:has(>code.language-text),.md pre.out{white-space:pre-wrap;overflow-wrap:anywhere;font-size:13px;line-height:22px;color:var(--d-body)}
.code{position:relative}
.code pre{margin-top:0}
.code pre:not(.out){padding-right:84px}
/* the copy button waits out of sight until the pointer or the keyboard reaches the block */
.copy{position:absolute;right:10px;top:10px;display:grid;place-items:center;width:30px;height:30px;padding:0;border:0;border-radius:8px;cursor:pointer;color:var(--d-soft);
  background:var(--d-ground);box-shadow:inset 0 0 0 1px var(--d-line);opacity:0;transition:opacity .15s,color .15s,background-color .15s}
.code:hover .copy,.copy:focus-visible,.copy[data-done]{opacity:1}
.copy:hover{color:var(--d-ink)}
.copy[data-done]{color:var(--mark)}
@media(hover:none){.copy{opacity:1}}

/* a heading's link to itself, in the margin, shown with the pointer on the heading */
.md h2,.md h3{position:relative}
.danchor{position:absolute;right:100%;top:50%;display:grid;place-items:center;width:26px;height:26px;margin:-13px 4px 0 0;border-radius:8px;color:var(--d-mute);
  text-decoration:none;opacity:0;transition:opacity .15s,color .15s,background-color .15s}
:is(.md h2,.md h3):hover .danchor,.danchor:focus-visible,.danchor[data-done]{opacity:1}
.danchor:hover{color:var(--d-ink);background:var(--d-wash)}
.danchor[data-done]{color:var(--mark)}

/* the code's colours: the light set, and the dark one in the dark room */
.md pre.astro-code{background-color:var(--d-code)!important}
:root[data-theme="dark"] .md pre.astro-code,:root[data-theme="dark"] .md pre.astro-code span{color:var(--shiki-dark)!important}

.md table{display:block;overflow-x:auto;border-collapse:collapse;font-size:14px;line-height:24px}
.md th,.md td{min-width:9ch;padding:10px 16px 10px 0;text-align:left;vertical-align:top;border-bottom:1px solid var(--d-hair);font-weight:400}
.md thead th{font-weight:600;line-height:20px;color:var(--d-ink)}
.md td:first-child code{white-space:nowrap}

/* what the guides and comparisons carry beyond plain words: a lead, a box that stands apart, tables
   of facts in their own frame, sources, and the two ways on */
.md .lede{font-size:18px}
.md .small,.md .src{font-size:14px;line-height:22px;color:var(--d-soft)}
.md .note{margin-top:20px;padding:16px 19px;border-radius:16px;background:var(--d-code);box-shadow:inset 0 0 0 1px var(--d-hair)}
.md .note>:first-child{margin-top:0}
.md .prose{max-width:641px}
.md .tbl{margin-top:20px;overflow-x:auto}
.md .tbl table{display:table;width:100%;margin-top:0}
.md tbody th{font-weight:600;color:var(--d-ink)}
.md caption{caption-side:top;padding-bottom:8px;text-align:left;font-size:13px;line-height:20px;color:var(--d-mute)}
.md .facts thead th:first-child{width:22%}
.md .facts.two thead th:not(:first-child){width:39%}
.md .facts.ways thead th:first-child{width:22%}
.md .facts.ways thead th:not(:first-child){width:26%}
.md .facts.ways :is(thead th:last-child,td.us){background:var(--d-code);color:var(--d-ink)}
.md .facts.ways td.us{font-weight:500}
.md .src{margin-top:48px;padding-top:24px;border-top:1px solid var(--d-hair)}
.md .src h2{margin-top:0;font-size:16px;line-height:24px;letter-spacing:0}
.md .next{display:flex;flex-wrap:wrap;gap:12px;margin-top:40px}
.md .pill{display:inline-flex;align-items:center;height:36px;padding:0 14px;border-radius:10px;background:#5E9E00;color:#fff;font:500 14px/20px var(--ui);text-decoration:none;
  box-shadow:inset 0 -1px 0 rgba(0,0,0,.2),inset 0 1px 0 rgba(255,255,255,.18);transition:background-color .15s}
.md .pill:hover{background:#538C00}
.md .pill.white{background:var(--d-ground);color:var(--d-on);box-shadow:inset 0 0 0 1px var(--d-line)}
.md .pill.white:hover{background:var(--d-wash)}
.code .cap{display:block;margin-bottom:6px;font-size:13px;line-height:20px;color:var(--d-mute)}
.code:has(.cap) .copy{top:36px}
/* Below this a row of facts is read as a card: each cell carries its column's name. */
@media(max-width:700px){
  .md .stack thead{display:none}
  .md .stack tr{display:block;padding:14px 0;border-bottom:1px solid var(--d-hair)}
  .md .stack th,.md .stack td{display:block;border:0;padding:3px 0}
  .md .stack td[data-label]::before{content:attr(data-label);display:block;font-size:12.5px;font-weight:600;color:var(--d-mute)}
  .md .stack td+td{margin-top:8px}
}

.dupdated{margin-top:48px;font-size:14px;line-height:20px;color:var(--d-mute)}
.dnext{display:grid;grid-template-columns:1fr 1fr;gap:16px;margin-top:16px;padding-top:24px;border-top:1px solid var(--d-hair)}
.dnext a{padding:12px 16px;border-radius:12px;font:500 14px/24px var(--ui);color:var(--d-ink);box-shadow:inset 0 0 0 1px var(--d-line);transition:background-color .15s}
.dnext a:hover{background:var(--d-wash)}
.dnext span{display:block;font-size:13px;line-height:20px;font-weight:400;color:var(--d-mute)}
.dnext .fwd{grid-column:2;text-align:right}

/* on this page: the heading the reader is on is green */
.dtoc p{display:flex;align-items:center;gap:8px;font-weight:500;color:var(--d-body)}
.dtoc a{display:block;padding:4px 0;color:var(--d-mute);transition:color .15s}
.dtoc a:hover{color:var(--d-ink)}
.dtoc a[aria-current]{color:var(--mark)}

.dfoot{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:10px 24px;padding-block:24px 32px;border-top:1px solid var(--d-hair);
  font:400 14px/20px var(--ui);color:var(--d-mute)}
.dfoot nav{display:flex;flex-wrap:wrap;gap:6px 24px}
.dfoot a:hover{color:var(--d-ink)}

@media(max-width:1279px){
  .dgrid{grid-template-columns:240px minmax(32px,75px) minmax(0,641px)}
  .dtoc{display:none}
}
@media(max-width:1023px){
  .dwrap{padding-inline:20px}
  #nav{--h-gut:20px}
  .dsections{flex-direction:column;align-items:stretch;gap:0}
  .dsearch{order:-1;width:auto;margin-top:4px}
  .dsearch kbd{display:none}
  .dpal{margin-top:16px}
  .dgrid{display:block}
  .dmenu{position:static;max-height:none;overflow:visible;margin:0;padding:16px 0 0}
  .dmenu-in{margin:0}
  .dmenu-btn{display:flex;align-items:center;justify-content:space-between;width:100%;height:40px;padding:0 14px;border:0;border-radius:12px;cursor:pointer;
    font:500 14px/1 var(--ui);color:var(--d-ink);background:var(--d-ground);box-shadow:inset 0 0 0 1px var(--d-line)}
  .dmenu-btn::after{content:'';width:6px;height:6px;margin-top:-3px;border-right:1.5px solid var(--d-soft);border-bottom:1.5px solid var(--d-soft);transform:rotate(45deg);transition:transform .15s}
  .dmenu-btn[aria-expanded="true"]::after{margin-top:3px;transform:rotate(225deg)}
  .dmenu-in{display:none;margin-top:8px;padding:14px 4px;border-radius:12px;box-shadow:inset 0 0 0 1px var(--d-line)}
  .dmenu.open .dmenu-in{display:block}
  .dpage{padding-top:24px}
}
@media(max-width:560px){
  .dtitle{flex-direction:column;align-items:flex-start;gap:12px}
  .dtitle h1{font-size:30px;line-height:36px}
  .dsub{font-size:17px}
  .dnext{grid-template-columns:1fr}
  .dnext .fwd{grid-column:1;text-align:left}
}
