/* 基础样式 */
body {
    background-color: #f0f7ff;
    background-image:
            radial-gradient(circle at 10% 20%, rgba(255,183,215,0.1) 0%, transparent 20%),
            radial-gradient(circle at 90% 70%, rgba(166,189,255,0.1) 0%, transparent 30%);
    color: #333;
}
.container {
    max-width: 1200px;
    padding-left: 15px;
    padding-right: 15px;
    margin-left: auto;
    margin-right: auto;
}

/* 平板端容器优化 */
@media (max-width: 992px) {
    .container {
        padding-left: 12px;
        padding-right: 12px;
    }
}

/* 手机端容器优化 */
@media (max-width: 768px) {
    .container {
        padding-left: 10px;
        padding-right: 10px;
    }
}

@media (max-width: 480px) {
    .container {
        padding-left: 8px;
        padding-right: 8px;
    }
}

/* 顶部导航  */
.site-header {
    background: linear-gradient(135deg, #ff9fd4 0%, #b58eff 100%);
    padding: 18px 0;
    box-shadow: 0 3px 15px rgba(200, 120, 255, 0.2);
    margin-bottom: 30px;
    border-bottom: 2px solid rgba(255,255,255,0.3);
}
.logo {
    display: flex;
    align-items: center;
    color: #fff;
    font-weight: bold;
    font-size: 1.5rem;
    text-decoration: none;
    text-shadow: 0 2px 4px rgba(100, 50, 150, 0.3);
}
.logo i {
    color: #fff;
    margin-right: 10px;
    font-size: 1.8rem;
    text-shadow: 0 2px 4px rgba(100, 50, 150, 0.3);
}
.login-link {
    color: #fff;
    text-decoration: none;
    font-size: 1rem;
    transition: all 0.3s;
    text-shadow: 0 1px 2px rgba(100, 50, 150, 0.2);
}
.login-link:hover {
    color: #fff;
    text-decoration: none;
    transform: scale(1.05);
}

/* 网站公告栏样式 */
.goods-list-notice {
    margin-bottom: 20px;
    border-radius: 12px;
    background-image:
            radial-gradient(circle at 10% 20%, rgba(255,183,215,0.1) 0%, transparent 20%),
            radial-gradient(circle at 90% 70%, rgba(166,189,255,0.1) 0%, transparent 30%);
    box-shadow: 0 3px 10px rgba(138, 95, 255, 0.1);
    overflow: hidden;
    position: relative;
    border: 1px solid rgba(255,255,255,0.3);
}

.notice-header {
    display: flex;
    align-items: center;
    padding: 12px 20px;
    gap: 10px;
    border-bottom: 1px solid rgba(181,126,255,0.1);
}

.notice-header .fa-bullhorn {
    font-size: 1.1rem;
    color: #8a5fff;
    flex-shrink: 0;
}

.notice-title {
    font-size: 0.95rem;
    color: #8a5fff;
    font-weight: 600;
    text-shadow: 0 1px 2px rgba(138, 95, 255, 0.2);
}

.notice-content {
    padding: 15px 20px;
}

.notice-text {
    font-size: 0.95rem;
    color: #5a4fcf;
    font-weight: 500;
    line-height: 1.6;
    word-break: break-word;
    margin: 0;
}

/* 公告栏悬浮效果 */
.goods-list-notice:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(138, 95, 255, 0.15);
    transition: all 0.3s ease;
}

/* 页面标题 */
.page-title {
    color: #8a5fff;
    font-weight: bold;
    margin-bottom: 25px;
    display: flex;
    align-items: center;
    font-size: 1.8rem;
    text-shadow: 0 1px 2px rgba(138, 95, 255, 0.2);
}
.page-title i {
    color: #ff7eb9;
    margin-right: 10px;
    animation: float 3s ease-in-out infinite;
}

/* 分类区域 */
.category-container {
    background: linear-gradient(135deg, rgba(255,255,255,0.9) 0%, rgba(248,250,255,0.9) 100%);
    padding: 15px 15px 10px 15px;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(138, 95, 255, 0.08);
    margin-bottom: 25px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255,255,255,0.6);
    position: relative;
    overflow: hidden;
}
.category-scroller {
    width: 100%;
    overflow-x: auto;
}
.category-list-shanjun {
    display: flex;
    flex-wrap: wrap;
    margin: 0;
    padding: 0;
    list-style: none;
    gap: 8px;
}
.category-item {
    flex: 0 0 auto;
}
@media (max-width: 992px) {
    .category-list-shanjun {
        flex-wrap: wrap;
    }
    .category-item {
        margin-bottom: 4px;
    }
}

