/* SRM-Demo - Farben wie SRM-Server/-Client (srmui.pas): Anthrazit-Kopf, Orange als Akzent, helles Grau als Grund */
:root {
  --bg:#f4f5f7; --card:#fff; --text:#1f2328; --muted:#6b6f75; --line:#c9cdd3; --soft:#eef0f2; --head:#eceef1;
  --dark:#2b3038; --dark2:#3a414b; --darkline:#687480; --headtext:#aab2bd;
  --accent:#f08a24; --accent-d:#d97410; --accent-t:#a85a06; --accent2:#fde8d0;
  --green:#2e9e5b; --green-t:#1c7a43; --greenbg:#e5f4ea; --blue:#3b82c4;
  --err:#b42318; --errbg:#fdecea;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg:#1f2329; --card:#2b3038; --text:#e6e8eb; --muted:#aab2bd; --line:#3a414b; --soft:#262a31; --head:#323841;
    --accent-t:#ffab5c; --accent2:#3f2d1a; --greenbg:#17321f; --green-t:#8fe0a8; --err:#ff8a80; --errbg:#3a1d1d;
  }
}
* { box-sizing:border-box; }
body { margin:0; font:15px/1.55 "Segoe UI",system-ui,-apple-system,Roboto,sans-serif; background:var(--bg); color:var(--text); }
.wrap { max-width:760px; margin:0 auto; padding:0 16px; }

