/* Generated by OCG v1.6.0 from templates/styles and the ocg.config.json theme. Change those sources instead of this file. */

@layer ocg.tokens, ocg.base, ocg.layout, ocg.components, ocg.pages, ocg.theme;

@layer ocg.tokens {
:root {
  --ocg-color-page: #f4f8f7;
  --ocg-color-page-alt: #e7f2f1;
  --ocg-color-panel: #ffffff;
  --ocg-color-card: #ffffff;
  --ocg-color-text: #163238;
  --ocg-color-muted: #546a70;
  --ocg-color-accent: #08717a;
  --ocg-color-accent-start: #11929a;
  --ocg-color-accent-border: #74bcc0;
  --ocg-color-accent-strong: #064e56;
  --ocg-color-border: #c9dddc;
  --ocg-color-warm-accent: #d89a4a;
  --ocg-font-heading: "Space Grotesk", sans-serif;
  --ocg-font-body: "IBM Plex Sans", sans-serif;
  --ocg-font-mono: "IBM Plex Mono", monospace;
  --ocg-radius-sm: 4px;
  --ocg-radius-md: 6px;
  --ocg-radius-lg: 8px;
  --ocg-radius-xl: 10px;
}

/*
 * Design tokens.
 *
 * The primitive tokens (--ocg-color-*, --ocg-font-*, --ocg-radius-*) are generated
 * from the `theme` section of ocg.config.json and emitted just before this file.
 * Everything below derives from them, so changing a theme color or radius restyles
 * every component that uses it.
 *
 * Component tokens (the last block) are the public styling surface: each one maps to
 * a `theme.components.<component>.<option>` config key, and a `theme.customCss` file
 * can override any of them directly.
 */
:root {
  /* Semantic colors */
  --ocg-color-text-secondary: var(--ocg-color-muted);
  --ocg-color-subtle: var(--ocg-color-page-alt);
  --ocg-color-subtle-soft: color-mix(in srgb, var(--ocg-color-page-alt) 50%, var(--ocg-color-panel));
  --ocg-color-border-subtle: color-mix(in srgb, var(--ocg-color-border) 55%, var(--ocg-color-panel));
  --ocg-color-border-strong: color-mix(in srgb, var(--ocg-color-border) 78%, var(--ocg-color-text));
  --ocg-color-overlay-hover: color-mix(in srgb, var(--ocg-color-text) 5%, transparent);
  --ocg-color-overlay-active: color-mix(in srgb, var(--ocg-color-text) 8%, transparent);
  --ocg-color-accent-subtle: color-mix(in srgb, var(--ocg-color-accent) 8%, var(--ocg-color-panel));
  --ocg-color-accent-muted: color-mix(in srgb, var(--ocg-color-accent) 24%, var(--ocg-color-panel));
  --ocg-color-on-accent: var(--ocg-color-panel);
  --ocg-color-focus: color-mix(in srgb, var(--ocg-color-accent) 60%, transparent);
  --ocg-color-danger: #b3261e;
  --ocg-color-warning: #a05a00;
  --ocg-color-graph-surface: color-mix(in srgb, var(--ocg-color-panel) 97%, var(--ocg-color-page-alt));
  --ocg-color-tooltip-background: color-mix(in srgb, var(--ocg-color-text) 94%, var(--ocg-color-accent-strong));
  --ocg-color-tooltip-text: var(--ocg-color-panel);

  /* Elevation: resting surfaces stay nearly flat; only floating elements cast a
     soft, layered shadow. */
  --ocg-shadow-sm: 0 1px 2px color-mix(in srgb, var(--ocg-color-text) 5%, transparent);
  --ocg-shadow-md:
    0 1px 2px color-mix(in srgb, var(--ocg-color-text) 5%, transparent),
    0 4px 12px -2px color-mix(in srgb, var(--ocg-color-text) 10%, transparent);
  --ocg-shadow-lg:
    0 2px 4px -1px color-mix(in srgb, var(--ocg-color-text) 6%, transparent),
    0 16px 32px -8px color-mix(in srgb, var(--ocg-color-text) 18%, transparent);

  /* Type scale */
  --ocg-text-xs: 0.75rem;
  --ocg-text-sm: 0.8125rem;
  --ocg-text-md: 0.875rem;
  --ocg-text-base: 0.9375rem;
  --ocg-text-lg: 1.0625rem;
  --ocg-text-xl: 1.25rem;
  --ocg-text-2xl: clamp(1.5rem, 1.1rem + 1.2vw, 1.875rem);
  --ocg-text-3xl: clamp(1.875rem, 1.2rem + 2vw, 2.5rem);
  --ocg-leading-tight: 1.2;
  --ocg-leading-body: 1.6;

  /* Motion */
  --ocg-duration-fast: 120ms;
  --ocg-ease: cubic-bezier(0.2, 0, 0, 1);

  /* Layout. Breakpoints used by the layout and page files: 1100px (graph sidebar),
     1040px (page TOC), 860px (single column), and 640px (full-screen graph). */
  --ocg-shell-width: 1120px;
  --ocg-shell-width-toc: 1320px;
  --ocg-shell-width-wide: 1450px;

  /* Component tokens: theme.components.<component>.<option> */
  --ocg-header-background: transparent;
  --ocg-header-border: transparent;
  --ocg-header-divider: var(--ocg-color-border);
  --ocg-header-radius: 0;
  --ocg-header-shadow: none;
  --ocg-header-padding: 18px 0 14px;

  --ocg-nav-radius: var(--ocg-radius-md);
  --ocg-nav-text: var(--ocg-color-text-secondary);
  --ocg-nav-hover-background: var(--ocg-color-overlay-hover);
  --ocg-nav-active-background: var(--ocg-color-overlay-active);
  --ocg-nav-active-text: var(--ocg-color-text);

  --ocg-button-radius: var(--ocg-radius-md);
  --ocg-button-height: 36px;
  --ocg-button-padding-x: 14px;
  --ocg-button-font-size: var(--ocg-text-md);
  --ocg-button-font-weight: 500;
  --ocg-button-primary-background: var(--ocg-color-accent);
  --ocg-button-primary-text: var(--ocg-color-on-accent);
  --ocg-button-primary-border: var(--ocg-color-accent-border);
  --ocg-button-primary-hover-background: var(--ocg-color-accent-strong);
  --ocg-button-secondary-background: var(--ocg-color-panel);
  --ocg-button-secondary-text: var(--ocg-color-text);
  --ocg-button-secondary-border: var(--ocg-color-border-strong);
  --ocg-button-secondary-hover-background: var(--ocg-color-subtle-soft);

  --ocg-panel-background: var(--ocg-color-panel);
  --ocg-panel-border: var(--ocg-color-border);
  --ocg-panel-radius: var(--ocg-radius-xl);
  --ocg-panel-shadow: var(--ocg-shadow-sm);
  --ocg-panel-padding: 24px;

  --ocg-card-background: var(--ocg-color-card);
  --ocg-card-border: var(--ocg-color-border);
  --ocg-card-radius: var(--ocg-radius-lg);
  --ocg-card-shadow: none;
  --ocg-card-padding: 16px;

  --ocg-badge-background: var(--ocg-color-accent-subtle);
  --ocg-badge-text: var(--ocg-color-accent-strong);
  --ocg-badge-border: transparent;
  --ocg-badge-radius: var(--ocg-radius-sm);

  --ocg-tabs-background: var(--ocg-color-subtle);
  --ocg-tabs-border: transparent;
  --ocg-tabs-radius: var(--ocg-radius-lg);
  --ocg-tabs-text: var(--ocg-color-text-secondary);
  --ocg-tabs-active-background: var(--ocg-color-panel);
  --ocg-tabs-active-text: var(--ocg-color-text);

  --ocg-input-background: var(--ocg-color-panel);
  --ocg-input-border: var(--ocg-color-border-strong);
  --ocg-input-text: var(--ocg-color-text);
  --ocg-input-radius: var(--ocg-radius-md);
  --ocg-input-focus-border: var(--ocg-color-accent);

  --ocg-table-border: var(--ocg-color-border);
  --ocg-table-radius: var(--ocg-radius-lg);
  --ocg-table-header-background: var(--ocg-color-subtle-soft);
  --ocg-table-header-text: var(--ocg-color-text-secondary);
  --ocg-table-stripe-background: transparent;
  --ocg-table-hover-background: color-mix(in srgb, var(--ocg-color-page-alt) 45%, transparent);

  --ocg-code-background: var(--ocg-color-subtle-soft);
  --ocg-code-text: var(--ocg-color-text);
  --ocg-code-border: var(--ocg-color-border-subtle);
  --ocg-code-radius: var(--ocg-radius-lg);

  --ocg-callout-background: var(--ocg-color-subtle-soft);
  --ocg-callout-border: var(--ocg-color-border-subtle);
  --ocg-callout-text: var(--ocg-color-text-secondary);
  --ocg-callout-radius: var(--ocg-radius-md);
}
}

