/* ==========================================================================
   Sign-up page (GRCIQ)
   Colours: navy #184b71 (brand), ink #12263a, body #374151, muted #6b7280,
            lines #dfe5ec, field fill #f7f9fc, action orange #ee6331
   Materialize styles all inputs/radios/checkboxes, so some rules use !important.
   ========================================================================== */

.su-page {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    min-height: calc(100vh - 80px);
    margin-top: 80px; /* clears the fixed site header */
    padding: 40px 16px 60px;
    background: radial-gradient(circle at 0% 0%, #e8f0f8 0%, transparent 45%),
                radial-gradient(circle at 100% 100%, #fdeee6 0%, transparent 40%),
                #f4f6fa;
}

.su-card {
    display: grid;
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
    overflow: hidden;
    width: 100%;
    max-width: 1040px;
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 20px 60px rgba(16, 24, 40, 0.12);
}

/* --------------------------------------------------------------------------
   Brand panel
   -------------------------------------------------------------------------- */
.su-brand {
    position: relative;
    display: flex;
    align-items: center;
    padding: 48px 40px;
    background: linear-gradient(160deg, #12385a 0%, #184b71 55%, #1f6a8f 100%);
    color: #fff;
}

    .su-brand:after {
        content: "";
        position: absolute;
        right: -80px;
        bottom: -80px;
        width: 240px;
        height: 240px;
        border-radius: 50%;
        background: rgba(255, 255, 255, 0.06);
    }

.su-brand__inner {
    position: relative;
    z-index: 1;
    width: 100%;
}

/* --------------------------------------------------------------------------
   Form panel
   -------------------------------------------------------------------------- */
.su-form {
    padding: 44px 48px;
}

.su-page .su-form__title {
    margin: 0 0 24px !important;
    color: #12263a !important;
    font-size: 28px !important;
    font-weight: 700;
    line-height: 1.25 !important;
}

.su-page .su-form__subtitle {
    margin: 0 0 24px !important;
    color: #6b7280 !important;
    font-size: 15px;
    text-align: left !important;
}

    .su-form__subtitle a {
        color: #184b71 !important;
        font-weight: 700;
    }

        .su-form__subtitle a:hover {
            text-decoration: underline !important;
        }

/* "Already a member? Sign in" below the Create Account button */
.su-page .su-form__subtitle--bottom {
    margin: 0 !important;
    text-align: center !important;
}

/* Social sign-up (in the navy brand panel): stacked white buttons */
.su-social {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.su-social__heading {
    margin-bottom: 2px;
    color: rgba(255, 255, 255, 0.75);
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.su-social__btn {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 46px;
    padding: 0 16px;
    border: 1px solid transparent;
    border-radius: 10px;
    background: #fff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    color: #1f2937 !important;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

    .su-social__btn:hover {
        box-shadow: 0 6px 16px rgba(0, 0, 0, 0.22);
        transform: translateY(-1px);
    }

    .su-social__btn i.fa {
        float: none;
        width: 20px;
        margin: 0;
        font-size: 18px;
        text-align: center;
    }

.su-social__btn--facebook i.fa { color: #1877f2; }
.su-social__btn--google i.fa { color: #ea4335; }
.su-social__btn--linkedin i.fa { color: #0a66c2; }

/* Alerts (server message, terms check, social login errors) */
.su-alert {
    margin-bottom: 18px;
    padding: 12px 14px;
    border: 1px solid #f5c2c0;
    border-left: 4px solid #d64545;
    border-radius: 8px;
    background: #fdf2f2;
    color: #9b1c1c;
    font-size: 14px;
    line-height: 1.5;
}

/* Fields */
.su-row {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.su-field {
    margin-bottom: 18px;
}

    .su-page .su-field > label,
    .su-field__label {
        display: block;
        position: static !important;
        margin-bottom: 6px;
        transform: none !important;
        color: #374151 !important;
        font-size: 14px !important;
        font-weight: 600;
    }

.su-input {
    position: relative;
    display: flex;
    align-items: center;
}

    .su-input > i.fa {
        position: absolute;
        left: 14px;
        z-index: 1;
        float: none;
        width: auto;
        margin: 0;
        color: #9aa3ae;
        font-size: 16px;
        pointer-events: none;
    }

    .su-page .su-input input {
        box-sizing: border-box !important;
        width: 100% !important;
        height: 46px !important;
        margin: 0 !important;
        padding: 0 14px 0 42px !important;
        border: 1px solid #dfe5ec !important;
        border-radius: 10px !important;
        background: #f7f9fc !important;
        box-shadow: none !important;
        color: #12263a !important;
        font-size: 15px !important;
        transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
    }

        .su-page .su-input input::placeholder {
            color: #a0a8b3;
        }

        .su-page .su-input input:focus {
            border-color: #184b71 !important;
            background: #fff !important;
            box-shadow: 0 0 0 3px rgba(24, 75, 113, 0.15) !important;
        }

    /* Password field leaves room for the show/hide button */
    .su-page .su-input input[type="password"],
    .su-page .su-input input#Password {
        padding-right: 46px !important;
    }

.su-input__toggle {
    position: absolute;
    right: 8px;
    width: 34px;
    height: 34px;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: #6b7280;
    font-size: 16px;
    cursor: pointer;
}

    .su-input__toggle:hover,
    .su-input__toggle:focus {
        background: #eef2f6;
        color: #184b71;
        outline: none;
    }

/* MVC validation messages */
/* md-redesign.css makes .field-validation-error position:absolute; keep each message under its own field */
.su-page .field-validation-error {
    position: static !important;
    top: auto !important;
    left: auto !important;
    right: auto !important;
}

.su-field .field-validation-error {
    display: block;
    margin-top: 6px;
    color: #c53030;
    font-size: 13px;
}

.su-page .su-input input.input-validation-error {
    border-color: #e57373 !important;
    background: #fff8f8 !important;
}

/* Account type: two selectable tiles (radio inputs stay real for model binding) */
.su-account-type {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.su-account-type__option {
    display: block;
    margin: 0;
    cursor: pointer;
}

    .su-page .su-account-type__option [type="radio"] + span {
        display: flex !important;
        align-items: center;
        justify-content: flex-start;
        gap: 8px;
        position: relative !important;
        height: 46px !important;
        padding: 0 12px 0 44px !important;
        border: 1px solid #dfe5ec;
        border-radius: 10px;
        background: #f7f9fc;
        color: #374151 !important;
        font-size: 15px !important;
        font-weight: 600;
        line-height: 46px !important;
        transition: border-color 0.2s ease, background 0.2s ease, color 0.2s ease;
    }

        /* Checkbox-style indicator on the left of each tile (still a radio: only one can be selected).
           Replaces Materialize's radio circle, which sits top-left. */
        .su-page .su-account-type__option [type="radio"] + span:before,
        .su-page .su-account-type__option [type="radio"] + span:after {
            content: "" !important;
            display: block !important;
            position: absolute !important;
            top: 50% !important;
            z-index: 0 !important;
            margin: 0 !important;
            transition: border-color 0.2s ease, background 0.2s ease !important;
        }

        /* Box */
        .su-page .su-account-type__option [type="radio"] + span:before {
            left: 14px !important;
            width: 18px !important;
            height: 18px !important;
            margin-top: -9px !important;
            border: 2px solid #9aa3ae !important;
            border-radius: 4px !important;
            background: #fff !important;
            transform: none !important;
        }

        /* Tick (only visible when selected) */
        .su-page .su-account-type__option [type="radio"] + span:after {
            left: 20px !important;
            width: 6px !important;
            height: 11px !important;
            margin-top: -7px !important;
            border: solid transparent !important;
            border-width: 0 2px 2px 0 !important;
            border-radius: 0 !important;
            background: transparent !important;
            transform: rotate(45deg) !important;
        }

    .su-page .su-account-type__option [type="radio"]:checked + span {
        border-color: #184b71;
        background: #eef4f9;
        box-shadow: 0 0 0 3px rgba(24, 75, 113, 0.12);
        color: #184b71 !important;
    }

        .su-page .su-account-type__option [type="radio"]:checked + span:before {
            border-color: #184b71 !important;
            background: #184b71 !important;
        }

        .su-page .su-account-type__option [type="radio"]:checked + span:after {
            border-color: #fff !important;
        }

    /* Keyboard focus on the hidden radio shows on the tile */
    .su-page .su-account-type__option [type="radio"]:focus + span {
        border-color: #184b71;
    }

    .su-account-type__option span i.fa {
        float: none;
        width: auto;
        margin: 0;
        color: inherit;
    }

/* Checkboxes (Materialize filled-in style kept) */
.su-checks {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin: 4px 0 16px;
}

    .su-checks label {
        display: block;
        margin: 0;
    }

    .su-page .su-checks label span {
        color: #4b5563 !important;
        font-size: 14px !important;
        line-height: 20px !important;
    }

    .su-checks label a {
        color: #184b71 !important;
        font-weight: 600;
        text-decoration: underline !important;
    }

/* reCAPTCHA renders at a fixed 304x78; scale it to 80% (~243x62) and reserve only that space */
.su-captcha {
    height: 62px;
    margin-bottom: 16px;
    text-align: left;
}

    .su-captcha .g-recaptcha {
        display: inline-block;
        transform: scale(0.8);
        transform-origin: 0 0;
    }

/* Submit */
.su-submit {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    height: 50px;
    margin-bottom: 16px;
    border: 0;
    border-radius: 10px;
    background: #ee6331;
    box-shadow: 0 6px 18px rgba(238, 99, 49, 0.3);
    color: #fff;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

    .su-submit:hover,
    .su-submit:focus {
        background: #d9541f;
        box-shadow: 0 8px 22px rgba(238, 99, 49, 0.38);
        outline: none;
        transform: translateY(-1px);
    }

/* --------------------------------------------------------------------------
   Responsive
   -------------------------------------------------------------------------- */
@media only screen and (max-width: 991px) {
    .su-card {
        grid-template-columns: 1fr;
        max-width: 620px;
    }

    .su-brand {
        padding: 32px 28px;
    }
}

@media only screen and (max-width: 576px) {
    .su-page {
        padding: 16px 12px 40px;
    }

    .su-form {
        padding: 28px 20px;
    }

    .su-page .su-form__title {
        font-size: 24px !important;
    }

    .su-row {
        grid-template-columns: 1fr;
        gap: 0;
    }
}
