/*
Theme Name: Weddeb webflow template
Author: Weddeb
Description: Contemporary template for Weddeb
Requires at least: 6.7
Tested up to: 6.8
Requires PHP: 7.2
Version: 1.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
*/

body {
    scroll-behavior: smooth !important;
}

a.w-webflow-badge,
body .w-webflow-badge {
    display: none !important;
}

/**musica**/
#play-music {
    background-color: white;
    width: fit-content;
    padding: 3px 20px;
    position: fixed !important;
    right: 10px;
    bottom: 10px;
    z-index: 100;
    border: none;
}

#play-music svg {
    width: 20px;
    height: 20x
}

.text-left.header {
    padding: 0px 40px 0px 40px;
    margin-bottom: -100px;
}

.slider{
    height:fit-content !important;
}

/** RSVP custom form (reusing previous Forminator look) **/

.w-form {
    margin: 0 !important;
}

#group-header{
    font-family: Inter, sans-serif !important;
    letter-spacing: 0.3px;
    text-transform: none !important;
    font-size: 18px;
    line-height: 40px;
}

/** RSVP custom form (reusing previous Forminator look) **/ 
.section-asistencia .form-block.w-form #weddeb-rsvp-form {
    display: flex !important;
    flex-direction: column !important;
    gap: 16px !important;
}

