/*
 * Plan grid (resources/views/pricing_table.blade.php), page-scoped with a pg- prefix. Loaded by the
 * partial itself, so every page that includes it gets these styles.
 * Same visual language as demo-launch-20260925.css: brand #4a63e7 (hover #3d55d6), dark text
 * #2a2f45, muted #646c9a, borders #e3e6f0, 14px card radius. Button and link blues pass 4.5:1
 * against white.
 */

.pg {
    color: #595d6e;
    font-size: 15px;
    line-height: 1.5;
}

.pg-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px 24px;
    margin-bottom: 30px;
}

.pg-lead {
    margin: 0;
    color: #2a2f45;
    font-weight: 500;
}

/* Billing toggle: two pressed/unpressed buttons in a pill. */
.pg-billing {
    display: inline-flex;
    gap: 4px;
    padding: 4px;
    background: #e6e8f2;
    border-radius: 999px;
}

.pg-billing__btn {
    min-height: 36px;
    padding: 0 16px;
    border: 0;
    border-radius: 999px;
    background: transparent;
    color: #595d6e;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.15s ease, color 0.15s ease;
}

.pg-billing__btn--on {
    background: #ffffff;
    color: #2a2f45;
    box-shadow: 0 1px 3px rgba(42, 47, 69, 0.15);
}

/*
 * Cards: as many columns as the container fits, so the grid adapts to the container rather than
 * the viewport (inside the backend layout the portlet sits beside the 265px aside). The 22%
 * floor caps a wide container at four columns, one per card; a card is never narrower than
 * 230px, so a narrow container gets three or two columns, and phones get one.
 */
.pg-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(max(230px, 22%), 1fr));
    gap: 28px 20px;
    padding-top: 12px;
}

@media (max-width: 767.98px) {
    .pg-cards {
        grid-template-columns: minmax(0, 1fr);
        gap: 18px;
    }
}

.pg-card {
    position: relative;
    box-sizing: border-box;
    padding: 26px 22px 22px;
    background: #ffffff;
    border: 2px solid #e3e6f0;
    border-radius: 14px;
    box-shadow: 0 1px 2px rgba(42, 47, 69, 0.05);
}

.pg-card--recommended {
    border-color: #4a63e7;
    box-shadow: 0 18px 40px rgba(61, 85, 214, 0.16);
}

.pg-card--current {
    border-color: #2a2f45;
}

.pg-badge {
    position: absolute;
    top: -14px;
    left: 20px;
    padding: 4px 12px;
    border-radius: 999px;
    color: #ffffff;
    font-size: 12px;
    font-weight: 600;
    white-space: nowrap;
}

.pg-badge--recommended {
    background: #4a63e7;
}

.pg-badge--current,
.pg-badge--popular {
    background: #2a2f45;
}

.pg-card__name {
    display: block;
    margin: 0;
    color: #2a2f45;
    font-size: 20px;
    font-weight: 600;
    line-height: 1.3;
}

.pg-card__range {
    display: block;
    margin: 2px 0 0;
    color: #646c9a;
    font-size: 13px;
}

/* The title is a plain heading on wide screens and a fold button on narrow ones. */
.pg-card__toggle {
    display: none;
    width: 100%;
    align-items: center;
    gap: 12px;
    padding: 0;
    border: 0;
    background: transparent;
    color: #2a2f45;
    text-align: left;
    cursor: pointer;
}

.pg-card__toggle-text {
    flex-grow: 1;
    min-width: 0;
}

.pg-card__from {
    flex-shrink: 0;
    color: #646c9a;
    font-size: 13px;
}

.pg-card__from strong {
    color: #2a2f45;
    font-size: 16px;
    font-weight: 700;
}

.pg-card__chevron {
    flex-shrink: 0;
    color: #646c9a;
    transition: transform 0.15s ease;
}

.pg-card--open .pg-card__chevron {
    transform: rotate(180deg);
}

