/* ==========================================================================
   Discovery module — /search and /api (Design system v2, "consumer-security clean").
   Prefix: dc-. Tokens only (see /css/base.css). Mobile-first and 360px-safe,
   robust to long translations (no nowrap/fixed widths on text), dark-mode-safe
   via tokens, print rules at the end. Monospace only for paths, IDs and code.
   ========================================================================== */

/* ------------------------------------------------------------------ hero */
.dc-hero {
  overflow: hidden;
}
.page-hero--dark.dc-hero {
  padding-block: var(--s-8) var(--s-9);
}
.dc-hero__text {
  min-width: 0;
}
.dc-hero__title {
  max-width: 16ch;
  text-wrap: balance;
  overflow-wrap: break-word;
}
.dc-hero--compact {
  padding-block: var(--s-7) var(--s-7);
}
.dc-hero--compact .dc-hero__title {
  font-size: var(--fs-2xl);
  max-width: 30ch;
  overflow-wrap: anywhere;
}
.dc-hero .dc-answer {
  max-width: 62ch;
}
.dc-hero__notice {
  margin-top: var(--s-5);
  max-width: 62ch;
}
.page-hero--dark .dc-hero__notice .notice {
  background: var(--c-band-surface-2);
  border: 1px solid var(--c-band-rule);
  color: var(--c-band-fg);
}
.page-hero--dark .dc-hero__notice .notice .icon {
  color: var(--c-amber);
}
.dc-hero__art {
  position: relative;
  min-width: 0;
}
.dc-hero__art .illustration {
  display: block;
  box-shadow: var(--shadow-lg);
}
.dc-hero__badge {
  position: absolute;
  left: var(--s-4);
  bottom: var(--s-4);
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  max-width: calc(100% - var(--s-4) * 2);
  padding: var(--s-2) var(--s-4);
  border-radius: var(--r-pill);
  background: var(--c-band-fg);
  color: var(--c-band);
  font-size: var(--fs-xs);
  font-weight: 600;
  line-height: 1.35;
  box-shadow: var(--shadow-md);
}
.dc-hero__badge .icon {
  flex-shrink: 0;
  color: var(--c-accent-hover);
}
@media (max-width: 1079px) {
  .dc-hero__art {
    max-width: 560px;
  }
}

/* trust row (check icons + short facts) */
.dc-trust {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-3) var(--s-5);
  margin-top: var(--s-6);
  padding: 0;
  list-style: none;
  font-size: var(--fs-sm);
  font-weight: 550;
  color: var(--c-ink-2);
}
.dc-trust li {
  display: inline-flex;
  align-items: flex-start;
  gap: var(--s-2);
  min-width: 0;
}
.dc-trust .icon {
  flex-shrink: 0;
  margin-top: 0.1em;
  color: var(--c-teal);
}

