/*
Theme Name: Sol Fundas
Template: fundas
*/


/* ===== 自定义单产品页面 ===== */
.custom-single-product {
    display: flex;
    flex-wrap: wrap;
    gap: 2.5rem;
    margin: 2rem 0;
    background: #fff;
    padding: 2rem;
    border-radius: 20px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.05);
}

.product-images {
    flex: 1 1 45%;
    min-width: 280px;
}

.product-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 0.8rem;
}

.product-gallery .gallery-item {
    border-radius: 12px;
    overflow: hidden;
    background: #f9f7f0;
    aspect-ratio: 1 / 1;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.product-gallery .gallery-item:hover {
    transform: scale(1.03);
}

.product-gallery img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.product-info {
    flex: 1 1 45%;
    min-width: 280px;
}

.product-title {
    font-size: 2.2rem;
    font-weight: 700;
    color: #2d2d2d;
    margin: 0 0 0.5rem;
}

.product-price {
    font-size: 1.8rem;
    font-weight: 700;
    color: #CE1126;
    margin-bottom: 0.5rem;
}

.product-rating {
    margin-bottom: 0.5rem;
}

.product-short-description {
    font-size: 1rem;
    color: #555;
    margin: 1rem 0 1.5rem;
    line-height: 1.6;
}

.product-attributes {
    background: #f8f6f0;
    padding: 0.8rem 1.2rem;
    border-radius: 12px;
    margin: 1.2rem 0;
}

.attr-item {
    display: flex;
    justify-content: space-between;
    padding: 0.3rem 0;
    border-bottom: 1px solid #e5e0d6;
}

.attr-item:last-child {
    border-bottom: none;
}

.attr-label {
    font-weight: 600;
    color: #006341;
}

.attr-value {
    color: #333;
}

.product-add-to-cart {
    margin: 1.5rem 0;
}

.product-add-to-cart .single_add_to_cart_button {
    background: #006341;
    color: #fff;
    padding: 0.8rem 2.5rem;
    border-radius: 50px;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: background 0.2s;
}

.product-add-to-cart .single_add_to_cart_button:hover {
    background: #004a30;
}

.product-meta {
    margin-top: 1rem;
    font-size: 0.9rem;
    color: #777;
}

/* ===== 相关产品 ===== */
.related-products {
    margin-top: 3rem;
}

.related-title {
    font-size: 1.8rem;
    color: #2d2d2d;
    border-left: 6px solid #CE1126;
    padding-left: 1rem;
    margin-bottom: 1.5rem;
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1.5rem;
    list-style: none;
    padding: 0;
}

.product-item {
    background: #fff;
    border-radius: 16px;
    padding: 1rem;
    text-align: center;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
    transition: transform 0.2s, box-shadow 0.2s;
}

.product-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.08);
}

.product-item img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin-bottom: 0.5rem;
}

.product-item h3 {
    font-size: 1rem;
    font-weight: 600;
    color: #2d2d2d;
    margin: 0.5rem 0;
}

.product-item .price {
    color: #CE1126;
    font-weight: 700;
    display: block;
    margin-bottom: 0.5rem;
}

.product-item .add_to_cart_button {
    background: #006341;
    color: #fff;
    padding: 0.3rem 1.2rem;
    border-radius: 30px;
    font-size: 0.8rem;
    border: none;
    cursor: pointer;
    transition: background 0.2s;
}

.product-item .add_to_cart_button:hover {
    background: #004a30;
}

/* ===== 响应式 ===== */
@media (max-width: 768px) {
    .custom-single-product {
        flex-direction: column;
        padding: 1rem;
    }
    .product-title {
        font-size: 1.8rem;
    }
    .product-price {
        font-size: 1.5rem;
    }
    .product-gallery {
        grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
        gap: 0.5rem;
    }
}
