/* Cortana developer docs. Every colour, size and font is a token in :root, so the global design system
   (/assets/cortana.css, loaded first) can take over by redefining them. No other file styles this page. */
:root {
  --cx-bg: var(--night); --cx-panel: var(--night-2); --cx-raised: var(--night-3); --cx-line: var(--line-soft); --cx-text: var(--paper); --cx-dim: var(--mist); --cx-faint: var(--dim);
  --cx-accent: var(--screen); --cx-good: var(--go); --cx-warn: var(--stop); --cx-danger: var(--stop); --cx-code: #d0d5ee; --cx-radius: var(--r-2);
  --cx-font: var(--font); --cx-mono: var(--mono);
  --cx-nav-w: 264px; --cx-measure: 760px;
}
*, *::before, *::after { box-sizing: border-box; }
html { color-scheme: dark; scroll-behavior: smooth; scroll-padding-top: 24px; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; } }
body { margin: 0; background: var(--cx-bg); color: var(--cx-text); font: 16px/1.65 var(--cx-font); -webkit-font-smoothing: antialiased; }
a { color: var(--cx-accent); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 2px solid var(--cx-accent); outline-offset: 3px; border-radius: 4px; }
.skip { position: absolute; left: 16px; top: -60px; padding: 10px 14px; background: var(--cx-text); color: var(--cx-bg); border-radius: 8px; font-weight: 600; z-index: 10; }
.skip:focus { top: 16px; }

.shell { display: grid; grid-template-columns: var(--cx-nav-w) minmax(0, 1fr); min-height: 100vh; }
.side { position: sticky; top: 0; align-self: start; height: 100vh; overflow-y: auto; padding: 28px 20px 40px 28px; border-right: 1px solid var(--cx-line); }
.brand { display: flex; align-items: baseline; gap: 10px; margin: 0 0 28px; color: var(--cx-text); text-decoration: none; font-weight: 650; font-size: 18px; letter-spacing: -0.01em; }
.brand span { color: var(--cx-faint); font-weight: 500; font-size: 14px; }
.side h2 { margin: 22px 0 6px; font-size: 12px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--cx-faint); }
.side ul { list-style: none; margin: 0; padding: 0; }
.side li a { display: block; padding: 5px 10px; margin: 1px -10px; border-radius: 7px; color: var(--cx-dim); text-decoration: none; font-size: 14.5px; line-height: 1.4; }
.side li a:hover { color: var(--cx-text); background: var(--cx-panel); }
.side li a[aria-current="true"] { color: var(--cx-text); background: var(--cx-raised); }

main { min-width: 0; padding: 56px 48px 120px; }
.doc { max-width: var(--cx-measure); margin: 0 auto; }
.hero p.kicker { margin: 0 0 12px; color: var(--cx-accent); font-size: 14px; font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase; }
h1 { margin: 0 0 16px; font-size: clamp(34px, 5vw, 46px); line-height: 1.08; letter-spacing: -0.03em; font-weight: 680; }
.lede { margin: 0 0 28px; font-size: 19px; line-height: 1.55; color: var(--cx-dim); }
section { padding-top: 56px; }
h2 { margin: 0 0 12px; font-size: 27px; line-height: 1.2; letter-spacing: -0.02em; font-weight: 650; }
h3 { margin: 36px 0 10px; font-size: 19px; line-height: 1.3; letter-spacing: -0.01em; font-weight: 620; }
h4 { margin: 24px 0 8px; font-size: 15px; font-weight: 620; color: var(--cx-text); }
p, ul, ol, table, pre, .note, .cards { margin: 0 0 18px; }
p, li { color: var(--cx-dim); }
strong { color: var(--cx-text); font-weight: 600; }
li { margin: 4px 0; }
ol.steps { padding-left: 0; list-style: none; counter-reset: step; }
ol.steps > li { position: relative; padding: 0 0 6px 44px; margin: 0 0 14px; counter-increment: step; }
ol.steps > li::before { content: counter(step); position: absolute; left: 0; top: 1px; width: 28px; height: 28px; display: grid; place-items: center; border: 1px solid var(--cx-line); border-radius: 50%; color: var(--cx-text); font: 600 13px var(--cx-font); background: var(--cx-panel); }
ol.steps > li > :last-child { margin-bottom: 0; }

code { font: 0.875em var(--cx-mono); color: var(--cx-code); background: var(--cx-raised); padding: 0.15em 0.4em; border-radius: 5px; overflow-wrap: anywhere; }
.code { position: relative; margin: 0 0 18px; border: 1px solid var(--cx-line); border-radius: var(--cx-radius); background: var(--cx-panel); overflow: hidden; }
.code > header { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 40px; padding: 0 8px 0 16px; border-bottom: 1px solid var(--cx-line); color: var(--cx-faint); font: 500 12.5px var(--cx-font); }
.code pre { margin: 0; padding: 16px; overflow-x: auto; font: 13.5px/1.6 var(--cx-mono); color: var(--cx-code); tab-size: 2; }
.code pre code { padding: 0; background: none; font: inherit; color: inherit; overflow-wrap: normal; }
.copy { min-width: 60px; min-height: 30px; padding: 0 10px; border: 1px solid var(--cx-line); border-radius: 7px; background: transparent; color: var(--cx-dim); font: 500 12.5px var(--cx-font); cursor: pointer; }
.copy:hover { color: var(--cx-text); border-color: var(--cx-faint); }
.copy[data-done] { color: var(--cx-good); border-color: var(--cx-good); }

