/* ==========================================================================
   Cards — product cards, category cards, guide cards, feature cards.
   ========================================================================== */

/* --- Product card --- */

.product-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: 26px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.product-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 18px 38px rgba(17, 24, 39, 0.12);
}

.product-image {
    aspect-ratio: 1.2 / 1;
    background: linear-gradient(135deg, #91a3ff, #a365e4);
    position: relative;
    overflow: hidden;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Gradient placeholders for cards without images */
.product-image.g1 { background: linear-gradient(135deg, #91a3ff, #a365e4); }
.product-image.g2 { background: linear-gradient(135deg, #7bc8ff, #6d7cff); }
.product-image.g3 { background: linear-gradient(135deg, #ffb347, #e4658a); }
.product-image.g4 { background: linear-gradient(135deg, #6de4b3, #6d9cff); }
.product-image.g5 { background: linear-gradient(135deg, #ff7eb3, #a365e4); }
.product-image.g6 { background: linear-gradient(135deg, #ffe47e, #ff9147); }
.product-image.g7 { background: linear-gradient(135deg, #7effc8, #6d7cff); }
.product-image.g8 { background: linear-gradient(135deg, #b3a3ff, #e465c8); }
.product-image.g9 { background: linear-gradient(135deg, #ff9a7e, #ffcc47); }

.badge {
    position: absolute;
    top: 16px;
    left: 16px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(255, 255, 255, 0.88);
    color: var(--text);
    padding: 8px 12px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
}

.badge-new {
    position: absolute;
    top: 16px;
    right: 16px;
    background: #22c55e;
    color: var(--white);
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 700;
}

.product-body {
    padding: 20px;
}

.product-title {
    font-size: 21px;
    line-height: 1.2;
    margin-bottom: 10px;
    font-weight: 700;
    color: var(--dark);
}

.card-rating {
    display: inline-flex;
    align-items: center;
    gap: 2px;
    font-size: 12px;
    color: #f59e0b;
}

.card-rating .bi-star {
    color: #d1d5db;
}

.card-rating-text {
    font-size: 12px;
    color: var(--muted);
    margin-left: 4px;
    font-weight: 600;
}

.product-meta {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    font-size: 14px;
    color: var(--muted);
    margin-bottom: 16px;
}

.creator-link {
    color: var(--secondary);
    font-weight: 600;
}

.price-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.price {
    font-size: 22px;
    font-weight: 800;
    color: var(--dark);
}

/* --- Category card --- */

.category-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 24px 18px;
    text-align: center;
    box-shadow: var(--shadow);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    display: block;
}

.category-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 18px 38px rgba(17, 24, 39, 0.12);
    color: var(--text);
}

.category-icon {
    width: 62px;
    height: 62px;
    margin: 0 auto 14px;
    border-radius: 20px;
    display: grid;
    place-items: center;
    font-size: 26px;
    background: linear-gradient(135deg, rgba(109, 124, 255, 0.12), rgba(138, 75, 214, 0.16));
}

.category-card h3 {
    font-size: 18px;
    margin-bottom: 6px;
}

.category-card p {
    font-size: 14px;
    color: var(--text);
    margin-bottom: 0;
}

/* --- Feature card (how it works, icon boxes) --- */

.feature-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: 26px;
    padding: 28px;
    box-shadow: var(--shadow);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.feature-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 18px 38px rgba(17, 24, 39, 0.12);
}

.feature-card .step {
    display: inline-flex;
    width: 54px;
    height: 54px;
    border-radius: 18px;
    align-items: center;
    justify-content: center;
    margin-bottom: 18px;
    background: linear-gradient(135deg, rgba(109, 124, 255, 0.14), rgba(138, 75, 214, 0.18));
    font-weight: 800;
    color: var(--secondary);
}

.feature-card h3 {
    font-size: 22px;
    margin-bottom: 10px;
}

.feature-card p {
    color: var(--text);
    margin-bottom: 0;
}

/* --- Guide card --- */

.guide-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 28px;
    box-shadow: var(--shadow);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.guide-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 18px 38px rgba(17, 24, 39, 0.12);
}

.guide-icon {
    width: 54px;
    height: 54px;
    border-radius: 18px;
    display: grid;
    place-items: center;
    margin-bottom: 18px;
    background: linear-gradient(135deg, rgba(109, 124, 255, 0.12), rgba(138, 75, 214, 0.16));
    font-size: 22px;
}

.guide-card h3 {
    font-size: 22px;
    margin-bottom: 10px;
}

.guide-card p {
    color: var(--text);
    margin-bottom: 18px;
}

.guide-link {
    color: var(--secondary);
    font-weight: 700;
}

/* --- LB Build Card (template-parts/build-card.php) --- */

.lb-build-card .build-thumb {
    position: relative;
    overflow: hidden;
}

.lb-build-card .build-cat {
    position: absolute;
    top: 16px;
    left: 16px;
    background: rgba(255, 255, 255, 0.88);
    color: var(--text);
    padding: 8px 12px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
}

.lb-build-card .platform-badge {
    font-size: 13px;
    color: var(--muted);
    font-weight: 600;
}

/* --- Icon box (icon-left variant) --- */

.icon-box--left {
    display: flex;
    gap: 18px;
    align-items: flex-start;
}

.icon-box--left .feature-card .step {
    flex-shrink: 0;
    margin-bottom: 0;
}
