/* SELLAVI · COOKIES CONSENT — banner + modale paramétrage
   Style aligné avec la charte : fond cosmique, violet #431E96 / magenta #A202C7,
   typographie système, boutons cohérents avec le reste du site. */

/* ============ BANNER ============ */
.sc-banner {
  position: fixed;
  left: 50%;
  bottom: 24px;
  transform: translateX(-50%) translateY(120%);
  width: min(960px, calc(100vw - 32px));
  background: rgba(16, 6, 40, 0.92);
  border: 1px solid rgba(124, 58, 255, 0.32);
  border-radius: 18px;
  padding: 22px 26px;
  box-shadow:
    0 24px 60px rgba(0, 0, 0, 0.55),
    0 0 0 1px rgba(255, 255, 255, 0.02) inset;
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  color: #FFFFFF;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  z-index: 100000;
  transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.4s ease;
  opacity: 0;
  pointer-events: none;
}
.sc-banner.is-open {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
  pointer-events: auto;
}
.sc-banner-inner {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 20px;
  align-items: center;
}
.sc-banner-text {
  font-size: 14px;
  line-height: 1.55;
  color: rgba(255, 255, 255, 0.86);
}
.sc-banner-text strong {
  color: #FFFFFF;
  font-weight: 600;
}
.sc-banner-text a {
  color: #C99BFF;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.sc-banner-text a:hover { color: #FFFFFF; }
.sc-banner-actions {
  display: flex;
  gap: 10px;
  flex-wrap: nowrap;
  align-items: center;
}
.sc-btn {
  appearance: none;
  border: 0;
  cursor: pointer;
  font-family: inherit;
  font-size: 13px;
  font-weight: 600;
  padding: 11px 18px;
  border-radius: 11px;
  white-space: nowrap;
  transition: transform 0.15s ease, background 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
  letter-spacing: -0.005em;
}
.sc-btn:active { transform: translateY(1px); }
.sc-btn--primary {
  background: linear-gradient(135deg, #7C3AFF 0%, #A202C7 100%);
  color: #FFFFFF;
  box-shadow: 0 8px 24px rgba(124, 58, 255, 0.32);
}
.sc-btn--primary:hover {
  box-shadow: 0 10px 30px rgba(124, 58, 255, 0.45);
}
.sc-btn--ghost {
  background: transparent;
  color: rgba(255, 255, 255, 0.86);
  border: 1px solid rgba(255, 255, 255, 0.16);
}
.sc-btn--ghost:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.28);
  color: #FFFFFF;
}
.sc-btn--text {
  background: transparent;
  color: rgba(255, 255, 255, 0.72);
  padding: 11px 14px;
}
.sc-btn--text:hover { color: #FFFFFF; }

@media (max-width: 760px) {
  .sc-banner {
    bottom: 14px;
    width: calc(100vw - 24px);
    padding: 18px 18px;
    border-radius: 16px;
  }
  .sc-banner-inner {
    grid-template-columns: 1fr;
    gap: 14px;
  }
  .sc-banner-actions {
    flex-wrap: wrap;
    gap: 8px;
  }
  .sc-btn {
    flex: 1 1 auto;
    text-align: center;
    padding: 12px 14px;
  }
}

/* ============ MODALE PARAMÉTRAGE ============ */
.sc-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(7, 2, 15, 0.78);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  z-index: 100001;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.28s ease;
}
.sc-modal-overlay.is-open {
  opacity: 1;
  pointer-events: auto;
}
.sc-modal {
  width: 100%;
  max-width: 560px;
  background: linear-gradient(180deg, rgba(28, 14, 64, 0.96) 0%, rgba(16, 6, 40, 0.96) 100%);
  border: 1px solid rgba(124, 58, 255, 0.28);
  border-radius: 20px;
  padding: 28px;
  color: #FFFFFF;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  max-height: calc(100vh - 48px);
  overflow-y: auto;
  box-shadow: 0 32px 80px rgba(0, 0, 0, 0.6);
  transform: translateY(18px) scale(0.98);
  transition: transform 0.3s cubic-bezier(0.22, 1, 0.36, 1);
}
.sc-modal-overlay.is-open .sc-modal {
  transform: translateY(0) scale(1);
}
.sc-modal-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 18px;
}
.sc-modal-title {
  font-size: 20px;
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: -0.015em;
  margin: 0;
}
.sc-modal-close {
  appearance: none;
  background: transparent;
  border: 0;
  color: rgba(255, 255, 255, 0.6);
  width: 32px;
  height: 32px;
  border-radius: 8px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-left: 12px;
  transition: background 0.15s ease, color 0.15s ease;
}
.sc-modal-close:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #FFFFFF;
}
.sc-modal-lead {
  font-size: 13.5px;
  line-height: 1.55;
  color: rgba(255, 255, 255, 0.74);
  margin: 0 0 22px;
}
.sc-modal-lead a {
  color: #C99BFF;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.sc-cats {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 24px;
}
.sc-cat {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  padding: 16px 18px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  align-items: center;
}
.sc-cat-info {
  min-width: 0;
}
.sc-cat-name {
  font-size: 14.5px;
  font-weight: 600;
  margin: 0 0 4px;
  color: #FFFFFF;
}
.sc-cat-desc {
  font-size: 12.5px;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.62);
  margin: 0;
}
.sc-cat-locked {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: rgba(124, 58, 255, 0.92);
  background: rgba(124, 58, 255, 0.12);
  border: 1px solid rgba(124, 58, 255, 0.32);
  padding: 6px 10px;
  border-radius: 8px;
}
/* Toggle switch */
.sc-toggle {
  position: relative;
  display: inline-block;
  width: 44px;
  height: 24px;
  flex-shrink: 0;
}
.sc-toggle input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}
.sc-toggle-slider {
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.22s ease, border-color 0.22s ease;
}
.sc-toggle-slider::before {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: 18px;
  height: 18px;
  background: #FFFFFF;
  border-radius: 50%;
  transition: transform 0.22s cubic-bezier(0.22, 1, 0.36, 1);
}
.sc-toggle input:checked ~ .sc-toggle-slider {
  background: linear-gradient(135deg, #7C3AFF 0%, #A202C7 100%);
  border-color: transparent;
}
.sc-toggle input:checked ~ .sc-toggle-slider::before {
  transform: translateX(20px);
}
.sc-toggle input:focus-visible ~ .sc-toggle-slider {
  box-shadow: 0 0 0 3px rgba(124, 58, 255, 0.35);
}

.sc-modal-actions {
  display: flex;
  gap: 10px;
  justify-content: flex-end;
  flex-wrap: wrap;
}
.sc-modal-actions .sc-btn {
  flex: 0 1 auto;
}

@media (max-width: 540px) {
  .sc-modal {
    padding: 22px 20px;
    border-radius: 18px;
  }
  .sc-modal-title { font-size: 18px; }
  .sc-modal-actions { justify-content: stretch; }
  .sc-modal-actions .sc-btn { flex: 1 1 auto; }
}

/* Body lock quand un dialog cookies est ouvert */
body.sc-locked { overflow: hidden; }
