
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
}

#cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: var(--c-dark);
  color: var(--c-fg-on-dark);
  padding: var(--space-4);
  border-top: 2px solid var(--c-accent);
  box-shadow: 0 -2px 12px rgba(0, 0, 0, 0.15);
  font-family: var(--font-body);
  font-size: clamp(0.875rem, 1vw, 1rem);
  line-height: 1.5;
}

#cookie-banner .container {
  max-width: 1400px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
}

#cookie-banner-text {
  flex: 1;
  min-width: 200px;
}

#cookie-banner-text p {
  margin: 0 0 var(--space-2) 0;
}

#cookie-banner-text a {
  color: var(--c-accent-lt);
  text-decoration: underline;
  cursor: pointer;
}

#cookie-banner-text a:hover {
  color: var(--c-fg-on-dark);
}

#cookie-banner-buttons {
  display: flex;
  gap: var(--space-2);
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
}

#cookie-banner button {
  padding: var(--space-2) var(--space-4);
  border: none;
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.2s;
  white-space: nowrap;
}

#cookie-accept-all {
  background: var(--c-accent);
  color: var(--c-bg);
  border: none;
}

#cookie-accept-all:hover {
  background: var(--c-accent-hover);
}

#cookie-reject-all {
  background: transparent;
  color: var(--c-fg-on-dark);
  border: 1px solid var(--c-fg-on-dark);
}

#cookie-reject-all:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--c-fg-on-dark);
}

#cookie-customize {
  background: transparent;
  color: var(--c-fg-on-dark);
  border: 1px solid var(--c-fg-on-dark);
}

#cookie-customize:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--c-fg-on-dark);
}

#cookie-customize-modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 2000;
  align-items: center;
  justify-content: center;
}

#cookie-customize-modal.active {
  display: flex;
}

.cookie-modal-content {
  background: var(--c-bg);
  color: var(--c-fg);
  border-radius: var(--radius-md);
  padding: var(--space-6);
  max-width: 600px;
  width: 90%;
  max-height: 80%;
  overflow-y: auto;
  font-family: var(--font-body);
}

.cookie-modal-content h2 {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 4vw, 2rem);
  margin: 0 0 var(--space-4) 0;
  color: var(--c-fg);
}

.cookie-modal-content p {
  margin: 0 0 var(--space-4) 0;
  line-height: 1.6;
  color: var(--c-muted);
}

.cookie-category {
  display: flex;
  align-items: flex-start;
  gap: var(--space-3);
  margin-bottom: var(--space-4);
  padding: var(--space-3);
  background: var(--c-bg);
  border: 1px solid var(--c-muted);
  border-radius: var(--radius-sm);
}

.cookie-category input[type="checkbox"] {
  margin-top: 4px;
  cursor: pointer;
  accent-color: var(--c-accent);
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.cookie-category input[type="checkbox"]:disabled {
  cursor: not-allowed;
  opacity: 0.5;
}

.cookie-category-text {
  flex: 1;
}

.cookie-category-text strong {
  display: block;
  color: var(--c-fg);
  font-weight: 600;
  margin-bottom: var(--space-1);
}

.cookie-category-text small {
  display: block;
  color: var(--c-muted);
  font-size: 0.875rem;
}

.cookie-modal-buttons {
  display: flex;
  gap: var(--space-3);
  justify-content: flex-end;
  margin-top: var(--space-5);
  flex-wrap: wrap;
}

.cookie-modal-buttons button {
  padding: var(--space-3) var(--space-5);
  border: none;
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.2s;
}

#cookie-save-custom {
  background: var(--c-accent);
  color: var(--c-bg);
  border: none;
}

#cookie-save-custom:hover {
  background: var(--c-accent-hover);
}

#cookie-cancel-custom {
  background: transparent;
  color: var(--c-fg);
  border: 1px solid var(--c-border);
}

#cookie-cancel-custom:hover {
  background: var(--c-surface);
  border-color: var(--c-border);
}

@media (max-width: 640px) {
  #cookie-banner .container {
    flex-direction: column;
    align-items: stretch;
    justify-content: stretch;
  }

  #cookie-banner-buttons {
    justify-content: stretch;
    flex-direction: column;
  }

  #cookie-banner button {
    width: 100%;
  }

  .cookie-modal-content {
    width: 95%;
    padding: var(--space-4);
  }

  .cookie-modal-buttons {
    flex-direction: column;
    justify-content: stretch;
  }

  .cookie-modal-buttons button {
    width: 100%;
  }
}

#cookie-customize-modal { color: #ffffff !important; }
