/* 背景样式 */
body.bg-image {
  background-image: var(--bg-image);
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  background-repeat: no-repeat;
}

body.bg-gradient {
  background-image: var(--bg-gradient) !important;
  background-attachment: fixed !important;
  background-repeat: no-repeat !important;
  background-size: 100% 100% !important;
}

body.bg-color {
  background-color: var(--bg-color);
}

/* 背景浅色覆盖层，当背景较暗时使内容可见 */
body.bg-overlay::before {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(255, 255, 255, 0.4);
  z-index: -1;
}

/* 背景管理页样式 */
.bg-card-preview {
  height: 150px;
  background-size: cover;
  background-position: center;
  border-top-left-radius: calc(0.25rem - 1px);
  border-top-right-radius: calc(0.25rem - 1px);
  background-color: #f8f9fa;
  position: relative;
}

.gradient-item,
.color-item {
  height: 40px;
  border-radius: 5px;
  cursor: pointer;
  transition: all 0.2s;
  border: 1px solid rgba(0, 0, 0, 0.1);
}

.gradient-item:hover,
.color-item:hover {
  transform: scale(1.05);
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}
