/* Cookie consent — matches cookie-consent.js (.cookie-consent-banner) */
.cookie-consent-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 9999;
  display: none;
  padding: 18px 20px;
  padding-bottom: calc(18px + env(safe-area-inset-bottom, 0));
  background: var(--space-blue, #ffffff);
  color: var(--star-white, #4c1d95);
  border-top: var(--g20-border, 2px solid #e9d5ff);
  box-shadow: var(--shadow-lift, 0 -8px 32px rgba(167, 139, 250, 0.2));
  font-family: var(--g20-font, system-ui, sans-serif);
  animation: tgn-cookie-slide-up 0.35s ease-out;
}

@keyframes tgn-cookie-slide-up {
  from { transform: translateY(100%); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

.cookie-consent-banner.show { display: block; }

.cookie-consent-content {
  max-width: 1180px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.cookie-consent-text { flex: 1; min-width: 280px; }

.cookie-consent-text > div:first-child {
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 6px;
  color: var(--nebula-pink, #f472b6);
}

.cookie-consent-text p {
  margin: 0 0 6px;
  font-size: 0.88rem;
  line-height: 1.55;
  color: var(--ink-muted, #7c3aed);
}

.cookie-consent-text a {
  color: var(--comet-cyan, #38bdf8);
  font-weight: 600;
  text-decoration: underline;
}

.cookie-consent-buttons {
  display: flex;
  flex-shrink: 0;
  flex-wrap: wrap;
  gap: 8px;
}

.cookie-btn {
  padding: 10px 18px;
  border-radius: var(--g20-radius-sm, 16px);
  font-family: inherit;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  border: 1px solid transparent;
  transition: background var(--transition-fast, 0.2s ease), color var(--transition-fast, 0.2s ease);
}

.cookie-btn-accept {
  background: var(--nebula-pink, #f472b6);
  color: #fff;
  border-color: var(--nebula-pink, #f472b6);
}

.cookie-btn-reject,
.cookie-btn-settings {
  background: var(--space-dark, #fef6ff);
  color: var(--star-white, #4c1d95);
  border-color: var(--line-soft, #e9d5ff);
}

.cookie-btn-reject:hover,
.cookie-btn-settings:hover {
  border-color: var(--planet-purple, #a78bfa);
}

.cookie-settings-modal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 10000;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(76, 29, 149, 0.45);
}

.cookie-settings-modal.show { display: flex; }

.cookie-settings-content {
  width: 100%;
  max-width: 520px;
  max-height: 90vh;
  overflow-y: auto;
  padding: 24px;
  border-radius: var(--g20-radius, 24px);
  background: var(--space-blue, #fff);
  color: var(--star-white, #4c1d95);
  border: var(--g20-border, 2px solid #e9d5ff);
  box-shadow: var(--shadow-lift);
  animation: tgn-cookie-modal-in 0.25s ease-out;
}

@keyframes tgn-cookie-modal-in {
  from { opacity: 0; transform: scale(0.96); }
  to { opacity: 1; transform: scale(1); }
}

.cookie-settings-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 18px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line-soft, #e9d5ff);
}

.cookie-settings-header > div { font-size: 1.2rem; font-weight: 700; }

.cookie-settings-close {
  padding: 0;
  border: none;
  background: none;
  font-size: 1.75rem;
  line-height: 1;
  color: var(--ink-muted, #7c3aed);
  cursor: pointer;
}

.cookie-setting-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 0;
  border-bottom: 1px solid var(--line-soft, #e9d5ff);
}

.cookie-setting-item:last-child { border-bottom: none; }

.cookie-setting-info > div { margin-bottom: 4px; font-size: 0.95rem; font-weight: 600; }

.cookie-setting-info p {
  margin: 0;
  font-size: 0.82rem;
  line-height: 1.45;
  color: var(--ink-muted, #7c3aed);
}

.cookie-toggle { position: relative; flex-shrink: 0; width: 48px; height: 26px; }
.cookie-toggle input { opacity: 0; width: 0; height: 0; }

.cookie-toggle-slider {
  position: absolute;
  inset: 0;
  cursor: pointer;
  border-radius: 999px;
  background: #e9d5ff;
  transition: background 0.25s ease;
}

.cookie-toggle-slider::before {
  content: "";
  position: absolute;
  left: 3px;
  bottom: 3px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #fff;
  transition: transform 0.25s ease;
}

.cookie-toggle input:checked + .cookie-toggle-slider {
  background: var(--comet-cyan, #38bdf8);
}

.cookie-toggle input:checked + .cookie-toggle-slider::before {
  transform: translateX(22px);
}

.cookie-toggle.disabled { opacity: 0.55; cursor: not-allowed; }

.cookie-settings-footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid var(--line-soft, #e9d5ff);
}

.cookie-settings-footer .cookie-btn-accept {
  background: var(--planet-purple, #a78bfa);
  color: #fff;
}

@media (max-width: 768px) {
  .cookie-consent-banner { bottom: var(--g20-mobile-nav-h, 72px); }
  .cookie-consent-content { flex-direction: column; text-align: center; }
  .cookie-consent-buttons { width: 100%; justify-content: center; }
  .cookie-consent-buttons .cookie-btn { flex: 1; min-width: 0; }
  .cookie-setting-item { flex-direction: column; align-items: flex-start; }
  .cookie-toggle { align-self: flex-end; }
  .cookie-settings-footer { flex-direction: column; }
  .cookie-settings-footer .cookie-btn { width: 100%; }
}
