/* 背景选择器样式 */

/* 背景选择器容器 */
.bg-grid-container {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
    max-height: 280px;
    overflow-y: auto;
    padding: 12px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 12px;
    margin-top: 10px;
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.3) rgba(0, 0, 0, 0.2);
}

/* 自定义滚动条样式 */
.bg-grid-container::-webkit-scrollbar {
    width: 6px;
}

.bg-grid-container::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 3px;
}

.bg-grid-container::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.3);
    border-radius: 3px;
}

.bg-grid-container::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.5);
}

/* 背景项目 */
.bg-item {
    position: relative;
    aspect-ratio: 2/1;
    width: 100%;
    border-radius: 6px;
    overflow: hidden;
    cursor: pointer;
    border: 1px solid transparent;
    transition: all 0.3s ease;
}

.bg-item:hover {
    transform: scale(1.02);
    border-color: rgba(255, 255, 255, 0.5);
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.3);
}

.bg-item.active {
    border-color: #00b09b;
    box-shadow: 0 0 15px rgba(0,176,155,0.5);
}

.bg-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.bg-item:hover img {
    transform: scale(1.1);
}

/* 背景名称标签 */
.bg-item .bg-name {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 8px;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.8), rgba(0, 0, 0, 0));
    color: white;
    font-size: 13px;
    text-align: center;
    opacity: 0;
    transition: opacity 0.3s ease, transform 0.3s ease;
    transform: translateY(5px);
}

.bg-item:hover .bg-name {
    opacity: 1;
    transform: translateY(0);
}
