/* ── Reset & Global ── */
* { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Segoe UI', Tahoma, sans-serif; }
body {
  background: #576CBC;
  color: #333; min-height: 100vh;
  display: flex; flex-direction: column; align-items: center; padding: 0 20px 0;
}

/* ── Site Footer ── */
.site-footer {
  width: 100%;
  margin-top: auto;
  padding: 28px 24px 22px;
  display: flex; flex-direction: column; align-items: center; gap: 6px;
  color: rgba(255,255,255,0.85);
  font-size: 0.88rem;
  text-align: center;
}
.site-footer-inner {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap; justify-content: center;
}
.site-footer-link {
  color: #fff; text-decoration: none; opacity: 0.92;
  padding: 4px 8px; border-radius: 6px;
  background: transparent; border: none; font: inherit; cursor: pointer;
  transition: background 0.15s, opacity 0.15s;
}
.site-footer-link:hover { background: rgba(255,255,255,0.12); opacity: 1; }
.site-footer-sep { color: rgba(255,255,255,0.55); }
.site-footer-copy { color: rgba(255,255,255,0.7); font-size: 0.8rem; }
@media print {
  .site-footer { display: none !important; }
}

/* ── Top Bar ── */
.top-bar {
  width: 100%; display: flex; align-items: center; justify-content: space-between;
  padding: 14px 24px; margin-bottom: 24px;
}
.top-bar-brand {
  color: #fff; font-weight: 800; font-size: 2.8rem;
  text-decoration: none; letter-spacing: -0.5px;
  display: flex; flex-direction: column; align-items: flex-start; line-height: 1;
}
.top-bar-brand:hover { opacity: 0.9; }
.logo-row { display: flex; align-items: center; }
.logo-tagline {
  color: rgba(255,255,255,0.85);
  font-size: 1rem;
  font-weight: 500;
  letter-spacing: 0.5px;
  margin-top: 4px;
}
.logo-go {
  color: #fff;
  font-style: italic;
}
.logo-plan {
  color: #fff;
  font-style: normal;
}
.top-bar-links { display: flex; gap: 8px; }
.top-bar-link {
  color: #fff; background: rgba(255,255,255,0.18); border-radius: 8px;
  padding: 7px 18px; font-size: 0.9rem; font-weight: 600;
  text-decoration: none; transition: background 0.15s;
}
.top-bar-link:hover { background: rgba(255,255,255,0.3); }

.verwalten-menu { position: relative; display: inline-block; z-index: 1001; }
.verwalten-trigger { border: none; cursor: pointer; font-family: inherit; }
.verwalten-arrow { display: inline-block; transition: transform 0.15s; }
.verwalten-trigger[aria-expanded="true"] .verwalten-arrow { transform: rotate(180deg); }
.verwalten-dropdown {
  display: none;
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  min-width: 180px;
  background: #fff;
  border: 1px solid #e0e0e8;
  border-radius: 10px;
  box-shadow: 0 8px 28px rgba(0,0,0,0.22);
  padding: 6px;
  z-index: 1000;
}
.verwalten-dropdown.open { display: block; }
.verwalten-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,0.35);
  opacity: 0; pointer-events: none; transition: opacity 0.2s; z-index: 999;
}
.verwalten-overlay.show { opacity: 1; pointer-events: auto; }
.verwalten-item {
  display: block;
  width: 100%;
  text-align: left;
  background: none;
  border: none;
  padding: 10px 14px;
  font-size: 0.92rem;
  color: #1a1a2e;
  text-decoration: none;
  border-radius: 8px;
  cursor: pointer;
  font-family: inherit;
  white-space: nowrap;
}
.verwalten-item:hover { background: #f0f2ff; }
.verwalten-item-favoriten,
.verwalten-item-feedback {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.verwalten-item-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 22px;
  height: 22px;
  padding: 0 7px 2px;
  border-radius: 11px;
  background: #f5b301;
  color: #1a1a2e;
  font-size: 0.78rem;
  font-weight: 700;
  line-height: 1;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.container {
  background: #fff; border-radius: 12px;
  box-shadow: 0 2px 12px rgba(0,0,0,0.08);
  padding: 32px; width: 100%;
}
h1 { font-size: 1.5rem; margin-bottom: 24px; color: #1a1a2e; }

/* ── Shared components ── */
.section { margin-bottom: 24px; }
.section-label {
  font-weight: 600; font-size: 0.95rem; color: #555;
  margin-bottom: 10px; text-transform: uppercase; letter-spacing: 0.5px;
}
.error-msg {
  color: #b3261e; background: #fdecee; border: 1px solid #f5c4ca;
  border-radius: 9px; padding: 10px 14px;
  font-size: 0.92rem; font-weight: 600; line-height: 1.4;
  text-align: left; margin: 10px 0;
}
.error-msg[hidden] { display: none; }
.btn-primary {
  background: #2C74B3;
  color: #fff; border: none; border-radius: 8px;
  padding: 10px 32px; font-size: 1rem; font-weight: 600;
  cursor: pointer; transition: background 0.15s; font-family: inherit;
}
.btn-primary:hover { filter: brightness(1.05); }
.btn-primary:disabled { background: #aab; cursor: not-allowed; }

.btn-cancel {
  background: #fff; color: #3D84A8; border: 1px solid #2C74B3; border-radius: 7px;
  padding: 8px 16px; font-size: 0.95rem; font-weight: 600;
  cursor: pointer; transition: background 0.15s, border-color 0.15s, color 0.15s; font-family: inherit;
}
.btn-cancel:hover { background: #E3F0FA; border-color: #3D84A8; color: #3D84A8; }

/* -- Merkliste (Favoriten) -- */
.merkliste-tab {
  position: fixed; left: 0; top: 50%; transform: translateY(-50%);
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  background: #fff; color: #1a1a2e; border: none; cursor: pointer;
  padding: 14px 12px; border-radius: 0 10px 10px 0;
  font-family: inherit; font-size: 0.85rem; font-weight: 600;
  box-shadow: 2px 2px 8px rgba(0,0,0,0.15); z-index: 998;
  transition: background 0.15s, padding 0.15s;
}
.merkliste-tab:hover { background: #E3F0FA; padding-left: 16px; }
.merkliste-tab.hidden { opacity: 0; pointer-events: none; transform: translateY(-50%) translateX(-100%); }
.merkliste-tab-label { text-align: center; line-height: 1.15; letter-spacing: 0.3px; }
.merkliste-tab-star {
  position: relative; display: inline-flex; align-items: center; justify-content: center;
  width: 56px; height: 56px;
}
.merkliste-tab-star-icon {
  width: 56px; height: 56px;
  fill: #f5b301;
  stroke: #d99800;
  filter: drop-shadow(0 1px 2px rgba(0,0,0,0.25));
}
.merkliste-tab-count {
  position: absolute; top: 48%; left: 50%; transform: translate(-50%, -50%);
  color: #1a1a2e; font-size: 0.95rem; font-weight: 800; line-height: 1;
  pointer-events: none;
}
.merkliste-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,0.35);
  opacity: 0; pointer-events: none; transition: opacity 0.2s; z-index: 1050;
}
.merkliste-overlay.show { opacity: 1; pointer-events: auto; }
body.merkliste-open { overflow: hidden; }
.merkliste-panel {
  position: fixed; top: 140px; left: 0; max-height: calc(100vh - 180px); width: 340px; max-width: 90vw;
  background: #fff; box-shadow: 4px 4px 16px rgba(0,0,0,0.15); border-radius: 0 12px 12px 0;
  transform: translateX(-100%); transition: transform 0.25s ease;
  z-index: 1060; display: flex; flex-direction: column;
}
.merkliste-panel.open { transform: translateX(0); }
.merkliste-panel-header {
  display: flex; justify-content: space-between; align-items: center;
  padding: 16px 20px; border-bottom: 1px solid #eee;
}
.merkliste-panel-header h3 { margin: 0; font-size: 1.1rem; color: #333; }
.merkliste-close {
  background: none; border: none; font-size: 1.6rem; cursor: pointer;
  color: #999; line-height: 1; padding: 0 4px;
}
.merkliste-close:hover { color: #333; }
.merkliste-list { overflow-y: auto; padding: 12px 16px; max-height: 600px; }
.merkliste-empty { color: #888; font-size: 0.9rem; text-align: center; padding: 30px 12px; line-height: 1.5; }
.merkliste-item {
  display: flex; justify-content: space-between; align-items: center;
  padding: 10px 12px; border: 1px solid #eee; border-radius: 8px;
  margin-bottom: 8px; transition: border-color 0.15s, background 0.15s;
}
.merkliste-item:hover { border-color: #3D84A8; background: #E3F0FA; }
.merkliste-item-name { color: #333; text-decoration: none; font-size: 0.92rem; flex: 1; }
.merkliste-item-name:hover { color: #3D84A8; }
.merkliste-item-remove {
  background: none; border: none; cursor: pointer;
  color: #bbb; font-size: 1.2rem; line-height: 1; padding: 0 6px;
}
.merkliste-item-remove:hover { color: #e74c3c; }



@media print {
  .merkliste-tab, .merkliste-overlay, .merkliste-panel { display: none !important; }
}

/* -- Buchungen (unten rechts) -- */
.buchungen-tab {
  position: fixed; right: 0; bottom: 24px; top: auto; transform: none;
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  background: #fff; color: #1a1a2e; border: none; cursor: pointer;
  padding: 14px 12px; border-radius: 10px 0 0 10px;
  font-family: inherit; font-size: 0.85rem; font-weight: 600;
  box-shadow: -2px 2px 8px rgba(0,0,0,0.15); z-index: 998;
  transition: background 0.15s, padding 0.15s;
}
.buchungen-tab:hover { background: #E3F0FA; padding-right: 16px; }
.buchungen-tab.hidden { opacity: 0; pointer-events: none; transform: translateX(100%); }
.buchungen-tab-label { text-align: center; line-height: 1.15; letter-spacing: 0.3px; }
.buchungen-tab-icon {
  position: relative; display: inline-flex; align-items: center; justify-content: center;
  width: 56px; height: 56px;
}
.buchungen-tab-icon-svg {
  width: 56px; height: 56px;
  fill: #3D84A8;
  stroke: #2c3fb8;
  filter: drop-shadow(0 1px 2px rgba(0,0,0,0.25));
}
.buchungen-tab-count {
  position: absolute; top: 42%; left: 50%; transform: translate(-50%, -50%);
  color: #fff; font-size: 0.95rem; font-weight: 800; line-height: 1;
  pointer-events: none;
}
.buchungen-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,0.35);
  opacity: 0; pointer-events: none; transition: opacity 0.2s; z-index: 1050;
}
.buchungen-overlay.show { opacity: 1; pointer-events: auto; }
.buchungen-panel {
  position: fixed; top: 140px; right: 0; max-height: calc(100vh - 180px); width: 360px; max-width: 90vw;
  background: #fff; box-shadow: -4px 4px 16px rgba(0,0,0,0.15); border-radius: 12px 0 0 12px;
  transform: translateX(100%); transition: transform 0.25s ease;
  z-index: 1060; display: flex; flex-direction: column;
}
.buchungen-panel.open { transform: translateX(0); }
.buchungen-panel-hint {
  padding: 10px 20px 0; color: #666; font-size: 0.82rem; line-height: 1.4;
}

.buchung-item {
  flex-direction: column; align-items: stretch; gap: 10px;
  padding: 14px 14px 12px;
  border: 1px solid #e5e7f0;
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 1px 2px rgba(20, 30, 60, 0.04);
  transition: border-color 0.15s, box-shadow 0.15s, transform 0.15s;
}
.buchung-item:hover {
  border-color: #c7d0f5;
  box-shadow: 0 4px 12px rgba(61, 132, 168, 0.10);
  background: #fff;
}
.buchung-top-row { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; width: 100%; }
.buchung-name {
  flex: 1; font-weight: 600; font-size: 0.95rem; color: #1a1a2e;
  line-height: 1.3; letter-spacing: 0.1px;
}
.buchung-name:hover { color: #3D84A8; }
.buchung-meta {
  display: inline-flex; align-items: center; gap: 6px;
  align-self: flex-start;
  padding: 3px 10px 3px 8px;
  background: #E3F0FA; color: #3D84A8;
  border-radius: 999px;
  font-size: 0.78rem; font-weight: 600;
  line-height: 1.2;
}
.buchung-meta-icon { width: 13px; height: 13px; fill: currentColor; flex-shrink: 0; }
.buchung-btn-row {
  display: flex; justify-content: flex-end;
  margin-top: 2px;
}
.buchung-rate-btn {
  background: #3D84A8;
  color: #fff; border: none; border-radius: 7px;
  padding: 7px 16px; font-size: 0.85rem; font-weight: 600;
  cursor: pointer; font-family: inherit; white-space: nowrap;
  box-shadow: 0 2px 6px rgba(61, 132, 168, 0.25);
  transition: background 0.15s, box-shadow 0.15s, transform 0.05s;
}
.buchung-rate-btn:hover { filter: brightness(1.05); box-shadow: 0 4px 10px rgba(61, 132, 168, 0.32); }
.buchung-rate-btn:active { transform: translateY(1px); box-shadow: 0 1px 3px rgba(61, 132, 168, 0.25); }

@media print {
  .buchungen-tab, .buchungen-overlay, .buchungen-panel { display: none !important; }
}

/* -- Kommende Aktivitäten (rechte Seite, gleiche Höhe wie Merkliste) -- */
.aktivitaeten-tab {
  position: fixed; right: 0; top: 50%; transform: translateY(-50%);
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  background: #fff; color: #1a1a2e; border: none; cursor: pointer;
  padding: 14px 12px; border-radius: 10px 0 0 10px;
  font-family: inherit; font-size: 0.85rem; font-weight: 600;
  box-shadow: -2px 2px 8px rgba(0,0,0,0.15); z-index: 998;
  transition: background 0.15s, padding 0.15s;
}
.aktivitaeten-tab:hover { background: #E3F0FA; padding-right: 16px; }
.aktivitaeten-tab.hidden { opacity: 0; pointer-events: none; transform: translateY(-50%) translateX(100%); }
.aktivitaeten-tab .buchungen-tab-count { top: 58%; }

@media print {
  .aktivitaeten-tab { display: none !important; }
}

/* -- Aktivitäten-Item: Teilnehmerliste -- */
.aktivitaet-item { cursor: pointer; }
.aktivitaet-participants {
  margin-top: 4px;
  border-top: 1px dashed #e5e7f0;
  padding-top: 8px;
}
.aktivitaet-participants[hidden] { display: none; }
.aktivitaet-participants-title {
  font-size: 0.82rem;
  font-weight: 600;
  color: #3D84A8;
  padding: 2px 0 4px;
}
.aktivitaet-participants-list {
  list-style: none;
  margin: 6px 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 3px;
  max-height: 180px;
  overflow-y: auto;
}
.aktivitaet-participants-list li {
  font-size: 0.85rem;
  color: #1a1a2e;
  padding: 3px 8px;
  background: #E3F0FA;
  border-radius: 6px;
}
.aktivitaet-participant-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 10px !important;
}
.aktivitaet-participant-name {
  flex: 1;
  font-weight: 500;
  word-break: break-word;
}
.aktivitaet-participant-paid {
  display: inline-flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
  font-size: 0.72rem;
  color: #6b7280;
  font-weight: 500;
}
.aktivitaet-participant-paid-label { letter-spacing: 0.2px; }
.aktivitaet-paid-input {
  font-family: inherit;
  font-size: 0.82rem;
  padding: 4px 6px;
  border: 1px solid #2C74B3;
  border-radius: 6px;
  background: #fff;
  color: #1a1a2e;
}
.aktivitaet-paid-input:focus {
  outline: none;
  border-color: #3D84A8;
  box-shadow: 0 0 0 2px rgba(61, 132, 168, 0.18);
}
.aktivitaet-participants-empty {
  margin-top: 4px;
  padding-top: 8px;
  border-top: 1px dashed #e5e7f0;
  font-size: 0.82rem;
  color: #888;
  font-style: italic;
}
.aktivitaet-hint {
  margin-top: 4px;
  padding-top: 8px;
  border-top: 1px dashed #e5e7f0;
  font-size: 0.78rem;
  color: #6b7280;
}
.aktivitaet-detail-modal { max-width: 460px; width: 92vw; }
.aktivitaet-detail-modal .aktivitaet-participants-list { max-height: 50vh; }

/* -- Globaler Bewertungs-Modal (auch außerhalb von detail.html) -- */
.review-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,0.5);
  display: flex; align-items: center; justify-content: center;
  z-index: 2000; padding: 16px; overflow: hidden; overscroll-behavior: contain;
}
.review-overlay[hidden] { display: none; }
#global-review-overlay { z-index: 2200 !important; }
#global-review-delete-overlay { z-index: 9999 !important; }
#buchung-remove-overlay { z-index: 9999 !important; }
.review-modal {
  background: #fff; border-radius: 12px; padding: 24px;
  width: 100%; max-width: 560px; position: relative;
  box-shadow: 0 12px 40px rgba(0,0,0,0.25);
}
.review-modal h3 { margin: 0 0 8px; font-size: 1.15rem; color: #1a1a2e; }
.review-hint { margin: 0 0 18px; color: #666; font-size: 0.9rem; }
.review-close {
  position: absolute; top: 10px; right: 12px;
  background: transparent; border: none; cursor: pointer;
  width: 32px; height: 32px; min-width: 32px; min-height: 32px;
  flex: 0 0 32px; box-sizing: border-box; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  color: #555; font-size: 22px; line-height: 1; padding: 0;
  font-family: Arial, Helvetica, sans-serif;
  transition: background 0.15s, color 0.15s;
}
.review-close:hover { background: #e63946; color: #fff; }
.review-actions {
  display: flex; gap: 10px; justify-content: flex-end; margin-top: 18px;
}
.review-actions .btn-primary,
.review-actions .btn-secondary {
  border: none; border-radius: 8px; padding: 9px 18px;
  font-size: 0.92rem; font-weight: 600; cursor: pointer; font-family: inherit;
  transition: background 0.15s, color 0.15s;
}
.review-actions .btn-primary { background: #2C74B3; color: #fff; }
.review-actions .btn-primary:hover:not(:disabled) { filter: brightness(1.05); }
.review-actions .btn-primary:disabled { background: #b8c2cc; color: #f0f0f0; cursor: not-allowed; opacity: 0.7; }
.review-actions .btn-secondary { background: #f0f1f5; color: #333; }
.review-actions .btn-secondary:hover { background: #e3e5ec; }
.review-actions .btn-danger {
  background: #e63946; color: #fff; border: none; border-radius: 8px;
  padding: 9px 18px; font-size: 0.92rem; font-weight: 600;
  cursor: pointer; font-family: inherit; transition: background 0.15s;
}
.review-actions .btn-danger:hover { background: #c92e3b; }
.hearts-input {
  display: flex; gap: 6px; justify-content: center; margin: 8px 0 16px;
}
.heart-btn {
  background: none; border: none; padding: 4px; cursor: pointer; line-height: 0;
}
.heart-btn svg { width: 36px; height: 36px; }
.heart-btn svg path { fill: none; stroke: #cdd0d8; stroke-width: 1.6; transition: fill 0.1s, stroke 0.1s; }
.heart-btn.on svg path,
.heart-btn.hover svg path { fill: #e63946; stroke: #e63946; }

/* Numerische Bewertungsskala 1-10 mit Smileys */
.rating-scale { flex-direction: column; align-items: stretch; gap: 6px; margin: 10px 0 18px; }
.rating-scale .rating-row {
  display: flex; gap: 6px; justify-content: space-between;
}
.rating-scale .rating-num {
  flex: 1; min-width: 0; padding: 0;
  height: 38px; line-height: 1;
  border: 1px solid #d0d4de; border-radius: 8px;
  background: #fff; color: #1a1a2e;
  font-family: inherit; font-size: 0.95rem; font-weight: 600;
  cursor: pointer; transition: all 0.12s;
}
.rating-scale .rating-num:hover { border-color: #3D84A8; color: #3D84A8; }
.rating-scale .rating-num.on,
.rating-scale .rating-num.hover {
  background: #3D84A8; border-color: #3D84A8; color: #fff;
}
.rating-scale .rating-labels {
  display: flex; justify-content: space-between;
  padding: 0 4px; font-size: 1.1rem; line-height: 1;
}
.rating-scale .rating-emoji { user-select: none; }
.review-comment {
  width: 100%; border: 1px solid #d0d4de; border-radius: 8px;
  padding: 10px 12px; font-family: inherit; font-size: 0.92rem;
  resize: none; min-height: 80px; box-sizing: border-box;
}
.review-comment:focus { outline: none; border-color: #3D84A8; }
.review-anonym-hint {
  margin: 6px 2px 0; font-size: 0.78rem; color: #6b7280; line-height: 1.35;
}

/* Scroll-to-top Button */
.scroll-top-btn {
  position: fixed; right: 28px; bottom: 28px;
  width: 48px; height: 48px;
  background: linear-gradient(135deg, #8a9eff 0%, #a98bd6 100%);
  color: #fff; border: none; border-radius: 14px;
  box-shadow: 0 6px 18px rgba(138, 158, 255, 0.4);
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  opacity: 0; visibility: hidden; transform: translateY(10px);
  transition: opacity 0.2s, transform 0.2s, visibility 0.2s, box-shadow 0.15s, filter 0.15s;
  z-index: 9000;
}
.scroll-top-btn.visible { opacity: 1; visibility: visible; transform: translateY(0); }
.scroll-top-btn:hover {
  filter: brightness(1.05);
  box-shadow: 0 8px 22px rgba(102, 126, 234, 0.55);
}
.scroll-top-btn:active { transform: translateY(1px); }
.scroll-top-btn svg { width: 22px; height: 22px; }

/* ── Feedback-FAB & Modal ── */
.feedback-fab {
  position: fixed; left: 28px; bottom: 28px;
  width: 48px; height: 48px;
  background: #ff7a59;
  color: #fff; border: none; border-radius: 14px;
  box-shadow: 0 6px 18px rgba(255, 94, 98, 0.4);
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  transition: box-shadow 0.15s, filter 0.15s, transform 0.1s;
  z-index: 9000;
}
.feedback-fab:hover {
  filter: brightness(1.05);
  box-shadow: 0 8px 22px rgba(255, 94, 98, 0.55);
}
.feedback-fab:active { transform: translateY(1px); }
.feedback-fab svg { width: 22px; height: 22px; }
@media print { .feedback-fab { display: none !important; } }
/* Wenn ein Modal/Overlay geöffnet ist, den Feedback-FAB nicht klickbar
   machen (er bleibt sichtbar, aber Klicks gehen ans Overlay). */
body:has(.modal-overlay.open) .feedback-fab,
body:has(.feedback-overlay.open) .feedback-fab,
body:has(.akt-modal-overlay.open) .feedback-fab,
body:has(.akt-email-overlay.open) .feedback-fab,
body:has(.akt-pdf-preview-overlay.open) .feedback-fab,
body:has(.review-overlay:not([hidden])) .feedback-fab {
  pointer-events: none !important;
  opacity: 0.5;
}

.feedback-overlay {
  position: fixed; inset: 0;
  background: rgba(20, 20, 35, 0.55);
  display: flex; align-items: center; justify-content: center;
  z-index: 10000;
  padding: 16px;
}
.feedback-overlay[hidden] { display: none; }
.feedback-modal {
  background: #fff; color: #222;
  width: 100%; max-width: 520px;
  border-radius: 14px; box-shadow: 0 20px 50px rgba(0,0,0,0.3);
  display: flex; flex-direction: column;
  overflow: hidden;
}
.feedback-modal-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 18px;
}
.feedback-modal-head h3 {
  margin: 0; font-size: 1.25rem; color: #2c2c44;
}
.feedback-close {
  background: transparent; border: none; cursor: pointer;
  width: 32px; height: 32px; min-width: 32px; min-height: 32px;
  flex: 0 0 32px; box-sizing: border-box; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  color: #555; font-size: 22px; line-height: 1; padding: 0;
  font-family: Arial, Helvetica, sans-serif;
  transition: background 0.15s, color 0.15s;
}
.feedback-close:hover { background: #e63946; color: #fff; }
.feedback-modal-body { padding: 16px 18px; }
.feedback-kind-row {
  display: flex; gap: 16px; margin-bottom: 12px;
}
.feedback-kind-opt {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 14px; color: #444; cursor: pointer;
}
.feedback-kind-opt input[type="radio"] {
  appearance: none; -webkit-appearance: none; -moz-appearance: none;
  width: 22px; height: 22px;
  border-radius: 50%;
  border: 2px solid #c2c8dc;
  background: #fff;
  cursor: pointer;
  margin: 0;
  padding: 0;
  display: inline-block;
  vertical-align: middle;
  transition: background 0.15s, border-color 0.15s, box-shadow 0.15s;
}
.feedback-kind-opt input[type="radio"]:hover { border-color: #3D84A8; }
.feedback-kind-opt input[type="radio"]:checked {
  background: #3D84A8;
  border-color: #3D84A8;
  box-shadow: 0 0 0 2px rgba(61, 132, 168, 0.18);
}
.feedback-kind-opt input[type="radio"]:focus { outline: none; }
.feedback-kind-opt input[type="radio"]:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px rgba(61, 132, 168, 0.25);
}
.feedback-textarea {
  width: 100%; box-sizing: border-box;
  border: 1px solid #d8d8e2; border-radius: 8px;
  padding: 10px 12px; font: inherit;
  resize: none; min-height: 140px;
}
.feedback-textarea:focus {
  outline: none; border-color: #8a9eff;
  box-shadow: 0 0 0 3px rgba(138, 158, 255, 0.25);
}
.feedback-status {
  margin-top: 10px; padding: 8px 10px; border-radius: 6px; font-size: 14px;
}
.feedback-status-ok { background: #e6f4ea; color: #1e7e34; }
.feedback-status-error {
  color: #b3261e; background: #fdecee; border: 1px solid #f5c4ca;
  border-radius: 9px; padding: 10px 14px;
  font-size: 0.92rem; font-weight: 600; line-height: 1.4;
  text-align: left;
}
.feedback-textarea.field-error,
.feedback-textarea.field-error:hover,
.feedback-reply-input.field-error,
.feedback-reply-input.field-error:hover {
  border-color: #b3261e !important;
  background: #fff5f4 !important;
}
.feedback-textarea.field-error:focus {
  border-color: #b3261e !important;
  box-shadow: 0 0 0 3px rgba(179, 38, 30, 0.15) !important;
}
.feedback-reply-input.field-error:focus {
  border-color: #b3261e !important;
  box-shadow: 0 0 0 3px rgba(179, 38, 30, 0.15) !important;
}
.feedback-modal-foot {
  display: flex; justify-content: flex-end; gap: 10px;
  padding: 14px 18px 18px;
  background: transparent;
}
.feedback-btn-primary, .feedback-btn-secondary {
  cursor: pointer;
  padding: 10px 24px; border-radius: 10px;
  font-family: inherit; font-size: 0.9rem; font-weight: 600;
  line-height: 1.2;
  white-space: nowrap;
  flex: 0 0 auto;
  transition: all 0.15s;
}
.feedback-btn-primary {
  background: #3D84A8; color: #fff; border: none;
}
.feedback-btn-primary:hover:not([disabled]) { filter: brightness(1.05); }
.feedback-btn-primary:active { transform: translateY(1px); }
.feedback-btn-primary[disabled] { opacity: 0.6; cursor: not-allowed; }
.feedback-btn-secondary {
  background: #f0f1f5; border: none; color: #333; font-weight: 600;
}
.feedback-btn-secondary:hover { background: #e3e5ec; }

/* ── Feedback-Inbox-Liste ── */
.feedback-tab {
  display: inline-block; padding: 8px 14px;
  border-radius: 8px; text-decoration: none;
  background: rgba(255,255,255,0.85); color: #2c2c44;
  font-weight: 500; font-size: 14px;
  border: 1px solid transparent;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}
.feedback-tab:hover {
  background: #fff;
  border-color: #3D84A8;
  color: #3D84A8;
}
.feedback-tab.active {
  background: #3D84A8; color: #fff;
  border-color: #3D84A8;
}
.feedback-tab.active:hover {
  background: #fff; color: #3D84A8;
  border-color: #3D84A8;
}
.feedback-card {
  background: #fff; border: 1px solid #e6e6ee;
  border-radius: 12px; padding: 14px 16px;
  margin-bottom: 12px;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.feedback-card:hover {
  border-color: #3D84A8;
  box-shadow: 0 2px 8px rgba(61, 132, 168, 0.12);
}
.feedback-list-scroll {
  max-height: 560px;
  overflow-y: auto;
  padding-right: 14px !important;
  scrollbar-gutter: stable;
}
/* Erledigte Tickets nicht ausgrauen, damit die Aktionsbuttons in voller Farbe bleiben. */
.feedback-card-head {
  display: flex; align-items: center; flex-wrap: wrap;
  gap: 10px; margin-bottom: 8px;
}
.feedback-pill {
  display: inline-block; padding: 3px 10px;
  border-radius: 999px; font-size: 12px; font-weight: 600;
}
.feedback-pill-feedback { background: #e8efff; color: #3651b5; }
.feedback-pill-stoerung { background: #fdecea; color: #b3261e; }
.feedback-card-meta { color: #6a6a7a; font-size: 13px; }
.feedback-card-fields {
  display: flex; flex-wrap: wrap;
  gap: 6px 18px;
  font-size: 13px;
  color: #1f1f33;
  flex: 1 1 auto;
}
.feedback-field { white-space: nowrap; display: inline-flex; align-items: center; }
.feedback-field-label { color: #6a6a7a; font-weight: 600; margin-right: 4px; }
.feedback-field-value { color: #1f1f33; font-weight: 600; }
.feedback-kind-stoerung { color: inherit; }
.feedback-kind-feedback { color: inherit; }
.feedback-status-open { color: #a36a00; }
.feedback-status-done { color: #0a7a3a; }
.feedback-status-closed { color: #555a6b; }
.feedback-status-open-pill {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 999px;
  background: #fff6e5;
  border: 1px solid #f0d9a8;
  color: #a36a00;
  font-size: .88rem;
  font-weight: 600;
  line-height: 1.2;
}

/* Status-Dropdown auf den Tickets (Nachrichten-Seite) */
.fb-status-dd {
  position: relative;
  display: inline-block;
  vertical-align: middle;
}
/* Geschlossener Zustand: kleine Pille im Status-Farbton */
.fb-status-dd-toggle {
  display: inline-flex; align-items: center; gap: 6px;
  cursor: pointer; font-weight: 600; user-select: none;
  padding: 3px 10px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: transparent;
  font-size: .88rem;
  line-height: 1.2;
  white-space: nowrap;
  transition: background .12s ease, border-color .12s ease, box-shadow .12s ease, padding .12s ease, border-radius .12s ease, min-width .12s ease;
}
.fb-status-dd-toggle.feedback-status-open { background: #fff6e5; border-color: #f0d9a8; color: #a36a00; }
.fb-status-dd-toggle.feedback-status-done { background: #e8f6ee; border-color: #b8e0c5; color: #0a7a3a; }
.fb-status-dd-toggle:hover { box-shadow: 0 1px 4px rgba(0, 0, 0, .08); }
.fb-status-dd-toggle .arrow {
  font-size: .55rem; color: inherit; opacity: .7;
  transition: transform .18s ease;
  margin-left: 2px;
}
/* Offener Zustand: Toggle wird zur breiten Input-Box */
.fb-status-dd.open { min-width: 180px; }
.fb-status-dd.open .fb-status-dd-toggle {
  background: #fff;
  border: 1px solid #3D84A8;
  border-bottom-left-radius: 0;
  border-bottom-right-radius: 0;
  border-top-left-radius: 8px;
  border-top-right-radius: 8px;
  padding: 6px 12px;
  min-height: 34px;
  min-width: 180px;
  justify-content: space-between;
  color: #1a1a2e;
  box-shadow: none;
}
.fb-status-dd.open .fb-status-dd-toggle .arrow {
  transform: rotate(180deg);
  color: #3D84A8;
  opacity: 1;
  font-size: .65rem;
}
.fb-status-dd-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  z-index: 60;
  background: #fff;
  border: 1px solid #3D84A8;
  border-top: none;
  border-bottom-left-radius: 8px;
  border-bottom-right-radius: 8px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
  min-width: 180px;
}
.fb-status-dd.open .fb-status-dd-menu { display: block; }
.fb-status-dd-item {
  display: block;
  padding: 9px 12px;
  cursor: pointer;
  font-size: 0.92rem;
  color: #1a1a2e;
  transition: background 0.1s;
}
.fb-status-dd-item:hover { background: #E3F0FA; color: #3D84A8; }
.fb-status-dd-item.active { background: #E3F0FA; color: #3D84A8; font-weight: 600; cursor: default; }
.feedback-msg-edit {
  margin-left: auto;
}
.feedback-msg-delete {
  background: none; border: none; color: #6b7280; cursor: pointer;
  font-size: 1rem; padding: 2px 6px; border-radius: 4px;
  line-height: 1; transition: color 0.15s, background 0.15s;
}
.feedback-msg-delete:hover,
.feedback-msg-delete:focus-visible { color: #e63946; background: transparent; outline: none; }
.feedback-msg-edit {
  background: none; border: none; color: #6b7280; cursor: pointer;
  font-size: 0.95rem; padding: 2px 6px; border-radius: 4px;
  transition: color 0.15s, background 0.15s;
}
.feedback-msg-edit:hover,
.feedback-msg-edit:focus-visible { color: #3D84A8; background: #E3F0FA; outline: none; }
.feedback-msg-edit-form {
  margin-top: 6px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.feedback-msg-edit-input {
  width: 100%;
  box-sizing: border-box;
  resize: vertical;
}
.feedback-msg-edit-actions {
  margin-top: 4px;
}
.feedback-card-reply-toggle {
  display: flex;
  justify-content: flex-end;
  margin-top: 12px;
}
.feedback-card-reply-toggle[hidden] { display: none; }
.feedback-card-reply-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 10px;
  flex-wrap: wrap;
}
.feedback-card-reply-toolbar .feedback-upload {
  display: flex; align-items: center; gap: 10px;
  margin-top: 0; flex-wrap: wrap;
}
.feedback-card-reply-wrap {
  margin-top: 12px;
}
.feedback-card-actions-split {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.feedback-card-attachments {
  margin: 6px 0 4px;
}
.feedback-card-attachments > summary {
  cursor: pointer;
  display: inline-block;
  color: #3D84A8;
  font-weight: 600;
  font-size: 13px;
  padding: 2px 0;
  list-style: none;
  user-select: none;
}
.feedback-card-attachments > summary::-webkit-details-marker { display: none; }
.feedback-card-attachments > summary .fb-attach-icon {
  width: 14px;
  height: 14px;
  vertical-align: -2px;
  margin-right: 6px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.feedback-card-attachments > summary .fb-attach-label-close { display: none; }
.feedback-card-attachments[open] > summary .fb-attach-label-open { display: none; }
.feedback-card-attachments[open] > summary .fb-attach-label-close { display: inline; }
.feedback-card-attachments[open] > summary { margin-bottom: 8px; }
.feedback-card-attachments .feedback-card-images {
  display: flex; flex-wrap: wrap; gap: 8px;
}
.feedback-card-attachments .feedback-card-images img {
  max-width: 140px; max-height: 140px;
  border-radius: 8px; border: 1px solid #e6e6ee;
  cursor: zoom-in; display: block;
}
.feedback-card-message {
  white-space: pre-wrap; color: #1f1f33;
  margin: 4px 0 8px; line-height: 1.45;
}
.feedback-card-url, .feedback-card-ua {
  font-size: 12px; color: #555; margin-top: 4px; word-break: break-all;
}
.feedback-card-url a { color: #3651b5; }
.feedback-card-label { font-weight: 600; color: #444; }
.feedback-card-actions { margin-top: 10px; display: flex; gap: 8px; flex-wrap: wrap; }
.feedback-card-head { position: relative; padding-right: 32px; }
.feedback-card-close {
  position: absolute;
  top: 0;
  right: 0;
  width: 26px;
  height: 26px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: none;
  color: #6a6a7a;
  font-size: 18px;
  font-weight: 600;
  line-height: 1;
  cursor: pointer;
  padding: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  transition: color 0.15s;
}
.feedback-card-close::before {
  content: "\00d7";
  display: block;
  line-height: 1;
}
.feedback-card-close:hover {
  background: transparent;
  color: #b3261e;
}

/* Bestätigungs-Modal für Ticket zurücknehmen */
.fb-confirm-overlay {
  position: fixed; inset: 0;
  background: rgba(20, 22, 38, 0.45);
  display: flex; align-items: center; justify-content: center;
  z-index: 10010;
  padding: 16px;
}
.fb-confirm-overlay[hidden] { display: none; }
.fb-confirm-modal {
  position: relative;
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 18px 48px rgba(0,0,0,0.22);
  width: 100%;
  max-width: 460px;
  padding: 22px 24px 20px;
  text-align: left;
  animation: fbConfirmIn 0.16s ease-out;
}
@keyframes fbConfirmIn {
  from { transform: translateY(8px) scale(0.98); opacity: 0; }
  to   { transform: none; opacity: 1; }
}
.fb-confirm-close {
  position: absolute;
  top: 12px; right: 14px;
  width: 28px; height: 28px;
  border: none;
  background: transparent;
  color: #555;
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
  padding: 0;
  border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  font-family: Arial, Helvetica, sans-serif;
  transition: background 0.15s, color 0.15s;
}
.fb-confirm-close:hover { background: #e63946; color: #fff; }
.fb-confirm-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: #1a1a2e;
  margin: 0 36px 8px 0;
}
.fb-confirm-text {
  color: #5a5a66;
  font-size: 0.95rem;
  margin: 0 0 18px;
  line-height: 1.45;
}
.fb-confirm-actions {
  display: flex; gap: 10px; justify-content: flex-end;
}
.fb-confirm-btn {
  border: none;
  border-radius: 8px;
  padding: 10px 18px;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  transition: filter 0.15s, background 0.15s;
}
.fb-confirm-btn-cancel {
  background: #e9ebf1;
  color: #1a1a2e;
}
.fb-confirm-btn-cancel:hover { background: #dde0e9; }
.fb-confirm-btn-confirm {
  background: #3D84A8;
  color: #fff;
}
.fb-confirm-btn-confirm:hover { filter: brightness(1.06); }
.fb-confirm-btn-confirm.fb-confirm-btn-danger {
  background: #e63946;
  color: #fff;
}
.fb-confirm-btn-confirm.fb-confirm-btn-danger:hover { background: #d62b39; filter: none; }
.feedback-ticket-id {
  display: inline-block;
  padding: 0;
  background: transparent;
  color: #1a1a2e;
  font-family: inherit;
  font-size: inherit;
  line-height: inherit;
  vertical-align: baseline;
  font-weight: 700;
  letter-spacing: 0.5px;
  margin-right: 4px;
}
.feedback-card-reply {
  margin-top: 12px;
  padding: 10px 12px;
  background: #f4faf6;
  border-left: 3px solid #2e8b57;
  border-radius: 6px;
}
.feedback-card-reply-text {
  white-space: pre-wrap;
  color: #1f1f33;
  margin-top: 4px;
  line-height: 1.45;
}
.feedback-card-reply-form {
  margin-top: 10px;
}
.feedback-card-reply-toggle {
  margin-top: 12px;
}
.feedback-card-reply-toggle[hidden] {
  display: none;
}
.feedback-sort-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 18px;
}
.feedback-sort-label {
  font-size: 0.88rem;
  color: #555;
}
.fb-sort-dd {
  position: relative;
  min-width: 200px;
}
.fb-sort-dd-toggle {
  border: 1px solid #ccc;
  border-radius: 8px;
  padding: 8px 12px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  background: #fff;
  transition: border 0.15s;
  min-height: 38px;
  user-select: none;
  font-size: 0.92rem;
  color: #1a1a2e;
}
.fb-sort-dd-toggle:hover { border-color: #3D84A8; }
.fb-sort-dd.open .fb-sort-dd-toggle {
  border-color: #3D84A8;
  border-bottom-left-radius: 0;
  border-bottom-right-radius: 0;
}
.fb-sort-dd-toggle .arrow {
  font-size: 0.65rem;
  color: #999;
  transition: transform 0.2s;
}
.fb-sort-dd.open .fb-sort-dd-toggle .arrow {
  transform: rotate(180deg);
  color: #3D84A8;
}
.fb-sort-dd-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  z-index: 50;
  background: #fff;
  border: 1px solid #3D84A8;
  border-top: none;
  border-bottom-left-radius: 8px;
  border-bottom-right-radius: 8px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}
.fb-sort-dd.open .fb-sort-dd-menu { display: block; }
.fb-sort-dd-item {
  display: block;
  padding: 9px 12px;
  cursor: pointer;
  font-size: 0.92rem;
  color: #1a1a2e;
  transition: background 0.1s;
}
.fb-sort-dd-item:hover { background: #E3F0FA; color: #3D84A8; }
.fb-sort-dd-item.active { background: #E3F0FA; color: #3D84A8; font-weight: 600; }
.feedback-card-thread {
  margin-top: 10px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.feedback-thread-msg {
  padding: 10px 12px;
  border-radius: 6px;
}
.feedback-thread-msg-admin {
  background: #f4faf6;
  border-left: 3px solid #2e8b57;
}
.feedback-thread-msg-user {
  background: #f3f5fb;
  border-left: 3px solid #3651b5;
}
.feedback-reply-input {
  width: 100%;
  box-sizing: border-box;
  padding: 8px 10px;
  border: 1px solid #d6dbef;
  border-radius: 8px;
  font: inherit;
  resize: none;
}

/* Upload-Bereich im Modal */
.feedback-upload {
  display: flex; align-items: center; gap: 10px; margin-top: 10px; flex-wrap: wrap;
}
.feedback-upload-btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 10px 18px; border-radius: 10px; cursor: pointer;
  background: #3D84A8; color: #fff; border: none;
  font-size: 0.9rem; font-weight: 600; line-height: 1.2;
  white-space: nowrap;
  transition: filter 0.15s, transform 0.05s;
}
.feedback-upload-btn:hover { filter: brightness(1.05); }
.feedback-upload-btn:active { transform: translateY(1px); }
.feedback-upload-hint { font-size: 12px; color: #777; }

.feedback-previews {
  display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px;
}
.feedback-previews:empty { display: none; }
.feedback-preview-item {
  position: relative; width: 84px; height: 84px;
  border-radius: 8px; overflow: hidden; border: 1px solid #d6dbef;
  background: #f5f6fb;
}
.feedback-preview-item img {
  width: 100%; height: 100%; object-fit: cover; display: block;
}
.feedback-preview-remove {
  position: absolute; top: 2px; right: 2px;
  width: 22px; height: 22px; border-radius: 50%;
  border: none; cursor: pointer;
  background: rgba(0,0,0,0.6); color: #fff;
  font: 600 14px/1 Arial, sans-serif;
  padding: 0;
  display: flex; align-items: center; justify-content: center;
  text-align: center;
  font-size: 0;
}
.feedback-preview-remove::before {
  content: "✕";
  font: 600 13px/1 Arial, "Helvetica Neue", sans-serif;
  display: block;
}
.feedback-preview-remove:hover { background: rgba(0,0,0,0.85); }

/* Bilder in der Inbox */
.feedback-card-images {
  display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px;
}
.feedback-card-images a {
  display: block; width: 120px; height: 90px;
  border-radius: 8px; overflow: hidden; border: 1px solid #e6e6ee;
}
.feedback-card-images img {
  width: 100%; height: 100%; object-fit: cover; display: block;
}


/* ============================================================ */
/* Einheitlicher Abbrechen-Button (Text-Variante)                */
/* ============================================================ */
.btn-secondary,
.akt-btn-secondary,
.akt-cancel-btn,
.btn-cancel-modal,
.btn-cancel-inline,
.feedback-btn-secondary,
.fb-confirm-btn-cancel {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  background: #eef0f4 !important;
  color: #1a1a2e !important;
  border: 1px solid #dfe2ea !important;
  border-radius: 8px !important;
  padding: 10px 22px !important;
  font-size: 0.95rem !important;
  font-weight: 600 !important;
  font-family: inherit !important;
  line-height: 1.2 !important;
  text-decoration: none !important;
  cursor: pointer !important;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease !important;
  box-shadow: none !important;
  filter: none !important;
}
.btn-secondary:hover,
.akt-btn-secondary:hover,
.akt-cancel-btn:hover,
.btn-cancel-modal:hover,
.btn-cancel-inline:hover,
.feedback-btn-secondary:hover,
.fb-confirm-btn-cancel:hover {
  background: #dde0e9 !important;
  border-color: #c7ccd8 !important;
  color: #1a1a2e !important;
}
.btn-secondary:disabled,
.akt-btn-secondary:disabled,
.akt-cancel-btn:disabled,
.btn-cancel-modal:disabled,
.btn-cancel-inline:disabled,
.feedback-btn-secondary:disabled,
.fb-confirm-btn-cancel:disabled {
  opacity: 0.6 !important;
  cursor: not-allowed !important;
}

