/* Terminbuchung – ein einziges, schlichtes Stylesheet */
:root {
  --bg: #f6f7f5;
  --surface: #ffffff;
  --text: #1c1f1d;
  --muted: #5d6661;
  --line: #dfe3df;
  --ok: #1d7a46;
  --warn: #a35a00;
  --err: #b3261e;
  --radius: 12px;
  --accent: #1f7a5c;
  --accent-ink: #ffffff;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #131614;
    --surface: #1c201d;
    --text: #eceeed;
    --muted: #a0a9a4;
    --line: #2f3531;
    --ok: #55c785;
    --warn: #f0b04f;
    --err: #ff8f86;
  }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.55 system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}
.wrap { max-width: 880px; margin: 0 auto; padding: 0 16px; }
main.wrap { padding-top: 24px; padding-bottom: 56px; }
a { color: var(--accent); }
h1 { font-size: 1.7rem; line-height: 1.2; margin: 0 0 .6rem; }
h2 { font-size: 1.2rem; margin: 1.8rem 0 .6rem; }
h3 { margin: 0; font-size: 1.05rem; }
code { background: var(--surface); border: 1px solid var(--line); border-radius: 6px; padding: 1px 6px; }
.break { word-break: break-all; display: inline-block; }
.mono { font-family: ui-monospace, Menlo, Consolas, monospace; width: 100%; }
.lead { color: var(--muted); font-size: 1.05rem; margin-top: 0; }
.hint, .opt { color: var(--muted); font-size: .9rem; font-weight: 400; }
.hint { display: block; margin: .3rem 0; }
.empty { color: var(--muted); padding: 24px 0; }
.muted { opacity: .6; }
.back { margin: 0 0 12px; }

/* Kopf und Fuß */
.site-header { background: var(--surface); border-bottom: 1px solid var(--line); }
.head-inner { display: flex; align-items: center; gap: 14px; min-height: 64px; padding-top: 8px; padding-bottom: 8px; flex-wrap: wrap; }
.logo { display: block; max-height: 52px; max-width: 160px; width: auto; height: auto; }
.logo-link { line-height: 0; }
.site-name { font-weight: 700; font-size: 1.15rem; color: var(--text); text-decoration: none; margin-right: auto; }
.site-footer { border-top: 1px solid var(--line); padding: 20px 0 36px; color: var(--muted); font-size: .92rem; }
.site-footer .wrap { display: flex; gap: 18px; flex-wrap: wrap; }
.site-footer a { color: var(--muted); }

/* Buttons */
.btn {
  display: inline-block; background: var(--accent); color: var(--accent-ink);
  border: 2px solid var(--accent); border-radius: 999px; padding: 9px 20px;
  font: inherit; font-weight: 600; text-decoration: none; cursor: pointer; text-align: center;
}
.btn:hover { filter: brightness(1.08); }
.btn:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, button:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--accent) 55%, transparent); outline-offset: 2px;
}
.btn-ghost { background: transparent; color: var(--accent); }
.btn-danger { background: transparent; color: var(--err); border-color: var(--err); }
.btn-big { padding: 13px 28px; font-size: 1.05rem; margin-top: 8px; }
.btn-small { padding: 4px 12px; font-size: .88rem; }
.insta { padding: 6px 16px; }

/* Terminliste */
.intro p { color: var(--muted); max-width: 60ch; }
.day { margin: 2rem 0 .6rem; font-size: 1.05rem; color: var(--muted); text-transform: none; }
.cards { display: grid; gap: 10px; }
.card {
  display: grid; grid-template-columns: 64px 1fr auto; gap: 14px; align-items: center;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px;
}
.card-time { font-weight: 700; font-size: 1.15rem; line-height: 1.15; }
.card-time small { display: block; font-weight: 400; font-size: .8rem; color: var(--muted); }
.card h3 a { color: var(--text); text-decoration: none; }
.card h3 a:hover { text-decoration: underline; }
.meta { margin: 2px 0 0; color: var(--muted); font-size: .92rem; }
.spots { margin: 4px 0 0; font-size: .92rem; font-weight: 600; }
.spots-ok { color: var(--ok); }
.spots-few { color: var(--warn); }
.spots-full, .spots-closed { color: var(--muted); }
@media (max-width: 560px) {
  .card { grid-template-columns: 52px 1fr; }
  .card .btn { grid-column: 1 / -1; }
}