@layer ocg.base {
/* Element defaults shared by every generated page except the ReSpec document. */
*,
*::before,
*::after {
  box-sizing: border-box;
}
html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}
body {
  margin: 0;
  min-height: 100vh;
  background: var(--ocg-color-page);
  color: var(--ocg-color-text);
  font-family: var(--ocg-font-body);
  font-size: var(--ocg-text-base);
  line-height: var(--ocg-leading-body);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
a {
  color: var(--ocg-color-accent);
  text-decoration: none;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}
a:hover {
  text-decoration: underline;
}
:focus-visible {
  outline: 2px solid var(--ocg-color-focus);
  outline-offset: 2px;
}
::selection {
  background: color-mix(in srgb, var(--ocg-color-accent) 18%, transparent);
}
h1,
h2,
h3 {
  margin: 0;
  color: var(--ocg-color-text);
  font-family: var(--ocg-font-heading);
  font-weight: 600;
  line-height: var(--ocg-leading-tight);
  letter-spacing: -0.011em;
}
h1 {
  margin-bottom: 12px;
  font-size: var(--ocg-text-2xl);
  letter-spacing: -0.02em;
}
h2 {
  font-size: var(--ocg-text-xl);
}
h3 {
  margin-bottom: 8px;
  font-size: 1rem;
}
p {
  margin: 0;
  color: var(--ocg-color-text-secondary);
  line-height: var(--ocg-leading-body);
}
strong {
  font-weight: 600;
}
code,
kbd,
pre,
samp {
  font-family: var(--ocg-font-mono);
}
code {
  font-size: 0.9em;
}
pre code {
  font-size: inherit;
}
img {
  max-width: 100%;
}
section[id] {
  scroll-margin-top: 22px;
}
.plain-list {
  margin: 0;
  padding-left: 18px;
  color: var(--ocg-color-text-secondary);
  line-height: 1.65;
}
.plain-list li + li {
  margin-top: 4px;
}
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
}
}

@layer ocg.layout {
/* Page shell, the optional table-of-contents column, and shared content grids. */
.page-shell {
  width: min(var(--ocg-shell-width), calc(100% - 32px));
  margin: 0 auto;
  padding: 12px 0 56px;
}
.page-has-toc .page-shell {
  width: min(var(--ocg-shell-width-toc), calc(100% - 40px));
}
.page-graph .page-shell {
  width: min(var(--ocg-shell-width-wide), calc(100% - 40px));
  padding-bottom: 40px;
}
.page-content-layout {
  --ocg-toc-motion: 0.24s;
  --ocg-toc-ease: cubic-bezier(0.22, 1, 0.36, 1);
  display: grid;
  grid-template-columns: minmax(180px, 214px) minmax(0, 1fr);
  align-items: start;
  gap: 24px;
  transition:
    grid-template-columns var(--ocg-toc-motion) var(--ocg-toc-ease),
    gap var(--ocg-toc-motion) var(--ocg-toc-ease);
}
.page-content-layout--toc-collapsed {
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 20px;
}
.page-content {
  min-width: 0;
}
.card-grid,
.metrics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
}
@media (max-width: 1040px) {
  .page-has-toc .page-shell {
    width: min(var(--ocg-shell-width), calc(100% - 32px));
  }
  .page-content-layout,
  .page-content-layout--toc-collapsed {
    grid-template-columns: 1fr;
    gap: 16px;
  }
}
@media (max-width: 860px) {
  .page-shell,
  .page-has-toc .page-shell,
  .page-graph .page-shell {
    width: calc(100% - 24px);
  }
}
}

@layer ocg.components {
/* Site header: brand mark, project identity, and page navigation. Also used by the
   ReSpec specification page, so it sets its own font and link styles. */
.site-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 24px;
  margin-bottom: 24px;
  padding: var(--ocg-header-padding);
  border: 1px solid var(--ocg-header-border);
  border-bottom-color: var(--ocg-header-divider);
  border-radius: var(--ocg-header-radius);
  background: var(--ocg-header-background);
  box-shadow: var(--ocg-header-shadow);
  color: var(--ocg-color-text);
  font-family: var(--ocg-font-body);
  line-height: 1.4;
}
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 1 1 360px;
  max-width: 100%;
  min-width: 0;
  color: var(--ocg-color-text);
  text-decoration: none;
}
.brand:hover {
  text-decoration: none;
}
.brand-mark {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  width: auto;
  min-width: 36px;
  max-width: min(40vw, 320px);
  height: 36px;
  padding: 0 8px;
  border-radius: var(--ocg-radius-md);
  background: var(--ocg-color-accent);
  color: var(--ocg-color-on-accent);
  font-family: var(--ocg-font-heading);
  font-size: var(--ocg-text-xs);
  font-weight: 600;
  letter-spacing: 0.04em;
  line-height: 1.1;
  overflow-wrap: anywhere;
  text-align: center;
}
.brand-mark--image {
  width: 36px;
  min-width: 36px;
  max-width: 36px;
  padding: 3px;
  border: 1px solid var(--ocg-color-border);
  background: var(--ocg-color-panel);
}
.brand-mark--image img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.brand-copy {
  display: grid;
  flex: 1 1 auto;
  gap: 1px;
  min-width: 0;
}
.brand-copy strong,
.brand-copy span {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
  word-break: break-word;
}
.brand-copy strong {
  color: var(--ocg-color-text);
  font-family: var(--ocg-font-heading);
  font-size: var(--ocg-text-base);
  font-weight: 600;
}
.brand-copy span {
  color: var(--ocg-color-text-secondary);
  font-family: var(--ocg-font-mono);
  font-size: var(--ocg-text-xs);
}
.site-nav {
  display: flex;
  flex: 0 1 auto;
  flex-wrap: wrap;
  justify-content: flex-end;
  align-items: center;
  gap: 2px;
  min-width: 0;
}
.site-nav .nav-link {
  display: inline-flex;
  align-items: center;
  padding: 6px 10px;
  border: 1px solid transparent;
  border-radius: var(--ocg-nav-radius);
  color: var(--ocg-nav-text);
  font-size: var(--ocg-text-md);
  font-weight: 500;
  line-height: 1.4;
  text-decoration: none;
  transition:
    background-color var(--ocg-duration-fast) var(--ocg-ease),
    color var(--ocg-duration-fast) var(--ocg-ease);
}
.site-nav .nav-link:hover {
  background: var(--ocg-nav-hover-background);
  color: var(--ocg-color-text);
  text-decoration: none;
}
.site-nav .nav-link.is-active {
  background: var(--ocg-nav-active-background);
  color: var(--ocg-nav-active-text);
}
.site-nav .nav-link--guide {
  position: relative;
  margin-left: 13px;
}
.site-nav .nav-link--guide::before {
  content: "";
  position: absolute;
  top: 50%;
  left: -8px;
  width: 1px;
  height: 16px;
  background: var(--ocg-color-border);
  transform: translateY(-50%);
}
.site-nav .nav-link--how-to {
  margin-left: 6px;
  border-color: var(--ocg-color-border);
  font-size: var(--ocg-text-sm);
}
@media (max-width: 860px) {
  .site-header {
    align-items: flex-start;
  }
  .site-nav {
    justify-content: flex-start;
    width: calc(100% + 10px);
    margin-left: -10px;
  }
}