/* ---------------------------------------------------------- search form */
.dc-search {
  margin-top: var(--s-6);
  max-width: 760px;
}
.dc-search__bar {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  padding: var(--s-2);
  padding-inline-start: var(--s-5);
  background: var(--c-surface);
  border: 1px solid var(--c-rule-strong);
  border-radius: var(--r-pill);
  box-shadow: var(--shadow-sm);
  transition: border-color 0.15s, box-shadow 0.15s;
}
.dc-search__bar:focus-within {
  border-color: var(--c-accent-line);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--c-accent) 22%, transparent), var(--shadow-md);
}
.dc-search__icon {
  display: inline-flex;
  flex-shrink: 0;
  color: var(--c-muted);
}
.dc-search__input {
  flex: 1 1 auto;
  min-width: 0;
  padding: 0.85rem 0;
  border: 0;
  background: transparent;
  color: var(--c-ink);
  font: inherit;
  font-size: var(--fs-md);
  outline: none;
}
.dc-search__input::placeholder {
  color: var(--c-muted);
  opacity: 1;
}
.dc-search__input::-webkit-search-cancel-button {
  cursor: pointer;
}
.dc-search__submit {
  flex-shrink: 0;
  min-height: 3rem;
}
/* on the navy hero the bar is a bright white pill in both colour schemes */
.dc-search--dark .dc-search__bar {
  background: var(--c-band-fg);
  border-color: transparent;
  box-shadow: var(--shadow-lg);
}
.dc-search--dark .dc-search__input {
  color: var(--c-band);
}
.dc-search--dark .dc-search__input::placeholder,
.dc-search--dark .dc-search__icon {
  color: color-mix(in srgb, var(--c-band) 55%, var(--c-band-fg));
}
.dc-search--dark .dc-search__bar:focus-within {
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--c-band-fg) 35%, transparent), var(--shadow-lg);
}
.dc-search__opts {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-3) var(--s-5);
  margin-top: var(--s-4);
  padding-inline: var(--s-2);
}
.dc-search__type {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-2);
  min-width: 0;
  max-width: 100%;
}
.dc-search__type-label {
  font-size: var(--fs-sm);
  font-weight: 600;
  color: var(--c-ink-2);
}
.dc-search__select {
  min-width: 0;
  max-width: 100%;
  padding: 0.45rem 2.2rem 0.45rem 0.95rem;
  border: 1px solid var(--c-rule-strong);
  border-radius: var(--r-pill);
  background-color: var(--c-surface);
  background-image: linear-gradient(45deg, transparent 50%, currentColor 50%), linear-gradient(135deg, currentColor 50%, transparent 50%);
  background-position: calc(100% - 1.1rem) 55%, calc(100% - 0.8rem) 55%;
  background-size: 5px 5px;
  background-repeat: no-repeat;
  color: var(--c-ink);
  font: inherit;
  font-size: var(--fs-sm);
  -webkit-appearance: none;
  appearance: none;
  cursor: pointer;
}
.dc-search__select:focus-visible {
  outline: var(--focus);
  outline-offset: 2px;
}
.dc-search__hint {
  flex: 1 1 18rem;
  min-width: 0;
  font-size: var(--fs-xs);
  color: var(--c-muted);
}
.dc-search__hint code {
  font-family: var(--f-mono);
  font-size: 0.95em;
  padding: 0.1em 0.45em;
  border-radius: var(--r-xs);
  background: var(--c-surface-2);
  color: var(--c-ink);
}
@media (max-width: 559px) {
  .dc-search__bar {
    padding-inline-start: var(--s-4);
  }
  .dc-search__icon {
    display: none;
  }
  .dc-search__submit {
    padding-inline: var(--s-4);
  }
  /* icon-only button on small phones; the label stays available to assistive tech */
  .dc-search__submit-text {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
  }
}

/* ------------------------------------------------------- suggestion chips */
.dc-chips {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-3);
  margin-top: var(--s-5);
}
.dc-chips__label {
  font-size: var(--fs-sm);
  font-weight: 600;
  color: var(--c-ink-2);
}
.dc-chips__list {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2);
  margin: 0;
  padding: 0;
  list-style: none;
}
.dc-chip {
  display: inline-flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 0.15rem 0.5rem;
  padding: 0.45rem 0.95rem;
  border: 1px solid var(--c-rule-strong);
  border-radius: var(--r-pill);
  background: var(--c-surface);
  color: var(--c-ink);
  font-size: var(--fs-sm);
  font-weight: 600;
  text-decoration: none;
  transition: border-color 0.15s, background 0.15s, color 0.15s;
}
.dc-chip:hover {
  border-color: var(--c-accent-line);
  color: var(--c-accent-text);
}
.dc-chip__note {
  font-weight: 450;
  font-size: var(--fs-xs);
  color: var(--c-muted);
}
.dc-chips--dark .dc-chip {
  background: color-mix(in srgb, var(--c-band-fg) 8%, transparent);
  border-color: color-mix(in srgb, var(--c-band-fg) 22%, transparent);
  color: var(--c-band-fg);
}
.dc-chips--dark .dc-chip:hover {
  background: color-mix(in srgb, var(--c-band-fg) 16%, transparent);
  border-color: color-mix(in srgb, var(--c-band-fg) 45%, transparent);
  color: var(--c-band-fg);
}
.dc-chips--dark .dc-chip__note {
  display: none;
}

