/* ═══════════════════════════════════════════════════════════════
   VFIB FRANKENTHAL — KOMPONENTEN
   ═══════════════════════════════════════════════════════════════ */

/* ═══ TOPBAR / NAVIGATION ═══ */
.topbar {
  position: sticky;
  top: 0;
  z-index: 200;
  background: color-mix(in srgb, var(--cream-50) 92%, transparent);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-gold-soft);
}
.topbar__inner {
  display: flex;
  align-items: center;
  gap: var(--space-5);
  min-height: 72px;
}
.brand {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  text-decoration: none;
  margin-right: auto;
}
.brand__emblem { height: 44px; width: auto; }
.brand__name {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.05rem;
  line-height: 1.2;
  color: var(--green-800);
}
.brand__sub {
  display: block;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold-600);
}
.nav { display: none; align-items: center; gap: var(--space-5); }
.nav a {
  text-decoration: none;
  white-space: nowrap;
  font-weight: 600;
  font-size: var(--fs-small);
  color: var(--text-body);
  padding: 6px 2px;
  border-bottom: 2px solid transparent;
  transition: color var(--t-fast), border-color var(--t-fast);
}
.nav a:hover { color: var(--green-800); border-bottom-color: var(--gold-500); }
@media (min-width: 960px) {
  .nav { display: flex; }
}

/* Topbar kompakt auf schmalen Screens */
.nav-cta__short { display: none; }
@media (max-width: 768px) {
  .topbar__inner { gap: var(--space-3); }
  .brand__sub { display: none; }
  .brand__name { white-space: nowrap; }
}
@media (max-width: 640px) {
  .topbar__inner { gap: var(--space-2); min-height: 60px; }
  .brand__emblem { height: 34px; }
  .brand__name { display: none; }
  .lang-switch button { padding: 4px 10px; }
  .topbar .btn--sm { padding: 8px 14px; }
  .nav-cta__long { display: none; }
  .nav-cta__short { display: inline; }
}

/* ═══ SPRACHUMSCHALTER ═══ */
.lang-switch {
  display: flex;
  gap: 2px;
  padding: 3px;
  background: var(--cream-200);
  border-radius: var(--radius-pill);
  border: 1px solid var(--border-gold-soft);
}
.lang-switch button {
  padding: 5px 14px;
  border-radius: var(--radius-pill);
  font-size: 0.8125rem;
  font-weight: 700;
  color: var(--text-muted);
  transition: background var(--t-fast), color var(--t-fast);
}
.lang-switch button[aria-pressed="true"] {
  background: var(--green-800);
  color: var(--text-on-dark);
}
.lang-switch button:not([aria-pressed="true"]):hover { color: var(--green-800); }

/* ═══ BUTTONS ═══ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 28px;
  border-radius: var(--radius-pill);
  font-weight: 700;
  font-size: var(--fs-body);
  text-decoration: none;
  white-space: nowrap;
  border: 1.5px solid transparent;
  transition: transform var(--t-fast) var(--ease-out),
              box-shadow var(--t-fast),
              background var(--t-fast),
              color var(--t-fast),
              border-color var(--t-fast);
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn svg { width: 18px; height: 18px; flex: none; }

.btn--primary {
  background: var(--green-800);
  color: var(--text-on-dark);
  box-shadow: var(--shadow-sm);
}
.btn--primary:hover { background: var(--green-700); box-shadow: var(--shadow-md); }

.btn--gold {
  background: transparent;
  color: var(--green-800);
  border-color: var(--gold-500);
}
.btn--gold:hover { background: var(--gold-100); }

.btn--ghost { color: var(--green-800); }
.btn--ghost:hover { background: var(--green-50); }

.btn--paypal { background: var(--paypal); color: #fff; box-shadow: var(--shadow-sm); }
.btn--paypal:hover { background: #00257A; box-shadow: var(--shadow-md); }

.btn--whatsapp { background: var(--whatsapp); color: #fff; }
.btn--whatsapp:hover { background: #168F43; }

.btn--lg { padding: 17px 36px; font-size: 1.0625rem; }
.btn--sm { padding: 9px 18px; font-size: var(--fs-small); }
.btn--block { width: 100%; }

.on-dark .btn--gold { color: var(--gold-300); border-color: var(--gold-500); }
.on-dark .btn--gold:hover { background: rgba(193, 154, 75, 0.12); }

/* ═══ ORNAMENT-TRENNER  (Linie · Herz · Linie) ═══ */
.ornament {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  justify-content: center;
  color: var(--gold-500);
  margin-block: var(--space-2);
}
.ornament::before, .ornament::after {
  content: "";
  height: 1px;
  width: clamp(40px, 8vw, 96px);
  background: linear-gradient(90deg, transparent, var(--gold-500));
}
.ornament::after { background: linear-gradient(90deg, var(--gold-500), transparent); }
.ornament svg { width: 18px; height: 18px; }