/* Configured footer copy and the OCG attribution line. Also used by the ReSpec page. */
.site-footer,
.site-footer-generator {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
  margin-top: 40px;
  padding-top: 20px;
  border-top: 1px solid var(--ocg-color-border);
  color: var(--ocg-color-text-secondary);
  font-family: var(--ocg-font-body);
  font-size: var(--ocg-text-sm);
  line-height: 1.5;
}
.site-footer {
  justify-content: space-between;
}
.site-footer-generator {
  justify-content: center;
  width: 100%;
  text-align: center;
}
.site-footer + .site-footer-generator {
  margin-top: 12px;
  padding-top: 0;
  border-top: 0;
}
.site-footer-generator strong {
  color: var(--ocg-color-text);
  font-weight: 600;
}
.site-footer-generator a {
  color: var(--ocg-color-text-secondary);
  font-weight: 500;
  text-decoration: none;
}
.site-footer-generator a:hover {
  color: var(--ocg-color-text);
  text-decoration: underline;
}
.site-footer-separator {
  color: var(--ocg-color-border-strong);
}
.ocg-footer-repository {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.ocg-footer-icon {
  width: 16px;
  height: 16px;
  border-radius: 4px;
  object-fit: contain;
}

/* Panels: the section containers every page is built from, plus their headings. */
.section,
.hero-copy,
.hero-panel {
  border: 1px solid var(--ocg-panel-border);
  border-radius: var(--ocg-panel-radius);
  background: var(--ocg-panel-background);
  box-shadow: var(--ocg-panel-shadow);
}
.section {
  margin-bottom: 20px;
  padding: var(--ocg-panel-padding);
}
.section-head {
  display: grid;
  gap: 6px;
  margin-bottom: 20px;
}
.section-head:last-child {
  margin-bottom: 0;
}
.section-heading-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.section-heading-row h1,
.section-heading-row h2 {
  margin-bottom: 0;
}
.section-note {
  max-width: 78ch;
}
.eyebrow {
  color: var(--ocg-color-accent);
  font-size: var(--ocg-text-sm);
  font-weight: 600;
  letter-spacing: 0.01em;
  line-height: 1.4;
}

/* Cards: overview, example, featured-term, metric, and guide cards. Cards sit on a
   panel, so they are separated by a border rather than by elevation. */
.card,
.metric-card,
.guide-card {
  display: grid;
  align-content: start;
  gap: 8px;
  padding: var(--ocg-card-padding);
  border: 1px solid var(--ocg-card-border);
  border-radius: var(--ocg-card-radius);
  background: var(--ocg-card-background);
  box-shadow: var(--ocg-card-shadow);
}
.card h3,
.guide-card h3 {
  margin: 0;
  font-size: var(--ocg-text-base);
}
.card p,
.guide-card p {
  font-size: var(--ocg-text-md);
  line-height: 1.55;
}
.card-link {
  display: inline-flex;
  margin-top: 4px;
  color: var(--ocg-color-accent);
  font-size: var(--ocg-text-md);
  font-weight: 500;
}
.metric-card {
  gap: 2px;
}
.metric-number {
  color: var(--ocg-color-text);
  font-family: var(--ocg-font-heading);
  font-size: 1.5rem;
  font-variant-numeric: tabular-nums;
  font-weight: 600;
  line-height: 1.2;
}
.metric-label {
  color: var(--ocg-color-text-secondary);
  font-size: var(--ocg-text-sm);
  font-weight: 500;
}
.featured-terms-grid {
  align-items: stretch;
}
.featured-term-card {
  grid-template-rows: auto auto 1fr;
  min-width: 0;
  overflow: hidden;
}
.featured-term-card h3,
.featured-term-card p {
  margin: 0;
  min-width: 0;
  overflow-wrap: anywhere;
  word-break: break-word;
}
.featured-term-card h3 {
  font-family: var(--ocg-font-mono);
  font-size: var(--ocg-text-md);
  font-weight: 500;
  line-height: 1.35;
}
.featured-term-card h3 a {
  color: var(--ocg-color-text);
  overflow-wrap: anywhere;
  word-break: break-word;
}
.featured-term-card h3 a:hover,
.guide-card h3 a:hover {
  color: var(--ocg-color-accent);
  text-decoration: none;
}
.guide-card h3 a {
  color: var(--ocg-color-text);
}

/* Definition tiles for ontology metadata (home resource panel and term pages). */
.meta-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin: 0;
}
.meta-grid > div {
  min-width: 0;
  padding: 10px 12px;
  border: 1px solid var(--ocg-color-border-subtle);
  border-radius: var(--ocg-radius-md);
  background: var(--ocg-color-subtle-soft);
}
.meta-grid dt {
  margin-bottom: 2px;
  color: var(--ocg-color-text-secondary);
  font-size: var(--ocg-text-xs);
  font-weight: 500;
}
.meta-grid dd {
  margin: 0;
  color: var(--ocg-color-text);
  font-size: var(--ocg-text-md);
  overflow-wrap: anywhere;
}
.namespace-value {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.namespace-value code {
  min-width: 0;
  overflow-x: auto;
  font-size: var(--ocg-text-sm);
  white-space: nowrap;
}
@media (max-width: 860px) {
  .meta-grid {
    grid-template-columns: 1fr;
  }
}

/* Buttons. `.btn--primary` and `.btn--ghost` map to the primary and secondary button
   tokens; icon buttons and How To links reuse the secondary treatment. */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: var(--ocg-button-height);
  padding: 6px var(--ocg-button-padding-x);
  border: 1px solid transparent;
  border-radius: var(--ocg-button-radius);
  font-family: inherit;
  font-size: var(--ocg-button-font-size);
  font-weight: var(--ocg-button-font-weight);
  line-height: 1.25;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition:
    background-color var(--ocg-duration-fast) var(--ocg-ease),
    border-color var(--ocg-duration-fast) var(--ocg-ease),
    color var(--ocg-duration-fast) var(--ocg-ease);
}
.btn:hover {
  text-decoration: none;
}
.btn--primary {
  border-color: var(--ocg-button-primary-border);
  background: var(--ocg-button-primary-background);
  color: var(--ocg-button-primary-text);
}
.btn--primary:hover {
  border-color: var(--ocg-button-primary-hover-background);
  background: var(--ocg-button-primary-hover-background);
}
.btn--ghost {
  border-color: var(--ocg-button-secondary-border);
  background: var(--ocg-button-secondary-background);
  color: var(--ocg-button-secondary-text);
}
.btn--ghost:hover {
  background: var(--ocg-button-secondary-hover-background);
}
.btn--small {
  min-height: calc(var(--ocg-button-height) - 6px);
  padding: 4px max(8px, calc(var(--ocg-button-padding-x) - 4px));
  font-size: var(--ocg-text-sm);
}
.icon-button {
  display: inline-grid;
  flex: 0 0 auto;
  place-items: center;
  width: 28px;
  height: 28px;
  padding: 5px;
  border: 1px solid var(--ocg-button-secondary-border);
  border-radius: var(--ocg-button-radius);
  background: var(--ocg-button-secondary-background);
  color: var(--ocg-color-text-secondary);
  cursor: pointer;
  transition:
    background-color var(--ocg-duration-fast) var(--ocg-ease),
    border-color var(--ocg-duration-fast) var(--ocg-ease),
    color var(--ocg-duration-fast) var(--ocg-ease);
}
.icon-button:hover {
  background: var(--ocg-button-secondary-hover-background);
  color: var(--ocg-color-text);
}
.icon-button[data-copied="true"] {
  border-color: var(--ocg-color-accent-muted);
  background: var(--ocg-color-accent-subtle);
  color: var(--ocg-color-accent-strong);
}
.icon-button svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}
.how-to-link {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  min-height: 26px;
  padding: 2px 9px;
  border: 1px solid var(--ocg-color-border);
  border-radius: var(--ocg-button-radius);
  color: var(--ocg-color-text-secondary);
  font-size: var(--ocg-text-xs);
  font-weight: 500;
  line-height: 1.3;
  white-space: nowrap;
  transition:
    background-color var(--ocg-duration-fast) var(--ocg-ease),
    border-color var(--ocg-duration-fast) var(--ocg-ease),
    color var(--ocg-duration-fast) var(--ocg-ease);
}
.how-to-link:hover {
  border-color: var(--ocg-color-border-strong);
  background: var(--ocg-color-overlay-hover);
  color: var(--ocg-color-text);
  text-decoration: none;
}

