/*
 * create_account_layout.css
 * UP Faith & Family – Create Account (Step 1 of 2) layout.
 * Self-contained: does not depend on bootstrap.min.css loading, and is scoped/specific
 * enough to win over Bootstrap and create_account.css when they do load.
 */
:root {
    --ck-cream: #fff9e5;
    --ck-orange: #F9971F;
    --ck-orange-hover: #e7850c;
    --ck-line: #f0b273;
    --ck-blue: #20a0c4;
    --ck-ink: #444444;
    --ck-field-border: #d5d5d5;
    --ck-placeholder: #9a9a9a;
    --ck-error: #dc3545;
    --ck-font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

html { background: var(--ck-cream); }
body.body-upfaithandfamily {
    margin: 0;
    background: var(--ck-cream);
    color: var(--ck-ink);
    font-family: var(--ck-font);
    font-size: 16px;
    line-height: 1.5;
    -webkit-text-size-adjust: 100%;
}
.ck-page, .ck-page *, .ck-page *::before, .ck-page *::after { box-sizing: border-box; }
.ck-page [hidden] { display: none !important; }

.ck-page {
    width: 100%;
    max-width: 1140px;
    margin: 0 auto;
    padding: 0 16px;
}

/* ---------- Top bar ---------- */
.ck-page header.ck-topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: 0;
    padding: 24px 32px 0;
    border-bottom: none;
}
.ck-logo { display: block; width: 112px; height: auto; }
.ck-login {
    color: var(--ck-blue);
    font-size: 15px;
    text-decoration: none;
}
.ck-login:hover, .ck-login:focus-visible { text-decoration: underline; }

/* ---------- Intro ---------- */
.ck-intro { text-align: center; margin: 40px auto 32px; }
.ck-page .ck-step {
    margin: 0 0 8px;
    font-family: var(--ck-font);
    font-size: 34px;
    font-weight: 400;
    line-height: 1.2;
    color: var(--ck-ink);
}
.ck-page .ck-trial-note {
    margin: 0;
    font-size: 20px;
    color: var(--ck-blue);
}

/* ---------- Card ---------- */
.ck-card {
    display: flex;
    max-width: 836px;
    margin: 0 auto;
    background: #fff;
    border: 1px solid var(--ck-line);
    border-radius: 16px;
    overflow: hidden;
}
.ck-plan-col { flex: 0 0 46%; border-right: 1px solid var(--ck-line); }
.ck-form-col { flex: 1 1 54%; min-width: 0; }

/* ---------- Plan panel ---------- */
.ck-plan { padding: 78px 24px 32px; }