/* ---------------------------------------------------------------- shared */
.dc-center {
  display: flex;
  justify-content: center;
  margin-top: var(--s-7);
}
.dc-split {
  display: grid;
  gap: var(--s-5);
  grid-template-columns: minmax(0, 1fr);
  align-items: start;
}
.dc-split + .dc-split {
  margin-top: var(--s-5);
}
@media (min-width: 1080px) {
  .dc-split {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: var(--s-6);
  }
}
.dc-subhead {
  margin-top: var(--s-8);
  margin-bottom: var(--s-3);
  font-size: var(--fs-xl);
  font-weight: 700;
  line-height: var(--lh-snug);
  letter-spacing: var(--tracking-tight);
}
.dc-feature__text > .dc-subhead:first-child {
  margin-top: 0;
}
.dc-text {
  max-width: 70ch;
  margin-bottom: var(--s-5);
  color: var(--c-ink-2);
}
.dc-note {
  margin-top: var(--s-5);
}
.dc-path,
.dc-field,
.dc-type-cell code {
  font-family: var(--f-mono);
  font-size: 0.875em;
  overflow-wrap: anywhere;
  word-break: break-word;
}
a.dc-path {
  color: var(--c-accent-text);
  text-decoration: none;
}
a.dc-path:hover {
  text-decoration: underline;
  text-underline-offset: 0.2em;
}
.dc-field {
  color: var(--c-ink);
  font-weight: 600;
}
.dc-type-cell code {
  color: var(--c-muted);
}
.dc-format {
  display: inline-flex;
  padding: 0.15rem 0.6rem;
  border-radius: var(--r-pill);
  background: var(--c-accent-soft);
  color: var(--c-accent-text);
  font-size: var(--fs-xs);
  font-weight: 650;
}
.dc-weight__pill {
  display: inline-flex;
  padding: 0.15rem 0.65rem;
  border-radius: var(--r-pill);
  background: var(--c-accent-soft);
  color: var(--c-accent-text);
  font-weight: 650;
  font-size: var(--fs-xs);
}

/* tables: identifiers stay on one line on wide screens (the wrapper scrolls if needed);
   rows become cards below 720px */
@media (min-width: 720px) {
  .dc-table .dc-field,
  .dc-table .dc-path,
  .dc-table .dc-type-cell code,
  .dc-format {
    white-space: nowrap;
    overflow-wrap: normal;
    word-break: normal;
  }
  .dc-table .dc-type-cell code {
    white-space: normal;
  }
}
@media (min-width: 1080px) {
  .dc-split > .dc-code {
    position: sticky;
    top: calc(var(--header-h) + var(--s-5));
  }
}
.dc-table .data-table th[scope='row'] {
  font-weight: 650;
}
@media (max-width: 719px) {
  .dc-table {
    overflow: visible;
  }
  .dc-stack thead {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
  }
  .dc-stack,
  .dc-stack tbody,
  .dc-stack tr,
  .dc-stack th,
  .dc-stack td {
    display: block;
    width: 100%;
  }
  .dc-stack caption {
    display: block;
  }
  .dc-stack tr {
    padding: var(--s-4) var(--s-5);
    border-bottom: var(--rule);
  }
  .dc-stack tbody tr:last-child {
    border-bottom: 0;
  }
  .dc-stack th,
  .dc-stack td {
    padding: 0;
    border: 0;
    text-align: left;
  }
  .dc-stack td {
    margin-top: var(--s-2);
  }
  .dc-stack td[data-label]::before {
    content: attr(data-label);
    display: block;
    font-size: var(--fs-2xs);
    font-weight: 650;
    color: var(--c-muted);
    margin-bottom: 0.1rem;
  }
  .dc-stack td.num {
    text-align: left;
  }
  .dc-stack tbody tr:hover {
    background: transparent;
  }
  /* field references: name + type on one line, description below, no repeated labels */
  .dc-stack--fields th,
  .dc-stack--fields td.dc-type-cell {
    display: inline;
    width: auto;
  }
  .dc-stack--fields td.dc-type-cell {
    margin-inline-start: var(--s-2);
  }
  .dc-stack--fields td[data-label]::before {
    content: none;
  }
  .dc-stack--fields td:last-child {
    margin-top: var(--s-1);
    font-size: var(--fs-sm);
    color: var(--c-ink-2);
  }
  .dc-type {
    padding: var(--s-4);
  }
  .dc-type__icon {
    width: 40px;
    height: 40px;
  }
}