/* Badges label term types and guide sections. Page files reuse the badge tokens for
   counts, severities, and graph selection types. */
.term-badge {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  min-height: 22px;
  padding: 2px 8px;
  border: 1px solid var(--ocg-badge-border);
  border-radius: var(--ocg-badge-radius);
  background: var(--ocg-badge-background);
  color: var(--ocg-badge-text);
  font-size: var(--ocg-text-xs);
  font-weight: 500;
  line-height: 1.3;
  white-space: nowrap;
}

/* Segmented tabs: the artifact viewer, graph representation, and graph mode tabs. */
.tabs,
.graph-view-tabs,
.graph-mode-tabs {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 2px;
  max-width: 100%;
  margin-bottom: 16px;
  padding: 3px;
  border: 1px solid var(--ocg-tabs-border);
  border-radius: var(--ocg-tabs-radius);
  background: var(--ocg-tabs-background);
}
.tab,
.graph-view-tab,
.graph-mode-tab {
  appearance: none;
  padding: 5px 12px;
  border: 0;
  border-radius: max(0px, calc(var(--ocg-tabs-radius) - 3px));
  background: transparent;
  color: var(--ocg-tabs-text);
  font: inherit;
  font-size: var(--ocg-text-md);
  font-weight: 500;
  line-height: 1.4;
  cursor: pointer;
  transition:
    background-color var(--ocg-duration-fast) var(--ocg-ease),
    box-shadow var(--ocg-duration-fast) var(--ocg-ease),
    color var(--ocg-duration-fast) var(--ocg-ease);
}
.tab:hover,
.graph-view-tab:hover,
.graph-mode-tab:hover {
  color: var(--ocg-color-text);
}
.tab.active,
.graph-view-tab.active,
.graph-mode-tab.active {
  background: var(--ocg-tabs-active-background);
  color: var(--ocg-tabs-active-text);
  box-shadow:
    0 0 0 1px var(--ocg-color-border-subtle),
    var(--ocg-shadow-sm);
}
@media (max-width: 640px) {
  .tabs,
  .graph-view-tabs,
  .graph-mode-tabs {
    display: flex;
    width: 100%;
  }
  .tab,
  .graph-view-tab,
  .graph-mode-tab {
    flex: 1 1 auto;
    text-align: center;
  }
}

/* Data tables (reference, terms, relationships) and the guide option tables. */
.table-wrap,
.guide-options-wrap {
  overflow-x: auto;
  border: 1px solid var(--ocg-table-border);
  border-radius: var(--ocg-table-radius);
  background: var(--ocg-color-panel);
}
.table-wrap {
  margin-top: 12px;
}
table {
  width: 100%;
  min-width: 760px;
  border-collapse: collapse;
  font-size: var(--ocg-text-md);
}
th,
td {
  padding: 10px 14px;
  border-bottom: 1px solid var(--ocg-color-border-subtle);
  line-height: 1.45;
  text-align: left;
  vertical-align: top;
}
th {
  background: var(--ocg-table-header-background);
  color: var(--ocg-table-header-text);
  font-size: var(--ocg-text-sm);
  font-weight: 500;
}
thead th {
  border-bottom-color: var(--ocg-table-border);
}
td {
  color: var(--ocg-color-text);
}
tbody tr:nth-child(even) td {
  background: var(--ocg-table-stripe-background);
}
tbody tr:hover td {
  background: var(--ocg-table-hover-background);
}
tbody tr:last-child th,
tbody tr:last-child td {
  border-bottom: 0;
}
.guide-options {
  min-width: 680px;
}
.guide-options thead th {
  font-size: var(--ocg-text-xs);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.guide-options tbody th {
  width: 38%;
  background: transparent;
  color: var(--ocg-color-text);
  font-weight: 500;
}
.guide-options tbody td {
  color: var(--ocg-color-text-secondary);
  line-height: 1.5;
}

/* Code blocks (artifact viewer and guide examples) and inline IRI examples. */
.viewer-pane,
.guide-code {
  margin: 0;
  padding: 14px 16px;
  border: 1px solid var(--ocg-code-border);
  border-radius: var(--ocg-code-radius);
  background: var(--ocg-code-background);
  color: var(--ocg-code-text);
  font-size: var(--ocg-text-sm);
  line-height: 1.6;
  overflow: auto;
  tab-size: 2;
}
.viewer-pane {
  min-height: 340px;
  max-height: min(640px, 75vh);
  white-space: pre-wrap;
  word-break: break-word;
}
.iri-example {
  display: inline-block;
  max-width: 100%;
  padding: 1px 6px;
  border: 1px solid var(--ocg-color-accent-muted);
  border-radius: var(--ocg-radius-sm);
  background: var(--ocg-color-accent-subtle);
  color: var(--ocg-color-accent-strong);
  font-weight: 500;
  overflow-wrap: anywhere;
  vertical-align: baseline;
}

/* Callouts: guide notes and instructions, plus the graph, hierarchy, and pitfall
   notices that share the same treatment. */
.guide-callout,
.graph-view-note,
.hierarchy-empty,
.pitfall-unavailable {
  padding: 12px 16px;
  border: 1px solid var(--ocg-callout-border);
  border-radius: var(--ocg-callout-radius);
  background: var(--ocg-callout-background);
  color: var(--ocg-callout-text);
  font-size: var(--ocg-text-md);
  line-height: 1.55;
}
.guide-callout strong,
.graph-view-note strong,
.pitfall-unavailable strong {
  color: var(--ocg-color-text);
}
.guide-callout a {
  color: var(--ocg-color-accent-strong);
  font-weight: 500;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
}
.guide-callout--instruction {
  border-color: var(--ocg-color-accent-muted);
  background: var(--ocg-color-accent-subtle);
}
.graph-view-note {
  margin-bottom: 14px;
}
.hierarchy-empty {
  border-style: dashed;
  border-color: var(--ocg-color-border-strong);
  background: transparent;
}
.pitfall-unavailable {
  margin-top: 12px;
  border-color: color-mix(in srgb, var(--ocg-color-warning) 35%, var(--ocg-color-panel));
  background: color-mix(in srgb, var(--ocg-color-warning) 6%, var(--ocg-color-panel));
}

/* Form controls used by the graph sidebar. */
input[type="checkbox"],
input[type="radio"] {
  accent-color: var(--ocg-color-accent);
}
.sigma-search {
  width: 100%;
  min-height: 34px;
  padding: 6px 10px;
  border: 1px solid var(--ocg-input-border);
  border-radius: var(--ocg-input-radius);
  background: var(--ocg-input-background);
  color: var(--ocg-input-text);
  font: inherit;
  font-size: var(--ocg-text-md);
  transition:
    border-color var(--ocg-duration-fast) var(--ocg-ease),
    box-shadow var(--ocg-duration-fast) var(--ocg-ease);
}
.sigma-search::placeholder {
  color: var(--ocg-color-text-secondary);
  opacity: 0.8;
}
.sigma-search:focus {
  border-color: var(--ocg-input-focus-border);
  outline: none;
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--ocg-input-focus-border) 18%, transparent);
}

