/* ===== BANNER RGPD ===== */

.gdpr-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(15, 23, 42, 0.98);
  border-top: 2px solid rgba(248, 113, 113, 0.6);
  padding: 1.5rem 2rem;
  box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.5);
  z-index: 10000;
  transform: translateY(100%);
  transition: transform 0.3s ease-out;
  backdrop-filter: blur(10px);
}

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

.gdpr-banner-overlay {
  display: none;
}

@media (max-width: 768px) {
  .gdpr-banner-overlay {
    display: block;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.75);
    z-index: 9998;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
  }

  .gdpr-banner-overlay.gdpr-banner-overlay-show {
    opacity: 1;
    pointer-events: auto;
  }
}

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

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

.gdpr-banner-title {
  font-size: 1.2rem;
  font-weight: 700;
  color: rgba(248, 250, 252, 0.95);
  margin: 0 0 0.5rem 0;
}

.gdpr-banner-description {
  font-size: 0.95rem;
  color: rgba(226, 232, 240, 0.85);
  margin: 0;
  line-height: 1.5;
}

.gdpr-banner-actions {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  align-items: center;
}

.gdpr-banner-actions .btn {
  padding: 0.65rem 1.5rem;
  font-size: 0.95rem;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  border: none;
  white-space: nowrap;
}

.gdpr-banner-actions .btn-primary {
  background: linear-gradient(120deg, #00d2ff 0%, #3a7bd5 100%);
  color: #fff;
  box-shadow: 0 4px 15px rgba(6, 148, 206, 0.4);
}

.gdpr-banner-actions .btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(6, 148, 206, 0.5);
}

.gdpr-banner-actions .btn-secondary {
  background: rgba(71, 85, 105, 0.8);
  color: rgba(248, 250, 252, 0.95);
  border: 1px solid rgba(148, 163, 184, 0.4);
}

.gdpr-banner-actions .btn-secondary:hover {
  background: rgba(71, 85, 105, 1);
  border-color: rgba(148, 163, 184, 0.6);
}

.gdpr-banner-actions .btn-outline {
  background: transparent;
  color: rgba(248, 250, 252, 0.95);
  border: 1px solid rgba(148, 163, 184, 0.5);
}

.gdpr-banner-actions .btn-outline:hover {
  background: rgba(148, 163, 184, 0.1);
  border-color: rgba(148, 163, 184, 0.7);
}

/* ===== MODAL RGPD ===== */

.gdpr-modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 10001;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.gdpr-modal.gdpr-modal-show {
  opacity: 1;
}

.gdpr-modal-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(5px);
}

.gdpr-modal-content {
  position: relative;
  max-width: 700px;
  max-height: 90vh;
  margin: 2rem auto;
  background: rgba(15, 23, 42, 0.98);
  border: 1px solid rgba(148, 163, 184, 0.3);
  border-radius: 16px;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.6);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.gdpr-modal-header {
  padding: 1.5rem 2rem;
  border-bottom: 1px solid rgba(148, 163, 184, 0.2);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.gdpr-modal-header h2 {
  font-size: 1.5rem;
  font-weight: 700;
  color: rgba(248, 250, 252, 0.95);
  margin: 0;
}

.gdpr-modal-close {
  background: none;
  border: none;
  font-size: 2rem;
  color: rgba(226, 232, 240, 0.7);
  cursor: pointer;
  line-height: 1;
  padding: 0;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  transition: all 0.3s ease;
}

.gdpr-modal-close:hover {
  background: rgba(148, 163, 184, 0.2);
  color: rgba(248, 250, 252, 0.95);
}

.gdpr-modal-body {
  padding: 2rem;
  overflow-y: auto;
  flex: 1;
}

.gdpr-modal-intro {
  font-size: 1rem;
  color: rgba(226, 232, 240, 0.85);
  margin-bottom: 1.5rem;
  line-height: 1.6;
}

.gdpr-preference-item {
  margin-bottom: 1.5rem;
  padding: 1.25rem;
  background: rgba(30, 41, 59, 0.6);
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 12px;
}

.gdpr-preference-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1.5rem;
}