/* Termin-Details */
.facts { list-style: none; padding: 0; margin: 14px 0; display: grid; gap: 4px; }
.desc { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; margin: 16px 0; }
.legal { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; max-width: 70ch; }

/* Formulare */
.form { display: grid; gap: 14px; max-width: 640px; margin-top: 12px; }
.form.narrow { max-width: 420px; }
.form.inline-form { max-width: none; }
.booking-form { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; margin-top: 24px; }
.booking-form h2 { margin-top: 0; }
label { display: grid; gap: 4px; font-weight: 600; }
label.check { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; }
label.check input { margin-top: 5px; width: auto; flex: none; }
input[type=text], input[type=email], input[type=url], input[type=password], input[type=number],
input[type=date], input[type=time], input[type=datetime-local], input[type=file], select, textarea {
  width: 100%; font: inherit; color: var(--text); background: var(--bg);
  border: 1px solid var(--line); border-radius: 8px; padding: 9px 11px;
}
input[type=color] { width: 64px; height: 40px; padding: 2px; border: 1px solid var(--line); border-radius: 8px; background: var(--bg); }
textarea { resize: vertical; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media (max-width: 560px) { .grid2 { grid-template-columns: 1fr; } }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* Hinweise */
.notice { border-radius: var(--radius); padding: 12px 14px; margin: 12px 0; border: 1px solid var(--line); background: var(--surface); }
.notice.ok { border-color: var(--ok); }
.notice.err { border-color: var(--err); }
.notice.info { border-color: var(--accent); }
.cancel-box, .danger-zone, .panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 4px 18px 18px; margin-top: 28px; }
.danger-zone form + form { margin-top: 10px; }
.checks { list-style: none; padding: 0; display: grid; gap: 2px; }
.checks .ok { color: var(--ok); }
.checks .bad { color: var(--err); font-weight: 700; }
.logo-preview { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.logo-preview img { max-height: 80px; max-width: 220px; border: 1px solid var(--line); border-radius: 8px; background: #fff; }

/* Admin */
.admin-nav { gap: 6px 18px; }
.navlink { color: var(--text); text-decoration: none; font-weight: 600; padding: 4px 0; border-bottom: 2px solid transparent; }
.navlink.active, .navlink:hover { border-bottom-color: var(--accent); }
.linkbtn { background: none; border: 0; font: inherit; cursor: pointer; padding: 4px 0; }
.admin .site-name { margin-right: 12px; }
form.inline { display: inline; }
.toolbar { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; flex-wrap: wrap; margin-bottom: 8px; }
.toolbar h1 { margin: 0; }
.actions { display: flex; gap: 8px; flex-wrap: wrap; }
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); margin: 12px 0; }
.table { width: 100%; border-collapse: collapse; font-size: .95rem; }
.table th, .table td { padding: 9px 12px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: middle; }
.table th { font-size: .82rem; text-transform: uppercase; letter-spacing: .03em; color: var(--muted); }
.table tr:last-child td { border-bottom: 0; }
.rowactions { white-space: nowrap; }
.tag { display: inline-block; font-size: .78rem; font-weight: 700; padding: 1px 8px; border-radius: 999px; border: 1px solid var(--line); color: var(--muted); }
.tag-ok { color: var(--ok); border-color: var(--ok); }
.tag-warn { color: var(--warn); border-color: var(--warn); }
.tag-err { color: var(--err); border-color: var(--err); }

/* Ticket-Auswahl */
[hidden] { display: none !important; }
fieldset.tickets { border: 1px solid var(--line); border-radius: var(--radius); padding: 10px 14px 12px; margin: 0; display: grid; gap: 6px; }
fieldset.tickets legend { font-weight: 700; padding: 0 6px; }
.ticket-opt { font-weight: 600; }
input[type=radio] { margin-top: 5px; width: auto; flex: none; }
.pill-row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.att-yes { color: var(--ok); border-color: var(--ok); }
.att-no { color: var(--err); border-color: var(--err); }
.mono-code { font-family: ui-monospace, Menlo, Consolas, monospace; letter-spacing: .05em; }
input[type=search] { width: 100%; font: inherit; color: var(--text); background: var(--bg); border: 1px solid var(--line); border-radius: 8px; padding: 9px 11px; }
