/* Haus-App - gemeinsame Gestaltung (Anmeldung, Startseite, Konto, Verwaltung) */
:root {
  --bg: #f4f2ec; --flaeche: #ffffff; --text: #2c2c2a; --text2: #5f5e5a;
  --rand: #d3d1c7; --akzent: #185fa5; --akzent-text: #ffffff;
  --fehler: #a32d2d; --fehler-bg: #fcebeb; --ok: #3b6d11; --ok-bg: #eaf3de;
  --hinweis-bg: #faeeda; --hinweis: #633806;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #1f1f1d; --flaeche: #2c2c2a; --text: #f1efe8; --text2: #b4b2a9;
    --rand: #5f5e5a; --akzent: #85b7eb; --akzent-text: #042c53;
    --fehler: #f09595; --fehler-bg: #501313; --ok: #c0dd97; --ok-bg: #173404;
    --hinweis-bg: #412402; --hinweis: #fac775;
  }
}
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body { font-family: system-ui, -apple-system, "Segoe UI", sans-serif; font-size: 16px;
       line-height: 1.5; background: var(--bg); color: var(--text); }
h1 { font-size: 1.5rem; font-weight: 600; margin: 0 0 .25rem; }
h2 { font-size: 1.15rem; font-weight: 600; margin: 0 0 .75rem; }
p { margin: 0 0 .75rem; }
a { color: var(--akzent); }
.leise { color: var(--text2); }

/* Kopfzeile */
.kopf { display: flex; flex-wrap: wrap; align-items: center; gap: .75rem;
        padding: .75rem 1rem; background: var(--flaeche); border-bottom: 1px solid var(--rand); }
.kopf .titel { font-weight: 600; font-size: 1.1rem; margin-right: auto; text-decoration: none; color: var(--text); }
.kopf nav { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; }
.kopf .wer { color: var(--text2); font-size: .9rem; }

/* Inhalt */
.inhalt { max-width: 60rem; margin: 0 auto; padding: 1.5rem 1rem 3rem; }
.mitte { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 1rem; }
.karte { background: var(--flaeche); border: 1px solid var(--rand); border-radius: 12px;
         padding: 1.5rem; margin-bottom: 1.25rem; }
.karte.schmal { width: 100%; max-width: 24rem; margin: 0; }

/* Formulare */
label { display: block; font-size: .9rem; margin: .75rem 0 .25rem; }
input[type=email], input[type=password], input[type=text] {
  width: 100%; padding: .6rem .7rem; font: inherit; color: var(--text);
  background: var(--bg); border: 1px solid var(--rand); border-radius: 8px; }
input:focus-visible, button:focus-visible, a:focus-visible { outline: 2px solid var(--akzent); outline-offset: 2px; }
.haken { display: flex; align-items: center; gap: .5rem; margin: .9rem 0 0; font-size: .95rem; }
.haken input { width: 1.1rem; height: 1.1rem; }
.zeile { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: 1.1rem; }
button, .knopf { font: inherit; padding: .55rem .9rem; border-radius: 8px; cursor: pointer;
  border: 1px solid var(--rand); background: var(--flaeche); color: var(--text); text-decoration: none; display: inline-block; }
button.haupt { background: var(--akzent); border-color: var(--akzent); color: var(--akzent-text); font-weight: 600; }
button.gefahr { color: var(--fehler); border-color: var(--fehler); }
button.klein, .knopf.klein { padding: .3rem .6rem; font-size: .88rem; }
button:disabled { opacity: .55; cursor: default; }

/* Meldungen */
.meldung { padding: .6rem .8rem; border-radius: 8px; margin: .9rem 0 0; font-size: .95rem; }
.meldung.fehler { background: var(--fehler-bg); color: var(--fehler); }
.meldung.ok { background: var(--ok-bg); color: var(--ok); }
.meldung.hinweis { background: var(--hinweis-bg); color: var(--hinweis); }
.meldung code { font-size: 1.05rem; font-weight: 600; user-select: all; }
[hidden] { display: none !important; }

/* Tabelle der Benutzer */
.tabelle-huelle { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: .55rem .5rem; border-bottom: 1px solid var(--rand); vertical-align: top; }
th { font-size: .85rem; font-weight: 600; color: var(--text2); }
td .aktionen { display: flex; flex-wrap: wrap; gap: .35rem; }
.marke { display: inline-block; font-size: .78rem; padding: .1rem .45rem; border-radius: 999px;
         background: var(--hinweis-bg); color: var(--hinweis); margin-left: .35rem; }
.marke.rot { background: var(--fehler-bg); color: var(--fehler); }

/* Dialog "Neues Passwort" */
dialog { border: 1px solid var(--rand); border-radius: 12px; padding: 1.5rem; width: min(26rem, 92vw);
         background: var(--flaeche); color: var(--text); }
dialog::backdrop { background: rgba(0, 0, 0, .45); }
