/* =====================================================================
   Mobile Public Pages — login se pehle wale pages (<= 767px only)
   MasterPage.master  : ForgotPassword, MemberRegisterCheckStatus
   Main1.master       : MemberRegistration, MemberRegistrationList, Successful
   Dono masters <body class="pub-page"> lagate hain. Sirf look badla hai —
   markup / IDs / links same hain. Tokens mobile-app.css se match karte hain.
   ===================================================================== */

@media (max-width: 767px) {

    body.pub-page {
        background:
            linear-gradient(160deg, #4b83f8 0%, #2f6df2 45%, #245be6 100%) no-repeat,
            #eef2fa !important;
        background-size: 100% 190px, auto !important;
        font-family: "Outfit", "Poppins", "Inter", -apple-system, "Segoe UI", Roboto, Arial, sans-serif !important;
        color: #33405c;
        -webkit-tap-highlight-color: transparent;
        padding-bottom: 24px;
    }

    /* ---------- Main white card ---------- */
    body.pub-page > .container.card,
    body.pub-page form > div > .container {
        margin: 22px 14px 0 !important;
        width: auto !important;
        max-width: 480px;
        padding: 0 !important;
        border: 0 !important;
        border-radius: 22px !important;
        background: #fff !important;
        box-shadow: 0 20px 40px rgba(31, 61, 138, .14) !important;
        overflow: hidden;
    }

    @media (min-width: 509px) {
        body.pub-page > .container.card,
        body.pub-page form > div > .container { margin-left: auto !important; margin-right: auto !important; }
    }

    /* grey decorative bars hatao — kuch jagah inline "!important" hai jo CSS se
       override nahi hota, isliye inset box-shadow se upar white paint karte hain */
    body.pub-page [style*="background:#e3e3e3"],
    body.pub-page [style*="background: #e3e3e3"] {
        background: transparent !important;
        box-shadow: inset 0 0 0 999px #fff;
        min-height: 0;
    }

        body.pub-page .row > [style*="#e3e3e3"]:empty,
        body.pub-page div.fs-18[style*="#e3e3e3"]:empty,
        body.pub-page .custom-footer { display: none !important; }

    /* "Member Registration" title strip */
    body.pub-page div.fs-18[style*="#e3e3e3"] {
        color: #17253f;
        font-size: 20px !important;
        font-weight: 700;
        padding: 6px 16px 2px !important;
    }

    /* BS5 card (MasterPage): row ke negative gutter se content edge par chipakta tha */
    body.pub-page > .container.card .row {
        margin-left: 0 !important;
        margin-right: 0 !important;
        --bs-gutter-x: 0;
    }

    body.pub-page > .container.card .body-margin { padding: 4px 16px 18px; }

        body.pub-page > .container.card .body-margin .p-4 { padding: 6px 0 !important; }
        body.pub-page > .container.card .body-margin .mt-5 { margin-top: 6px !important; }
        body.pub-page > .container.card h5 { font-size: 19px; font-weight: 700; margin: 4px 0 4px; padding: 0; }

    /* logo */
    body.pub-page img.logo {
        max-height: 84px !important;
        width: auto;
        margin: 18px auto 4px !important;
        display: block;
    }

    /* Section header strip (e.g. "Personal Details") => chip heading */
    body.pub-page .col-sm-12.text-center[style*="#e3e3e3"] {
        background: #e8f0ff !important;
        box-shadow: inset 0 0 0 999px #e8f0ff;
        color: #2f6df2;
        border-radius: 12px;
        padding: 10px 12px !important;
        margin: 16px 0 10px !important;
        font-size: 13.5px;
        letter-spacing: .3px;
    }

    /* page title (Main1 panel headers / center tags) */
    body.pub-page .panel { border: 0 !important; box-shadow: none !important; background: transparent; margin: 0; }

    body.pub-page .panel-heading {
        background: transparent !important;
        border: 0 !important;
        color: #17253f !important;
        font-size: 20px !important;
        font-weight: 700 !important;
        text-align: center;
        padding: 16px 16px 6px !important;
    }

    body.pub-page .panel-body { padding: 8px 16px 18px !important; }

    body.pub-page h1, body.pub-page h2, body.pub-page h3, body.pub-page h4, body.pub-page h5 {
        color: #17253f;
    }

    body.pub-page h1.fs-3 { font-size: 19px !important; line-height: 1.4; }
    body.pub-page .fs-4 { font-size: 15px !important; }

    body.pub-page .p-4 { padding: 18px 16px !important; }
    body.pub-page .p-5 { padding: 22px 16px !important; }

    /* ---------- Fields ---------- */
    body.pub-page label {
        display: block;
        font-size: 12.5px;
        font-weight: 600;
        color: #5b6680;
        margin: 10px 0 6px 2px;
    }

    body.pub-page .form-control,
    body.pub-page select,
    body.pub-page input[type="text"],
    body.pub-page input[type="password"],
    body.pub-page input[type="email"],
    body.pub-page input[type="tel"],
    body.pub-page input[type="number"],
    body.pub-page textarea {
        height: 50px;
        width: 100%;
        border: 1.5px solid #e6ebf5 !important;
        border-radius: 12px !important;
        background-color: #f6f8fd !important;
        color: #17253f !important;
        font-size: 16px !important;
        padding: 10px 14px !important;
        box-shadow: none !important;
        transition: border-color .15s ease, box-shadow .15s ease, background-color .15s ease;
    }

    body.pub-page textarea { height: auto; min-height: 90px; }

    body.pub-page select,
    body.pub-page select.form-control,
    body.pub-page .form-select {
        -webkit-appearance: none;
        appearance: none;
        padding-right: 38px !important;
        background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5l5 5 5-5' fill='none' stroke='%237a869e' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") !important;
        background-repeat: no-repeat !important;
        background-position: right 14px center !important;
    }

    body.pub-page .form-control:focus,
    body.pub-page input:focus,
    body.pub-page select:focus,
    body.pub-page textarea:focus {
        border-color: #2f6df2 !important;
        background-color: #fff !important;
        box-shadow: 0 0 0 4px rgba(47, 109, 242, .12) !important;
        outline: none !important;
    }

    body.pub-page ::placeholder { color: #a3abbd !important; opacity: 1; }

    /* input-group with icon addon (Registration) */
    body.pub-page .input-group { display: flex; flex-wrap: nowrap; width: 100%; }

        body.pub-page .input-group > .form-control { border-radius: 12px 0 0 12px !important; flex: 1 1 auto; }
        body.pub-page .input-group > .input-group-addon:first-child + .form-control { border-radius: 0 12px 12px 0 !important; }

    body.pub-page .input-group-addon,
    body.pub-page .input-group-text {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 46px;
        min-width: 46px;
        height: 50px;
        padding: 0 !important;
        border: 1.5px solid #e6ebf5 !important;
        background: #fff !important;
        color: #2f6df2 !important;
        font-size: 15px;
    }

        body.pub-page .input-group > .input-group-addon:last-child { border-left: 0 !important; border-radius: 0 12px 12px 0 !important; }
        body.pub-page .input-group > .input-group-addon:first-child { border-right: 0 !important; border-radius: 12px 0 0 12px !important; }

    /* file inputs */
    body.pub-page input[type="file"] {
        height: auto !important;
        padding: 10px !important;
        font-size: 14px !important;
    }

    body.pub-page input[type="file"]::file-selector-button {
        border: 0;
        border-radius: 10px;
        background: #e8f0ff;
        color: #2f6df2;
        font-weight: 600;
        padding: 8px 12px;
        margin-right: 10px;
    }

    /* ---------- Buttons ---------- */
    body.pub-page .btn {
        border-radius: 14px !important;
        font-weight: 600 !important;
        font-size: 15px !important;
        letter-spacing: .3px;
        text-shadow: none !important;
    }

    body.pub-page .btn-primary,
    body.pub-page .btn-success,
    body.pub-page .btn-dark,
    body.pub-page input[type="submit"] {
        min-height: 50px;
        border: 0 !important;
        color: #fff !important;
        background: linear-gradient(135deg, #4b83f8 0%, #2f6df2 50%, #245be6 100%) !important;
        box-shadow: 0 10px 20px rgba(47, 109, 242, .28) !important;
    }

        body.pub-page .btn-primary:active,
        body.pub-page input[type="submit"]:active { transform: scale(.98); }

    /* input + button group (CheckStatus Search) */
    body.pub-page .input-group > .btn,
    body.pub-page .input-group > input[type="submit"] {
        border-radius: 0 12px 12px 0 !important;
        box-shadow: none !important;
        min-height: 50px;
    }

    body.pub-page .input-group-addon:has(> .btn),
    body.pub-page .input-group-addon:has(> input[type="submit"]) {
        width: auto;
        min-width: 0;
        border: 0 !important;
        background: transparent !important;
    }

        body.pub-page .input-group-addon > .btn,
        body.pub-page .input-group-addon > input[type="submit"] {
            width: auto !important;
            height: 50px !important;
            margin: 0 !important;
            padding: 0 16px !important;
            border-radius: 0 12px 12px 0 !important;
            box-shadow: none !important;
        }

    body.pub-page .input-group > .t-10 + .form-control,
    body.pub-page .input-group > .form-control:has(+ .input-group-addon > .btn) { border-radius: 12px 0 0 12px !important; }

    body.pub-page .text-danger { color: #e5484d !important; font-size: 13px; }
    body.pub-page .text-success { color: #16a45c !important; }
    body.pub-page a { color: #2f6df2; }
}
