/* 通知偏好弹窗：高对比 + 自定义开关 + 浮层不被裁切 */

.proto-notification-pref-modal {
  color: #f2f2f5;
}

.proto-notification-pref-dialog.ant-modal .ant-modal-content,
.ant-modal-root:has(.proto-notification-pref-modal) .ant-modal-content {
  background: #201f24 !important;
  color: #f2f2f5 !important;
  overflow: visible !important;
}

.proto-notification-pref-dialog.ant-modal .ant-modal-header,
.ant-modal-root:has(.proto-notification-pref-modal) .ant-modal-header {
  background: #201f24 !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12) !important;
}

.proto-notification-pref-dialog.ant-modal .ant-modal-title,
.ant-modal-root:has(.proto-notification-pref-modal) .ant-modal-title {
  color: #ffffff !important;
  font-weight: 600;
}

.proto-notification-pref-dialog.ant-modal .ant-modal-close,
.ant-modal-root:has(.proto-notification-pref-modal) .ant-modal-close {
  color: rgba(255, 255, 255, 0.75) !important;
}

.proto-notification-pref-dialog.ant-modal .ant-modal-body,
.ant-modal-root:has(.proto-notification-pref-modal) .ant-modal-body {
  overflow-x: visible !important;
  overflow-y: auto !important;
  max-height: min(72vh, 640px);
}

.proto-notification-pref-matrix {
  overflow: visible !important;
}

.proto-notification-pref-modal .proto-nppi-hint {
  margin: 0 0 14px;
  padding: 10px 12px;
  border-radius: 8px;
  background: rgba(255, 193, 7, 0.14);
  border: 1px solid rgba(255, 193, 7, 0.4);
  color: #ffe58f !important;
  font-size: 12px;
  line-height: 1.55;
}

/* 自定义开关（替代未导出的 antd Switch） */
.proto-nppi-switch {
  position: relative;
  display: inline-block;
  width: 36px;
  height: 20px;
  padding: 0;
  border: none;
  border-radius: 999px;
  background: #4a4952;
  cursor: pointer;
  vertical-align: middle;
  transition: background 0.2s ease;
}

.proto-nppi-switch::after {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.35);
  transition: transform 0.2s ease;
}

.proto-nppi-switch.is-on {
  background: #ffc107;
}

.proto-nppi-switch.is-on::after {
  transform: translateX(16px);
}

.proto-nppi-switch.is-disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.proto-nppi-switch.is-disabled.is-on {
  background: #8a7a3a;
}

.ant-tooltip {
  z-index: 12050 !important;
}
