/* Cheetah Privacy Cookie Banner */
.cheetah-banner {
  --cheetah-bg: #ffffff;
  --cheetah-text: #1a1a1a;
  --cheetah-primary: #2563eb;
  position: fixed;
  z-index: 999999;
  background: var(--cheetah-bg);
  color: var(--cheetah-text);
  box-shadow: 0 -4px 24px rgba(0,0,0,.12);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-size: 14px;
  line-height: 1.5;
  animation: cheetahSlideUp 0.4s ease forwards;
}

@media (prefers-color-scheme: dark) {
  .cheetah-banner:not([style*="--cheetah-bg"]) {
    --cheetah-bg: #1f2937;
    --cheetah-text: #f9fafb;
  }
}

@keyframes cheetahSlideUp {
  from { transform: translateY(100%); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

.cheetah-banner--bottom_bar {
  bottom: 0;
  left: 0;
  right: 0;
  padding: 16px 24px;
}

.cheetah-banner--top_bar {
  top: 0;
  bottom: auto;
  left: 0;
  right: 0;
  padding: 16px 24px;
  animation-name: cheetahSlideDown;
  box-shadow: 0 4px 24px rgba(0,0,0,.12);
}

@keyframes cheetahSlideDown {
  from { transform: translateY(-100%); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

.cheetah-banner--popup {
  bottom: 24px;
  right: 24px;
  left: auto;
  max-width: 420px;
  border-radius: 12px;
  padding: 20px;
  animation-name: cheetahFadeIn;
}

@keyframes cheetahFadeIn {
  from { opacity: 0; transform: scale(0.95); }
  to { opacity: 1; transform: scale(1); }
}

.cheetah-banner--hidden {
  display: none !important;
}

.cheetah-banner-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  max-width: 1200px;
  margin: 0 auto;
}

.cheetah-banner-content {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 1;
  min-width: 200px;
}

.cheetah-banner-logo {
  border-radius: 6px;
  object-fit: contain;
}

.cheetah-banner-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.cheetah-btn {
  cursor: pointer;
  border: none;
  border-radius: 6px;
  padding: 10px 18px;
  font-size: 14px;
  font-weight: 600;
  transition: opacity 0.2s, background 0.2s;
}

.cheetah-btn-primary {
  background: var(--cheetah-primary);
  color: #fff;
}

.cheetah-btn-primary:hover { opacity: 0.9; }

.cheetah-btn-outline {
  background: transparent;
  color: var(--cheetah-primary);
  border: 2px solid var(--cheetah-primary);
}

.cheetah-btn-text {
  background: transparent;
  color: var(--cheetah-text);
  text-decoration: underline;
  padding: 10px 12px;
}

.cheetah-banner-close,
.cheetah-modal-close {
  position: absolute;
  top: 12px;
  right: 12px;
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  color: var(--cheetah-text);
  line-height: 1;
  padding: 4px 8px;
}

.cheetah-attribution {
  text-align: center;
  font-size: 11px;
  opacity: 0.6;
  margin: 8px 0 0;
}

/* Modal */
.cheetah-modal {
  position: fixed;
  inset: 0;
  z-index: 1000000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.cheetah-modal[hidden] { display: none; }

.cheetah-modal-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,.5);
}

.cheetah-modal-card {
  position: relative;
  background: var(--cheetah-bg, #fff);
  color: var(--cheetah-text, #1a1a1a);
  border-radius: 12px;
  max-width: 640px;
  width: 100%;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  box-shadow: 0 20px 60px rgba(0,0,0,.2);
}

@media (prefers-color-scheme: dark) {
  .cheetah-modal-card { background: #1f2937; color: #f9fafb; }
}

.cheetah-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid rgba(0,0,0,.1);
  flex-shrink: 0;
}

.cheetah-modal-header h2 { margin: 0; font-size: 18px; }

.cheetah-modal-body {
  overflow-y: auto;
  padding: 16px 20px;
  flex: 1;
}

.cheetah-modal-footer {
  display: flex;
  gap: 8px;
  padding: 16px 20px;
  border-top: 1px solid rgba(0,0,0,.1);
  flex-shrink: 0;
}

.cheetah-accordion-item {
  border-bottom: 1px solid rgba(0,0,0,.08);
  padding: 12px 0;
}

.cheetah-accordion-trigger {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px 0;
  font-weight: 600;
  color: inherit;
  text-align: left;
}

.cheetah-cat-badge {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
}

.cheetah-chevron::after {
  content: '';
  display: inline-block;
  width: 8px;
  height: 8px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
  margin-left: auto;
  transition: transform 0.2s;
}

.cheetah-accordion-trigger[aria-expanded="true"] .cheetah-chevron::after {
  transform: rotate(-135deg);
}

.cheetah-accordion-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 4px;
}

.cheetah-cat-desc {
  margin: 0;
  font-size: 13px;
  opacity: 0.8;
  flex: 1;
}

.cheetah-toggle {
  position: relative;
  display: inline-block;
  width: 44px;
  height: 24px;
  flex-shrink: 0;
}

.cheetah-toggle input { opacity: 0; width: 0; height: 0; }

.cheetah-toggle-slider {
  position: absolute;
  inset: 0;
  background: #d1d5db;
  border-radius: 24px;
  cursor: pointer;
  transition: 0.2s;
}

.cheetah-toggle-slider::before {
  content: '';
  position: absolute;
  height: 18px;
  width: 18px;
  left: 3px;
  bottom: 3px;
  background: #fff;
  border-radius: 50%;
  transition: 0.2s;
}

.cheetah-toggle input:checked + .cheetah-toggle-slider {
  background: var(--cheetah-primary, #2563eb);
}

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

.cheetah-toggle--disabled { opacity: 0.5; pointer-events: none; }

.cheetah-accordion-panel { padding: 12px 0 0; }

.cheetah-cookie-table {
  width: 100%;
  font-size: 12px;
  border-collapse: collapse;
}

.cheetah-cookie-table th,
.cheetah-cookie-table td {
  padding: 6px 8px;
  text-align: left;
  border-bottom: 1px solid rgba(0,0,0,.06);
}

.cheetah-cookie-desc { font-size: 11px; opacity: 0.75; }

/* DSAR Form */
.cheetah-dsar-form-wrap { max-width: 560px; }
.cheetah-field { margin-bottom: 16px; }
.cheetah-field label { display: block; margin-bottom: 4px; font-weight: 600; }
.cheetah-field input,
.cheetah-field select,
.cheetah-field textarea {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid #d1d5db;
  border-radius: 6px;
  font-size: 14px;
}
.cheetah-children-warning { font-size: 13px; color: #6b7280; }
.cheetah-dsar-message { padding: 12px; border-radius: 6px; margin-bottom: 12px; }
.cheetah-dsar-message.success { background: #d1fae5; color: #065f46; }
.cheetah-dsar-message.error { background: #fee2e2; color: #991b1b; }

@media (max-width: 640px) {
  .cheetah-banner-inner { flex-direction: column; align-items: stretch; }
  .cheetah-banner-actions { flex-direction: column; }
  .cheetah-banner-actions .cheetah-btn { width: 100%; text-align: center; }
  .cheetah-banner--popup { left: 16px; right: 16px; max-width: none; }
}
