/* Public browsing surfaces: calm hierarchy, legible controls, and focused reading. */
:root {
  --ui-blue: #315b7d;
  --ui-blue-soft: #edf3f8;
  --ui-border: #dde5ee;
}
.atlas-workbench, .search-page {
  --accent: var(--ui-blue);
  --accent-soft: var(--ui-blue-soft);
}
:where(a, button, input, select, textarea, summary):focus-visible {
  outline: 2px solid #437cab;
  outline-offset: 3px;
}
:where(button, a, summary) { -webkit-tap-highlight-color: transparent; }

/* The Atlas keeps one shallow desktop header. */
#site-frame .header-actions [hidden] { display: none !important; }
#site-frame .workspace-switches { display: flex; align-items: center; gap: 7px; }
#site-frame .atlas-menu { display: block; flex: 1 1 auto; min-width: 0; align-self: center; }
#site-frame .atlas-menu-content { display: flex; align-items: center; gap: 6px; min-width: 0; }
#site-frame .atlas-menu > summary { display: none; }
#site-frame .atlas-menu-content > .activity-nav-link { font: 12px/1.4 var(--sans); }
#site-frame .auth-button { font-size: 11px; }
#site-frame .auth-user { font: 11px/1.4 var(--sans); }
#site-frame .quick-search-form input { font-size: 12px; }
#site-frame .quick-search-form button { font-size: 11px; }
#site-frame .layout-button { font-size: 11px; padding: 5px 9px; }
#site-frame .assistant-toggle { background: #f0f5fa; color: var(--ui-blue); }
#site-frame .assistant-toggle[aria-expanded="true"] { color: white; background: var(--ui-blue); }
.navigation-backdrop, .mobile-pane-close { display: none; }
.atlas-workbench .rail { background: #f1f5f9; padding-top: 24px; }
.atlas-workbench .browser-panel { background: #f8fafc; }
.atlas-workbench .rail-heading { padding-bottom: 16px; }
.atlas-workbench .domain-group > summary { font-size: 11px; line-height: 1.5; padding-block: 12px; }
.atlas-workbench .domain-button { border-radius: 6px; }
.atlas-workbench .domain-button b { font-size: 13px; line-height: 1.45; }
.atlas-workbench .domain-button small { font: 11px/1.5 var(--sans); margin-top: 4px; }
.atlas-workbench .domain-button em, .atlas-workbench .tree-count { font-size: 10px; font-variant-numeric: tabular-nums; }
.atlas-workbench .tree-row { min-height: 39px; border-radius: 5px; }
.atlas-workbench .tree-label b { font-size: 14px; line-height: 1.5; }
.atlas-workbench .tree-row.selected { background: #e8f0f8; box-shadow: inset 3px 0 var(--ui-blue); }
.atlas-workbench .tree-row.selected .tree-label b { color: #274d6d; }
.atlas-workbench .panel-head { padding-bottom: 20px; }
.atlas-workbench .panel-head h1 { font-size: 23px; }
.atlas-workbench .topic-index { gap: 12px; }
.atlas-workbench .topic-index-card { border-radius: 7px; padding: 17px 18px; transition: border-color .15s, background .15s; }
.atlas-workbench .topic-index-card:hover { background: #f7fafd; border-color: #9ab2c8; }
.atlas-workbench .topic-index-card b { font-size: 17px; line-height: 1.45; }
.atlas-workbench .topic-index-card span { font: 11px/1.5 var(--sans); margin-top: 7px; color: #677b90; }
.atlas-workbench .statement-card { border-radius: 7px; box-shadow: none; }
.atlas-workbench .statement-card > summary { padding: 12px 15px; background: #fff; }
.atlas-workbench .statement-heading > b { font-size: 16px; line-height: 1.5; }
.atlas-workbench .statement-content { padding: 0 16px 16px; }
.atlas-workbench .formal-block { background: #f5f8fb; border-left: 2px solid #a4bed5; font-size: 16px; line-height: 1.85; padding: 14px 16px; }
.atlas-workbench .statement-evidence > summary { padding-top: 5px; font-size: 12px; color: #526d86; letter-spacing: 0; }
.statement-reading-label { display: block; margin-bottom: 6px; color: #526d86; font: 11px/1.4 var(--sans); letter-spacing: .04em; }
.statement-reading-full { margin: 8px 0 12px; }
.statement-reading-full > summary { cursor: pointer; color: #526d86; font: 12px/1.6 var(--sans); }
.statement-reading-full > .formal-block { margin-top: 10px; }
.atlas-workbench .statement-badge { font: 10px/1.4 var(--sans); }
.atlas-workbench .statement-tools { align-self: flex-start; }
.atlas-workbench .knowledge-section-heading h3 { font: 500 17px/1.5 var(--sans); color: #40566c; }
.atlas-assistant .assistant-form textarea:focus { border-color: #739aba; }
.atlas-assistant .assistant-welcome { padding-top: 26px; }
.atlas-assistant .assistant-welcome button { line-height: 1.5; min-height: 44px; }
.atlas-assistant .assistant-result { padding-block: 14px; }

/* Portal and documentation share the same type and navigation rhythm. */
.portal-header, .portal-footer { max-width: 1200px; }
.portal-header { padding-top: 19px; padding-bottom: 19px; min-height: 70px; }
.portal-header nav { gap: 22px; }
.portal-header nav a { font-size: 13px; }
.portal-brand { letter-spacing: -.5px; }
.home-page main { max-width: 1200px; }
.home-page .intro { padding-top: 34px; padding-bottom: 26px; }
.home-page .intro h1 { font-size: clamp(34px, 3.5vw, 46px); letter-spacing: -1.1px; }
.home-page .intro-heading { justify-content: space-between; gap: 20px; }
.home-page .intro .atlas-button { padding: 9px 18px; min-height: 44px; border-radius: 6px; font-size: 14px; }
.home-page .lede { max-width: 880px; line-height: 1.8; }
.home-page .atlas-goals { gap: 16px 36px; margin-top: 24px; }
.home-page .atlas-goals li { padding-left: 15px; border-left-color: #cbdbe8; }
.home-page .atlas-goals strong { margin-bottom: 3px; font-size: 14px; }
.home-page .about-link { font-size: 13px; text-decoration: none; }
.home-page .about-link:hover { text-decoration: underline; }
.home-page .search-panel { padding: 16px 20px; border-radius: 8px; border-color: #d5e0eb; box-shadow: 0 3px 12px #1b355005; }
.home-page .search-row input { min-height: 44px; border-radius: 5px; }
.home-page .search-row button { background: var(--ui-blue); color: #fff; border-color: var(--ui-blue); border-radius: 5px; padding-inline: 20px; }
.home-page .search-row button:hover { background: #244761; }
.home-page .search-method select { min-height: 36px; font-size: 13px; }
.home-page .domain-overview { padding-top: 30px; }
.home-page .section-heading h2 { font-size: 26px; }
.home-page .section-heading > a { font-size: 13px; }
.home-page .domain-overview-grid { gap: 14px; margin-top: 22px; }
.home-page .domain-overview-item { position: relative; padding: 19px 20px; border-radius: 8px; background: #fff; border-color: var(--ui-border); transition: border-color .15s, box-shadow .15s; }
.home-page .domain-overview-item:hover, .home-page .domain-overview-item:focus-within { border-color: #93adc5; box-shadow: 0 3px 14px #1e45630a; }
.home-page .domain-overview-heading, .home-page .domain-overview-heading h3 { width: 100%; }
.home-page .domain-overview-heading h3 { font-size: 21px; line-height: 1.35; }
.home-page .domain-entry-link { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; color: var(--ink); text-decoration: none; }
.home-page .domain-entry-link::after { content: ''; position: absolute; inset: 0; border-radius: inherit; }
.home-page .domain-entry-arrow { color: #7a97af; font: 19px/1 var(--sans); }
.home-page .domain-overview-item:hover .domain-entry-arrow { color: var(--ui-blue); }
.home-page .domain-summary { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 13px; font-size: 12px; line-height: 1.5; }
.home-page .domain-summary strong { color: #445b70; font-weight: 600; font-variant-numeric: tabular-nums; }
.home-page .domain-summary > span { white-space: nowrap; }
.home-page .lower-grid { padding: 30px 0; gap: 36px; }
.home-page .resource-links { gap: 12px; }
.home-page .contributors:not(:has(li)) { display: none; }

/* Search leaves room for results while keeping the graph within reach. */
.search-page .masthead { height: auto; min-height: 64px; padding-block: 14px; }
.search-page .search-header-actions { gap: 22px; }
.search-page .search-header-actions a { font: 13px/1.5 var(--sans); }
.search-page .search-main { width: min(1440px, calc(100% - 64px)); padding-top: 30px; }
.search-page .search-heading h1 { font-size: 38px; margin: 9px 0 22px; letter-spacing: -.5px; }
.search-page .search-input-wrap { border-radius: 7px; box-shadow: 0 3px 12px #18212f05; }
.search-page .search-input-wrap input { padding-block: 11px; font: 16px/1.5 var(--sans); }
.search-page .search-input-wrap button { border-radius: 4px; font: 13px var(--sans); }
.search-page .search-toolbar { gap: 13px; margin-top: 18px; }
.search-page .search-filters { border-radius: 6px; padding: 4px; }
.search-page .search-filters button { padding: 8px 14px; font: 12px/1.4 var(--sans); }
.search-options { width: 100%; border-bottom: 1px solid var(--ui-border); }
.search-options > summary { display: flex; align-items: center; gap: 10px; list-style: none; padding: 8px 0 12px; cursor: pointer; font: 500 12px/1.5 var(--sans); color: #4d647a; }
.search-options > summary::-webkit-details-marker { display: none; }
.search-options > summary::before { content: ''; width: 5px; height: 5px; border-right: 1.5px solid; border-bottom: 1.5px solid; transform: rotate(-45deg); margin: 0 3px; }
.search-options[open] > summary::before { transform: rotate(45deg); }
.search-options > summary span { font-size: 11px; font-weight: 400; color: var(--muted); }
.search-page .search-result-controls { padding-bottom: 14px; gap: 12px; }
.search-page .search-result-controls label > span { font: 11px/1.5 var(--sans); text-transform: none; letter-spacing: 0; }
.search-page .search-result-controls select { min-height: 36px; font: 12px var(--sans); border-radius: 5px; }
.search-page .search-status { font: 12px/1.7 var(--sans); text-transform: none; letter-spacing: 0; color: #5d7084; }
.search-page .search-workspace { gap: 28px; grid-template-columns: minmax(0, 1.15fr) minmax(340px, .85fr); margin-top: 22px; }
.search-page .search-result { border-radius: 7px; box-shadow: none; }
.search-page .search-result.graph-selected { border-color: #a2bad0; box-shadow: inset 3px 0 var(--ui-blue); }
.search-page .search-result-link { padding: 18px 20px 12px; gap: 8px; }
.search-page .search-result-labels { gap: 9px; }
.search-page .search-result-badge { font: 10px/1.4 var(--sans); padding: 3px 7px; border-radius: 4px; letter-spacing: .2px; }
.search-page .search-result-domain { font: 12px/1.5 var(--sans); }
.search-page .search-result h2 { font-size: 23px; line-height: 1.35; margin: 10px 0; }
.search-page .search-result-content > p { font: 14px/1.75 var(--sans); color: #5d6e80; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.search-page .search-result-path { font: 11px/1.6 var(--sans); }
.search-page .search-result-id { font: 10px/1.5 var(--mono); padding: 2px 5px; background: #f5f7fa; }
.search-page .search-result-graph-action { padding-top: 2px; }
.search-page .search-feedback { padding: 10px 20px; background: #fbfcfe; font-family: var(--sans); }
.search-page .search-feedback-prompt, .search-page .search-feedback-state { font: 11px/1.5 var(--sans); }
.search-page .search-feedback-button { font: 11px/1.5 var(--sans); min-height: 30px; }
.search-page .search-graph-panel { top: 86px; border-radius: 8px; max-height: calc(100dvh - 108px); }
.graph-preview-title { font-size: 14px; line-height: 1.65; }
.graph-preview-entries li { border-bottom: 1px solid #eef2f6; padding-block: 7px; }
.graph-preview-entries li:last-child { border: 0; }
.graph-preview-body svg a:focus { outline: none; }
.graph-preview-body svg a:focus circle, .graph-preview-body svg a:hover circle { stroke: #315b7d; stroke-width: 3px; }

/* Long API documents have an index and a comfortable reading measure. */
.api-main { max-width: 1200px; padding-top: 32px; }
.api-doc-links { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.api-doc-links > a { position: relative; border-radius: 8px; padding: 25px 54px 25px 26px; min-height: 126px; border-color: #a9c0d4; background: #edf3f8; }
.api-doc-links strong { font: 600 28px/1.25 var(--sans); }
.api-doc-links span { font-size: 14px; color: #4b647a; }
.api-doc-links > a::after { content: '→'; position: absolute; top: 26px; right: 24px; font: 24px/1.3 var(--sans); }
.api-doc-links > a:first-child { border-color: var(--ui-blue); background: var(--ui-blue); color: #fff; }
.api-doc-links > a:first-child span { color: #e3edf6; }
.api-doc-links > a:first-child:hover { background: #264b69; }
.api-doc-links > a:last-child { grid-column: 1 / -1; flex-direction: row; align-items: baseline; flex-wrap: wrap; gap: 8px 16px; min-height: 0; padding: 4px 0; border: 0; background: transparent; }
.api-doc-links > a:last-child strong { font-size: 16px; }
.api-doc-links > a:last-child::after { content: none; }
.api-doc-links > a:last-child:hover strong { text-decoration: underline; text-underline-offset: 4px; }
.api-doc-nav { gap: 10px 18px; margin: 24px 0 16px; }
.api-doc-nav a { display: flex; align-items: center; min-height: 44px; padding: 8px 0; border: 0; background: transparent; font: 500 15px/1.5 var(--sans); }
.api-doc-nav .api-doc-tab { flex: 1 1 calc(50% - 18px); justify-content: space-between; gap: 16px; min-height: 68px; padding: 16px 22px; border: 1px solid #afc3d5; border-radius: 8px; background: #fff; color: var(--ui-blue); font: 600 20px/1.4 var(--sans); }
.api-doc-nav .api-doc-tab::after { content: '→'; font-size: 22px; }
.api-doc-nav .api-doc-tab:hover { background: var(--ui-blue-soft); border-color: var(--ui-blue); }
.api-doc-nav .api-doc-tab[aria-current="page"] { border-color: var(--ui-blue); background: var(--ui-blue); color: #fff; }
.api-doc-nav .api-doc-tab[aria-current="page"]::after { content: '✓'; font-size: 18px; }
.api-panel { border-radius: 8px; }
.api-panel p { font-size: 14px; }
.api-start { padding-bottom: 10px; }
.docs-page .api-guide { max-width: 1200px; }
.docs-page .api-intro { max-width: none; margin-bottom: 32px; }
.docs-page .api-intro h1 { font-size: 42px; margin-bottom: 12px; }
.docs-layout { display: grid; grid-template-columns: 220px minmax(0, 1fr); align-items: start; gap: 36px; }
.docs-toc { position: sticky; top: 28px; border: 1px solid var(--ui-border); border-radius: 8px; padding: 18px 12px; background: #edf3f8; }
.docs-toc p { font: 600 11px/1.5 var(--sans); color: #526d85; letter-spacing: 1px; margin: 0 10px 10px; }
.docs-toc a { display: block; padding: 10px; border-radius: 5px; font: 500 15px/1.5 var(--sans); color: #365772; text-decoration: none; }
.docs-toc a:hover { color: var(--ui-blue); background: #fff; text-decoration: underline; }
.docs-content { min-width: 0; max-width: 820px; padding-bottom: 24px; }
.docs-content > h2 { scroll-margin-top: 24px; font-size: 26px; border-top: 1px solid var(--ui-border); margin: 30px 0 18px; padding-top: 26px; }
.docs-content p, .docs-content li, .docs-content td, .docs-content th { font: 14px/1.8 var(--sans); }
.docs-content li { padding-bottom: 6px; }
.docs-content ul { padding-left: 22px; }
.docs-content pre { border-radius: 7px; background: #fff; padding: 20px; font: 12px/1.8 var(--mono); }
.docs-content table { display: table; width: 100%; background: white; border: 1px solid var(--ui-border); border-radius: 6px; }
.docs-content th { background: #f0f4f8; color: #40586f; font-weight: 600; }
.docs-content td, .docs-content th { padding: 12px 15px; vertical-align: top; }
.docs-content td { overflow-wrap: anywhere; }

@media (max-width: 1199px) {
  #site-frame .atlas-menu { display: block; position: relative; margin-left: auto; flex: 0 0 auto; }
  #site-frame .atlas-menu > summary { display: grid; place-items: center; width: 34px; height: 32px; border: 1px solid var(--ui-border); border-radius: 5px; cursor: pointer; color: var(--ui-blue); list-style: none; font: 600 14px var(--sans); }
  #site-frame .atlas-menu > summary::-webkit-details-marker { display: none; }
  #site-frame .atlas-menu-content { position: absolute; top: 42px; right: 0; display: flex; flex-direction: column; align-items: stretch; gap: 3px; width: 280px; padding: 12px; border: 1px solid var(--ui-border); border-radius: 8px; box-shadow: 0 12px 36px #18212f20; background: white; z-index: 40; }
  #site-frame .atlas-menu-content > a { min-height: 40px; padding: 11px 12px; border-radius: 4px; font: 13px/1.5 var(--sans); }
  #site-frame .atlas-menu-content > a:hover { background: var(--ui-blue-soft); }
  #site-frame .header-account-area { flex-direction: column; align-items: stretch; margin: 8px 0 0; gap: 12px; padding: 14px 8px 6px; border-top: 1px solid var(--ui-border); }
  #site-frame .header-account-area .auth-control { flex-wrap: wrap; justify-content: flex-start; gap: 10px; }
  #site-frame .header-account-area .atlas-total-count { justify-content: flex-start; }
  #site-frame .quality-queue-button::before { content: none; }
  .home-page .domain-summary { gap: 5px 12px; }
}
@media (max-width: 900px) {
  .search-page .search-main { width: calc(100% - 40px); padding-top: 26px; }
  .search-page .search-workspace { grid-template-columns: 1fr; gap: 18px; }
  .search-page .search-graph-panel { position: static; max-height: none; }
  .docs-layout { grid-template-columns: 1fr; gap: 24px; }
  .docs-toc { position: static; display: flex; flex-wrap: wrap; gap: 4px 8px; padding: 14px; }
  .docs-toc p { width: 100%; margin: 0 8px 4px; }
  .docs-toc a { padding: 8px; font-size: 14px; }
}
@media (max-width: 880px) {
  #site-frame > .masthead { display: grid; grid-template-columns: 86px minmax(0, 1fr) 34px; gap: 8px 10px; padding: 11px 14px; z-index: 24; }
  #site-frame .brand { grid-column: 1; grid-row: 1; }
  #site-frame .brand b { font-size: 20px; }
  #site-frame .header-actions { display: contents; }
  #site-frame .atlas-home-link { display: none; }
  #site-frame .quick-search-form { grid-column: 2; grid-row: 1; width: 100%; min-width: 0; }
  #site-frame .quick-search-form input { width: 0; font-size: 16px; padding-inline: 7px; }
  #site-frame .quick-search-form button { font-size: 11px; }
  #site-frame .workspace-switches { grid-column: 1 / -1; grid-row: 2; justify-content: space-between; gap: 10px; }
  #site-frame .layout-controls { min-height: 34px; }
  #site-frame .layout-button { min-height: 28px; font-size: 12px; padding: 5px 10px; }
  #site-frame .assistant-toggle { min-height: 34px; font-size: 12px; padding-inline: 12px; }
  #site-frame .atlas-menu { grid-column: 3; grid-row: 1; margin: 0; align-self: center; }
  #site-frame .atlas-menu > summary { height: 34px; }
  .atlas-workbench .app-shell { min-height: calc(100dvh - var(--atlas-header-height, 100px)); }
  .atlas-workbench .workspace { min-height: 0; }
  .atlas-workbench .detail-panel { height: auto; min-height: calc(100dvh - var(--atlas-header-height, 100px)); border-top: 0; }
  .atlas-workbench .rail, .atlas-workbench .browser-panel { position: fixed; top: var(--atlas-header-height, 100px); left: 0; bottom: 0; width: min(360px, calc(100% - 32px)); height: calc(100dvh - var(--atlas-header-height, 100px)); max-height: none; z-index: 22; box-shadow: 12px 0 36px #18212f18; overflow: hidden; display: flex; flex-direction: column; border-right: 1px solid var(--ui-border); }
  .atlas-workbench .rail { padding: 22px 16px 14px; }
  .atlas-workbench .browser-panel { padding: 0; }
  .atlas-workbench.library-hidden .rail, .atlas-workbench.directory-hidden .browser-panel { display: none; }
  .atlas-workbench .rail-heading { align-items: center; }
  .atlas-workbench .domain-scroll { overflow: auto; margin: 8px -4px 0; padding: 7px 4px 20px; mask-image: none; -webkit-mask-image: none; }
  .atlas-workbench .domain-nav { display: grid; }
  .atlas-workbench .domain-group-items { display: grid; }
  .atlas-workbench .domain-button { width: 100%; min-height: 60px; }
  .atlas-workbench .tree-view { min-height: 0; max-height: none; flex: 1; }
  .atlas-workbench .mobile-pane-close { display: inline-grid; place-items: center; font-size: 22px; }
  .atlas-workbench .navigation-backdrop { display: none; position: fixed; top: var(--atlas-header-height, 100px); inset-inline: 0; bottom: 0; z-index: 21; border: 0; background: #182b3f52; width: 100%; cursor: pointer; }
  .atlas-workbench:not(.library-hidden) .navigation-backdrop, .atlas-workbench:not(.directory-hidden) .navigation-backdrop { display: block; }
  .atlas-workbench .topic-hero { padding: 22px 18px 16px; }
  .atlas-workbench .topic-hero h2 { font-size: 29px; }
  .atlas-workbench .detail-body { padding: 18px 16px 32px; }
  .atlas-workbench .statement-heading > b { font-size: 16px; }
  .atlas-workbench .statement-tools > .compact-action { width: 34px; height: 34px; min-height: 34px; }
  .atlas-workbench .formal-block { padding: 12px; font-size: 16px; }
  .atlas-workbench .topic-index-card { padding: 15px; }
}
@media (max-width: 620px) {
  .portal-header, .portal-footer, .home-page main, .api-main { padding-inline: 20px; }
  .portal-header { gap: 13px; padding-block: 18px; min-height: 0; }
  .portal-header-actions { gap: 10px; }
  .portal-header nav { gap: 4px 18px; justify-content: flex-start; }
  .portal-header nav a { font-size: 13px; min-height: 32px; }
  .home-page .intro { padding-top: 27px; }
  .home-page .intro-heading { gap: 16px; }
  .home-page .intro h1 { font-size: 37px; line-height: 1.15; }
  .home-page .lede { font-size: 15px; }
  .home-page .atlas-goals { gap: 14px; }
  .home-page .search-panel { padding: 17px; }
  .home-page .search-panel h2 { font-size: 23px; }
  .home-page .search-method { margin-top: 2px; }
  .home-page .domain-overview { padding-top: 26px; }
  .home-page .domain-overview-grid { grid-template-columns: 1fr; gap: 10px; margin-top: 18px; }
  .home-page .domain-overview-item { padding: 17px 18px; }
  .home-page .domain-overview-heading h3 { font-size: 22px; }
  .home-page .domain-summary { gap: 18px; margin-top: 10px; }
  .home-page .section-heading { align-items: center; gap: 12px; }
  .home-page .section-heading h2 { font-size: 25px; }
  .home-page .section-heading > a { font-size: 12px; }
  .home-page .participate { padding-left: 0; }
  .search-page .masthead { padding: 16px 20px; gap: 12px; }
  .search-page .search-header-actions { gap: 6px 19px; }
  .search-page .search-header-actions a { font-size: 12px; }
  .search-page .search-heading h1 { font-size: 33px; }
  .search-page .search-filters button { min-height: 36px; }
  .search-page .search-input-wrap { grid-template-columns: minmax(0, 1fr) auto; gap: 4px; }
  .search-page .search-input-wrap input { padding-inline: 9px; }
  .search-page .search-input-wrap button { min-height: 42px; padding-inline: 15px; }
  .search-options > summary { align-items: baseline; flex-wrap: wrap; gap: 6px; }
  .search-options > summary span { margin-left: auto; font-size: 10px; }
  .search-page .search-result-controls { grid-template-columns: 1fr 1fr; padding-top: 4px; }
  .search-page .search-result h2 { font-size: 22px; }
  .search-page .search-result-link { padding-inline: 17px; }
  .search-page .search-result-graph-action { padding-inline: 17px; }
  .search-page .search-feedback { padding-inline: 17px; }
  .search-page .search-feedback-prompt { width: auto; }
  .search-page .search-workspace { margin-top: 18px; }
  .search-page .search-graph-panel { padding: 17px; }
  .api-grid, .api-fields { grid-template-columns: 1fr; }
  .api-main .api-intro h1, .docs-page .api-intro h1 { font-size: 36px; }
  .api-main .api-doc-links { gap: 10px; margin-top: 22px; }
  .api-doc-links { grid-template-columns: 1fr; }
  .api-doc-links > a { min-height: 110px; padding: 20px 48px 20px 20px; }
  .api-doc-links strong { font-size: 26px; }
  .api-doc-links > a::after { top: 20px; right: 20px; }
  .api-doc-links > a:last-child { padding-top: 6px; }
  .api-panel { padding: 21px; }
  .api-doc-nav { gap: 10px 16px; }
  .api-doc-nav a { font-size: 15px; }
  .api-doc-nav .api-doc-tab { min-height: 60px; padding: 14px 16px; font-size: 18px; gap: 8px; }
  .docs-content > h2 { font-size: 25px; line-height: 1.35; }
  .docs-content pre { padding: 15px; font-size: 12px; }
  .docs-content table { display: block; max-width: 100%; overflow-x: auto; }
  .docs-content td, .docs-content th { padding: 10px; min-width: 100px; }
}
@media (prefers-reduced-motion: reduce) {
  .home-page .domain-overview-item, .atlas-workbench .topic-index-card { transition: none; }
}

/* Shorten the introduction on phones while keeping its full purpose available. */
.home-purpose > summary { display: none; }
#site-frame .quick-search-form button::before { content: none; }
@media (max-width: 880px) {
  .atlas-workbench:not(.library-hidden), .atlas-workbench:not(.directory-hidden) { overflow: hidden; }
}
@media (max-width: 620px) {
  .home-page .portal-header { position: relative; }
  .home-page .portal-header-actions > .atlas-total-count { position: absolute; top: 24px; right: 20px; }
  .home-purpose { margin-top: 18px; }
  .home-purpose > summary { display: flex; align-items: center; justify-content: space-between; padding: 10px 0; font: 13px/1.5 var(--sans); color: var(--ui-blue); cursor: pointer; list-style: none; }
  .home-purpose > summary::-webkit-details-marker { display: none; }
  .home-purpose[open] > summary > span { transform: rotate(180deg); }
  .home-purpose .atlas-goals { margin-top: 14px; }
}

.atlas-workbench .tree-topic-link { display: block; min-width: 0; width: 100%; padding: 0; border: 0; background: transparent; color: inherit; text-align: left; font: inherit; cursor: pointer; }

/* Preserve complete account labels in the compact navigation menu. */
#site-frame .atlas-menu-content .quality-queue-label { display: inline; }
#site-frame .atlas-menu-content .quality-queue-button::before,
#site-frame .atlas-menu-content .admin-review-button::before { content: none; }

/* Formal declarations are evidence, with provenance and links in one header. */
.atlas-workbench .atlas-formal-sources { margin: 0; padding: 0; border: 0; }
.atlas-workbench .atlas-formal-source { margin: 8px 0 0; padding: 11px 13px; }
.atlas-workbench .atlas-formal-source:first-child { margin-top: 0; }
.atlas-workbench .formal-source-heading { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: baseline; gap: 6px 14px; }
.atlas-workbench .formal-source-identity { display: flex; flex: 1 1 240px; align-items: baseline; flex-wrap: wrap; gap: 5px 8px; min-width: 0; }
.atlas-workbench .formal-source-identity strong { font-size: 12px; overflow-wrap: anywhere; }
.atlas-workbench .formal-source-library { padding: 2px 8px; border: 1px solid #b9cee2; border-radius: 4px; background: #e4eef8; color: #244f73; font: 700 12px/1.5 var(--sans); white-space: nowrap; }
.atlas-workbench .formal-source-prover { justify-self: end; font: 11px/1.5 var(--sans); color: #718397; white-space: nowrap; }
.atlas-workbench .formal-source-heading .formal-source-links { flex: 0 0 auto; gap: 13px; margin: 0; font-size: 12px; }
.atlas-workbench .formal-source-links a { white-space: nowrap; }
.atlas-workbench .atlas-formal-source .formal-source-locator { margin: 5px 0 7px; font-size: 11px; line-height: 1.6; }
.atlas-workbench .formal-source-pair { margin-top: 7px; }
.atlas-workbench .formal-source-pair > summary { font-size: 12px; font-weight: 500; }
.atlas-workbench .formal-source-lean pre { margin: 8px 0; }

@container entry (max-width: 560px) {
  .atlas-workbench .formal-source-heading { grid-template-columns: minmax(0, 1fr) auto; }
  .atlas-workbench .formal-source-identity { grid-column: 1; grid-row: 1; }
  .atlas-workbench .formal-source-prover { grid-column: 2; grid-row: 1; }
  .atlas-workbench .formal-source-heading .formal-source-links { grid-column: 1 / -1; grid-row: 2; }
}
