
/*
 * PD TAPETE — Global Product Card
 * One design shared across every listing.
 */

.pd-products-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 24px 16px;
    align-items: stretch;
}

.pd-product-card,
.pd-product-card * {
    box-sizing: border-box;
}

.pd-product-card {
    display: flex;
    flex-direction: column;
    min-width: 0;
    height: 100%;
    overflow: hidden;
    background: #ffffff;
    border: 1px solid #dadada;
    transition:
        transform .25s ease,
        box-shadow .25s ease,
        border-color .25s ease;
}

.pd-product-card:hover {
    transform: translateY(-4px);
    border-color: #a0a0a0;
    box-shadow: 0 15px 34px rgba(33,33,33,.08);
}

/* Product image */

.pd-product-card__media {
    position: relative;
    width: 100%;
    aspect-ratio: 4 / 4.5;
    overflow: hidden;
    background: #dadada;
}

.pd-product-card__image-link {
    display: block;
    width: 100%;
    height: 100%;
}

.pd-product-card__media img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .45s ease;
}

.pd-product-card:hover .pd-product-card__media img {
    transform: scale(1.045);
}

.pd-product-card__placeholder {
    display: grid;
    place-items: center;
    width: 100%;
    height: 100%;
    padding: 15px;
    background: linear-gradient(
        135deg,
        #dadada,
        #c2c2c2
    );
    color: #606060;
    text-align: center;
    font: italic 19px Georgia, serif;
}

/* Wishlist */

.pd-product-card__wishlist {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 2;
    display: grid;
    place-items: center;
    width: 35px;
    height: 35px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: rgba(253,253,253,.96);
    color: #1b1b1b;
    cursor: pointer;
    transition: background .2s, color .2s;
}

.pd-product-card__wishlist:hover {
    background: #dadada;
}

.pd-product-card__wishlist svg {
    width: 18px;
    height: 18px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.7;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.pd-product-card__wishlist.is-saved {
    color: #444444;
}

.pd-product-card__wishlist.is-saved svg {
    fill: currentColor;
}

/* Title left, details right */

.pd-product-card__body {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    flex: 1;
    min-height: 70px;
    padding: 14px 13px;
    flex-direction: column;
}

.pd-product-card__title {
    flex: 1;
    min-width: 0;
    margin: 0;
    color: #1b1b1b;
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 17px;
    font-weight: 400;
    line-height: 1.4;
    overflow-wrap: anywhere;
}

.pd-product-card__title a {
    color: inherit;
    text-decoration: none;
}

.pd-product-card__title a:hover {
    color: #444444;
}

.pd-product-card__details {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    flex-shrink: 0;
    color: #444444;
    font-family: 'DM Sans', Arial, sans-serif;
    font-size: 11px;
    font-weight: 600;
    white-space: nowrap;
    text-decoration: none;
}

.pd-product-card__details:hover {
    color: #1b1b1b;
}

.pd-product-card__details svg {
    width: 16px;
    height: 16px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.7;
}

/* Responsive */

@media (max-width: 1100px) {
    .pd-products-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 850px) {
    .pd-products-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 600px) {
    .pd-products-grid {
        gap: 14px 10px;
    }

    .pd-product-card__media {
        aspect-ratio: 4 / 4.6;
    }

    .pd-product-card__body {
        min-height: 59px;
        padding: 11px 9px;
        gap: 7px;
    }

    .pd-product-card__title {
        font-size: 14px;
    }

    .pd-product-card__details {
        font-size: 9px;
        gap: 3px;
    }

    .pd-product-card__details svg {
        width: 13px;
        height: 13px;
    }

    .pd-product-card__wishlist {
        top: 7px;
        right: 7px;
        width: 30px;
        height: 30px;
    }

    .pd-product-card__wishlist svg {
        width: 16px;
        height: 16px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .pd-product-card,
    .pd-product-card__media img {
        transition: none;
    }
}



/* =============================================================
   PD TAPETE — Rug photography: show the full rug, without crop.
   Applied to the shared category/collection cards and Shop cards.
   The !important declarations also override older page-level styles.
   ============================================================= */
.pd-product-card__media,
.pds-card-media {
    background: #ffffff !important;
    padding: 12px !important;
    box-sizing: border-box;
}

.pd-product-card__image-link,
.pds-card-image-link {
    display: flex !important;
    justify-content: center;
    align-items: center;
    width: 100%;
    height: 100%;
}

.pd-product-card__media img,
.pds-card-media img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain !important;
    object-position: center center !important;
    background: #ffffff !important;
    transform: none !important;
}

.pd-product-card:hover .pd-product-card__media img,
.pds-card:hover .pds-card-media img {
    transform: none !important;
}

@media (max-width: 600px) {
    .pd-product-card__media,
    .pds-card-media { padding: 7px !important; }
}
