.wp-block-headless-product-cards {
    padding: clamp(28px, 3.2vw, 40px);
    border-radius: 34px;
    background: transparent;
    box-shadow: none;
}

.product-cards-header {
    margin-bottom: 34px;
    text-align: center;
}

.product-cards-section-title {
    margin: 0;
    color: #365072;
    font-size: 52px;
    font-weight: 600;
    line-height: 1.1;
}

.product-cards-section-subtitle {
    max-width: 760px;
    margin: 16px auto 0;
    color: rgba(22, 30, 35, 0.75);
    font-size: clamp(1.02rem, 1.5vw, 1.35rem);
    line-height: 1.6;
}

.product-cards-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 28px;
}

.product-cards-grid[data-card-count="1"] {
    grid-template-columns: minmax(0, 1fr);
}

.product-cards-grid[data-card-count="2"] {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.product-cards-grid[data-card-count="3"] {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.product-cards-card {
    display: flex;
    flex-direction: column;
    min-height: 100%;
    overflow: hidden;
    border-radius: 30px;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 20px 46px rgba(27, 45, 61, 0.08);
    text-decoration: none;
    transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.product-cards-card.is-highlighted {
    box-shadow: 0 20px 46px rgba(27, 45, 61, 0.08);
}

.product-cards-card:hover,
.product-cards-card.is-highlighted:hover {
    transform: translateY(-8px);
    box-shadow: 0 28px 60px rgba(67, 98, 124, 0.18);
}

.product-cards-card-top {
    position: relative;
    overflow: hidden;
}

.product-cards-title {
    margin: 0 0 12px;
    color: #365072;
    font-size: clamp(1.6rem, 2vw, 2rem);
    font-weight: 600;
    line-height: 1.06;
    letter-spacing: -0.03em;
}

.product-cards-subtitle {
    margin: 0 0 12px;
    color: #000000;
    font-size: 20px;
    font-weight: 600;
    line-height: 1.3;
}

.product-cards-count {
    position: absolute;
    top: 18px;
    right: 18px;
    flex: 0 0 auto;
    color: rgba(255, 255, 255, 0.92);
    font-size: 1rem;
    font-weight: 700;
    line-height: 1;
    z-index: 2;
}

.product-cards-count span {
    color: rgba(255, 255, 255, 0.46);
    font-weight: 600;
}

.product-cards-image {
    display: flex;
    align-items: flex-end;
    justify-content: center;
    min-height: 470px;
    padding: 10px 18px 0;
    background: linear-gradient(180deg, #5b7099 0%, #b7d8eb 100%);
}

.product-cards-image img {
    display: block;
    max-width: 118%;
    max-height: 505px;
    width: auto;
    height: auto;
    object-fit: contain;
    transform: scale(1.08);
    transform-origin: center bottom;
}

.product-cards-card:nth-child(1) .product-cards-image {
    background: linear-gradient(180deg, #5b7099 0%, #b7d8eb 100%);
}

.product-cards-card:nth-child(2) .product-cards-image {
    background: linear-gradient(180deg, #ffc08b 0%, #bedcf0 100%);
}

.product-cards-card:nth-child(3) .product-cards-image {
    background: linear-gradient(180deg, #313131 0%, #d8dce3 100%);
}

.product-cards-image-placeholder {
    border-radius: 0;
    border: none;
    background: transparent;
}

.product-cards-image-placeholder span {
    color: #6e7b86;
    font-size: 0.95rem;
    font-weight: 600;
}

.product-cards-footer {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    position: relative;
    z-index: 2;
    margin-top: -132px;
    padding: 30px 24px 26px;
    background: rgba(255, 255, 255, 0.98);
    border-top-left-radius: 26px;
    border-top-right-radius: 26px;
}

.product-cards-description {
    margin: 0 0 16px;
    color: rgba(22, 30, 35, 0.75);
    font-size: 0.875rem;
    line-height: 1.6;
}

.product-cards-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 18px;
}

.product-cards-tag {
    display: inline-flex;
    align-items: center;
    min-height: 34px;
    padding: 0 14px;
    border-radius: 999px;
    background: #edf2f7;
    color: #728191;
    font-size: 0.86rem;
    font-weight: 600;
    line-height: 1;
}

.product-cards-cta {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: auto;
    color: #fa700d;
    font-size: 1rem;
    font-weight: 700;
}

.product-cards-compare-wrap {
    display: flex;
    justify-content: center;
    margin-top: 28px;
}

.product-cards-compare-link {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: rgba(255, 255, 255, 0.96);
    text-decoration: none;
    font-size: 1rem;
    font-weight: 700;
}

.product-cards-compare-link::after {
    content: "→";
    font-size: 1.05em;
}

@media (max-width: 1200px) {
    .product-cards-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 700px) {
    .wp-block-headless-product-cards {
        padding: 16px;
        border-radius: 22px;
    }

    .product-cards-header {
        margin-bottom: 20px;
    }

    .product-cards-section-title {
        font-size: clamp(1.8rem, 7vw, 2.4rem);
    }

    .product-cards-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .product-cards-grid[data-card-count="2"],
    .product-cards-grid[data-card-count="3"] {
        grid-template-columns: 1fr;
    }

    .product-cards-card {
        border-radius: 20px;
    }

    .product-cards-image {
        min-height: 220px;
        padding: 6px 14px 0;
    }

    .product-cards-image img {
        max-width: 80%;
        max-height: 240px;
        transform: scale(1);
    }

    .product-cards-footer {
        margin-top: -60px;
        padding: 20px 18px 18px;
        border-top-left-radius: 18px;
        border-top-right-radius: 18px;
    }

    .product-cards-title {
        font-size: 1.35rem;
        margin-bottom: 8px;
    }

    .product-cards-subtitle {
        font-size: 16px;
        margin-bottom: 8px;
    }

    .product-cards-description {
        font-size: 0.92rem;
        margin-bottom: 12px;
    }

    .product-cards-tags {
        gap: 6px;
        margin-bottom: 14px;
    }

    .product-cards-tag {
        min-height: 28px;
        padding: 0 10px;
        font-size: 0.78rem;
    }
}