/* code card: always dark */
.dc-code {
  margin: 0;
  min-width: 0;
  overflow: hidden;
  border-radius: var(--r-lg);
  background: var(--c-band);
  border: 1px solid var(--c-band-rule);
  color: var(--c-band-fg);
  box-shadow: var(--shadow-md);
}
.dc-code__head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-2) var(--s-3);
  padding: var(--s-3) var(--s-4);
  border-bottom: 1px solid var(--c-band-rule);
  background: var(--c-band-surface);
}
.dc-code__dots {
  display: inline-flex;
  gap: 6px;
}
.dc-code__dots i {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--c-band-rule);
}
.dc-code__dots i:first-child {
  background: var(--sev-critical);
}
.dc-code__dots i:nth-child(2) {
  background: var(--c-amber);
}
.dc-code__dots i:last-child {
  background: var(--sev-pass);
}
.dc-code__label {
  font-size: var(--fs-sm);
  font-weight: 650;
  color: var(--c-band-fg);
}
.dc-code__meta {
  flex: 1 1 auto;
  min-width: 0;
  font-size: var(--fs-xs);
  color: var(--c-band-muted);
}
.dc-code__copy {
  margin-inline-start: auto;
  color: var(--c-band-fg);
  border-color: var(--c-band-rule);
  background: transparent;
}
.dc-code__copy:hover {
  background: var(--c-band-surface-2);
}
.dc-code__pre {
  margin: 0;
  max-height: 34rem;
  overflow: auto;
  padding: var(--s-5);
  font-family: var(--f-mono);
  font-size: var(--fs-xs);
  line-height: 1.7;
  color: color-mix(in srgb, var(--c-band-fg) 86%, var(--c-glow));
  tab-size: 2;
}
.dc-code__pre:focus-visible {
  outline: var(--focus);
  outline-offset: -3px;
}

/* --------------------------------------------------------- search landing */
.dc-types {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 17.5rem), 1fr));
  gap: var(--s-4);
  margin: 0;
  padding: 0;
  list-style: none;
}
.dc-type {
  position: relative;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  grid-template-areas: 'icon label go' 'icon count go';
  align-items: center;
  gap: 0.15rem var(--s-4);
  height: 100%;
  padding: var(--s-5);
  border: 1px solid var(--c-rule);
  border-radius: var(--r-lg);
  background: var(--c-surface);
  color: var(--c-ink);
  text-decoration: none;
  transition: box-shadow 0.2s, border-color 0.2s, transform 0.2s;
}
.dc-type:hover {
  border-color: var(--c-rule-strong);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}
.dc-type__icon {
  grid-area: icon;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border-radius: var(--r-md);
  background: var(--c-accent-soft);
  color: var(--c-accent-text);
}
.dc-type__label {
  grid-area: label;
  font-weight: 650;
  line-height: var(--lh-snug);
  overflow-wrap: break-word;
  hyphens: auto;
}
.dc-type__count {
  grid-area: count;
  font-size: var(--fs-sm);
  color: var(--c-muted);
}
.dc-type__go {
  grid-area: go;
  display: inline-flex;
  color: var(--c-accent-text);
  transition: transform 0.2s;
}
.dc-type:hover .dc-type__go {
  transform: translateX(3px);
}

.dc-tips {
  padding: var(--s-6);
  border-radius: var(--r-xl);
  background: var(--c-surface);
  border: 1px solid var(--c-rule);
}
.dc-tips__title {
  font-size: var(--fs-lg);
  font-weight: 700;
  line-height: var(--lh-snug);
  margin-bottom: var(--s-4);
}
.dc-tips__list {
  display: grid;
  gap: var(--s-4);
  margin: 0;
}
.dc-tip dt {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  font-weight: 650;
}
.dc-tip dt .icon {
  flex-shrink: 0;
  color: var(--c-teal);
}
.dc-tip dd {
  margin: 0.2rem 0 0;
  padding-inline-start: calc(18px + var(--s-2));
  font-size: var(--fs-sm);
  color: var(--c-ink-2);
}

