/**
 * EZee Link Membership Pro - Subscription Frontend
 * Final audited component stylesheet.
 * Global typography, links and .btn visuals are owned by el-template.css.
 */

/* =========================================================
   Shared subscription container
   ========================================================= */
.el-subscription {
    width: min(900px, calc(100% - 28px));
    margin: 28px auto 60px;
    padding: 24px;
    border: 1px solid var(--border-color);
    border-radius: 10px;
    background: var(--surface-color);
    box-shadow: 0 6px 20px rgba(0, 0, 0, .07);
}

.el-subscription *,
.el-subscription *::before,
.el-subscription *::after,
.el-plans *,
.el-plans *::before,
.el-plans *::after {
    box-sizing: border-box;
}

.el-subscription__title {
    margin: 0 0 22px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border-color);
    color: var(--text-color);
}

.el-subscription__message {
    margin: -8px 0 24px;
    color: var(--muted-color);
}

.el-subscription__login,
.el-subscription__section {
    margin-bottom: 28px;
}

.el-subscription__login {
    padding: 16px 18px;
    border: 1px solid color-mix(in srgb,var(--theme-color) 12%,var(--border-color));
    border-radius: 7px;
    background: color-mix(in srgb,var(--surface-color) 95%,var(--theme-accent));
}

.el-subscription__section-title,
.el-detail__heading {
    margin: 0 0 18px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--border-color);
    color: var(--text-color);
}

.el-subscription__section + .el-subscription__section {
    padding-top: 24px;
    border-top: 1px solid var(--border-color);
}

.el-subscription__actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 26px;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
}

.el-subscription__actions--center {
    justify-content: center;
}

.el-subscription__submit {
    min-width: 190px;
}

.el-subscription__back {
    min-width: 110px;
}

.el-subscription__loader {
    width: auto;
    height: auto;
}

/* =========================================================
   Login prompt
   ========================================================= */
.el-login {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    text-align: left;
}

.el-login__text {
    margin: 0;
}

.el-login .el-login-trigger {
    min-width: 110px;
}

/* =========================================================
   Form fields
   ========================================================= */
.el-field {
    display: grid;
    grid-template-columns: minmax(190px, 30%) minmax(0, 1fr);
    gap: 10px 22px;
    align-items: center;
    margin-bottom: 16px;
}

.el-field__label-wrap,
.el-field__label {
    min-width: 0;
    font-weight: 600;
}

.el-field__control,
.el-field > .eb-form-control {
    min-width: 0;
}

.el-control,
.el-field__control input:not([type="checkbox"]):not([type="radio"]):not([type="file"]),
.el-field__control select,
.el-field__control textarea,
.el-payment__expiry select {
    width: 100%;
    min-height: 44px;
    padding: 9px 12px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    background: var(--surface-color);
    color: var(--text-color);
    font: inherit;
    line-height: 1.4;
    transition: border-color .18s ease, box-shadow .18s ease;
}

.el-field__control textarea {
    min-height: 120px;
    resize: vertical;
}

.el-control:focus,
.el-field__control input:focus,
.el-field__control select:focus,
.el-field__control textarea:focus,
.el-payment__expiry select:focus {
    border-color: var(--theme-accent);
    outline: 0;
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--theme-accent) 18%, transparent);
}

.el-control--file {
    padding: 8px;
}

.el-field--hidden {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    margin: -1px !important;
    padding: 0 !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

/* Semantic validation colours remain independent of branding. */
.el-field .required,
.el-subscription .required,
.el-subscription .star,
.el-subscription .invalid,
.el-subscription .error,
.el-subscription span.error,
.el-field__error,
.el-subscription .formError,
.el-subscription .formRed {
    color: #c62828;
}

.el-field__error,
.el-subscription .formError,
.el-subscription .formRed,
.el-subscription .text-error {
    font-size: .875rem;
    font-weight: 600;
}

.el-field__error {
    display: block;
    margin-top: 6px;
}

.el-subscription .required {
    padding-left: 5px;
}

.el-subscription .text-error {
    color: #b94a48;
}

.el-subscription .inline-display {
    display: inline;
}

.el-subscription .formError {
    z-index: 990;
}

.el-subscription .formErrorContent {
    font-size: .875rem;
}

.el-subscription .osm-invisible-to-visitors {
    position: absolute !important;
    left: -10000px !important;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden !important;
}

/* =========================================================
   Password utility
   ========================================================= */
.el-password {
    position: relative;
}

.el-password .el-control {
    padding-right: 46px;
}

.el-password__toggle {
    position: absolute;
    top: 50%;
    right: 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--muted-color);
    cursor: pointer;
    transform: translateY(-50%);
}

