/* Main form container */
.wpcf7 {
    max-width: 700px;
    margin: 0 auto;
    padding: 0;
    font-family: var(--wp--preset--font-family--hero);
    color: var(--wp--preset--color--base);
    font-size: var(--wp--preset--font-size--m);
    box-sizing: border-box;
}

/* Form wrapper with glass effect */
.wpcf7-form {
    border: 1px solid rgba(255, 255, 255, 0.3);
    padding: 2rem;
    border-radius: 20px;
    box-sizing: border-box;
    width: 100%;
    margin: 0;
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    box-shadow: inset 0 0 15px rgba(135, 135, 135, 0.1), 
                0 0 18px 3px rgba(0, 0, 0, 0.3);
}

/* Text & Links */
.wpcf7 p {
    color: var(--wp--preset--color--base);
    margin: 0;
}

.wpcf7 p:last-child {
    margin-bottom: 0;
}

.wpcf7 a {
    color: var(--wp--preset--color--base);
    text-decoration: underline;
    transition: opacity 0.3s ease;
}

.wpcf7 a:hover {
    opacity: 0.8;
}

/* Labels */
.wpcf7 label {
    display: block;
    color: var(--wp--preset--color--base);
    font-weight: 500;
    margin-bottom: 0.5rem;
}

/* Individual form control wrappers */
.wpcf7-form-control-wrap {
    position: relative;
    display: block;
    margin-bottom: 1.5rem;
    width: 100%;
    box-sizing: border-box;
}

/* All form inputs and textareas */
.wpcf7-form-control {
    width: 100%;
    max-width: 100%;
    padding: 1rem 1.25rem;
    border-radius: 10px;
    border: 0.5px solid rgba(255, 255, 255, 0.2);
    font-size: var(--wp--preset--font-size--s);
    font-family: var(--wp--preset--font-family--hero);
    background-color: rgba(255, 255, 255, 0.2);
    color: var(--wp--preset--color--base);
    transition: all 0.3s ease;
    box-sizing: border-box;
    min-height: 48px;
    outline: none;
}

.wpcf7-form-control.wpcf7-textarea {
    min-height: 38px;
    max-height: 100px;

}
/* Acceptance checkbox (terms & conditions) */
.wpcf7-form-control.wpcf7-acceptance {
    margin-bottom: 1.5rem;
    border: none;
    background: transparent;
    width: 100%;
    max-width: 100%;
    padding: 1rem 1.25rem;
    font-size: var(--wp--preset--font-size--s);
    font-family: var(--wp--preset--font-family--hero);
    color: var(--wp--preset--color--base);
    transition: all 0.3s ease;
    box-sizing: border-box;
    min-height: 48px;
    outline: none;
}

/* Fix checkbox alignment (CF7) */
.wpcf7-acceptance {
    padding: 0 !important;
    min-height: unset !important;
    margin-left: 0 !important;
}

.wpcf7-acceptance .wpcf7-form-control-wrap {
    margin-bottom: 0;
}

.wpcf7-form-control.wpcf7-acceptance label {
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.wpcf7-form-control.wpcf7-acceptance input[type="checkbox"] {
    margin: 0;
    position: relative;
    top: -1px; /* tiny optical correction */
}

.wpcf7-form-control.wpcf7-acceptance .wpcf7-list-item-label {
    display: block;
    line-height: 1.3;
}

/* Focus state for inputs */
.wpcf7-form-control:focus {
    border-color: rgba(255, 255, 255, 0.5);
    background-color: rgba(255, 255, 255, 0.25);
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.1);
}

/* Textarea specific */
.wpcf7-textarea {
    min-height: 150px;
    max-height: 300px;
    resize: vertical;
}

/* Placeholder text */
.wpcf7-form-control::placeholder {
    color: rgba(255, 255, 255, 0.6);
    opacity: 1;
}

/* Select dropdown */
.wpcf7-select {
    cursor: pointer;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23ffffff' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    background-size: 12px;
    padding-right: 2.5rem;
    appearance: none;
}

/* Checkboxes and Radio buttons */
.wpcf7-list-item {
    display: inline-flex;
    align-items: center;
    margin-bottom: 0.75rem;
    margin-right: 0;
}

.wpcf7-list-item-label {
    display: inline-flex;
    align-items: center;
    cursor: pointer;
    gap: 0.5rem;
    font-size: var(--wp--preset--font-size--s);
}

.wpcf7-checkbox input[type="checkbox"],
.wpcf7-radio input[type="radio"] {
    width: 20px;
    height: 20px;
    min-height: auto;
    margin: 0;
    padding: 0;
    cursor: pointer;
    flex-shrink: 0;
    accent-color: var(--wp--preset--color--primary);
}

/* Remove default form control styling from checkboxes/radios */
.wpcf7-checkbox .wpcf7-list-item input[type="checkbox"],
.wpcf7-radio .wpcf7-list-item input[type="radio"] {
    background-color: transparent;
    border: 1px solid rgba(255, 255, 255, 0.4);
}

/* File upload */
.wpcf7-file {
    padding: 0.75rem 1rem;
    cursor: pointer;
}

.wpcf7-file::-webkit-file-upload-button {
    padding: 0.5rem 1rem;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 5px;
    background-color: rgba(255, 255, 255, 0.1);
    color: var(--wp--preset--color--base);
    cursor: pointer;
    transition: all 0.3s ease;
}

