/* 收藏按钮激活状态 */
.favoriteBtn.active {
    background-color: #0d6efd;
    color: white;
}
/* 上传按钮样式 */
.custom-upload-btn {
    position: relative;
    overflow: hidden;
    display: inline-block;
}
.custom-upload-btn input[type="file"] {
    position: absolute;
    font-size: 100px;
    right: 0;
    top: 0;
    opacity: 0;
    cursor: pointer;
}
/* 切割预览区域 */
#splitPreviewWrapper {
    position: relative;
    display: inline-block;
    max-width: 100%;
    line-height: 0;
    background: #f8f9fa;
    border: 1px dashed #dee2e6;
    border-radius: 8px;
    padding: 8px;
}
#splitPreviewWrapper img {
    max-width: 100%;
    max-height: 500px;
    height: auto;
    display: block;
    user-select: none;
    -webkit-user-drag: none;
}
/* 网格覆盖层 */
#gridOverlay {
    position: absolute;
    top: 8px;
    left: 8px;
    right: 8px;
    bottom: 8px;
    pointer-events: none;
}
.grid-line {
    position: absolute;
    background-color: rgba(13, 110, 253, 0.6);
}
.grid-line.vertical {
    top: 0;
    bottom: 0;
    width: 1px;
}
.grid-line.horizontal {
    left: 0;
    right: 0;
    height: 1px;
}
/* 切片预览网格 */
#slicesGrid {
    display: grid;
    gap: 8px;
    max-height: 600px;
    overflow-y: auto;
    padding: 8px;
    background: #f8f9fa;
    border-radius: 8px;
    border: 1px dashed #dee2e6;
}
.slice-item {
    position: relative;
    background: #fff;
    border: 1px solid #dee2e6;
    border-radius: 6px;
    padding: 6px;
    text-align: center;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    transition: transform 0.2s;
}
.slice-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}
.slice-item img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 4px;
}
.slice-item .slice-label {
    margin-top: 4px;
    font-size: 11px;
    color: #6c757d;
}
.slice-item .slice-download {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: rgba(13, 110, 253, 0.85);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    text-decoration: none;
    opacity: 0;
    transition: opacity 0.2s;
}
.slice-item:hover .slice-download {
    opacity: 1;
}
.slice-item .slice-download:hover {
    background: #0d6efd;
    color: #fff;
}
/* 空状态提示 */
.empty-state {
    text-align: center;
    padding: 40px 20px;
    color: #6c757d;
}
.empty-state i {
    font-size: 48px;
    display: block;
    margin-bottom: 12px;
    color: #dee2e6;
}
