/* The app's components brought into the verus design system. Loaded after capture.css,
   styles.css and site.css, before lab.css. */
body { font-family: var(--font-sans); background: var(--paper); color: var(--ink); }
[data-theme] { background: var(--paper); color: var(--ink); min-height: 100vh; }

/* Labels are sentence case, never capitals. */
.label, .cap-table th, .cap-new, .rail-tree__label, .pt-kicker, .live__steps span { text-transform: none; letter-spacing: 0; }
.cap-table th { font: 500 13px/18px var(--font-sans); color: var(--ink-3); }
.rail-tree__label, .pt-kicker { font-size: 12px; line-height: 16px; }

/* The rail: plain paper with a hairline, no glass. */
.cap-rail { background: var(--paper); box-shadow: none; }
.cap-rail::before { content: none; }
.cap-rail__brand { gap: 10px; padding: 0 var(--space-3) var(--space-6); }
.cap-rail__brand .title { font: 500 17px/1 var(--font-sans); letter-spacing: 0; }
.cap-rail__item { font: 400 14px/20px var(--font-sans); height: 34px; }
.cap-rail__item[aria-current="page"] { background: var(--paper-3); box-shadow: none; }
@media (hover: hover) { .cap-rail__item:not([aria-current]):hover { background: var(--paper-2); color: var(--ink); } }
.cap-avatar-dot { border-radius: var(--radius-xs); background: var(--ink-4); }

/* Buttons, as vs-btn. */
.cap-btn { height: 36px; border-radius: var(--radius-md); background: transparent; border-color: var(--line-strong); font: 500 14px/1 var(--font-sans); touch-action: manipulation; -webkit-tap-highlight-color: transparent; transition: scale 150ms ease-out, background-color 150ms ease-out, border-color 150ms ease-out; }
.cap-btn:active { scale: .97; }
.cap-btn--primary { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.cap-btn--quiet { border-color: transparent; }
@media (hover: hover) {
  .cap-btn:hover { background: var(--paper-2); border-color: var(--ink-3); }
  .cap-btn--primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); }
  .cap-btn--quiet:hover { background: transparent; border-color: transparent; color: var(--ink); }
}
.providers .cap-btn { height: 48px; font-size: 15px; }

/* No pills: chips and switchers take the small radius. */
.cap-chip, .pill, .pill b, .pt-badge, .cap-new { border-radius: var(--radius-sm); }

/* Cards and panels: fill, no border. */
.cap-card, .cap-details, .live__panel { border-color: transparent; }
.cap-dialog { border-radius: var(--radius-lg); background: var(--paper-2); border: 0; box-shadow: var(--shadow-float); animation: vs-in .2s var(--ease-out) both; }
.overlay .cap-scrim { background: var(--scrim); }
.input, .cap-select, .cap-comment-field { border-radius: var(--radius-sm); background: var(--paper); border-color: var(--line-strong); }
.input:focus-visible, .cap-comment-field:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }

/* Page heads: the verus h1. */
.cap-page__head .display, .signin__col .display { font: 500 36px/42px var(--font-sans); }
.reading { font-size: 18px; line-height: 28px; }

/* An opened Activity row is a panel: a fill, no border and no shadow, which dialogs alone take. */
.cap-review[aria-expanded="true"] { border-color: transparent; box-shadow: none; }
/* A subject is code text: mono at 400, as the design's text-code. */
.cap-review__ref { font: 400 13px/20px var(--font-mono); }

/* The docs' page title: the verus h1, at 500 and with no negative tracking. */
.doc h1 { font: 500 36px/42px var(--font-sans); letter-spacing: 0; }
.doc h2 { letter-spacing: 0; }

/* Code and keys sit on the code ground. */
.keybox, .codebox { background: var(--code); border-color: transparent; }

/* Verdicts in lists use the system's shapes. */
.cap-review__row .vs-verdict { font-weight: 500; }
.cap-status svg { stroke-width: 1.8; }

/* The mark where the orb stood. */
.signin__col .vs-mark { margin-bottom: var(--space-2); }
.cap-empty .vs-mark, .cap-page .vs-mark[data-size="lg"] { margin-bottom: var(--space-2); }

/* The live check's running mark. */
.pt-spin { border-color: var(--accent); border-right-color: transparent; }

/* The rail's foot: Docs opens the public docs in a new tab. */
.cap-rail__out { width: 12px; height: 12px; margin-left: auto; opacity: .6; }

@media (max-width: 720px) { .cap-page__head .display, .signin__col .display { font-size: 30px; line-height: 36px; } }


