/* Kontor – ruhig, klar, iPad-tauglich. Dunkelblauer Kopf, Mandantenfarbe als Streifen. */
:root {
  --navy: #0b1f3a;
  --navy-2: #13294b;
  --navy-3: #1e3a64;
  --text: #17202c;
  --leise: #5b6676;
  --linie: #dfe4ea;
  --flaeche: #f4f6f9;
  --karte: #ffffff;
  --akzent: #1d4ed8;
  --ok: #16794a;
  --warn: #a15c00;
  --fehler: #b42318;
  --mandant: #1d4ed8;
  --radius: 10px;
  --schatten: 0 1px 2px rgba(16, 24, 40, .06), 0 1px 3px rgba(16, 24, 40, .08);
  font-size: 16px;
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Roboto, "Helvetica Neue", Arial, sans-serif;
  color: var(--text); background: var(--flaeche); line-height: 1.45;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--akzent); text-decoration: none; }
a:hover { text-decoration: underline; }
h1 { font-size: 1.6rem; margin: 0 0 .75rem; letter-spacing: -.01em; }
h2 { font-size: 1.1rem; margin: 1.25rem 0 .6rem; }
.karte > h2:first-child, .karte-kopf h2 { margin-top: 0; }
code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .88em; background: #eef1f5; padding: .1em .35em; border-radius: 4px; }
.unsichtbar { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.leise { color: var(--leise); }
.klein { font-size: .85rem; }
.mitte { text-align: center; }

/* Kopf */
.kopf { background: var(--navy); color: #fff; position: sticky; top: 0; z-index: 10; }
.kopf-innen { display: flex; align-items: center; gap: 1rem; padding: .6rem 1.25rem; min-height: 60px; }
.marke { color: #fff; font-weight: 700; font-size: 1.15rem; display: flex; align-items: center; gap: .55rem; }
.marke:hover { text-decoration: none; }
.marke-zeichen {
  display: inline-grid; place-items: center; width: 32px; height: 32px; border-radius: 8px;
  background: #fff; color: var(--navy); font-weight: 800;
}
.mandant-streifen { height: 4px; background: var(--mandant); }
.mandant-wahl { display: flex; align-items: center; gap: .5rem; background: var(--navy-2); border-radius: 999px; padding: .2rem .4rem .2rem .75rem; }
.mandant-punkt, .farbpunkt { width: 12px; height: 12px; border-radius: 50%; background: var(--mandant); display: inline-block; flex: none; }
.mandant-wahl select { background: transparent; color: #fff; border: 0; font: inherit; font-weight: 600; padding: .4rem .3rem; min-height: 40px; }
.mandant-wahl select option { color: var(--text); }
.suche { flex: 1; max-width: 560px; }
.suche input { width: 100%; border: 0; border-radius: 8px; padding: .6rem .8rem; background: var(--navy-3); color: #fff; font: inherit; min-height: 42px; }
.suche input::placeholder { color: #aebbd0; }
.kopf-rechts { margin-left: auto; display: flex; align-items: center; gap: 1rem; }
.benutzer-name { color: #dbe4f3; }
.kopf .knopf-link { color: #dbe4f3; }

/* Rahmen */
.rahmen { display: grid; grid-template-columns: 220px 1fr; min-height: calc(100vh - 64px); }
.navi { background: #fff; border-right: 1px solid var(--linie); padding: 1rem .6rem; display: flex; flex-direction: column; gap: 2px; }
.navi a { color: var(--text); padding: .65rem .8rem; border-radius: 8px; font-weight: 500; }
.navi a:hover { background: var(--flaeche); text-decoration: none; }
.navi a.aktiv { background: #e8eef9; color: var(--navy); font-weight: 650; box-shadow: inset 3px 0 0 var(--mandant); }
.navi-trenner { height: 1px; background: var(--linie); margin: .6rem .4rem; }
.navi-fuss { margin-top: auto; color: var(--leise); font-size: .78rem; padding: .8rem; }
.inhalt { padding: 1.5rem 2rem 3rem; max-width: 1280px; width: 100%; }

/* Bausteine */
.seitenkopf { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; margin-bottom: 1rem; }
.seitenkopf h1 { margin-bottom: .2rem; }
.karte { background: var(--karte); border: 1px solid var(--linie); border-radius: var(--radius); padding: 1.25rem 1.4rem; box-shadow: var(--schatten); margin-bottom: 1.25rem; }
.karte.ohne-rand { padding: 0; overflow-x: auto; }
.karte.innen { box-shadow: none; }
.karte.schmal { max-width: 440px; margin: 0 auto; }
.karte-kopf { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: .6rem; }
.spalten { display: grid; grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)); gap: 1.25rem; }
.spalten > .karte { margin-bottom: 0; }
.spalten + .karte, .kacheln + .spalten { margin-top: 1.25rem; }

.kacheln { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: .9rem; margin-bottom: 1.25rem; }
.kachel { background: #fff; border: 1px solid var(--linie); border-radius: var(--radius); padding: 1rem 1.1rem; display: flex; flex-direction: column; gap: .2rem; color: var(--text); box-shadow: var(--schatten); min-height: 108px; }
.kachel:hover { text-decoration: none; border-color: #c4cdd9; }
.kachel-titel { color: var(--leise); font-size: .88rem; font-weight: 550; }
.kachel-wert { font-size: 1.9rem; font-weight: 700; letter-spacing: -.02em; }
.kachel.leer .kachel-wert { color: #b3bcc8; }
.kachel-hinweis { font-size: .75rem; color: var(--leise); }

.aufgaben, .shopliste, .liste-klein, .punkte { list-style: none; margin: 0; padding: 0; }
.aufgabe { padding: .7rem 0; border-bottom: 1px solid var(--linie); display: flex; gap: .6rem; align-items: flex-start; justify-content: space-between; }
.aufgabe:last-child { border-bottom: 0; }
.aufgabe a { color: var(--text); }
.aufgabe.wichtig a { font-weight: 600; }
.shopliste li { display: flex; align-items: center; justify-content: space-between; gap: .8rem; padding: .65rem 0; border-bottom: 1px solid var(--linie); }
.shopliste li:last-child { border-bottom: 0; }
.shopliste a { display: flex; flex-direction: column; color: var(--text); }
.shop-name { font-weight: 600; }
.liste-klein li { padding: .45rem 0; border-bottom: 1px solid var(--linie); }
.liste-klein li:last-child { border-bottom: 0; }
.punkte li { padding: .3rem 0 .3rem 1.2rem; position: relative; }
.punkte li::before { content: ""; position: absolute; left: .2rem; top: .8rem; width: 6px; height: 6px; border-radius: 50%; background: var(--mandant); }

.marker { display: inline-block; font-size: .72rem; font-weight: 650; padding: .15rem .5rem; border-radius: 999px; background: #e8eef9; color: var(--navy-3); white-space: nowrap; }
.marker.warn { background: #fff4e0; color: var(--warn); }
.status { font-size: .8rem; font-weight: 650; padding: .25rem .6rem; border-radius: 999px; white-space: nowrap; }
.s-geplant { background: #eef1f5; color: var(--leise); }
.s-wartung { background: #fff4e0; color: var(--warn); }
.s-aktiv { background: #e3f5ea; color: var(--ok); }
.s-urlaub { background: #e8eef9; color: var(--navy-3); }

.tabelle { width: 100%; border-collapse: collapse; font-size: .94rem; }
.tabelle th { text-align: left; font-size: .78rem; text-transform: uppercase; letter-spacing: .04em; color: var(--leise); font-weight: 650; padding: .75rem 1rem; border-bottom: 1px solid var(--linie); background: #fafbfc; }
.tabelle td { padding: .75rem 1rem; border-bottom: 1px solid var(--linie); vertical-align: top; }
.tabelle tr:last-child td { border-bottom: 0; }
.tabelle.kompakt td { padding: .45rem .3rem; }
.tabelle .zeit { white-space: nowrap; color: var(--leise); }
.tabelle .details { font-size: .82rem; max-width: 380px; overflow-wrap: anywhere; }
.tabelle.rollen th { text-transform: none; letter-spacing: 0; font-size: .8rem; }
.tabelle.rollen input { width: 22px; height: 22px; }

/* Formulare */
.formular fieldset { border: 0; padding: 0; margin: 0; }
.raster { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: .9rem 1.1rem; }
.raster .breit { grid-column: span 2; }
label { display: flex; flex-direction: column; gap: .3rem; font-weight: 550; font-size: .9rem; margin-bottom: .9rem; }
.raster label { margin-bottom: 0; }
input, select, textarea { font: inherit; font-weight: 400; color: var(--text); border: 1px solid #c9d1dc; border-radius: 8px; padding: .65rem .75rem; background: #fff; min-height: 46px; }
input[type=color] { padding: .2rem; width: 80px; }
input:focus, select:focus, textarea:focus { outline: 3px solid #bcd0fb; border-color: var(--akzent); }
input:disabled, fieldset:disabled input, fieldset:disabled select, fieldset:disabled textarea { background: #f1f3f6; color: var(--leise); }
label.haken { flex-direction: row; align-items: center; gap: .65rem; font-weight: 500; }
label.haken input { width: 22px; height: 22px; min-height: 0; }
.haken-liste { display: grid; gap: .2rem; margin-bottom: 1rem; }
.code-feld { font-size: 1.5rem; letter-spacing: .3em; text-align: center; font-variant-numeric: tabular-nums; }
.aktionen { margin-top: 1.2rem; display: flex; gap: .8rem; }
.knopfreihe { display: flex; flex-wrap: wrap; gap: .6rem; }

.knopf { display: inline-flex; align-items: center; justify-content: center; gap: .4rem; border: 0; border-radius: 8px; background: var(--navy); color: #fff; font: inherit; font-weight: 600; padding: .7rem 1.15rem; min-height: 46px; cursor: pointer; }
.knopf:hover { background: var(--navy-3); text-decoration: none; }
.knopf.gross { padding: .85rem 1.6rem; min-height: 52px; font-size: 1.02rem; }
.knopf.klein { padding: .45rem .8rem; min-height: 38px; font-size: .88rem; }
.knopf.voll { width: 100%; }
.knopf.zweit { background: #fff; color: var(--navy); border: 1px solid #c9d1dc; }
.knopf.zweit:hover { background: var(--flaeche); }
.knopf-link { background: none; border: 0; color: var(--akzent); font: inherit; cursor: pointer; padding: .4rem; }

.meldung { border-radius: 8px; padding: .8rem 1rem; margin-bottom: 1rem; background: #e8eef9; color: var(--navy); }
.meldung.ok { background: #e3f5ea; color: var(--ok); font-weight: 550; }
.meldung.fehler { background: #fdecea; color: var(--fehler); }
.meldung ul { margin: 0; padding-left: 1.2rem; }

/* Einzelseiten (Anmeldung) */
.einzeln { min-height: 100vh; padding: 8vh 1rem 2rem; background: var(--navy); }
.einzeln-marke { color: #fff; font-weight: 700; font-size: 1.4rem; display: flex; align-items: center; gap: .6rem; justify-content: center; margin-bottom: 1.5rem; }
.einzeln-unter { font-weight: 400; color: #aebbd0; font-size: 1rem; }
.einzeln .karte { padding: 1.75rem; }
.unter-karte { text-align: center; margin-top: .8rem; }
.unter-karte .knopf-link { color: #dbe4f3; }
.qr { display: flex; justify-content: center; margin: .5rem 0 1rem; }
.qr svg { width: 210px; height: 210px; }
.schritte { padding-left: 1.2rem; margin: .5rem 0; }
.umbruch { overflow-wrap: anywhere; }
.passwort-anzeige code { font-size: 1.4rem; padding: .4rem .8rem; user-select: all; }

/* iPad hochkant und kleiner */
@media (max-width: 960px) {
  .rahmen { grid-template-columns: 1fr; }
  .navi { flex-direction: row; overflow-x: auto; border-right: 0; border-bottom: 1px solid var(--linie); padding: .5rem; }
  .navi a { white-space: nowrap; }
  .navi-trenner, .navi-fuss { display: none; }
  .kopf-innen { flex-wrap: wrap; }
  .suche { order: 5; flex-basis: 100%; max-width: none; }
  .inhalt { padding: 1.2rem 1rem 2rem; }
  .raster .breit { grid-column: auto; }
}