/* Table of contents: the collapsible rail every page with sections shares. */
.page-toc {
  position: sticky;
  top: 20px;
  align-self: start;
  width: 100%;
  overflow: hidden;
  transition: width 0.2s ease;
}
.page-toc-panel {
  --ocg-page-toc-panel-width: 214px;
  width: var(--ocg-page-toc-panel-width);
  min-width: var(--ocg-page-toc-panel-width);
  height: auto;
  overflow: hidden;
  border: 1px solid var(--ocg-panel-border);
  border-radius: var(--ocg-panel-radius);
  background: var(--ocg-panel-background);
  transition: width var(--ocg-toc-motion) var(--ocg-toc-ease);
}
.page-toc-head {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  padding: 10px 46px 10px 14px;
  color: var(--ocg-color-text);
  font-size: var(--ocg-text-sm);
  font-weight: 600;
}
.page-toc-title {
  min-width: 0;
  overflow-wrap: anywhere;
  opacity: 1;
  transform: translateX(0);
  transition: opacity 0.18s ease-out, transform var(--ocg-toc-motion) var(--ocg-toc-ease);
}
.page-toc-toggle {
  position: absolute;
  top: 8px;
  right: 8px;
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  padding: 4px;
  border: 1px solid transparent;
  border-radius: var(--ocg-radius-md);
  background: transparent;
  color: var(--ocg-color-text-secondary);
  cursor: pointer;
  transition:
    background-color var(--ocg-duration-fast) var(--ocg-ease),
    color var(--ocg-duration-fast) var(--ocg-ease);
}
.page-toc-toggle:hover,
.page-toc-toggle:focus-visible {
  background: var(--ocg-color-overlay-hover);
  color: var(--ocg-color-text);
}
.page-toc-toggle:focus-visible {
  outline-offset: -2px;
}
.page-toc-toggle-icon {
  display: block;
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2;
  transition: transform var(--ocg-toc-motion) var(--ocg-toc-ease);
}
.page-toc nav {
  padding: 6px;
  border-top: 1px solid var(--ocg-color-border-subtle);
  max-height: calc(100vh - 7rem);
  overflow-y: auto;
  overscroll-behavior: contain;
  opacity: 1;
  transition: opacity 0.18s ease-out;
}
.page-toc.is-collapsed {
  width: 44px;
}
.page-toc.is-collapsed .page-toc-panel {
  width: 44px;
  min-width: 44px;
  height: 44px;
  max-height: 44px;
  border-radius: var(--ocg-radius-lg);
}
/* Fill the panel's content box rather than its border box: a hard 44px here
   overhangs the 1px border and pushes the centred toggle off by 2px. */
.page-toc.is-collapsed .page-toc-head {
  width: 100%;
  height: 100%;
  min-height: 0;
  padding: 0;
}
.page-toc.is-collapsed .page-toc-title,
.page-toc.is-collapsed nav {
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
}
/* Collapsed, the panel is a square and the toggle is all that shows, so centre it
   instead of leaving it pinned to the expanded panel's right edge. */
.page-toc.is-collapsed .page-toc-toggle {
  top: 50%;
  right: 50%;
  transform: translate(50%, -50%);
}
.page-toc.is-collapsed .page-toc-toggle-icon {
  transform: rotate(180deg);
}
.page-toc ol {
  display: grid;
  gap: 1px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.page-toc a {
  display: block;
  padding: 6px 8px;
  border-radius: var(--ocg-radius-md);
  color: var(--ocg-color-text-secondary);
  font-size: var(--ocg-text-sm);
  font-weight: 500;
  line-height: 1.35;
  overflow-wrap: anywhere;
  transition:
    background-color var(--ocg-duration-fast) var(--ocg-ease),
    color var(--ocg-duration-fast) var(--ocg-ease);
}
.page-toc a:hover,
.page-toc a:focus-visible {
  background: var(--ocg-color-overlay-hover);
  color: var(--ocg-color-text);
  text-decoration: none;
}
.page-toc-item--level-1 a {
  padding-left: 20px;
  font-weight: 400;
}
}

