/**
 * Frontend: helle Flächen im Dark Mode (Events, Kontakt, Event-Detail).
 */

/* —— Kontakt —— */
html[data-theme-mode="dark"] body.theme-enabled .contact-page__card-head,
html[data-theme-mode="auto"] body.theme-enabled .contact-page__card-head {
  background: var(--theme-surface) !important;
  border-bottom: 1px solid var(--theme-card-border) !important;
}

html[data-theme-mode="dark"] body.theme-enabled .contact-page__card-title,
html[data-theme-mode="auto"] body.theme-enabled .contact-page__card-title {
  color: var(--theme-muted) !important;
  font-size: 0.8rem !important;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-weight: 600;
}

/* —— Events-Liste —— */
html[data-theme-mode="dark"] body.theme-enabled .events-page .card,
html[data-theme-mode="auto"] body.theme-enabled .events-page .card {
  background: var(--theme-surface) !important;
  border-color: var(--theme-card-border) !important;
  color: var(--theme-text) !important;
}

html[data-theme-mode="dark"] body.theme-enabled .events-page .card-title,
html[data-theme-mode="dark"] body.theme-enabled .events-page h5,
html[data-theme-mode="dark"] body.theme-enabled .events-page h6,
html[data-theme-mode="auto"] body.theme-enabled .events-page .card-title,
html[data-theme-mode="auto"] body.theme-enabled .events-page h5,
html[data-theme-mode="auto"] body.theme-enabled .events-page h6 {
  color: var(--theme-text) !important;
}

html[data-theme-mode="dark"] body.theme-enabled .events-page .form-control,
html[data-theme-mode="dark"] body.theme-enabled .events-page .flatpickr-input,
html[data-theme-mode="auto"] body.theme-enabled .events-page .form-control,
html[data-theme-mode="auto"] body.theme-enabled .events-page .flatpickr-input {
  background-color: var(--theme-bg) !important;
  color: var(--theme-text) !important;
  border-color: var(--theme-card-border) !important;
}

html[data-theme-mode="dark"] body.theme-enabled .events-page .form-label,
html[data-theme-mode="auto"] body.theme-enabled .events-page .form-label {
  color: var(--theme-muted) !important;
}

html[data-theme-mode="dark"] body.theme-enabled .event-table,
html[data-theme-mode="auto"] body.theme-enabled .event-table {
  background: var(--theme-surface) !important;
  border-color: var(--theme-card-border) !important;
  box-shadow: var(--theme-elev-shadow, 0 8px 28px rgba(0, 0, 0, 0.25)) !important;
}

html[data-theme-mode="dark"] body.theme-enabled .event-table td,
html[data-theme-mode="auto"] body.theme-enabled .event-table td {
  background: transparent !important;
  color: var(--theme-text) !important;
  border-color: var(--theme-card-border) !important;
}

html[data-theme-mode="dark"] body.theme-enabled .event-table h3,
html[data-theme-mode="auto"] body.theme-enabled .event-table h3 {
  color: var(--theme-text) !important;
}

html[data-theme-mode="dark"] body.theme-enabled .event-table p,
html[data-theme-mode="auto"] body.theme-enabled .event-table p {
  color: var(--theme-muted) !important;
}

html[data-theme-mode="dark"] body.theme-enabled .event-media-placeholder,
html[data-theme-mode="auto"] body.theme-enabled .event-media-placeholder {
  background: color-mix(in srgb, var(--theme-accent) 10%, var(--theme-bg)) !important;
  border: 1px dashed color-mix(in srgb, var(--theme-accent) 35%, var(--theme-card-border)) !important;
  color: var(--theme-muted) !important;
}

.event-media-placeholder {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 120px;
  min-height: 80px;
  max-height: 120px;
  border-radius: 8px;
  font-size: 1.75rem;
}

.event-media-placeholder--detail {
  width: 100%;
  min-height: 220px;
  max-height: 320px;
  font-size: 2.5rem;
  border-radius: 12px;
}

/* —— Event-Detail (event-details.css) —— */
html[data-theme-mode="dark"] body.theme-enabled .event-details-hero,
html[data-theme-mode="auto"] body.theme-enabled .event-details-hero {
  border-color: color-mix(in srgb, var(--theme-accent) 35%, transparent) !important;
  background: linear-gradient(
    135deg,
    color-mix(in srgb, var(--theme-accent) 22%, var(--theme-surface)),
    color-mix(in srgb, var(--theme-accent) 8%, var(--theme-bg))
  ) !important;
}

html[data-theme-mode="dark"] body.theme-enabled .event-details-card,
html[data-theme-mode="auto"] body.theme-enabled .event-details-card {
  background: var(--theme-surface) !important;
  border-color: var(--theme-card-border) !important;
}

html[data-theme-mode="dark"] body.theme-enabled #calendar,
html[data-theme-mode="auto"] body.theme-enabled #calendar {
  background: var(--theme-bg) !important;
  border-color: var(--theme-card-border) !important;
}

@media (prefers-color-scheme: dark) {
  html[data-theme-mode="auto"] body.theme-enabled .contact-page__card-head {
    background: var(--theme-surface) !important;
  }
}
