/* Otoolia — TikZ → SVG */
.tz-head { margin-bottom: var(--ot-space); }
.tz-head h1 { margin-bottom: .2em; }
.tz-two { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: calc(var(--ot-space) * 1.25); align-items: start; }
@media (max-width: 860px) { .tz-two { grid-template-columns: minmax(0, 1fr); } }
.tz-in { display: flex; flex-direction: column; gap: 10px; }
.tz-label { font-weight: 700; font-size: 1rem; margin: 0; }
.tz-ex { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; font-size: .9rem; color: var(--ot-text-soft); }
.tz-mini { padding: 4px 10px; font-size: .85rem; }
.tz-code { width: 100%; font-family: var(--ot-mono, ui-monospace, SFMono-Regular, Menlo, Consolas, monospace); font-size: .88rem; line-height: 1.45; tab-size: 2; white-space: pre; overflow-x: auto; }
.tz-pre-d summary { cursor: pointer; font-weight: 600; }
.tz-pre-d[open] summary { margin-bottom: 6px; }
.tz-hint { font-size: .85rem; color: var(--ot-text-soft); margin: 4px 0 0; }
.tz-fields { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 10px; }
.tz-f { display: flex; flex-direction: column; gap: 4px; font-size: .9rem; font-weight: 600; }
.tz-go { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.tz-res { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
/* l'aperçu reste sur fond blanc (les figures LaTeX sont noires), y compris en thème sombre */
.tz-prev { background: #fff; color: #111; border: 1px solid var(--ot-border); border-radius: var(--ot-radius); min-height: 180px; padding: 16px; display: flex; align-items: center; justify-content: center; overflow: auto; }
.tz-prev svg { max-width: 100%; height: auto; }
.tz-empty { color: #777; margin: 0; }
.tz-status { margin: 0; padding: 10px 12px; border-radius: var(--ot-radius-s); font-size: .92rem; background: var(--ot-surface-2); }
.tz-status ul { margin: 6px 0 0 1.2em; padding: 0; }
.tz-status--ok { background: color-mix(in srgb, var(--ot-success) 14%, transparent); }
.tz-status--warn { background: color-mix(in srgb, #f4a261 22%, transparent); }
.tz-status--err { background: color-mix(in srgb, var(--ot-danger) 14%, transparent); }
.tz-status--wait::before { content: ""; display: inline-block; width: 12px; height: 12px; margin-right: 8px; vertical-align: -1px; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: tz-spin .8s linear infinite; }
@keyframes tz-spin { to { transform: rotate(360deg); } }
.tz-out { display: flex; flex-wrap: wrap; gap: 8px; }
.tz-imp summary { cursor: pointer; font-weight: 600; }
.tz-imp[open] summary { margin-bottom: 8px; }
.tz-imp .ot-btn { margin-top: 8px; }
/* zone de travail de TikZJax : rendue (le moteur mesure le texte) mais hors de l'écran */
.tz-work { position: absolute; left: -10000px; top: 0; width: 1px; overflow: hidden; }
.tz-help { margin-top: calc(var(--ot-space) * 2.5); }