@media (max-width: 768px) {
    .category-container {
        padding: 12px;
        margin-bottom: 20px;
    }
    
    .category-list-shanjun{
        display: flex;
        flex-wrap: wrap;
        gap: 8px;
    }
    
    .category-item{
        margin: 0;
        text-align: center;
    }
    
    .category-item a{
        display: block;
        width: 100%;
        padding: 8px 12px;
        font-size: 0.85rem;
    }
    
    .category-scroller {
        overflow-x: visible;
        padding-bottom: 0;
    }
}

@media (max-width: 480px) {
    .category-container {
        padding: 10px;
        margin-bottom: 15px;
    }
   
    
    .category-item a{
        padding: 6px 10px;
        font-size: 0.8rem;
    }
}

.category-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 16px;
    border-radius: 12px;
    text-decoration: none;
    font-size: 0.9rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-weight: 500;
    position: relative;
    overflow: hidden;
    min-height: 36px;
}
.category-link:hover{
    text-decoration: none;
    transform: translateY(-1px);
}
.category-link.active {
    background: linear-gradient(135deg, #8a5fff 0%, #7d48ff 100%);
    color: #fff;
    box-shadow: 0 3px 10px rgba(138, 95, 255, 0.2);
    border: 1px solid rgba(255,255,255,0.2);
}
.category-link.active::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent 0%,
        rgba(255,255,255,0.2) 50%,
        transparent 100%
    );
    animation: category-shine 3s infinite;
}
@keyframes category-shine {
    0% { left: -100%; }
    50% { left: 100%; }
    100% { left: 100%; }
}
.category-link.inactive {
    background: rgba(255,255,255,0.6);
    color: #6a5acd;
    box-shadow: 0 1px 4px rgba(138, 95, 255, 0.08);
    border: 1px solid rgba(138, 95, 255, 0.1);
}
.category-link.inactive:hover {
    background: rgba(255,255,255,0.8);
    transform: translateY(-1px);
    box-shadow: 0 3px 8px rgba(138, 95, 255, 0.12);
    border-color: rgba(138, 95, 255, 0.2);
}

/* 商品数量样式 */
.category-count {
    font-size: 0.75rem;
    font-weight: 600;
    color: #8a5fff;
    background: rgba(138, 95, 255, 0.12);
    padding: 2px 6px;
    border-radius: 8px;
    min-width: 20px;
    text-align: center;
    white-space: nowrap;
    border: 1px solid rgba(138, 95, 255, 0.2);
}

.category-link.active .category-count {
    background: rgba(255,255,255,0.2);
    color: #fff;
}

/* 分类名称样式 */
.category-name {
    flex: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 120px;
}

/* 商品列表 */
.product-list {
    margin-bottom: 30px;
}
.product-item {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    background-color: rgba(255,255,255,0.9);
    padding: 12px;
    border-radius: 12px;
    box-shadow: 0 5px 15px rgba(138, 95, 255, 0.08);
    margin-bottom: 12px;
    transition: all 0.3s;
    border: 1px solid rgba(255,255,255,0.8);
}

/* 使用手机端布局 */
.product-item {
    flex-direction: column;
    align-items: stretch;
    padding: 10px;
    margin-bottom: 10px;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(138, 95, 255, 0.06);
    border: 1px solid rgba(138, 95, 255, 0.08);
    background: linear-gradient(135deg, rgba(255,255,255,0.95) 0%, rgba(248,250,255,0.95) 100%);
    position: relative;
    overflow: hidden;
    padding-bottom: 3px;
}

/* 左右布局包装器 */
.product-content-wrapper {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 10px;
}



/* 隐藏原始的图片和详情 */
.product-item > .product-image,
.product-item > .product-details {
    display: none;
}

/* 图片样式 */
.product-content-wrapper .product-image {
    width: 100px;
    height: 100px;
    margin-right: 0;
    margin-bottom: 0;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(138, 95, 255, 0.15);
    border: 2px solid rgba(255,255,255,0.8);
    position: relative;
    flex-shrink: 0;
}