#contemporaneo.section-asistencia .form-block.w-form {
    #group-info {
        box-sizing: border-box;
        margin: 0px 32px 12px !important; /* small top space from content above, bit of space to form */
        color: var(--color-scheme-1--text) !important;
        font-family: Inter, sans-serif !important;
        font-size: 16px !important; 
        line-height: 20px !important;
    }

    /* Core RSVP form container */
    #weddeb-rsvp-form {
        display: flex !important;
        flex-direction: column !important;
        gap: 16px !important;

        /* Inputs, select, textarea visual style */
        input[type="text"],
        select,
        textarea {
            box-sizing: border-box !important;
            width: 100% !important;
            border-radius: 12px !important;
            background: transparent !important;
            border: 2px solid #e4e4e7;
            color: var(--color-scheme-1--text) !important;
            font-family: Inter, sans-serif !important;
            font-size: 16px !important;
            line-height: 25px !important;
            padding: 20px 14px 0 !important;
        }

        /* Placeholder color */
        input::placeholder,
        textarea::placeholder {
            color: var(--color-scheme-1--text) !important;
            opacity: 0.6 !important;
        }

        /* Heights */
        input[type="text"],
        select {
            height: 66px !important;
        }

        textarea {
            min-height: 90px !important;
            padding-top: 32px !important;
            padding-bottom: 14px !important;
            resize: vertical !important;
            line-height: 15px !important;
        }

        /* Floating labels */
        label[for],
        #guest-count > label,
        #rsvp-message-row > label {
            position: absolute !important;
            top: 10px; /* lowered to sit inside the rounded border */
            left: 48px;
            z-index: 3 !important;
            pointer-events: none;
            color: #7b7b81 !important;
            font-family: Inter, sans-serif !important;
            font-size: 14px !important;
            font-weight: 400 !important;
            line-height: 1.2 !important;
            max-width: calc(100% - 52px);
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
        }
    }
    /* Readonly guest name: pull floating label left only when next input is readonly */
    #weddeb-rsvp-form #rows-wrap .rsvp-row label[for]:has(+ input[readonly]) {
        left: 45px !important;
    }

    #weddeb-rsvp-form p,
    #weddeb-rsvp-form #attend-choice,
    #weddeb-rsvp-form #guest-count,
    #weddeb-rsvp-form #rows-wrap .rsvp-row,
    #weddeb-rsvp-form #rsvp-message-row {
        position: relative !important;
        padding: 0 32px !important;
        margin: 0 !important;
    }

    /* Radio group: attend choice */
    #weddeb-rsvp-form #attend-choice[hidden],
    #weddeb-rsvp-form #attend-choice[aria-hidden="true"],
    #weddeb-rsvp-form #attend-choice.hidden,
    #weddeb-rsvp-form #attend-choice.is-hidden {
        display: none !important;
    }

    #weddeb-rsvp-form #attend-choice:not([hidden]):not([aria-hidden="true"]):not(.hidden):not(.is-hidden):not([style*="display:none"]):not([style*="display: none"]) {
        display: flex !important;
        flex-wrap: wrap !important;
        gap: 0 !important; /* seamless pair seam like segmented control */
    }

    #weddeb-rsvp-form #attend-choice label {
        display: inline-flex !important;
        align-items: center !important;
        color: var(--color-scheme-1--text) !important;
        font-family: Inter, sans-serif !important;
        font-size: 14px !important;
        font-weight: 400 !important;
        margin: 0 !important;
    }

    /* Hide native radios and style labels as pills for attend-choice */
    #weddeb-rsvp-form #attend-choice label > input[type="radio"] {
        position: absolute !important;
        width: 1px !important;
        height: 1px !important;
        margin: -1px !important;
        padding: 0 !important;
        border: 0 !important;
        clip: rect(0 0 0 0) !important;
        overflow: hidden !important;
    }

    #weddeb-rsvp-form #attend-choice label:has(> input[type="radio"]) {
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        min-width: 104px;
        padding: 7px 12px !important;
        font-family: Inter, sans-serif !important;
        font-weight: 400 !important;
        font-size: 15px !important;
        line-height: 1.2 !important;
        color: var(--color-scheme-1--text) !important;
        background: #fff !important;
        border: 1.5px solid var(--color-scheme-1--accent) !important;
        cursor: pointer !important;
        user-select: none !important;
        margin: 0 !important;
        gap: 0 !important; /* no internal gap since input is visually hidden */
    }

    #weddeb-rsvp-form #attend-choice label:has(> input[type="radio"]):first-of-type {
        border-right: 0 !important;
        border-top-left-radius: 999px !important;
        border-bottom-left-radius: 999px !important;
    }
    #weddeb-rsvp-form #attend-choice label:has(> input[type="radio"]) + label:has(> input[type="radio"]) {
        border-left: 1.5px solid var(--color-scheme-1--accent) !important;
        border-top-right-radius: 999px !important;
        border-bottom-right-radius: 999px !important;
        margin-left: 0 !important; /* tight seam */
    }

    #weddeb-rsvp-form #attend-choice label:has(> input[type="radio"]:checked) {
        background: var(--color-scheme-1--accent) !important;
        color: #fff !important;
    }
    #weddeb-rsvp-form #attend-choice label:has(> input[type="radio"]:focus-visible) {
        outline: 2px solid #9aa9c0 !important;
        outline-offset: 2px !important;
    }

    #weddeb-rsvp-form input[type="radio"] {
        accent-color: var(--color-scheme-1--text) !important;
    }

    /* Rows of guest names */
    #weddeb-rsvp-form #rows-wrap[hidden],
    #weddeb-rsvp-form #rows-wrap[aria-hidden="true"],
    #weddeb-rsvp-form #rows-wrap.hidden,
    #weddeb-rsvp-form #rows-wrap.is-hidden {
        display: none !important;
    }

    #weddeb-rsvp-form #rows-wrap:not([hidden]):not([aria-hidden="true"]):not(.hidden):not(.is-hidden):not([style*="display:none"]):not([style*="display: none"]) {
        display: grid !important;
        gap: 14px !important;
    }

    /* Named rows layout: name on left, radios on right */
    #weddeb-rsvp-form #rows-wrap .rsvp-row {
        display: flex;
        align-items: center;
        gap: 0 !important; /* allow seamless segmented buttons */
    }

    #weddeb-rsvp-form #rows-wrap .rsvp-row .rsvp-name {
        color: var(--color-scheme-1--text) !important;
        font-family: Inter, sans-serif !important;
        font-size: 16px !important;
        font-weight: 500 !important;
        line-height: 25px !important;
        margin-right: 12px !important;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    #weddeb-rsvp-form #rows-wrap .rsvp-row label {
        display: inline-flex !important;
        align-items: center !important;
        gap: 8px !important;
        color: #7b7b81 !important;
        font-family: Inter, sans-serif !important;
        font-size: 14px !important;
        font-weight: 400 !important;
        margin: 0 !important;
    }

    /* Ensure any other label variations inside rows-wrap use the same label color */
    #weddeb-rsvp-form #rows-wrap label {
        color: #7b7b81 !important;
    }

    /* Push radios to the right; space between options */
    #weddeb-rsvp-form #rows-wrap .rsvp-row label:first-of-type {
        margin-left: auto !important;
    }
    #weddeb-rsvp-form #rows-wrap .rsvp-row label + label {
        margin-left: 20px !important;
    }

    /* Segmented control appearance for radio options inside each row */
    #weddeb-rsvp-form #rows-wrap .rsvp-row label > input[type="radio"] {
        /* Visually hide the native control but keep it accessible */
        position: absolute !important;
        width: 1px !important;
        height: 1px !important;
        margin: -1px !important;
        padding: 0 !important;
        border: 0 !important;
        clip: rect(0 0 0 0) !important;
        overflow: hidden !important;
    }

    /* Base chip styles for the two labels that contain radios */
    #weddeb-rsvp-form #rows-wrap .rsvp-row label:has(> input[type="radio"]) {
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        min-width: 104px;
        padding: 7px 12px !important;
        font-family: Inter, sans-serif !important; /* match form */
        font-weight: 400 !important; /* match nearby label/button tone */
        font-size: 15px !important;  /* slightly smaller than base */
        line-height: 1.2 !important;
        color: var(--color-scheme-1--text) !important;
        background: #fff !important;
        border: 1.5px solid var(--color-scheme-1--accent) !important;
        cursor: pointer !important;
        user-select: none !important;
        margin: 0 !important;
    }

    /* Tighten pair seam and round outer corners */
    #weddeb-rsvp-form #rows-wrap .rsvp-row label:has(> input[type="radio"]):first-of-type {
        border-right: 0 !important;
        border-top-left-radius: 999px !important;
        border-bottom-left-radius: 999px !important;
    }
    #weddeb-rsvp-form #rows-wrap .rsvp-row label:has(> input[type="radio"]) + label:has(> input[type="radio"]) {
        border-left: 1.5px solid var(--color-scheme-1--accent) !important;
        border-top-right-radius: 999px !important;
        border-bottom-right-radius: 999px !important;
    }

    /* Checked and focus states using :has */
    #weddeb-rsvp-form #rows-wrap .rsvp-row label:has(> input[type="radio"]:checked) {
        background: var(--color-scheme-1--accent) !important;
        color: #fff !important;
    }
    #weddeb-rsvp-form #rows-wrap .rsvp-row label:has(> input[type="radio"]:focus-visible) {
        outline: 2px solid #9aa9c0 !important;
        outline-offset: 2px !important;
    }

    /* Push the radio pair to the right of the name (desktop) */
    #weddeb-rsvp-form #rows-wrap .rsvp-row label[for] + input[readonly] + label:has(> input[type="radio"]) {
        margin-left: auto !important;
        border-top-left-radius: 999px !important;
        border-bottom-left-radius: 999px !important;
        border-right: 0 !important;
    }

    /* Remove legacy gaps between the two option labels in segmented mode */
    #weddeb-rsvp-form #rows-wrap .rsvp-row label:has(> input[type="radio"]) + label:has(> input[type="radio"]) {
        margin-left: 0 !important;
    }

    /* Select min width similar to previous */
    #weddeb-rsvp-form select {
        min-width: 239px !important;
    }

    /* Submit button (match .forminator-button) */
    #weddeb-rsvp-form button[type="submit"],
    #weddeb-rsvp-form #rsvp-submit {
        background-color: #fcf1f0 !important;
        color: var(--_primitives---colors--brown) !important;
        border: 1.5px solid #fff !important;
        border-radius: 100px !important;
        padding-left: 89px !important;
        padding-right: 89px !important;
        height: 48px !important;
        font-size: 18px !important;
        font-weight: 500 !important;
        line-height: 18px !important;
        box-shadow: none !important;
        cursor: pointer !important;
    }

    #weddeb-rsvp-form button[type="submit"]:hover,
    #weddeb-rsvp-form #rsvp-submit:hover {
        background: var(--_primitives---colors--brown) !important;
        color: var(--_primitives---colors--light) !important;
    }

    /* (Removed forced aria-invalid red border to let plugin manage errors) */

    /* Disabled/read-only mimic */
    #weddeb-rsvp-form input:disabled,
    #weddeb-rsvp-form select:disabled,
    #weddeb-rsvp-form textarea:disabled {
        background-color: #f5f5f5 !important;
        color: #888 !important;
        cursor: not-allowed !important;
        opacity: 1 !important;
        border-color: #ddd !important;
    }

    /* Readonly via data attribute */
    #weddeb-rsvp-form [data-readonly="true"] {
        pointer-events: none !important;
        background-color: #f5f5f5 !important;
        opacity: 0.6 !important;
        cursor: not-allowed !important;
    }

    /* Rows-wrap: remove borders when inputs are disabled (guest name fields) */
    #weddeb-rsvp-form #rows-wrap input[type="text"][disabled],
    #weddeb-rsvp-form #rows-wrap input[type="text"][readonly],
    #weddeb-rsvp-form #rows-wrap input[type="text"][aria-disabled="true"],
    #weddeb-rsvp-form #rows-wrap input[type="text"].disabled,
    #weddeb-rsvp-form #rows-wrap input[type="text"].is-disabled {
        border: none !important;
        border-width: 0 !important;
        box-shadow: none !important;
        cursor: default !important; /* show normal arrow, not text I-beam */
        caret-color: transparent !important; /* hide caret if focus somehow lands here */
        /* pointer-events removed so tooltips work */
            background-color: #fff !important; /* Prevent iOS Safari gray background on readonly */
            -webkit-tap-highlight-color: transparent !important;
    }

        /* iOS Safari only: prevent gray flicker on readonly guest name input for all states */
        @supports (-webkit-touch-callout: none) {
            #weddeb-rsvp-form #rows-wrap input[type="text"][readonly],
            #weddeb-rsvp-form #rows-wrap input[type="text"][readonly]:focus,
            #weddeb-rsvp-form #rows-wrap input[type="text"][readonly]:active,
            #weddeb-rsvp-form #rows-wrap input[type="text"][readonly]:hover {
                background-color: #fff !important;
                -webkit-tap-highlight-color: transparent !important;
            }
        }

        /* iOS Safari only: prevent gray background on readonly guest name input */
        @supports (-webkit-touch-callout: none) {
            #weddeb-rsvp-form #rows-wrap input[type="text"][readonly] {
                background-color: #fff !important;
            }
        }

    /* Suppress black border/outline on readonly input when focused/clicked */
    #weddeb-rsvp-form #rows-wrap input[type="text"][readonly]:focus,
    #weddeb-rsvp-form #rows-wrap input[type="text"][readonly]:active {
        outline: none !important;
        border: none !important;
        box-shadow: none !important;
    }

    /* Also remove any focus outlines that some browsers add to read-only inputs */
    #weddeb-rsvp-form #rows-wrap input[type="text"][readonly]:focus,
    #weddeb-rsvp-form #rows-wrap input[type="text"][readonly]:focus-visible,
    #weddeb-rsvp-form #rows-wrap input[type="text"][disabled]:focus,
    #weddeb-rsvp-form #rows-wrap input[type="text"][disabled]:focus-visible {
        outline: none !important;
        outline-offset: 0 !important;
        box-shadow: none !important;
    }

    /* Inline loaders */
    #weddeb-rsvp-form .weddeb-inline-loader {
        display: inline-block;
        width: 18px;
        height: 18px;
        margin-left: 8px;
        vertical-align: middle;
        border-radius: 50%;
        border: 2px solid var(--color-scheme-1--accent);
        border-top-color: transparent;
        animation: weddeb-spin 0.8s linear infinite;
        box-shadow: none !important;
    }

    /* Minimal placement for the code loader: no display overrides, JS controls visibility */
    #weddeb-rsvp-form :is(div, p, section, fieldset, label, .w-input, .w-field, .form-field, .form-group):has(#code-loader) {
        position: relative !important;
    }

    #weddeb-rsvp-form #code-loader {
        position: absolute !important;
        top: 25px !important; /* move up inside the input area */
        right: 45px !important; /* align to the input's right padding */
        z-index: 4 !important;
    }

    /* Make room so text doesn't run under the spinner */
    #weddeb-rsvp-form input#rsvp-code,
    #weddeb-rsvp-form input#code,
    #weddeb-rsvp-form input[name="code"] {
        padding-right: 44px !important;
    }

    /* Status messages */
    #weddeb-rsvp-form #status {
        box-sizing: border-box;
        display: block;
        font-family: Inter, sans-serif !important;
        font-weight: 500 !important;
        width: 100% !important;
        margin-top: 8px !important;
        padding: 0 32px !important;
    color: var(--color-scheme-1--text);
    }

    /* When JS focuses the status region for announcements, hide the blue focus ring */
    #weddeb-rsvp-form #status:focus,
    #weddeb-rsvp-form #status:focus-visible {
        outline: none !important;
        box-shadow: none !important;
    }

    /* Hide the honeypot from any visual glitches (already inline, just in case) */
    #weddeb-rsvp-form #weddeb-hp {
        position: absolute !important;
        left: -9999px !important;
    }

    /* Submit row alignment and divider similar to .forminator-row-last */
    #weddeb-rsvp-form p:last-of-type {
        text-align: center !important;
        padding-top: 24px !important;
        border-top: 1.5px solid var(--_primitives---colors--light) !important;
        margin-top: 14px !important;
    }

    /* Busy state */
    #weddeb-rsvp-form[aria-busy="true"] {
        opacity: 0.7 !important;
        pointer-events: none !important;
    }

    /* Status helpers */
    #weddeb-rsvp-form #status.success {
        color: #0f766e; /* teal-700; plugin can override */
    }

    #weddeb-rsvp-form #status.error {
        color: #b91c1c; /* red-700; plugin can override */
    }

    /* ----- Robust visibility controls (override legacy display rules) ----- */
    /* Status: hide when empty/hidden; show when populated */
    #weddeb-rsvp-form #status:empty,
    #weddeb-rsvp-form #status[hidden],
    #weddeb-rsvp-form #status[aria-hidden="true"],
    #weddeb-rsvp-form #status.hidden,
    #weddeb-rsvp-form #status.is-hidden,
    #weddeb-rsvp-form #status[style*="display:none"],
    #weddeb-rsvp-form #status[style*="display: none"] {
        display: none !important;
    }

    #weddeb-rsvp-form #status:not(:empty):not([hidden]):not([aria-hidden="true"]):not(.hidden):not(.is-hidden):not([style*="display:none"]):not([style*="display: none"]) {
        display: block !important;
    }

    /* Submit row <p> visibility: hide only when BOTH the button and loader are hidden */
    #weddeb-rsvp-form p:has(> #rsvp-submit, > #submit-loader) {
        display: block !important; /* default visible when present */
    }
    #weddeb-rsvp-form p:has(> #rsvp-submit[hidden],
                             > #rsvp-submit[aria-hidden="true"],
                             > #rsvp-submit.hidden,
                             > #rsvp-submit.is-hidden,
                             > #rsvp-submit[style*="display:none" i],
                             > #rsvp-submit[style*="display: none" i]):has(> #submit-loader[hidden],
                                                                           > #submit-loader[aria-hidden="true"],
                                                                           > #submit-loader.hidden,
                                                                           > #submit-loader.is-hidden,
                                                                           > #submit-loader[style*="display:none" i],
                                                                           > #submit-loader[style*="display: none" i]) {
        display: none !important;
    }

    /* Submit loader: hidden unless JS shows while submitting */
    #weddeb-rsvp-form #submit-loader[hidden],
    #weddeb-rsvp-form #submit-loader[aria-hidden="true"],
    #weddeb-rsvp-form #submit-loader.hidden,
    #weddeb-rsvp-form #submit-loader.is-hidden,
    #weddeb-rsvp-form #submit-loader[style*="display:none"],
    #weddeb-rsvp-form #submit-loader[style*="display: none"] {
        display: none !important;
    }

    #weddeb-rsvp-form #submit-loader:not([hidden]):not([aria-hidden="true"]):not(.hidden):not(.is-hidden):not([style*="display:none"]):not([style*="display: none"]) {
        display: inline-block !important;
    }

    /* Larger separation for main sections (divs) vs. individual fields */
    #weddeb-rsvp-form > div {
        margin-block: 0px !important; /* distinguish main blocks (attend, guest-count, rows, status) */
    }

    @media (max-width: 768px) {
        #group-header {
            font-family: Inter, sans-serif !important;
            letter-spacing: 0.3px;
            text-transform: none !important;
            font-size: 18px;
            line-height: 25px;
        }

        #group-info {
            margin: 0px 16px 0px !important;
            font-size: 14px !important;
            line-height: 19px !important;
        }

        #weddeb-rsvp-form :is(div, p, section, fieldset, label, .w-input, .w-field, .form-field, .form-group):has(#code-loader){
            margin-top: 10px !important;
        }

        #weddeb-rsvp-form label[for],
        #weddeb-rsvp-form #guest-count > label,
        #weddeb-rsvp-form #rsvp-message-row > label {
            left: 30px; /* 16px container padding + ~14px input left padding */
        }

        /* Mobile: align readonly guest name label to mobile side padding */
        #weddeb-rsvp-form #rows-wrap .rsvp-row label[for]:has(+ input[readonly]) {
            left: 30px !important;
        }

        #weddeb-rsvp-form p,
        #weddeb-rsvp-form #attend-choice,
        #weddeb-rsvp-form #guest-count,
        #weddeb-rsvp-form #rows-wrap .rsvp-row,
        #weddeb-rsvp-form #rsvp-message-row {
            padding: 0 16px !important;
        }

        /* Keep chips readable on mobile */
        #weddeb-rsvp-form #rows-wrap .rsvp-row label:has(> input[type="radio"]) {
            min-width: 96px;
            padding: 6px 10px !important;
            }

        /* Align pill radio buttons with guest name text in mobile RSVP rows */
        #weddeb-rsvp-form #rows-wrap .rsvp-row input[readonly] + label:has(> input[type="radio"]) {
            margin-left: 32px !important;
        }

        #weddeb-rsvp-form #attend-choice label:has(> input[type="radio"]) {
            min-width: 96px;
            padding: 6px 10px !important;
        }
        /* When stacking, give a small gap between the two chips */
        #weddeb-rsvp-form #rows-wrap .rsvp-row {
            gap: 6px;
        }

        /* Adjust status side padding on mobile */
        #weddeb-rsvp-form #status {
            padding: 0 16px !important;
        }

        /* Position of the code loader on mobile */
        #weddeb-rsvp-form #code-loader {
            top: 26px !important;
            right: 30px !important;
        }

        /* Mobile layout for rows: wrap and make the readonly name full width */
        #weddeb-rsvp-form #rows-wrap .rsvp-row {
            flex-wrap: wrap;             /* allow wrapping to a new line */
            align-items: flex-start;
        }

        #weddeb-rsvp-form #rows-wrap .rsvp-row input[readonly] {
            flex: 0 0 100% !important;
        }
        #weddeb-rsvp-form #rows-wrap .rsvp-row label:first-of-type {
            margin-left: 0 !important;
        }
        #weddeb-rsvp-form #rows-wrap .rsvp-row label[for] + input[readonly] + label:has(> input[type="radio"]) {
            margin-left: 12px !important;
        }
        #weddeb-rsvp-form #rows-wrap .rsvp-row label:has(> input[type="radio"]) + label:has(> input[type="radio"]) {
            margin-left: 0 !important;
        }
    }
}

