{"id":10838,"date":"2026-03-16T16:30:59","date_gmt":"2026-03-16T20:30:59","guid":{"rendered":"https:\/\/www.sheelersda.com\/m\/recursos-audiovisuales-form-10837\/"},"modified":"2026-04-28T15:25:54","modified_gmt":"2026-04-28T19:25:54","slug":"recursos-audiovisuales-2","status":"publish","type":"page","link":"https:\/\/www.sheelersda.com\/m\/recursos-audiovisuales-2\/","title":{"rendered":"Recursos Audiovisuales"},"content":{"rendered":"        <style id=\"cbran-form-logic-css-10837\">.cbran-form-field--conditional.cbran-logic-pending{display:none!important}<\/style>\n        <div class=\"cbran-form-container max-w-2xl mx-auto\" data-cbran-tailwind=\"1\">\n            <script>(function(){try{document.title=\"Recursos Audiovisuales \\u2014 Sheeler SDA Management\";}catch(e){}})();<\/script>            <div id=\"cbran-form-wrapper-10837\" class=\"bg-white shadow-lg rounded-lg p-6 hover:shadow-xl transition-shadow\">\n                <div id=\"cbran-form-content-10837\">\n                                        <div id=\"cbran-sms-link-box-10837\" class=\"cbran-form-sms-link-box mb-6 p-4 rounded-lg border border-blue-200 bg-blue-50\/80 relative\" data-form-id=\"10837\">\n                        <button type=\"button\" class=\"cbran-sms-link-box-close cbran-btn-icon-close absolute top-3 right-3 w-8 h-8 flex items-center justify-center rounded-md transition-colors\" aria-label=\"Close\" data-form-id=\"10837\">\n                            <svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"18\" height=\"18\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><line x1=\"18\" y1=\"6\" x2=\"6\" y2=\"18\"><\/line><line x1=\"6\" y1=\"6\" x2=\"18\" y2=\"18\"><\/line><\/svg>\n                        <\/button>\n                        <p class=\"text-sm text-gray-800 mb-3 pr-8\">At Sheeler SDA MGT, you can fill or continue this form from your mobile. Enter your phone number and we&#039;ll send you a link via text message so you can fill it at your convenience.<\/p>\n                        <div class=\"cbran-sms-link-actions flex flex-wrap items-center justify-center gap-2 mb-3\">\n                            <input type=\"tel\" id=\"cbran-sms-link-phone-10837\" class=\"cbran-sms-link-phone-input flex-1 min-w-[160px] max-w-[240px] rounded-md border border-gray-300 px-3 py-2 text-sm\" placeholder=\"Phone number\" autocomplete=\"tel\">\n                            <button type=\"button\" class=\"cbran-send-form-link-sms-btn cbran-btn-primary px-4 py-2 text-sm font-medium rounded-md disabled:opacity-50 disabled:cursor-not-allowed\" data-form-id=\"10837\">Send me the link<\/button>\n                        <\/div>\n                                                <div class=\"cbran-sms-link-consent-box mt-3 p-3 rounded-md border border-gray-300 bg-gray-50\/80 flex items-center justify-center gap-3\">\n                            <label for=\"cbran-sms-link-consent-10837\" class=\"cbran-toggle-switch flex-shrink-0 cursor-pointer active\">\n                                <input type=\"checkbox\" id=\"cbran-sms-link-consent-10837\" class=\"cbran-sms-link-consent-checkbox\" data-form-id=\"10837\" checked>\n                            <\/label>\n                            <label for=\"cbran-sms-link-consent-10837\" class=\"cbran-sms-link-consent flex-1 cursor-pointer\">\n                                <span class=\"text-sm text-gray-700\">I agree to receive text messages from Sheeler SDA MGT.<\/span>\n                            <\/label>\n                        <\/div>\n                        <p id=\"cbran-sms-link-message-10837\" class=\"mt-2 text-xs hidden text-center\" role=\"status\"><\/p>\n                    <\/div>\n                    <p id=\"cbran-sms-link-reopen-10837\" class=\"cbran-sms-link-reopen mb-4 text-sm text-center hidden\">\n                        <button type=\"button\" class=\"cbran-sms-link-reopen-btn\">Get form link by text message<\/button>\n                    <\/p>\n                                                                                \n                                        <form id=\"cbran-frontend-form-10837\" class=\"space-y-4\" enctype=\"multipart\/form-data\" data-form-layout=\"vertical\" aria-label=\"Recursos Audiovisuales\">\n                    <div class=\"form-field cbran-form-field-event-itinerary\"><label class=\"block text-sm font-medium text-gray-700 mb-1 flex items-start gap-2\" for=\"cbran-ei-498c4202bd0b-event\"><span class=\"cbran-field-icon cbran-field-icon-color-blue flex-shrink-0\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\" class=\"w-4 h-4\"><rect x=\"3\" y=\"4\" width=\"18\" height=\"18\" rx=\"2\" ry=\"2\"\/><line x1=\"16\" y1=\"2\" x2=\"16\" y2=\"6\"\/><line x1=\"8\" y1=\"2\" x2=\"8\" y2=\"6\"\/><line x1=\"3\" y1=\"10\" x2=\"21\" y2=\"10\"\/><\/svg><\/span><span class=\"flex flex-1 min-w-0 flex-wrap items-center gap-1 justify-start text-left\"><span class=\"\">Selecione una actividad\/evento<\/span><\/span><\/label><div class=\"cbran-event-itinerary-field space-y-2\" data-form-id=\"10837\" data-field-name=\"selecione_una_actividad\/evento\" data-required=\"0\" data-cbran-ei-has-sections=\"0\"><div><label class=\"block text-xs font-medium text-gray-600 mb-0.5\" for=\"cbran-ei-498c4202bd0b-event\">Event<\/label><select id=\"cbran-ei-498c4202bd0b-event\" class=\"cbran-ei-event-select w-full rounded-md border-gray-300 shadow-sm focus:border-blue-500 focus:ring-blue-500\"><option value=\"\">Loading events\u2026<\/option><\/select><\/div><div class=\"cbran-ei-section-wrap\" style=\"display:none;\"><label class=\"block text-xs font-medium text-gray-600 mb-0.5\" for=\"cbran-ei-498c4202bd0b-section\">Itinerary section<\/label><select id=\"cbran-ei-498c4202bd0b-section\" class=\"cbran-ei-section-select w-full rounded-md border-gray-300 shadow-sm focus:border-blue-500 focus:ring-blue-500\"><option value=\"\">Select a section\u2026<\/option><\/select><\/div><input type=\"hidden\" name=\"selecione_una_actividad\/evento\" id=\"cbran-ei-498c4202bd0b-json\" class=\"cbran-event-itinerary-json\" value=\"\" autocomplete=\"off\"><\/div><\/div><div class=\"form-field\"><label class=\"block text-sm font-medium text-gray-700 mb-1 flex items-start gap-2\" for=\"nombre_y_apellido\"><span class=\"cbran-field-icon cbran-field-icon-color-blue flex-shrink-0\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\" class=\"w-4 h-4\"><path d=\"M14.5 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7.5L14.5 2z\"\/><polyline points=\"14 2 14 8 20 8\"\/><line x1=\"16\" y1=\"13\" x2=\"8\" y2=\"13\"\/><line x1=\"16\" y1=\"17\" x2=\"8\" y2=\"17\"\/><line x1=\"10\" y1=\"9\" x2=\"8\" y2=\"9\"\/><\/svg><\/span><span class=\"flex flex-1 min-w-0 flex-wrap items-center gap-1 justify-start text-left\"><span class=\"\">Nombre y Apellido <span class=\"text-red-500\">*<\/span><\/span><\/span><\/label><input type=\"text\" name=\"nombre_y_apellido\" id=\"nombre_y_apellido\" class=\"w-full rounded-md border-gray-300 shadow-sm focus:border-blue-500 focus:ring-blue-500\" placeholder=\"Joan Rodriguez\" required><\/div><div class=\"form-field\"><label class=\"block text-sm font-medium text-gray-700 mb-1 flex items-start gap-2\" for=\"n\u00famero_de_tel\u00e9fono\"><span class=\"cbran-field-icon cbran-field-icon-color-blue flex-shrink-0\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\" class=\"w-4 h-4\"><path d=\"M13.832 16.568a1 1 0 0 0 1.213-.303l.355-.465A2 2 0 0 1 17 15h3a2 2 0 0 1 2 2v3a2 2 0 0 1-2 2A18 18 0 0 1 2 4a2 2 0 0 1 2-2h3a2 2 0 0 1 2 2v3a2 2 0 0 1-.8 1.6l-.468.351a1 1 0 0 0-.292 1.233 14 14 0 0 0 6.392 6.384\"><\/path><\/svg><\/span><span class=\"flex flex-1 min-w-0 flex-wrap items-center gap-1 justify-start text-left\"><span class=\"\">N\u00famero de tel\u00e9fono<\/span><\/span><\/label><input type=\"tel\" name=\"n\u00famero_de_tel\u00e9fono\" id=\"n\u00famero_de_tel\u00e9fono\" class=\"w-full rounded-md border-gray-300 shadow-sm focus:border-blue-500 focus:ring-blue-500\" placeholder=\"\"><\/div><div class=\"form-field\"><label class=\"block text-sm font-medium text-gray-700 mb-1 flex items-start gap-2\" for=\"departamento\"><span class=\"cbran-field-icon cbran-field-icon-color-blue flex-shrink-0\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\" class=\"w-4 h-4\"><path d=\"M14.5 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7.5L14.5 2z\"\/><polyline points=\"14 2 14 8 20 8\"\/><line x1=\"16\" y1=\"13\" x2=\"8\" y2=\"13\"\/><line x1=\"16\" y1=\"17\" x2=\"8\" y2=\"17\"\/><line x1=\"10\" y1=\"9\" x2=\"8\" y2=\"9\"\/><\/svg><\/span><span class=\"flex flex-1 min-w-0 flex-wrap items-center gap-1 justify-start text-left\"><span class=\"\">Departamento <span class=\"text-red-500\">*<\/span><\/span><\/span><\/label><input type=\"text\" name=\"departamento\" id=\"departamento\" class=\"w-full rounded-md border-gray-300 shadow-sm focus:border-blue-500 focus:ring-blue-500\" placeholder=\"M\u00fasica\" required><\/div><div class=\"form-field\"><label class=\"block text-sm font-medium text-gray-700 mb-1 flex items-start gap-2\" for=\"fecha_programaci\u00f3n_(si_no_seleciono_un_evento)\"><span class=\"cbran-field-icon cbran-field-icon-color-blue flex-shrink-0\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\" class=\"w-4 h-4\"><rect x=\"3\" y=\"4\" width=\"18\" height=\"18\" rx=\"2\" ry=\"2\"\/><line x1=\"16\" y1=\"2\" x2=\"16\" y2=\"6\"\/><line x1=\"8\" y1=\"2\" x2=\"8\" y2=\"6\"\/><line x1=\"3\" y1=\"10\" x2=\"21\" y2=\"10\"\/><\/svg><\/span><span class=\"flex flex-1 min-w-0 flex-wrap items-center gap-1 justify-start text-left\"><span class=\"\">Fecha Programaci\u00f3n (Si no seleciono un evento)<\/span><\/span><\/label><div class=\"cbran-form-date-wrap\"><input type=\"date\" name=\"fecha_programaci\u00f3n_(si_no_seleciono_un_evento)\" id=\"fecha_programaci\u00f3n_(si_no_seleciono_un_evento)\" class=\"cbran-form-field-date\" placeholder=\"mm\/dd\/yyyy\" autocomplete=\"off\"><button type=\"button\" class=\"cbran-form-date-open-btn\" aria-label=\"Open calendar\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\" class=\"h-5 w-5\"><rect x=\"3\" y=\"4\" width=\"18\" height=\"18\" rx=\"2\" ry=\"2\"\/><line x1=\"16\" y1=\"2\" x2=\"16\" y2=\"6\"\/><line x1=\"8\" y1=\"2\" x2=\"8\" y2=\"6\"\/><line x1=\"3\" y1=\"10\" x2=\"21\" y2=\"10\"\/><\/svg><\/button><\/div><\/div><div class=\"form-field\"><label class=\"block text-sm font-medium text-gray-700 mb-1 flex items-start gap-2\" for=\"enlace_de_youtube\"><span class=\"cbran-field-icon cbran-field-icon-color-blue flex-shrink-0\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\" class=\"w-4 h-4\"><path d=\"M14.5 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7.5L14.5 2z\"\/><polyline points=\"14 2 14 8 20 8\"\/><\/svg><\/span><span class=\"flex flex-1 min-w-0 flex-wrap items-center gap-1 justify-start text-left\"><span class=\"\">Enlace de YouTube<\/span><\/span><\/label><input type=\"url\" name=\"enlace_de_youtube\" id=\"enlace_de_youtube\" class=\"w-full rounded-md border-gray-300 shadow-sm focus:border-blue-500 focus:ring-blue-500\" placeholder=\"Por favor compartir el o los enlaces de Youtube (En caso de tener varios).\"><\/div><div class=\"form-field\"><label class=\"block text-sm font-medium text-gray-700 mb-1 flex items-start gap-2\" for=\"archivos_de_audio,_video,_presentaciones,_im\u00e1genes_o_programas_(opcional)\"><span class=\"cbran-field-icon cbran-field-icon-color-blue flex-shrink-0\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\" class=\"w-4 h-4\"><path d=\"m21.44 11.05-9.19 9.19a6 6 0 0 1-8.49-8.49l9.19-9.19a4 4 0 0 1 5.66 5.66l-9.2 9.19a2 2 0 0 1-2.83-2.83l8.49-8.48\"\/><\/svg><\/span><span class=\"flex flex-1 min-w-0 flex-wrap items-center gap-1 justify-start text-left\"><span class=\"\">Archivos de Audio, Video, Presentaciones, Im\u00e1genes o Programas (opcional)<\/span><\/span><\/label><div class=\"cbran-multi-file-field\" data-field-type=\"document\"><div class=\"cbran-file-gallery-accordion\" id=\"archivos_de_audio,_video,_presentaciones,_im\u00e1genes_o_programas_(opcional)-gallery-accordion\"><div class=\"cbran-file-gallery flex flex-wrap gap-2 mt-2\" id=\"archivos_de_audio,_video,_presentaciones,_im\u00e1genes_o_programas_(opcional)-gallery\" aria-live=\"polite\"><\/div><\/div><div class=\"cbran-file-actions mt-2 flex flex-wrap items-center gap-2\"><input type=\"file\" name=\"archivos_de_audio,_video,_presentaciones,_im\u00e1genes_o_programas_(opcional)[]\" id=\"archivos_de_audio,_video,_presentaciones,_im\u00e1genes_o_programas_(opcional)\" data-max-size-mb=\"100\" multiple class=\"cbran-file-input w-full rounded-md border-gray-300 shadow-sm focus:border-blue-500 focus:ring-blue-500 file:mr-4 file:py-2 file:px-4 file:rounded-md file:border-0 file:text-sm file:font-semibold file:bg-blue-50 file:text-blue-700 hover:file:bg-blue-100\"><span class=\"text-xs text-gray-500\">Select multiple files. You can add more later.<\/span><\/div><\/div><\/div><div class=\"form-field form-field-textarea\"><label class=\"block text-sm font-medium text-gray-700 mb-1 flex items-start gap-2\" for=\"comentarios\"><span class=\"cbran-field-icon cbran-field-icon-color-blue flex-shrink-0\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\" class=\"w-4 h-4\"><line x1=\"8\" x2=\"21\" y1=\"6\" y2=\"6\"><\/line><line x1=\"8\" x2=\"21\" y1=\"12\" y2=\"12\"><\/line><line x1=\"8\" x2=\"21\" y1=\"18\" y2=\"18\"><\/line><line x1=\"3\" x2=\"3.01\" y1=\"6\" y2=\"6\"><\/line><line x1=\"3\" x2=\"3.01\" y1=\"12\" y2=\"12\"><\/line><line x1=\"3\" x2=\"3.01\" y1=\"18\" y2=\"18\"><\/line><\/svg><\/span><span class=\"flex flex-1 min-w-0 flex-wrap items-center gap-1 justify-start text-left\"><span class=\"\">Comentarios <span class=\"text-red-500\">*<\/span><\/span><\/span><\/label><div class=\"cbran-textarea-voice-wrap relative\"><textarea name=\"comentarios\" id=\"comentarios\" class=\"cbran-form-textarea w-full rounded-md border-gray-300 shadow-sm focus:border-blue-500 focus:ring-blue-500 cbran-form-textarea--with-voice\" rows=\"4\" placeholder=\"Informaci\u00f3n Adicional. Si no aplica escriba: NA. Ejemplo: Esta m\u00fasica va despu\u00e9s de la oraci\u00f3n.\" required><\/textarea><div class=\"cbran-stt-btn-container print:hidden\" role=\"button\" tabindex=\"0\" aria-pressed=\"false\" aria-label=\"Start voice input\" data-cbran-stt-start-label=\"Start voice input\" data-cbran-stt-stop-label=\"Stop voice input\" data-cbran-stt-cancel-label=\"Cancel countdown\" data-cbran-stt-countdown-aria=\"Voice input starts in %s\" data-cbran-stt-target=\"comentarios\" data-lang=\"es-MX\"><div class=\"cbran-stt-btn-progress relative w-12 h-12 flex items-center justify-center\"><span class=\"cbran-stt-countdown absolute inset-0 flex items-center justify-center font-bold text-lg text-slate-700 tabular-nums\" aria-live=\"polite\" aria-atomic=\"true\" aria-hidden=\"true\"><\/span><span class=\"cbran-stt-mic-wrap absolute inset-0 flex items-center justify-center pointer-events-none\" aria-hidden=\"true\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" viewBox=\"0 0 384 512\" class=\"cbran-stt-mic-icon w-5 h-5 opacity-80\" fill=\"currentColor\"><path d=\"M192 352c53.03 0 96-42.97 96-96V96c0-53.03-42.97-96-96-96S96 42.97 96 96v160c0 53 42.1 96 96 96zm152-160c-13.3 0-24 10.7-24 23.1V256c0 73.33-61.97 132.4-136.3 127.7C117.62 379.531 64 317.11 64 250.9v-35.8c0-12.4-10.75-23.1-24-23.1s-24 10.7-24 23.1v32.15c0 89.66 63.97 169.6 152 181.7V464h-40c-18.19 0-32.84 15.18-31.96 33.57C96.43 505.8 103.8 512 112 512h160c8.222 0 15.57-6.216 15.96-14.43C288.8 479.2 274.2 464 256 464h-40v-33.77C301.7 418.5 368 344.9 368 256v-40.9c0-12.4-10.7-23.1-24-23.1z\"\/><\/svg><\/span><span class=\"cbran-stt-stop-wrap absolute inset-0 flex items-center justify-center pointer-events-none\" aria-hidden=\"true\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" viewBox=\"0 0 24 24\" class=\"cbran-stt-stop-icon w-5 h-5\" fill=\"currentColor\" aria-hidden=\"true\"><rect x=\"5\" y=\"5\" width=\"14\" height=\"14\" rx=\"2.5\"><\/rect><\/svg><\/span><svg class=\"cbran-stt-ring\" viewBox=\"0 0 100 100\" aria-hidden=\"true\"><circle class=\"cbran-stt-ring-bg\" cx=\"50\" cy=\"50\" r=\"40\" fill=\"none\" \/><circle class=\"cbran-stt-ring-progress\" cx=\"50\" cy=\"50\" r=\"40\" fill=\"none\" transform=\"rotate(-90 50 50)\" \/><\/svg><\/div><\/div><\/div><\/div>                                                <div class=\"pt-4\">\n                            <button type=\"submit\" class=\"w-full py-2 px-4 bg-blue-600 hover:bg-blue-700 text-white rounded-md font-medium\">Submit Form<\/button>\n                        <\/div>\n                                                                <\/form>\n                                    <\/div>\n                <!-- Success Message (initially hidden) -->\n                <div id=\"cbran-success-message-10837\" style=\"display: none;\" class=\"text-center py-8\">\n                    <div class=\"inline-flex items-center justify-center w-16 h-16 bg-green-100 rounded-full mb-4\">\n                        <svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"32\" height=\"32\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\" class=\"text-green-600\">\n                            <polyline points=\"20 6 9 17 4 12\"><\/polyline>\n                        <\/svg>\n                    <\/div>\n                                        <p class=\"text-lg text-green-600 font-medium mb-2\">Submitted Successfully!<\/p>\n                    <p class=\"text-sm text-gray-600\">Thank you! Your submission has been received.<\/p>\n                <\/div>\n            <\/div>\n        <\/div>\n        \n        <script>\n        jQuery(document).ready(function($) {\n            \/\/ Check if showNotification exists (from admin panel)\n            if (typeof showNotification === 'undefined') {\n                \/\/ Define showNotification for frontend if it doesn't exist\n                window.showNotification = function(message, type = 'success') {\n                    let container = $('#cbran-notification-container');\n                    if (!container.length) {\n                        $('body').append('<div id=\"cbran-notification-container\"><\/div>');\n                        container = $('#cbran-notification-container');\n                    }\n                    if (container.length) document.body.appendChild(container[0]);\n                    const successIcon = `<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\" class=\"w-5 h-5\"><path d=\"M22 11.08V12a10 10 0 1 1-5.93-9.14\"><\/path><polyline points=\"22 4 12 14.01 9 11.01\"><\/polyline><\/svg>`;\n                    const errorIcon = `<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\" class=\"w-5 h-5\"><circle cx=\"12\" cy=\"12\" r=\"10\"><\/circle><line x1=\"12\" y1=\"8\" x2=\"12\" y2=\"12\"><\/line><line x1=\"12\" y1=\"16\" x2=\"12.01\" y2=\"16\"><\/line><\/svg>`;\n                    const notification = $(`<div class=\"cbran-notification ${type} fixed top-4 right-4 flex items-center gap-3 p-4 rounded-lg shadow-lg ${type === 'success' ? 'bg-green-50 text-green-800' : 'bg-red-50 text-red-800'}\" style=\"min-width: 300px; z-index: 2147483647;\">${type === 'success' ? successIcon : errorIcon}<p class=\"text-sm font-medium\">${message}<\/p><\/div>`);\n                    container.append(notification);\n                    setTimeout(() => {\n                        notification.fadeOut(400, function() { $(this).remove(); });\n                    }, 5000);\n                };\n            }\n            \n            \/\/ Initialize multi-file fields with gallery preview\n            (function initCbranFileGallery() {\n                $('#cbran-form-wrapper-10837 form').each(function() {\n                var form = $(this);\n                form.find('.cbran-multi-file-field').each(function() {\n                    var $wrap = $(this);\n                    var $input = $wrap.find('.cbran-file-input');\n                    var $gallery = $wrap.find('.cbran-file-gallery');\n                    var $accordion = $gallery.closest('.cbran-file-gallery-accordion');\n\n                    function renderPreviews() {\n                        $gallery.empty();\n                        var files = $input[0].files || [];\n                        $accordion.toggleClass('is-open', files.length > 0);\n                        for (var i = 0; i < files.length; i++) {\n                            (function(idx) {\n                                var file = files[idx];\n                                var $item = $('<div class=\"cbran-file-preview-item\"><\/div>');\n                                if (file.type && file.type.indexOf('image\/') === 0) {\n                                    var reader = new FileReader();\n                                    reader.onload = function(e) {\n                                        $item.html('<img decoding=\"async\" src=\"' + e.target.result + '\" class=\"cbran-file-thumb\" alt=\"\"><button type=\"button\" class=\"cbran-file-remove\" data-index=\"' + idx + '\" aria-label=\"Remove\">\u00d7<\/button>');\n                                        $gallery.append($item);\n                                    };\n                                    reader.readAsDataURL(file);\n                                } else {\n                                    var safeName = (file.name || '').replace(\/<\/g, '&lt;').replace(\/>\/g, '&gt;');\n                                    $item.html('<div class=\"cbran-file-doc\"><span class=\"cbran-file-icon\" aria-hidden=\"true\">\ud83d\udcc4<\/span><span class=\"cbran-file-name\">' + safeName + '<\/span><\/div><button type=\"button\" class=\"cbran-file-remove\" data-index=\"' + idx + '\" aria-label=\"Remove\">\u00d7<\/button>');\n                                    $gallery.append($item);\n                                }\n                            })(i);\n                        }\n                    }\n\n                    $input.on('change', function() {\n                        var currentFiles = $input.data('cbranCurrentFiles') || [];\n                        var newFiles = Array.prototype.slice.call(this.files || []);\n                        var combined = currentFiles.concat(newFiles);\n                        $input.data('cbranCurrentFiles', combined);\n\n                        var dt = new DataTransfer();\n                        combined.forEach(function(f) { dt.items.add(f); });\n                        this.files = dt.files;\n                        renderPreviews();\n                    });\n\n                    $gallery.on('click', '.cbran-file-remove', function(e) {\n                        e.preventDefault();\n                        var index = parseInt($(this).data('index'), 10);\n                        var currentFiles = $input.data('cbranCurrentFiles') || Array.prototype.slice.call($input[0].files || []);\n                        var newFiles = currentFiles.filter(function(_, i) { return i !== index; });\n                        $input.data('cbranCurrentFiles', newFiles);\n\n                        var dt = new DataTransfer();\n                        newFiles.forEach(function(f) { dt.items.add(f); });\n                        $input[0].files = dt.files;\n                        renderPreviews();\n                    });\n                });\n                });\n            })();\n\n            (function initCbranFormDatePickers() {\n                var root = document.getElementById('cbran-form-wrapper-10837');\n                if (!root) return;\n                root.querySelectorAll('.cbran-form-date-wrap').forEach(function(wrap) {\n                    var input = wrap.querySelector('input.cbran-form-field-date');\n                    var btn = wrap.querySelector('.cbran-form-date-open-btn');\n                    if (!input) return;\n                    function openPicker() {\n                        if (typeof input.showPicker === 'function') {\n                            try {\n                                input.showPicker();\n                            } catch (e) {\n                                input.focus();\n                            }\n                        } else {\n                            input.focus();\n                        }\n                    }\n                    if (btn) {\n                        btn.addEventListener('click', function(e) {\n                            e.preventDefault();\n                            openPicker();\n                        });\n                    }\n                });\n            })();\n\n            (function initCbranSignaturePads() {\n                var formRoot = $('#cbran-form-wrapper-10837');\n                function syncCbranSignaturePads($scope) {\n                    if (!$scope || !$scope.length) return;\n                    $scope.find('.cbran-signature-field').each(function() {\n                        var wrap = this;\n                        var canvas = wrap.querySelector('.cbran-signature-canvas');\n                        var input = wrap.querySelector('.cbran-signature-input');\n                        if (!canvas || !input) return;\n                        if (wrap.getAttribute('data-cbran-sig-dirty') === '1') {\n                            try { input.value = canvas.toDataURL('image\/png'); } catch (e) { input.value = ''; }\n                        } else {\n                            input.value = '';\n                        }\n                    });\n                }\n                window.cbranSyncSignaturePadsInForm = syncCbranSignaturePads;\n                formRoot.find('.cbran-signature-field').each(function() {\n                    var wrap = this;\n                    if (wrap.getAttribute('data-cbran-sig-init')) return;\n                    wrap.setAttribute('data-cbran-sig-init', '1');\n                    var canvas = wrap.querySelector('.cbran-signature-canvas');\n                    var clearBtn = wrap.querySelector('.cbran-signature-clear');\n                    if (!canvas) return;\n                    var ctx = canvas.getContext('2d');\n                    function setupCanvas() {\n                        var dpr = window.devicePixelRatio || 1;\n                        var rect = canvas.getBoundingClientRect();\n                        var w = Math.max(280, Math.floor((rect.width > 10 ? rect.width : 400)));\n                        var h = 160;\n                        canvas.style.height = h + 'px';\n                        canvas.width = Math.floor(w * dpr);\n                        canvas.height = Math.floor(h * dpr);\n                        ctx.setTransform(1, 0, 0, 1, 0, 0);\n                        ctx.scale(dpr, dpr);\n                        ctx.fillStyle = '#ffffff';\n                        ctx.fillRect(0, 0, w, h);\n                        ctx.strokeStyle = '#111827';\n                        ctx.lineWidth = 2;\n                        ctx.lineCap = 'round';\n                        ctx.lineJoin = 'round';\n                        wrap.setAttribute('data-cbran-sig-dirty', '0');\n                        var inp = wrap.querySelector('.cbran-signature-input');\n                        if (inp) inp.value = '';\n                    }\n                    setupCanvas();\n                    var drawing = false;\n                    var last = null;\n                    function pos(ev) {\n                        var r = canvas.getBoundingClientRect();\n                        var cx, cy;\n                        if (ev.touches && ev.touches[0]) {\n                            cx = ev.touches[0].clientX - r.left;\n                            cy = ev.touches[0].clientY - r.top;\n                        } else {\n                            cx = ev.clientX - r.left;\n                            cy = ev.clientY - r.top;\n                        }\n                        return { x: cx, y: cy };\n                    }\n                    function startDraw(ev) {\n                        ev.preventDefault();\n                        drawing = true;\n                        last = pos(ev);\n                        wrap.setAttribute('data-cbran-sig-dirty', '1');\n                    }\n                    function moveDraw(ev) {\n                        if (!drawing || !last) return;\n                        ev.preventDefault();\n                        var p = pos(ev);\n                        ctx.beginPath();\n                        ctx.moveTo(last.x, last.y);\n                        ctx.lineTo(p.x, p.y);\n                        ctx.stroke();\n                        last = p;\n                    }\n                    function endDraw() {\n                        drawing = false;\n                        last = null;\n                    }\n                    canvas.addEventListener('mousedown', startDraw);\n                    canvas.addEventListener('mousemove', moveDraw);\n                    canvas.addEventListener('mouseup', endDraw);\n                    canvas.addEventListener('mouseleave', endDraw);\n                    canvas.addEventListener('touchstart', startDraw, { passive: false });\n                    canvas.addEventListener('touchmove', moveDraw, { passive: false });\n                    canvas.addEventListener('touchend', endDraw);\n                    if (clearBtn) {\n                        clearBtn.addEventListener('click', function(e) {\n                            e.preventDefault();\n                            setupCanvas();\n                        });\n                    }\n                });\n            })();\n\n            (function initCbranTextareaSpeechToText() {\n                var SR = window.SpeechRecognition || window.webkitSpeechRecognition;\n                if (!SR) {\n                    $('.cbran-stt-btn-container').addClass('cbran-stt-unsupported').attr('hidden', 'hidden').removeAttr('tabindex').removeAttr('role');\n                    return;\n                }\n                if (window.cbranSttGlobalInit) {\n                    return;\n                }\n                window.cbranSttGlobalInit = true;\n                var CBRAN_STT_MAX_RECORD_MS = 60000;\n                var state = { recognition: null, $btn: null, base: '', finalChunk: '', targetId: null, intentionalStop: false, recordLimitTimer: null };\n\n                function clearRecordLimitTimer() {\n                    if (state.recordLimitTimer) {\n                        clearTimeout(state.recordLimitTimer);\n                        state.recordLimitTimer = null;\n                    }\n                }\n\n                function getTargetTextarea($btn) {\n                    var id = $btn.attr('data-cbran-stt-target');\n                    if (!id) return null;\n                    var el = document.getElementById(id);\n                    return el && el.tagName === 'TEXTAREA' ? el : null;\n                }\n\n                function clearCountdownState($btn) {\n                    if (!$btn || !$btn.length) return;\n                    $btn.removeData('cbranSttCdGen');\n                    var tm = $btn.data('cbranSttCdTimer');\n                    if (tm) {\n                        clearTimeout(tm);\n                    }\n                    $btn.removeData('cbranSttCdTimer');\n                    $btn.removeClass('is-countdown');\n                    $btn.find('.cbran-stt-countdown').text('').attr('aria-hidden', 'true');\n                }\n\n                function setListening($btn, on) {\n                    $btn.toggleClass('is-listening', on);\n                    $btn.attr('aria-pressed', on ? 'true' : 'false');\n                    var stopL = $btn.attr('data-cbran-stt-stop-label') || '';\n                    var startAttr = $btn.attr('data-cbran-stt-start-label') || '';\n                    if (on && stopL) {\n                        $btn.attr('aria-label', stopL);\n                    } else if (!on) {\n                        if ($btn.data('cbranSttStartLabel')) {\n                            $btn.attr('aria-label', $btn.data('cbranSttStartLabel'));\n                        } else if (startAttr) {\n                            $btn.attr('aria-label', startAttr);\n                        }\n                    }\n                }\n\n                function stopStt() {\n                    clearRecordLimitTimer();\n                    state.intentionalStop = true;\n                    var prevBtn = state.$btn;\n                    if (prevBtn && prevBtn.length) {\n                        clearCountdownState(prevBtn);\n                    }\n                    if (state.recognition) {\n                        try { state.recognition.stop(); } catch (e) {}\n                    }\n                    state.recognition = null;\n                    state.$btn = null;\n                    state.targetId = null;\n                    state.base = '';\n                    state.finalChunk = '';\n                    if (prevBtn && prevBtn.length) {\n                        setListening(prevBtn, false);\n                    }\n                }\n\n                function runCountdown($btn, done) {\n                    var gen = Date.now() + Math.random();\n                    $btn.data('cbranSttCdGen', gen);\n                    $btn.addClass('is-countdown');\n                    var $cd = $btn.find('.cbran-stt-countdown');\n                    var cdTpl = $btn.attr('data-cbran-stt-countdown-aria') || '';\n                    var cancelL = $btn.attr('data-cbran-stt-cancel-label') || '';\n                    if (cancelL) {\n                        $btn.attr('aria-label', cancelL);\n                    }\n                    var nums = [3, 2, 1];\n                    var step = 0;\n                    function tick() {\n                        if ($btn.data('cbranSttCdGen') !== gen) {\n                            return;\n                        }\n                        if (step >= nums.length) {\n                            clearCountdownState($btn);\n                            var sl = $btn.attr('data-cbran-stt-start-label') || '';\n                            if (sl) {\n                                $btn.attr('aria-label', sl);\n                            }\n                            done();\n                            return;\n                        }\n                        var n = nums[step];\n                        $cd.text(String(n)).attr('aria-hidden', 'false');\n                        if (cdTpl) {\n                            $btn.attr('aria-label', cdTpl.split('%s').join(String(n)));\n                        }\n                        step++;\n                        $btn.data('cbranSttCdTimer', setTimeout(tick, 1000));\n                    }\n                    tick();\n                }\n\n                function startStt($btn) {\n                    var ta = getTargetTextarea($btn);\n                    if (!ta) return;\n                    if (state.$btn && state.$btn.length && state.$btn[0] !== $btn[0]) {\n                        stopStt();\n                    }\n                    if (!$btn.data('cbranSttStartLabel')) {\n                        $btn.data('cbranSttStartLabel', $btn.attr('data-cbran-stt-start-label') || $btn.attr('aria-label') || '');\n                    }\n                    clearCountdownState($btn);\n                    state.intentionalStop = false;\n                    state.$btn = $btn;\n                    state.targetId = ta.id;\n                    state.base = ta.value;\n                    state.finalChunk = '';\n                    var rec;\n                    try {\n                        rec = new SR();\n                    } catch (e) {\n                        if (typeof showNotification === 'function') {\n                            showNotification(\"Voice input is not available in this browser.\", 'error');\n                        }\n                        return;\n                    }\n                    rec.continuous = true;\n                    rec.interimResults = true;\n                    rec.lang = $btn.attr('data-lang') || (document.documentElement.lang || 'en-US').replace('_', '-');\n                    rec.onresult = function(event) {\n                        var interim = '';\n                        var fin = state.finalChunk;\n                        for (var i = event.resultIndex; i < event.results.length; i++) {\n                            var t = event.results[i][0].transcript;\n                            if (event.results[i].isFinal) {\n                                fin += t;\n                            } else {\n                                interim += t;\n                            }\n                        }\n                        state.finalChunk = fin;\n                        ta.value = state.base + fin + interim;\n                        try {\n                            ta.dispatchEvent(new Event('input', { bubbles: true }));\n                        } catch (e) {}\n                    };\n                    rec.onerror = function(ev) {\n                        if (ev && ev.error === 'not-allowed') {\n                            if (typeof showNotification === 'function') {\n                                showNotification(\"Microphone permission denied. Allow access to use voice input.\", 'error');\n                            }\n                        }\n                        stopStt();\n                    };\n                    rec.onend = function() {\n                        if (state.intentionalStop || !state.$btn || state.$btn[0] !== $btn[0]) {\n                            setListening($btn, false);\n                            return;\n                        }\n                        try {\n                            rec.start();\n                        } catch (e) {\n                            setListening($btn, false);\n                            state.recognition = null;\n                            state.$btn = null;\n                        }\n                    };\n                    state.recognition = rec;\n                    setListening($btn, true);\n                    try {\n                        rec.start();\n                        clearRecordLimitTimer();\n                        state.recordLimitTimer = setTimeout(function() {\n                            state.recordLimitTimer = null;\n                            if (!state.$btn || !state.$btn.length || state.$btn[0] !== $btn[0]) {\n                                return;\n                            }\n                            if (typeof showNotification === 'function') {\n                                showNotification(\"Voice input stopped: maximum duration is 1 minute.\", 'success');\n                            }\n                            stopStt();\n                        }, CBRAN_STT_MAX_RECORD_MS);\n                    } catch (e) {\n                        clearRecordLimitTimer();\n                        setListening($btn, false);\n                        state.recognition = null;\n                        state.$btn = null;\n                        if (typeof showNotification === 'function') {\n                            showNotification(\"Could not start voice input.\", 'error');\n                        }\n                    }\n                }\n\n                $(document).on('click', '.cbran-stt-btn-container', function(e) {\n                    e.preventDefault();\n                    var $btn = $(this);\n                    if ($btn.hasClass('cbran-stt-unsupported')) return;\n                    if ($btn.hasClass('is-countdown')) {\n                        clearCountdownState($btn);\n                        var sl0 = $btn.attr('data-cbran-stt-start-label') || '';\n                        if (sl0) {\n                            $btn.attr('aria-label', sl0);\n                        }\n                        return;\n                    }\n                    if ($btn.hasClass('is-listening')) {\n                        stopStt();\n                        return;\n                    }\n                    runCountdown($btn, function() {\n                        startStt($btn);\n                    });\n                });\n                $(document).on('keydown', '.cbran-stt-btn-container', function(e) {\n                    if (e.key !== 'Enter' && e.key !== ' ') return;\n                    e.preventDefault();\n                    $(this).trigger('click');\n                });\n            })();\n\n            (function initCbranFormEventItineraryFields() {\n                var formWrapper = $('#cbran-form-wrapper-10837');\n                function escOpt(s) {\n                    return $('<div>').text(s == null ? '' : String(s)).html();\n                }\n                function updateHidden($wrap) {\n                    var $ev = $wrap.find('.cbran-ei-event-select');\n                    var $sec = $wrap.find('.cbran-ei-section-select');\n                    var $hid = $wrap.find('.cbran-event-itinerary-json');\n                    if (!$ev.length || !$hid.length) return;\n                    var eid = parseInt($ev.val(), 10) || 0;\n                    var sid = '';\n                    \/\/ Use data flag, not :visible \u2014 section UI may be inside display:none (e.g. another card step).\n                    var hasSecs = String($wrap.attr('data-cbran-ei-has-sections') || '0') === '1';\n                    if (hasSecs && $sec.length) {\n                        sid = String($sec.val() || '');\n                    }\n                    if (eid <= 0) {\n                        $hid.val('');\n                        return;\n                    }\n                    $hid.val(JSON.stringify({ event_id: eid, section_id: sid }));\n                }\n                function syncAll($scope) {\n                    if (!$scope || !$scope.length) return;\n                    $scope.find('.cbran-event-itinerary-field').each(function() {\n                        updateHidden($(this));\n                    });\n                }\n                window.cbranSyncEventItineraryFieldsInForm = syncAll;\n                function loadEventsForWrap($wrap) {\n                    if (typeof cbran_ajax === 'undefined') return;\n                    var formId = $wrap.data('form-id');\n                    var $ev = $wrap.find('.cbran-ei-event-select');\n                    $ev.prop('disabled', true);\n                    $.post(cbran_ajax.ajax_url, {\n                        action: 'cbran_get_form_events_for_itinerary_select',\n                        nonce: cbran_ajax.nonce,\n                        form_id: formId\n                    }).done(function(res) {\n                        $ev.prop('disabled', false);\n                        var opts = '<option value=\"\">' + escOpt(\"Select an event\\u2026\") + '<\/option>';\n                        if (res && res.success && res.data && res.data.events && res.data.events.length) {\n                            res.data.events.forEach(function(ev) {\n                                var optLabel = (ev.label != null && String(ev.label).trim() !== '') ? ev.label : ev.title;\n                                opts += '<option value=\"' + String(parseInt(ev.id, 10) || 0) + '\">' + escOpt(optLabel) + '<\/option>';\n                            });\n                        }\n                        $ev.html(opts);\n                        $wrap.attr('data-cbran-ei-has-sections', '0');\n                        $wrap.find('.cbran-ei-section-wrap').hide();\n                        $wrap.find('.cbran-ei-section-select').html('<option value=\"\">' + escOpt(\"Select a section\\u2026\") + '<\/option>');\n                        updateHidden($wrap);\n                    }).fail(function() {\n                        $ev.prop('disabled', false);\n                        $ev.html('<option value=\"\">' + escOpt(\"Could not load events.\") + '<\/option>');\n                    });\n                }\n                function bindWrap($wrap) {\n                    if ($wrap.data('cbranEiInit')) return;\n                    $wrap.data('cbranEiInit', 1);\n                    loadEventsForWrap($wrap);\n                    $wrap.on('change.cbranEi', '.cbran-ei-event-select', function() {\n                        var eid = parseInt($(this).val(), 10) || 0;\n                        var $sw = $wrap.find('.cbran-ei-section-wrap');\n                        var $ss = $wrap.find('.cbran-ei-section-select');\n                        if (eid <= 0) {\n                            $wrap.attr('data-cbran-ei-has-sections', '0');\n                            $sw.hide();\n                            $ss.html('<option value=\"\">' + escOpt(\"Select a section\\u2026\") + '<\/option>');\n                            updateHidden($wrap);\n                            return;\n                        }\n                        if (typeof cbran_ajax === 'undefined') return;\n                        $ss.prop('disabled', true);\n                        $.post(cbran_ajax.ajax_url, {\n                            action: 'cbran_get_form_event_itinerary_sections_for_select',\n                            nonce: cbran_ajax.nonce,\n                            form_id: $wrap.data('form-id'),\n                            event_id: eid\n                        }).done(function(res) {\n                            $ss.prop('disabled', false);\n                            var list = (res && res.success && res.data && res.data.sections) ? res.data.sections : [];\n                            var o = '<option value=\"\">' + escOpt(\"Select a section\\u2026\") + '<\/option>';\n                            list.forEach(function(s) {\n                                var vid = String(s.id || '').replace(\/\"\/g, '&quot;');\n                                o += '<option value=\"' + vid + '\">' + escOpt(s.label || s.id) + '<\/option>';\n                            });\n                            $ss.html(o);\n                            $wrap.attr('data-cbran-ei-has-sections', list.length > 0 ? '1' : '0');\n                            if (list.length > 0) {\n                                $sw.show();\n                            } else {\n                                $sw.hide();\n                            }\n                            updateHidden($wrap);\n                        }).fail(function() {\n                            $ss.prop('disabled', false);\n                            $wrap.attr('data-cbran-ei-has-sections', '0');\n                            $sw.hide();\n                            updateHidden($wrap);\n                        });\n                    });\n                    $wrap.on('change.cbranEi', '.cbran-ei-section-select', function() {\n                        updateHidden($wrap);\n                    });\n                }\n                window.cbranReinitEventItineraryFields = function($root) {\n                    if (!$root || !$root.length) return;\n                    $root.find('.cbran-event-itinerary-field').each(function() {\n                        var $w = $(this);\n                        $w.removeData('cbranEiInit');\n                        $w.off('.cbranEi');\n                        bindWrap($w);\n                    });\n                };\n                formWrapper.find('.cbran-event-itinerary-field').each(function() {\n                    bindWrap($(this));\n                });\n            })();\n\n            (function initCbranFormEventOnlyFields() {\n                var formWrapperEv = $('#cbran-form-wrapper-10837');\n                function escOptEv(s) {\n                    return $('<div>').text(s == null ? '' : String(s)).html();\n                }\n                function loadEvOnlySelect($wrap) {\n                    if (typeof cbran_ajax === 'undefined') return;\n                    var formId = $wrap.data('form-id');\n                    var $sel = $wrap.find('.cbran-ev-event-select');\n                    if (!$sel.length) return;\n                    $sel.prop('disabled', true);\n                    $.post(cbran_ajax.ajax_url, {\n                        action: 'cbran_get_form_events_for_itinerary_select',\n                        nonce: cbran_ajax.nonce,\n                        form_id: formId\n                    }).done(function(res) {\n                        $sel.prop('disabled', false);\n                        var opts = '<option value=\"\">' + escOptEv(\"Select an event\\u2026\") + '<\/option>';\n                        if (res && res.success && res.data && res.data.events && res.data.events.length) {\n                            res.data.events.forEach(function(ev) {\n                                var optLabel = (ev.label != null && String(ev.label).trim() !== '') ? ev.label : ev.title;\n                                opts += '<option value=\"' + String(parseInt(ev.id, 10) || 0) + '\">' + escOptEv(optLabel) + '<\/option>';\n                            });\n                        }\n                        $sel.html(opts);\n                    }).fail(function() {\n                        $sel.prop('disabled', false);\n                        $sel.html('<option value=\"\">' + escOptEv(\"Could not load events.\") + '<\/option>');\n                    });\n                }\n                function bindEvWrap($wrap) {\n                    if ($wrap.data('cbranEvOnlyInit')) return;\n                    $wrap.data('cbranEvOnlyInit', 1);\n                    loadEvOnlySelect($wrap);\n                }\n                window.cbranReinitEventOnlyFields = function($root) {\n                    if (!$root || !$root.length) return;\n                    $root.find('.cbran-event-select-field').each(function() {\n                        var $w = $(this);\n                        $w.removeData('cbranEvOnlyInit');\n                        bindEvWrap($w);\n                    });\n                };\n                formWrapperEv.find('.cbran-event-select-field').each(function() {\n                    bindEvWrap($(this));\n                });\n            })();\n\n            \/\/ SMS link consent: enable\/disable phone input and Send button based on consent\n            $(document).on('change', '.cbran-sms-link-consent-checkbox', function() {\n                var formId = $(this).data('form-id');\n                var consentChecked = $(this).prop('checked');\n                $(this).closest('.cbran-toggle-switch').toggleClass('active', consentChecked);\n                var $phoneInput = $('#cbran-sms-link-phone-' + formId);\n                var $btn = $('.cbran-send-form-link-sms-btn[data-form-id=\"' + formId + '\"]');\n                $btn.prop('disabled', !consentChecked);\n                $phoneInput.prop('disabled', !consentChecked);\n                if (!consentChecked) {\n                    $phoneInput.val('');\n                    $('#cbran-sms-link-message-' + formId).addClass('hidden');\n                }\n            });\n            $('.cbran-sms-link-consent-checkbox').each(function() {\n                $(this).trigger('change');\n            });\n            \n            \/\/ Close SMS link box (show reopen link)\n            $(document).on('click', '.cbran-sms-link-box-close', function() {\n                var formId = $(this).data('form-id');\n                $('#cbran-sms-link-box-' + formId).addClass('hidden');\n                $('#cbran-sms-link-reopen-' + formId).removeClass('hidden');\n            });\n            \/\/ Reopen SMS link box\n            $(document).on('click', '.cbran-sms-link-reopen button', function() {\n                var formId = $(this).closest('.cbran-sms-link-reopen').attr('id').replace('cbran-sms-link-reopen-', '');\n                $('#cbran-sms-link-box-' + formId).removeClass('hidden');\n                $('#cbran-sms-link-reopen-' + formId).addClass('hidden');\n            });\n            \/\/ Auto-hide SMS box when user types 3+ characters in any form field (text inputs, textarea, or select option)\n            var formIdSms = 10837;\n            $('#cbran-frontend-form-10837').on('input change', 'input[type=\"text\"], input[type=\"email\"], input[type=\"tel\"]:not([id^=\"cbran-sms-link-phone\"]), input[type=\"number\"], input[type=\"url\"], input[type=\"search\"], textarea, select', function() {\n                var val = $(this).val();\n                if (val != null && String(val).trim().length >= 3) {\n                    $('#cbran-sms-link-box-' + formIdSms).addClass('hidden');\n                    $('#cbran-sms-link-reopen-' + formIdSms).removeClass('hidden');\n                }\n            });\n            \n            \/\/ Send form link via SMS (mobile)\n            $(document).on('click', '.cbran-send-form-link-sms-btn', function() {\n                var btn = $(this);\n                var formId = btn.data('form-id');\n                if (btn.prop('disabled')) return;\n                var consentChecked = $('#cbran-sms-link-consent-' + formId).prop('checked');\n                if (!consentChecked) {\n                    $('#cbran-sms-link-message-' + formId).removeClass('hidden text-green-600').addClass('text-red-600').text('Please agree to receive text messages first.').show();\n                    return;\n                }\n                var phoneInput = $('#cbran-sms-link-phone-' + formId);\n                var msgEl = $('#cbran-sms-link-message-' + formId);\n                var phone = (phoneInput.val() || '').trim();\n                if (!phone) {\n                    msgEl.removeClass('hidden text-green-600').addClass('text-red-600').text('Please enter your phone number.').show();\n                    return;\n                }\n                if (typeof cbran_ajax === 'undefined') {\n                    msgEl.removeClass('hidden text-green-600').addClass('text-red-600').text('Unable to send. Please refresh the page.').show();\n                    return;\n                }\n                btn.prop('disabled', true);\n                msgEl.addClass('hidden').removeClass('text-red-600 text-green-600');\n                $.post(cbran_ajax.ajax_url, {\n                    action: 'cbran_send_form_link_sms',\n                    nonce: cbran_ajax.nonce,\n                    form_id: formId,\n                    phone: phone,\n                    form_url: window.location.href\n                }).done(function(res) {\n                    if (res.success && res.data && res.data.message) {\n                        msgEl.removeClass('hidden').addClass('text-green-600').text(res.data.message).show();\n                        phoneInput.val('');\n                        var postSubmitAction = 'reload';\n                        var redirectUrl = '';\n                        var actionDelay = parseInt('3', 10) * 1000;\n                        if (postSubmitAction === 'redirect' && redirectUrl) {\n                            setTimeout(function() { window.location.href = redirectUrl; }, actionDelay);\n                        } else if (postSubmitAction === 'reload') {\n                            setTimeout(function() { location.reload(); }, actionDelay);\n                        }\n                    } else {\n                        msgEl.removeClass('hidden').addClass('text-red-600').text(res.data || 'Something went wrong.').show();\n                    }\n                }).fail(function(xhr) {\n                    var err = (xhr.responseJSON && xhr.responseJSON.data) ? xhr.responseJSON.data : 'Request failed. Please try again.';\n                    msgEl.removeClass('hidden').addClass('text-red-600').text(err).show();\n                }).always(function() {\n                    var consentOk = $('#cbran-sms-link-consent-' + formId).prop('checked');\n                    btn.prop('disabled', !consentOk);\n                });\n            });\n            \n            \/\/ Conditional field visibility + multi-step branch navigation (page breaks)\n            var formEl = $('#cbran-frontend-form-10837');\n            (function () {\n                if (!formEl.length) return;\n                function escFieldName(name) {\n                    return String(name || '').replace(\/\\\\\/g, '\\\\\\\\').replace(\/\"\/g, '\\\\\"');\n                }\n                function getDomVal($form, name) {\n                    if (!name) return '';\n                    var sel = '[name=\"' + escFieldName(name) + '\"]';\n                    var $els = $form.find(sel);\n                    if (!$els.length && String(name).indexOf('[') === -1) {\n                        $els = $form.find('[name=\"' + escFieldName(name) + '[]\"]');\n                    }\n                    if (!$els.length) return '';\n                    var $first = $els.first();\n                    var tp = ($first.attr('type') || '').toLowerCase();\n                    if (tp === 'radio') {\n                        var $chk = $form.find('[name=\"' + escFieldName(name) + '\"]:checked');\n                        return $chk.length ? $chk.val() : '';\n                    }\n                    if (tp === 'checkbox') {\n                        var nm = $first.attr('name') || '';\n                        if ($els.length > 1 || nm.indexOf('[]') !== -1) {\n                            return $els.filter(':checked').map(function () { return $(this).val(); }).get();\n                        }\n                        return $first.prop('checked') ? $first.val() : '';\n                    }\n                    if ($first.is('select')) return $first.val() || '';\n                    if ($first.is('textarea')) return $first.val() || '';\n                    return $first.val() || '';\n                }\n                function normVal(v) {\n                    if (v == null) return '';\n                    if (Array.isArray(v)) return v.join(',');\n                    return String(v);\n                }\n                function evalSingleCondition($form, rule) {\n                    if (!rule || !rule.when_field) return false;\n                    var op = rule.op ? String(rule.op) : 'equals';\n                    var expect = rule.value != null ? String(rule.value) : '';\n                    var raw = getDomVal($form, String(rule.when_field));\n                    var s = normVal(raw).trim();\n                    var lowExp = expect.toLowerCase();\n                    var lowS = s.toLowerCase();\n                    if (op === 'empty') return s === '';\n                    if (op === 'not_empty') return s !== '';\n                    if (op === 'contains') return lowS.indexOf(lowExp) !== -1;\n                    if (op === 'not_equals') return lowS !== lowExp;\n                    return lowS === lowExp;\n                }\n                function evalConditionBundle($form, bundle) {\n                    if (!bundle) return false;\n                    if (bundle.when_field) {\n                        return evalSingleCondition($form, bundle);\n                    }\n                    var matchAny = bundle.match === 'any';\n                    var conds = bundle.conditions || [];\n                    if (!conds.length) return false;\n                    var i, ok = [];\n                    for (i = 0; i < conds.length; i++) {\n                        ok.push(evalSingleCondition($form, conds[i]));\n                    }\n                    if (matchAny) {\n                        for (i = 0; i < ok.length; i++) { if (ok[i]) return true; }\n                        return false;\n                    }\n                    for (i = 0; i < ok.length; i++) { if (!ok[i]) return false; }\n                    return true;\n                }\n                function jumpRuleMatches($form, rule) {\n                    if (!rule || rule.goto_step === undefined || rule.goto_step === null) return false;\n                    var payload = {};\n                    for (var k in rule) {\n                        if (rule.hasOwnProperty(k) && k !== 'goto_step') {\n                            payload[k] = rule[k];\n                        }\n                    }\n                    return evalConditionBundle($form, payload);\n                }\n                function applyFieldVisibility($form) {\n                    $form.find('.form-field.cbran-form-field--conditional').each(function () {\n                        var $row = $(this);\n                        var raw = $row.attr('data-cbran-show-when');\n                        var rule = null;\n                        try { rule = raw ? JSON.parse(raw) : null; } catch (eR) { rule = null; }\n                        var ok = rule ? evalConditionBundle($form, rule) : true;\n                        $row.toggleClass('cbran-hidden-by-logic', !ok);\n                        $row.find('input,select,textarea').each(function () {\n                            var $i = $(this);\n                            if (!ok) {\n                                if (!$i.data('cbranHadReq')) {\n                                    $i.data('cbranHadReq', $i.prop('required') ? 1 : 0);\n                                }\n                                $i.prop('required', false).prop('disabled', true);\n                            } else {\n                                $i.prop('disabled', false);\n                                if ($i.data('cbranHadReq')) {\n                                    $i.prop('required', true);\n                                }\n                            }\n                        });\n                    });\n                    $form.find('.cbran-logic-pending').removeClass('cbran-logic-pending');\n                }\n                applyFieldVisibility(formEl);\n                formEl.on('input change', 'input, select, textarea', function () {\n                    applyFieldVisibility(formEl);\n                });\n\n                if (formEl.data('form-layout') === 'cards' || formEl.data('form-layout') === 'pagebreaks') {\n                var nav = formEl.find('.cbran-form-card-nav');\n                var cards = formEl.find('.cbran-form-card');\n                var totalCards = cards.length;\n                var currentCardIndex = 0;\n                var pbNavLabels = [];\n                try {\n                    var pbRaw = $('#cbran-pagebreak-nav-10837').text();\n                    if (pbRaw) { pbNavLabels = JSON.parse(pbRaw); }\n                } catch (ePb) { pbNavLabels = []; }\n                var layoutKind = formEl.data('form-layout');\n                var jumpMatrix = [];\n                try {\n                    if (layoutKind === 'pagebreaks') {\n                        var pj = $('#cbran-pagebreak-jumps-10837').text();\n                        if (pj) { jumpMatrix = JSON.parse(pj); }\n                    } else if (layoutKind === 'cards') {\n                        var cj = $('#cbran-card-jumps-10837').text();\n                        if (cj) { jumpMatrix = JSON.parse(cj); }\n                    }\n                } catch (eJm) { jumpMatrix = []; }\n                var stepHistory = [0];\n\n                function computeNextStep(cur) {\n                    if ((layoutKind !== 'pagebreaks' && layoutKind !== 'cards') || !jumpMatrix.length) {\n                        return Math.min(cur + 1, totalCards - 1);\n                    }\n                    var rules = jumpMatrix[cur] || [];\n                    for (var ri = 0; ri < rules.length; ri++) {\n                        if (jumpRuleMatches(formEl, rules[ri])) {\n                            var g = parseInt(rules[ri].goto_step, 10);\n                            if (isFinite(g)) {\n                                return Math.max(0, Math.min(totalCards - 1, g));\n                            }\n                        }\n                    }\n                    return Math.min(cur + 1, totalCards - 1);\n                }\n\n                function showCard(index) {\n                    cards.hide().eq(index).show();\n                    currentCardIndex = index;\n                    nav.find('.cbran-form-card-back').toggle(stepHistory.length > 1);\n                    nav.find('.cbran-form-card-next').toggle(index < totalCards - 1);\n                    nav.find('.cbran-form-card-submit').toggle(index === totalCards - 1);\n                    if (formEl.data('form-layout') === 'pagebreaks' && pbNavLabels.length === totalCards) {\n                        var nl = pbNavLabels[index];\n                        var backTxt = \"Back\";\n                        var nextTxt = \"Continue\";\n                        if (nl && nl.back) {\n                            nav.find('.cbran-form-card-back').text(nl.back);\n                        } else {\n                            nav.find('.cbran-form-card-back').text(backTxt);\n                        }\n                        if (nl && nl.next) {\n                            nav.find('.cbran-form-card-next').text(nl.next);\n                        } else {\n                            nav.find('.cbran-form-card-next').text(nextTxt);\n                        }\n                    }\n                    applyFieldVisibility(formEl);\n                }\n\n                function validateCurrentCard() {\n                    if (typeof window.cbranSyncSignaturePadsInForm === 'function') window.cbranSyncSignaturePadsInForm(formEl);\n                    if (typeof window.cbranSyncEventItineraryFieldsInForm === 'function') window.cbranSyncEventItineraryFieldsInForm(formEl);\n                    var card = cards.eq(currentCardIndex);\n                    var valid = true;\n                    formEl.find('.field-error').removeClass('field-error');\n                    formEl.find('.error-message').remove();\n                    card.find('input, textarea, select').css('border-color', '');\n                    card.find('.cbran-signature-canvas').css('border-color', '');\n                    card.find('.cbran-ei-event-select, .cbran-ei-section-select, .cbran-ev-event-select').css('border-color', '');\n                    card.find('[required]').each(function() {\n                        var $f = $(this);\n                        if ($f.closest('.cbran-hidden-by-logic').length) return;\n                        if ($f.prop('disabled')) return;\n                        var empty = !$f.val() || ($f.val() + '').trim() === '';\n                        if ($f.attr('type') === 'checkbox' && $f.closest('[data-required=\"true\"]').length) {\n                            var name = $f.closest('[data-required=\"true\"]').data('field-name');\n                            empty = formEl.find('input[name=\"' + name + '[]\"]:checked').length === 0;\n                        } else if ($f.attr('type') === 'file') { empty = this.files.length === 0; }\n                        else if ($f.attr('type') === 'hidden' && $f.hasClass('cbran-signature-input')) {\n                            empty = !$f.val() || String($f.val()).trim() === '';\n                            if (empty) {\n                                var $cv = $f.closest('.cbran-signature-field').find('.cbran-signature-canvas');\n                                if ($cv.length) $cv.css('border-color', '#ef4444');\n                            }\n                        } else if ($f.attr('type') === 'hidden' && $f.hasClass('cbran-event-itinerary-json')) {\n                            var rawEi = $f.val();\n                            var pEi = null;\n                            try { pEi = rawEi ? JSON.parse(rawEi) : null; } catch (e2) { pEi = null; }\n                            var eidEi = pEi && pEi.event_id ? parseInt(pEi.event_id, 10) : 0;\n                            empty = eidEi <= 0;\n                            var $iwEi = $f.closest('.cbran-event-itinerary-field');\n                            if (!empty && $iwEi.length && String($iwEi.attr('data-cbran-ei-has-sections') || '0') === '1') {\n                                var sidEi = pEi && pEi.section_id ? String(pEi.section_id) : '';\n                                empty = !sidEi;\n                            }\n                            if (empty && $iwEi.length) {\n                                $iwEi.find('.cbran-ei-event-select, .cbran-ei-section-select, .cbran-ev-event-select').css('border-color', '#ef4444');\n                            }\n                        }\n                        if (empty) {\n                            valid = false;\n                            if ($f.attr('type') !== 'hidden' || (!$f.hasClass('cbran-signature-input') && !$f.hasClass('cbran-event-itinerary-json'))) {\n                                $f.css('border-color', '#ef4444');\n                            }\n                            $f.closest('.form-field').find('label').first().after('<p class=\"error-message text-red-600 text-sm mt-1\">' + \"This field is required.\" + '<\/p>');\n                        }\n                    });\n                    card.find('[data-required=\"true\"]').each(function() {\n                        var $g = $(this);\n                        if ($g.closest('.cbran-hidden-by-logic').length) return;\n                        var name = $g.data('field-name');\n                        if (formEl.find('input[name=\"' + name + '[]\"]:checked').length === 0) {\n                            valid = false;\n                            $g.closest('.form-field').find('.error-message').remove().end().find('label').first().after('<p class=\"error-message text-red-600 text-sm mt-1\">' + \"Please select at least one option.\" + '<\/p>');\n                        }\n                    });\n                    return valid;\n                }\n\n                nav.on('click', '.cbran-form-card-next', function() {\n                    if (!validateCurrentCard()) return;\n                    if (currentCardIndex < totalCards - 1) {\n                        var nextIx = computeNextStep(currentCardIndex);\n                        stepHistory.push(nextIx);\n                        showCard(nextIx);\n                    }\n                });\n                nav.on('click', '.cbran-form-card-back', function() {\n                    if (stepHistory.length > 1) {\n                        stepHistory.pop();\n                        showCard(stepHistory[stepHistory.length - 1]);\n                    }\n                });\n                showCard(0);\n                stepHistory = [0];\n                }\n            })();\n\n            $('#cbran-frontend-form-10837').on('submit', function(e) {\n                e.preventDefault();\n                \n                const form = $(this);\n                const submitBtn = form.find('button[type=\"submit\"]');\n                if (typeof window.cbranSyncSignaturePadsInForm === 'function') window.cbranSyncSignaturePadsInForm(form);\n                if (typeof window.cbranSyncEventItineraryFieldsInForm === 'function') window.cbranSyncEventItineraryFieldsInForm(form);\n                \n                \/\/ Validate required fields before submission\n                let isValid = true;\n                let firstInvalidField = null;\n                const requiredFields = form.find('[required]');\n                \n                \/\/ Remove previous error styling\n                form.find('.field-error').removeClass('field-error');\n                form.find('.error-message').remove();\n                form.find('input, textarea, select').css('border-color', '');\n                form.find('.cbran-signature-canvas').css('border-color', '');\n                form.find('.cbran-ei-event-select, .cbran-ei-section-select, .cbran-ev-event-select').css('border-color', '');\n                \n                \/\/ First, check for checkbox groups with data-required attribute\n                form.find('[data-required=\"true\"]').each(function() {\n                    const $group = $(this);\n                    if ($group.closest('.cbran-hidden-by-logic').length) return;\n                    const fieldName = $group.data('field-name');\n                    const checkboxGroup = form.find('input[name=\"' + fieldName + '[]\"]');\n                    if (checkboxGroup.filter(':checked').length === 0) {\n                        isValid = false;\n                        if (!firstInvalidField) {\n                            firstInvalidField = checkboxGroup.first();\n                        }\n                        $group.find('input').first().addClass('field-error');\n                        $group.find('input').first().css('border-color', '#ef4444');\n                        const fieldLabel = $group.closest('.form-field').find('label').text().replace('*', '').trim();\n                        if (!$group.closest('.form-field').find('.error-message').length) {\n                            $group.closest('.form-field').append('<p class=\"error-message text-red-600 text-sm mt-1\">' + fieldLabel + ' is required. Please select at least one option.<\/p>');\n                        }\n                    }\n                });\n                \n                \/\/ Then validate other required fields\n                requiredFields.each(function() {\n                    const $field = $(this);\n                    if ($field.closest('.cbran-hidden-by-logic').length) return true;\n                    if ($field.prop('disabled')) return true;\n                    const fieldType = $field.attr('type');\n                    const fieldName = $field.attr('name');\n                    let isEmpty = false;\n                    \n                    \/\/ Skip checkboxes that are part of a required group (already validated above)\n                    if (fieldType === 'checkbox' && $field.closest('[data-required=\"true\"]').length > 0) {\n                        return true; \/\/ Continue to next field\n                    }\n                    \n                    if (fieldType === 'checkbox') {\n                        \/\/ For standalone checkboxes, check if at least one is checked\n                        const checkboxGroup = form.find('input[name=\"' + fieldName + '\"]');\n                        isEmpty = checkboxGroup.filter(':checked').length === 0;\n                    } else if (fieldType === 'file') {\n                        \/\/ For file inputs, check if a file is selected\n                        isEmpty = this.files.length === 0;\n                    } else if (fieldType === 'hidden' && $field.hasClass('cbran-signature-input')) {\n                        const v = $field.val();\n                        isEmpty = !v || String(v).trim() === '';\n                        if (isEmpty) {\n                            const $cv = $field.closest('.cbran-signature-field').find('.cbran-signature-canvas');\n                            if ($cv.length) $cv.css('border-color', '#ef4444');\n                        }\n                    } else if (fieldType === 'hidden' && $field.hasClass('cbran-event-itinerary-json')) {\n                        const rawEi2 = $field.val();\n                        let pEi2 = null;\n                        try { pEi2 = rawEi2 ? JSON.parse(rawEi2) : null; } catch (e3) { pEi2 = null; }\n                        const eidEi2 = pEi2 && pEi2.event_id ? parseInt(pEi2.event_id, 10) : 0;\n                        isEmpty = eidEi2 <= 0;\n                        const $iwEi2 = $field.closest('.cbran-event-itinerary-field');\n                        if (!isEmpty && $iwEi2.length && String($iwEi2.attr('data-cbran-ei-has-sections') || '0') === '1') {\n                            const sidEi2 = pEi2 && pEi2.section_id ? String(pEi2.section_id) : '';\n                            isEmpty = !sidEi2;\n                        }\n                        if (isEmpty && $iwEi2.length) {\n                            $iwEi2.find('.cbran-ei-event-select, .cbran-ei-section-select, .cbran-ev-event-select').css('border-color', '#ef4444');\n                        }\n                    } else {\n                        \/\/ For other fields, check if value is empty\n                        const value = $field.val();\n                        isEmpty = !value || value.trim() === '';\n                    }\n                    \n                    if (isEmpty) {\n                        isValid = false;\n                        if (!firstInvalidField) {\n                            if ($field.hasClass('cbran-signature-input')) {\n                                firstInvalidField = $field.closest('.cbran-signature-field').find('.cbran-signature-canvas').get(0) || $field;\n                            } else if ($field.hasClass('cbran-event-itinerary-json')) {\n                                firstInvalidField = $field.closest('.cbran-event-itinerary-field').find('.cbran-ei-event-select').get(0) || $field;\n                            } else {\n                                firstInvalidField = $field;\n                            }\n                        }\n                        \n                        \/\/ Add error styling\n                        $field.addClass('field-error');\n                        if (fieldType !== 'hidden' || (!$field.hasClass('cbran-signature-input') && !$field.hasClass('cbran-event-itinerary-json'))) {\n                            $field.css('border-color', '#ef4444');\n                        }\n                        \n                        \/\/ Add error message\n                        const fieldLabel = $field.closest('.form-field').find('label').text().replace('*', '').trim();\n                        if (!$field.closest('.form-field').find('.error-message').length) {\n                            $field.closest('.form-field').append('<p class=\"error-message text-red-600 text-sm mt-1\">' + fieldLabel + ' is required.<\/p>');\n                        }\n                    } else {\n                        \/\/ Remove error styling if field is valid\n                        $field.removeClass('field-error');\n                        $field.css('border-color', '');\n                        $field.closest('.form-field').find('.error-message').remove();\n                    }\n                });\n\n                let subscriptionValidationMsg = '';\n                form.find('.cbran-subscription-field').each(function() {\n                    const $wrap = $(this);\n                    const base = $wrap.attr('data-cbran-field-base');\n                    if (!base) {\n                        return;\n                    }\n                    const reqName = ($wrap.attr('data-cbran-sub-req-name') || '1') === '1';\n                    const anyCh = $wrap.find('input[type=\"checkbox\"][name=\"' + base + '[channels][]\"]:checked').length > 0;\n                    const anySeg = $wrap.find('input[type=\"checkbox\"][name=\"' + base + '[segments][]\"]:checked').length > 0;\n                    if (!anyCh && !anySeg) {\n                        return;\n                    }\n                    const wantEmail = $wrap.find('input[name=\"' + base + '[channels][]\"][value=\"email\"]:checked').length > 0;\n                    const wantSms = $wrap.find('input[name=\"' + base + '[channels][]\"][value=\"sms\"]:checked').length > 0;\n                    const wantWa = $wrap.find('input[name=\"' + base + '[channels][]\"][value=\"whatsapp\"]:checked').length > 0;\n                    let emailVal = '';\n                    form.find('input[type=\"email\"]').each(function() {\n                        const v = ($(this).val() || '').trim();\n                        if (v) {\n                            emailVal = v;\n                            return false;\n                        }\n                    });\n                    let phoneVal = '';\n                    form.find('input[type=\"tel\"],input[type=\"phone\"]').each(function() {\n                        const v = ($(this).val() || '').trim();\n                        if (v) {\n                            phoneVal = v;\n                            return false;\n                        }\n                    });\n                    if (!phoneVal) {\n                        form.find('input[type=\"text\"]').each(function() {\n                            const n = ($(this).attr('name') || '').toLowerCase();\n                            if (n.indexOf('phone') >= 0 || n.indexOf('tel') >= 0 || n.indexOf('movil') >= 0) {\n                                const v = ($(this).val() || '').trim();\n                                if (v) {\n                                    phoneVal = v;\n                                    return false;\n                                }\n                            }\n                        });\n                    }\n                    let nameVal = '';\n                    form.find('input[type=\"text\"]').each(function() {\n                        const v = ($(this).val() || '').trim();\n                        if (v) {\n                            nameVal = v;\n                            return false;\n                        }\n                    });\n                    const onlySeg = !anyCh && anySeg;\n                    if (wantEmail && !emailVal) {\n                        isValid = false;\n                        subscriptionValidationMsg = \"Subscription: add a valid email address for the Email channel you selected.\";\n                        if (!firstInvalidField) {\n                            firstInvalidField = $wrap;\n                        }\n                    }\n                    if ((wantSms || wantWa) && !phoneVal) {\n                        isValid = false;\n                        subscriptionValidationMsg = \"Subscription: add a phone number for SMS \\\/ WhatsApp channels you selected.\";\n                        if (!firstInvalidField) {\n                            firstInvalidField = $wrap;\n                        }\n                    }\n                    if (onlySeg && !emailVal && !phoneVal) {\n                        isValid = false;\n                        subscriptionValidationMsg = \"Subscription: add an email or phone number so we can save your preferences.\";\n                        if (!firstInvalidField) {\n                            firstInvalidField = $wrap;\n                        }\n                    }\n                    if (reqName && !nameVal) {\n                        isValid = false;\n                        subscriptionValidationMsg = \"Subscription: enter your name to complete the opt-in.\";\n                        if (!firstInvalidField) {\n                            firstInvalidField = $wrap;\n                        }\n                    }\n                });\n                \n                \/\/ If validation fails, stop submission\n                if (!isValid) {\n                    submitBtn.prop('disabled', false).text('Submit Form');\n                    if (firstInvalidField) {\n                        $(firstInvalidField).trigger('focus');\n                        $('html, body').animate({\n                            scrollTop: $(firstInvalidField).offset().top - 100\n                        }, 500);\n                    }\n                    showNotification(subscriptionValidationMsg || \"Please fill in all required fields.\", 'error');\n                    return false;\n                }\n                \n                \/\/ Disable button and show loading state\n                submitBtn.prop('disabled', true).text('Submitting...');\n                \n                \/\/ Collect form data\n                const formData = new FormData();\n                \n                form.find('input, textarea, select').each(function() {\n                    const $field = $(this);\n                    const fieldType = $field.attr('type');\n                    const name = $field.attr('name');\n                    \n                    if (name) {\n                        if (fieldType === 'file') {\n                            \/\/ Handle file uploads (name already ends with [] for multi-file fields)\n                            const files = this.files;\n                            const fileKey = \/\\[\\]$\/.test(name) ? name : (name + '[]');\n                            if (files.length > 0) {\n                                for (let i = 0; i < files.length; i++) {\n                                    formData.append(fileKey, files[i]);\n                                }\n                            }\n                        } else if (fieldType === 'checkbox') {\n                            \/\/ Handle checkboxes - collect all checked values\n                            const checkedBoxes = form.find('input[name=\"' + name + '\"]:checked');\n                            if (checkedBoxes.length > 0) {\n                                checkedBoxes.each(function() {\n                                    formData.append(name + '[]', $(this).val());\n                                });\n                            }\n                        } else {\n                            formData.append(name, $field.val());\n                        }\n                    }\n                });\n                \n                \/\/ Add form_id and action\n                formData.append('action', 'cbran_submit_form');\n                formData.append('nonce', cbran_ajax.nonce);\n                formData.append('form_id', 10837);\n                \n                console.log('Form submission started. Data:', formData);\n                console.log('AJAX URL:', cbran_ajax.ajax_url);\n                console.log('Nonce:', cbran_ajax.nonce);\n                \n                $.ajax({\n                    url: cbran_ajax.ajax_url,\n                    type: 'POST',\n                    data: formData,\n                    processData: false,\n                    contentType: false,\n                    success: function(response) {\n                        console.log('AJAX response received:', response);\n                        if (response.success) {\n                            \/\/ Hide the form\n                            $('#cbran-form-content-10837').fadeOut(300, function() {\n                                \/\/ Show success message\n                                $('#cbran-success-message-10837').fadeIn(300);\n                                \n                                \/\/ Handle post-submit action\n                                const postSubmitAction = 'reload';\n                                const redirectUrl = '';\n                                const actionDelay = parseInt('3') * 1000; \/\/ Convert to milliseconds\n                                \n                                if (postSubmitAction === 'redirect' && redirectUrl) {\n                                    setTimeout(function() {\n                                        window.location.href = redirectUrl;\n                                    }, actionDelay);\n                                } else if (postSubmitAction === 'reload') {\n                                    setTimeout(function() {\n                                        location.reload();\n                                    }, actionDelay);\n                                }\n                                \/\/ If 'none', do nothing - just show the success message\n                            });\n                        } else {\n                            showNotification(response.data || 'An error occurred while submitting the form.', 'error');\n                            submitBtn.prop('disabled', false).text('Submit Form');\n                        }\n                    },\n                    error: function(xhr, status, error) {\n                        console.error('AJAX error:', status, error);\n                        console.error('Response:', xhr.responseText);\n                        showNotification('An error occurred while submitting the form. Please check the console for details.', 'error');\n                        submitBtn.prop('disabled', false).text('Submit Form');\n                    }\n                });\n            });\n                    });\n        <\/script>\n        \n","protected":false},"excerpt":{"rendered":"At Sheeler SDA MGT, you can fill or continue this form from your mobile. Enter your phone number and we&#039;ll","protected":false},"author":2,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"class_list":["post-10838","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/www.sheelersda.com\/m\/wp-json\/wp\/v2\/pages\/10838","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.sheelersda.com\/m\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/www.sheelersda.com\/m\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/www.sheelersda.com\/m\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.sheelersda.com\/m\/wp-json\/wp\/v2\/comments?post=10838"}],"version-history":[{"count":13,"href":"https:\/\/www.sheelersda.com\/m\/wp-json\/wp\/v2\/pages\/10838\/revisions"}],"predecessor-version":[{"id":10907,"href":"https:\/\/www.sheelersda.com\/m\/wp-json\/wp\/v2\/pages\/10838\/revisions\/10907"}],"wp:attachment":[{"href":"https:\/\/www.sheelersda.com\/m\/wp-json\/wp\/v2\/media?parent=10838"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}