@layer ocg.pages {
/* Home page: hero, resource panel, snapshot metrics, and overview cards. */
.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(280px, 0.9fr);
  gap: 16px;
  margin-bottom: 20px;
}
.hero-copy {
  padding: 32px;
}
.hero-copy .eyebrow {
  margin-bottom: 12px;
}
.hero-copy h1 {
  margin-bottom: 12px;
  font-size: var(--ocg-text-3xl);
  line-height: 1.1;
  letter-spacing: -0.025em;
}
.hero-copy > p {
  max-width: 62ch;
  font-size: 1rem;
}
.hero-panel {
  display: grid;
  align-content: start;
  gap: 12px;
  padding: 20px;
}
.hero-panel h2 {
  font-size: var(--ocg-text-lg);
}
.hero-panel > p {
  font-size: var(--ocg-text-md);
  line-height: 1.5;
}
.hero-actions {
  display: grid;
  gap: 12px;
  margin-top: 24px;
}
.hero-action-group {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.hero-action-group--artifacts {
  display: grid;
  grid-template-columns: repeat(var(--artifact-count, 1), minmax(0, 1fr));
  padding-top: 12px;
  border-top: 1px solid var(--ocg-color-border-subtle);
}
.hero-action-group--artifacts .btn {
  width: 100%;
}
.meta-item--namespace,
.meta-item--canonical {
  grid-column: 1 / -1;
}
.page-home .metrics-grid {
  grid-template-columns: repeat(var(--metric-count, 1), minmax(0, 1fr));
}
.page-home .section--overview .section-note {
  max-width: none;
}
.page-home .section--overview .card {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  min-width: 0;
}
.page-home .section--overview .card h3,
.page-home .section--overview .card p,
.page-home .section--overview .card-link {
  min-width: 0;
  overflow-wrap: anywhere;
  word-break: break-word;
}
.page-home .section--overview .card-link {
  margin-top: auto;
  padding-top: 8px;
}
.viewer-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}
.viewer-head strong {
  font-size: var(--ocg-text-base);
}
.viewer-note {
  margin-top: 2px;
  color: var(--ocg-color-text-secondary);
  font-size: var(--ocg-text-sm);
}
@media (max-width: 860px) {
  .hero {
    grid-template-columns: 1fr;
  }
  .hero-copy {
    padding: 24px;
  }
  .hero-action-group--artifacts {
    grid-template-columns: 1fr;
  }
  .page-home .metrics-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Reference page: the ontology structure overview. */
.hierarchy-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: -8px 0 16px;
  color: var(--ocg-color-text-secondary);
  font-size: var(--ocg-text-sm);
  font-weight: 500;
}
.hierarchy-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(260px, 0.8fr);
  align-items: start;
  gap: 16px;
}
.hierarchy-tree,
.hierarchy-links {
  padding: 12px;
  border: 1px solid var(--ocg-color-border-subtle);
  border-radius: var(--ocg-radius-lg);
  background: var(--ocg-color-panel);
}
.hierarchy-tree ul {
  display: grid;
  gap: 1px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.hierarchy-item {
  min-width: 0;
}
.hierarchy-item details > ul {
  margin: 1px 0 4px 11px;
  padding-left: 10px;
  border-left: 1px solid var(--ocg-color-border);
}
.hierarchy-item summary,
.hierarchy-item--leaf {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 32px;
  padding: 4px 8px;
  border-radius: var(--ocg-radius-md);
  color: var(--ocg-color-text);
  list-style: none;
  transition: background-color var(--ocg-duration-fast) var(--ocg-ease);
}
.hierarchy-item summary {
  cursor: pointer;
}
.hierarchy-item summary::-webkit-details-marker {
  display: none;
}
.hierarchy-item summary::before {
  content: "";
  flex: 0 0 auto;
  width: 6px;
  height: 6px;
  margin: 0 3px 0 2px;
  border: solid var(--ocg-color-text-secondary);
  border-width: 0 1.5px 1.5px 0;
  transform: rotate(-45deg);
  transition: transform var(--ocg-duration-fast) var(--ocg-ease);
}
.hierarchy-item details[open] > summary::before {
  transform: rotate(45deg);
}
.hierarchy-item--leaf::before {
  content: "";
  flex: 0 0 auto;
  width: 4px;
  height: 4px;
  margin: 0 4px 0 3px;
  border-radius: 50%;
  background: var(--ocg-color-border-strong);
}
.hierarchy-item summary:hover,
.hierarchy-item--leaf:hover {
  background: var(--ocg-color-overlay-hover);
}
.hierarchy-item summary .hierarchy-term,
.hierarchy-item--leaf .hierarchy-term {
  flex: 1 1 auto;
  min-width: 0;
}
.hierarchy-term {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 6px;
  color: var(--ocg-color-text);
  font-size: var(--ocg-text-md);
  overflow-wrap: anywhere;
}
.hierarchy-term:hover {
  color: var(--ocg-color-accent);
  text-decoration: none;
}
.hierarchy-term code {
  color: var(--ocg-color-text-secondary);
  font-size: var(--ocg-text-xs);
}
.hierarchy-child-count {
  display: inline-grid;
  flex: 0 0 auto;
  place-items: center;
  min-width: 20px;
  height: 18px;
  padding: 0 6px;
  border-radius: var(--ocg-badge-radius);
  background: var(--ocg-color-subtle);
  color: var(--ocg-color-text-secondary);
  font-size: 0.6875rem;
  font-variant-numeric: tabular-nums;
  font-weight: 500;
}
.hierarchy-links h3 {
  margin: 0 0 10px;
  font-size: var(--ocg-text-base);
}
.hierarchy-links ul {
  display: grid;
  gap: 8px;
  margin: 0;
  padding-left: 16px;
  color: var(--ocg-color-text-secondary);
  font-size: var(--ocg-text-md);
}
.hierarchy-links li {
  line-height: 1.5;
}
.hierarchy-links .hierarchy-term {
  display: inline;
}
.hierarchy-relation {
  display: inline-block;
  margin: 0 3px;
  color: var(--ocg-color-accent-strong);
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
@media (max-width: 860px) {
  .hierarchy-grid {
    grid-template-columns: 1fr;
  }
}

/* Graph page: Sigma ontology network, WebVOWL embed, and the full-screen view.
   The graph script requests native full screen and falls back to the
   .graph-panel--expanded class, so each full-screen rule targets both states. */
.graph-view-panel[hidden] {
  display: none;
}
.sigma-layout {
  display: grid;
  grid-template-columns: minmax(292px, 320px) minmax(0, 1fr);
  align-items: stretch;
  gap: 16px;
}
.sigma-panel {
  position: relative;
  display: grid;
  grid-auto-rows: max-content;
  align-content: start;
  gap: 8px;
  min-width: 0;
  min-height: calc(80vh - 100px);
  max-height: calc(150vh - 200px);
  overflow: auto;
  scrollbar-color: var(--ocg-color-border-strong) transparent;
  scrollbar-width: thin;
}
.sigma-panel::-webkit-scrollbar {
  width: 7px;
}
.sigma-panel::-webkit-scrollbar-track {
  background: transparent;
}
.sigma-panel::-webkit-scrollbar-thumb {
  border: 2px solid transparent;
  border-radius: 999px;
  background: var(--ocg-color-border-strong);
  background-clip: padding-box;
}
.sigma-card {
  min-width: 0;
}
.sigma-block {
  min-width: 0;
  border: 1px solid var(--ocg-color-border);
  border-radius: var(--ocg-radius-lg);
  background: var(--ocg-color-panel);
  overflow: visible;
}
.sigma-block-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  min-height: 38px;
  padding: 8px 12px;
  border-radius: calc(var(--ocg-radius-lg) - 1px);
  color: var(--ocg-color-text);
  font-family: var(--ocg-font-heading);
  font-size: var(--ocg-text-md);
  font-weight: 600;
  line-height: 1.2;
  list-style: none;
  text-align: left;
  cursor: pointer;
  transition: background-color var(--ocg-duration-fast) var(--ocg-ease);
}
.sigma-block-toggle::-webkit-details-marker {
  display: none;
}
.sigma-block-toggle::marker {
  content: "";
}
.sigma-block-toggle:hover {
  background: var(--ocg-color-subtle-soft);
}
.sigma-block[open] .sigma-block-toggle {
  border-bottom: 1px solid var(--ocg-color-border-subtle);
  border-radius: calc(var(--ocg-radius-lg) - 1px) calc(var(--ocg-radius-lg) - 1px) 0 0;
}
.sigma-chevron {
  color: var(--ocg-color-text-secondary);
  font-size: var(--ocg-text-md);
  transform: rotate(-90deg);
  transition: transform var(--ocg-duration-fast) var(--ocg-ease);
}
.sigma-block[open] .sigma-chevron {
  transform: rotate(0deg);
}
.sigma-block-body {
  display: grid;
  gap: 8px;
  min-width: 0;
  padding: 10px 12px 12px;
}
.sigma-muted,
.sigma-status,
.sigma-graph-hint {
  margin: 0;
  color: var(--ocg-color-text-secondary);
  font-size: var(--ocg-text-sm);
  line-height: 1.45;
}
.sigma-control-group {
  display: grid;
  gap: 6px;
}
.sigma-control-group label,
.sigma-block-body > label {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--ocg-color-text);
  font-size: var(--ocg-text-sm);
}
.sigma-filter-title {
  margin: 4px 0 0;
  color: var(--ocg-color-text-secondary);
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
.sigma-search-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
}
.sigma-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 32px;
  padding: 6px 10px;
  border: 1px solid var(--ocg-button-secondary-border);
  border-radius: var(--ocg-button-radius);
  background: var(--ocg-button-secondary-background);
  color: var(--ocg-button-secondary-text);
  font-family: inherit;
  font-size: var(--ocg-text-sm);
  font-weight: var(--ocg-button-font-weight);
  line-height: 1.25;
  cursor: pointer;
  transition:
    background-color var(--ocg-duration-fast) var(--ocg-ease),
    border-color var(--ocg-duration-fast) var(--ocg-ease);
}
.sigma-btn:hover {
  background: var(--ocg-button-secondary-hover-background);
}
.sigma-btn--reset {
  grid-column: 1 / -1;
  border-color: var(--ocg-button-primary-border);
  background: var(--ocg-button-primary-background);
  color: var(--ocg-button-primary-text);
}
.sigma-btn--reset:hover {
  border-color: var(--ocg-button-primary-hover-background);
  background: var(--ocg-button-primary-hover-background);
}
.sigma-detail,
.sigma-overview {
  display: grid;
  gap: 8px;
  min-width: 0;
  color: var(--ocg-color-text);
  font-size: var(--ocg-text-sm);
  line-height: 1.4;
}
.sigma-detail,
.sigma-detail * {
  min-width: 0;
}
.sigma-detail-heading {
  display: grid;
  gap: 5px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--ocg-color-border-subtle);
}
.sigma-detail-heading strong {
  color: var(--ocg-color-text);
  font-family: var(--ocg-font-mono);
  font-size: var(--ocg-text-md);
  font-weight: 500;
  overflow-wrap: anywhere;
}
.sigma-detail-type {
  width: fit-content;
  padding: 1px 6px;
  border: 1px solid var(--ocg-badge-border);
  border-radius: var(--ocg-badge-radius);
  background: var(--ocg-badge-background);
  color: var(--ocg-badge-text);
  font-size: 0.6875rem;
  font-weight: 500;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}