.section-asistencia .form-block.w-form {
    #group-info {
        box-sizing: border-box;
        margin: 0px 32px 12px !important; /* small top space from content above, bit of space to form */
        color: var(--color-scheme-1--text) !important;
        font-family: Inter, sans-serif !important;
        font-size: 16px !important; 
        line-height: 20px !important;
    }

    /* Core RSVP form container */
    #weddeb-rsvp-form {
        display: flex !important;
        flex-direction: column !important;
        gap: 16px !important;

        /* Inputs, select, textarea visual style */
        input[type="text"],
        select,
        textarea {
            box-sizing: border-box !important;
            width: 100% !important;
            border-radius: 12px !important;
            background: transparent !important;
            border: 2px solid #e4e4e7;
            color: var(--color-scheme-1--text) !important;
            font-family: Inter, sans-serif !important;
            font-size: 16px !important;
            line-height: 25px !important;
            padding: 20px 14px 0 !important;
        }

        /* Placeholder color */
        input::placeholder,
        textarea::placeholder {
            color: var(--color-scheme-1--text) !important;
            opacity: 0.6 !important;
        }

        /* Heights */
        input[type="text"],
        select {
            height: 66px !important;
        }

        textarea {
            min-height: 90px !important;
            padding-top: 32px !important;
            padding-bottom: 14px !important;
            resize: vertical !important;
            line-height: 15px !important;
        }

        /* Floating labels */
        label[for],
        #guest-count > label,
        #rsvp-message-row > label {
            position: absolute !important;
            top: 10px; /* lowered to sit inside the rounded border */
            left: 48px;
            z-index: 3 !important;
            pointer-events: none;
            color: #7b7b81 !important;
            font-family: Inter, sans-serif !important;
            font-size: 14px !important;
            font-weight: 400 !important;
            line-height: 1.2 !important;
            max-width: calc(100% - 52px);
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
        }
    }
    /* Readonly guest name: pull floating label left only when next input is readonly */
    #weddeb-rsvp-form #rows-wrap .rsvp-row label[for]:has(+ input[readonly]) {
        left: 45px !important;
    }

    #weddeb-rsvp-form p,
    #weddeb-rsvp-form #attend-choice,
    #weddeb-rsvp-form #guest-count,
    #weddeb-rsvp-form #rows-wrap .rsvp-row,
    #weddeb-rsvp-form #rsvp-message-row {
        position: relative !important;
        padding: 0 32px !important;
        margin: 0 !important;
    }

    /* Radio group: attend choice */
    #weddeb-rsvp-form #attend-choice[hidden],
    #weddeb-rsvp-form #attend-choice[aria-hidden="true"],
    #weddeb-rsvp-form #attend-choice.hidden,
    #weddeb-rsvp-form #attend-choice.is-hidden {
        display: none !important;
    }

    #weddeb-rsvp-form #attend-choice:not([hidden]):not([aria-hidden="true"]):not(.hidden):not(.is-hidden):not([style*="display:none"]):not([style*="display: none"]) {
        display: flex !important;
        flex-wrap: wrap !important;
        gap: 0 !important; /* seamless pair seam like segmented control */
    }

    #weddeb-rsvp-form #attend-choice label {
        display: inline-flex !important;
        align-items: center !important;
        color: var(--color-scheme-1--text) !important;
        font-family: Inter, sans-serif !important;
        font-size: 14px !important;
        font-weight: 400 !important;
        margin: 0 !important;
    }

    /* Hide native radios and style labels as pills for attend-choice */
    #weddeb-rsvp-form #attend-choice label > input[type="radio"] {
        position: absolute !important;
        width: 1px !important;
        height: 1px !important;
        margin: -1px !important;
        padding: 0 !important;
        border: 0 !important;
        clip: rect(0 0 0 0) !important;
        overflow: hidden !important;
    }

    #weddeb-rsvp-form #attend-choice label:has(> input[type="radio"]) {
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        min-width: 97px;
        padding: 7px 2px !important;
        font-family: Inter, sans-serif !important;
        font-weight: 400 !important;
        font-size: 14px !important;
        line-height: 1.2 !important;
        color: var(--color-scheme-1--text) !important;
        background: #fff !important;
        border: 1.5px solid var(--color-scheme-1--accent) !important;
        cursor: pointer !important;
        user-select: none !important;
        margin: 0 !important;
        gap: 0 !important; /* no internal gap since input is visually hidden */
    }

    #weddeb-rsvp-form #attend-choice label:has(> input[type="radio"]):first-of-type {
        border-right: 0 !important;
        border-top-left-radius: 999px !important;
        border-bottom-left-radius: 999px !important;
    }
    #weddeb-rsvp-form #attend-choice label:has(> input[type="radio"]) + label:has(> input[type="radio"]) {
        border-left: 1.5px solid var(--color-scheme-1--accent) !important;
        border-top-right-radius: 999px !important;
        border-bottom-right-radius: 999px !important;
        margin-left: 0 !important; /* tight seam */
    }

    #weddeb-rsvp-form #attend-choice label:has(> input[type="radio"]:checked) {
        background: var(--color-scheme-1--accent) !important;
        color: #fff !important;
    }
    #weddeb-rsvp-form #attend-choice label:has(> input[type="radio"]:focus-visible) {
        outline: 2px solid #9aa9c0 !important;
        outline-offset: 2px !important;
    }

    #weddeb-rsvp-form input[type="radio"] {
        accent-color: var(--color-scheme-1--text) !important;
    }

    /* Rows of guest names */
    #weddeb-rsvp-form #rows-wrap[hidden],
    #weddeb-rsvp-form #rows-wrap[aria-hidden="true"],
    #weddeb-rsvp-form #rows-wrap.hidden,
    #weddeb-rsvp-form #rows-wrap.is-hidden {
        display: none !important;
    }

    #weddeb-rsvp-form #rows-wrap:not([hidden]):not([aria-hidden="true"]):not(.hidden):not(.is-hidden):not([style*="display:none"]):not([style*="display: none"]) {
        display: grid !important;
        gap: 14px !important;
    }

    /* Named rows layout: name on left, radios on right */
    #weddeb-rsvp-form #rows-wrap .rsvp-row {
        display: flex;
        align-items: center;
        gap: 0 !important; /* allow seamless segmented buttons */
    }

    #weddeb-rsvp-form #rows-wrap .rsvp-row .rsvp-name {
        color: var(--color-scheme-1--text) !important;
        font-family: Inter, sans-serif !important;
        font-size: 16px !important;
        font-weight: 500 !important;
        line-height: 25px !important;
        margin-right: 12px !important;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    #weddeb-rsvp-form #rows-wrap .rsvp-row label {
        display: inline-flex !important;
        align-items: center !important;
        gap: 8px !important;
        color: #7b7b81 !important;
        font-family: Inter, sans-serif !important;
        font-size: 14px !important;
        font-weight: 400 !important;
        margin: 0 !important;
    }

    /* Ensure any other label variations inside rows-wrap use the same label color */
    #weddeb-rsvp-form #rows-wrap label {
        color: #7b7b81 !important;
    }

    /* Push radios to the right; space between options */
    #weddeb-rsvp-form #rows-wrap .rsvp-row label:first-of-type {
        margin-left: auto !important;
    }
    #weddeb-rsvp-form #rows-wrap .rsvp-row label + label {
        margin-left: 20px !important;
    }

    /* Segmented control appearance for radio options inside each row */
    #weddeb-rsvp-form #rows-wrap .rsvp-row label > input[type="radio"] {
        /* Visually hide the native control but keep it accessible */
        position: absolute !important;
        width: 1px !important;
        height: 1px !important;
        margin: -1px !important;
        padding: 0 !important;
        border: 0 !important;
        clip: rect(0 0 0 0) !important;
        overflow: hidden !important;
    }

    /* Base chip styles for the two labels that contain radios */
    #weddeb-rsvp-form #rows-wrap .rsvp-row label:has(> input[type="radio"]) {
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        min-width: 97px;
        padding: 7px 2px !important;
        font-family: Inter, sans-serif !important; /* match form */
        font-weight: 400 !important; /* match nearby label/button tone */
        font-size: 14px !important;  /* slightly smaller than base */
        line-height: 1.2 !important;
        color: var(--color-scheme-1--text) !important;
        background: #fff !important;
        border: 1.5px solid var(--color-scheme-1--accent) !important;
        cursor: pointer !important;
        user-select: none !important;
        margin: 0 !important;
    }

    /* Tighten pair seam and round outer corners */
    #weddeb-rsvp-form #rows-wrap .rsvp-row label:has(> input[type="radio"]):first-of-type {
        border-right: 0 !important;
        border-top-left-radius: 999px !important;
        border-bottom-left-radius: 999px !important;
    }
    #weddeb-rsvp-form #rows-wrap .rsvp-row label:has(> input[type="radio"]) + label:has(> input[type="radio"]) {
        border-left: 1.5px solid var(--color-scheme-1--accent) !important;
        border-top-right-radius: 999px !important;
        border-bottom-right-radius: 999px !important;
    }

    /* Checked and focus states using :has */
    #weddeb-rsvp-form #rows-wrap .rsvp-row label:has(> input[type="radio"]:checked) {
        background: var(--color-scheme-1--accent) !important;
        color: #fff !important;
    }
    #weddeb-rsvp-form #rows-wrap .rsvp-row label:has(> input[type="radio"]:focus-visible) {
        outline: 2px solid #9aa9c0 !important;
        outline-offset: 2px !important;
    }

    /* Push the radio pair to the right of the name (desktop) */
    #weddeb-rsvp-form #rows-wrap .rsvp-row label[for] + input[readonly] + label:has(> input[type="radio"]) {
        margin-left: auto !important;
        border-top-left-radius: 999px !important;
        border-bottom-left-radius: 999px !important;
        border-right: 0 !important;
    }

    /* Remove legacy gaps between the two option labels in segmented mode */
    #weddeb-rsvp-form #rows-wrap .rsvp-row label:has(> input[type="radio"]) + label:has(> input[type="radio"]) {
        margin-left: 0 !important;
    }

    /* Select min width similar to previous */
    #weddeb-rsvp-form select {
        min-width: 239px !important;
    }

    /* Submit button (match .forminator-button) */
    #weddeb-rsvp-form button[type="submit"],
    #weddeb-rsvp-form #rsvp-submit {
        background-color: var(--_primitives---colors--brown) !important;
        color: var(--_primitives---colors--light) !important;
        border: 1.5px solid #fff !important;
        border-radius: 100px !important;
        padding-left: 89px !important;
        padding-right: 89px !important;
        height: 48px !important;
        font-size: 18px !important;
        font-weight: 500 !important;
        line-height: 18px !important;
        box-shadow: none !important;
        cursor: pointer !important;
    }

    #weddeb-rsvp-form button[type="submit"]:hover,
    #weddeb-rsvp-form #rsvp-submit:hover {
        background: var(--_primitives---colors--light) !important;
        color: var(--_primitives---colors--brown) !important;
    }

    /* (Removed forced aria-invalid red border to let plugin manage errors) */

    /* Disabled/read-only mimic */
    #weddeb-rsvp-form input:disabled,
    #weddeb-rsvp-form select:disabled,
    #weddeb-rsvp-form textarea:disabled {
        background-color: #f5f5f5 !important;
        color: #888 !important;
        cursor: not-allowed !important;
        opacity: 1 !important;
        border-color: #ddd !important;
    }

    /* Readonly via data attribute */
    #weddeb-rsvp-form [data-readonly="true"] {
        pointer-events: none !important;
        background-color: #f5f5f5 !important;
        opacity: 0.6 !important;
        cursor: not-allowed !important;
    }

    /* Rows-wrap: remove borders when inputs are disabled (guest name fields) */
    #weddeb-rsvp-form #rows-wrap input[type="text"][disabled],
    #weddeb-rsvp-form #rows-wrap input[type="text"][readonly],
    #weddeb-rsvp-form #rows-wrap input[type="text"][aria-disabled="true"],
    #weddeb-rsvp-form #rows-wrap input[type="text"].disabled,
    #weddeb-rsvp-form #rows-wrap input[type="text"].is-disabled {
        border: none !important;
        border-width: 0 !important;
        box-shadow: none !important;
        cursor: default !important; /* show normal arrow, not text I-beam */
        caret-color: transparent !important; /* hide caret if focus somehow lands here */
        /* pointer-events removed so tooltips work */
            background-color: #fff !important; /* Prevent iOS Safari gray background on readonly */
            -webkit-tap-highlight-color: transparent !important;
    }

        /* iOS Safari only: prevent gray flicker on readonly guest name input for all states */
        @supports (-webkit-touch-callout: none) {
            #weddeb-rsvp-form #rows-wrap input[type="text"][readonly],
            #weddeb-rsvp-form #rows-wrap input[type="text"][readonly]:focus,
            #weddeb-rsvp-form #rows-wrap input[type="text"][readonly]:active,
            #weddeb-rsvp-form #rows-wrap input[type="text"][readonly]:hover {
                background-color: #fff !important;
                -webkit-tap-highlight-color: transparent !important;
            }
        }

    /* Suppress black border/outline on readonly input when focused/clicked */
    #weddeb-rsvp-form #rows-wrap input[type="text"][readonly]:focus,
    #weddeb-rsvp-form #rows-wrap input[type="text"][readonly]:active {
        outline: none !important;
        border: none !important;
        box-shadow: none !important;
    }

    /* Also remove any focus outlines that some browsers add to read-only inputs */
    #weddeb-rsvp-form #rows-wrap input[type="text"][readonly]:focus,
    #weddeb-rsvp-form #rows-wrap input[type="text"][readonly]:focus-visible,
    #weddeb-rsvp-form #rows-wrap input[type="text"][disabled]:focus,
    #weddeb-rsvp-form #rows-wrap input[type="text"][disabled]:focus-visible {
        outline: none !important;
        outline-offset: 0 !important;
        box-shadow: none !important;
    }

    /* Inline loaders */
    #weddeb-rsvp-form .weddeb-inline-loader {
        display: inline-block;
        width: 18px;
        height: 18px;
        margin-left: 8px;
        vertical-align: middle;
        border-radius: 50%;
        border: 2px solid var(--color-scheme-1--accent);
        border-top-color: transparent;
        animation: weddeb-spin 0.8s linear infinite;
        box-shadow: none !important;
    }

    /* Minimal placement for the code loader: no display overrides, JS controls visibility */
    #weddeb-rsvp-form :is(div, p, section, fieldset, label, .w-input, .w-field, .form-field, .form-group):has(#code-loader) {
        position: relative !important;
    }

    #weddeb-rsvp-form #code-loader {
        position: absolute !important;
        top: 25px !important; /* move up inside the input area */
        right: 45px !important; /* align to the input's right padding */
        z-index: 4 !important;
    }

    /* Make room so text doesn't run under the spinner */
    #weddeb-rsvp-form input#rsvp-code,
    #weddeb-rsvp-form input#code,
    #weddeb-rsvp-form input[name="code"] {
        padding-right: 44px !important;
    }

    /* Status messages */
    #weddeb-rsvp-form #status {
        box-sizing: border-box;
        display: block;
        font-family: Inter, sans-serif !important;
        font-weight: 500 !important;
        width: 100% !important;
        margin-top: 8px !important;
        padding: 0 32px !important;
    color: var(--color-scheme-1--text);
    }

    /* When JS focuses the status region for announcements, hide the blue focus ring */
    #weddeb-rsvp-form #status:focus,
    #weddeb-rsvp-form #status:focus-visible {
        outline: none !important;
        box-shadow: none !important;
    }

    /* Hide the honeypot from any visual glitches (already inline, just in case) */
    #weddeb-rsvp-form #weddeb-hp {
        position: absolute !important;
        left: -9999px !important;
    }

    /* Submit row alignment and divider similar to .forminator-row-last */
    #weddeb-rsvp-form p:last-of-type {
        text-align: center !important;
        padding-top: 24px !important;
        border-top: 1.5px solid var(--_primitives---colors--light) !important;
        margin-top: 14px !important;
    }

    /* Busy state */
    #weddeb-rsvp-form[aria-busy="true"] {
        opacity: 0.7 !important;
        pointer-events: none !important;
    }

    /* Status helpers */
    #weddeb-rsvp-form #status.success {
        color: #0f766e; /* teal-700; plugin can override */
    }

    #weddeb-rsvp-form #status.error {
        color: #b91c1c; /* red-700; plugin can override */
    }

    /* ----- Robust visibility controls (override legacy display rules) ----- */
    /* Status: hide when empty/hidden; show when populated */
    #weddeb-rsvp-form #status:empty,
    #weddeb-rsvp-form #status[hidden],
    #weddeb-rsvp-form #status[aria-hidden="true"],
    #weddeb-rsvp-form #status.hidden,
    #weddeb-rsvp-form #status.is-hidden,
    #weddeb-rsvp-form #status[style*="display:none"],
    #weddeb-rsvp-form #status[style*="display: none"] {
        display: none !important;
    }

    #weddeb-rsvp-form #status:not(:empty):not([hidden]):not([aria-hidden="true"]):not(.hidden):not(.is-hidden):not([style*="display:none"]):not([style*="display: none"]) {
        display: block !important;
    }

    /* Submit row <p> visibility: hide only when BOTH the button and loader are hidden */
    #weddeb-rsvp-form p:has(> #rsvp-submit, > #submit-loader) {
        display: block !important; /* default visible when present */
    }
    #weddeb-rsvp-form p:has(> #rsvp-submit[hidden],
                             > #rsvp-submit[aria-hidden="true"],
                             > #rsvp-submit.hidden,
                             > #rsvp-submit.is-hidden,
                             > #rsvp-submit[style*="display:none" i],
                             > #rsvp-submit[style*="display: none" i]):has(> #submit-loader[hidden],
                                                                           > #submit-loader[aria-hidden="true"],
                                                                           > #submit-loader.hidden,
                                                                           > #submit-loader.is-hidden,
                                                                           > #submit-loader[style*="display:none" i],
                                                                           > #submit-loader[style*="display: none" i]) {
        display: none !important;
    }

    /* Submit loader: hidden unless JS shows while submitting */
    #weddeb-rsvp-form #submit-loader[hidden],
    #weddeb-rsvp-form #submit-loader[aria-hidden="true"],
    #weddeb-rsvp-form #submit-loader.hidden,
    #weddeb-rsvp-form #submit-loader.is-hidden,
    #weddeb-rsvp-form #submit-loader[style*="display:none"],
    #weddeb-rsvp-form #submit-loader[style*="display: none"] {
        display: none !important;
    }

    #weddeb-rsvp-form #submit-loader:not([hidden]):not([aria-hidden="true"]):not(.hidden):not(.is-hidden):not([style*="display:none"]):not([style*="display: none"]) {
        display: inline-block !important;
    }

    /* Larger separation for main sections (divs) vs. individual fields */
    #weddeb-rsvp-form > div {
        margin-block: 0px !important; /* distinguish main blocks (attend, guest-count, rows, status) */
    }

    @media (max-width: 768px) {
        #group-header {
            font-family: Inter, sans-serif !important;
            letter-spacing: 0.3px;
            text-transform: none !important;
            font-size: 18px;
            line-height: 25px;
        }

        #group-info {
            margin: 0px 16px 0px !important;
            font-size: 14px !important;
            line-height: 19px !important;
        }

        #weddeb-rsvp-form :is(div, p, section, fieldset, label, .w-input, .w-field, .form-field, .form-group):has(#code-loader){
            margin-top: 10px !important;
        }

        #weddeb-rsvp-form label[for],
        #weddeb-rsvp-form #guest-count > label,
        #weddeb-rsvp-form #rsvp-message-row > label {
            left: 30px; /* 16px container padding + ~14px input left padding */
        }

        /* Mobile: align readonly guest name label to mobile side padding */
        #weddeb-rsvp-form #rows-wrap .rsvp-row label[for]:has(+ input[readonly]) {
            left: 30px !important;
        }

        #weddeb-rsvp-form p,
        #weddeb-rsvp-form #attend-choice,
        #weddeb-rsvp-form #guest-count,
        #weddeb-rsvp-form #rows-wrap .rsvp-row,
        #weddeb-rsvp-form #rsvp-message-row {
            padding: 0 16px !important;
        }

        /* Keep chips readable on mobile */
        #weddeb-rsvp-form #rows-wrap .rsvp-row label:has(> input[type="radio"]) {
            min-width: 96px;
            padding: 6px 10px !important;
            }

        /* Align pill radio buttons with guest name text in mobile RSVP rows */
        #weddeb-rsvp-form #rows-wrap .rsvp-row input[readonly] + label:has(> input[type="radio"]) {
            margin-left: 32px !important;
        }

        #weddeb-rsvp-form #attend-choice label:has(> input[type="radio"]) {
            min-width: 96px;
            padding: 6px 10px !important;
        }
        /* When stacking, give a small gap between the two chips */
        #weddeb-rsvp-form #rows-wrap .rsvp-row {
            gap: 6px;
        }

        /* Adjust status side padding on mobile */
        #weddeb-rsvp-form #status {
            padding: 0 16px !important;
        }

        /* Position of the code loader on mobile */
        #weddeb-rsvp-form #code-loader {
            top: 26px !important;
            right: 30px !important;
        }

        /* Mobile layout for rows: wrap and make the readonly name full width */
        #weddeb-rsvp-form #rows-wrap .rsvp-row {
            flex-wrap: wrap;             /* allow wrapping to a new line */
            align-items: flex-start;
        }

        #weddeb-rsvp-form #rows-wrap .rsvp-row input[readonly] {
            flex: 0 0 100% !important;
        }
        #weddeb-rsvp-form #rows-wrap .rsvp-row label:first-of-type {
            margin-left: 0 !important;
        }
        #weddeb-rsvp-form #rows-wrap .rsvp-row label[for] + input[readonly] + label:has(> input[type="radio"]) {
            margin-left: 12px !important;
        }
        #weddeb-rsvp-form #rows-wrap .rsvp-row label:has(> input[type="radio"]) + label:has(> input[type="radio"]) {
            margin-left: 0 !important;
        }
    }
}