/* 全局样式重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Microsoft YaHei", Arial, sans-serif;
}

/* 页面整体背景白色，完全符合你的要求 */
body {
    background-color: #ffffff;
    color: #333333;
    line-height: 1.5;
}

/* 顶部搜索栏（仿淘宝橙色导航栏） */
.header-search {
    width: 100%;
    background-color: #ff4400;
    padding: 15px 0;
    position: sticky;
    top: 0;
    z-index: 999;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.search-container {
    width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0;
}

.search-input {
    width: 600px;
    height: 40px;
    padding: 0 15px;
    border: none;
    border-radius: 4px 0 0 4px;
    font-size: 14px;
    outline: none;
}

.search-btn {
    height: 40px;
    padding: 0 30px;
    background-color: #ffb800;
    border: none;
    border-radius: 0 4px 4px 0;
    color: #ffffff;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    transition: background-color 0.2s;
}

.search-btn:hover {
    background-color: #ffaa00;
}

/* 商品列表容器，一行4个，仿淘宝布局 */
.product-list-container {
    width: 1200px;
    margin: 20px auto;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

/* 单个商品卡片，悬浮有动效，仿淘宝商品卡片 */
.product-card {
    border: 1px solid #f4f4f4;
    border-radius: 8px;
    overflow: hidden;
    transition: all 0.2s;
    background-color: #ffffff;
}

.product-card:hover {
    box-shadow: 0 0 10px rgba(0,0,0,0.1);
    border-color: #ff4400;
    transform: translateY(-2px);
}

/* 左侧商品图片区域 */
.product-img-box {
    width: 100%;
    height: 250px;
    overflow: hidden;
    background-color: #f8f8f8;
}

.product-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s;
}

.product-card:hover .product-img {
    transform: scale(1.05);
}

/* 右侧商品参数信息区域 */
.product-info {
    padding: 12px;
}

/* 价格突出显示，淘宝红色 */
.product-price {
    font-size: 20px;
    color: #ff4400;
    font-weight: bold;
    margin-bottom: 8px;
}

.product-price span {
    font-size: 14px;
}

/* 商品名称，限制2行，避免溢出 */
.product-name {
    font-size: 14px;
    color: #333333;
    line-height: 1.4;
    height: 40px;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    margin-bottom: 10px;
}

/* 商品参数，一行一个，简洁清晰 */
.product-param {
    font-size: 12px;
    color: #666666;
    margin-bottom: 4px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.product-param span {
    color: #999999;
    margin-right: 4px;
}

/* 个人评分突出显示 */
.product-score {
    display: inline-block;
    margin-top: 6px;
    padding: 2px 6px;
    background-color: #fff2e8;
    color: #ff4400;
    font-size: 12px;
    border-radius: 4px;
    font-weight: bold;
}

/* 分页栏样式 */
.pagination-container {
    width: 1200px;
    margin: 30px auto;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.pagination-btn {
    padding: 8px 16px;
    border: 1px solid #e0e0e0;
    background-color: #ffffff;
    color: #333333;
    text-decoration: none;
    border-radius: 4px;
    font-size: 14px;
    transition: all 0.2s;
}

.pagination-btn:hover {
    border-color: #ff4400;
    color: #ff4400;
}

.pagination-btn.active {
    background-color: #ff4400;
    color: #ffffff;
    border-color: #ff4400;
}

.pagination-btn.disabled {
    color: #cccccc;
    border-color: #f0f0f0;
    cursor: not-allowed;
    pointer-events: none;
}

/* 商品统计信息 */
.page-info {
    width: 1200px;
    margin: 10px auto 0;
    font-size: 12px;
    color: #999999;
    text-align: right;
}

/* 响应式适配，手机/平板也能正常显示 */
@media (max-width: 1200px) {
    .search-container, .product-list-container, .pagination-container, .page-info {
        width: 95%;
    }
    .product-list-container {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .product-list-container {
        grid-template-columns: repeat(2, 1fr);
    }
    .search-input {
        width: 70%;
    }
}