/* Panorama-Theme – Überlagerung über themes/default/css/styles.css.
   Großes Titelbild (Hintergrundbild des Vereins), transparenter Header,
   Inhaltsflächen liegen als „Blatt“ über dem Bild. Farben aus --primary/--primary-2. */

:root,
[data-theme="light"] {
  --bg: #ffffff;
  --bgcard: #f4f5f7;
  --bgsection-alt: #f4f5f7;
  --ink: #12151a;
  --muted: #5d6673;
  --radius: 24px;
  --p-line: rgba(18, 21, 26, 0.08);
  --shadow-sm: 0 1px 2px rgba(18, 21, 26, 0.05);
  --shadow-md: 0 10px 30px -12px rgba(18, 21, 26, 0.25);
  --shadow-lg: 0 24px 60px -20px rgba(18, 21, 26, 0.35);
  --p-ease: cubic-bezier(0.2, 0.8, 0.2, 1);
  --p-overlap: clamp(48px, 7vw, 88px);
}

[data-theme="dark"] {
  --bg: #0d1014;
  --bgcard: #171b21;
  --bgsection-alt: #12161b;
  --ink: #eef0f3;
  --muted: #9aa3b0;
  --p-line: rgba(255, 255, 255, 0.08);
}

body {
  background: var(--bg);
}

/* ---------- Topbar ---------- */
.topbar {
  background: rgba(10, 12, 16, 0.92);
  font-size: 0.8rem;
}

/* ---------- Header: über dem Titelbild, danach solide ---------- */
.site-header {
  top: var(--h-topbar, 40px);
  padding: 10px 0;
  background: var(--bg);
  box-shadow: 0 1px 0 var(--p-line);
  transition: background 0.35s var(--p-ease), box-shadow 0.35s var(--p-ease), color 0.35s var(--p-ease);
}

.brand img {
  height: 54px;
  border-radius: 12px;
  box-shadow: none;
}

.brand .brand-text strong {
  font-size: 1.1rem;
  letter-spacing: -0.01em;
}

.nav-toggle {
  border-radius: 12px;
}

body:has(.hero-cover) .site-header {
  margin-bottom: calc(-1 * var(--h-header, 76px));
}

body:has(.hero-cover) .site-header:not(.is-scrolled) {
  background: transparent;
  box-shadow: none;
}

body:has(.hero-cover) .site-header:not(.is-scrolled) .brand,
body:has(.hero-cover) .site-header:not(.is-scrolled) .brand-text span,
body:has(.hero-cover) .site-header:not(.is-scrolled) .nav-toggle {
  color: #fff;
}

body:has(.hero-cover) .site-header:not(.is-scrolled) .nav-toggle {
  background: rgba(255, 255, 255, 0.14);
}

body:has(.hero-cover) .site-header:not(.is-scrolled) .nav-toggle:hover,
body:has(.hero-cover) .site-header:not(.is-scrolled) .nav-toggle:focus {
  background: #fff;
  color: var(--primary);
}

.nav,
body.nav-open .nav {
  border-radius: 20px;
  border: 1px solid var(--p-line);
  box-shadow: var(--shadow-lg);
}

.nav a,
body.nav-open .nav a {
  border-bottom: 0;
  border-radius: 12px;
}

/* ---------- Titelbild ---------- */
.hero-cover {
  position: relative;
  display: flex;
  align-items: flex-end;
  min-height: max(540px, calc(100vh - var(--h-topbar, 40px) + var(--p-overlap)));
  min-height: max(540px, calc(100svh - var(--h-topbar, 40px) + var(--p-overlap)));
  padding: calc(var(--h-header, 76px) + 40px) 0 clamp(96px, 14vw, 160px);
  color: #fff;
  overflow: hidden;
  isolation: isolate;
}

.hero-cover-bg {
  position: absolute;
  inset: 0;
  z-index: -2;
  background-color: color-mix(in srgb, var(--primary) 70%, #000);
  background-image:
    radial-gradient(70% 90% at 15% 10%, color-mix(in srgb, var(--primary-2) 70%, transparent), transparent 65%),
    radial-gradient(60% 80% at 90% 90%, color-mix(in srgb, var(--primary) 80%, transparent), transparent 70%);
  background-size: cover;
  background-position: center;
  transform: scale(1.04);
  animation: p-zoom 18s ease-out forwards;
}

/* Foto ersetzt die Farbflächen, wenn eines hinterlegt ist */
.hero-cover-bg[style] {
  background-color: #111;
}

/* Diashow aus der Galerie: Bilder blenden sanft ineinander über */
.hero-cover-slide {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0;
  transition: opacity 1.8s ease-in-out;
}

.hero-cover-slide.is-active {
  opacity: 1;
}

/* Titelvideo füllt die Fläche wie ein Hintergrundbild */
.hero-cover-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  pointer-events: none;
}

