/* ============================================
   Cozzi Cotton Product Grid - Revamped Card Layout
   ============================================ */

:root {
    /* Brand palette */
    --cozzicotton-primary: #B89658;
    --cozzicotton-primary-hover: #947844;
    --cozzicotton-gold: #d4af37;
}

/* Grid container */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr); /* Desktop default (≥992px) */
    gap: 32px;
    max-width: 1800px;
    margin: 0 auto;
    padding: 20px 0;
    font-family: "Inter", "Roboto", "Helvetica Neue", Arial, sans-serif;
}

/* Tablet (768–991px) */
@media (max-width: 991px) and (min-width: 768px) {
    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Mobile (≤767px) */
@media (max-width: 767px) {
    .gallery-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .product-media {
        height: 260px; /* smaller media height for mobile */
    }
}

/* Card */
.product-card {
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, .08);
    transition: transform .2s ease, box-shadow .2s ease;
    overflow: hidden;
}

.product-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 16px 40px rgba(0, 0, 0, .12);
}

/* Media (image container) */
.product-media {
    position: relative;
    height: 340px; /* desktop height */
    overflow: hidden;
}

.product-media img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* image fills card */
    transform: scale(1);
    transition: transform .5s ease;
}

.product-card:hover .product-media img {
    transform: scale(1.08); /* zoom effect on hover */
}

/* Meta (title, artist, price) */
.product-meta {
    padding: 14px 16px 16px;
    color: #1A1A1A;
}

.product-title {
    margin: 0 0 4px;
    font-size: 18px;
    line-height: 1.25;
}

.product-title a {
    color: inherit;
    text-decoration: none;
}

.product-title a:hover {
    color: var(--cozzicotton-primary-hover);
}

.product-artist {
    font-size: 13px;
    color: #6B7280;
    margin-bottom: 6px;
}

.product-price {
    font-weight: 600;
    color: var(--cozzicotton-primary);
}

.product-item {
    break-inside: avoid;
    margin-bottom: 16px;
}

.product-item img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 8px;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.product-item img:hover {
    transform: scale(1.02);
}

.product-info {
    text-align: center;
    margin-top: 10px;
}

/* Title styling */
.product-info h4 {
    margin: 0;
    font-size: 1.3rem;
    font-weight: 600;
    color: #222;
    line-height: 1.4;
    word-break: break-word;
}

/* Make title clickable with clean link style */
.product-info h4 a {
    text-decoration: none;
    color: inherit;
}

.product-info h4 a:hover {
    text-decoration: underline;
}

/* Price styling */
.product-info .price {
    margin-top: 6px;
    font-weight: 500;
    font-size: 1.2rem;
    color: #111;
}