.wpcf7-file::-webkit-file-upload-button:hover {
    background-color: rgba(255, 255, 255, 0.2);
}

/* Submit Button */
.wpcf7-submit {
    background-color: var(--wp--preset--color--dark-magenta);
    border-radius: 40px;
    padding: 1rem 2.25rem;
    text-transform: uppercase;
    border: 1px solid rgba(255, 255, 255, 0.3);
    cursor: pointer;
    font-weight: 600;
    letter-spacing: 0.05em;
    transition: all 0.3s ease;
    min-width: 200px;

    /* Fake gradient text for input elements */
    color: transparent;
    background-image: var(--wp--preset--gradient--light-gradient);
    -webkit-background-clip: text;
    background-clip: text;
}

/* Remove your current pseudo background layer */
.wpcf7-submit::before {
    display: none;
}

/* Button hover state */
.wpcf7-submit:hover {
    transform: translateY(-2px);
    box-shadow: inset 0 0 15px rgba(135, 135, 135, 0.1), 
                0 0 18px 3px rgba(0, 0, 0, 0.3);
}

/* Button active state */
.wpcf7-submit:active {
    transform: translateY(0);
}

/* Button disabled state */
.wpcf7-submit:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* Validation errors */
.wpcf7-not-valid {
    border-color: rgba(255, 100, 100, 0.8) !important;
    background-color: rgba(255, 100, 100, 0.1) !important;
}

.wpcf7-not-valid-tip {
    color: #ffcccc;
    font-size: 0.875rem;
    margin-top: 0.5rem;
    display: block;
}

/* Response messages */
.wpcf7-response-output {
    margin: 1.5rem 0 0 0;
    padding: 1rem 1.25rem;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    text-align: center;
}

.wpcf7-mail-sent-ok {
    background-color: rgba(100, 255, 100, 0.1);
    border-color: rgba(100, 255, 100, 0.5);
    color: #ccffcc;
}

.wpcf7-mail-sent-ng,
.wpcf7-validation-errors,
.wpcf7-acceptance-missing {
    background-color: rgba(255, 100, 100, 0.1);
    border-color: rgba(255, 100, 100, 0.5);
    color: #ffcccc;
}

.wpcf7-spam-blocked {
    background-color: rgba(255, 165, 0, 0.1);
    border-color: rgba(255, 165, 0, 0.5);
    color: #ffd699;
}

/* Loading spinner */
.wpcf7-spinner {
    margin-left: 1rem;
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: var(--wp--preset--color--base);
    border-radius: 50%;
    animation: wpcf7-spin 0.8s linear infinite;
}

@keyframes wpcf7-spin {
    to { transform: rotate(360deg); }
}



.wpcf7-acceptance .wpcf7-list-item {
    display: flex;
    align-items: center;  
    gap: 0.75rem;
    margin: 0;
}


.wpcf7-acceptance .wpcf7-list-item-label {
    flex: 1;
    line-height: 1.5;
}

.wpcf7-acceptance input[type="checkbox"] {
    margin-left: 0;
    transform: translateY(-1px); /* tiny optical alignment */
}


.wpcf7-checkbox,
.wpcf7-radio {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 8px;
    background: transparent;
    border: none;
}

/* Quiz field */
.wpcf7-quiz {
    max-width: 150px;
}

/* reCAPTCHA */
.wpcf7-form .grecaptcha-badge {
    margin-top: 1rem;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .wpcf7-form {
        padding: 1.5rem;
    }
    
    .wpcf7-submit {
        width: 100%;
        min-width: auto;
    }
}

@media (max-width: 480px) {
    .wpcf7-form {
        padding: 1rem;
    }
    
    .wpcf7-form-control {
        padding: 0.875rem 1rem;
        font-size: 16px; /* Prevents zoom on iOS */
    }
}

/* ============================================
   Fix: Contact form section mobile overflow
   ============================================ */

/* Force columns to stack on mobile */
@media (max-width: 781px) {

    /* Remove the negative margins alignwide adds — 
       this is the main cause of horizontal scroll */
    .wp-block-group.alignfull .wp-block-columns.alignwide {
        margin-left: 0 !important;
        margin-right: 0 !important;
        max-width: 100% !important;
        overflow: hidden;
    }

    /* Override the fixed flex-basis so columns stack vertically */
    .wp-block-group.alignfull .wp-block-columns.alignwide .wp-block-column {
        flex-basis: 100% !important;
        min-width: 100% !important;
        width: 100% !important;
    }

    /* Prevent long words/headings from overflowing */
    .wp-block-group.alignfull .wp-block-columns.alignwide h3,
    .wp-block-group.alignfull .wp-block-columns.alignwide p {
        overflow-wrap: break-word;
        word-break: break-word;
        hyphens: auto;
    }

    /* Prevent the contact form (CF7) from overflowing */
    .wp-block-group.alignfull .wp-block-columns.alignwide .wpcf7 {
        max-width: 100%;
        overflow: hidden;
    }

    .wp-block-group.alignfull .wp-block-columns.alignwide .wpcf7 input,
    .wp-block-group.alignfull .wp-block-columns.alignwide .wpcf7 textarea,
    .wp-block-group.alignfull .wp-block-columns.alignwide .wpcf7 select {
        max-width: 100%;
        box-sizing: border-box;
    }
}

