body {
    background:
        radial-gradient(circle at top left, rgba(96, 165, 250, 0.14), transparent 34%),
        linear-gradient(180deg, #fef9f0 0%, #f5f2ec 100%);
}

.payment-shell {
    padding-top: 0px;
}

.payment-hero {
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, #08162b 0%, #0f2551 58%, #183b78 100%);
    padding: 80px 5% 46px;
}

.payment-bg,
.payment-grid {
    position: absolute;
    inset: 0;
    pointer-events: none;
}

.payment-grid {
    background-image: linear-gradient(rgba(255, 255, 255, .04) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, .04) 1px, transparent 1px);
    background-size: 26px 26px;
    mask-image: linear-gradient(180deg, rgba(0, 0, 0, .95), transparent);
}

.payment-hero-in {
    position: relative;
    z-index: 1;
}

.payment-copy {
    max-width: 760px;
    color: #fff;
}

.payment-copy h1 {
    font-family: 'Fraunces', serif;
    font-size: clamp(2.2rem, 5vw, 4.5rem);
    line-height: 1.06;
    letter-spacing: -.03em;
}

.payment-copy h1 em {
    font-style: italic;
    color: var(--gold);
}

.hero-lead {
    margin-top: 16px;
    max-width: 600px;
    color: rgba(255, 255, 255, .72);
    font-size: 1.03rem;
    line-height: 1.7;
}

.hero-points {
    margin-top: 24px;
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.hero-pill {
    padding: 11px 16px;
    border-radius: 999px;
    background: rgba(255, 255, 255, .1);
    border: 1px solid rgba(255, 255, 255, .16);
    color: #fff;
    font-size: .9rem;
    font-weight: 700;
}

.checkout-section {
    padding: 40px 5% 88px;
}

.checkout-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(320px, .85fr);
    gap: 28px;
    align-items: start;
}

.checkout-card,
.summary-card {
    background: rgba(255, 255, 255, .88);
    backdrop-filter: blur(14px);
    border: 1px solid rgba(226, 232, 240, .92);
    border-radius: 28px;
    box-shadow: 0 18px 45px rgba(11, 29, 56, .10);
}

.checkout-card {
    padding: 34px;
}

.summary-card {
    padding: 28px;
    position: sticky;
    top: 108px;
}

.section-head h2 {
    font-family: 'Fraunces', serif;
    font-size: clamp(1.7rem, 3vw, 2.2rem);
    line-height: 1.15;
    color: var(--navy);
}

.section-head p {
    margin-top: 8px;
    color: var(--slate);
    line-height: 1.65;
}

.mini-tag {
    display: inline-flex;
    margin-bottom: 12px;
    padding: 5px 12px;
    border-radius: 999px;
    background: rgba(37, 99, 235, .08);
    border: 1px solid rgba(37, 99, 235, .18);
    color: var(--blue);
    font-size: .74rem;
    font-weight: 800;
    letter-spacing: .05em;
    text-transform: uppercase;
}

#payment-form {
    margin-top: 26px;
}

.field-row {
    margin-bottom: 18px;
}

.two-up {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.field {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.field span {
    font-size: .9rem;
    font-weight: 700;
    color: var(--navy);
}

.field small {
    color: var(--slate);
    font-weight: 500;
}

.subjects-pills {
    display: flex;
    gap: 5px;
    margin-top: 8px;
}

.subject-pill {
    border: 1px solid rgba(15, 23, 42, 0.16);
    background: #fff;
    color: #1f2b3a;
    padding: 10px 14px;
    border-radius: 999px;
    font: inherit;
    font-weight: 600;
    cursor: pointer;
    transition: 0.2s ease;
}

.subject-pill:hover {
    transform: translateY(-1px);
    border-color: rgba(15, 23, 42, 0.28);
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.08);
}

.subject-pill.active {
    background: #1f2b3a;
    color: #fff;
    border-color: #1f2b3a;
}

.subject-pill.locked {
    background: #eef2f7;
    color: #5b6574;
    border-color: #d8dee8;
    cursor: default;
    box-shadow: none;
    transform: none;
}

#subjects.invalid+#subjects-help,
#subjects-help.error {
    color: #b42318;
}