.ck-toggle {
    display: flex;
    border: 1px solid var(--ck-orange);
    border-radius: 5px;
    overflow: hidden;
}
.ck-radio {
    position: absolute;
    width: 1px; height: 1px;
    margin: -1px; padding: 0;
    overflow: hidden;
    clip: rect(0 0 0 0);
    border: 0;
}
.ck-toggle label {
    flex: 1 1 50%;
    margin: 0;
    padding: 10px 6px;
    text-align: center;
    font-size: 13px;
    font-weight: 400;
    letter-spacing: .02em;
    text-transform: uppercase;
    color: var(--ck-ink);
    background: #fff;
    cursor: pointer;
    user-select: none;
    transition: background-color .15s ease, color .15s ease;
}
.ck-radio:checked + label { background: var(--ck-orange); color: #fff; font-weight: 500; }
.ck-radio:focus-visible + label { outline: 3px solid rgba(32,160,196,.6); outline-offset: -3px; }

.ck-summary {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin-top: 26px;
}
.ck-summary-text { text-align: center; }
.ck-page .ck-plan-name { margin: 0; font-size: 19px; font-weight: 600; line-height: 1.25; color: var(--ck-ink); }
.ck-page .ck-price { margin: 2px 0 0; font-size: 25px; font-weight: 700; line-height: 1.2; color: var(--ck-ink); }
.ck-page .ck-billing { margin: 8px 0 0; font-size: 14px; color: #444; font-weight: bold;}
.ck-badge { display: block; flex: 0 0 auto; width: 88px; height: 88px; margin-right: 4px; }

.ck-benefits-wrap { display: block; }
.ck-benefits { list-style: none; margin: 32px 0 0; padding: 0 0 0 10px; font-size: 13.5px; }
.ck-benefits li { position: relative; padding-left: 16px; margin-bottom: 8px; line-height: 1.45; color: #333; }
.ck-benefits li::before { content: "\2713"; position: absolute; left: 0; top: 0; }
.ck-benefits li.ck-highlight { font-weight: 700; }

.ck-benefits-toggle {
    display: none;
    margin: 6px auto 0;
    padding: 4px 12px;
    background: none;
    border: 0;
    color: var(--ck-ink);
    line-height: 1;
    cursor: pointer;
}
.ck-benefits-toggle svg { display: block; transition: transform .2s ease; }
.ck-benefits-toggle[aria-expanded="true"] svg { transform: rotate(180deg); }

/* ---------- Form panel ---------- */
.ck-form { padding: 28px 22px 22px; }

.ck-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 16px 12px; }
.ck-field { min-width: 0; }

.ck-page .ck-form .form-label {
    display: block;
    margin: 0 0 6px;
    font-size: 12.5px;
    font-weight: 400;
    color: var(--ck-ink);
}
.ck-page .ck-form .form-control {
    display: block;
    width: 100%;
    height: 32px;
    margin: 0;
    padding: 4px 10px;
    font-family: var(--ck-font);
    font-size: 13px;
    line-height: 1.5;
    color: #212529;
    background: #fff;
    border: 1px solid var(--ck-field-border);
    border-radius: 4px;
    box-shadow: none;
    appearance: none;
    text-overflow: ellipsis;
    transition: border-color .15s ease, box-shadow .15s ease;
}
.ck-page .ck-form .form-control::placeholder { color: var(--ck-placeholder); opacity: 1; }
.ck-page .ck-form .form-control:focus {
    outline: 0;
    border-color: var(--ck-orange);
    box-shadow: 0 0 0 3px rgba(249,151,31,.2);
}

/* Validation (mirrors Bootstrap's .was-validated behaviour used by checkout.js) */
.ck-page .ck-form .invalid-feedback { display: none; margin-top: 4px; font-size: 11.5px; line-height: 1.35; color: var(--ck-error); }
.ck-page .was-validated .form-control:invalid,
.ck-page .ck-form .form-control.is-invalid { border-color: var(--ck-error); }
.ck-page .was-validated .form-control:invalid ~ .invalid-feedback,
.ck-page .ck-form .form-control.is-invalid ~ .invalid-feedback { display: block; }

.ck-page .ck-form hr {
    margin: 36px 0 0;
    border: 0;
    border-top: 1px solid #dcdcdc;
    opacity: 1;
}

.ck-page .ck-terms {
    max-width: 290px;
    margin: 44px auto 52px;
    font-size: 12px;
    line-height: 1.5;
    text-align: center;
    color: var(--ck-ink);
}
.ck-page .ck-terms a { color: var(--ck-orange); text-decoration: underline; }

.ck-consent { display: flex; align-items: center; gap: 16px; margin-bottom: 12px; }
.ck-consent input[type="checkbox"] {
    flex: 0 0 auto;
    width: 12px; height: 12px;
    margin: 0;
    accent-color: #2f6fed;
}
.ck-page .ck-consent label { margin: 0; font-size: 11px; line-height: 1.45; color: var(--ck-ink); }

.ck-page .ck-form .ck-submit {
    display: block;
    width: 100%;
    margin: 40px 0 0;
    padding: 6px 12px;
    font-family: var(--ck-font);
    font-size: 16px;
    font-weight: 400;
    line-height: 1.5;
    color: #fff;
    background-color: var(--ck-orange);
    border: 0;
    border-radius: 3px;
    box-shadow: none;
    cursor: pointer;
}
.ck-page .ck-form .ck-submit:hover,
.ck-page .ck-form .ck-submit:focus-visible { background-color: var(--ck-orange-hover); color: #fff; }
.ck-page .ck-form .ck-submit:focus-visible { outline: 3px solid rgba(32,160,196,.6); outline-offset: 2px; }

/* ---------- Footer ---------- */
.ck-page .ck-footer { margin: 16px 0 32px; text-align: center; }
.ck-page .ck-footer p { margin: 0; font-size: 10px; color: #B8B8B8; }

/* Footer rendered by the shared footer include (overrides its my-5 / pt-5 spacing) */
.ck-page > footer { margin: 16px 0 32px !important; padding: 0 !important; text-align: center; }
.ck-page > footer p { margin: 0; }

/* Server-side flash / validation messages */
.ck-page .ck-alert,
.ck-page .alert { max-width: 836px; margin: 0 auto 16px; font-size: 14px; }

/* ---------- Plans page (plan toggle + account form) ---------- */
/* plans.php renders inside the plans view's Bootstrap row (row-cols-md-2 text-center): take the full row, undo centring */
.ck-plans-col { flex: 0 0 100% !important; width: 100% !important; max-width: 100% !important; }
.ck-page.ck-plans { padding: 0; }
.ck-page.ck-plans .ck-card { text-align: left; }

/* ---------- Mobile ---------- */
@media (max-width: 767.98px) {
    .ck-page { padding: 0 12px; }
    .ck-page header.ck-topbar { flex-direction: column; align-items: stretch; padding: 16px 0 0; }
    .ck-logo { width: 150px; margin: 0 auto; }
    .ck-login { align-self: center; margin-top: 6px; font-size: 14px; }

    .ck-intro { margin: 32px auto 22px; padding: 0 4px; }
    .ck-page .ck-step { font-size: 24px; margin-bottom: 4px; }
    .ck-page .ck-trial-note { font-size: 17px; line-height: 1.45; }

    .ck-card { flex-direction: column; border-radius: 12px; }
    .ck-plan-col { flex: none; border-right: 0; border-bottom: 1px solid var(--ck-line); }
    .ck-form-col { flex: none; }

    .ck-plan { padding: 10px 10px 6px; }
    .ck-toggle label { font-size: 13px; padding: 9px 4px; }
    .ck-summary { margin-top: 10px; gap: 8px; }
    .ck-badge { width: 52px; height: 52px; }
    .ck-page .ck-plan-name { font-size: 17px; }
    .ck-page .ck-price { font-size: 23px; }
    .ck-page .ck-billing { margin-top: 4px; font-size: 14px; color: #444; font-weight: bold;}

    .ck-benefits-wrap { display: none; }
    .ck-page .ck-benefits-wrap.is-open { display: block !important; }
    .ck-benefits { margin: 16px 0 0; padding-left: 16px; font-size: 13.5px; }
    .ck-benefits-toggle { display: block; position: relative; z-index: 1; touch-action: manipulation; -webkit-tap-highlight-color: transparent; }

    .ck-form { padding: 18px 10px 10px; }
    .ck-fields { gap: 14px 10px; }
    .ck-page .ck-form .form-control { height: 34px; font-size: 16px; } /* 16px stops iOS zoom-on-focus */
    .ck-page .ck-form .form-label { font-size: 12.5px; }
    .ck-page .ck-form hr { margin-top: 18px; }
    .ck-page .ck-terms { margin: 22px auto 14px; font-size: 11.5px; }
    .ck-consent { align-items: flex-start; gap: 22px; margin-bottom: 10px; }
    .ck-consent input[type="checkbox"] { margin-top: 2px; }
    .ck-page .ck-form .ck-submit { margin-top: 12px; }

}

@media (prefers-reduced-motion: reduce) {
    .ck-benefits-toggle svg, .ck-toggle label { transition: none; }
}
