/* preisspiegel.css — Ergänzungen für „Preisspiegel im Bau“. Farben nur aus auswertung.css. */

html, body { overflow-x: clip; }
html { overflow-x: clip; }

/* Tastatur: sichtbarer Rahmen an allem, was sich bedienen lässt */
:focus-visible { outline: 2px solid var(--akzent); outline-offset: 2px; }
.knopf:focus-visible, a:focus-visible, button:focus-visible, select:focus-visible, input:focus-visible,
.tabelle-huelle:focus-visible { outline: 2px solid var(--akzent); outline-offset: 2px; border-radius: 6px; }
.ablage:focus-within { border-color: var(--akzent); }
.ablage label.knopf:focus-within { outline: 2px solid var(--akzent); outline-offset: 2px; }

/* das hidden-Attribut muss auch bei Knöpfen und Karten mit display gelten */
main [hidden] { display: none !important; }

.ps-hinweis { margin: -12px 0 20px; padding: 10px 14px; border-radius: 10px; background: var(--flaeche-2); color: var(--text-2); font-size: 14px; }
.ps-hinweis b { color: var(--text-1); font-weight: 620; }
.ps-feld { display: inline-flex; align-items: center; gap: 6px; flex-wrap: wrap; max-width: 100%; }
.ps-feld select { max-width: 100%; }
.ps-neben { font-size: 13px; color: var(--text-3); }
.filter { margin-top: 4px; }

@media (max-width: 520px) {
  #kennzahlen { grid-template-columns: 1fr 1fr; }
  #kennzahlen .kz { padding: 12px 12px 14px; min-width: 0; }
  #kennzahlen .kz .kz-wert { font-size: 21px; }
  .karte { padding: 16px 14px 12px; }
}
.kz .kz-neben { overflow-wrap: anywhere; }

/* eigene Diagramme */
.dia .ps-name { fill: var(--text-1); font-size: 12px; font-weight: 600; }
.dia .ps-unter { fill: var(--text-2); font-size: 11px; }
.dia .ps-spur { stroke: var(--raster); stroke-width: 1; }
.dia .ps-null { stroke: var(--text-3); stroke-width: 1; }
.dia .ps-marke { stroke: var(--text-1); stroke-width: 1.5; stroke-dasharray: 4 3; }
.dia .ps-marke-text { fill: var(--text-1); font-size: 11px; font-weight: 600; }
.dia .ps-punkt { stroke: var(--flaeche-1); stroke-width: 1.5; }
.dia .ps-punkt.auff { stroke: var(--text-1); stroke-width: 2; }
.dia .ps-rand { fill: var(--text-2); font-size: 11px; font-weight: 600; }
.dia .ps-zeile:hover .ps-spur { stroke: var(--linie); }

/* Regler */
.ps-regler { padding: 10px 0; border-top: 1px solid var(--raster); }
.ps-regler:first-child { border-top: 0; padding-top: 0; }
.ps-regler label, .ps-regler .ps-rname { display: block; font-size: 14px; font-weight: 620; color: var(--text-1); }
.ps-regler .ps-kipp { display: block; font-size: 13px; font-weight: 400; color: var(--text-2); margin-top: 1px; }
.ps-zug { display: grid; grid-template-columns: 1fr 5.2em; align-items: center; gap: 10px; }
.ps-zug input[type=range] { width: 100%; min-height: 44px; margin: 0; accent-color: var(--akzent); background: transparent; cursor: pointer; }
.ps-zug output { text-align: right; font-weight: 650; font-size: 15px; }
.ps-regler select.feld { width: 100%; margin-top: 6px; }
.ps-haken { display: flex; align-items: flex-start; gap: 10px; min-height: 44px; padding: 10px 0; border-top: 1px solid var(--raster); font-size: 14px; cursor: pointer; }
.ps-haken input { width: 20px; height: 20px; margin: 1px 0 0; flex: none; accent-color: var(--akzent); }
.ps-haken small { display: block; color: var(--text-2); font-size: 13px; }
.ps-knoepfe { display: flex; flex-wrap: wrap; gap: 8px; padding-top: 12px; border-top: 1px solid var(--raster); }