.product-content-wrapper .product-image::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(138,95,255,0.1) 0%, rgba(255,126,185,0.1) 100%);
    z-index: 1;
    pointer-events: none;
}

.product-content-wrapper .product-image img {
    border-radius: 6px;
    transition: transform 0.4s ease;
}

.product-content-wrapper .product-image:hover img {
    transform: scale(1.05);
}

/* 自动发货标签样式 */
.auto-delivery-tag {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    color: #fff;
    font-size: 0.7rem;
    font-weight: 600;
    padding: 4px 8px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    gap: 3px;
    box-shadow: 0 2px 6px rgba(40, 167, 69, 0.3);
    animation: pulse-green 2s infinite;
    border: 1px solid rgba(255, 255, 255, 0.2);
    flex-shrink: 0;
    order: 3;
}

.auto-delivery-tag i {
    font-size: 0.65rem;
    animation: flash-green 1.5s infinite;
}

.auto-delivery-tag span {
    white-space: nowrap;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

/* 绿色脉冲动画 */
@keyframes pulse-green {
    0% {
        box-shadow: 0 2px 6px rgba(40, 167, 69, 0.3);
        transform: scale(1);
    }
    50% {
        box-shadow: 0 2px 8px rgba(40, 167, 69, 0.5);
        transform: scale(1.05);
    }
    100% {
        box-shadow: 0 2px 6px rgba(40, 167, 69, 0.3);
        transform: scale(1);
    }
}

/* 闪电图标闪烁动画 */
@keyframes flash-green {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.6;
        transform: scale(0.9);
    }
}

