/* Tische zuweisen und Tischbestand im Panel. Farben aus dem Panel, Tippziele mindestens 44 px. */
.adm-edit.tz { max-width: 680px; }
.tz .adm-edit__body { display: block; }
.tz-kopf { margin: 0 0 6px; font-size: 1rem; line-height: 1.5; }
.tz-gastwunsch { margin: 0 0 10px; font-style: italic; color: var(--vr-text-muted, #45525f); }
.tz-hilfe { margin: 0 0 12px; font-size: 0.875rem; line-height: 1.5; color: var(--vr-text-muted, #45525f); }
.tz-gruppe { margin: 0 0 14px; padding: 0; border: 0; }
.tz-gruppe legend { padding: 0; margin: 0 0 8px; font-weight: 700; font-size: 0.9375rem; color: #112f4d; }
.tz-wunsch { display: inline-block; margin-left: 6px; padding: 2px 8px; border-radius: 9999px; background: #f4e7c8; color: #5b4208; font-size: 0.75rem; font-weight: 700; }
.tz-raster { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; }
.tz-tisch {
  position: relative; display: flex; flex-direction: column; justify-content: center; gap: 2px;
  min-height: 56px; padding: 8px 12px 8px 40px; border: 2px solid #d9cfb8; border-radius: 10px;
  background: #fff; cursor: pointer; transition: border-color .15s ease, background-color .15s ease;
}
.tz-tisch input { position: absolute; left: 12px; top: 50%; width: 20px; height: 20px; margin: -10px 0 0; accent-color: #112f4d; }
.tz-tisch:hover { border-color: #b8933f; }
.tz-tisch:has(input:checked) { border-color: #112f4d; background: #eef2f6; }
.tz-tisch:has(input:focus-visible) { outline: 3px solid #b8933f; outline-offset: 2px; }
.tz-tisch--belegt { cursor: not-allowed; background: #f3f1ec; border-style: dashed; }
.tz-tisch--belegt .tz-name, .tz-tisch--belegt .tz-info { color: #6b6457; }
.tz-name { font-weight: 700; font-size: 1rem; color: #1d2a36; }
.tz-info { font-size: 0.8125rem; color: #45525f; }
.tz-summe { margin: 6px 0 0; padding: 10px 12px; border-radius: 8px; background: #f6f1e7; font-size: 0.9375rem; line-height: 1.45; }
.tz-summe--gut { background: #e7efe4; color: #24451f; }
.tz-summe--warn { background: #fbecd0; color: #5b3a00; font-weight: 600; }
.tz-fehler { margin: 10px 0 0; padding: 10px 12px; border-radius: 8px; background: #f6e3e5; color: #7a1a24; font-weight: 600; }
.tz .adm-edit__acts { flex-wrap: wrap; }
.tz .adm-edit__acts .adm-mini { min-height: 44px; padding: 8px 16px; }

.adm-tisch-meta { margin-top: 4px; }
.adm-tisch-zu { font-weight: 700; color: #112f4d; }
.adm-tisch-offen { font-weight: 700; color: #7a4b00; }

.einst-tl { flex-wrap: wrap; }
.einst-tl .adm-field input[type="text"] { min-width: 0; }
.einst-tl-komb { flex: 0 0 auto; align-self: center; }

html[data-theme="dark"] .tz-tisch { background: #1b2430; border-color: #3a4656; }
html[data-theme="dark"] .tz-tisch:has(input:checked) { background: #24344a; border-color: #e6bd68; }
html[data-theme="dark"] .tz-name { color: #f5efe0; }
html[data-theme="dark"] .tz-info, html[data-theme="dark"] .tz-hilfe, html[data-theme="dark"] .tz-gastwunsch { color: #c4ccd6; }
html[data-theme="dark"] .tz-gruppe legend, html[data-theme="dark"] .adm-tisch-zu { color: #e6bd68; }
html[data-theme="dark"] .adm-tisch-offen { color: #f2c27a; }
html[data-theme="dark"] .tz-summe { background: #232a33; color: #f5efe0; }
html[data-theme="dark"] .tz-summe--gut { background: #22301f; color: #a8d3a0; }
html[data-theme="dark"] .tz-summe--warn { background: #3a2f17; color: #f2c27a; }
html[data-theme="dark"] .tz-tisch--belegt { background: #20242a; }
html[data-theme="dark"] .tz-tisch--belegt .tz-name, html[data-theme="dark"] .tz-tisch--belegt .tz-info { color: #9aa3ad; }

@media (max-width: 490px) {
  .tz-raster { grid-template-columns: 1fr 1fr; }
  .tz .adm-edit__acts .adm-mini { flex: 1 1 100%; }
}
@media (prefers-reduced-motion: reduce) { .tz-tisch { transition: none; } }

/* Dialog in beiden Fassungen mit eigenen Farben (Farbe a: Nachtblau und Gold), unabhaengig vom Panel-Grund. */
html body .adm-edit.tz { background: #fbf9f6; color: #1d2a36; }
html body .adm-edit.tz .adm-edit__head { background: #112f4d; color: #f3dca6; }
html body .adm-edit.tz .tz-kopf { color: #1d2a36; }
html body .adm-edit.tz .adm-edit__acts { border-top-color: #e8dfcc; }
html body .adm-edit.tz .adm-mini { background: #ffffff; border: 2px solid #112f4d; color: #112f4d; font-weight: 700; }
html body .adm-edit.tz .adm-mini.confirm { background: #112f4d; color: #ffffff; }
html body .adm-edit.tz .adm-mini:focus-visible { outline: 3px solid #b8933f; outline-offset: 2px; }
html body .adm-edit.tz .adm-mini:disabled { opacity: .55; }
html[data-theme="dark"] body .adm-edit.tz { background: #141c26; color: #f5efe0; }
html[data-theme="dark"] body .adm-edit.tz .adm-edit__head { background: #0c2238; color: #e6bd68; }
html[data-theme="dark"] body .adm-edit.tz .tz-kopf { color: #f5efe0; }
html[data-theme="dark"] body .adm-edit.tz .adm-edit__acts { border-top-color: #2c3846; }
html[data-theme="dark"] body .adm-edit.tz .adm-mini { background: transparent; border-color: #e6bd68; color: #e6bd68; }
html[data-theme="dark"] body .adm-edit.tz .adm-mini.confirm { background: #e6bd68; color: #112f4d; }
html[data-theme="dark"] .tz-fehler { background: #3a2225; color: #f0b4bd; }
html[data-theme="dark"] .tz-wunsch { background: #3a2f17; color: #f3dca6; }

/* Tischliste am Handy: Name ueber die ganze Breite, darunter Plaetze und Bereich, darunter zusammenstellbar und entfernen. */
@media (max-width: 490px) {
  .einst-zimmer.einst-tl { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 10px; align-items: end; }
  .einst-tl .einst-weit { grid-column: 1 / -1; }
  .einst-tl .adm-field { min-width: 0; }
  .einst-tl .adm-field input { width: 100%; max-width: none; box-sizing: border-box; }
  .einst-tl .einst-tl-komb { align-self: center; }
  .einst-tl .einst-weg { width: 100%; }
}

/* Fenster "Reservierung bearbeiten" (admin.js openAdminEdit): eigene Farben in hell und dunkel, Kontrast AAA,
   Felder 16 px (iOS zoomt sonst), sichtbarer Fokus. Die Fenster der Vermerke (gv-fenster) und Tisch zuweisen (tz) haben eigene. */
html body .adm-edit:not(.tz):not(.gv-fenster) { background: #fbf9f6; color: #1d2a36; }
html body .adm-edit:not(.tz):not(.gv-fenster) .adm-edit__head { background: #112f4d; color: #f3dca6; }
html body .adm-edit:not(.tz):not(.gv-fenster) .adm-ef > span { font-size: 13px; color: #33404c; font-weight: 600; }
html body .adm-edit:not(.tz):not(.gv-fenster) .adm-ef input,
html body .adm-edit:not(.tz):not(.gv-fenster) .adm-ef select,
html body .adm-edit:not(.tz):not(.gv-fenster) .adm-ef textarea { font-size: 16px; min-height: 44px; background-color: #ffffff; color: #1d2a36; border: 1px solid #7d8794; }
html body .adm-edit:not(.tz):not(.gv-fenster) .adm-ef :is(input, select, textarea):focus-visible { outline: 3px solid #b8933f; outline-offset: 1px; border-color: #112f4d; }
html body .adm-edit:not(.tz):not(.gv-fenster) .adm-edit__acts { border-top-color: #e8dfcc; }
html body .adm-edit:not(.tz):not(.gv-fenster) .adm-mini { min-height: 44px; padding: 8px 16px; background: #ffffff; border: 2px solid #112f4d; color: #112f4d; font-weight: 700; }
html body .adm-edit:not(.tz):not(.gv-fenster) .adm-mini.confirm { background: #112f4d; color: #ffffff; }
html body .adm-edit:not(.tz):not(.gv-fenster) .adm-mini:focus-visible { outline: 3px solid #b8933f; outline-offset: 2px; }
html[data-theme="dark"] body .adm-edit:not(.tz):not(.gv-fenster) { background: #141c26; color: #f5efe0; }
html[data-theme="dark"] body .adm-edit:not(.tz):not(.gv-fenster) .adm-edit__head { background: #0c2238; color: #e6bd68; }
html[data-theme="dark"] body .adm-edit:not(.tz):not(.gv-fenster) .adm-ef > span { color: #c9d1da; }
html[data-theme="dark"] body .adm-edit:not(.tz):not(.gv-fenster) .adm-ef input,
html[data-theme="dark"] body .adm-edit:not(.tz):not(.gv-fenster) .adm-ef select,
html[data-theme="dark"] body .adm-edit:not(.tz):not(.gv-fenster) .adm-ef textarea { background-color: #0e151e !important; color: #f5efe0 !important; border-color: #6b7787 !important; color-scheme: dark; }
html[data-theme="dark"] body .adm-edit:not(.tz):not(.gv-fenster) .adm-edit__acts { border-top-color: #2c3846; }
html[data-theme="dark"] body .adm-edit:not(.tz):not(.gv-fenster) .adm-mini { background: transparent; border-color: #e6bd68; color: #e6bd68; }
html[data-theme="dark"] body .adm-edit:not(.tz):not(.gv-fenster) .adm-mini.confirm { background: #e6bd68; color: #112f4d; }

/* WebKit zeichnet ein select sonst nur 24 px hoch: eigenes Aussehen, feste Hoehe, Pfeil aus zwei Verlaeufen. */
html body .adm-edit:not(.tz):not(.gv-fenster) .adm-ef select {
  -webkit-appearance: none; appearance: none; height: 44px; padding-right: 36px;
  background-image: linear-gradient(45deg, transparent 50%, #112f4d 50%), linear-gradient(135deg, #112f4d 50%, transparent 50%) !important;
  background-position: calc(100% - 20px) 50%, calc(100% - 14px) 50% !important; background-size: 6px 6px, 6px 6px !important; background-repeat: no-repeat !important;
}
html[data-theme="dark"] body .adm-edit:not(.tz):not(.gv-fenster) .adm-ef select {
  background-image: linear-gradient(45deg, transparent 50%, #e6bd68 50%), linear-gradient(135deg, #e6bd68 50%, transparent 50%) !important;
}
