/* Registration form mobile optimizations */
@media (max-width: 767px) {
    /* Form title and subtitle */
    .card-body h1 {
        font-size: 22px !important;
        line-height: 1.3 !important;
        margin-bottom: 8px !important;
    }

    .form-subtitle {
        font-size: 15px !important;
        line-height: 1.4 !important;
        margin-bottom: 20px !important;
    }

    /* Form labels */
    .form-label {
        font-size: 13px !important;
        font-weight: 600 !important;
        margin-bottom: 4px !important;
        color: #333 !important;
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
    }

    /* Form controls */
    .form-control {
        font-size: 12px !important;
        /* padding: 8px 10px !important; */
        line-height: 1.3 !important;
        height: auto !important;
    }

    /* Form groups */
    .form-group {
        margin-bottom: 12px !important;
    }

    /* Small text */
    small {
        font-size: 10px !important;
        line-height: 1.3 !important;
        margin-top: 2px !important;
        display: block !important;
    }

    /* Error messages and muted text */
    .invalid-feedback,
    .text-muted {
        font-size: 10px !important;
    }

    /* Compact 2-column grid layout for all steps */
    .form-step .row .col-lg-6,
    .form-step .row .col-6 {
        flex: 0 0 50% !important;
        max-width: 50% !important;
        padding-left: 3px !important;
        padding-right: 3px !important;
    }

    .form-step .row {
        margin-left: -3px !important;
        margin-right: -3px !important;
    }

    /* Full width for specific fields */
    .form-step .row .col-lg-12 {
        flex: 0 0 100% !important;
        max-width: 100% !important;
        padding-left: 3px !important;
        padding-right: 3px !important;
    }

    /* Full width for Create Profile For in step 1 */
    /* .step-1 .row:first-child .col-lg-6 {
        flex: 0 0 100% !important;
        max-width: 100% !important;
    } */

    /* Button styling */
    .btn {
        font-size: 12px !important;
        padding: 8px 16px !important;
        line-height: 1.4 !important;
    }

    /* Progress text */
    .text-center small {
        font-size: 12px !important;
    }

    /* Input group alignment fix */
    .input-group {
        display: flex !important;
        align-items: stretch !important;
    }

    .input-group-prepend {
        display: flex !important;
    }

    .input-group-text {
        font-size: 12px !important;
        padding: 8px 10px !important;
        border-right: 0 !important;
    }

    /* .input-group .form-control { */
        /* border-left: 0 !important; */
    /* } */

    /* Dropdown field alignment fix */
    /* .aiz-selectpicker {
        height: auto !important;
        font-size: 12px !important;
        padding: 8px 10px !important;
    } */

    /* .bootstrap-select .dropdown-toggle {
        height: auto !important;
        padding: 8px 10px !important;
        font-size: 12px !important;
        line-height: 1.3 !important;
        text-align: left !important;
        padding-left: 10px !important;
    } */

    /* .bootstrap-select {
        width: 100% !important;
    } */

    .bootstrap-select .dropdown-toggle:focus {
        outline: none !important;
        box-shadow: 0 0 0 0.2rem rgba(0,123,255,.25) !important;
    }
    
    /* Fix multiselect actions box in mobile */
    .bootstrap-select .bs-actionsbox {
        padding: 2px 4px !important;
    }
    
    .bootstrap-select .bs-actionsbox .btn-group button {
        font-size: 10px !important;
        padding: 2px 6px !important;
        margin: 0 1px !important;
    }

    /* Password fields full width on mobile */
    .form-step .row .col-lg-6[class*="password"],
    .form-step .row .col-6:has(input[name="password"]),
    .form-step .row .col-6:has(input[name="password_confirmation"]) {
        flex: 0 0 100% !important;
        max-width: 100% !important;
    }

    /* Captcha layout optimization */
    #canvas {
        max-width: 100% !important;
        height: auto !important;
    }

    .captcha-refresh-btn {
        font-size: 11px !important;
        padding: 4px 8px !important;
        margin-top: 8px !important;
    }
}
