/* ============================================================
   Cookie Consent Manager – Styles
   Christian Breitschwerdt Ökosystem
   Navy / Gold Design – passend zu allen 5 Websites
   ============================================================ */

/* ── Banner ──────────────────────────────────────────────── */

#cb-cookie-banner {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 99999;
  background: rgba(10, 15, 35, 0.97);
  border-top: 2px solid rgba(232, 201, 122, 0.5);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  padding: 20px 24px;
  box-shadow: 0 -4px 30px rgba(0, 0, 0, 0.5);
}

.cb-cookie-banner-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
}

.cb-cookie-banner-text {
  flex: 1;
  min-width: 260px;
}

.cb-cookie-banner-text strong {
  display: block;
  color: #e8c97a;
  font-size: 1rem;
  margin-bottom: 6px;
  font-family: inherit;
}

.cb-cookie-banner-text p {
  color: #b0bec5;
  font-size: 0.875rem;
  line-height: 1.5;
  margin: 0;
}

.cb-cookie-banner-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
  flex-shrink: 0;
}

/* ── Buttons ─────────────────────────────────────────────── */

.cb-btn {
  display: inline-block;
  padding: 10px 20px;
  border-radius: 6px;
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: all 0.2s ease;
  white-space: nowrap;
  font-family: inherit;
  letter-spacing: 0.02em;
}

.cb-btn-primary {
  background: linear-gradient(135deg, #e8c97a, #c9a84c);
  color: #0a0f23;
}

.cb-btn-primary:hover {
  background: linear-gradient(135deg, #f0d890, #d4b060);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(232, 201, 122, 0.3);
}

.cb-btn-secondary {
  background: transparent;
  color: #e8c97a;
  border: 1px solid rgba(232, 201, 122, 0.5);
}

.cb-btn-secondary:hover {
  background: rgba(232, 201, 122, 0.1);
  border-color: #e8c97a;
}

.cb-btn-text {
  background: transparent;
  color: #78909c;
  font-weight: 400;
  padding: 10px 12px;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.cb-btn-text:hover {
  color: #b0bec5;
}

/* ── Link ────────────────────────────────────────────────── */

.cb-link {
  color: #e8c97a;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.cb-link:hover {
  color: #f0d890;
}

/* ── Modal Overlay ───────────────────────────────────────── */

#cb-cookie-modal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 100000;
  background: rgba(0, 0, 0, 0.75);
  align-items: center;
  justify-content: center;
  padding: 16px;
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}

.cb-cookie-modal-box {
  background: #0d1428;
  border: 1px solid rgba(232, 201, 122, 0.3);
  border-radius: 12px;
  max-width: 600px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
}

/* ── Modal Header ────────────────────────────────────────── */

.cb-cookie-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 24px 28px 16px;
  border-bottom: 1px solid rgba(232, 201, 122, 0.15);
}

.cb-cookie-modal-header h2 {
  color: #e8c97a;
  font-size: 1.25rem;
  font-weight: 700;
  margin: 0;
  font-family: inherit;
}

.cb-modal-close {
  background: transparent;
  border: none;
  color: #78909c;
  font-size: 1.5rem;
  cursor: pointer;
  padding: 4px 8px;
  line-height: 1;
  border-radius: 4px;
  transition: color 0.2s;
}

.cb-modal-close:hover {
  color: #e8c97a;
}

/* ── Modal Body ──────────────────────────────────────────── */

.cb-cookie-modal-body {
  padding: 20px 28px;
}

.cb-modal-intro {
  color: #90a4ae;
  font-size: 0.875rem;
  line-height: 1.6;
  margin: 0 0 20px;
}

.cb-cookie-category {
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 8px;
  padding: 16px 18px;
  margin-bottom: 12px;
  background: rgba(255, 255, 255, 0.02);
}

.cb-cookie-category-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.cb-cookie-category-header > div:first-child {
  flex: 1;
}

.cb-cookie-category-header strong {
  display: block;
  color: #eceff1;
  font-size: 0.9375rem;
  margin-bottom: 4px;
  font-family: inherit;
}

.cb-cookie-category-header p {
  color: #78909c;
  font-size: 0.8125rem;
  line-height: 1.5;
  margin: 0;
}

/* ── Toggle Switch ───────────────────────────────────────── */

.cb-toggle-switch {
  position: relative;
  display: inline-block;
  width: 48px;
  height: 26px;
  flex-shrink: 0;
  margin-top: 2px;
}

.cb-toggle-switch input {
  opacity: 0;
  width: 0;
  height: 0;
  position: absolute;
}

.cb-toggle-slider {
  position: absolute;
  cursor: pointer;
  inset: 0;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 26px;
  transition: background 0.3s;
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.cb-toggle-slider::before {
  content: '';
  position: absolute;
  height: 18px;
  width: 18px;
  left: 3px;
  bottom: 3px;
  background: #78909c;
  border-radius: 50%;
  transition: transform 0.3s, background 0.3s;
}

.cb-toggle-switch input:checked + .cb-toggle-slider {
  background: rgba(232, 201, 122, 0.25);
  border-color: rgba(232, 201, 122, 0.5);
}

.cb-toggle-switch input:checked + .cb-toggle-slider::before {
  transform: translateX(22px);
  background: #e8c97a;
}

.cb-toggle-switch input:focus + .cb-toggle-slider {
  outline: 2px solid rgba(232, 201, 122, 0.5);
  outline-offset: 2px;
}

/* "Immer aktiv" Label */
.cb-toggle {
  display: flex;
  align-items: center;
  flex-shrink: 0;
  margin-top: 2px;
}

.cb-toggle-label {
  font-size: 0.75rem;
  color: #e8c97a;
  font-weight: 600;
  white-space: nowrap;
  letter-spacing: 0.03em;
}

/* ── Modal Footer ────────────────────────────────────────── */

.cb-cookie-modal-footer {
  display: flex;
  gap: 12px;
  padding: 16px 28px 20px;
  border-top: 1px solid rgba(232, 201, 122, 0.15);
  flex-wrap: wrap;
}

.cb-cookie-modal-footer .cb-btn {
  flex: 1;
  min-width: 140px;
  text-align: center;
}

.cb-cookie-modal-legal {
  text-align: center;
  padding: 0 28px 20px;
  font-size: 0.8125rem;
  color: #546e7a;
}

/* ── Scrollbar im Modal ──────────────────────────────────── */

.cb-cookie-modal-box::-webkit-scrollbar {
  width: 6px;
}
.cb-cookie-modal-box::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.03);
}
.cb-cookie-modal-box::-webkit-scrollbar-thumb {
  background: rgba(232, 201, 122, 0.3);
  border-radius: 3px;
}

/* ── Responsive ──────────────────────────────────────────── */

@media (max-width: 640px) {
  .cb-cookie-banner-inner {
    flex-direction: column;
    align-items: stretch;
    gap: 16px;
  }
  .cb-cookie-banner-actions {
    flex-direction: column;
  }
  .cb-btn {
    width: 100%;
    text-align: center;
  }
  .cb-cookie-modal-header {
    padding: 20px 20px 14px;
  }
  .cb-cookie-modal-body {
    padding: 16px 20px;
  }
  .cb-cookie-modal-footer {
    padding: 14px 20px 16px;
    flex-direction: column;
  }
  .cb-cookie-modal-footer .cb-btn {
    flex: none;
    width: 100%;
  }
  .cb-cookie-modal-legal {
    padding: 0 20px 16px;
  }
}