.gdpr-preference-info {
  flex: 1;
}

.gdpr-preference-info h3 {
  font-size: 1.1rem;
  font-weight: 600;
  color: rgba(248, 250, 252, 0.95);
  margin: 0 0 0.5rem 0;
}

.gdpr-preference-info p {
  font-size: 0.9rem;
  color: rgba(203, 213, 225, 0.85);
  margin: 0 0 0.75rem 0;
  line-height: 1.5;
}

.gdpr-preference-toggle {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
}

.gdpr-required {
  font-size: 0.75rem;
  color: rgba(148, 163, 184, 0.8);
  text-transform: uppercase;
  font-weight: 600;
  letter-spacing: 0.05em;
}

/* Toggle Switch */
.gdpr-switch {
  position: relative;
  display: inline-block;
  width: 56px;
  height: 28px;
}

.gdpr-switch.disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.gdpr-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.gdpr-slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(71, 85, 105, 0.8);
  border: 1px solid rgba(148, 163, 184, 0.4);
  transition: 0.3s;
  border-radius: 28px;
}

.gdpr-slider::before {
  position: absolute;
  content: '';
  height: 22px;
  width: 22px;
  left: 3px;
  bottom: 2px;
  background-color: white;
  transition: 0.3s;
  border-radius: 50%;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.gdpr-switch input:checked + .gdpr-slider {
  background: linear-gradient(120deg, #00d2ff 0%, #3a7bd5 100%);
  border-color: transparent;
}

.gdpr-switch input:checked + .gdpr-slider::before {
  transform: translateX(26px);
}

.gdpr-switch.disabled input + .gdpr-slider {
  cursor: not-allowed;
  background: rgba(148, 163, 184, 0.3);
}

.gdpr-switch input:focus + .gdpr-slider {
  box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.3);
}

/* Details */
.gdpr-details {
  margin-top: 0.75rem;
}

.gdpr-details summary {
  font-size: 0.85rem;
  color: #38bdf8;
  cursor: pointer;
  user-select: none;
  font-weight: 600;
}

.gdpr-details summary:hover {
  text-decoration: underline;
}

.gdpr-details ul {
  margin: 0.75rem 0 0 1.5rem;
  padding: 0;
  list-style: disc;
}

.gdpr-details li {
  font-size: 0.85rem;
  color: rgba(203, 213, 225, 0.8);
  margin-bottom: 0.5rem;
  line-height: 1.5;
}

.gdpr-details li strong {
  color: rgba(248, 250, 252, 0.9);
  font-weight: 600;
}

/* Modal Footer */
.gdpr-modal-footer {
  padding: 1.5rem 2rem;
  border-top: 1px solid rgba(148, 163, 184, 0.2);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.gdpr-privacy-link {
  font-size: 0.9rem;
  color: #38bdf8;
  text-decoration: none;
  font-weight: 600;
}

.gdpr-privacy-link:hover {
  text-decoration: underline;
}

.gdpr-modal-actions {
  display: flex;
  gap: 0.75rem;
}

.gdpr-modal-actions .btn {
  padding: 0.65rem 1.5rem;
  font-size: 0.95rem;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  border: none;
}

.gdpr-modal-actions .btn-primary {
  background: linear-gradient(120deg, #00d2ff 0%, #3a7bd5 100%);
  color: #fff;
  box-shadow: 0 4px 15px rgba(6, 148, 206, 0.4);
}

.gdpr-modal-actions .btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(6, 148, 206, 0.5);
}

.gdpr-modal-actions .btn-secondary {
  background: rgba(71, 85, 105, 0.8);
  color: rgba(248, 250, 252, 0.95);
  border: 1px solid rgba(148, 163, 184, 0.4);
}

.gdpr-modal-actions .btn-secondary:hover {
  background: rgba(71, 85, 105, 1);
  border-color: rgba(148, 163, 184, 0.6);
}

/* ===== THEME LIGHT ===== */

body.theme-light .gdpr-banner {
  background: rgba(255, 255, 255, 0.98);
  border-top-color: rgba(99, 102, 241, 0.6);
}

body.theme-light .gdpr-banner-title {
  color: #0f172a;
}

body.theme-light .gdpr-banner-description {
  color: #475569;
}

body.theme-light .gdpr-banner-actions .btn-secondary {
  background: rgba(226, 232, 240, 0.9);
  color: #0f172a;
  border-color: rgba(203, 213, 225, 0.8);
}

body.theme-light .gdpr-banner-actions .btn-secondary:hover {
  background: rgba(203, 213, 225, 1);
}

body.theme-light .gdpr-banner-actions .btn-outline {
  color: #0f172a;
  border-color: rgba(148, 163, 184, 0.6);
}

body.theme-light .gdpr-banner-actions .btn-outline:hover {
  background: rgba(148, 163, 184, 0.15);
}

body.theme-light .gdpr-modal-content {
  background: rgba(255, 255, 255, 0.98);
  border-color: rgba(203, 213, 225, 0.5);
}

body.theme-light .gdpr-modal-header h2 {
  color: #0f172a;
}

body.theme-light .gdpr-modal-close {
  color: #475569;
}

body.theme-light .gdpr-modal-close:hover {
  background: rgba(226, 232, 240, 0.8);
  color: #0f172a;
}

body.theme-light .gdpr-modal-intro {
  color: #475569;
}

body.theme-light .gdpr-preference-item {
  background: rgba(241, 245, 249, 0.8);
  border-color: rgba(203, 213, 225, 0.5);
}

body.theme-light .gdpr-preference-info h3 {
  color: #0f172a;
}

body.theme-light .gdpr-preference-info p {
  color: #475569;
}

body.theme-light .gdpr-details li {
  color: #64748b;
}

body.theme-light .gdpr-details li strong {
  color: #0f172a;
}

body.theme-light .gdpr-slider {
  background: rgba(203, 213, 225, 0.8);
  border-color: rgba(148, 163, 184, 0.6);
}

body.theme-light .gdpr-switch.disabled input + .gdpr-slider {
  background: rgba(203, 213, 225, 0.5);
}

/* ===== RESPONSIVE ===== */

@media (max-width: 768px) {
  .gdpr-banner {
    padding: 1.25rem 1.5rem;
  }

  .gdpr-banner-content {
    flex-direction: column;
    gap: 1.5rem;
  }

  .gdpr-banner-text {
    min-width: 100%;
  }

  .gdpr-banner-actions {
    width: 100%;
    flex-direction: column;
  }

  .gdpr-banner-actions .btn {
    width: 100%;
    text-align: center;
  }

  .gdpr-modal-content {
    margin: 1rem;
    max-height: calc(100vh - 2rem);
  }

  .gdpr-modal-header,
  .gdpr-modal-body,
  .gdpr-modal-footer {
    padding: 1.25rem 1.5rem;
  }

  .gdpr-preference-header {
    flex-direction: column;
    gap: 1rem;
  }

  .gdpr-preference-toggle {
    align-self: flex-start;
  }

  .gdpr-modal-footer {
    flex-direction: column;
    align-items: stretch;
  }

  .gdpr-modal-actions {
    width: 100%;
    flex-direction: column;
  }

  .gdpr-modal-actions .btn {
    width: 100%;
  }
}

@media (max-width: 480px) {
  .gdpr-banner-title {
    font-size: 1.1rem;
  }

  .gdpr-banner-description {
    font-size: 0.9rem;
  }

  .gdpr-modal-header h2 {
    font-size: 1.25rem;
  }
}