@media (max-width: 767.98px) {
    .pg-card {
        padding: 18px 16px 16px;
    }

    .pg-card__head {
        display: none;
    }

    .pg-card__toggle {
        display: flex;
    }

    .pg-card__body {
        display: none;
    }

    .pg-card--open .pg-card__body {
        display: block;
    }
}

.pg-price {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 16px;
}

.pg-price__amount {
    color: #2a2f45;
    font-size: 40px;
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.1;
}

.pg-price__unit {
    color: #646c9a;
    font-size: 15px;
}

.pg-price__note {
    margin: 4px 0 0;
    color: #646c9a;
    font-size: 13px;
}

.pg-label {
    margin: 18px 0 8px;
    color: #646c9a;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.pg-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.pg-pill {
    flex: 1 1 56px;
    min-height: 44px;
    padding: 0 4px;
    border: 1.5px solid #e3e6f0;
    border-radius: 10px;
    background: #ffffff;
    color: #2a2f45;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: border-color 0.15s ease, background-color 0.15s ease, color 0.15s ease;
}

.pg-pill:hover {
    border-color: #b9c2ff;
}

.pg-pill--on {
    border-color: #4a63e7;
    background: #eef1ff;
    color: #3d55d6;
}

.pg-guide {
    margin: 10px 0 0;
    color: #595d6e;
    font-size: 13px;
    line-height: 1.5;
}

.pg-card__cta {
    margin-top: 18px;
}

