/* 容器样式 */
.product-3 {
    width: calc(100% + 10px);
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-start;
}

/* 单个项目样式 */
.product-3 .item {
    width: calc(25% - 10px); /* 每个项目占据25%的宽度，减去左右padding */
    margin-right: 10px;
    margin-bottom:10px;
    border-radius: 8px;
    overflow: hidden;
}

.product-3 .item .imgs {
    position: relative; /* 为了绝对定位描述文本（可选） */
    height: 360px; /* 固定高度，你可以根据需要调整 */
    overflow: hidden; /* 确保图片放大时不会溢出容器 */
}

.product-3 .item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease; /* 添加过渡效果 */
}

.product-3 .item:hover img {
    transform: scale(1.02); /* 当鼠标悬停时，图片放大到原来的1.05倍 */
}

.product-3 .item .text {
    bottom: 10px; /* 距离容器底部的距离 */
    left: 0;
    right: 0;
    margin: 0 auto;
    font-size:16px;
    width: max-content; /* 或其他适当的宽度 */
    padding: 15px; /* 可选的，为了增加可读性 */
}

.product-3 .item .text p{
    font-weight: bold;
    padding-bottom:5px;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .product-3 .item {
        flex: 1 1 calc(50% - 20px); /* 每个项目占据50%的宽度 */
    }
}

@media (max-width: 480px) {
    .product-3 .item {
        flex: 1 1 calc(100% - 20px); /* 每个项目占据100%的宽度 */
    }
}