/* CLEAN */
.modalOverlay {
  position: fixed;
  inset: 0;
  background-color: rgb(0 0 0 / 70%);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9999;
  overflow: auto;
}

.modal {
  background: var(--spice-card);
  border-radius: 8px;
  width: 90%;
  max-width: 700px;
  max-height: 90vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  margin: auto;
  position: relative;
  animation: modalSlideIn 0.2s ease-out;
}

.modalHeader {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 24px;
  border-bottom: 1px solid var(--spice-button-disabled);
}

.modalTitle {
  margin: 0;
  font-size: 20px;
  font-weight: 700;
  color: var(--spice-text);
}

.modalBodyExtensions {
  overflow-y: auto;
  max-height: calc(90vh - 70px);
  display: flex;
  flex-direction: column;
  gap: 20px;
}

@media (width <= 768px) {
  .modal {
    width: 95%;
    max-height: 95vh;
  }
}

@keyframes modalSlideIn {
  from {
    opacity: 0;
    transform: translateY(-20px) scale(0.95);
  }

  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.toggleGroup {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 16px;
}

.toggleItem {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px;
  background: rgb(0 0 0 / 10%);
  border-radius: 8px;
  border: 1px solid rgb(255 255 255 / 5%);
  transition: background-color 0.2s ease;
}

.toggleItem:hover {
  background: rgb(255 255 255 / 5%);
}

.toggleInfo {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.toggleLabel {
  font-weight: 500;
  color: var(--spice-text);
  font-size: 14px;
  margin: 0;
}

.toggleDescription {
  font-size: 12px;
  color: var(--spice-subtext);
  opacity: 0.8;
}

.slider {
  position: absolute;
  inset: 0;
  background-color: var(--spice-button-disabled);
  border-radius: 24px;
  transition: background-color 0.3s;
}

.slider::before {
  position: absolute;
  content: "";
  height: 18px;
  width: 18px;
  left: 3px;
  bottom: 3px;
  background-color: #fff;
  border-radius: 50%;
  transition: transform 0.3s;
}

.toggleSwitch {
  position: relative;
  display: inline-block;
  width: 44px;
  height: 24px;
  cursor: pointer;
  flex-shrink: 0;
}

.toggleSwitch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.toggleSwitch input:checked + .slider {
  background-color: #1e90ff;
}

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