/* Slides: exam-style design (countdown, marks per question, Full / Half / None marking). Uses the site's colour variables, so dark mode follows. */
.sd-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; margin: 10px 0 14px; }
.sd-timer { margin-left: auto; padding: 5px 14px; border-radius: 999px; background: var(--navy); color: #fff; font-weight: 800; font-size: 1.05rem; font-variant-numeric: tabular-nums; }
[data-theme="dark"] .sd-timer { background: var(--primary); }
.sd-timer.is-low { background: var(--red); color: #fff; }
.sd-body { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 20px; align-items: start; }
@media (max-width: 860px) { .sd-body { grid-template-columns: 1fr; } }
.sd-figs { display: grid; gap: 10px; }
.sd-figs.two { grid-template-columns: 1fr 1fr; }
@media (max-width: 520px) { .sd-figs.two { grid-template-columns: 1fr; } }
.sd-figs figure { position: relative; margin: 0; }
.sd-figs figcaption { position: absolute; left: 8px; top: 8px; padding: 1px 9px; border-radius: 6px; background: rgba(255, 255, 255, .92); color: #14213D; font-weight: 800; }
.sd-zoom { display: grid; place-items: center; width: 100%; padding: 0; border: 0; border-radius: var(--r); background: #0d1117; overflow: hidden; cursor: zoom-in; }
.sd-zoom img { display: block; max-width: 100%; max-height: 72vh; object-fit: contain; -webkit-user-drag: none; user-select: none; }
.sd-case { margin: 0 0 12px; padding: 11px 14px; border-radius: var(--r-sm); background: var(--t); color: var(--ink); font-weight: 600; }
[data-theme="dark"] .sd-case { background: color-mix(in srgb, var(--c) 22%, var(--surface)); }
.sd-list { margin: 0; padding-left: 22px; display: grid; gap: 12px; }
.sd-list > li::marker { font-weight: 800; color: var(--c); }
.sd-q { display: flex; justify-content: space-between; gap: 12px; font-weight: 600; color: var(--ink); }
.sd-q > div > :first-child { margin-top: 0; } .sd-q > div > :last-child { margin-bottom: 0; }
.sd-q em, .sd-mk { flex: none; font-style: normal; font-size: .78rem; font-weight: 600; color: var(--muted); }
.slide-qtext .sd-mk { margin-left: auto; padding-left: 10px; }
.sd-a { margin-top: 6px; padding: 9px 12px; border-left: 3px solid var(--green); border-radius: var(--r-sm); background: var(--green-wash); color: var(--ink); }
.sd-a > :first-child { margin-top: 0; } .sd-a ul, .sd-a ol { padding-left: 20px; }
.sd-show { margin-top: 6px; }
.sd-mark { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 8px; font-size: .8rem; color: var(--muted); }
.sd-mark button { padding: 4px 12px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); color: var(--ink); font: 700 .8rem var(--sans); cursor: pointer; }
.sd-mark button:hover { border-color: var(--c); }
.sd-mark button.on { background: var(--navy); border-color: var(--navy); color: #fff; }
[data-theme="dark"] .sd-mark button.on { background: var(--primary); border-color: var(--primary); }
.sd-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 18px; }
.sd-foot .btn-primary { margin-left: auto; }
.sd-foot .btn-primary:disabled { opacity: .5; cursor: not-allowed; }
.sd .slide-markbtns { margin-top: 8px; }
.exam-review .sd-slidescore { margin: 10px 0 0; font-weight: 600; }

/* "More examples": other pictures of the same diagnosis, shown after the answers */
.sd-gal { margin: 22px 0 6px; padding-top: 14px; border-top: 1px solid var(--line); }
.sd-gal h2 { margin: 0 0 10px; font-size: 1.05rem; color: var(--ink); }
.sd-gal-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 10px; }
.sd-gal-grid .sd-zoom img { width: 100%; height: 190px; max-height: none; object-fit: contain; }
.edit-gal { margin: 0; padding: 10px 14px; border: 1px dashed var(--line); border-radius: var(--r-sm); }
.edit-gal legend { padding: 0 6px; font-weight: 700; }
/* Picture viewer with zoom (assets/zoom.js) */
.zoom.zv { overflow: hidden; touch-action: none; cursor: default; user-select: none; -webkit-user-select: none; }
.zoom.zv img { max-width: 100%; max-height: calc(100% - 64px); transform-origin: center center; transition: transform .08s ease-out; cursor: zoom-in; -webkit-user-drag: none; }
.zoom.zv.zv-zoomed img { cursor: grab; }
.zoom.zv.zv-zoomed img:active { cursor: grabbing; }
.zv-bar { position: absolute; left: 50%; bottom: 16px; transform: translateX(-50%); display: flex; align-items: center; gap: 6px; padding: 6px; border-radius: 999px; background: rgba(20, 24, 33, .88); box-shadow: 0 4px 18px rgba(0, 0, 0, .4); z-index: 2; }
.zv-bar button { min-width: 40px; height: 40px; padding: 0 12px; border: 0; border-radius: 999px; background: rgba(255, 255, 255, .12); color: #fff; font: 700 1.1rem/1 var(--sans, system-ui); cursor: pointer; }
.zv-bar button:hover { background: rgba(255, 255, 255, .24); }
.zv-bar .zv-close { background: #fff; color: #14213D; font-size: .9rem; }
.zv-pct { min-width: 52px; text-align: center; color: #fff; font-weight: 700; font-size: .85rem; font-variant-numeric: tabular-nums; }
/* Learning slides (no questions) */
.sd-learn { margin-left: auto; padding: 5px 14px; border-radius: 999px; background: var(--green-wash); color: var(--green); font-weight: 800; font-size: .9rem; }
.sd-explain { padding: 12px 16px; border-left: 4px solid var(--c); border-radius: var(--r-sm); background: var(--surface); color: var(--ink); }
.sd-explain > :first-child { margin-top: 0; } .sd-explain > :last-child { margin-bottom: 0; } .sd-explain ul { padding-left: 20px; }
/* Gallery captions (each example's own diagnosis) */
.sd-gal-item { margin: 0; }
.sd-gal-item figcaption { margin-top: 4px; font-size: .82rem; font-weight: 600; color: var(--ink); line-height: 1.3; }
.edit-gal .edit-pic input[name^="gcap"] { width: 100%; margin: 4px 0; font-size: .82rem; }