/* Ergänzungen zur stil.css des Instrumentenkoffers.
   stil.css bleibt unverändert und wird beim Bauen aus dem Koffer-Projekt kopiert;
   alles, was nur diese Website braucht, steht hier. */

/* ------------------------------------------------------------ Silbentrennung */

/* Deutsche Silbentrennung im Fliesstext, am Bildschirm und im Druck. Sie braucht
   lang="de" am html-Element. Überschriften und Links bleiben ungetrennt. */
p, li, .anriss, .legende, .kennzeile {
  -webkit-hyphens: auto;
  hyphens: auto;
  hyphenate-limit-chars: 8 4 4;
}
h1, h2, h3, a, strong { -webkit-hyphens: manual; hyphens: manual; }

/* ------------------------------------------------------------ Kleine Geräte */

/* Sechs Reiter brauchen auf dem Handy drei Zeilen; enger setzen, damit der Kopf
   nicht den halben Bildschirm füllt. */
@media (max-width: 640px) {
  .haupt-nav { gap: 0.35rem 1rem; }
  .marke-neben { max-width: 15rem; }
}

/* ------------------------------------------------------------ Einleitung, Leitsatz */

.anriss { font-style: italic; }
.anriss em { font-style: normal; }

.leitsatz {
  font-weight: 300;
  color: var(--titel);
  font-size: 1.1rem;
  line-height: 1.6;
  margin: 1.8rem 0;
  padding-left: 1.1rem;
  border-left: 3px solid var(--akzent);
}

/* ------------------------------------------------------------ Kennzeile und Legende */

/* Die Kennzeile selbst kommt aus stil.css (Kasten mit blauer Kante). */
.kennzeile { margin-top: -0.4rem; }
.kennwert { display: flex; flex-direction: column; gap: 0.15rem; }
.kennwert.breit { flex-basis: 100%; }
.kennzeile a { color: var(--text); text-decoration: none; border-bottom: 1px solid var(--linie); }
.kennzeile a:hover { color: var(--akzent-tief); border-bottom-color: var(--akzent); }
.kennzeile .trenner { color: var(--text-leise); padding: 0 0.35rem; }

.legende {
  margin: 0 0 2.4rem;
  padding: 0 0 0 1.1rem;
  border-left: 3px solid var(--linie);
  font-size: 0.86rem;
  line-height: 1.6;
  color: var(--text-leise);
}

.legende p { margin: 0 0 0.5rem; }
.legende strong { font-weight: 500; color: var(--text); }
.legende a { white-space: nowrap; }

/* ------------------------------------------------------------ Verweiszeilen */

.verweise { margin: -0.3rem 0 1.6rem; }

.verweis {
  margin: 0 0 0.35rem;
  font-size: 0.95rem;
}

.verweis a { text-decoration: none; border-bottom: 1px solid var(--linie); }
.verweis a:hover { border-bottom-color: var(--akzent-tief); }