.dc-endpoints {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 15rem), 1fr));
  gap: var(--s-4);
  margin: 0;
  padding: 0;
  list-style: none;
}
.dc-endpoint {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
  height: 100%;
  padding: var(--s-5);
  border-radius: var(--r-lg);
  background: var(--c-surface);
  border: 1px solid var(--c-rule);
  color: var(--c-ink);
  text-decoration: none;
  transition: border-color 0.2s, transform 0.2s;
}
.dc-endpoint:hover {
  border-color: var(--c-accent-line);
  transform: translateY(-2px);
}
.dc-endpoint__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: var(--r-md);
  background: var(--c-accent-soft);
  color: var(--c-accent-text);
}
.dc-endpoint__path {
  font-family: var(--f-mono);
  font-size: var(--fs-sm);
  font-weight: 600;
  color: var(--c-accent-text);
  overflow-wrap: anywhere;
}
.dc-endpoint__desc {
  font-size: var(--fs-sm);
  color: var(--c-ink-2);
}

/* --------------------------------------------------------------- results */
.dc-results-wrap {
  padding-top: var(--s-7);
}
.dc-results-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--s-2) var(--s-5);
  margin-bottom: var(--s-5);
}
.dc-results-head__title {
  font-size: var(--fs-xl);
  font-weight: 700;
  line-height: var(--lh-snug);
  letter-spacing: var(--tracking-tight);
  overflow-wrap: anywhere;
}
.dc-results-head__meta {
  font-size: var(--fs-sm);
  color: var(--c-muted);
  overflow-wrap: anywhere;
}
.dc-results-wrap > .container > .notice,
.dc-direct,
.dc-results-wrap > .container > .notice + .notice {
  margin-bottom: var(--s-5);
}
.dc-direct {
  display: grid;
  gap: var(--s-4);
}
.dc-direct__item {
  padding: var(--s-4);
  border-radius: var(--r-xl);
  background: var(--c-accent-soft);
}
.dc-direct__label {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  margin: 0 0 var(--s-3) var(--s-2);
  font-size: var(--fs-sm);
  font-weight: 650;
  color: var(--c-accent-text);
}
.dc-hashlist {
  margin: var(--s-2) 0 0;
  padding-inline-start: 1.2em;
}
.dc-hashlist a {
  overflow-wrap: anywhere;
}

/* facet chips */
.dc-facets {
  margin-bottom: var(--s-6);
}
.dc-facets ul {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2);
  margin: 0;
  padding: 0;
  list-style: none;
}
.dc-facet {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  padding: 0.4rem 0.5rem 0.4rem 0.95rem;
  border: 1px solid var(--c-rule-strong);
  border-radius: var(--r-pill);
  background: var(--c-surface);
  color: var(--c-ink);
  font-size: var(--fs-sm);
  font-weight: 600;
  text-decoration: none;
  transition: border-color 0.15s, background 0.15s;
}
.dc-facet:hover {
  border-color: var(--c-accent-line);
}
.dc-facet__count {
  min-width: 1.75rem;
  padding: 0.05rem 0.5rem;
  border-radius: var(--r-pill);
  background: var(--c-surface-2);
  color: var(--c-ink-2);
  font-size: var(--fs-xs);
  font-weight: 650;
  text-align: center;
  font-variant-numeric: tabular-nums;
}
.dc-facet[aria-current] {
  background: var(--c-accent);
  border-color: var(--c-accent-line);
  color: var(--c-accent-ink);
}
.dc-facet[aria-current] .dc-facet__count {
  background: color-mix(in srgb, var(--c-accent-ink) 20%, transparent);
  color: var(--c-accent-ink);
}

.dc-results-grid {
  display: grid;
  gap: var(--s-6);
  grid-template-columns: minmax(0, 1fr);
}
@media (min-width: 1080px) {
  .dc-results-grid {
    grid-template-columns: minmax(0, 1fr) 320px;
    gap: var(--s-7);
    align-items: start;
  }
  .dc-help {
    position: sticky;
    top: calc(var(--header-h) + var(--s-5));
  }
}
.dc-results-main {
  min-width: 0;
}
.dc-results {
  display: grid;
  gap: var(--s-3);
  margin: 0;
  padding: 0;
  list-style: none;
}
.dc-result__card {
  position: relative;
  padding: var(--s-5);
  border: 1px solid var(--c-rule);
  border-radius: var(--r-lg);
  background: var(--c-surface);
  transition: box-shadow 0.2s, border-color 0.2s;
}
.dc-result__card:hover {
  border-color: var(--c-rule-strong);
  box-shadow: var(--shadow-md);
}
.dc-result__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-2);
  margin-bottom: var(--s-3);
}
.dc-result__date {
  font-size: var(--fs-xs);
  color: var(--c-muted);
}
.dc-result__title {
  font-size: var(--fs-md);
  font-weight: 650;
  line-height: var(--lh-snug);
  overflow-wrap: anywhere;
}
.dc-result__title a {
  color: var(--c-ink);
  text-decoration: none;
}
.dc-result__title a::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
}
.dc-result__card:hover .dc-result__title a {
  color: var(--c-accent-text);
}
.dc-result__title a:focus-visible {
  outline: none;
}
.dc-result__title a:focus-visible::after {
  outline: var(--focus);
  outline-offset: 2px;
}
.dc-result__url {
  margin-top: 0.2rem;
  font-family: var(--f-mono);
  font-size: var(--fs-2xs);
  color: var(--c-teal);
  overflow-wrap: anywhere;
}
.dc-result__snippet {
  margin-top: var(--s-2);
  font-size: var(--fs-sm);
  color: var(--c-ink-2);
  overflow-wrap: break-word;
}
.dc-mark {
  padding: 0 0.15em;
  border-radius: 4px;
  background: var(--c-mark);
  color: var(--c-mark-ink);
}
.dc-result__meta .record-id,
.dc-result__meta .badge {
  position: relative;
  z-index: 1;
}
.dc-results + .pagination {
  margin-top: var(--s-6);
}

.dc-empty .empty-state {
  margin-bottom: var(--s-5);
}
.dc-empty__hint {
  color: var(--c-ink-2);
}
.dc-empty .dc-chips {
  justify-content: center;
}

.dc-help {
  padding: var(--s-5);
  border-radius: var(--r-xl);
  background: var(--c-surface-2);
}
.dc-help__art {
  display: block;
  margin-bottom: var(--s-4);
  border-radius: var(--r-lg);
}
.dc-help__title {
  font-size: var(--fs-lg);
  font-weight: 700;
  line-height: var(--lh-snug);
  margin-bottom: var(--s-3);
}
.dc-help__links {
  display: grid;
  gap: var(--s-1);
  margin: 0;
  padding: 0;
  list-style: none;
}
.dc-help__links a {
  display: flex;
  align-items: flex-start;
  gap: var(--s-3);
  padding: var(--s-2) var(--s-3);
  border-radius: var(--r-md);
  color: var(--c-ink);
  font-size: var(--fs-sm);
  font-weight: 550;
  text-decoration: none;
}
.dc-help__links a:hover {
  background: var(--c-surface);
  color: var(--c-accent-text);
}
.dc-help__links .icon {
  flex-shrink: 0;
  margin-top: 0.1em;
  color: var(--c-accent-text);
}
.dc-help__api {
  margin-top: var(--s-4);
  font-size: var(--fs-xs);
  color: var(--c-muted);
}
.dc-help__api code {
  font-family: var(--f-mono);
}

/* ------------------------------------------------------------------ /api */
.dc-spec-wrap {
  padding-top: var(--s-7);
  padding-bottom: 0;
}
.dc-spec {
  padding: var(--s-6);
  border-radius: var(--r-xl);
  background: var(--c-surface);
  border: 1px solid var(--c-rule);
  box-shadow: var(--shadow-sm);
}
.dc-spec__head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-3);
  margin-bottom: var(--s-5);
}
.dc-spec__title {
  font-size: var(--fs-xl);
  font-weight: 700;
  line-height: var(--lh-snug);
  letter-spacing: var(--tracking-tight);
}
.dc-spec__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 15rem), 1fr));
  gap: var(--s-3);
  margin: 0;
}
.dc-spec__item {
  min-width: 0;
  padding: var(--s-4);
  border-radius: var(--r-md);
  background: var(--c-surface-2);
}
.dc-spec__item dt {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  font-size: var(--fs-xs);
  font-weight: 650;
  color: var(--c-muted);
}
.dc-spec__item dt .icon {
  flex-shrink: 0;
  color: var(--c-accent-text);
}
.dc-spec__item dd {
  margin: var(--s-2) 0 0;
  font-size: var(--fs-sm);
  font-weight: 550;
  overflow-wrap: anywhere;
}
.dc-spec__item code {
  font-family: var(--f-mono);
  font-size: 0.9em;
}