/* Kopfzeile wie im SRM-Client */
header { background:var(--dark); color:#fff; border-bottom:3px solid var(--accent); }
header .wrap { display:flex; align-items:center; gap:14px; min-height:64px; }
.marke { display:flex; align-items:center; gap:12px; color:#fff; text-decoration:none; }
.marke .logo { width:36px; height:36px; display:block; }
.marke .titel { display:flex; flex-direction:column; line-height:1.2; }
.marke .titel b { font-weight:400; font-size:18px; letter-spacing:.2px; }
.marke .titel small { color:var(--headtext); font-size:12px; }
.srm { background:var(--accent); color:#fff; padding:2px 8px; border-radius:4px; margin-right:6px; letter-spacing:.5px; }
.tag { margin-left:auto; font-size:12px; font-weight:600; color:#fff; background:var(--accent); padding:3px 12px; border-radius:20px; text-transform:uppercase; letter-spacing:.6px; }
.sprache { font-size:13px; color:var(--headtext); text-decoration:none; white-space:nowrap; border:1px solid var(--darkline); border-radius:4px; padding:3px 10px; }
.sprache:hover { color:#fff; border-color:var(--accent); }

main, main.wrap { padding-top:28px; padding-bottom:40px; }
/* Fusszeile immer unten, auch bei kurzen Seiten */
html, body { height:100%; } body { display:flex; flex-direction:column; } main { flex:1 0 auto; width:100%; }
h1 { font-size:26px; line-height:1.25; margin:0 0 12px; font-weight:600; }
h2 { font-size:18px; margin:28px 0 8px; font-weight:600; }
h2.oben { margin-top:0; }
p { margin:0 0 12px; }
.lead { color:var(--muted); font-size:16px; }

/* Karten wie die Kacheln im Client: weiss, feine Linie, farbiger Strich links */
.karte > :first-child, .karte > form > :first-child, .karte > form > .falle + label { margin-top:0; }
.karte { background:var(--card); border:1px solid var(--line); border-left:4px solid var(--accent); border-radius:4px; padding:20px; margin:18px 0; }
label { display:block; font-weight:600; margin:14px 0 4px; }
input[type=text], input[type=email], input[type=password] { width:100%; padding:9px 12px; font-size:15px; border:1px solid var(--line); border-radius:4px; background:var(--card); color:var(--text); }
input:focus, textarea:focus { outline:2px solid var(--accent); outline-offset:0; border-color:var(--accent); }
.check { display:flex; gap:10px; align-items:flex-start; font-weight:400; margin-top:18px; }
.check input { margin-top:5px; accent-color:var(--accent); }

/* Knoepfe wie TSrmButton: Primaer orange, sonst hell mit Linie */
button { margin-top:20px; background:var(--accent); color:#fff; border:1px solid var(--accent); border-radius:4px; padding:10px 22px; font-size:15px; font-weight:600; cursor:pointer; }
button:hover, a.knopf:hover { background:var(--accent-d); border-color:var(--accent-d); }
a.knopf { display:inline-block; background:var(--accent); color:#fff; border:1px solid var(--accent); border-radius:4px; text-decoration:none; font-weight:600; padding:10px 22px; }
button.klein, a.knopf.klein { margin-top:0; padding:6px 14px; font-size:14px; }
button.hell { background:var(--card); color:var(--text); border:1px solid var(--line); }
button.hell:hover { background:var(--soft); border-color:var(--accent); }
button.rot { background:var(--err); border-color:var(--err); color:#fff; }

.fehler { background:var(--errbg); color:var(--err); padding:10px 14px; border-radius:4px; }
.falle { position:absolute; left:-5000px; width:1px; height:1px; overflow:hidden; }
.punkte { padding-left:20px; } .punkte li { margin:4px 0; }
.punkte li::marker, ol.schritte li::marker { color:var(--accent); font-weight:600; }
dl.werte { display:grid; grid-template-columns:max-content 1fr; gap:6px 16px; margin:0; }
dl.werte dt { color:var(--muted); } dl.werte dd { margin:0; font-family:Consolas,ui-monospace,monospace; word-break:break-all; }
dl.werte dd .tipp { display:block; margin-top:4px; font:13px/1.45 "Segoe UI",system-ui,sans-serif; color:var(--muted); word-break:normal; }
.code { font:700 30px Consolas,ui-monospace,monospace; letter-spacing:3px; color:var(--accent-t); }
ol.schritte li { margin:8px 0; }
code { font-family:Consolas,ui-monospace,monospace; background:var(--head); padding:1px 5px; border-radius:3px; word-break:break-all; }
a { color:var(--accent-t); }

footer { color:var(--muted); font-size:13px; padding:16px 0 28px; border-top:1px solid var(--line); background:var(--head); }
footer a { color:var(--muted); }
@media (max-width:560px) { dl.werte { grid-template-columns:1fr; } dl.werte dd { margin-bottom:8px; } h1 { font-size:22px; } .marke .titel small { display:none; } }

/* ---- Verwaltung ---- */
.wrap.breit { max-width:1180px; }
.vmenu { display:flex; flex-wrap:wrap; gap:6px 18px; align-items:center; margin:0 0 18px; padding-bottom:12px; border-bottom:1px solid var(--line); }
.vmenu a { text-decoration:none; font-weight:600; color:var(--text); border-bottom:2px solid transparent; padding-bottom:2px; }
.vmenu a:hover { border-bottom-color:var(--accent); }
.vmenu form { margin-left:auto; }
.hinweis { padding:10px 14px; border-radius:4px; margin:0 0 16px; }
.hinweis.ok { background:var(--greenbg); color:var(--green-t); border-left:4px solid var(--green); }
.hinweis.fehler { background:var(--errbg); color:var(--err); border-left:4px solid var(--err); }
.kopf { display:flex; flex-wrap:wrap; align-items:center; gap:8px 16px; margin-bottom:12px; }
.kopf h1 { margin:0; }
.leise { color:var(--muted); font-size:14px; }
/* Tabellen wie die Listen im Client */
.tabelle { overflow-x:auto; background:var(--card); border:1px solid var(--line); border-radius:4px; }
table { border-collapse:collapse; width:100%; font-size:14px; }
th, td { text-align:left; padding:9px 12px; border-bottom:1px solid var(--soft); vertical-align:top; }
th { font-size:13px; color:var(--text); font-weight:600; background:var(--head); border-bottom:1px solid var(--line); }
tbody tr:nth-child(even) td { background:var(--soft); }
tbody tr:hover td { background:var(--accent2); }
tr:last-child td { border-bottom:0; }
.badge { display:inline-block; font-size:12px; font-weight:600; padding:2px 10px; border-radius:20px; white-space:nowrap; }
.badge.gruen { background:var(--greenbg); color:var(--green-t); }
.badge.grau { background:var(--soft); color:var(--muted); border:1px solid var(--line); }
.badge.blau { background:#e3eef8; color:var(--blue); }
.badge.orange { background:var(--accent2); color:var(--accent-t); }
.badge.rot { background:var(--errbg); color:var(--err); }
@media (prefers-color-scheme: dark) { .badge.blau { background:#1d3350; color:#8ec1f0; } }
form.inline { display:inline-flex; align-items:center; gap:8px; margin:4px 10px 4px 0; }
.aktionen { display:flex; flex-wrap:wrap; align-items:center; }
.check.klein { margin:0; font-size:14px; font-weight:400; display:inline-flex; gap:6px; align-items:center; }
.check.klein input { margin:0; }
form.zeile { display:flex; gap:10px; align-items:center; }
form.zeile input[type=text] { flex:1; }
.gefahr { border-color:var(--err); border-left-color:var(--err); }
.schmal { max-width:480px; }
/* Protokoll wie im Client: dunkler Kasten */
pre.log { background:#1f2329; color:#c9d1d9; border:1px solid var(--line); border-radius:4px; padding:14px; font:13px/1.45 Consolas,ui-monospace,monospace; white-space:pre-wrap; word-break:break-all; max-height:520px; overflow:auto; }
@media (max-width:640px) { .vmenu form { margin-left:0; } form.zeile { flex-direction:column; align-items:stretch; } }
textarea { width:100%; padding:10px 12px; font:14px/1.5 Consolas,ui-monospace,monospace; border:1px solid var(--line); border-radius:4px; background:var(--card); color:var(--text); resize:vertical; }
.zeile-knopf { display:flex; gap:16px; align-items:center; margin-top:12px; }