.el-password__toggle:hover,
.el-password__toggle:focus-visible {
    color: var(--theme-color);
}

.el-password__toggle:focus-visible {
    outline: 2px solid var(--theme-accent);
    outline-offset: 2px;
}

/* =========================================================
   Money, recurring terms and VAT
   ========================================================= */
.el-money {
    position: relative;
    min-width: 0;
}

.el-money__symbol {
    position: absolute;
    top: 50%;
    left: 12px;
    z-index: 1;
    transform: translateY(-50%);
    pointer-events: none;
}

.el-money .el-control {
    padding-left: 32px;
}

.el-field--total {
    font-weight: 700;
}

.el-recurring__terms {
    display: grid;
    grid-template-columns: minmax(160px, 32%) minmax(0, 1fr);
    gap: 24px;
    margin-bottom: 20px;
}

.el-recurring__label {
    font-weight: 600;
}

.el-recurring__group + .el-recurring__group {
    margin-top: 24px;
}

.el-vat {
    display: flex;
    align-items: stretch;
    width: 100%;
}

.el-vat__country {
    display: flex;
    align-items: center;
    padding: 0 12px;
    border: 1px solid var(--border-color);
    border-right: 0;
    border-radius: 4px 0 0 4px;
    background: var(--page-background);
    color: var(--muted-color);
}

.el-vat .el-control {
    border-radius: 0 4px 4px 0;
}

.el-vat .el-field__error {
    align-self: center;
    margin: 0 0 0 10px;
}

/* =========================================================
   Radio / choice fields
   ========================================================= */
.el-subscription .el-field.field-type-radio {
    align-items: center;
    margin-bottom: 20px;
}

.el-subscription .el-field.field-type-radio > .el-field__label-wrap {
    align-self: center;
}

.el-subscription .el-field.field-type-radio > .el-field__label-wrap label {
    display: inline-flex;
    align-items: baseline;
    gap: 4px;
    margin: 0;
    font-weight: 700;
    line-height: 1.35;
}

.el-subscription .el-field.field-type-radio fieldset.oms-radio-container {
    width: 100%;
    min-width: 0;
    margin: 0;
    padding: 0 18px;
    border: 1px solid var(--border-color);
    border-radius: 7px;
    background: var(--surface-color);
}

.el-subscription .el-field.field-type-radio fieldset.oms-radio-container > .clearfix {
    margin: 0;
    padding: 0;
}

.el-subscription .el-field.field-type-radio fieldset.oms-radio-container > .clearfix + .clearfix {
    border-top: 1px solid var(--border-color);
}

.el-subscription .el-field.field-type-radio fieldset.oms-radio-container > .clearfix > div {
    padding: 0;
}

.el-subscription .el-field.field-type-radio label.radio {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    width: 100%;
    margin: 0;
    padding: 12px 0;
    color: var(--text-color);
    font-weight: 400;
    line-height: 1.45;
    cursor: pointer;
}

.el-subscription .el-field.field-type-radio input[type="radio"] {
    flex: 0 0 auto;
    width: 17px;
    height: 17px;
    margin: 2px 0 0;
    accent-color: var(--theme-accent);
    cursor: pointer;
}

.el-subscription .el-field.field-type-radio label.radio:hover {
    color: var(--theme-color);
}

/* =========================================================
   Payment methods
   ========================================================= */
.el-payment {
    margin: 0;
}

.el-payment__label {
    margin-bottom: 12px;
    font-weight: 600;
}

