/* ─── Advanced Cookie Banner Styles ────────────────────────── */
.cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--white);
  border-top: 1px solid var(--neutral-200);
  box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.15);
  z-index: 9999;
  transform: translateY(100%);
  transition: transform 0.3s ease;
  backdrop-filter: blur(12px);
}

.cookie-banner.show {
  transform: translateY(0);
}

.cookie-banner-content {
  max-width: 1280px;
  margin: 0 auto;
  padding: var(--space-6);
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--space-6);
  flex-wrap: wrap;
}

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

.cookie-banner-text h3 {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 700;
  color: var(--neutral-900);
  margin-bottom: var(--space-2);
  letter-spacing: -0.01em;
}

.cookie-banner-text p {
  font-size: 14px;
  color: var(--neutral-600);
  line-height: 1.5;
  margin: 0 0 var(--space-3);
}

.cookie-policy-link {
  color: var(--primary-600);
  text-decoration: underline;
  text-underline-offset: 2px;
  transition: color 0.2s ease;
}

.cookie-policy-link:hover {
  color: var(--primary-700);
}

.cookie-banner-actions {
  display: flex;
  gap: var(--space-3);
  flex-shrink: 0;
  flex-wrap: wrap;
  align-items: center;
}

.cookie-btn {
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 600;
  padding: var(--space-3) var(--space-5);
  border-radius: var(--radius-lg);
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.cookie-btn-primary {
  background: linear-gradient(135deg, var(--primary-600) 0%, var(--primary-500) 100%);
  color: var(--white);
  box-shadow: var(--shadow-sm);
}

.cookie-btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.cookie-btn-secondary {
  background: var(--neutral-100);
  color: var(--neutral-700);
  border: 1px solid var(--neutral-300);
}

.cookie-btn-secondary:hover {
  background: var(--neutral-200);
  border-color: var(--neutral-400);
}

.cookie-btn-text {
  background: transparent;
  color: var(--primary-600);
  text-decoration: underline;
  text-underline-offset: 2px;
  padding: var(--space-3) var(--space-4);
}

.cookie-btn-text:hover {
  color: var(--primary-700);
  text-decoration-color: var(--primary-700);
}

/* ─── Cookie Settings Modal ─────────────────────────────────── */
.cookie-modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 10000;
}

.cookie-modal-overlay {
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-4);
  backdrop-filter: blur(4px);
}

.cookie-modal-content {
  background: var(--white);
  border-radius: var(--radius-2xl);
  max-width: 600px;
  width: 100%;
  max-height: 90vh;
  overflow: hidden;
  box-shadow: var(--shadow-xl);
  display: flex;
  flex-direction: column;
}

.cookie-modal-header {
  padding: var(--space-6);
  border-bottom: 1px solid var(--neutral-200);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
}

.cookie-modal-header h2 {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 700;
  color: var(--neutral-900);
  margin: 0;
  letter-spacing: -0.01em;
}

.cookie-modal-close {
  background: none;
  border: none;
  font-size: 28px;
  color: var(--neutral-500);
  cursor: pointer;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-sm);
  transition: all 0.2s ease;
}

.cookie-modal-close:hover {
  background: var(--neutral-100);
  color: var(--neutral-700);
}

.cookie-modal-body {
  padding: var(--space-6);
  overflow-y: auto;
  flex: 1;
}

.cookie-modal-body > p {
  font-size: 15px;
  color: var(--neutral-600);
  line-height: 1.6;
  margin-bottom: var(--space-6);
}

.cookie-categories {
  display: flex;
  flex-direction: column;
  gap: var(--space-5);
}

.cookie-category {
  border: 1px solid var(--neutral-200);
  border-radius: var(--radius-xl);
  padding: var(--space-5);
  transition: border-color 0.2s ease;
}

.cookie-category:hover {
  border-color: var(--primary-300);
}

.cookie-category-header {
  margin-bottom: var(--space-3);
}

.cookie-toggle {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  cursor: pointer;
  font-size: 16px;
  font-weight: 600;
  color: var(--neutral-900);
}

.cookie-toggle input[type="checkbox"] {
  position: relative;
  width: 44px;
  height: 24px;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  background: var(--neutral-300);
  border-radius: 12px;
  transition: all 0.2s ease;
  cursor: pointer;
}

.cookie-toggle input[type="checkbox"]:checked {
  background: var(--primary-600);
}

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

.cookie-toggle input[type="checkbox"]::before {
  content: '';
  position: absolute;
  top: 2px;
  left: 2px;
  width: 20px;
  height: 20px;
  background: var(--white);
  border-radius: 50%;
  transition: transform 0.2s ease;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

.cookie-toggle input[type="checkbox"]:checked::before {
  transform: translateX(20px);
}

.cookie-required {
  font-size: 12px;
  color: var(--neutral-500);
  font-weight: 500;
  margin-left: var(--space-2);
}

.cookie-category-description {
  font-size: 14px;
  color: var(--neutral-600);
  line-height: 1.5;
  margin-bottom: var(--space-3);
}

.cookie-details {
  margin-top: var(--space-3);
}

.cookie-details summary {
  font-size: 13px;
  color: var(--primary-600);
  cursor: pointer;
  padding: var(--space-2) 0;
  border-bottom: 1px solid var(--neutral-200);
}

.cookie-details summary:hover {
  color: var(--primary-700);
}

.cookie-list {
  list-style: none;
  padding: var(--space-3) 0 0;
  margin: 0;
}

.cookie-list li {
  padding: var(--space-1) 0;
  font-size: 12px;
  color: var(--neutral-600);
}

.cookie-list code {
  background: var(--neutral-100);
  padding: 2px var(--space-2);
  border-radius: var(--radius-xs);
  font-family: var(--font-mono);
  font-size: 11px;
}

.cookie-modal-footer {
  padding: var(--space-6);
  border-top: 1px solid var(--neutral-200);
  display: flex;
  gap: var(--space-3);
  flex-wrap: wrap;
  justify-content: flex-end;
  flex-shrink: 0;
}

/* ─── Responsive Design ─────────────────────────────────────── */
@media (max-width: 768px) {
  .cookie-banner-content {
    flex-direction: column;
    align-items: flex-start;
    text-align: left;
  }
  
  .cookie-banner-actions {
    width: 100%;
    justify-content: flex-start;
  }
  
  .cookie-btn {
    flex: 1;
    min-width: 0;
    text-align: center;
  }
  
  .cookie-modal-overlay {
    padding: var(--space-2);
  }
  
  .cookie-modal-header,
  .cookie-modal-body,
  .cookie-modal-footer {
    padding: var(--space-4);
  }
  
  .cookie-modal-footer {
    flex-direction: column;
  }
  
  .cookie-modal-footer .cookie-btn {
    width: 100%;
  }
}

@media (max-width: 480px) {
  .cookie-banner-actions {
    flex-direction: column;
  }
  
  .cookie-btn {
    width: 100%;
  }
  
  .cookie-toggle {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--space-2);
  }
}