table { width: 100%; border-collapse: collapse; font-size: 14.5px; }
.table { overflow-x: auto; margin: 0 0 18px; border: 1px solid var(--cx-line); border-radius: var(--cx-radius); }
.table table { margin: 0; }
th, td { padding: 10px 14px; text-align: left; vertical-align: top; border-top: 1px solid var(--cx-line); color: var(--cx-dim); }
thead th { border-top: 0; color: var(--cx-faint); font-size: 12.5px; font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase; background: var(--cx-panel); white-space: nowrap; }
td:first-child { white-space: nowrap; }
td code { white-space: nowrap; }

.note { padding: 14px 16px; border: 1px solid var(--cx-line); border-left: 3px solid var(--cx-accent); border-radius: 10px; background: var(--cx-panel); color: var(--cx-dim); font-size: 15px; }
.note.warn { border-left-color: var(--cx-warn); }
.note > :last-child { margin-bottom: 0; }
.method { display: inline-block; min-width: 46px; margin-right: 8px; padding: 1px 7px; border-radius: 5px; font: 650 11.5px var(--cx-mono); letter-spacing: 0.03em; text-align: center; background: var(--cx-raised); color: var(--cx-good); }
.method.get { color: var(--cx-accent); } .method.del { color: var(--cx-danger); } .method.put { color: var(--cx-accent); }
.endpoint { margin: 28px 0 10px; padding: 10px 14px; border: 1px solid var(--cx-line); border-radius: 10px; background: var(--cx-panel); font: 14px var(--cx-mono); color: var(--cx-text); overflow-x: auto; white-space: nowrap; }
.pill { display: inline-block; padding: 1px 8px; border: 1px solid var(--cx-line); border-radius: 999px; font-size: 12px; color: var(--cx-dim); white-space: nowrap; }
.pill.pro { color: var(--cx-accent); border-color: var(--cx-accent); }

.cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; padding: 0; list-style: none; }
.cards a { display: block; height: 100%; padding: 16px; border: 1px solid var(--cx-line); border-radius: var(--cx-radius); background: var(--cx-panel); text-decoration: none; }
.cards a:hover { border-color: var(--cx-faint); }
.cards strong { display: block; margin-bottom: 4px; }
.cards span { font-size: 14px; color: var(--cx-dim); line-height: 1.45; display: block; }

details.preset { margin: 0 0 12px; border: 1px solid var(--cx-line); border-radius: var(--cx-radius); background: var(--cx-panel); }
details.preset > summary { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 56px; padding: 0 18px; cursor: pointer; list-style: none; font-weight: 620; font-size: 17px; color: var(--cx-text); }
details.preset > summary::-webkit-details-marker { display: none; }
details.preset > summary small { font-weight: 500; font-size: 13.5px; color: var(--cx-faint); }
details.preset > summary::after { content: "+"; color: var(--cx-faint); font: 400 22px var(--cx-mono); }
details.preset[open] > summary::after { content: "\2212"; }
details.preset[open] > summary { border-bottom: 1px solid var(--cx-line); }
details.preset > .body { padding: 20px 18px 6px; }
details.preset h3 { margin-top: 20px; }

.brief pre { max-height: 520px; overflow: auto; white-space: pre-wrap; overflow-wrap: anywhere; }
footer.end { margin-top: 72px; padding-top: 24px; border-top: 1px solid var(--cx-line); color: var(--cx-faint); font-size: 14px; }

@media (max-width: 900px) {
  .shell { display: block; }
  .side { position: static; height: auto; padding: 16px 20px; border-right: 0; border-bottom: 1px solid var(--cx-line); }
  .brand { margin-bottom: 6px; min-height: 44px; align-items: center; }
  .cards { grid-template-columns: 1fr; }
  details.preset > summary small { display: none; }
  .side nav { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 6px; scrollbar-width: none; }
  .side nav::-webkit-scrollbar { display: none; }
  .side h2 { display: none; }
  .side ul { display: flex; gap: 6px; }
  .side li a { margin: 0; padding: 0 14px; min-height: 44px; display: flex; align-items: center; white-space: nowrap; border: 1px solid var(--cx-line); border-radius: 999px; }
  main { padding: 32px 20px 96px; }
  .lede { font-size: 17.5px; }
  td:first-child { white-space: normal; }
  .copy { min-height: 44px; min-width: 64px; }
  .code > header { min-height: 52px; }
}

/* ---- W6: onto the shared design system. Tokens above now read site/assets/cortana.css; these lines set the type. */
h1, h2 { font-stretch: 112%; font-weight: 720; letter-spacing: -.035em; }
h1 { font-size: var(--t-2xl); line-height: 1; }
.hero p.kicker { display: none; }
.side .brand { display: inline-flex; align-items: center; gap: .6rem; margin-bottom: 12px; font-size: 1.125rem; }
.side .brand span { color: var(--paper); font-weight: 650; font-size: inherit; }
.side-links { display: flex; flex-wrap: wrap; gap: 2px 14px; margin: 0 0 20px; font-size: 14px; }
.side-links a { color: var(--mist); text-decoration: none; padding: 6px 0; }
.side-links a:hover { color: var(--paper); }
.side h2 { font-stretch: 100%; text-transform: none; letter-spacing: 0; font-size: 13px; }
thead th { text-transform: none; letter-spacing: 0; }

/* R3-M6: the shared .doc (legal pages) pads its top for the fixed site nav. This page has a sidebar instead, so that
   padding was a blank band above the hero. The hero now starts at the top of the column, level with the sidebar brand. */
main > .doc { padding-block: 0; }
main > .doc > header.hero { margin-bottom: 0; }
