:root {
    /* Shared design tokens; cards render outside the browser shell too. */
    --blpb-border: #e2e7eb;
    --blpb-surface: #ffffff;
    --blpb-tint: #f6f7f8;
    --blpb-muted: #66747f;
    --blpb-text: #243746;
    --blpb-accent: #b32533;
    --blpb-accent-deep: #77001c;
    --blpb-accent-soft: #faeef0;
    --blpb-focus: #1c5fd4;
}

/* Visually hidden helper; defined here because every consuming surface
   (browser shell, related module) relies on it. */
.blpb-sr-only {
    border: 0;
    clip: rect(0, 0, 0, 0);
    height: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute;
    white-space: nowrap;
    width: 1px;
}

/* Reusable plan-card module; layout grids belong to the consuming surface. */
.blpb-plan-card {
    background: var(--blpb-surface);
    border: 1px solid var(--blpb-border);
    border-radius: 14px;
    min-width: 0;
    overflow: hidden;
    transition: box-shadow 0.18s ease, transform 0.18s ease, border-color 0.18s ease;
}

/* The whole card lifts as one piece. The image itself never scales, so there
   is no competing second motion. */
.blpb-plan-card:hover {
    border-color: #cfd7dd;
    box-shadow: 0 10px 28px rgba(26, 36, 44, 0.13);
    transform: translateY(-2px);
}

@media (prefers-reduced-motion: reduce) {
    .blpb-plan-card,
    .blpb-plan-card:hover {
        transform: none;
        transition: none;
    }
}

/* Tripled-up selector outranks the theme's
   `.entry-content a:not(.wp-block-button__link)` link styling (0,2,1). */
.blpb-plan-card .blpb-plan-card__link.blpb-plan-card__link,
.blpb-plan-card .blpb-plan-card__link.blpb-plan-card__link:hover,
.blpb-plan-card .blpb-plan-card__link.blpb-plan-card__link:focus {
    border-bottom: 0;
    box-shadow: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    height: 100%;
    text-decoration: none;
}

.blpb-plan-card__link:focus-visible {
    outline: 3px solid var(--blpb-focus);
    outline-offset: 3px;
}

.blpb-plan-card__media {
    aspect-ratio: 4 / 3;
    background: #eef1f3;
    display: block;
    overflow: hidden;
    position: relative;
}

.blpb-plan-card__media img,
.blpb-plan-card__media-placeholder {
    display: block;
    height: 100%;
    width: 100%;
}

.blpb-plan-card__media img {
    object-fit: cover;
}

.blpb-plan-card__media-placeholder {
    background: linear-gradient(135deg, #eef1f3 0%, #e3e8ec 100%);
}

/* Plan code rides on the photo (top corner; many source photos carry their
   own caption strip along the bottom edge). */
.blpb-plan-card__code {
    background: rgba(255, 255, 255, 0.93);
    border-radius: 6px;
    color: var(--blpb-accent-deep);
    font-size: 12px;
    font-weight: 800;
    left: 10px;
    letter-spacing: 0.04em;
    line-height: 1;
    padding: 6px 8px;
    position: absolute;
    top: 10px;
}

.blpb-plan-card__body {
    display: flex;
    flex: 1;
    flex-direction: column;
    gap: 8px;
    padding: 14px 16px 14px;
}

.blpb-plan-card__title {
    color: var(--blpb-text);
    display: -webkit-box;
    font-size: 16px;
    font-weight: 700;
    line-height: 1.3;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.blpb-plan-card__meta {
    align-items: center;
    color: var(--blpb-muted);
    display: flex;
    flex-wrap: wrap;
    font-size: 13px;
    font-weight: 500;
    gap: 4px 8px;
    line-height: 1.35;
}

.blpb-plan-card__meta-dot {
    background: #c2ccd3;
    border-radius: 999px;
    display: inline-block;
    height: 3px;
    width: 3px;
}

.blpb-plan-card__features {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.blpb-plan-card__feature {
    background: var(--blpb-tint);
    border-radius: 999px;
    color: #50616d;
    font-size: 12px;
    font-weight: 600;
    line-height: 1.2;
    padding: 4px 9px;
}

.blpb-plan-card__footer {
    align-items: center;
    border-top: 1px solid var(--blpb-border);
    display: flex;
    gap: 8px;
    justify-content: space-between;
    margin-top: auto;
    padding-top: 11px;
}

.blpb-plan-card__price {
    color: var(--blpb-text);
    font-size: 15px;
    font-weight: 800;
}

.blpb-plan-card__cta {
    color: var(--blpb-accent);
    font-size: 13px;
    font-weight: 700;
    margin-left: auto;
    white-space: nowrap;
}

.blpb-plan-card:hover .blpb-plan-card__cta {
    text-decoration: underline;
    text-underline-offset: 2px;
}