.ps-urteil { margin: 12px 0 0; font-size: 15px; color: var(--text-1); }
.ps-urteil .status { font-size: 13px; margin-right: 6px; }

/* Rechenprüfung */
.ps-liste { list-style: none; margin: 14px 0 0; padding: 0; display: grid; gap: 6px; font-size: 14px; color: var(--text-2); }
.ps-liste li { display: flex; flex-wrap: wrap; gap: 4px 10px; align-items: baseline; }
.ps-liste b { color: var(--text-1); font-weight: 620; }

/* Preisspiegel-Tabelle */
.ps-zeichen { display: flex; flex-wrap: wrap; gap: 4px 18px; margin: 0 0 10px; font-size: 13px; color: var(--text-2); }
.ps-zeichen b { color: var(--text-1); display: inline-block; min-width: 1em; }
.ps-huelle { max-height: 620px; position: relative; }   /* relative: die nur vorgelesenen Wörter in den Zellen bleiben im Scrollkasten */
table.ps-tab td, table.ps-tab th { padding: 6px 9px; }
table.ps-tab td.ps-text { white-space: normal; min-width: 200px; max-width: 320px; }
table.ps-tab .ps-min { font-weight: 700; color: var(--text-1); }
table.ps-tab .ps-min b, table.ps-tab .ps-max b, table.ps-tab .ps-auff b { font-weight: 700; margin-right: 3px; }
table.ps-tab .ps-max { color: var(--text-2); }
table.ps-tab .ps-auff b { margin: 0 0 0 3px; color: var(--kritisch-text); }
table.ps-tab .ps-ohne { color: var(--kritisch-text); font-weight: 600; }
table.ps-tab tr.ps-lg th { position: static; background: var(--flaeche-2); color: var(--text-1); font-weight: 650; text-align: left; }
table.ps-tab tr.ps-lg td { background: var(--flaeche-2); font-weight: 600; }
table.ps-tab tr.ps-summe td, table.ps-tab tr.ps-summe th { position: static; background: var(--flaeche-1); border-top: 2px solid var(--linie); font-weight: 650; color: var(--text-1); text-align: right; }
table.ps-tab tr.ps-summe th { text-align: left; }
table.ps-tab tr.ps-neben-zeile td, table.ps-tab tr.ps-neben-zeile th { position: static; background: var(--flaeche-1); font-weight: 400; color: var(--text-2); text-align: right; }
table.ps-tab tr.ps-neben-zeile th { text-align: left; }
.ps-art { display: inline-block; margin-left: 6px; padding: 0 6px; border-radius: 999px; border: 1px solid var(--linie); font-size: 11px; font-weight: 600; color: var(--text-2); white-space: nowrap; }
.ps-farbe { display: inline-block; width: 9px; height: 9px; border-radius: 3px; margin-right: 6px; vertical-align: baseline; }

/* Tabellen mit langen Texten */
#d-auffliste td:nth-child(2), #d-rechen td:nth-child(3) { white-space: normal; min-width: 200px; max-width: 340px; }

/* Handy: Hinweis aufs seitliche Schieben, schmalere Textspalte */
.ps-wisch { display: none; margin: 0 0 8px; font-size: 13px; color: var(--text-3); }
@media (max-width: 720px) {
  .ps-wisch { display: block; }
  table.ps-tab td.ps-text { min-width: 150px; }
  #d-auffliste td:nth-child(2), #d-rechen td:nth-child(3) { min-width: 150px; }
}

/* Zustände der Knöpfe, lange Wörter in Überschriften */
.knopf:active, .tabelle-knopf:active, .wahl button:active { transform: translateY(1px); }
.knopf:disabled, .knopf[aria-disabled="true"] { opacity: .5; cursor: not-allowed; }
#vorlage { white-space: nowrap; }
.a-titel h1, .abschnitt > h2, .karte-kopf h2 { overflow-wrap: break-word; text-wrap: balance; }

/* Verweis auf „Datei erkennen lassen“ */
.erkennen-satz { display: block; margin-top: 6px; font-size: 14px; color: var(--text-2); }
.erkennen-satz a { color: var(--akzent); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }
