/* api-docs.php: REST-documentatie. Voorvoegsel .ad-.
   De codeblokken blijven donker: dat is bij documentatie de gewoonte en het
   scheidt code duidelijk van uitleg. De rest volgt de huisstijltokens. */
.ad-body { padding: clamp(1.5rem, 3vw, 2.5rem) 0 3rem; }
.ad-grid { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 2rem; align-items: start; }

/* Zijnavigatie */
.ad-nav { position: sticky; top: 84px; }
.ad-nav-kop { font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--text-muted); padding: 1rem .6rem .3rem; }
.ad-nav-kop:first-child { padding-top: 0; }
.ad-nav a { display: block; padding: .35rem .6rem; border-radius: var(--radius-sm); font-size: .88rem; color: var(--text-muted); text-decoration: none; }
.ad-nav a:hover { background: var(--band-groen); color: var(--primary-dark); }
.ad-nav code { font-size: .85em; color: inherit; background: none; padding: 0; }

/* Secties */
.ad-sectie { scroll-margin-top: 90px; margin-bottom: 2.5rem; }
.ad-sectie h2 { font-size: clamp(1.25rem, 2.2vw, 1.6rem); margin: 0 0 .6rem; }
.ad-sectie h3 { font-family: var(--font-body); font-size: 1.05rem; font-weight: 700; margin: 1.5rem 0 .5rem; }
.ad-sectie > p { font-size: .95rem; color: var(--text-muted); line-height: 1.7; margin: 0 0 .8rem; max-width: 70ch; }
.ad-sectie code { background: var(--bg); border: 1px solid var(--border); border-radius: .3rem; padding: .05rem .3rem; font-size: .88em; color: var(--text); }

.ad-let { display: flex; gap: .6rem; align-items: flex-start; background: var(--band-groen); border: 1px solid var(--primary-border); border-radius: var(--radius-sm); padding: .8rem .95rem; font-size: .9rem; color: var(--primary-darker); line-height: 1.6; margin-top: .9rem; }
.ad-let i { margin-top: .15rem; flex-shrink: 0; }

/* Codeblok */
.code-block { background: #0f172a; border-radius: .7rem; padding: 1.1rem 1.3rem; font-size: .8rem; line-height: 1.7; overflow-x: auto; margin: .75rem 0; }
.code-block pre { margin: 0; color: #e2e8f0; }
.code-block code { background: none; border: 0; padding: 0; color: inherit; }
.code-block .kw  { color: #7dd3fc; }
.code-block .str { color: #86efac; }
.code-block .cm  { color: #94a3b8; }
.code-block .num { color: #fbbf24; }

/* Endpoints */
.endpoint-card { border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); box-shadow: var(--shadow-sm); overflow: hidden; margin-bottom: 1.5rem; }
.endpoint-header { display: flex; align-items: center; gap: .7rem; flex-wrap: wrap; padding: .85rem 1.15rem; background: var(--bg); border-bottom: 1px solid var(--border); }
.method-badge { font-size: .72rem; font-weight: 700; padding: .25em .6em; border-radius: .35rem; letter-spacing: .04em; }
.method-get  { background: var(--blue-light); color: var(--blue-dark); }
.method-post { background: var(--band-groen); color: var(--primary-darker); }
.endpoint-path { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .93rem; font-weight: 600; }
.endpoint-noauth { margin-left: auto; font-size: .82rem; color: var(--text-muted); }
.endpoint-body { padding: 1.15rem; }
.endpoint-body > p { font-size: .93rem; color: var(--text-muted); line-height: 1.65; margin: 0 0 .9rem; }
.ad-label { display: block; font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--text-muted); margin: 1.1rem 0 .35rem; }
.ad-label:first-of-type { margin-top: 0; }

/* Tabellen */
.ad-tabel-wrap { overflow-x: auto; }
.param-table { width: 100%; border-collapse: collapse; font-size: .88rem; }
.param-table th { text-align: left; font-size: .75rem; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--text-muted); padding: .4rem .6rem; border-bottom: 1px solid var(--border); }
.param-table td { padding: .5rem .6rem; border-bottom: 1px solid var(--border); vertical-align: top; color: var(--text-muted); }
.param-table td:first-child { color: var(--text); }
.param-table tr:last-child td { border-bottom: 0; }
.required-badge { font-size: .68rem; font-weight: 600; background: color-mix(in srgb, var(--danger) 10%, var(--surface)); color: var(--danger); padding: .12em .45em; border-radius: .3rem; }
.optional-badge { font-size: .68rem; font-weight: 600; background: var(--bg); color: var(--text-muted); padding: .12em .45em; border-radius: .3rem; }
.ad-code-kolom { font-size: .74rem; font-weight: 700; padding: .12em .45em; border-radius: .3rem; background: var(--bg); color: var(--text); }

/* Changelog en slot */
.ad-kaart { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-sm); padding: 1.15rem 1.25rem; }
.ad-versie { display: flex; gap: .8rem; align-items: flex-start; }
.ad-versie-badge { flex-shrink: 0; font-size: .75rem; font-weight: 700; background: var(--band-groen); color: var(--primary-darker); border-radius: .35rem; padding: .15em .5em; margin-top: .15rem; }
.ad-versie strong { display: block; font-size: .95rem; }
.ad-versie p { margin: .15rem 0 0; font-size: .87rem; color: var(--text-muted); line-height: 1.6; }

.ad-slot { background: var(--band-groen); border: 1px solid var(--primary-border); border-radius: var(--radius); padding: 2rem 1.5rem; text-align: center; }
.ad-slot h2 { font-size: 1.3rem; margin: 0 0 .4rem; }
.ad-slot p { margin: 0 0 1.2rem; font-size: .95rem; color: var(--text-muted); max-width: 52ch; margin-inline: auto; }

@media (max-width: 991.98px) {
  .ad-grid { grid-template-columns: 1fr; }
  .ad-nav { position: static; display: none; }
}
