
.tr-plans-page,
.tr-subscription-page,
.tr-subscription-simple-card {
    --tr-navy: #0B315F;
    --tr-red: #EF334F;
    --tr-green: #2E8B3C;
    --tr-muted: #64748B;
    --tr-border: #E2E8F0;
    width: min(calc(100% - 28px), 1180px);
    margin: clamp(34px, 6vw, 74px) auto;
    color: #10233F;
}

.tr-plans-page *,
.tr-subscription-page *,
.tr-subscription-simple-card * {
    box-sizing: border-box;
}

.tr-subscription-hero {
    padding: clamp(30px, 5vw, 54px);
    border: 1px solid var(--tr-border);
    border-radius: 26px;
    background:
        radial-gradient(circle at 8% 88%, rgba(239, 51, 79, .10), transparent 24rem),
        linear-gradient(135deg, #fff, #f6f9fc);
    box-shadow: 0 18px 48px rgba(11, 49, 95, .07);
}

.tr-subscription-hero > span {
    color: var(--tr-red);
    font-weight: 900;
}

.tr-subscription-hero h1 {
    margin: 8px 0 10px;
    color: var(--tr-navy);
    font-size: clamp(34px, 5vw, 56px);
    line-height: 1.25;
}

.tr-subscription-hero p {
    margin: 0;
    color: var(--tr-muted);
}

.tr-plan-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 16px;
    margin-top: 22px;
}

.tr-plan-card,
.tr-payment-card,
.tr-payment-history,
.tr-current-subscription,
.tr-subscription-simple-card {
    border: 1px solid var(--tr-border);
    border-radius: 22px;
    background: #fff;
    box-shadow: 0 14px 38px rgba(11, 49, 95, .06);
}

.tr-plan-card {
    position: relative;
    display: flex;
    min-height: 430px;
    flex-direction: column;
    padding: 24px;
}

.tr-plan-card.is-featured {
    border: 2px solid var(--tr-red);
    transform: translateY(-6px);
}

.tr-plan-popular {
    position: absolute;
    top: 14px;
    left: 14px;
    padding: 5px 9px;
    border-radius: 999px;
    color: #fff;
    background: var(--tr-red);
    font-size: 11px;
    font-weight: 900;
}

.tr-plan-card h2 {
    margin: 0 0 16px;
    color: var(--tr-navy);
}

.tr-plan-price {
    display: flex;
    align-items: baseline;
    gap: 6px;
}

.tr-plan-price strong {
    color: var(--tr-red);
    font-size: 34px;
}

.tr-plan-price span {
    color: var(--tr-muted);
    font-size: 12px;
}

.tr-plan-card ul {
    display: grid;
    gap: 9px;
    margin: 22px 0;
    padding: 0;
    list-style: none;
}

.tr-plan-card li::before {
    content: "✓";
    margin-left: 7px;
    color: var(--tr-green);
    font-weight: 900;
}

.tr-plan-card > a,
.tr-plan-current {
    display: flex;
    min-height: 46px;
    align-items: center;
    justify-content: center;
    margin-top: auto;
    border-radius: 12px;
    color: #fff !important;
    background: var(--tr-navy);
    font-weight: 900;
    text-decoration: none !important;
}

.tr-plan-current {
    color: #166534 !important;
    background: #dcfce7;
}

.tr-current-subscription {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr)) auto;
    gap: 16px;
    align-items: center;
    margin-top: 18px;
    padding: 20px;
}

.tr-current-subscription > div {
    display: grid;
    gap: 3px;
}

.tr-current-subscription span {
    color: var(--tr-muted);
    font-size: 12px;
}

.tr-current-subscription strong {
    color: var(--tr-navy);
}

.tr-current-subscription > a {
    color: var(--tr-red);
    font-weight: 900;
}

.tr-subscription-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    gap: 18px;
    margin-top: 18px;
    align-items: start;
}

.tr-payment-card,
.tr-payment-history {
    padding: clamp(22px, 4vw, 34px);
}

.tr-payment-card h2,
.tr-payment-history h2 {
    margin-top: 0;
    color: var(--tr-navy);
}

.tr-payment-form {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 15px;
}

.tr-payment-form label {
    display: grid;
    gap: 7px;
}

.tr-payment-form label > span {
    color: var(--tr-navy);
    font-size: 14px;
    font-weight: 800;
}

.tr-payment-form input,
.tr-payment-form select,
.tr-payment-form textarea {
    width: 100%;
    min-height: 49px;
    margin: 0;
    padding: 10px 13px;
    border: 1px solid var(--tr-border);
    border-radius: 12px;
    font: inherit;
}

.tr-payment-full {
    grid-column: 1 / -1;
}

.tr-payment-upload {
    padding: 14px;
    border: 1px dashed #cbd5e1;
    border-radius: 14px;
    background: #f8fafc;
}

.tr-payment-upload small {
    color: var(--tr-muted);
}

.tr-payment-form button {
    grid-column: 1 / -1;
    min-height: 52px;
    border: 0;
    border-radius: 13px;
    color: #fff;
    background: var(--tr-navy);
    font: inherit;
    font-weight: 900;
    cursor: pointer;
}

.tr-payment-history {
    display: grid;
    gap: 10px;
}

.tr-payment-history-card {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 5px 10px;
    padding: 14px;
    border: 1px solid #eef2f7;
    border-radius: 14px;
}

.tr-payment-history-card > div {
    display: grid;
}

.tr-payment-history-card strong {
    color: var(--tr-navy);
}

.tr-payment-history-card span,
.tr-payment-history-card small {
    color: var(--tr-muted);
}

.tr-payment-status {
    font-size: 12px;
    font-weight: 800;
}

.tr-subscription-message,
.tr-form-preserved-notice {
    margin: 16px 0;
    padding: 14px 16px;
    border-radius: 12px;
    font-weight: 800;
}

.tr-subscription-message-success {
    color: #166534;
    border: 1px solid #bbf7d0;
    background: #f0fdf4;
}

.tr-subscription-message-error {
    color: #991b1b;
    border: 1px solid #fecaca;
    background: #fef2f2;
}

.tr-form-preserved-notice {
    color: #0b315f;
    border: 1px solid #bfdbfe;
    background: #eff6ff;
}

.tr-subscription-simple-card {
    max-width: 650px;
    padding: 36px;
    text-align: center;
}

.tr-subscription-simple-card h2 {
    margin-top: 0;
    color: var(--tr-navy);
}

.tr-subscription-simple-card p {
    color: var(--tr-muted);
}

.tr-subscription-simple-card a {
    display: inline-flex;
    min-height: 46px;
    align-items: center;
    padding: 9px 16px;
    border-radius: 11px;
    color: #fff !important;
    background: var(--tr-navy);
    font-weight: 900;
    text-decoration: none !important;
}

.tr-product-subscription-banner {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 18px;
    align-items: center;
    margin: 16px 0;
    padding: 15px 18px;
    border: 1px solid #bfdbfe;
    border-radius: 14px;
    color: #0b315f;
    background: #eff6ff;
}

.tr-product-subscription-banner a {
    margin-right: auto;
    font-weight: 900;
}

@media (max-width: 1050px) {
    .tr-plan-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .tr-subscription-layout {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 680px) {
    .tr-plan-grid,
    .tr-payment-form,
    .tr-current-subscription {
        grid-template-columns: 1fr;
    }

    .tr-plan-card.is-featured {
        transform: none;
    }

    .tr-payment-full {
        grid-column: auto;
    }
}