/* 人工发货标签样式 */
.manual-delivery-tag {
    background: linear-gradient(135deg, #ff7eb9 0%, #ff6b9d 100%);
    color: #fff;
    font-size: 0.7rem;
    font-weight: 600;
    padding: 4px 8px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    gap: 3px;
    box-shadow: 0 2px 6px rgba(255, 126, 185, 0.3);
    animation: pulse-pink 2s infinite;
    border: 1px solid rgba(255, 255, 255, 0.2);
    flex-shrink: 0;
    order: 3;
}

.manual-delivery-tag i {
    font-size: 0.65rem;
    animation: flash-pink 1.5s infinite;
}

.manual-delivery-tag span {
    white-space: nowrap;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

/* 粉色脉冲动画 */
@keyframes pulse-pink {
    0% {
        box-shadow: 0 2px 6px rgba(255, 126, 185, 0.3);
        transform: scale(1);
    }
    50% {
        box-shadow: 0 2px 8px rgba(255, 126, 185, 0.5);
        transform: scale(1.05);
    }
    100% {
        box-shadow: 0 2px 6px rgba(255, 126, 185, 0.3);
        transform: scale(1);
    }
}

/* 手指图标闪烁动画 */
@keyframes flash-pink {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.6;
        transform: scale(0.9);
    }
}

/* 详情样式 */
.product-content-wrapper .product-details {
    flex: 1;
    margin-bottom: 0;
    padding: 0;
    min-width: 0;
    margin-top: 3px;
}

.product-content-wrapper .product-title {
    font-size: 0.9rem;
    line-height: 1.3;
    font-weight: 600;
    color: #5a4fcf;
    margin-bottom: 4px;
    height: 2.6em; /* 两行高度 = 1.3 * 2 */
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
}

.product-content-wrapper .product-desc {
    font-size: 0.75rem;
    line-height: 1.3;
    color: #888;
    font-weight: 400;
    margin-bottom: 2px;
    height: 2.6em; /* 两行高度 = 1.3 * 2 */
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
}

/* 详情区域价格样式 */
.product-details .product-price {
    display: inline-block;
    font-size: 1rem;
    font-weight: 700;
    color: #ff4785;
    text-shadow: 0 1px 2px rgba(255,71,133,0.1);
    white-space: nowrap;
}

/* 价格容器 */
.price-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

/* 划线价样式 */
.product-market-price {
    font-size: 0.9rem;
    color: #999;
    text-decoration: line-through;
    opacity: 0.7;
    font-weight: 400;
    position: relative;
    transition: all 0.3s ease;
}

/* 划线价hover效果 */
.product-market-price:hover {
    opacity: 1;
    color: #666;
}

/* 为划线价添加删除线动画 */
.product-market-price::after {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    width: 100%;
    height: 1px;
    background: linear-gradient(90deg, transparent 0%, #ff6b6b 50%, transparent 100%);
    transform: translateY(-50%) scaleX(0);
    transform-origin: center;
    transition: transform 0.3s ease;
}

.product-market-price:hover::after {
    transform: translateY(-50%) scaleX(1);
}

/* 操作区域样式 */
.product-actions {
    width: 100%;
    display: flex;
    padding: 8px 2px;
    border-top: 1px solid rgba(138, 95, 255, 0.1);
    flex-direction: row;
    align-items: center;
    gap: 8px;
    background: linear-gradient(135deg, rgba(248,250,255,0.8) 0%, rgba(240,245,255,0.8) 100%);
    border-radius: 6px;
    margin: 0;
}



.product-actions .btn-primary
 {
    flex: 1;
    text-align: center;
    order: 4;
    padding: 4px 8px;
    font-size: 0.7rem;
    border-radius: 6px;
    background: linear-gradient(135deg, #8a5fff 0%, #7d48ff 100%);
    box-shadow: 0 2px 6px rgba(138, 95, 255, 0.2);
    min-height: 27px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 500;
    white-space: nowrap;
    flex-shrink: 0;
    color: #fff;
}



.product-actions .product-sales {
    flex: 0 0 auto;
    order: 2;
    justify-content: center;
    margin: 0;
    padding: 4px 12px;
    background: rgba(138, 95, 255, 0.08);
    border-radius: 4px;
    font-size: 0.8rem;
    color: #6a5acd;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    white-space: nowrap;
    flex-shrink: 0;
}

.product-actions .product-sales i {
    color: #8a5fff;
    margin-right: 3px;
    font-size: 0.7rem;
}

.product-actions .product-sales:first-of-type {
    order: 1;
}

.product-actions .product-sales:nth-of-type(2) {
    order: 2;
}




.product-item:hover {
    box-shadow: 0 8px 20px rgba(138, 95, 255, 0.15);
}

/* 流光效果 */
.product-item {
    position: relative;
    overflow: hidden;
}

.product-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent 0%,
        rgba(255, 255, 255, 0.2) 20%,
        rgba(255, 255, 255, 0.4) 50%,
        rgba(255, 255, 255, 0.2) 80%,
        transparent 100%
    );
    transform: skewX(-15deg);
    transition: left 0.8s ease;
    z-index: 10;
    pointer-events: none;
}

.product-item:hover::before {
    left: 100%;
}

/* 添加额外的hover效果 */
.product-item:hover {
    transform: translateY(-2px);
    transition: all 0.3s ease;
}

.product-image {
    width: 80px;
    height: 80px;
    flex-shrink: 0;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 3px 8px rgba(0,0,0,0.1);
    border: 2px solid #fff;
}


.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}
.product-item:hover .product-image img {
    transform: scale(1.08);
}

.product-details {
    flex: 1;
    min-width: 0;
    margin-bottom: 15px;
}



.product-title {
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: #6a5acd;
    font-size: 1.1rem;
    /* 允许在单词内换行 */
    word-break: break-word;
    /* 允许在单词之间换行 */
    overflow-wrap: break-word;
    /* 确保文本不会溢出容器 */
    white-space: normal;
}















/* 分页样式 */
.pagination-container {
    text-align: center;
    margin-top: 30px;
}
.pagination .page-item .page-link {
    color: #8a5fff;
    border-color: #e6d9ff;
    border-radius: 8px;
    margin: 0 3px;
    transition: all 0.2s;
}
.pagination .page-item.active .page-link {
    background-color: #b58eff;
    border-color: #b58eff;
}
.pagination .page-item:hover .page-link:not(.active) {
    background-color: #f0e6ff;
    transform: translateY(-2px);
}

/* 滚动条样式 */
.category-scroller::-webkit-scrollbar {
    height: 8px;
}
.category-scroller::-webkit-scrollbar-track {
    background: rgba(248,250,255,0.5);
    border-radius: 10px;
}
.category-scroller::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #ff7eb9 0%, #8a5fff 100%);
    border-radius: 10px;
    border: 1px solid rgba(255,255,255,0.2);
}
.category-scroller::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, #b58eff 0%, #7d48ff 100%);
    transform: scale(1.1);
}

/* 动画效果 */
@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-8px); }
    100% { transform: translateY(0px); }
}