.dc-pills {
  margin-top: var(--s-5);
}
.dc-pills ul {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2);
  margin: 0;
  padding: 0;
  list-style: none;
}
.dc-pill {
  display: inline-flex;
  padding: 0.45rem 1rem;
  border-radius: var(--r-pill);
  border: 1px solid var(--c-rule-strong);
  background: var(--c-surface);
  color: var(--c-ink);
  font-size: var(--fs-sm);
  font-weight: 600;
  text-decoration: none;
}
.dc-pill:hover {
  border-color: var(--c-accent-line);
  color: var(--c-accent-text);
}

.dc-epcards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 22rem), 1fr));
  gap: var(--s-4);
  margin: 0;
  padding: 0;
  list-style: none;
}
.dc-epcard {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
  min-width: 0;
  padding: var(--s-5);
  border: 1px solid var(--c-rule);
  border-radius: var(--r-lg);
  background: var(--c-surface);
  scroll-margin-top: calc(var(--header-h) + var(--s-5));
}
.dc-epcard__top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-2);
}
.dc-method {
  padding: 0.15rem 0.6rem;
  border-radius: var(--r-pill);
  background: var(--c-teal-soft);
  color: var(--c-success);
  font-family: var(--f-mono);
  font-size: var(--fs-2xs);
  font-weight: 700;
}
.dc-epcard__format {
  font-size: var(--fs-xs);
  font-weight: 650;
  color: var(--c-ink-2);
}
.dc-status {
  margin-inline-start: auto;
  padding: 0.15rem 0.6rem;
  border-radius: var(--r-pill);
  background: var(--c-surface-2);
  color: var(--c-ink-2);
  font-family: var(--f-mono);
  font-size: var(--fs-2xs);
  font-weight: 600;
}
.dc-epcard__path {
  font-size: var(--fs-md);
  line-height: 1.4;
}
.dc-epcard__path .dc-path {
  font-weight: 600;
}
.dc-epcard__text {
  font-size: var(--fs-sm);
  color: var(--c-ink-2);
}

/* text + illustration feature row */
.dc-feature {
  display: grid;
  gap: var(--s-6);
  grid-template-columns: minmax(0, 1fr);
  align-items: center;
  margin-bottom: var(--s-7);
}
.dc-feature--reverse {
  margin-top: var(--s-7);
  margin-bottom: 0;
}
.dc-feature__art {
  margin: 0;
  min-width: 0;
  max-width: 560px;
}
@media (min-width: 1080px) {
  .dc-feature {
    grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
    gap: var(--s-8);
  }
  .dc-feature--reverse {
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  }
  .dc-feature--reverse .dc-feature__art {
    order: -1;
  }
}
.dc-feature .section-head {
  grid-template-columns: minmax(0, 1fr);
  margin-bottom: var(--s-5);
}
.dc-prose {
  display: grid;
  gap: var(--s-4);
  max-width: 68ch;
  color: var(--c-ink-2);
}
.dc-prose code {
  font-family: var(--f-mono);
  font-size: 0.85em;
  padding: 0.1em 0.4em;
  border-radius: var(--r-xs);
  background: var(--c-surface-2);
  color: var(--c-ink);
  overflow-wrap: anywhere;
}
.dc-split--code {
  margin-top: 0;
}

/* navy stat band (rounded panel) */
.dc-statband {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 12rem), 1fr));
  gap: var(--s-4);
  margin-bottom: var(--s-6);
  padding: var(--s-6);
  border-radius: var(--r-xl);
}
.dc-statband .stat {
  background: transparent;
  border: 0;
  padding: var(--s-3) var(--s-2);
}
.dc-statband .stat__value {
  color: var(--c-band-fg);
}

