/* =====================================================================
   BEUP. – Eigenes Cookie-Consent-Tool (DSGVO: Opt-in, granular, widerrufbar)
   Design exakt in der BEUP-CI: dunkel, Fraunces-Headline, Akzent #ff5436.
   Zentriertes Modal. Keine Abhaengigkeiten.
   ===================================================================== */

.bc-root {
  --bc-bg:          #18181b;   /* Karte, wie .card auf der Website */
  --bc-bg-deep:     #0c0c0d;
  --bc-line:        #26262b;
  --bc-accent:      #ff5436;
  --bc-accent-deep: #e23c1f;
  --bc-text:        #f4f4f5;
  --bc-text-soft:   #b6b6bd;
  --bc-muted:       #a1a1aa;
  --bc-surface:     #26262b;   /* Sekundaer-Button-Flaeche */
  --bc-surface-hi:  #34343b;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}
.bc-root, .bc-root * { box-sizing: border-box; }

/* ---------- Overlay (abdunkeln + leichter Blur, Fokus aufs Banner) ---------- */
.bc-overlay {
  position: fixed; inset: 0; z-index: 2147483000;
  background: rgba(6,6,7,.66);
  backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px);
  opacity: 0; visibility: hidden; transition: opacity .28s ease, visibility .28s;
}
.bc-overlay.bc-show { opacity: 1; visibility: visible; }

/* ---------- Banner-Karte: zentriert ---------- */
.bc-banner {
  position: fixed; z-index: 2147483001;
  top: 50%; left: 50%;
  transform: translate(-50%, calc(-50% + 14px));
  width: min(540px, calc(100vw - 32px));
  max-height: calc(100vh - 40px); overflow-y: auto;
  background: var(--bc-bg); color: var(--bc-text-soft);
  border: 1px solid var(--bc-line); border-top: 3px solid var(--bc-accent);
  border-radius: 18px;
  box-shadow: 0 40px 100px -25px rgba(0,0,0,.75), 0 0 0 1px rgba(255,255,255,.02) inset;
  padding: clamp(22px, 3vw, 32px);
  opacity: 0; visibility: hidden;
  transition: opacity .3s ease, transform .3s cubic-bezier(.2,0,.2,1), visibility .3s;
}
.bc-banner.bc-show { opacity: 1; visibility: visible; transform: translate(-50%, -50%); }

.bc-brand { display: flex; align-items: center; gap: 10px; margin-bottom: 16px; }
.bc-brand-logo { font-weight: 800; font-size: 1.1rem; letter-spacing: -.02em; color: var(--bc-text); }
.bc-brand-logo span { color: var(--bc-accent); }

.bc-title {
  font-family: inherit;                 /* fette Sans-Serif wie die Website-Headlines */
  font-weight: 700; font-size: clamp(1.4rem, 2.7vw, 1.75rem);
  letter-spacing: -.03em; line-height: 1.1; color: var(--bc-text); margin: 0 0 12px;
}
.bc-text { font-size: .94rem; line-height: 1.6; color: var(--bc-text-soft); margin: 0 0 20px; }
.bc-text a { color: var(--bc-accent); text-decoration: underline; text-underline-offset: 2px; }
.bc-text a:hover { color: var(--bc-accent-deep); }

/* ---------- Einstellungen (Kategorien) ---------- */
.bc-settings { display: none; margin: 0 0 20px; border-top: 1px solid var(--bc-line); }
.bc-settings.bc-open { display: block; }
.bc-cat {
  display: flex; align-items: flex-start; gap: 14px;
  padding: 16px 0; border-bottom: 1px solid var(--bc-line);
}
.bc-cat-info { flex: 1; min-width: 0; }
.bc-cat-name { font-weight: 600; font-size: .95rem; color: var(--bc-text); margin-bottom: 3px; }
.bc-cat-desc { font-size: .85rem; line-height: 1.45; color: var(--bc-muted); }

/* Toggle-Switch */
.bc-switch { position: relative; flex-shrink: 0; width: 44px; height: 26px; }
.bc-switch input { position: absolute; opacity: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }
.bc-slider {
  position: absolute; inset: 0; border-radius: 999px;
  background: #3f3f46; transition: background .2s ease; pointer-events: none;
}
.bc-slider::before {
  content: ""; position: absolute; top: 3px; left: 3px;
  width: 20px; height: 20px; border-radius: 50%; background: #fff;
  box-shadow: 0 1px 3px rgba(0,0,0,.4); transition: transform .2s ease;
}
.bc-switch input:checked + .bc-slider { background: var(--bc-accent); }
.bc-switch input:checked + .bc-slider::before { transform: translateX(18px); }
.bc-switch input:disabled + .bc-slider { background: var(--bc-accent); opacity: .45; }
.bc-switch input:disabled { cursor: not-allowed; }

/* ---------- Buttons ---------- */
.bc-actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.bc-btn {
  border: 1px solid transparent; border-radius: 999px;
  padding: 12px 22px; font-weight: 600; font-size: .92rem; cursor: pointer;
  transition: transform .15s ease, background .2s ease, border-color .2s ease, color .2s ease;
  font-family: inherit; line-height: 1;
}
.bc-btn:hover { transform: translateY(-1px); }
.bc-accept { background: var(--bc-accent); color: #fff; border-color: var(--bc-accent); flex: 1; min-width: 130px; }
.bc-accept:hover { background: var(--bc-accent-deep); border-color: var(--bc-accent-deep); }
/* Ablehnen: gleiche Groesse/Prominenz, neutrale Flaeche (gut sichtbar auf dunkel) */
.bc-reject { background: var(--bc-surface); color: var(--bc-text); border-color: var(--bc-line); flex: 1; min-width: 130px; }
.bc-reject:hover { background: var(--bc-surface-hi); border-color: var(--bc-surface-hi); }
.bc-save { background: var(--bc-accent); color: #fff; border-color: var(--bc-accent); flex: 1; min-width: 130px; }
.bc-save:hover { background: var(--bc-accent-deep); }
.bc-settings-btn { background: transparent; color: var(--bc-muted); border-color: var(--bc-line); flex: 1; min-width: 130px; }
.bc-settings-btn:hover { color: var(--bc-text); border-color: var(--bc-muted); }

/* ---------- Wiederaufruf-Button (unten links) ---------- */
.bc-reopen {
  position: fixed; left: 18px; bottom: 18px; z-index: 2147482000;
  width: 46px; height: 46px; border-radius: 50%;
  background: var(--bc-bg); color: var(--bc-accent);
  border: 1px solid var(--bc-line);
  box-shadow: 0 10px 28px -10px rgba(0,0,0,.7);
  display: none; align-items: center; justify-content: center; cursor: pointer;
  transition: transform .15s ease, border-color .2s ease;
}
.bc-reopen.bc-show { display: flex; }
.bc-reopen:hover { transform: translateY(-2px); border-color: var(--bc-accent); }
.bc-reopen svg { width: 22px; height: 22px; }

@media (max-width: 560px) {
  .bc-banner { width: calc(100vw - 24px); padding: 22px; }
  .bc-accept, .bc-reject, .bc-save, .bc-settings-btn { flex: 1 1 100%; }
}

@media (prefers-reduced-motion: reduce) {
  .bc-overlay, .bc-banner, .bc-btn, .bc-reopen, .bc-slider, .bc-slider::before { transition: none !important; }
}