.el-payment__options {
    display: grid;
    gap: 10px;
}

.el-payment__option {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    background: var(--surface-color);
    cursor: pointer;
    transition: border-color .18s ease, background-color .18s ease, box-shadow .18s ease;
}

.el-payment__option:hover {
    border-color: color-mix(in srgb,var(--theme-color) 22%,var(--border-color));
    background: color-mix(in srgb,var(--surface-color) 97%,var(--theme-accent));
}

.el-payment__option:has(.el-payment__radio:checked) {
    border-color: var(--theme-accent);
    background: color-mix(in srgb,var(--theme-accent) 7%,var(--surface-color));
    box-shadow: 0 0 0 2px color-mix(in srgb,var(--theme-accent) 12%,transparent);
}

.el-payment__radio {
    flex: 0 0 auto;
    accent-color: var(--theme-accent);
}

.el-payment__option-content {
    display: flex;
    align-items: center;
    min-width: 0;
}

.el-payment__icon {
    display: block;
    width: auto;
    max-width: 180px;
    max-height: 42px;
}

.el-payment__expiry {
    display: flex;
    align-items: center;
    gap: 8px;
}

.el-payment__gateway {
    min-height: 44px;
    padding: 11px 12px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    background: var(--surface-color);
}

/* =========================================================
   Consent
   ========================================================= */
.el-consent {
    margin: 18px 0 0;
    padding: 14px 16px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    background: var(--page-background);
}

.el-check {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    cursor: pointer;
}

.el-check__input {
    flex: 0 0 auto;
    margin-top: .25em;
    accent-color: var(--theme-accent);
}

.el-check__text {
    min-width: 0;
}

.el-consent__message {
    margin: 10px 0 0 26px;
}

/* =========================================================
   Subscription detail
   ========================================================= */
.el-detail {
    overflow: hidden;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background: var(--surface-color);
}

.el-detail__row {
    display: grid;
    grid-template-columns: minmax(170px, 38%) minmax(0, 1fr);
    gap: 18px;
    padding: 13px 16px;
    border-bottom: 1px solid var(--border-color);
}

.el-detail__row:last-child {
    border-bottom: 0;
}

.el-detail__label {
    color: var(--muted-color);
    font-weight: 600;
}

.el-detail__value {
    min-width: 0;
    overflow-wrap: anywhere;
    color: var(--text-color);
}

.el-detail__heading {
    margin: 28px 0 0;
    padding: 16px;
    background: var(--page-background);
}

.el-detail__message {
    padding: 14px 16px;
    border-bottom: 1px solid var(--border-color);
}

.el-detail__row--total {
    background: color-mix(in srgb, var(--theme-accent) 7%, var(--surface-color));
    font-weight: 700;
}

.el-status {
    display: inline-flex;
    align-items: center;
    padding: 4px 9px;
    border-radius: 999px;
    font-size: .82rem;
    font-weight: 700;
    line-height: 1.3;
}

.el-status--active {
    background: #e8f5e9;
    color: #1b5e20;
}

.el-status--pending {
    background: #fff8e1;
    color: #8a5a00;
}

.el-status--expired {
    background: #f1f3f4;
    color: #555d63;
}

.el-status--cancelled {
    background: #fdecea;
    color: #a32222;
}

/* =========================================================
   Complete / failure result pages
   ========================================================= */
.el-result__title {
    text-align: center;
}
.el-result__body {
    padding: 22px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background: var(--page-background);
	text-align: left;
}

.el-result__message {
    margin: 0;
}

.el-result--success .el-result__body {
    border-left: 4px solid #2e7d32;
}

.el-result--failure .el-result__body {
    border-left: 4px solid #c62828;
}

.el-result__reason {
    margin-top: 18px;
    padding-top: 18px;
    border-top: 1px solid var(--border-color);
    text-align: left;
}

.el-result__reason-label {
    display: block;
    margin-bottom: 6px;
}

.el-result__reason-text {
    margin: 0;
}

/* =========================================================
   Subscription plans
   ========================================================= */
.el-plans {
    width: min(1280px, calc(100% - 28px));
    margin: 24px auto 60px;
}