/* ═══ IKONEN-KREIS (Goldring) ═══ */
.icon-circle {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  flex: none;
  background: var(--green-800);
  color: var(--gold-300);
  box-shadow: 0 0 0 1.5px var(--gold-500), 0 0 0 5px rgba(193, 154, 75, 0.15);
}
.icon-circle svg { width: 28px; height: 28px; }
.icon-circle--light {
  background: var(--cream-100);
  color: var(--green-700);
  box-shadow: 0 0 0 1.5px var(--gold-500);
}
.icon-circle--sm { width: 48px; height: 48px; }
.icon-circle--sm svg { width: 22px; height: 22px; }

/* ═══ KARTEN ═══ */
.card {
  background: var(--surface-card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-soft);
  box-shadow: var(--shadow-md);
  padding: clamp(24px, 3.5vw, 40px);
}
.card--gold {
  border: 1px solid var(--border-gold);
  box-shadow: var(--shadow-sm);
  background: var(--white);
}
.card--cream { background: var(--cream-100); border-color: var(--border-gold-soft); }

/* Dunkelgrüne Karte mit Goldring (Flyer-Motiv) */
.card--dark {
  background: var(--surface-dark);
  border-radius: var(--radius-lg);
  border: 1px solid var(--gold-500);
  box-shadow: var(--shadow-md), inset 0 0 0 1px rgba(193, 154, 75, 0.15);
  color: var(--text-on-dark-muted);
  padding: clamp(24px, 3.5vw, 40px);
}

/* ═══ SPENDENBETRÄGE ═══ */
.amount-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-3);
}
@media (min-width: 640px) { .amount-grid { grid-template-columns: repeat(4, 1fr); } }

.amount-chip {
  position: relative;
  display: grid;
  justify-items: center;
  gap: 2px;
  padding: 18px 12px 14px;
  background: var(--green-800);
  color: var(--cream-50);
  border-radius: var(--radius-md);
  border: 1px solid var(--gold-500);
  box-shadow: inset 0 0 0 1px rgba(193, 154, 75, 0.18);
  transition: transform var(--t-fast) var(--ease-out), box-shadow var(--t-fast), background var(--t-fast);
}
.amount-chip:hover { transform: translateY(-2px); box-shadow: var(--shadow-gold); }
.amount-chip .amount {
  font-family: var(--font-display);
  font-size: 1.75rem;
  font-weight: 700;
  line-height: 1.1;
}
.amount-chip .label {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold-300);
}
.amount-chip[aria-checked="true"] {
  background: var(--green-700);
  box-shadow: 0 0 0 2.5px var(--gold-500), var(--shadow-gold);
}
.amount-chip .check {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--gold-500);
  color: var(--green-900);
  opacity: 0;
  transform: scale(0.5);
  transition: opacity var(--t-fast), transform var(--t-fast) var(--ease-out);
}
.amount-chip[aria-checked="true"] .check { opacity: 1; transform: scale(1); }
.amount-chip .check svg { width: 12px; height: 12px; }