.offen-verweis { color: #a0522d; }

/* ------------------------------------------------------------ Offene Stellen */

mark.offen {
  background: #fff1b8;
  color: #7a4b00;
  padding: 0 0.25em;
  border-radius: 3px;
  font-weight: 400;
}

/* ------------------------------------------------------------ Listen */

ol { margin: 0 0 1.3rem; padding-left: 1.6rem; list-style: decimal; }
ol li { padding-left: 0.3rem; }
ol li::before { content: none; }
ol li::marker { color: var(--akzent-tief); }

.anmerkung {
  display: block;
  margin-top: 0.3rem;
  font-size: 0.93rem;
  color: var(--text-leise);
}

/* ------------------------------------------------------------ Kapitelübersicht */

.kapitel-liste { display: flex; flex-direction: column; gap: 0.6rem; margin-top: 1.2rem; }

.kapitel-zeile {
  display: flex;
  gap: 1.1rem;
  align-items: flex-start;
  padding: 1rem 1.2rem;
  background: #fff;
  border: 1px solid var(--linie);
  border-radius: var(--rundung);
  box-shadow: var(--schatten);
  text-decoration: none;
  color: var(--text);
  transition: border-color 0.15s, box-shadow 0.15s;
}

.kapitel-zeile:hover { border-color: var(--akzent); box-shadow: var(--schatten-erhoben); }

.kapitel-nr {
  flex: none;
  width: 2.1rem;
  height: 2.1rem;
  border-radius: 50%;
  background: var(--papier-tief);
  border: 1px solid var(--linie);
  color: var(--titel);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 400;
  margin-top: 0.1rem;
}

.kapitel-text { display: flex; flex-direction: column; gap: 0.2rem; }
.kapitel-name { color: var(--titel); font-size: 1.05rem; }
.kapitel-anriss { font-size: 0.9rem; color: var(--text-leise); line-height: 1.55; }

/* ------------------------------------------------------------ Drei Kästen auf der Startseite */

.wege { grid-template-columns: repeat(3, 1fr); gap: 0.8rem; margin: 2rem 0 2.6rem; }
.weg { padding: 1.1rem 1.15rem; }
@media (max-width: 40rem) { .wege { grid-template-columns: 1fr; } }
.weg h3 { font-size: 1.08rem; }
.weg h3::after { content: " →"; color: var(--akzent); }
.weg p { color: var(--text-leise); line-height: 1.6; }

/* ------------------------------------------------------------ Karten */

.karte .karte-felder { font-size: 0.78rem; color: var(--akzent); letter-spacing: 0.04em; margin-top: auto; }
.kapitel-text .karte-felder { font-size: 0.78rem; color: var(--akzent); letter-spacing: 0.04em; margin-top: 0.3rem; }

/* ------------------------------------------------------------ Blättern */

/* Zurück und Weiter auf einer Höhe, die Übersicht mittig darunter */
.blaettern { flex-direction: column; align-items: stretch; gap: 0.9rem; }
.blaettern-zeile { display: flex; justify-content: space-between; gap: 1.5rem; }
.blaettern-zeile .weiter { margin-left: auto; text-align: right; }
.blaettern .mitte { align-self: center; color: var(--text-leise); }
.blaettern .mitte:hover { color: var(--akzent-tief); }
@media (max-width: 640px) {
  .blaettern-zeile { flex-direction: column; gap: 0.5rem; }
  .blaettern-zeile .weiter { margin-left: 0; text-align: left; }
}

/* ------------------------------------------------------------ Drucken */

.druckkopf { display: none; }

.kennwert.drucken { flex-basis: auto; margin-left: auto; justify-content: flex-end; }

.drucken button {
  font: inherit;
  font-size: 0.88rem;
  color: var(--akzent-tief);
  background: #fff;
  border: 1px solid var(--linie);
  border-radius: var(--rundung);
  padding: 0.35rem 0.8rem;
  cursor: pointer;
}

.drucken button:hover { border-color: var(--akzent); color: var(--titel); }

@media print {
  /* Druckfassung der Hilfsmittel: schwarz auf weiss, normale Schriftstärke, engere
     Zeilen, schlichte Kennzeile, keine verwaisten Überschriften. Eingerichtet nach dem
     Testausdruck vom 18.09.2026. */
  @page {
    size: A4;
    margin: 16mm 20mm 18mm 20mm;
    @bottom-right {
      content: "Seite " counter(page) " von " counter(pages);
      font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
      font-size: 8.5pt;
      color: #666;
    }
  }
  .legende, .drucken, .fuss, .blaettern { display: none; }
  /* Verweiszeilen bleiben im Druck als Text stehen, damit ein Team auf Papier sieht,
     welches Hilfsmittel und welche Frage dazugehören. */
  .verweise { margin: -0.2rem 0 0.8rem; }
  .verweis { font-size: 9pt; color: #444; margin: 0 0 0.15rem; }
  .verweis a { border-bottom: none; }
  html, body { background: #fff; }
  body { color: #111; font-weight: 400; font-size: 10pt; line-height: 1.42; }
  main.innen { padding: 0; max-width: 16.5cm; margin: 0; }
  .druckkopf {
    display: block;
    font-size: 8.5pt;
    color: #666;
    border-bottom: 1px solid #bbb;
    padding-bottom: 0.25rem;
    margin-bottom: 1rem;
  }
  h1 { color: #000; font-weight: 400; font-size: 18pt; line-height: 1.2; margin: 0 0 0.5rem; }
  h2 { color: #000; font-weight: 600; font-size: 11.5pt; margin: 1.1rem 0 0.35rem; }
  h3 { color: #000; font-weight: 600; font-size: 10.5pt; margin: 0.8rem 0 0.25rem; }
  h1, h2, h3 { break-after: avoid-page; page-break-after: avoid; }
  p, li { orphans: 3; widows: 3; }
  p { margin: 0 0 0.55rem; }
  ul, ol { margin: 0 0 0.7rem; }
  li { margin-bottom: 0.3rem; }
  li::before { background: #555; opacity: 1; top: 0.6em; }
  strong { color: #000; font-weight: 600; }
  .anriss { font-size: 10pt; line-height: 1.42; color: #333; margin: 0 0 0.8rem; }
  .leitsatz { color: #000; border-left-color: #999; }
  .kennzeile {
    background: none;
    box-shadow: none;
    border-left: 2px solid #999;
    border-radius: 0;
    padding: 0.2rem 0 0.2rem 0.8rem;
    margin: 0 0 1rem;
    font-size: 9pt;
    gap: 0.15rem 1.4rem;
  }
  .kennname { color: #666; font-size: 7.5pt; }
  .kennzeile a { border-bottom: none; color: #111; }
  .kennzeile .trenner { color: #666; }
  .anmerkung { color: #444; }
  mark.offen { background: none; color: inherit; }
  a { color: inherit; text-decoration: none; }
}