.sigma-detail-label {
  color: var(--ocg-color-text);
  font-weight: 500;
  overflow-wrap: anywhere;
}
.sigma-detail-description {
  margin: 0;
  color: var(--ocg-color-text-secondary);
  font-size: var(--ocg-text-sm);
  overflow-wrap: anywhere;
}
.sigma-detail-group {
  display: grid;
  gap: 5px;
}
.sigma-detail-group-title {
  display: flex;
  justify-content: space-between;
  color: var(--ocg-color-text-secondary);
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.sigma-detail-group ul {
  display: grid;
  gap: 4px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.sigma-detail-group li {
  display: grid;
  gap: 2px;
  padding: 6px 8px;
  border-radius: var(--ocg-radius-md);
  background: var(--ocg-color-subtle-soft);
  overflow-wrap: anywhere;
}
.sigma-relation-kind {
  color: var(--ocg-color-text-secondary);
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}
.sigma-detail-empty {
  color: var(--ocg-color-text-secondary);
  font-style: italic;
}
.sigma-detail-metadata {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  gap: 6px 10px;
  margin: 0;
}
.sigma-detail-metadata dt {
  color: var(--ocg-color-text-secondary);
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}
.sigma-detail-metadata dd {
  margin: 0;
  overflow-wrap: anywhere;
}
.sigma-detail code,
.sigma-overview code {
  padding: 1px 5px;
  border-radius: var(--ocg-radius-sm);
  background: var(--ocg-color-accent-subtle);
  color: var(--ocg-color-accent-strong);
  font-family: var(--ocg-font-mono);
  word-break: break-word;
}
.sigma-stats {
  display: grid;
  gap: 6px;
  color: var(--ocg-color-text);
  font-size: var(--ocg-text-sm);
}
.sigma-graph-top {
  display: grid;
  gap: 8px;
  margin-bottom: 8px;
}
.sigma-legend {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 14px;
  padding: 8px 12px;
  border: 1px solid var(--ocg-color-border-subtle);
  border-radius: var(--ocg-radius-md);
  background: var(--ocg-color-subtle-soft);
}
.sigma-legend-title {
  margin-right: 2px;
  color: var(--ocg-color-text);
  font-family: var(--ocg-font-heading);
  font-size: var(--ocg-text-sm);
  font-weight: 600;
}
.sigma-legend-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--ocg-color-text-secondary);
  font-size: var(--ocg-text-sm);
  white-space: nowrap;
}
.sigma-swatch {
  flex: 0 0 auto;
  width: 10px;
  height: 10px;
  border: 1px solid color-mix(in srgb, var(--ocg-color-text) 18%, transparent);
  border-radius: 3px;
}
.sigma-line {
  display: inline-block;
  flex: 0 0 auto;
  width: 28px;
  height: 10px;
  color: var(--line-color, currentColor);
}
.sigma-line svg {
  display: block;
  width: 100%;
  height: 100%;
}
#sigma-graph-container {
  position: relative;
  width: 100%;
  min-height: 670px;
  height: calc(100vh - 190px);
  overflow: hidden;
  border: 1px solid var(--ocg-color-border);
  border-radius: var(--ocg-radius-lg);
  background: var(--ocg-color-graph-surface);
}
.sigma-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.sigma-controls-toggle,
.graph-expand-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 32px;
  padding: 6px 10px;
  border: 1px solid var(--ocg-color-border);
  border-radius: var(--ocg-button-radius);
  background: var(--ocg-color-panel);
  color: var(--ocg-color-text-secondary);
  box-shadow: var(--ocg-shadow-sm);
  font: inherit;
  font-size: var(--ocg-text-sm);
  font-weight: 500;
  white-space: nowrap;
  cursor: pointer;
  transition:
    background-color var(--ocg-duration-fast) var(--ocg-ease),
    border-color var(--ocg-duration-fast) var(--ocg-ease),
    color var(--ocg-duration-fast) var(--ocg-ease);
}
.sigma-controls-toggle:hover,
.graph-expand-btn:hover {
  border-color: var(--ocg-color-border-strong);
  background: var(--ocg-color-subtle-soft);
  color: var(--ocg-color-text);
}
.sigma-controls-toggle {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 25;
}
.sigma-controls-toggle svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-width: 1.7;
}
.graph-expand-btn--icon {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 25;
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  min-height: 0;
  padding: 6px;
}
.graph-expand-btn--icon svg {
  display: block;
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}
.graph-expand-btn--icon svg[hidden] {
  display: none;
}
.graph-expand-help {
  position: absolute;
  top: 50px;
  right: 10px;
  z-index: 24;
  padding: 4px 8px;
  border: 1px solid var(--ocg-color-border);
  border-radius: var(--ocg-radius-md);
  background: var(--ocg-color-panel);
  color: var(--ocg-color-text-secondary);
  box-shadow: var(--ocg-shadow-sm);
  font-size: var(--ocg-text-xs);
  line-height: 1.3;
  white-space: nowrap;
  pointer-events: none;
}
.graph-expand-help[hidden] {
  display: none;
}
.sigma-tooltip {
  position: absolute;
  z-index: 20;
  display: none;
  max-width: 320px;
  padding: 6px 9px;
  border-radius: var(--ocg-radius-md);
  background: var(--ocg-color-tooltip-background);
  color: var(--ocg-color-tooltip-text);
  box-shadow: var(--ocg-shadow-lg);
  font-size: var(--ocg-text-xs);
  line-height: 1.35;
  pointer-events: none;
}
.sigma-node-tooltip {
  max-width: 290px;
}
.sigma-tooltip.visible {
  display: block;
}
.webvowl-graph-surface {
  position: relative;
  width: 100%;
}
.webvowl-frame {
  display: block;
  width: 100%;
  min-height: 320px;
  border: 1px solid var(--ocg-color-border);
  border-radius: var(--ocg-radius-lg);
  background: var(--ocg-color-panel);
}
body.graph-fullscreen-active {
  overflow: hidden;
}
.sigma-graph-panel.graph-controls-collapsed .sigma-layout {
  grid-template-columns: minmax(0, 1fr);
}
.sigma-graph-panel.graph-controls-collapsed .sigma-panel {
  display: none;
}
.graph-view-panel:is(.graph-panel--expanded, :fullscreen) {
  position: fixed;
  inset: 0;
  z-index: 1000;
  width: 100vw;
  height: 100vh;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 16px 20px 20px;
  overflow: auto;
  border: 0;
  border-radius: 0;
  background: var(--ocg-color-panel);
}
.sigma-graph-panel:is(.graph-panel--expanded, :fullscreen) {
  padding: 0;
  overflow: hidden;
  background: var(--ocg-color-graph-surface);
}
.sigma-graph-panel:is(.graph-panel--expanded, :fullscreen) .sigma-layout {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  min-height: 0;
}
.sigma-graph-panel:is(.graph-panel--expanded, :fullscreen) .sigma-card {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  min-height: 0;
}
.sigma-graph-panel:is(.graph-panel--expanded, :fullscreen) #sigma-graph-container {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  min-height: 0;
  border: 0;
  border-radius: 0;
}
.sigma-graph-panel:is(.graph-panel--expanded, :fullscreen) .sigma-panel {
  position: absolute;
  top: 56px;
  bottom: 14px;
  left: 14px;
  z-index: 45;
  display: grid;
  width: min(330px, calc(100vw - 28px));
  height: auto;
  min-height: 0;
  max-height: none;
  padding: 8px;
  gap: 6px;
  border: 1px solid var(--ocg-color-border);
  border-radius: var(--ocg-radius-xl);
  background: var(--ocg-color-subtle-soft);
  box-shadow: var(--ocg-shadow-lg);
  transition: transform 180ms ease, opacity 180ms ease;
}
.sigma-graph-panel:is(.graph-panel--expanded, :fullscreen).graph-controls-collapsed .sigma-panel {
  display: grid;
  opacity: 0;
  transform: translateX(calc(-100% - 24px));
  pointer-events: none;
}
.sigma-graph-panel:is(.graph-panel--expanded, :fullscreen) .sigma-graph-top {
  position: absolute;
  top: 10px;
  right: 56px;
  left: 156px;
  z-index: 22;
  margin: 0;
  pointer-events: none;
}
.sigma-graph-panel:is(.graph-panel--expanded, :fullscreen) .sigma-legend {
  width: fit-content;
  max-width: 100%;
  margin: 0 auto;
  padding: 6px 10px;
  gap: 5px 10px;
  border-color: var(--ocg-color-border);
  background: var(--ocg-color-panel);
  box-shadow: var(--ocg-shadow-md);
  pointer-events: auto;
}
.sigma-graph-panel:is(.graph-panel--expanded, :fullscreen) .sigma-graph-hint {
  display: none;
}
.sigma-graph-panel:is(.graph-panel--expanded, :fullscreen) .graph-mode-tabs {
  position: absolute;
  bottom: 12px;
  left: 50%;
  z-index: 50;
  width: max-content;
  max-width: calc(100% - 24px);
  margin: 0;
  border-color: var(--ocg-color-border);
  box-shadow: var(--ocg-shadow-md);
  transform: translateX(-50%);
}
.sigma-graph-panel:is(.graph-panel--expanded, :fullscreen) .sigma-block-toggle {
  min-height: 36px;
  padding: 8px 10px;
  font-size: var(--ocg-text-sm);
}
.sigma-graph-panel:is(.graph-panel--expanded, :fullscreen) .sigma-block-body {
  gap: 6px;
  padding: 8px 10px 10px;
}
.sigma-graph-panel:is(.graph-panel--expanded, :fullscreen) .sigma-btn {
  min-height: 30px;
  padding: 5px 9px;
  font-size: var(--ocg-text-xs);
}
.graph-view-panel:is(.graph-panel--expanded, :fullscreen) .webvowl-graph-surface {
  height: calc(100vh - 142px);
}
.graph-view-panel:is(.graph-panel--expanded, :fullscreen) .webvowl-frame {
  height: 100% !important;
  min-height: 0;
}
@media (max-width: 1100px) {
  .sigma-layout {
    grid-template-columns: 1fr;
  }
  .sigma-panel {
    min-height: 0;
    max-height: none;
  }
  #sigma-graph-container {
    min-height: 520px;
    height: 70vh;
  }
}
@media (max-width: 640px) {
  .graph-view-panel:is(.graph-panel--expanded, :fullscreen) {
    padding: 12px;
  }
  .sigma-graph-panel:is(.graph-panel--expanded, :fullscreen) {
    padding: 0;
  }
  .sigma-graph-panel:is(.graph-panel--expanded, :fullscreen) .sigma-graph-top,
  .sigma-graph-panel:is(.graph-panel--expanded, :fullscreen) .sigma-controls-toggle span {
    display: none;
  }
}