.hero-cover::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(180deg, rgba(8, 10, 14, 0.55) 0%, rgba(8, 10, 14, 0.15) 35%, rgba(8, 10, 14, 0.75) 100%);
}

.hero-cover-inner {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 20px;
}

.hero-cover-kicker {
  display: inline-block;
  margin: 0 0 16px;
  padding: 6px 16px;
  border: 1px solid rgba(255, 255, 255, 0.45);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  font-size: 0.8rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.hero-cover h1,
.hero-cover-title {
  margin: 0;
  max-width: 14ch;
  font-size: clamp(2.8rem, 9vw, 6.5rem);
  line-height: 0.98;
  letter-spacing: -0.04em;
  font-weight: 700;
  text-shadow: 0 4px 40px rgba(0, 0, 0, 0.35);
}

/* Kompaktes Titelbild für Unterseiten */
.hero-cover--page {
  min-height: clamp(340px, 48vh, 480px);
  padding-bottom: calc(var(--p-overlap) + 32px);
}

.hero-cover--page .hero-cover-title {
  max-width: 20ch;
  font-size: clamp(2.2rem, 6.5vw, 4.5rem);
}

/* Inhalt der Unterseite liegt als Blatt über dem Bild */
.hero-cover--page + main {
  position: relative;
  z-index: 2;
  margin-top: calc(-1 * var(--p-overlap));
  border-radius: 36px 36px 0 0;
  background: var(--bg);
  box-shadow: 0 -20px 50px -20px rgba(0, 0, 0, 0.35);
}

/* Seitentitel steht bereits im Titelbild */
.hero-cover--page + main .downloads-section h1,
.hero-cover--page + main .application-header h1 {
  display: none;
}

.hero-cover-scroll {
  position: absolute;
  inset-inline-end: clamp(16px, 4vw, 48px);
  bottom: clamp(100px, 14vw, 164px);
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.12);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  color: #fff;
  cursor: pointer;
  animation: p-bob 2.4s ease-in-out infinite;
  transition: background 0.3s var(--p-ease), color 0.3s var(--p-ease);
}

.hero-cover-scroll:hover {
  background: #fff;
  color: var(--primary);
}

@keyframes p-zoom {
  to {
    transform: scale(1);
  }
}

@keyframes p-bob {
  50% {
    transform: translateY(6px);
  }
}

/* ---------- Inhalte als Blatt über dem Bild ---------- */
.hero-cover + .section,
.section.hero-next {
  position: relative;
  z-index: 2;
  margin-top: calc(-1 * var(--p-overlap));
  padding-top: clamp(40px, 6vw, 72px);
  border-radius: 36px 36px 0 0;
  background: var(--bg);
  box-shadow: 0 -20px 50px -20px rgba(0, 0, 0, 0.35);
}

.section {
  padding: clamp(44px, 6vw, 88px) 0;
}

.section .container {
  max-width: 1240px;
}

/* Geteiltes Layout: Titel links (haftet beim Scrollen), Inhalt rechts */
main.has-hero {
  counter-reset: sec;
}

main.has-hero .section > .container > h2::before {
  counter-increment: sec;
  content: counter(sec, decimal-leading-zero) " \2014";
  display: block;
  margin-bottom: 14px;
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  color: var(--primary);
}

@media (min-width: 961px) {
  main.has-hero .section > .container:has(> h2) {
    display: grid;
    grid-template-columns: minmax(240px, 0.32fr) minmax(0, 1fr);
    column-gap: clamp(32px, 5vw, 80px);
    align-items: start;
  }

  main.has-hero .section > .container:has(> h2) > * {
    grid-column: 2;
    min-width: 0;
  }

  main.has-hero .section > .container:has(> h2) > h2 {
    grid-column: 1;
    grid-row: 1 / span 99;
    position: sticky;
    top: calc(var(--h-topbar, 40px) + var(--h-header, 76px) + 28px);
    margin: 0;
    font-size: clamp(1.75rem, 2.8vw, 3rem);
    /* Wörter nie mitten im Wort trennen; zu lange Wörter verkleinert theme.js (fitHeadings) */
    overflow-wrap: normal;
    hyphens: manual;
  }

  main.has-hero .section > .container:has(> h2) > .section-subtitle {
    margin: 0 0 28px;
  }
}