.el-plans [hidden] {
    display: none !important;
}

.el-plans__toggle {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    margin-bottom: 24px;
}

/* Region selector: a dedicated segmented control, not a generic CTA. */
.el-plans__toggle-button {
    min-width: 250px;
    min-height: 44px;
    padding: 10px 20px;
    border: 1px solid var(--theme-color);
    border-radius: 999px;
    background: var(--surface-color);
    color: var(--theme-color);
    font: inherit;
    font-size: .95rem;
    font-weight: 600;
    line-height: 1.35;
    cursor: pointer;
    transition: background-color .2s ease, color .2s ease, box-shadow .2s ease;
}

.el-plans__toggle-button:hover,
.el-plans__toggle-button:focus-visible {
    background: color-mix(in srgb,var(--theme-accent) 9%,var(--surface-color));
}

.el-plans__toggle-button:focus-visible {
    outline: 3px solid color-mix(in srgb,var(--theme-color) 28%,transparent);
    outline-offset: 2px;
}

.el-plans__toggle-button.is-active {
    background: var(--theme-color);
    color: var(--theme-on-color);
    box-shadow: 0 3px 8px rgba(0,0,0,.14);
}

/* Publication/category panel */
.el-plans__category {
    margin-bottom: 24px;
    padding: 20px;
    border: 1px solid var(--border-color);
    border-radius: 9px;
    background: var(--surface-color);
}

.el-plans__category-title {
    margin: 0 0 20px;
    padding: 0 0 10px;
    border-bottom: 1px solid var(--border-color);
    color: var(--text-color);
}

/* Four cards on wide screens, matching the supplied reference. */
.el-plans__grid {
    display: grid;
    grid-template-columns: repeat(4,minmax(0,1fr));
    gap: 14px;
}

.el-plan-card {
    min-width: 0;
    min-height: 265px;
    padding: 16px 14px 15px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    background: var(--surface-color);
    box-shadow: 0 2px 5px rgba(0,0,0,.06);
    transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease;
}

@media (hover:hover) {
    .el-plan-card:hover {
        border-color: color-mix(in srgb,var(--theme-color) 20%,var(--border-color));
        box-shadow: 0 5px 14px rgba(0,0,0,.09);
        transform: translateY(-1px);
    }
}

.el-plan-card__body {
    display: flex;
    flex-direction: column;
    min-height: 100%;
}

.el-plan-card__category {
    margin: 0 0 14px;
    color: var(--text-color);
}

.el-plan-card__title {
    margin: 0 0 10px;
    color: var(--text-color);
    font-family: var(--font-body);
    font-size: 1rem;
    font-weight: 700;
    line-height: 1.4;
}

.el-plan-card__price {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 9px;
    margin: 0 0 8px;
    line-height: 1.35;
}

.el-plan-card__price-old {
    color: #d71920;
    font-size: 1rem;
    font-weight: 600;
}

.el-plan-card__price-current {
    color: var(--text-color);
    font-size: 1rem;
    font-weight: 700;
}

.el-plan-card__saving {
    margin: 0 0 14px;
    color: #159a35;
    font-size: .95rem;
    font-weight: 700;
}

.el-plan-card__includes {
    margin: 3px 0 6px;
    color: var(--text-color);
    font-size: .95rem;
    font-weight: 700;
}

.el-plan-card__description {
    margin: 0 0 16px;
    padding: 7px 9px;
    border: 0;
    border-left: 4px solid #f0a000;
    border-radius: 4px;
    background: #edf7ef;
    color: var(--text-color);
    font-size: .88rem;
    line-height: 1.45;
}

.el-plan-card__description > :first-child {
    margin-top: 0;
}

.el-plan-card__description > :last-child {
    margin-bottom: 0;
}

.el-plan-card__action {
    align-self: center;
    min-width: 150px;
    margin-top: auto;
}

/* Overseas cards use the same visual language, without the category panel. */
.el-plans__grid--international .el-plan-card {
    min-height: 220px;
}

.el-plan-card--international .el-plan-card__category {
    margin-bottom: 12px;
}