/* Buttons: one class per weight, toggled by Alpine when the billing period changes. */
.pg-btn,
.pg-btn:visited {
    display: flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    width: 100%;
    min-height: 48px;
    padding: 0 16px;
    border: 1.5px solid transparent;
    border-radius: 10px;
    font-size: 15px;
    font-weight: 600;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.pg-btn:hover,
.pg-btn:focus {
    text-decoration: none;
}

.pg-btn--primary,
.pg-btn--primary:visited {
    background: #4a63e7;
    border-color: #4a63e7;
    color: #ffffff;
}

.pg-btn--primary:hover,
.pg-btn--primary:focus {
    background: #3d55d6;
    border-color: #3d55d6;
    color: #ffffff;
}

.pg-btn--outline,
.pg-btn--outline:visited {
    background: #ffffff;
    border-color: #c3cbf7;
    color: #3d55d6;
}

.pg-btn--outline:hover,
.pg-btn--outline:focus {
    border-color: #4a63e7;
    background: #f4f6ff;
    color: #3d55d6;
}

.pg-btn--muted {
    background: #f1f2f7;
    border-color: #f1f2f7;
    color: #646c9a;
    cursor: default;
}

/* Metronic's warning yellow, with dark text: white on #ffb822 does not pass 4.5:1. */
.pg-btn--warning,
.pg-btn--warning:visited {
    background: #ffb822;
    border-color: #ffb822;
    color: #2a2f45;
}

.pg-btn--warning:hover,
.pg-btn--warning:focus {
    background: #f2a900;
    border-color: #f2a900;
    color: #2a2f45;
}

/* Volume row under the cards */
.pg-volume {
    position: relative;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 18px 28px;
    margin-top: 24px;
    padding: 18px 22px;
    background: #ffffff;
    border: 2px solid #e3e6f0;
    border-radius: 14px;
}

.pg-volume--recommended {
    border-color: #4a63e7;
}

.pg-volume__text {
    flex: 1 1 260px;
}

.pg-volume__title {
    margin: 0;
    color: #2a2f45;
    font-size: 16px;
    font-weight: 600;
}

.pg-volume__sub {
    margin: 2px 0 0;
    color: #646c9a;
    font-size: 13px;
}

.pg-volume__sub a {
    color: #3d55d6;
    font-weight: 600;
}

.pg-volume__pills {
    flex: 0 1 auto;
}

.pg-volume__pills .pg-pill {
    flex: 0 0 auto;
    min-width: 86px;
    padding: 0 10px;
}

.pg-volume__price {
    min-width: 160px;
    text-align: right;
}

.pg-volume__amount {
    color: #2a2f45;
    font-size: 24px;
    font-weight: 700;
}

.pg-volume__unit {
    color: #646c9a;
    font-size: 14px;
}

.pg-volume__per {
    color: #646c9a;
    font-size: 12px;
}

.pg-volume__cta {
    flex: 0 0 auto;
}

.pg-volume__cta .pg-btn {
    width: auto;
    min-width: 120px;
    padding: 0 20px;
}

@media (max-width: 767.98px) {
    .pg-volume {
        padding: 18px 16px 16px;
    }

    .pg-volume__pills {
        flex: 1 1 100%;
        flex-wrap: wrap;
    }

    .pg-volume__pills .pg-pill {
        flex: 1 1 40%;
        min-width: 0;
    }

    .pg-volume__price {
        flex: 1 1 auto;
        text-align: left;
    }

    .pg-volume__cta,
    .pg-volume__cta .pg-btn {
        width: 100%;
    }
}

/*
 * Public pricing page (resources/views/pricing.blade.php): hero, free test card, "included"
 * feature list. Same prefix so the page needs no stylesheet of its own.
 */
.pg-hero {
    max-width: 760px;
    margin: 24px auto 40px;
    text-align: center;
}

.pg-hero__eyebrow {
    display: block;
    margin-bottom: 12px;
    color: #3d55d6;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.pg-hero__title {
    margin: 0;
    color: #2a2f45;
    font-size: 38px;
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.15;
}

.pg-hero__text {
    margin: 16px 0 0;
    color: #595d6e;
    font-size: 17px;
    line-height: 1.6;
}

.pg-hero__points {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    margin: 20px 0 0;
    padding: 0;
    list-style: none;
}

.pg-hero__points li {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    border-radius: 999px;
    background: #f1f4ff;
    color: #2a2f45;
    font-size: 14px;
    font-weight: 500;
}

.pg-hero__points svg {
    color: #3d55d6;
}

@media (max-width: 767.98px) {
    .pg-hero__title {
        font-size: 28px;
    }

    .pg-hero__text {
        font-size: 15px;
    }
}

.pg-test {
    display: flex;
    align-items: center;
    gap: 24px;
    margin-bottom: 36px;
    padding: 22px 26px;
    background: #ffffff;
    border: 1.5px dashed #c3cbf7;
    border-radius: 14px;
}

.pg-test__icon {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 52px;
    height: 52px;
    border-radius: 12px;
    background: #eaf7f0;
    color: #0b6446;
}

.pg-test__text {
    flex: 1 1 0;
}

.pg-test__title {
    margin: 0;
    color: #2a2f45;
    font-size: 19px;
    font-weight: 600;
}

.pg-test__desc {
    margin: 4px 0 0;
    color: #595d6e;
    font-size: 14px;
    line-height: 1.5;
}

.pg-test .pg-btn {
    flex-shrink: 0;
    width: auto;
    padding: 0 24px;
}

@media (max-width: 767.98px) {
    .pg-test {
        flex-wrap: wrap;
        padding: 18px 16px;
    }

    .pg-test__icon {
        display: none;
    }

    .pg-test .pg-btn {
        width: 100%;
    }
}

.pg-included {
    margin-top: 56px;
}

.pg-section-title {
    margin: 0 0 24px;
    color: #2a2f45;
    font-size: 28px;
    font-weight: 700;
    letter-spacing: -0.01em;
    text-align: center;
}

.pg-features {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
    margin: 0;
    padding: 0;
    list-style: none;
}

@media (max-width: 991.98px) {
    .pg-features {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 575.98px) {
    .pg-features {
        grid-template-columns: minmax(0, 1fr);
    }
}

.pg-feature {
    padding: 20px;
    background: #f7f8fc;
    border-radius: 12px;
}

.pg-feature svg {
    color: #3d55d6;
}

.pg-feature__title {
    margin: 8px 0 4px;
    color: #2a2f45;
    font-size: 15px;
    font-weight: 600;
}

.pg-feature__text {
    margin: 0;
    color: #646c9a;
    font-size: 14px;
    line-height: 1.5;
}

/* Subscription page: usage banner under the status row and the yearly line under the grid. */
.pg-usage {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-top: 24px;
    padding: 18px 22px;
    background: #fff6ea;
    border: 1px solid #f6d6a8;
    border-radius: 12px;
}

.pg-usage svg {
    flex-shrink: 0;
    color: #a14f05;
}

.pg-usage__text {
    flex: 1 1 0;
}

.pg-usage__title {
    margin: 0;
    color: #2a2f45;
    font-size: 15px;
    font-weight: 600;
}

.pg-usage__sub {
    margin: 2px 0 0;
    color: #595d6e;
    font-size: 14px;
}

.pg-usage .pg-btn {
    flex-shrink: 0;
    width: auto;
    padding: 0 22px;
}

@media (max-width: 767.98px) {
    .pg-usage {
        flex-wrap: wrap;
    }

    .pg-usage .pg-btn {
        width: 100%;
    }
}

.pg-yearly {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 8px 24px;
    margin-top: 20px;
    padding: 14px 20px;
    background: #eaf7f0;
    border-radius: 12px;
    color: #0b5238;
    font-size: 14px;
}

.pg-yearly p {
    margin: 0;
}

.pg-yearly .pg-btn,
.pg-yearly .pg-btn:visited {
    width: auto;
    min-height: 40px;
    padding: 0 18px;
    background: #ffffff;
    border-color: #9ed9bc;
    color: #0b5238;
    font-size: 14px;
    white-space: nowrap;
}

.pg-yearly .pg-btn:hover,
.pg-yearly .pg-btn:focus {
    background: #f3fbf7;
    border-color: #0b8a5f;
    color: #0b5238;
}

@media (max-width: 767.98px) {
    .pg-yearly .pg-btn {
        width: 100%;
    }
}

/* Top-up modal (components/top-up-credits-modal), opened from the subscription page. */
.pg-topup__lead {
    margin: 0 0 20px;
    color: #595d6e;
    font-size: 14px;
    line-height: 1.6;
}

.pg-topup__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(max(200px, 30%), 1fr));
    gap: 16px;
}

