:root {
  --accent: #315b76;
  --accent-strong: #173b52;
  --accent-soft: #e8f0f4;
  --ink: #202124;
  --muted: #5c6268;
  --line: #c8cdd1;
  --paper: #fff;
  --wash: #f4f5f5;
  --code: #f1f3f4;
  --measure: 50rem;
}

* { box-sizing: border-box; }

html {
  background: #e7e9ea;
  color: var(--ink);
  font: 17px/1.62 Georgia, "Times New Roman", serif;
  scroll-behavior: smooth;
}

body { margin: 0; }

a {
  color: #075b9b;
  text-decoration-thickness: .06em;
  text-underline-offset: .14em;
}

a:hover { color: #9b2c19; }

.site-header {
  align-items: center;
  background: #17242c;
  color: #fff;
  display: flex;
  font-family: Arial, Helvetica, sans-serif;
  gap: 1rem;
  justify-content: space-between;
  min-height: 4.25rem;
  padding: .7rem clamp(1rem, 4vw, 3.5rem);
}

.brand {
  color: inherit;
  display: flex;
  gap: .75rem;
  text-decoration: none;
}

.brand-mark {
  border: 2px solid currentColor;
  display: grid;
  font: 700 .72rem/1 Arial, sans-serif;
  height: 2.2rem;
  letter-spacing: .04em;
  place-items: center;
  width: 2.2rem;
}

.brand-name { font-size: 1.05rem; font-weight: 700; }
.brand-note { color: #bdc9cf; display: block; font-size: .7rem; letter-spacing: .06em; text-transform: uppercase; }

.search-form { display: flex; max-width: 24rem; width: 38vw; }
.search-form input {
  background: #fff;
  border: 0;
  border-radius: 2px 0 0 2px;
  color: #17191b;
  font: .85rem Arial, sans-serif;
  min-width: 0;
  padding: .65rem .75rem;
  width: 100%;
}
.search-form button {
  background: var(--accent);
  border: 0;
  border-radius: 0 2px 2px 0;
  color: #fff;
  cursor: pointer;
  font: 700 .76rem Arial, sans-serif;
  padding: .65rem .8rem;
}

.status-stripe { background: var(--accent); height: .4rem; }
.status-draft { --accent: #9c6a00; --accent-strong: #674500; --accent-soft: #fff3cf; }
.status-current { --accent: #237a4b; --accent-strong: #135530; --accent-soft: #e2f3e9; }
.status-deprecated { --accent: #a7432d; --accent-strong: #762b1b; --accent-soft: #fbe8e3; }
.status-retired { --accent: #65676b; --accent-strong: #414347; --accent-soft: #ededee; }

.page-grid {
  display: grid;
  grid-template-columns: minmax(12rem, 17rem) minmax(0, 1fr);
  margin: 0 auto;
  max-width: 100rem;
  min-height: calc(100vh - 4.65rem);
}

.site-nav {
  background: var(--wash);
  border-right: 1px solid var(--line);
  font: .79rem/1.4 Arial, Helvetica, sans-serif;
  padding: 1.75rem 1.25rem 4rem;
}

.site-nav h2 {
  color: var(--muted);
  font-size: .68rem;
  letter-spacing: .1em;
  margin: 1.5rem 0 .45rem;
  text-transform: uppercase;
}

.site-nav h2:first-child { margin-top: 0; }
.site-nav ul { list-style: none; margin: 0; padding: 0; }
.site-nav li { margin: .15rem 0; }
.site-nav a { border-left: 3px solid transparent; color: #303438; display: block; padding: .35rem .5rem; text-decoration: none; }
.site-nav a:hover { background: #e5e8e9; }
.site-nav a[aria-current="page"] { background: var(--accent-soft); border-color: var(--accent); color: var(--accent-strong); font-weight: 700; }
.nav-status { color: var(--muted); font-size: .67rem; margin-left: .25rem; text-transform: uppercase; }

.document {
  background: var(--paper);
  box-shadow: 0 0 1.5rem rgb(0 0 0 / 8%);
  min-width: 0;
  padding: clamp(2rem, 5vw, 5rem) clamp(1.25rem, 6vw, 6rem) 6rem;
}

.document-head { border-bottom: 1px solid var(--line); margin-bottom: 2.2rem; max-width: var(--measure); padding-bottom: 1.5rem; }
.eyebrow { color: var(--accent-strong); font: 700 .72rem/1.3 Arial, sans-serif; letter-spacing: .12em; margin: 0 0 .65rem; text-transform: uppercase; }
.document h1 { color: #17191b; font-size: clamp(2.15rem, 5vw, 3.75rem); font-weight: 500; letter-spacing: -.035em; line-height: 1.04; margin: 0; }
.document-summary { color: var(--muted); font: .9rem/1.5 Arial, sans-serif; margin: 1rem 0 0; }

.status-box {
  background: var(--accent-soft);
  border-left: .45rem solid var(--accent);
  color: var(--accent-strong);
  font: .84rem/1.5 Arial, sans-serif;
  margin: 0 0 2rem;
  max-width: var(--measure);
  padding: .9rem 1.1rem;
}
.status-box strong { text-transform: capitalize; }

.toc { background: var(--wash); border: 1px solid var(--line); font: .84rem/1.45 Arial, sans-serif; margin: 0 0 2.5rem; max-width: var(--measure); padding: 1rem 1.25rem; }
.toc h2 { border: 0 !important; font: 700 .7rem/1.2 Arial, sans-serif !important; letter-spacing: .1em; margin: 0 0 .5rem !important; text-transform: uppercase; }
.toc ol { columns: 2; margin: 0; padding-left: 1.25rem; }
.toc li { break-inside: avoid; margin: .2rem 1rem .2rem 0; }

.prose { max-width: var(--measure); overflow-wrap: anywhere; }
.prose > :first-child { margin-top: 0; }
.prose h2, .prose h3, .prose h4 { color: #24272a; font-weight: 500; line-height: 1.2; scroll-margin-top: 1rem; }
.prose h2 { border-bottom: 1px solid var(--line); font-size: 1.75rem; margin: 2.5rem 0 1rem; padding-bottom: .3rem; }
.prose h3 { font-size: 1.3rem; margin: 2rem 0 .7rem; }
.prose h4 { font-size: 1.08rem; font-style: italic; margin: 1.5rem 0 .5rem; }
.heading-anchor { color: #8a9297; font: .75em Arial, sans-serif; margin-left: .35rem; opacity: 0; text-decoration: none; }
.prose :is(h2, h3, h4):hover .heading-anchor { opacity: 1; }
.prose p, .prose ul, .prose ol { margin: .75rem 0 1rem; }
.prose li + li { margin-top: .25rem; }
.prose blockquote { border-left: .3rem solid var(--accent); color: #444a4e; margin: 1.25rem 0; padding: .1rem 1rem; }
.prose code { background: var(--code); border: 1px solid #dfe2e4; border-radius: 2px; font: .82em/1.45 "SFMono-Regular", Consolas, monospace; padding: .08em .28em; }
.code-block { background: #20272b; border-left: .35rem solid var(--accent); color: #f4f6f7; margin: 1.25rem 0; overflow: auto; padding: 1rem 1.15rem; position: relative; }
.code-block code { background: transparent; border: 0; color: inherit; display: block; font-size: .78rem; padding: 0; white-space: pre; }
.code-language { color: #bfc9ce; float: right; font: .65rem Arial, sans-serif; letter-spacing: .08em; text-transform: uppercase; }
.copy-button { background: #35444c; border: 1px solid #63747d; color: #fff; cursor: pointer; font: .67rem Arial, sans-serif; padding: .28rem .5rem; position: absolute; right: .65rem; top: .65rem; }
.table-wrap { margin: 1.25rem 0; overflow-x: auto; }
table { border-collapse: collapse; font: .83rem/1.45 Arial, sans-serif; width: 100%; }
th { background: var(--accent-soft); color: var(--accent-strong); text-align: left; }
th, td { border: 1px solid var(--line); padding: .55rem .65rem; vertical-align: top; }
tbody tr:nth-child(even) { background: #fafafa; }
hr { border: 0; border-top: 1px solid var(--line); margin: 2rem 0; }

.artifact-actions { display: flex; font: .78rem Arial, sans-serif; gap: .6rem; margin-bottom: 1rem; }
.button-link { background: var(--accent); color: #fff; padding: .5rem .75rem; text-decoration: none; }
.button-link:hover { background: var(--accent-strong); color: #fff; }

.search-results { max-width: var(--measure); }
.search-result { border-top: 1px solid var(--line); padding: 1rem 0; }
.search-result h2 { border: 0; font-size: 1.3rem; margin: 0 0 .25rem; padding: 0; }
.search-result p { color: var(--muted); margin: 0; }

.site-footer { border-top: 1px solid var(--line); color: var(--muted); font: .72rem Arial, sans-serif; margin-top: 4rem; max-width: var(--measure); padding-top: 1rem; }

@media (max-width: 800px) {
  html { font-size: 16px; }
  .site-header { align-items: stretch; flex-direction: column; }
  .search-form { max-width: none; width: 100%; }
  .page-grid { display: block; }
  .site-nav { border-bottom: 1px solid var(--line); border-right: 0; padding: 1rem; }
  .site-nav h2 { margin-top: .75rem; }
  .site-nav ul { display: flex; flex-wrap: wrap; gap: .15rem; }
  .document { box-shadow: none; padding-top: 2.25rem; }
  .toc ol { columns: 1; }
}

@media print {
  html { background: #fff; font-size: 11pt; }
  .site-header, .status-stripe, .site-nav, .copy-button { display: none; }
  .page-grid { display: block; }
  .document { box-shadow: none; padding: 0; }
  a { color: inherit; }
  .prose a[href^="http"]::after { content: " (" attr(href) ")"; font-size: .8em; }
}