/* Freier Betrag */
.amount-custom {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: var(--space-4);
  padding: 14px 20px;
  background: var(--white);
  border: 1.5px dashed var(--gold-500);
  border-radius: var(--radius-md);
  transition: border-color var(--t-fast), box-shadow var(--t-fast);
}
.amount-custom:focus-within { border-style: solid; box-shadow: var(--shadow-gold); }
.amount-custom .label {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold-700);
  flex: none;
}
.amount-custom input {
  flex: 1;
  min-width: 60px;
  border: none;
  outline: none;
  background: transparent;
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--green-800);
}
.amount-custom input::placeholder { color: var(--text-muted); font-family: var(--font-body); font-size: 1rem; font-weight: 500; }
.amount-custom .currency {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--gold-600);
}

/* ═══ BANKVERBINDUNG ═══ */
.bank-row + .bank-row { margin-top: 10px; }
.bank-rows {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.bank-rows .bank-row { flex: 1; margin-top: 0; }
.bank-row {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: 10px 16px;
  background: var(--cream-50);
  border: 1px solid var(--border-gold-soft);
  border-radius: var(--radius-sm);
}
.bank-row__text { flex: 1; display: grid; gap: 1px; min-width: 0; }
.bank-row .label {
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gold-700);
}
.bank-row .value {
  font-weight: 700;
  font-size: 1.0625rem;
  color: var(--green-900);
  font-variant-numeric: tabular-nums;
  word-break: break-word;
  line-height: 1.35;
}
.bank-row .value--long { font-size: 0.9375rem; }
.copy-btn {
  flex: none;
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  color: var(--green-700);
  border: 1px solid var(--border-soft);
  background: var(--white);
  transition: background var(--t-fast), border-color var(--t-fast), color var(--t-fast);
}
.copy-btn:hover { background: var(--gold-100); border-color: var(--border-gold); }
.copy-btn svg { width: 17px; height: 17px; }
.copy-btn.copied { background: var(--green-50); color: var(--success); border-color: var(--success); }

/* ═══ QR-KACHEL ═══ */
.qr-tile {
  display: grid;
  justify-items: center;
  gap: var(--space-3);
  text-align: center;
}
.qr-tile img {
  width: 184px;
  height: 184px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-gold);
  box-shadow: var(--shadow-sm);
  background: #fff;
  padding: 8px;
}
.qr-tile a { font-size: var(--fs-small); font-weight: 600; color: var(--green-700); }

/* ═══ WERTE-LEISTE ═══ */
.values-band { background: var(--surface-dark); }
.values-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-5);
}
@media (min-width: 560px) { .values-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .values-grid { grid-template-columns: repeat(4, 1fr); } }
.value-item {
  display: flex;
  align-items: center;
  gap: var(--space-4);
}
.value-item .v-title {
  font-weight: 800;
  font-size: 0.9375rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-on-dark);
}
.value-item .v-sub {
  font-size: var(--fs-small);
  color: var(--gold-300);
}

/* ═══ FOTO-RAHMEN ═══ */
.photo-frame {
  border-radius: var(--radius-lg);
  overflow: hidden;
  isolation: isolate; /* Safari: erzwingt korrektes Radius-Clipping */
  /* iOS-Safari clippt das <img> sonst NICHT am elliptischen Bogen-Radius
     (overflow:hidden allein reicht nicht). Eigene Compositing-Ebene erzwingt
     das runde Clipping der Kind-Elemente. */
  transform: translateZ(0);
  -webkit-transform: translateZ(0);
  box-shadow: var(--ring-gold), var(--shadow-lg);
  background: var(--cream-200);
}
.photo-frame img { width: 100%; height: 100%; object-fit: cover; border-radius: inherit; }
.photo-frame--arch { border-radius: var(--radius-arch); }
body.no-arch .photo-frame--arch { border-radius: var(--radius-lg); }

