/*
 * GD Product Item — single product card.
 * Used inside .gd-product-category__grid.
 * Depends on gd-colors.css for --gd-* custom properties.
 */

.gd-product-item {
    list-style: none;
    min-height: 420px;
}

.gd-product-item__link {
    display: flex;
    flex-direction: column;
    width: 100%;
    height: 100%;
    background-color: #ffffff;
    border-radius: var(--gd-card-radius);
    gap: var(--gd-card-gap);
    padding: var(--gd-card-image-inset);
    box-sizing: border-box;
    text-decoration: none;
    color: inherit;
    transition: transform 0.15s ease;
}

.gd-product-item__link:hover {
    transform: translateY(-5px);
}

.gd-product-item__image {
    border-radius: var(--gd-card-image-radius);
    background: var(--gd-white, #ffffff);
    overflow: hidden;
}

.gd-product-item__image--placeholder {
    width: 100%;
    height: 270px;
}

.gd-product-item__img {
    width: 100%;
    height: 230px !important;
    display: block;
    border-radius: var(--gd-card-image-radius) !important;
}

.gd-product-item__image--fit-contain .gd-product-item__img {
    object-fit: contain;
}

.gd-product-item__image--fit-cover .gd-product-item__img {
    object-fit: cover;
}

.gd-product-item__main-content {
    padding: var(--gd-card-body-padding);
}

/* Center both title elements horizontally */
.gd-product-item__link .gd-header-wrapper {
    text-align: center;
}

/* CTA pushed to the bottom of the card; arrow animates on card hover */
.gd-product-item__cta {
    margin: auto var(--gd-card-body-padding) var(--gd-card-body-padding);
    align-self: center;
    display: flex;
    flex-direction: row;
}

.gd-product-item__link:hover .gd-button-icon {
    transform: translateX(4px);
}

.gd-product-item--style-with-category .gd-product-item__link .gd-header-wrapper {
    text-align: left;
}

.gd-product-item--style-with-category .gd-header--pre-card-title {
    margin-bottom: var(--gd-card-pretitle-gap);
}

.gd-product-item--style-with-category .gd-product-item__cta {
    align-self: flex-start;
}