/* discovery file cards */
.dc-files {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 18rem), 1fr));
  gap: var(--s-4);
  margin: 0;
  padding: 0;
  list-style: none;
}
.dc-file {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
  min-width: 0;
  padding: var(--s-5);
  border-radius: var(--r-lg);
  background: var(--c-surface);
  border: 1px solid var(--c-rule);
}
.dc-file__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  margin-bottom: var(--s-2);
  border-radius: var(--r-md);
  background: var(--c-accent-soft);
  color: var(--c-accent-text);
}
.dc-file__title {
  font-size: var(--fs-md);
  font-weight: 650;
  line-height: var(--lh-snug);
}
.dc-file__path {
  font-size: var(--fs-sm);
}
.dc-file__text {
  font-size: var(--fs-sm);
  color: var(--c-ink-2);
}
.dc-file__meta {
  display: grid;
  gap: var(--s-1);
  margin: auto 0 0;
  padding-top: var(--s-3);
  border-top: var(--rule);
  font-size: var(--fs-xs);
}
.dc-file__meta div {
  display: flex;
  flex-wrap: wrap;
  gap: 0 var(--s-2);
}
.dc-file__meta dt {
  color: var(--c-muted);
  font-weight: 600;
}
.dc-file__meta dd {
  margin: 0;
  min-width: 0;
  color: var(--c-ink-2);
  overflow-wrap: anywhere;
}
.dc-file__meta code {
  font-family: var(--f-mono);
  font-size: 0.95em;
}

/* terms of use: rule cards */
.dc-rules {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 18rem), 1fr));
  gap: var(--s-4);
  margin: 0;
  padding: 0;
  list-style: none;
}
.dc-rule {
  padding: var(--s-6) var(--s-5);
  border-radius: var(--r-lg);
  background: var(--c-surface-2);
}
.dc-rule__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  margin-bottom: var(--s-4);
  border-radius: 50%;
  background: var(--c-surface);
  color: var(--c-accent-text);
  box-shadow: var(--shadow-sm);
}
.dc-rule__title {
  font-size: var(--fs-md);
  font-weight: 650;
  line-height: var(--lh-snug);
  margin-bottom: var(--s-2);
}
.dc-rule__text {
  font-size: var(--fs-sm);
  color: var(--c-ink-2);
  overflow-wrap: break-word;
}

/* FAQ accordion: question headings inside <summary> */
.dc-faq .dc-faq__q {
  font: inherit;
  margin: 0;
  letter-spacing: 0;
}

/* CTA banner */
.dc-cta {
  display: grid;
  gap: var(--s-5);
  align-items: center;
  padding: var(--s-7) var(--s-6);
  border-radius: var(--r-xl);
}
@media (min-width: 960px) {
  .dc-cta {
    grid-template-columns: minmax(0, 1fr) auto;
    padding: var(--s-8) var(--s-7);
  }
}
.dc-cta__title {
  font-size: var(--fs-2xl);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: var(--tracking-display);
  max-width: 22ch;
}
.dc-cta__lead {
  margin-top: var(--s-3);
  max-width: 56ch;
  color: var(--c-ink-2);
}
.dc-cta__actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-3);
}

/* ----------------------------------------------------------------- print */
@media print {
  .dc-hero__art,
  .dc-search,
  .dc-chips,
  .dc-facets,
  .dc-help,
  .dc-pills,
  .dc-cta,
  .dc-code__copy,
  .dc-code__dots,
  .dc-feature__art {
    display: none !important;
  }
  .dc-code,
  .dc-code__head {
    background: #fff !important;
    color: #000 !important;
    border-color: #ccc !important;
    box-shadow: none !important;
  }
  .dc-code__pre {
    max-height: none;
    overflow: visible;
    color: #000;
    white-space: pre-wrap;
    word-break: break-word;
  }
  .dc-code__label,
  .dc-code__meta {
    color: #000;
  }
  .dc-statband {
    padding: 0;
    background: #fff !important;
  }
  .dc-statband .stat__value {
    color: #000;
  }
  .dc-type,
  .dc-result__card,
  .dc-epcard,
  .dc-file,
  .dc-rule,
  .dc-spec {
    box-shadow: none !important;
    transform: none !important;
    break-inside: avoid;
  }
  .dc-result__title a::after {
    content: none;
  }
}