/* ═══ KAMPAGNEN-BANNER (saisonal) ═══ */
.campaign {
  background:
    radial-gradient(ellipse at 18% 0%, rgba(193, 154, 75, 0.16) 0%, transparent 55%),
    var(--green-900);
  border-block: 1px solid var(--gold-600);
}
.campaign__inner {
  display: grid;
  gap: var(--space-5);
  justify-items: center;
  text-align: center;
  padding-block: clamp(36px, 5vw, 56px);
}

/* Countdown */
.countdown { display: flex; gap: var(--space-3); flex-wrap: wrap; justify-content: center; }
.countdown__box {
  display: grid;
  justify-items: center;
  gap: 2px;
  min-width: 84px;
  padding: 14px 10px 10px;
  background: rgba(252, 248, 239, 0.06);
  border: 1px solid var(--gold-600);
  border-radius: var(--radius-md);
}
.countdown__box .value {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 700;
  color: var(--cream-50);
  font-variant-numeric: tabular-nums;
  line-height: 1;
}
.countdown__box .unit {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gold-300);
}

/* ═══ MODAL ═══ */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 500;
  display: grid;
  place-items: center;
  padding: var(--space-4);
  background: rgba(12, 32, 24, 0.55);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--t-mid), visibility var(--t-mid);
}
.modal-overlay.open { opacity: 1; visibility: visible; }
.modal {
  width: 100%;
  max-width: 460px;
  max-height: 86dvh;
  overflow: auto;
  background: var(--cream-50);
  border-radius: var(--radius-lg);
  border: 1px solid var(--gold-500);
  box-shadow: var(--shadow-lg);
  padding: var(--space-6);
  transform: translateY(16px) scale(0.97);
  transition: transform var(--t-mid) var(--ease-out);
}
.modal-overlay.open .modal { transform: none; }
.modal__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  margin-bottom: var(--space-4);
}
.modal__close {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  color: var(--text-muted);
  transition: background var(--t-fast), color var(--t-fast);
}
.modal__close:hover { background: var(--cream-200); color: var(--ink); }
.modal__close svg { width: 18px; height: 18px; }

/* ═══ TOAST ═══ */
.toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translate(-50%, 16px);
  z-index: 600;
  padding: 12px 24px;
  background: var(--green-900);
  color: var(--cream-50);
  font-weight: 600;
  font-size: var(--fs-small);
  border: 1px solid var(--gold-500);
  border-radius: var(--radius-pill);
  box-shadow: var(--shadow-lg);
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--t-mid), transform var(--t-mid) var(--ease-out), visibility var(--t-mid);
}
.toast.show { opacity: 1; visibility: visible; transform: translate(-50%, 0); }

/* ═══ FOOTER ═══ */
.footer {
  background: var(--green-950);
  color: var(--text-on-dark-muted);
  padding-block: clamp(40px, 6vw, 64px) var(--space-6);
}
.footer__blessing {
  text-align: center;
  margin-bottom: var(--space-6);
}
.footer__grid {
  display: grid;
  gap: var(--space-5);
  padding-block: var(--space-6);
  border-block: 1px solid rgba(193, 154, 75, 0.25);
}
@media (min-width: 768px) {
  .footer__grid { grid-template-columns: 1fr auto; align-items: center; }
}
.footer__org strong { color: var(--text-on-dark); display: block; margin-bottom: 4px; }
.footer__legal {
  display: flex;
  gap: var(--space-4);
  flex-wrap: wrap;
  font-size: var(--fs-small);
}
.footer__legal a { color: var(--gold-300); text-decoration: none; }
.footer__legal a:hover { text-decoration: underline; }
.footer__copy {
  text-align: center;
  font-size: 0.8125rem;
  color: rgba(200, 207, 191, 0.6);
  padding-top: var(--space-5);
}
