/* Diagrams (generated by docs/book/tools/diagrams.py). Colors follow the mdBook theme:
   neutral shapes use the theme's foreground; three hues carry meaning and read on light
   and dark themes alike: amber = the guard / waiting, green = allowed, red = denied. */
.lx-fig { margin: 2em 0; }
.lx-fig svg { display: block; width: 100%; max-width: 860px; height: auto; margin: 0 auto; color: var(--fg); }
.lx-fig figcaption { text-align: center; font-size: 0.9em; opacity: 0.75; margin-top: 0.6em; }

.lx-fig .b    { fill: var(--quote-bg); stroke: currentColor; stroke-opacity: 0.45; stroke-width: 1.2; }
.lx-fig .ba   { fill: rgba(217, 119, 6, 0.14); stroke: #d97706; stroke-width: 1.6; }
.lx-fig .bacc { fill: rgba(217, 119, 6, 0.14); stroke: #d97706; stroke-width: 1.4; }
.lx-fig .bok  { fill: rgba(22, 163, 74, 0.14); stroke: #16a34a; stroke-width: 1.4; }
.lx-fig .bbad { fill: rgba(220, 38, 38, 0.13); stroke: #dc2626; stroke-width: 1.4; }

.lx-fig text { fill: currentColor; font-family: system-ui, -apple-system, "Segoe UI", sans-serif; }
.lx-fig .t   { font-size: 13px; }
.lx-fig .tb  { font-weight: 600; font-size: 14px; }
.lx-fig .s   { font-size: 11.5px; opacity: 0.72; }
.lx-fig .mono { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; }
.lx-fig .okt { fill: #16a34a; font-weight: 600; }
.lx-fig .badt { fill: #dc2626; font-weight: 600; opacity: 1; }

.lx-fig polyline { fill: none; stroke-width: 1.5; }
.lx-fig .l   { stroke: currentColor; stroke-opacity: 0.6; }
.lx-fig .ok  { stroke: #16a34a; }
.lx-fig .bad { stroke: #dc2626; }
.lx-fig .acc { stroke: #d97706; }
.lx-fig .mk    { fill: currentColor; fill-opacity: 0.6; }
.lx-fig .mkok  { fill: #16a34a; }
.lx-fig .mkbad { fill: #dc2626; }
.lx-fig .mkacc { fill: #d97706; }

/* Lesson headers */
.lx-lesson { border-left: 4px solid #d97706; padding: 0.6em 1em; background: var(--quote-bg); border-radius: 0 6px 6px 0; margin: 1em 0 1.5em; }
.lx-lesson p { margin: 0.25em 0; }
