/* 自定义样式 */

/* 消息提示样式 */
.message {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1050;
    min-width: 300px;
    animation: slideInRight 0.3s ease-out;
}

.message.fade-out {
    animation: slideOutRight 0.3s ease-out forwards;
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideOutRight {
    from {
        transform: translateX(0);
        opacity: 1;
    }
    to {
        transform: translateX(100%);
        opacity: 0;
    }
}

/* 表格样式 */
.table-hover tbody tr:hover {
    background-color: rgba(0, 123, 255, 0.05);
}

/* 卡片样式 */
.card {
    border-radius: 10px;
    border: none;
    transition: transform 0.2s;
}

.card:hover {
    transform: translateY(-2px);
}

/* 按钮样式 */
.btn {
    border-radius: 5px;
    padding: 8px 16px;
    font-weight: 500;
}

.btn-group-sm .btn {
    padding: 4px 8px;
}

/* 导航栏样式 */
.navbar {
    box-shadow: 0 2px 4px rgba(0,0,0,.1);
}

.navbar-brand {
    font-weight: 600;
    font-size: 1.2rem;
}

/* 表单样式 */
.form-control:focus {
    border-color: #80bdff;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

/* 徽章样式 */
.badge {
    font-size: 0.85em;
    font-weight: 500;
    padding: 0.35em 0.65em;
}

/* 加载动画 */
.spinner-border {
    width: 3rem;
    height: 3rem;
}

/* 响应式调整 */
@media (max-width: 768px) {
    .navbar-nav {
        text-align: center;
        padding-top: 10px;
    }

    .message {
        min-width: 250px;
        left: 50%;
        transform: translateX(-50%);
        right: auto;
    }
}

.product-thumbnail {
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #6c757d;
    font-size: 12px;
}

.product-thumbnail img {
    transition: transform 0.3s;
}

.product-thumbnail img:hover {
    transform: scale(1.1);
}

.no-image {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(45deg, #f8f9fa 25%, #e9ecef 25%, #e9ecef 50%, #f8f9fa 50%, #f8f9fa 75%, #e9ecef 75%);
    background-size: 20px 20px;
    color: #adb5bd;
    font-size: 10px;
}

/* 拖拽相关样式 */
.sortable-ghost {
    opacity: 0.4;
    background: #c8ebfb;
}

.sortable-drag {
    opacity: 0.8;
    transform: rotate(5deg);
}

.draggable-item.dragging {
    opacity: 0.5;
    transform: scale(1.05);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    z-index: 1000;
}

/* 拖拽时的视觉反馈 */
.image-preview {
    transition: transform 0.2s ease, opacity 0.2s ease;
}

.image-preview:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}