/* AFU-438 (SW-8): Übersicht der Schaltungs-Werkstatt, Fortschritt in der Leiste, Karte nach dem Lösen (Mockup 234).
   Werkbank und Leiste selbst in werkbank.css. Präfix sw-. */

.sw-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------------------------------------------------------------- Stand */
.sw-stand { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 1rem 1.6rem; align-items: center; margin: 0 0 1.2rem; }
.sw-stand p { margin: 0; }
.sw-stand-xp span { display: block; font-size: 2rem; font-weight: 700; line-height: 1.1; font-family: ui-monospace, Menlo, Consolas, monospace; color: #f5b942; }
@media (prefers-color-scheme: light) { .sw-stand-xp span { color: #a86e00; } }
.sw-stand-xp small { display: block; color: var(--muted); font-size: 0.88rem; margin-top: 0.2rem; }
.sw-stand-mitte .field-hint { margin-top: 0.4rem; display: block; }
.sw-stand-weiter .btn { white-space: nowrap; }
.sw-fertig { font-weight: 600; color: #3ecf8e; }
@media (prefers-color-scheme: light) { .sw-fertig { color: #137a4b; } }
.sw-balken.gross { display: block; width: auto; height: 10px; border-radius: 5px; }
@media (max-width: 760px) {
  .sw-stand { grid-template-columns: minmax(0, 1fr); }
  .sw-stand-weiter .btn { display: block; text-align: center; white-space: normal; }
}

/* ---------------------------------------------------------------- Filter */
.sw-filter { display: flex; flex-wrap: wrap; align-items: center; gap: 0.6rem 1.6rem; margin: 0 0 1rem; }
.sw-filter-gruppe { display: flex; align-items: center; gap: 0.6rem; }
.sw-filter-titel { font-size: 0.85rem; color: var(--muted); }
.sw-seg button { flex: 0 0 auto; min-width: 2.6rem; padding: 6px 12px; font-size: 0.88rem; }

/* ---------------------------------------------------------------- Themen */
.sw-themen { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 21rem), 1fr)); gap: 1rem; }
.sw-thema-karte { margin: 0; }
.sw-thema-karte h3 { margin: 0 0 0.4rem; font-size: 1.02rem; display: flex; justify-content: space-between; gap: 1rem; }
.sw-thema-karte h3 span { color: var(--muted); font-weight: 400; font-size: 0.85rem; white-space: nowrap; }
.sw-thema-karte .sw-balken { display: block; width: auto; margin: 0 0 0.8rem; }
.sw-level { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 0.4rem; }
.sw-marke { display: inline-flex; align-items: center; gap: 0.3rem; font: 0.85rem ui-monospace, Menlo, Consolas, monospace;
  padding: 0.3rem 0.55rem; min-height: 2rem; box-sizing: border-box; border-radius: 7px; border: 1px solid var(--border);
  color: var(--fg); text-decoration: none; background: color-mix(in srgb, var(--border) 25%, transparent); }
a.sw-marke:hover { border-color: var(--accent); }
a.sw-marke:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.sw-marke.ok { border-color: #3ecf8e; background: color-mix(in srgb, #3ecf8e 13%, transparent); }
.sw-marke.stern { border-color: #e8b840; background: color-mix(in srgb, #e8b840 15%, transparent); }
.sw-marke.weiter { outline: 2px solid var(--accent); outline-offset: 1px; }
.sw-zeichen { font-size: 0.8rem; }
.sw-marke.stern .sw-zeichen { color: #e8b840; }
@media (prefers-color-scheme: light) { .sw-marke.stern .sw-zeichen { color: #9a6c00; } }
.sw-legende { list-style: none; padding: 0; margin: 1.2rem 0 0; display: flex; flex-wrap: wrap; gap: 0.5rem 1.4rem; font-size: 0.88rem; color: var(--muted); }
.sw-legende .sw-marke { font-size: 0.75rem; min-height: 0; padding: 0 0.35rem; margin-right: 0.2rem; }

/* ---------------------------------------------------------------- Leiste im Level */
.sw-zurueck { text-decoration: none; }
.sw-thema { font-weight: 600; }
.sw-platz { color: var(--muted); font-size: 0.9rem; }
.sw-leiste .sw-auftrag { font-weight: 400; color: var(--muted); font-size: 0.9rem; }

/* ---------------------------------------------------------------- Karte nach dem Lösen */
.sw-geloest .sw-geloest-xp { margin-top: 0.4rem; }
.sw-geloest-satz { color: var(--muted); }
.sw-orden { display: inline-flex; gap: 0.3rem; align-items: center; border: 1px solid #e8b840; border-radius: 999px; padding: 0.05rem 0.6rem;
  font-size: 0.85rem; background: color-mix(in srgb, #e8b840 15%, transparent); }
.sw-geloest-knoepfe { margin: 0.7rem 0 0; }
.sw-geloest-knoepfe .btn-sm { text-decoration: none; }