/* Usage guide: hero, component cards, and long-form sections. */
.guide-hero {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
  padding: 28px;
}
.guide-hero h1 {
  max-width: 780px;
  margin-bottom: 12px;
  font-size: clamp(1.75rem, 1.2rem + 1.8vw, 2.25rem);
  line-height: 1.15;
}
.guide-hero > p {
  max-width: 70ch;
  margin: 0;
}
.guide-quick-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}
.guide-section > * + * {
  margin-top: 16px;
}
.guide-section > h3 {
  margin-top: 28px;
  margin-bottom: 0;
}
.guide-section > h3 + * {
  margin-top: 10px;
}
.guide-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 12px;
}
.guide-card .term-badge {
  margin-bottom: 2px;
}
.guide-component {
  scroll-margin-top: 28px;
}
.guide-component .section-head {
  align-items: end;
}
.guide-component .section-head > div {
  min-width: 0;
}
.guide-component .section-head .term-badge {
  margin-bottom: 8px;
}
.guide-example-note {
  color: var(--ocg-color-text-secondary);
  font-size: var(--ocg-text-md);
}
.guide-steps {
  display: grid;
  gap: 10px;
  margin: 0;
  padding-left: 22px;
  color: var(--ocg-color-text-secondary);
  line-height: 1.6;
}
.guide-steps::marker,
.guide-steps li::marker {
  color: var(--ocg-color-text-secondary);
  font-weight: 500;
}
.guide-steps strong {
  color: var(--ocg-color-text);
}
.persistent-iri-section .section-head .section-note {
  max-width: none;
}
.persistent-iri-section > .guide-steps {
  gap: 16px;
  margin: 24px 0;
}
.persistent-iri-section > .guide-callout {
  margin: 24px 0;
}
.persistent-iri-section > .guide-code {
  margin-bottom: 24px;
}
@media (max-width: 860px) {
  .guide-hero {
    padding: 20px;
  }
}

/* OOPS! pitfall report: severity metrics and pitfall cards. */
.pitfall-metric--critical .metric-number {
  color: var(--ocg-color-danger);
}
.pitfall-metric--important .metric-number {
  color: var(--ocg-color-warning);
}
.pitfall-metric--minor .metric-number {
  color: var(--ocg-color-accent-strong);
}
.pitfall-grid {
  align-items: start;
}
.pitfall-card {
  border-left: 3px solid var(--ocg-color-border-strong);
}
.pitfall-card--critical {
  border-left-color: var(--ocg-color-danger);
}
.pitfall-card--important {
  border-left-color: var(--ocg-color-warning);
}
.pitfall-card--minor {
  border-left-color: var(--ocg-color-accent);
}
.pitfall-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.pitfall-code {
  color: var(--ocg-color-text-secondary);
  font-size: var(--ocg-text-sm);
  font-weight: 500;
}
.pitfall-importance {
  padding: 1px 8px;
  border: 1px solid var(--ocg-badge-border);
  border-radius: var(--ocg-badge-radius);
  background: var(--ocg-badge-background);
  color: var(--ocg-badge-text);
  font-size: var(--ocg-text-xs);
  font-weight: 500;
}
.pitfall-card--critical .pitfall-importance {
  background: color-mix(in srgb, var(--ocg-color-danger) 9%, var(--ocg-color-panel));
  color: var(--ocg-color-danger);
}
.pitfall-card--important .pitfall-importance {
  background: color-mix(in srgb, var(--ocg-color-warning) 9%, var(--ocg-color-panel));
  color: var(--ocg-color-warning);
}
.pitfall-elements summary {
  color: var(--ocg-color-text-secondary);
  font-size: var(--ocg-text-md);
  font-weight: 500;
  cursor: pointer;
}
.pitfall-elements ul {
  display: grid;
  gap: 6px;
  margin: 10px 0 0;
  padding-left: 20px;
}
.pitfall-elements li {
  overflow-wrap: anywhere;
}
.pitfall-scope {
  color: var(--ocg-color-text-secondary);
  font-size: var(--ocg-text-md);
}
.pitfall-reference {
  display: inline-flex;
  margin-top: 4px;
  color: var(--ocg-color-accent);
  font-size: var(--ocg-text-md);
  font-weight: 500;
}
}
