/**
 * Cookie Banner Configurator page styles
 * /[lang]/cookie-banner/
 */

/* ── Hero ── */
.cb-hero {
  padding: 80px 20px 40px;
  text-align: center;
  background: linear-gradient(135deg, #f0fdf4 0%, #ecfdf5 50%, #f0f9ff 100%);
}
.dark-theme .cb-hero {
  background: linear-gradient(135deg, #0f2818 0%, #0c1f14 50%, #0c1524 100%);
}
.cb-hero h1 {
  font-family: 'Montserrat', sans-serif;
  font-size: 2.2rem;
  font-weight: 800;
  color: #1e293b;
  margin-bottom: 12px;
  line-height: 1.2;
}
.dark-theme .cb-hero h1 { color: #f1f5f9; }
.cb-hero h1 .accent { color: #10b981; }
.cb-hero .cb-subtitle {
  font-size: 1.05rem;
  color: #64748b;
  max-width: 640px;
  margin: 0 auto 12px;
  line-height: 1.6;
}
.dark-theme .cb-hero .cb-subtitle { color: #94a3b8; }
/* ── URL Scanner redirect — uses UrlScanner component (url-scanner.css) ── */
.cb-scanner-redirect {
  max-width: 580px;
  margin: 0 auto 0;
}
.cb-manual-hint {
  font-size: 0.95rem;
  color: #64748b;
  margin-top: 16px;
}
.dark-theme .cb-manual-hint { color: #94a3b8; }

/* ── Main layout ── */
.cb-layout {
  max-width: 1100px;
  margin: 0 auto;
  padding: 40px 20px 60px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: start;
}

/* ── Config panel ── */
.cb-config {
  background: white;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  padding: 28px;
}
.dark-theme .cb-config {
  background: #1e293b;
  border-color: #334155;
}
.cb-config h2 {
  font-family: 'Montserrat', sans-serif;
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 24px;
  color: #1e293b;
}
.dark-theme .cb-config h2 { color: #f1f5f9; }

/* Subtitle under config title */
.cb-config-subtitle {
  font-size: 13px;
  color: #64748b;
  margin: -16px 0 20px;
  line-height: 1.5;
}
.dark-theme .cb-config-subtitle { color: #94a3b8; }
.cb-scan-link {
  color: #10b981;
  font-weight: 600;
  text-decoration: none;
}
.cb-scan-link:hover { text-decoration: underline; }

.cb-field {
  margin-bottom: 20px;
}
.cb-field label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: #475569;
  margin-bottom: 8px;
}
.dark-theme .cb-field label { color: #94a3b8; }

/* Radio group */
.cb-radio-group {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.cb-radio-group label {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border: 2px solid #e2e8f0;
  border-radius: 8px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 500;
  color: #475569;
  transition: all 0.2s;
  margin-bottom: 0;
}
.dark-theme .cb-radio-group label {
  border-color: #334155;
  color: #94a3b8;
}
.cb-radio-group label:has(input:checked) {
  border-color: #10b981;
  background: #f0fdf4;
  color: #065f46;
}
.dark-theme .cb-radio-group label:has(input:checked) {
  background: rgba(16, 185, 129, 0.15);
  border-color: #10b981;
  color: #6ee7b7;
}
.cb-radio-group input[type="radio"] {
  accent-color: #10b981;
}

/* Text / URL input */
.cb-field input[type="text"],
.cb-field input[type="url"] {
  width: 100%;
  padding: 10px 14px;
  border: 2px solid #e2e8f0;
  border-radius: 8px;
  font-size: 14px;
  background: white;
  color: #1e293b;
  transition: border-color 0.2s;
}
.dark-theme .cb-field input[type="text"],
.dark-theme .cb-field input[type="url"] {
  background: #0f172a;
  border-color: #334155;
  color: #f1f5f9;
}
.cb-field input[type="text"]:focus,
.cb-field input[type="url"]:focus {
  outline: none;
  border-color: #10b981;
}

/* Color picker row */
.cb-color-row {
  display: flex;
  align-items: center;
  gap: 10px;
}
.cb-color-row input[type="color"] {
  width: 44px;
  height: 36px;
  border: 2px solid #e2e8f0;
  border-radius: 8px;
  padding: 2px;
  cursor: pointer;
  background: white;
}
.dark-theme .cb-color-row input[type="color"] {
  border-color: #334155;
  background: #0f172a;
}
.cb-color-row .cb-color-hex {
  font-size: 13px;
  color: #64748b;
  font-family: monospace;
}

/* Service checkboxes */
.cb-services-section {
  margin-bottom: 20px;
}
.cb-services-section h3 {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #94a3b8;
  margin-bottom: 8px;
}
.dark-theme .cb-services-section h3 { color: #64748b; }
.cb-checkbox-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
}
.cb-checkbox-grid label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: #475569;
  cursor: pointer;
  padding: 4px 0;
  margin-bottom: 0;
}
.dark-theme .cb-checkbox-grid label { color: #94a3b8; }
.cb-checkbox-grid input[type="checkbox"] {
  accent-color: #10b981;
}

/* ── Preview panel ── */
.cb-preview-panel {
}
.cb-preview-panel h2 {
  font-family: 'Montserrat', sans-serif;
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 16px;
  color: #1e293b;
}
.dark-theme .cb-preview-panel h2 { color: #f1f5f9; }
.cb-preview-frame {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  min-height: 320px;
  position: relative;
  overflow: hidden;
}
.dark-theme .cb-preview-frame {
  background: #0f172a;
  border-color: #334155;
}
.cb-preview-mockup {
  padding: 20px;
  font-size: 14px;
  color: #94a3b8;
  text-align: center;
  padding-top: 40px;
}
.cb-preview-mockup .fake-line {
  height: 10px;
  background: #e2e8f0;
  border-radius: 4px;
  margin-bottom: 10px;
}
.dark-theme .cb-preview-mockup .fake-line { background: #334155; }
.cb-preview-mockup .fake-line.short { width: 60%; }
.cb-preview-mockup .fake-line.medium { width: 80%; }

/* Banner inside preview — reuse wl-cc styles with scoped position */
.cb-preview-frame .wl-cc-banner {
  position: absolute;
  z-index: 10;
}
.cb-preview-frame .wl-cc-banner.wl-cc-bottom {
  bottom: 0; left: 0; right: 0;
  transform: none;
  border-top: 1px solid #e2e8f0;
  padding: 14px 16px;
}
.cb-preview-frame .wl-cc-banner.wl-cc-popup {
  bottom: 12px; left: 12px;
  max-width: 280px; width: calc(100% - 24px);
  border-radius: 10px;
  padding: 14px;
  transform: none;
  opacity: 1;
  border: 1px solid #e2e8f0;
}
.cb-preview-frame .wl-cc-banner.wl-cc-modal {
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  max-width: 300px; width: 85%;
  border-radius: 12px;
  padding: 18px;
  opacity: 1;
}

/* Banner internal styling (scoped to preview) */
.cb-preview-frame .wl-cc-banner {
  background: white;
  box-shadow: 0 -2px 16px rgba(0,0,0,0.08);
  font-family: 'Open Sans', -apple-system, sans-serif;
  font-size: 11px;
  color: #1e293b;
}
.cb-preview-frame .wl-cc-banner.wl-cc-dark-preview {
  background: #1e293b;
  color: #f1f5f9;
  border-color: #334155;
}
.cb-preview-frame .wl-cc-title {
  font-size: 12px;
  font-weight: 700;
  margin-bottom: 4px;
  display: flex;
  align-items: center;
  gap: 6px;
}
.cb-preview-frame .wl-cc-desc {
  font-size: 10px;
  color: #64748b;
  line-height: 1.5;
  margin-bottom: 10px;
}
.cb-preview-frame .wl-cc-banner.wl-cc-dark-preview .wl-cc-desc { color: #94a3b8; }
.cb-preview-frame .wl-cc-buttons {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}
.cb-preview-frame .wl-cc-btn {
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 10px;
  font-weight: 600;
  border: none;
  cursor: default;
  flex: 1;
  min-width: 70px;
  text-align: center;
}
.cb-preview-frame .wl-cc-btn-accept {
  background: var(--wl-cc-accent, #10b981);
  color: white;
}
.cb-preview-frame .wl-cc-btn-reject {
  background: #f1f5f9;
  color: #475569;
  border: 1px solid #e2e8f0;
}
.cb-preview-frame .wl-cc-banner.wl-cc-dark-preview .wl-cc-btn-reject {
  background: #334155;
  color: #f1f5f9;
  border-color: #475569;
}
.cb-preview-frame .wl-cc-btn-settings {
  background: transparent;
  color: var(--wl-cc-accent, #10b981);
  border: 1px solid var(--wl-cc-accent, #10b981);
}
.cb-preview-frame .wl-cc-branding {
  text-align: center;
  font-size: 8px;
  color: #94a3b8;
  padding-top: 6px;
  margin-top: 8px;
  border-top: 1px solid #f1f5f9;
}
.cb-preview-frame .wl-cc-banner.wl-cc-dark-preview .wl-cc-branding {
  border-color: #334155;
  color: #64748b;
}
.cb-preview-frame .wl-cc-branding a {
  color: #10b981;
  text-decoration: none;
  font-weight: 600;
}

/* ── Icon controls (Position + Theme) under preview ── */
.cb-icon-section { margin-top: 16px; }
.cb-icon-title {
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #94a3b8;
  text-align: center;
  margin-bottom: 8px;
}
.dark-theme .cb-icon-title { color: #64748b; }
.cb-icon-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 16px;
  padding: 10px 0;
}
.cb-icon-sep {
  width: 1px;
  height: 28px;
  background: #e2e8f0;
  margin: 0 4px;
}
.dark-theme .cb-icon-sep { background: #334155; }
.cb-icon-group {
  display: flex;
  gap: 4px;
}
.cb-icon-radio {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 36px;
  border: 2px solid #e2e8f0;
  border-radius: 8px;
  cursor: pointer;
  color: #94a3b8;
  transition: all 0.15s;
  margin-bottom: 0;
}
.dark-theme .cb-icon-radio {
  border-color: #334155;
  color: #64748b;
}
.cb-icon-radio:hover {
  border-color: #cbd5e1;
  color: #64748b;
}
.dark-theme .cb-icon-radio:hover {
  border-color: #475569;
  color: #94a3b8;
}
.cb-icon-radio:has(input:checked) {
  border-color: #10b981;
  background: #f0fdf4;
  color: #10b981;
}
.dark-theme .cb-icon-radio:has(input:checked) {
  background: rgba(16, 185, 129, 0.15);
  border-color: #10b981;
  color: #10b981;
}
.cb-icon-radio input[type="radio"] {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

/* ── Snippet section ── */
/* Snippet inline in preview panel */
.cb-snippet-inline {
  margin-top: 24px;
}
.cb-snippet-inline h3 {
  font-family: 'Montserrat', sans-serif;
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--foreground, #1e293b);
}
.dark-theme .cb-snippet-inline h3 { color: #f1f5f9; }

/* Legacy section snippet (kept for backward compat) */
.cb-snippet {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 20px 40px;
}
.cb-snippet h2 {
  font-family: 'Montserrat', sans-serif;
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 16px;
  color: #1e293b;
}
.dark-theme .cb-snippet h2 { color: #f1f5f9; }
.cb-snippet-box {
  background: #1e293b;
  border-radius: 12px;
  padding: 20px;
  position: relative;
  overflow-x: auto;
}
.cb-snippet-box code {
  font-family: 'SF Mono', 'Fira Code', monospace;
  font-size: 13px;
  color: #e2e8f0;
  line-height: 1.6;
  white-space: pre-wrap;
  word-break: break-all;
}
.cb-snippet-box .cb-copy-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 12px;
  background: #334155;
  color: #e2e8f0;
  border: none;
  border-radius: 6px;
  padding: 8px 16px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s;
}
.cb-snippet-box .cb-copy-btn:hover { background: #475569; }
.cb-snippet-box .cb-copy-btn.copied { background: #10b981; color: white; }
.cb-snippet-box .cb-copy-btn svg { flex-shrink: 0; }

/* Privacy CTA link under the URL field */
.cb-privacy-cta {
  display: inline-block;
  margin-top: 6px;
  font-size: 13px;
  color: var(--primary, #10b981);
  font-weight: 600;
}

/* Snippet instructions */
.cb-snippet-instructions {
  font-size: 13px;
  color: var(--muted-foreground, #64748b);
  margin-bottom: 12px;
  line-height: 1.6;
}
.cb-snippet-instructions code {
  background: var(--secondary, #f1f5f9);
  padding: 1px 5px;
  border-radius: 3px;
  font-size: 12px;
}
.dark-theme .cb-snippet-instructions { color: #94a3b8; }
.dark-theme .cb-snippet-instructions code { background: #334155; }

/* ── CTA cross-sell ── */
.cb-cta {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 20px 60px;
}
.cb-cta-box {
  background: linear-gradient(135deg, #f0fdf4, #ecfdf5);
  border: 2px solid #bbf7d0;
  border-radius: 16px;
  padding: 32px;
  text-align: center;
}
.dark-theme .cb-cta-box {
  background: linear-gradient(135deg, rgba(16,185,129,0.1), rgba(16,185,129,0.05));
  border-color: rgba(16,185,129,0.3);
}
.cb-cta-box h3 {
  font-family: 'Montserrat', sans-serif;
  font-size: 1.1rem;
  font-weight: 700;
  color: #065f46;
  margin-bottom: 8px;
}
.dark-theme .cb-cta-box h3 { color: #6ee7b7; }
.cb-cta-box p {
  font-size: 14px;
  color: #475569;
  margin-bottom: 16px;
}
.dark-theme .cb-cta-box p { color: #94a3b8; }
.cb-cta-box a {
  display: inline-block;
  padding: 12px 28px;
  background: #10b981;
  color: white;
  border-radius: 10px;
  font-weight: 600;
  font-size: 14px;
  text-decoration: none;
  transition: background 0.2s;
}
.cb-cta-box a:hover { background: #059669; }

/* ── Responsive ── */
@media (max-width: 768px) {
  .cb-hero h1 { font-size: 1.6rem; }
  .cb-layout {
    grid-template-columns: 1fr;
    gap: 24px;
  }
  .cb-preview-panel { position: static; }
  .cb-checkbox-grid { grid-template-columns: 1fr; }
  .cb-radio-group { flex-direction: column; }
}