/* =========================================================
   Responsive
   ========================================================= */
@media (max-width: 1000px) {
    .el-plans__grid {
        grid-template-columns: repeat(2,minmax(0,1fr));
    }
}

@media (max-width: 700px) {
    .el-subscription {
        width: calc(100% - 20px);
        margin: 18px auto 40px;
        padding: 18px 14px 20px;
        border-radius: 8px;
    }

    .el-subscription__title {
        margin-bottom: 22px;
    }

    .el-subscription__login {
        margin-bottom: 24px;
        padding: 14px;
    }

    .el-login {
        align-items: stretch;
        flex-direction: column;
        text-align: left;
    }

    .el-login .btn {
        width: 100%;
    }

    .el-field,
    .el-recurring__terms,
    .el-subscription .el-field.field-type-radio {
        grid-template-columns: 1fr;
        gap: 7px;
    }

    .el-subscription .el-field.field-type-radio {
        gap: 9px;
    }

    .el-subscription .el-field.field-type-radio > .el-field__label-wrap {
        align-self: auto;
    }

    .el-subscription .el-field.field-type-radio fieldset.oms-radio-container {
        padding-inline: 16px;
    }

    .el-subscription .el-field.field-type-radio label.radio {
        padding: 11px 0;
    }

    .el-subscription__actions {
        align-items: stretch;
        flex-direction: column-reverse;
    }

    .el-subscription__actions .btn {
        width: 100%;
        min-width: 0;
    }

    .el-vat {
        flex-wrap: wrap;
    }

    .el-vat__country {
        min-height: 44px;
    }

    .el-vat .el-field__error {
        width: 100%;
        margin: 7px 0 0;
    }

    .el-detail__row {
        grid-template-columns: 1fr;
        gap: 4px;
    }

    .el-plans {
        width: calc(100% - 20px);
        margin: 18px auto 40px;
    }

    .el-plans__toggle {
        flex-direction: column;
    }

    .el-plans__toggle-button {
        width: 100%;
        min-width: 0;
    }

    .el-plans__category {
        padding: 15px 12px;
    }

    .el-plans__grid {
        grid-template-columns: 1fr;
    }

    .el-plan-card__action {
        width: min(100%,180px);
        min-width: 0;
    }
}
/* =========================================================
   Offline payment / bank details
   ========================================================= */

.el-payment-bank-details {
    margin: 24px 0;
    overflow: hidden;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background: var(--surface-color);
}

.el-payment-bank-details__title {
    padding: 14px 16px;
    border-bottom: 1px solid var(--border-color);
    background: var(--page-background);
    font-weight: 700;
    color: var(--text-color);
}

.el-payment-bank {
    padding: 18px 16px;
    border-bottom: 1px solid var(--border-color);
}

.el-payment-bank:last-child {
    border-bottom: 0;
}

.el-payment-bank__name {
    margin-bottom: 12px;
    font-weight: 700;
    color: var(--text-color);
}

.el-payment-bank__row {
    display: grid;
    grid-template-columns: minmax(150px, 32%) minmax(0, 1fr);
    gap: 16px;
    padding: 6px 0;
}

.el-payment-bank__label {
    color: var(--muted-color);
    font-weight: 500;
}

.el-payment-bank__value {
    min-width: 0;
    color: var(--text-color);
    overflow-wrap: anywhere;
}

.el-payment-contact {
    margin-top: 24px;
    padding: 18px 20px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background: var(--page-background);
    line-height: 1.7;
}

.el-payment-contact a {
    overflow-wrap: anywhere;
}

@media (max-width: 600px) {
    .el-payment-bank-details {
        margin: 20px 0;
    }

    .el-payment-bank-details__title,
    .el-payment-bank {
        padding-left: 14px;
        padding-right: 14px;
    }

    .el-payment-bank__row {
        grid-template-columns: 1fr;
        gap: 2px;
        padding: 7px 0;
    }

    .el-payment-bank__label {
        font-size: .9rem;
    }

    .el-payment-contact {
        padding: 15px 14px;
    }
}