/* Wechselnde Bänder: jede Sektion überlappt die vorige mit geschwungener Oberkante */
.section ~ .section {
  position: relative;
  margin-top: -40px;
  padding-top: calc(clamp(44px, 6vw, 88px) + 40px);
  border-radius: 40px 40px 0 0;
}

.section.section-alt {
  background: color-mix(in srgb, var(--primary) 7%, var(--bg));
}

[data-theme="dark"] .section.section-alt {
  background: color-mix(in srgb, var(--primary) 14%, var(--bg)) !important;
}

.section h2 {
  margin: 0 0 clamp(18px, 3vw, 30px);
  font-size: clamp(2rem, 5vw, 3.4rem);
  line-height: 1.02;
  letter-spacing: -0.04em;
  font-weight: 700;
  color: inherit;
  background: none;
  -webkit-background-clip: border-box;
  background-clip: border-box;
}

.section h2::after {
  content: ".";
  color: var(--primary);
}

.section h2 > i,
.section h2 > svg {
  margin-inline-end: 0.3em;
  color: var(--primary);
  font-size: 0.7em;
}

.section-subtitle {
  margin: -4px 0 26px;
  font-size: 1.2rem;
}

.section-content {
  font-size: 1.08rem;
  line-height: 1.75;
}

.section-content img {
  max-width: 100%;
  height: auto;
  border-radius: var(--radius);
}

/* ---------- Karten ---------- */
.card,
.time-item,
.download-category-card {
  background: var(--bgcard);
  border: 0;
  border-radius: var(--radius);
  box-shadow: none;
}

.section-alt .card,
.section-alt .time-item {
  background: var(--bg);
}

.card {
  padding: clamp(22px, 3vw, 32px);
  border-radius: 10px 36px 10px 36px;
  border-inline-start: 4px solid var(--primary);
  transition: transform 0.45s var(--p-ease), box-shadow 0.45s var(--p-ease), background 0.45s var(--p-ease);
}

.card:hover {
  transform: translateY(-6px);
  background: var(--bg);
  box-shadow: var(--shadow-lg);
}

.card-title {
  color: var(--ink);
  letter-spacing: -0.02em;
}

/* ---------- Gebetszeiten: zusammenhängendes Farbband ---------- */
.times-grid {
  gap: 0;
  padding: 6px;
  border-radius: 10px 40px 10px 40px;
  background: linear-gradient(120deg, var(--primary), var(--primary-2));
  box-shadow: var(--shadow-md);
}

.time-item,
.section-alt .time-item {
  padding: 22px 12px;
  border-radius: 0;
  background: transparent;
  border-inline-end: 1px solid rgba(255, 255, 255, 0.22);
}

.time-item:last-child {
  border-inline-end: 0;
}

.time-item h3 {
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.78);
}

.time-item .val {
  color: #fff;
  letter-spacing: -0.04em;
  font-variant-numeric: tabular-nums;
}

/* ---------- Buttons ---------- */
.btn {
  padding: 14px 28px;
  border-radius: 8px 22px 8px 22px;
  background: var(--primary);
  box-shadow: none;
  transition: transform 0.3s var(--p-ease), background 0.3s var(--p-ease), gap 0.3s var(--p-ease);
}

.btn::after {
  content: "\2192";
}

[dir="rtl"] .btn::after {
  content: "\2190";
}

.btn:hover {
  gap: 16px;
  transform: translateY(-2px);
  background: var(--primary-2);
  box-shadow: none;
}

.map-wrap,
.map-wrap iframe,
.mySwiper,
.mySwiper .swiper-slide img {
  border-radius: var(--radius);
}

.map-wrap {
  box-shadow: none;
  border: 1px solid var(--p-line);
}

/* ---------- Formulare ---------- */
.section input[type="text"],
.section input[type="email"],
.section input[type="tel"],
.section input[type="number"],
.section select,
.section textarea {
  border: 2px solid transparent;
  border-radius: 14px;
  background: var(--bgcard);
  color: inherit;
  font: inherit;
  padding: 13px 16px;
  transition: border-color 0.25s var(--p-ease), background 0.25s var(--p-ease);
}

.section input:focus,
.section select:focus,
.section textarea:focus {
  outline: none;
  border-color: var(--primary);
  background: var(--bg);
}

/* ---------- Footer ---------- */
.site-footer {
  margin-top: 0;
  padding: 40px 0;
  background: #0a0c10;
  color: #9aa3b0;
}

.site-footer a {
  color: #fff;
}

/* ---------- Schwebende Elemente ---------- */
.theme-toggle,
.back-to-top {
  background: var(--ink);
  color: var(--bg);
  box-shadow: var(--shadow-md);
}