.pg-topup__card,
.pg-topup__card:visited {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 22px 20px 20px;
    background: #ffffff;
    border: 2px solid #e3e6f0;
    border-radius: 14px;
    color: #595d6e;
    text-decoration: none;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.pg-topup__card:hover,
.pg-topup__card:focus {
    border-color: #4a63e7;
    box-shadow: 0 12px 28px rgba(61, 85, 214, 0.12);
    color: #595d6e;
    text-decoration: none;
}

.pg-topup__card:hover .pg-btn--outline,
.pg-topup__card:focus .pg-btn--outline {
    border-color: #4a63e7;
    background: #f4f6ff;
}

.pg-topup__searches {
    color: #2a2f45;
    font-size: 22px;
    font-weight: 600;
    line-height: 1.3;
}

.pg-topup__searches small {
    color: #646c9a;
    font-size: 14px;
    font-weight: 500;
}

.pg-topup__price {
    margin-top: 10px;
    color: #2a2f45;
    font-size: 32px;
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.1;
}

.pg-topup__per {
    color: #646c9a;
    font-size: 13px;
}

.pg-topup__note {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin: 12px 0 16px;
    color: #0b6446;
    font-size: 13px;
    font-weight: 500;
}

.pg-topup__foot {
    margin: 20px 0 0;
    color: #646c9a;
    font-size: 13px;
}

.pg-topup__foot a {
    color: #3d55d6;
    font-weight: 600;
}
