/* Öffentliche Server-Liste (public/list/) – gleiche Farben und Kacheln wie gamets6.com */
:root {
  --bg: #070b16; --bg-soft: #0c1322; --card: #0e1626; --card-hover: #13203a; --line: #1b2a44;
  --accent: #2ee6a6; --accent-2: #7c5cff; --text: #e8eef8; --muted: #8395b2; --warn: #f0a35e; --bad: #ff6b6b;
  --ui: Inter, system-ui, "Segoe UI", "Noto Sans", Arial, sans-serif;
  --head: Rajdhani, Inter, system-ui, sans-serif;
  --mono: ui-monospace, "Cascadia Mono", Consolas, monospace;
  color-scheme: dark;
}
* { box-sizing: border-box; }
body {
  margin: 0; min-height: 100vh; color: var(--text); font: 15px/1.5 var(--ui); background-color: var(--bg);
  background-image: radial-gradient(1200px 600px at 85% -12%, rgba(124, 92, 255, .16), transparent), radial-gradient(1000px 520px at -8% 8%, rgba(46, 230, 166, .12), transparent);
  background-attachment: fixed;
}
a { color: var(--accent); }
.wrap { max-width: 1600px; margin: 0 auto; padding-inline: max(16px, env(safe-area-inset-left, 0px)) max(16px, env(safe-area-inset-right, 0px)); }
main.wrap { display: grid; gap: 20px; padding-block: 24px 40px; }
h1, h2 { font-family: var(--head); letter-spacing: .01em; text-wrap: balance; margin: 0; }
h1 { font-size: clamp(26px, 4vw, 36px); line-height: 1.15; }
h2 { font-size: 20px; }
h2.mt { margin-top: 18px; }
p { margin: 0; }
.muted, .hint { color: var(--muted); }
.hint { display: block; font-size: 13px; margin-top: 4px; }
.mono, .addr { font-family: var(--mono); font-size: 13px; overflow-wrap: anywhere; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* Kopfzeile */
.top { position: sticky; top: 0; z-index: 5; background: rgba(7, 11, 22, .86); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.top-in { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 22px; padding-block: 12px; }
.logo { font: 700 18px var(--head); letter-spacing: .08em; color: var(--text); text-decoration: none; }
.logo b { color: var(--accent); }
.top nav { display: flex; flex-wrap: wrap; gap: 4px; flex: 1; }
.top nav a { color: var(--text); text-decoration: none; padding: 6px 12px; border-radius: 10px; font-weight: 500; }
.top nav a:hover, .top nav a[aria-current] { background: var(--card-hover); box-shadow: inset 0 0 0 1px var(--line); }
.langs { display: flex; gap: 4px; }
.langs a { color: var(--muted); text-decoration: none; font-size: 13px; padding: 4px 9px; border-radius: 8px; border: 1px solid transparent; }
.langs a[aria-current] { color: var(--text); border-color: var(--line); }

/* Knöpfe */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 42px; padding: 8px 16px; border-radius: 11px; border: 1px solid var(--line);
  background: transparent; color: var(--text); font: 600 16px var(--head); letter-spacing: .02em; text-decoration: none; cursor: pointer; }
.btn:hover { background: var(--card-hover); border-color: #2a4166; }
.btn.primary { background-image: linear-gradient(120deg, var(--accent), var(--accent-2)); border: 0; color: #04140e; }
.btn.primary:hover { filter: brightness(1.08); }
.btn.big { min-height: 48px; font-size: 18px; padding-inline: 22px; }
.btn.small { min-height: 32px; padding: 4px 10px; font-size: 14px; }
.btn.danger { color: var(--bad); border-color: rgba(255, 107, 107, .5); }
.btn:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, button:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* Karten und Meldungen */
.card { background: var(--card); border: 1px solid var(--line); border-radius: 18px; padding: 20px; min-width: 0; display: grid; gap: 12px; align-content: start; }
.card.narrow { max-width: 680px; width: 100%; justify-self: center; }
.cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); gap: 20px; }
.flash { padding: 10px 14px; border-radius: 12px; border: 1px solid var(--accent); color: var(--accent); background: rgba(46, 230, 166, .08); overflow-wrap: anywhere; }
.flash.error { border-color: var(--bad); color: var(--bad); background: rgba(255, 107, 107, .08); }
.flash.info { border-color: #3a5a8c; color: var(--text); background: rgba(110, 168, 255, .08); }
.flash p { margin: 0 0 8px; }
.pill { display: inline-flex; align-items: center; gap: 4px; padding: 1px 9px; border-radius: 999px; font-size: 12px; border: 1px solid var(--line); color: var(--muted); white-space: nowrap; }
.pill.ok { color: var(--accent); border-color: rgba(46, 230, 166, .45); }
.pill.ts { color: var(--accent); border-color: rgba(46, 230, 166, .45); font-weight: 600; }
.pill.off { color: var(--warn); border-color: rgba(240, 163, 94, .5); }
.pill.demo { color: #c9b8ff; border-color: rgba(124, 92, 255, .6); }
.pill.own { color: #04140e; border: 0; font-weight: 600; background-image: linear-gradient(120deg, var(--accent), var(--accent-2)); }
.badges { display: flex; flex-wrap: wrap; gap: 6px; }
.crumbs a { color: var(--muted); text-decoration: none; }
.crumbs a:hover { color: var(--text); }

/* Kopf der Liste und Filter */
.hero { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 16px; }
.hero .lead { color: var(--muted); max-width: 70ch; margin-top: 6px; }
.hero .stats { margin-top: 8px; font-weight: 600; color: var(--accent); }
.filters { grid-template-columns: repeat(auto-fit, minmax(min(100%, 170px), 1fr)); align-items: end; gap: 12px 14px; }
.filters .f-q { grid-column: span 2; }
.f-check { display: flex; align-items: center; gap: 8px; min-height: 42px; }
.f-check label { margin: 0; color: var(--text); font-size: 14px; }
.f-actions { display: flex; gap: 8px; flex-wrap: wrap; }
label { display: block; font-size: 13px; color: var(--muted); margin-bottom: 4px; }
input, select, textarea { width: 100%; font: 15px var(--ui); color: var(--text); background: var(--bg-soft); border: 1px solid var(--line); border-radius: 10px; padding: 9px 11px; min-height: 42px; }
textarea { resize: vertical; }
input[type=checkbox], input[type=radio] { width: auto; min-height: 0; accent-color: var(--accent); }
.found { color: var(--muted); }
.empty { text-align: center; color: var(--muted); padding: 32px 20px; }

/* Kacheln */
.tiles { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 360px), 1fr)); gap: 18px; }
.tile { background: var(--card); border: 1px solid var(--line); border-radius: 18px; padding: 18px; display: flex; flex-direction: column; gap: 14px; min-width: 0; transition: background .15s, border-color .15s; }
.tile:hover { background: var(--card-hover); border-color: #24395c; }
.tile-head { display: flex; gap: 14px; align-items: flex-start; min-width: 0; }
.rank { flex: none; display: grid; place-items: center; width: 44px; height: 44px; border-radius: 12px; font: 700 20px var(--head);
  background-image: linear-gradient(135deg, var(--accent), var(--accent-2)); color: #04140e; }
.tile-title { min-width: 0; display: grid; gap: 6px; }
.tile-title h2 { font: 600 17px/1.3 var(--ui); overflow-wrap: anywhere; }
.tile-title h2 a { color: var(--text); text-decoration: none; }
.tile-title h2 a:hover { color: var(--accent); }
.tile-online { display: flex; align-items: center; gap: 8px; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.tile-online .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 4px rgba(46, 230, 166, .15); }
.tile-online .count { margin-left: 8px; padding: 4px 12px; border: 1px solid var(--line); border-radius: 10px; letter-spacing: 0; text-transform: none; font-size: 14px; color: var(--muted); }
.tile-online .count b { font: 700 22px var(--head); color: var(--accent); }
.is-off .tile-online .dot { background: var(--muted); box-shadow: none; }
.is-off .tile-online .count b { color: var(--muted); }
.is-off .rank { filter: grayscale(.8) brightness(.8); }
.tile-chart { display: grid; gap: 6px; }
.chart-label { display: flex; justify-content: space-between; gap: 8px; font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.no-data { height: 56px; display: grid; place-items: center; border: 1px dashed var(--line); border-radius: 10px; color: var(--muted); font-size: 13px; }
svg.spark { display: block; width: 100%; height: 56px; overflow: visible; }
.chart svg.spark { height: 120px; }
svg.spark polyline { fill: none; stroke: var(--accent); stroke-width: 1.8; vector-effect: non-scaling-stroke; stroke-linejoin: round; }
svg.spark .area { fill: rgba(46, 230, 166, .12); }
.tile-facts, .facts { display: grid; grid-template-columns: auto 1fr; gap: 6px 14px; margin: 0; font-size: 14px; }
.tile-facts dt, .facts dt { color: var(--muted); }
.tile-facts dd { margin: 0; text-align: right; min-width: 0; overflow-wrap: anywhere; }
.facts dd { margin: 0; min-width: 0; overflow-wrap: anywhere; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tags a { font-size: 12px; padding: 2px 9px; border-radius: 999px; background: rgba(124, 92, 255, .14); color: #c9b8ff; text-decoration: none; border: 1px solid rgba(124, 92, 255, .35); }
.tags a:hover { border-color: #a58cff; }
.tile-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: auto; }
.pager { display: flex; gap: 12px; align-items: center; justify-content: center; flex-wrap: wrap; }

/* Server-Seite */
.srv-head { grid-template-columns: 1fr auto; align-items: start; }
.srv-title { overflow-wrap: anywhere; }
.srv-head .badges { margin-top: 8px; }
.srv-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.kpis { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 10px; margin: 6px 0 0; }
.kpis div { background: var(--bg-soft); border: 1px solid var(--line); border-radius: 12px; padding: 10px 14px; }
.kpis dt { color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: .06em; }
.kpis dd { margin: 0; font: 700 28px var(--head); color: var(--accent); }
.kpis dd small { font-size: 16px; color: var(--muted); }
.kpis dd.sm { font: 600 15px var(--ui); color: var(--text); padding-top: 6px; }
.desc { overflow-wrap: anywhere; }
/* Jobbörse und Briefkasten auf der Verwaltungs-Seite */
.office-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.office-list li { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 12px; align-items: start; padding: 12px; border: 1px solid var(--line); border-radius: 12px; overflow-wrap: anywhere; }
.office-list p { margin: 6px 0 0; }
.viewer, .viewer ul { list-style: none; margin: 0; padding: 0; }
.viewer > li { padding: 6px 0 6px calc(var(--depth, 0) * 16px); border-bottom: 1px solid var(--line); }
.viewer .ch { font-weight: 600; }
.viewer ul li { padding-left: 18px; position: relative; font-size: 14px; }
.viewer ul li::before { content: ""; position: absolute; left: 4px; top: .6em; width: 7px; height: 7px; border-radius: 50%; background: var(--muted); }
.viewer ul li.talking::before { background: var(--accent); }
.viewer ul li.away { color: var(--muted); }
.radios { border: 0; padding: 0; margin: 0; display: grid; gap: 4px; }
.check { display: flex; align-items: center; gap: 8px; color: var(--text); font-size: 14px; margin: 0; }

/* Formulare (Eintragen, Bestätigen, Verwalten) */
.form { display: grid; gap: 14px; }
.form fieldset { border: 0; padding: 0; margin: 0; }
.form legend { font-weight: 600; margin-bottom: 8px; }
.grid2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); gap: 14px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { display: inline-flex; align-items: center; gap: 6px; margin: 0; padding: 5px 10px; border: 1px solid var(--line); border-radius: 999px; color: var(--text); font-size: 13px; cursor: pointer; background: var(--bg-soft); }
.chip:has(input:checked) { border-color: var(--accent); background: rgba(46, 230, 166, .1); }
.names-box { padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--bg-soft); }
.field-error { display: block; color: var(--bad); font-size: 13px; margin-top: 4px; }
.form-actions { display: flex; gap: 10px; flex-wrap: wrap; }
details summary { cursor: pointer; color: var(--muted); margin-bottom: 8px; }
.steps { margin: 0; padding-left: 22px; display: grid; gap: 10px; }
.code-box { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 8px; }
.code-box code { font: 600 20px var(--mono); color: var(--accent); padding: 8px 14px; border: 1px dashed rgba(46, 230, 166, .6); border-radius: 10px; background: var(--bg-soft); user-select: all; }
.code-box code.wrap-any { font-size: 13px; overflow-wrap: anywhere; word-break: break-all; }
.page-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: start; gap: 12px; }
.danger-zone { border-color: rgba(255, 107, 107, .35); }
.foot { color: var(--muted); font-size: 13px; padding-block: 0 28px; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px; }
.foot p { margin: 0; max-width: 80ch; }
.legal-links { display: flex; flex-wrap: wrap; gap: 4px 16px; }
.legal-links a { color: var(--muted); }
.legal-links a:hover, .legal-links a[aria-current="page"] { color: var(--text); }

/* Impressum, Datenschutz, Kontakt */
.legal { max-width: 820px; line-height: 1.6; }
.legal h2 { font-size: 19px; margin-top: 10px; scroll-margin-top: 80px; }
.legal p, .legal ul, .legal ol { margin: 0; }
.legal ul { padding-left: 20px; display: grid; gap: 6px; }
.legal .missing { color: var(--bad); font-weight: 600; }
.legal .toc { border: 1px solid var(--line); border-radius: 12px; background: var(--bg-soft); padding: 10px 16px; }
.legal .toc ol { padding-left: 22px; columns: 2 260px; column-gap: 24px; }
.legal .table-scroll { overflow-x: auto; }
.legal table { width: 100%; border-collapse: collapse; font-size: 14px; }
.legal th, .legal td { text-align: left; vertical-align: top; padding: 7px 10px; border-bottom: 1px solid var(--line); }
.legal th { color: var(--muted); font-weight: 600; }
.legal code { font-family: var(--mono); font-size: 13px; white-space: nowrap; }
ul.plain { margin: 0; padding-left: 20px; display: grid; gap: 8px; }

@media (max-width: 640px) {
  .filters .f-q { grid-column: auto; }
  .srv-head { grid-template-columns: 1fr; }
  .tile { padding: 16px; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }

/* Besitzer: Haus in der Stadt und Tagesablauf */
.house-colors { display: flex; flex-wrap: wrap; gap: 6px; }
.house-colors label { position: relative; width: 30px; height: 30px; border-radius: 50%; border: 2px solid var(--line); background: var(--c); cursor: pointer; margin: 0; }
.house-colors label.auto { width: auto; height: 30px; border-radius: 999px; padding: 0 10px; display: inline-flex; align-items: center; font-size: 12px; background: var(--bg-soft); }
.house-colors input { position: absolute; opacity: 0; inset: 0; }
.house-colors label:has(input:checked) { border-color: var(--accent); box-shadow: 0 0 0 2px var(--accent); }
.routine-list { list-style: none; margin: 0 0 12px; padding: 0; display: grid; gap: 6px; }
.routine-list li { display: flex; align-items: center; gap: 10px; padding: 8px 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--bg-soft); }
.routine-list li.now { border-color: var(--accent); }
.routine-list time { font-variant-numeric: tabular-nums; font-weight: 700; min-width: 3.2em; }
.routine-list .what { flex: 1; }
.routine-list form { margin: 0; }

/* Fragen und Antworten (list/faq.php) */
.faq-head h1 { margin: 0; }
.faq-jump .chip { text-decoration: none; }
.faq-part { scroll-margin-top: 80px; margin-top: 16px; }
.faq-part h2 { margin: 0; }
.faq-first { border: 1px solid var(--line); border-radius: 12px; background: var(--bg-soft); padding: 12px 16px; }
.faq-first h3 { margin: 0 0 8px; font-size: 15px; color: var(--accent); }
.faq-item { border-top: 1px solid var(--line); padding: 10px 0 2px; }
.faq-item summary { color: var(--text); font-weight: 600; margin-bottom: 6px; }
.faq-a { color: var(--text); padding: 0 0 8px 18px; max-width: 75ch; }
.faq-a ul { margin: 6px 0; padding-left: 20px; }
.faq-a code, .faq-first code { font-family: var(--mono); background: var(--bg-soft); border: 1px solid var(--line); border-radius: 6px; padding: 0 5px; }