#consentBanner {
  left: 12px !important;
  right: 12px !important;
  bottom: 12px !important;
  max-width: 720px;
  margin-inline: auto;
  border: 0 !important;
  border-radius: 20px;
  box-shadow: var(--shadow-lg);
}

#consentBanner button {
  border-radius: 12px !important;
}

@media (max-width: 840px) {
  .site-header .nav {
    background: var(--bg);
    border-radius: 18px;
  }

  .hero-cover h1,
  .hero-cover-title {
    max-width: none;
  }

  .hero-cover-scroll {
    display: none;
  }

  .hero-cover + .section,
  .section.hero-next,
  .hero-cover--page + main {
    border-radius: 26px 26px 0 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-cover-bg,
  .hero-cover-scroll {
    animation: none;
    transform: none;
  }

  /* Statt Video das Standbild (Vereins-Hintergrundbild bzw. Farbfläche) zeigen */
  .hero-cover-video {
    display: none;
  }
}

/* ================================================================
   Unterseiten: Spenden, Mitgliedsantrag, Downloads, Impressum, Datenschutz
   (diese Datei wird dort nach den seiteneigenen Styles geladen)
   ================================================================ */

body {
  background: var(--bg);
  color: var(--ink);
}

.donate-card,
.application-card,
.donors-list-card,
.downloads-section .download-category-card {
  background: var(--bgcard);
  border: 0;
  border-inline-start: 4px solid var(--primary);
  border-radius: 10px 36px 10px 36px;
  box-shadow: none;
  color: var(--ink);
}

.donate-header h1,
.application-header h1 {
  color: inherit;
  letter-spacing: -0.04em;
}

.donate-header p,
.application-header p,
.section-content p,
.custom-amount label,
.form-group label {
  color: var(--muted);
}

.form-section h3,
.amount-selection h3,
.legal h2,
.legal h3 {
  color: inherit;
  letter-spacing: -0.03em;
}

.form-section,
.form-section:hover {
  background: transparent;
  border-color: var(--p-line);
  border-radius: 8px 24px 8px 24px;
  box-shadow: none;
}

.amount-btn {
  border: 2px solid transparent;
  border-radius: 8px 20px 8px 20px;
  background: var(--bg);
  color: var(--ink);
}

.amount-btn:hover {
  border-color: var(--primary);
}

.amount-btn.selected {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
}

.custom-amount input,
.form-group input:not([type="checkbox"]):not([type="radio"]),
.form-group select,
.form-group textarea {
  border: 2px solid transparent;
  border-radius: 14px;
  background: var(--bg);
  color: var(--ink);
}

.custom-amount input:focus,
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  border-color: var(--primary);
  box-shadow: none;
  outline: none;
}

.payment-method {
  border: 2px solid transparent;
  border-radius: 8px 24px 8px 24px;
  background: var(--bg);
}

.payment-method.selected {
  border-color: var(--primary);
}

.btn-donate,
.btn-submit,
.btn-next {
  border: 0;
  border-radius: 8px 22px 8px 22px;
  background: var(--primary);
  color: #fff;
  box-shadow: none;
}

.btn-donate:hover:not(:disabled),
.btn-submit:hover:not(:disabled),
.btn-next:hover:not(:disabled) {
  background: var(--primary-2);
}

.btn-prev,
.btn-back {
  border-radius: 8px 22px 8px 22px;
}

.info-box {
  border-radius: 8px 24px 8px 24px;
}

.donor-item {
  border-radius: 8px 22px 8px 22px;
  background: var(--bg);
  color: var(--ink);
}

.campaign-banner {
  border-radius: 10px 40px 10px 40px;
}

.progress-container {
  background: var(--bg);
  border-bottom: 1px solid var(--p-line);
}

.progress-step,
.progress-step.active,
.progress-step.completed {
  color: var(--ink);
}

.downloads-section {
  padding: clamp(48px, 7vw, 96px) 0;
}

.downloads-section h1 {
  font-size: clamp(2.2rem, 6vw, 4rem);
  line-height: 1.02;
  letter-spacing: -0.04em;
}

.downloads-section .download-category-card {
  overflow: hidden;
}

.downloads-section .file-item {
  border-bottom-color: var(--p-line);
}

.downloads-section .file-item:hover {
  background: color-mix(in srgb, var(--primary) 7%, transparent);
}

.downloads-section .btn-success,
.downloads-section .download-btn {
  border: 0;
  border-radius: 8px 18px 8px 18px;
  background: var(--primary);
  color: #fff;
}

.legal {
  line-height: 1.8;
}

.legal a {
  color: var(--primary);
}
