:root { --blau:#004785; --rot:#ED1C24; }
* { box-sizing:border-box; } body { font-family:"Source Sans 3",Arial,sans-serif; margin:0; color:#222; }
.topbar { background:var(--blau); color:#fff; padding:10px 16px; display:flex; justify-content:space-between; align-items:center; }
.topbar a { color:#fff; margin-left:12px; }
.brand-event { color:#fff; font-weight:400; }
.banner { background:#fff7d6; border-bottom:2px solid var(--rot); padding:10px 16px; font-weight:600; }
.banner img { max-height:48px; vertical-align:middle; margin-right:12px; }
main { max-width:85%; margin:24px auto; padding:0 16px; }
.scan { width:100%; font-size:1.6rem; padding:14px; border:2px solid var(--blau); border-radius:8px; }
.result { margin-top:18px; padding:16px; border-radius:8px; background:#f4f6f8; min-height:48px; }
.result.hit { background:#e7f3ea; } .result.miss { background:#fde8e8; }
.result .name { font-size:1.5rem; font-weight:700; } .result .meta { font-size:1.1rem; }
.result .sub { color:#555; margin-top:6px; }
.candidates li { cursor:pointer; padding:8px; border-bottom:1px solid #ddd; } .candidates li:hover { background:#eef; }
.btn,button { background:var(--blau); color:#fff; border:0; padding:10px 16px; border-radius:6px; cursor:pointer; font-size:1rem; }
.login { text-align:center; margin-top:80px; } .ftr { text-align:center; color:#999; padding:24px; font-size:.8rem; }
/* Phase-2 Block1-C */
.modes { display:flex; flex-wrap:wrap; gap:12px; align-items:center; margin-bottom:12px; padding:8px 12px; background:#f0f4f9; border-radius:6px; border:1px solid #ccd6e0; }
.switch { display:flex; align-items:center; gap:6px; cursor:pointer; font-size:.95rem; }
.printer { display:flex; align-items:center; gap:6px; font-size:.95rem; }
.printer select { padding:4px 8px; border:1px solid #aab; border-radius:4px; font-size:.9rem; }
.result .grp { padding:6px 0; border-bottom:1px solid #d8e2d8; }
.result .grp:last-child { border-bottom:0; }
.result .grp-actions { display:flex; flex-wrap:wrap; gap:10px; align-items:center; padding-top:10px; }
.btn-attend { background:var(--blau); }
.btn-finish { background:#0b6e6e; }
.btn-pay { background:#1a7a2e; margin-left:auto; }
.pay-panel { margin-top:14px; background:#fff; border:1px solid #b9d3bd; border-radius:8px; padding:12px 14px; }
.pay-row { display:flex; flex-wrap:wrap; gap:10px; align-items:center; }
.pay-row label { font-size:.9rem; font-weight:600; }
.pay-row #pay-amount { width:110px; padding:7px 10px; border:1px solid #bbc; border-radius:5px; font-size:1rem; margin-left:6px; }
.pay-m { background:var(--blau); }
.pay-status { margin-top:10px; font-size:.95rem; }
.pay-ok { color:#1a7a2e; font-weight:700; font-size:1.1rem; }
.btn-link { background:none; border:0; color:#06c; cursor:pointer; font-size:.9rem; }
.btn-badge  { background:#555; }
.attend-status { font-size:.95rem; }
.attend-status.ok   { color:#1a7a2e; font-weight:600; }
.attend-status.warn { color:var(--rot); font-weight:600; }
.badge-note { margin:6px 0 0; font-size:.85rem; color:#888; font-style:italic; }
/* ── Neue-Buchung: großer Button ─────────────────────────────────────────── */
.btn-big { display:block; width:100%; padding:16px 24px; font-size:1.15rem;
  font-weight:700; background:var(--blau); color:#fff; border:0; border-radius:8px;
  cursor:pointer; margin-bottom:16px; letter-spacing:.02em; }
.btn-big:hover { background:#005fa3; }
/* ── Modal ───────────────────────────────────────────────────────────────── */
.modal-backdrop { position:fixed; inset:0; background:rgba(0,0,0,.45);
  z-index:1000; display:none; align-items:flex-start; justify-content:center;
  overflow-y:auto; padding:24px 16px; }
.modal-backdrop.open { display:flex; }
.modal-dialog { background:#fff; border-radius:10px; width:100%; max-width:760px;
  box-shadow:0 8px 32px rgba(0,0,0,.22); position:relative; margin:auto; }
.modal-header { display:flex; justify-content:space-between; align-items:center;
  padding:16px 20px 12px; border-bottom:1px solid #dde3ea; }
.modal-header h2 { margin:0; font-size:1.2rem; color:var(--blau); }
.modal-close { background:none; border:0; font-size:1.5rem; color:#777;
  cursor:pointer; padding:0 6px; line-height:1; }
.modal-close:hover { color:var(--rot); }
.modal-body { padding:20px; }
.modal-event-info { font-size:.9rem; color:#555; margin-bottom:16px; }
.modal-result { padding:14px 16px; border-radius:8px; background:#e7f3ea;
  border:1px solid #a3d3ab; margin-top:14px; }
.modal-result.err { background:#fde8e8; border-color:#f0aaaa; }
.modal-result pre { margin:6px 0 0; font-size:.8rem; color:#444; white-space:pre-wrap; }
/* Toggle "Ticket für Käufer" */
.bk-toggle-row { display:flex; align-items:center; gap:10px; margin-bottom:14px;
  padding:10px 14px; background:#eef4ff; border-radius:6px; border:1px solid #c5d8f0; }
.bk-toggle-row label { font-size:.95rem; font-weight:600; color:var(--blau);
  cursor:pointer; }
/* Ticket-Dropdown */
.f-ticket-select { padding:8px 10px; border:1px solid #bbc; border-radius:5px;
  font-size:.95rem; width:100%; background:#fff; }

/* ── Scan: Edit-Button + Edit-Panel ──────────────────────────────────────── */
.btn-edit-attendee { background:#555; color:#fff; border:0; padding:8px 14px;
  border-radius:6px; cursor:pointer; font-size:.9rem; }
.btn-edit-attendee:hover { background:#333; }
.attendee-edit-panel { margin-top:14px; background:#fff; border:1px solid #c0cfe0;
  border-radius:8px; padding:16px 18px; }
.attendee-edit-panel h3 { margin:0 0 12px; font-size:1rem; color:var(--blau); }
.edit-field-grid { display:grid; grid-template-columns:repeat(auto-fill, minmax(200px,1fr));
  gap:10px; margin-bottom:12px; }
.edit-field { display:flex; flex-direction:column; gap:3px; }
.edit-field label { font-size:.8rem; font-weight:600; color:#444; }
.edit-field input, .edit-field select { padding:6px 8px; border:1px solid #bbc;
  border-radius:4px; font-size:.9rem; }
.edit-field input:focus, .edit-field select:focus { border-color:var(--blau); outline:none; }
.edit-field-section-title { grid-column:1/-1; font-size:.82rem; font-weight:700;
  color:var(--blau); text-transform:uppercase; letter-spacing:.05em;
  border-bottom:1px solid #dde; padding-bottom:4px; margin-top:6px; }
.edit-actions { display:flex; align-items:center; gap:12px; }
.btn-edit-save { background:var(--blau); color:#fff; border:0; padding:9px 20px;
  border-radius:6px; cursor:pointer; font-weight:600; }
.btn-edit-save:hover { background:#005fa3; }
.btn-edit-cancel { background:none; border:1px solid #aab; color:#555; padding:8px 14px;
  border-radius:6px; cursor:pointer; font-size:.9rem; }
.edit-save-msg { font-size:.88rem; color:#1a7a2e; font-weight:600; }

/* ── Scan: Offene-Rechnung-Button ────────────────────────────────────────── */
.btn-open-invoice { background:var(--rot); color:#fff; border:0; padding:10px 18px;
  border-radius:6px; cursor:pointer; font-size:.95rem; font-weight:700;
  display:inline-flex; align-items:center; gap:6px; }
.btn-open-invoice:hover { background:#c00; }

/* ── Bezahlen-Dialog (mini-modal) ────────────────────────────────────────── */
.pay-modal-backdrop { position:fixed; inset:0; background:rgba(0,0,0,.5);
  z-index:2000; display:none; align-items:center; justify-content:center;
  padding:24px 16px; }
.pay-modal-backdrop.open { display:flex; }
.pay-modal-dialog { background:#fff; border-radius:10px; width:100%; max-width:640px;
  box-shadow:0 8px 32px rgba(0,0,0,.25); }
.pay-modal-header { display:flex; justify-content:space-between; align-items:center;
  padding:14px 18px 10px; border-bottom:1px solid #dde; }
.pay-modal-header h2 { margin:0; font-size:1.1rem; color:var(--rot); }
.pay-modal-body { padding:18px; }
.pay-invoice-table { width:100%; border-collapse:collapse; font-size:.9rem; margin-bottom:12px; }
.pay-invoice-table th { text-align:left; border-bottom:2px solid #dde; padding:6px 8px;
  font-size:.8rem; color:#555; }
.pay-invoice-table td { padding:7px 8px; border-bottom:1px solid #eee; vertical-align:middle; }
.pay-invoice-table tr:last-child td { border-bottom:0; }
.btn-pay-invoice { background:var(--blau); color:#fff; border:0; padding:5px 12px;
  border-radius:4px; cursor:pointer; font-size:.85rem; text-decoration:none;
  display:inline-block; }
.btn-pay-invoice:hover { background:#005fa3; }
.pay-stripe-note { font-size:.8rem; color:#888; font-style:italic; margin-top:8px; }

/* ── Booking: Neuanlage-Dialog ───────────────────────────────────────────── */
.neu-modal-backdrop { position:fixed; inset:0; background:rgba(0,0,0,.5);
  z-index:3000; display:none; align-items:center; justify-content:center;
  padding:24px 16px; }
.neu-modal-backdrop.open { display:flex; }
.neu-modal-dialog { background:#fff; border-radius:10px; width:100%; max-width:580px;
  box-shadow:0 8px 32px rgba(0,0,0,.25); }
.neu-modal-header { display:flex; justify-content:space-between; align-items:center;
  padding:14px 18px 10px; border-bottom:1px solid #dde; }
.neu-modal-header h2 { margin:0; font-size:1.1rem; color:var(--blau); }
.neu-modal-body { padding:18px; }
.neu-field-grid { display:grid; grid-template-columns:repeat(auto-fill, minmax(180px,1fr));
  gap:10px; margin-bottom:14px; }
.neu-field { display:flex; flex-direction:column; gap:3px; }
.neu-field label { font-size:.82rem; font-weight:600; color:#444; }
.neu-field input, .neu-field select { padding:7px 9px; border:1px solid #bbc;
  border-radius:5px; font-size:.9rem; }
.neu-field input:focus, .neu-field select:focus { border-color:var(--blau); outline:none; }
.neu-section-title { grid-column:1/-1; font-size:.8rem; font-weight:700; color:var(--blau);
  text-transform:uppercase; letter-spacing:.04em;
  border-bottom:1px solid #dde; padding-bottom:3px; margin-top:4px; }
.neu-modal-actions { display:flex; gap:10px; justify-content:flex-end; }
.btn-neu-confirm { background:var(--blau); color:#fff; border:0; padding:9px 20px;
  border-radius:6px; cursor:pointer; font-weight:600; }
.btn-neu-cancel { background:none; border:1px solid #aab; color:#555; padding:8px 14px;
  border-radius:6px; cursor:pointer; }
.btn-neu-anlegen { background:#1a7a2e; color:#fff; border:0; padding:7px 12px;
  border-radius:5px; cursor:pointer; font-size:.85rem; font-weight:600; white-space:nowrap; }