/* A version's status beside its word: no verdict's shape, so In force never reads as Holds. */
.cap-status-shape { justify-self: center; width: 10px; height: 10px; border-radius: var(--radius-xs); }
.cap-status-shape[data-status="needs-review"] { background: var(--signal); border-radius: 50%; }
.cap-status-shape[data-status="in-force"] { background: var(--ink); }
.cap-status-shape[data-status="superseded"] { border: 1px solid var(--ink-3); }

/* A dialog taller than the screen scrolls inside its scrim, so each of its buttons can be reached. */
.overlay .cap-scrim { overflow-y: auto; grid-template-columns: minmax(0, 1fr); align-items: start; justify-items: center; padding: var(--space-4); }
.overlay .cap-dialog { margin-block: auto; min-width: 0; }

/* On a phone the rail keeps to its icons, as site.css draws it, the design's type set aside, and
   Docs keeps its book alone; a dialog keeps to the screen. */
@media (max-width: 480px) {
  .cap-rail__item { font-size: 0; gap: 0; }
  .cap-rail__out { display: none; }
  .overlay .cap-dialog { padding: var(--space-4); }
  .cap-dialog__foot > span:empty { display: none; }
  .cap-dialog__foot .row-gap { flex-wrap: wrap; }
}

/* On a phone the keys are listed one under another, each with its labels, and nothing scrolls
   sideways. */
@media (max-width: 600px) {
  .cap-tabs { flex-wrap: wrap; column-gap: var(--space-4); row-gap: var(--space-2); }
  .cap-tabs button { white-space: nowrap; }
  .table-wrap { overflow-x: visible; }
  .cap-table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
  .cap-table, .cap-table tbody { display: block; }
  .cap-table tr { display: grid; grid-template-columns: minmax(0, 1fr) auto; column-gap: var(--space-3); row-gap: 2px; padding: var(--space-3) 0; border-top: 1px solid var(--line); }
  .cap-table tr:first-child { border-top: 0; }
  .cap-table td { display: block; min-width: 0; padding: 0; border-top: 0; text-align: left; overflow-wrap: anywhere; }
  .cap-table td:last-child { grid-column: 2; grid-row: 1 / span 5; align-self: center; text-align: right; }
  .cap-table td[data-label] { font-size: 13px; color: var(--ink-2); }
  .cap-table td[data-label]::before { content: attr(data-label) " "; color: var(--ink-3); }
}

@media (prefers-reduced-motion: reduce) {
  /* A dialog opens on its last frame, and the live check moves nothing. */
  .cap-dialog { animation: none; }
  .live *, .live *::before, .live *::after { transition: none !important; animation: none !important; }
}

/* The public docs: their own top bar and the page tree, no app rail. */
.topbar { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 10; display: flex; align-items: center; gap: var(--space-4); height: 60px; padding-left: max(var(--space-6), env(safe-area-inset-left, 0px)); padding-right: max(var(--space-6), env(safe-area-inset-right, 0px)); background: var(--background); border-bottom: 1px solid var(--border); }
.brand { display: inline-flex; align-items: center; gap: var(--space-2); text-decoration: none; color: var(--foreground); }
.brand .title { font: 500 17px/1 var(--font-sans); }
.topbar__end { margin-left: auto; display: flex; align-items: center; gap: var(--space-2); }
.docs-public__name { color: var(--ink-2); text-decoration: none; font: 400 14px/20px var(--font-sans); padding-left: var(--space-4); border-left: 1px solid var(--line); }
.docs-public__grid { display: grid; grid-template-columns: 240px minmax(0, 1fr); }
.docs-public__nav { position: sticky; top: 60px; align-self: start; max-height: calc(100vh - 60px); overflow-y: auto; padding: var(--space-6) var(--space-3); border-right: 1px solid var(--line); }
.docs-public__nav .rail-tree { display: grid; }
@media (max-width: 860px) {
  .topbar { padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); }
  .docs-public__grid { grid-template-columns: minmax(0, 1fr); }
  .docs-public__nav { display: none; }
  .docs-public .docs-jump { display: block; }
}

/* Activity: a check a link opened that the filters hide says so above it, and a list with nothing
   to show says so inside its box. */
.act-hidden { margin-bottom: var(--space-3); }
.note-list .act-none { padding: var(--space-3); }

/* A check's title wraps, though it is one long word such as a subject, so that "Copy trace" stays
   beside it on a phone and the page never scrolls sideways. (trace.css comes after this file, so
   these rules name the pane to win.) */
.note-pane .note__title { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.note-pane .note__top { min-width: 0; }

/* On a phone the Lean panel's title takes its own line, and Download .lean the next, never one over
   the other. */
@media (max-width: 480px) {
  .note-pane .lean__head { flex-wrap: wrap; row-gap: var(--space-1); }
  .note-pane .lean__toggle { flex-basis: 100%; }
  .note-pane .lean__title { white-space: normal; }
}
