﻿/* Cookie Consent – großes Modal, Overlay sperrt Seite bis Entscheidung */
:root {
  --cc-ink: #141b4d;
  --cc-muted: #5c6a8a;
  --cc-line: #e1e7f2;
  --cc-bg: #ffffff;
  --cc-soft: #eef3ff;
  --cc-primary: #2e7eed;
  --cc-primary-dark: #1a5fbe;
  --cc-indigo: #02225b;
  --cc-focus: #a3b3da;
  --cc-radius: 16px;
  --cc-font: "Inter", "Plus Jakarta Sans", "Segoe UI", system-ui, sans-serif;
}

html.cc-open,
html.cc-open body {
  overflow: hidden !important;
}

.cc-root {
  position: fixed;
  z-index: 10000;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(16px, 3vw, 32px);
  pointer-events: auto;
}

.cc-root[hidden] {
  display: none !important;
}

.cc-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.48);
  backdrop-filter: grayscale(0.35) brightness(0.72);
  -webkit-backdrop-filter: grayscale(0.35) brightness(0.72);
}

.cc-panel {
  position: relative;
  z-index: 1;
  width: min(920px, 100%);
  max-height: min(90dvh, 900px);
  overflow: auto;
  margin: 0;
  background: var(--cc-bg);
  color: var(--cc-ink);
  border: 1px solid var(--cc-line);
  border-radius: var(--cc-radius);
  box-shadow: 0 28px 80px -20px rgba(15, 23, 42, 0.55);
  padding: clamp(36px, 5vw, 56px) clamp(28px, 4.5vw, 52px);
  font-family: var(--cc-font);
}

.cc-main {
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.cc-copy {
  min-width: 0;
}

.cc-title {
  margin: 0 0 18px;
  font-size: clamp(1.65rem, 3vw, 2.15rem);
  font-weight: 700;
  line-height: 1.22;
  color: var(--cc-indigo);
  letter-spacing: -0.02em;
}

.cc-desc-block {
  display: grid;
  gap: 14px;
}

.cc-desc {
  margin: 0;
  font-size: clamp(1.02rem, 1.4vw, 1.12rem);
  line-height: 1.65;
  color: var(--cc-muted);
}

.cc-desc a {
  color: var(--cc-primary);
  text-decoration: underline;
  text-underline-offset: 2px;
  font-weight: 600;
}

.cc-desc a:hover {
  color: var(--cc-primary-dark);
}

.cc-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 8px;
}

.cc-actions--row {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 24px;
}

.cc-btn {
  appearance: none;
  margin: 0;
  min-height: 56px;
  padding: 16px 20px;
  border-radius: 10px;
  border: 2px solid var(--cc-primary);
  background: var(--cc-bg);
  color: var(--cc-primary-dark);
  font: inherit;
  font-size: 1.05rem;
  font-weight: 650;
  line-height: 1.2;
  cursor: pointer;
  text-align: center;
  width: 100%;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.cc-btn:hover {
  background: var(--cc-soft);
}

.cc-btn:focus-visible {
  outline: 3px solid var(--cc-focus);
  outline-offset: 2px;
}

.cc-actions .cc-btn:first-child {
  background: var(--cc-primary);
  border-color: var(--cc-primary);
  color: #fff;
}

.cc-actions .cc-btn:first-child:hover {
  background: var(--cc-primary-dark);
  border-color: var(--cc-primary-dark);
}

.cc-layer-settings .cc-title {
  color: var(--cc-indigo);
}

.cc-cats {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin: 12px 0 8px;
  max-height: min(42vh, 400px);
  overflow: auto;
  padding-right: 4px;
}

.cc-cat {
  border: 1px solid var(--cc-line);
  border-radius: 12px;
  padding: 18px 20px;
  background: var(--cc-soft);
}

.cc-cat-head {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  justify-content: space-between;
}

.cc-cat-title {
  min-width: 0;
  flex: 1;
}

.cc-cat-title strong {
  display: block;
  font-size: 1.1rem;
  color: var(--cc-ink);
  margin-bottom: 6px;
}

.cc-cat-title p {
  margin: 0;
  font-size: 0.98rem;
  line-height: 1.55;
  color: var(--cc-muted);
}

.cc-toggle-wrap {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
  flex: none;
}

.cc-obligatorisch {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--cc-primary-dark);
}

.cc-switch {
  position: relative;
  display: inline-flex;
  cursor: pointer;
}

.cc-switch input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.cc-switch-ui {
  width: 52px;
  height: 30px;
  border-radius: 999px;
  background: #c5d0da;
  border: 1px solid var(--cc-line);
  position: relative;
  transition: background 0.15s ease;
}

.cc-switch-ui::after {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 3px rgba(26, 35, 50, 0.25);
  transition: transform 0.15s ease;
}

.cc-switch input:checked + .cc-switch-ui {
  background: var(--cc-primary);
  border-color: var(--cc-primary);
}

.cc-switch input:checked + .cc-switch-ui::after {
  transform: translateX(22px);
}

.cc-switch input:disabled + .cc-switch-ui {
  opacity: 0.85;
  cursor: not-allowed;
}

.cc-switch input:focus-visible + .cc-switch-ui {
  outline: 3px solid var(--cc-focus);
  outline-offset: 2px;
}

.cc-float {
  position: fixed;
  z-index: 9990;
  left: 12px;
  bottom: 12px;
  appearance: none;
  border: 1px solid var(--cc-line);
  background: var(--cc-bg);
  color: var(--cc-primary-dark);
  font: inherit;
  font-size: 0.8rem;
  font-weight: 600;
  padding: 8px 12px;
  border-radius: 999px;
  cursor: pointer;
  box-shadow: 0 4px 16px -8px rgba(26, 35, 50, 0.35);
}

.cc-float:hover {
  background: var(--cc-soft);
}

.cc-float:focus-visible {
  outline: 3px solid var(--cc-focus);
  outline-offset: 2px;
}

@media (max-width: 720px) {
  .cc-actions,
  .cc-actions--row {
    grid-template-columns: 1fr;
  }

  .cc-btn {
    min-height: 52px;
  }

  .cc-panel {
    padding: 28px 18px 22px;
  }

  .cc-cat-head {
    flex-direction: column;
  }

  .cc-toggle-wrap {
    align-items: flex-start;
    flex-direction: row;
    width: 100%;
    justify-content: space-between;
  }
}

@media (prefers-reduced-motion: reduce) {
  .cc-btn,
  .cc-switch-ui,
  .cc-switch-ui::after {
    transition: none;
  }
}