.field input,
.field textarea,
.summary-chooser select {
    width: 100%;
    border-radius: 16px;
    border: 1.5px solid #dbe5f1;
    background: #fff;
    padding: 14px 15px;
    font: inherit;
    color: var(--ink);
    transition: border-color .2s ease, box-shadow .2s ease, transform .2s ease;
}

.field textarea {
    resize: vertical;
    min-height: 118px;
}

.field input:focus,
.field textarea:focus,
.summary-chooser select:focus {
    outline: none;
    border-color: rgba(234, 124, 30, .7);
    box-shadow: 0 0 0 4px rgba(245, 158, 11, .12);
}

.field input.invalid,
.field textarea.invalid {
    border-color: #dc2626;
    box-shadow: 0 0 0 4px rgba(220, 38, 38, .08);
}

.checkbox-field {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 0.98rem;
    line-height: 1.5;
}

.checkbox-field input[type="checkbox"] {
    margin-top: 3px;
    flex: 0 0 auto;
}

.checkbox-field a {
    font-weight: 600;
    text-decoration: underline;
}

.legal-check {
    padding: 12px 14px;
    border: 1px solid rgba(15, 23, 42, 0.12);
    border-radius: 14px;
    background: rgba(226, 134, 43, 0.9);
}

.compliance-note {
    margin-top: 8px;
    padding: 15px 16px;
    border-radius: 18px;
    background: linear-gradient(135deg, rgba(209, 250, 229, .55), rgba(255, 255, 255, .9));
    border: 1px solid rgba(5, 150, 105, .18);
    color: #065f46;
    line-height: 1.65;
}

.form-error {
    display: none;
    margin-top: 14px;
    color: #b91c1c;
    font-weight: 700;
}

.form-error.show {
    display: block;
}

.form-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    align-items: center;
    justify-content: space-between;
    margin-top: 22px;
}

.form-actions .btn {
    min-width: 220px;
}

.summary-plan {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: start;
    margin-top: 20px;
}

.summary-label {
    color: var(--slate);
    font-size: .82rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .04em;
}

#summary-plan-name {
    margin-top: 6px;
    font-size: 1.55rem;
    line-height: 1.15;
    color: var(--navy);
}

.summary-sub {
    margin-top: 8px;
    color: var(--slate);
    line-height: 1.6;
}

.summary-badge {
    padding: 9px 12px;
    border-radius: 999px;
    background: rgba(245, 158, 11, .12);
    color: #b45309;
    border: 1px solid rgba(245, 158, 11, .22);
    font-size: .77rem;
    font-weight: 800;
    white-space: nowrap;
}

.summary-price-wrap {
    margin-top: 22px;
    padding: 18px;
    border-radius: 22px;
    background: linear-gradient(180deg, rgba(11, 29, 56, .96), rgba(26, 58, 143, .94));
    color: #fff;
}

.summary-price-line {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 10px 0;
    font-size: .98rem;
}

.summary-price-line strong {
    font-size: 1.2rem;
}

.summary-price-line.muted {
    color: rgba(255, 255, 255, .74);
    border-top: 1px solid rgba(255, 255, 255, .12);
}

.summary-chooser {
    margin-top: 20px;
}

.summary-chooser label {
    display: block;
    margin-bottom: 8px;
    color: var(--navy);
    font-weight: 700;
}

.plan-includes {
    margin-top: 22px;
}

.plan-includes ul {
    margin-top: 12px;
    display: grid;
    gap: 10px;
    padding-left: 18px;
    color: var(--ink);
    line-height: 1.55;
}

.summary-footer {
    margin-top: 22px;
    padding-top: 18px;
    border-top: 1px solid var(--border);
    color: var(--slate);
}

.summary-footer a {
    margin-top: 6px;
    display: inline-block;
    color: var(--blue);
    font-weight: 800;
}
@media (max-width: 1250px){
    .subjects-pills{
        flex-wrap: wrap;
    }
}
@media (max-width: 980px) {
    .checkout-grid {
        grid-template-columns: 1fr;
    }

    .summary-card {
        position: static;
        top: auto;
    }
}

@media (max-width: 700px) {
    .payment-hero {
        padding-top: 64px;
    }

    .checkout-card,
    .summary-card {
        padding: 22px;
        border-radius: 22px;
    }

    .two-up {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    .summary-plan,
    .form-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .form-actions .btn {
        width: 100%;
        min-width: 0;
    }
}