/* 主样式文件 */

/* 基础样式重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    font-size: 16px;
    line-height: 1.5;
    color: #333;
    background-color: #f8f9fa;
}

/* 头部样式 */
header {
    background-color: #fff;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-top {
    background-color: #f0f0f0;
    padding: 10px 0;
}

.header-bottom {
    padding: 15px 0;
}

.logo {
    font-size: 24px;
    font-weight: bold;
    color: #007bff;
    text-decoration: none;
}

.search-form {
    max-width: 500px;
}

.cart-btn {
    position: relative;
}

.cart-count {
    position: absolute;
    top: -10px;
    right: -10px;
    background-color: #dc3545;
    color: white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    font-size: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* 产品卡片样式 */
.product-card {
    transition: transform 0.3s, box-shadow 0.3s;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    overflow: hidden;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.product-image {
    position: relative;
}

.product-image img {
    transition: transform 0.3s;
}

.product-card:hover .product-image img {
    transform: scale(1.05);
}

/* 销售模式标签样式 */
.badge.bg-purple {
    background-color: #6f42c1;
}

/* 价格样式 */
.price {
    font-size: 1.2rem;
    font-weight: bold;
    color: #dc3545;
}

.original-price {
    font-size: 0.9rem;
    text-decoration: line-through;
    color: #6c757d;
}

/* 按钮样式 */
.btn-primary {
    background-color: #007bff;
    border-color: #007bff;
}

.btn-primary:hover {
    background-color: #0056b3;
    border-color: #0056b3;
}

.btn-outline-primary {
    color: #007bff;
    border-color: #007bff;
}

.btn-outline-primary:hover {
    background-color: #007bff;
    color: white;
}

/* 购物车页面样式 */
.cart-item {
    border-bottom: 1px solid #e9ecef;
    padding: 15px 0;
}

.cart-item:last-child {
    border-bottom: none;
}

.cart-item-image {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 4px;
}

/* 订单页面样式 */
.order-card {
    border: 1px solid #e9ecef;
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 20px;
}

.order-header {
    background-color: #f8f9fa;
    padding: 15px;
    border-bottom: 1px solid #e9ecef;
}

.order-body {
    padding: 15px;
}

/* 标签页样式 */
.nav-tabs .nav-link {
    color: #6c757d;
}

.nav-tabs .nav-link.active {
    color: #007bff;
    border-color: #dee2e6 #dee2e6 #fff;
}

/* 筛选栏样式 */
.filter-card {
    border: 1px solid #e9ecef;
    border-radius: 8px;
    margin-bottom: 20px;
}

.filter-card .card-header {
    background-color: #f8f9fa;
    border-bottom: 1px solid #e9ecef;
}

/* 分页样式 */
.pagination .page-item.active .page-link {
    background-color: #007bff;
    border-color: #007bff;
}

.pagination .page-link {
    color: #007bff;
}

/* 页脚样式 */
footer {
    background-color: #f8f9fa;
    color: #333;
    padding: 30px 0;
    margin-top: 50px;
}

.footer-links {
    list-style: none;
    padding: 0;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    color: #6c757d;
    text-decoration: none;
    transition: color 0.3s;
}

.footer-links a:hover {
    color: #007bff;
}

.footer-bottom {
    border-top: 1px solid rgba(0, 0, 0, 0.1);
    padding-top: 20px;
    margin-top: 20px;
    text-align: center;
}

/* 响应式样式 */
@media (max-width: 768px) {
    .search-form {
        margin-top: 15px;
    }
    
    .header-bottom {
        text-align: center;
    }
    
    .cart-btn {
        margin-top: 15px;
    }
}

/* 自定义容器宽度 - 大屏幕最大宽度调整为1550px */
@media (min-width: 1200px) {
    .container {
        max-width: 1550px !important;
    }
}
