/* Contact Form 7 Custom Styling with Background Overlay */

/* Container wrapper for background effect */
.contact-form-container {
    position: relative;
    min-height: 100vh;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 60px 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Background pattern overlay */
.contact-form-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 20% 80%, rgba(120, 119, 198, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(255, 119, 198, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 40% 40%, rgba(120, 219, 255, 0.2) 0%, transparent 50%);
    z-index: 1;
}

/* Blurred background image effect */
.contact-form-container::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1000 1000"><defs><filter id="blur"><feGaussianBlur stdDeviation="20"/></filter></defs><rect width="100%" height="100%" fill="%23f0f8ff" filter="url(%23blur)"/><circle cx="200" cy="200" r="100" fill="%23e6f3ff" filter="url(%23blur)"/><circle cx="800" cy="300" r="150" fill="%23d1e7ff" filter="url(%23blur)"/><circle cx="400" cy="700" r="120" fill="%23b8d4ff" filter="url(%23blur)"/></svg>') center/cover;
    filter: blur(20px);
    z-index: 0;
}
.wpcf7 {
    max-width: 500px;
    margin: 0 auto;
    padding: 30px 40px;
    background: rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 15px;
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.4);
    border: 1px solid rgb(54 193 63 / 80%);
    font-family: 'Roboto', 'Inter', 'Source Sans Pro', 'Segoe UI', 'Helvetica Neue', Arial, sans-serif;
    position: relative;
    z-index: 2;
    transform: translateY(0);
    transition: all 0.3s ease;
}

/* Background overlay effect */
.wpcf7::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(2, 136, 72, 0.1) 0%, rgba(30, 132, 73, 0.05) 100%);
    border-radius: 15px;
    z-index: -1;
}

/* Hover effect for form */
.wpcf7:hover {
    border: 1px solid rgba(54, 193, 63, 0.9);
    box-shadow: 
        0 20px 40px rgba(0, 0, 0, 0.15),
        inset 0 1px 0 rgba(255, 255, 255, 0.4);
}

/* Floating animation */
@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}


.wpcf7 form.invalid .wpcf7-response-output, .wpcf7 form.unaccepted .wpcf7-response-output, .wpcf7 form.payment-required .wpcf7-response-output{
    padding: 0;
    border: none;
}
.form-title {
    font-size: 22px;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 16px;
    text-align: center;
    line-height: 1.3;
}

.form-desc {
    font-size: 14px;
    color: #7f8c8d;
    margin-bottom: 20px;
    text-align: center;
    line-height: 1.4;
}

/* Form Controls Styling */
.wpcf7-form-control-wrap {
    display: block;
    margin-bottom: 15px;
    position: relative;
}

.wpcf7-form-control {
    width: 100%;
    padding: 15px 20px;
    border-radius: 8px !important;
    font-size: 14px;
    font-family: 'Roboto', 'Inter', 'Source Sans Pro', 'Segoe UI', 'Helvetica Neue', Arial, sans-serif;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    transition: all 0.3s ease;
    box-sizing: border-box;
    outline: none;
    color: #2c3e50;
    font-weight: 500;
}

.wpcf7-form-control:focus {
    border-color: rgba(2, 136, 72, 0.8);
    background: rgba(255, 255, 255, 0.4);
    box-shadow: 
        0 0 0 3px rgba(2, 136, 72, 0.2),
        0 4px 15px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.wpcf7-form-control::placeholder {
    color: rgba(44, 62, 80, 0.7);
    font-weight: 400;
}

/* Input Fields */
.wpcf7-text,
.wpcf7-tel,
.wpcf7-email {
    height: 42px;
    line-height: 1.4;
}

/* Textarea */
.wpcf7-textarea {
    min-height: 80px;
    resize: vertical;
    line-height: 1.4;
    background-color: #ffffff !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
}

.wpcf7-textarea:focus {
    border-color: rgba(2, 136, 72, 0.8) !important;
    background-color: #ffffff !important;
    box-shadow: 
        0 0 0 3px rgba(2, 136, 72, 0.2),
        0 4px 15px rgba(0, 0, 0, 0.1) !important;
    transform: translateY(-2px);
}

/* Submit Button */
.wpcf7-submit {
    background: linear-gradient(135deg, rgba(2, 136, 72, 0.9) 0%, rgba(30, 132, 73, 0.9) 100%);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.3);
    padding: 15px 30px;
    font-size: 16px;
    font-weight: 600;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    width: 100%;
    margin-top: 10px;
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: 
        0 4px 15px rgba(2, 136, 72, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.wpcf7-submit:hover {
    box-shadow: 
        0 8px 25px rgba(2, 136, 72, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
    background: linear-gradient(135deg, rgba(30, 132, 73, 0.95) 0%, rgba(2, 136, 72, 0.95) 100%);
}

.wpcf7-submit:active {
    transform: translateY(0);
}

/* Spinner Animation */
.wpcf7-spinner {
    display: none;
    width: 20px;
    height: 20px;
    border: 2px solid #ffffff;
    border-top: 2px solid transparent;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-left: 10px;
}

.wpcf7-submit:disabled + .wpcf7-spinner {
    display: inline-block;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Validation States */
.wpcf7-not-valid {
    border-color: #e74c3c !important;
    background-color: #fdf2f2;
}

.wpcf7-not-valid:focus {
    border-color: #e74c3c !important;
    box-shadow: 0 0 0 3px rgba(231, 76, 60, 0.1) !important;
}

.wpcf7-validates-as-required:invalid {
    border-color: #e74c3c;
    background-color: #fdf2f2;
}

/* Response Messages */
.wpcf7-response-output {
    margin-top: 20px;
    padding: 15px 20px;
    border-radius: 8px;
    font-weight: 500;
    text-align: center;
}

.wpcf7-mail-sent-ok {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.wpcf7-mail-sent-ng {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.wpcf7-spam-blocked {
    background-color: #fff3cd;
    color: #856404;
    border: 1px solid #ffeaa7;
}

.wpcf7-validation-errors {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* Required Field Indicator */
.wpcf7-form-control[aria-required="true"]::after {
    content: " *";
    color: #e74c3c;
    font-weight: bold;
}

/* Focus States Enhancement */
.wpcf7-form-control:focus {
    background-color: #f8fffe;
}

/* Hover Effects */
.wpcf7-form-control:hover:not(:focus) {
    border-color: #bdc3c7;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .contact-form-container {
        padding: 30px 15px;
        min-height: 100vh;
    }
    
    .wpcf7 {
        padding: 25px 20px;
        margin: 15px;
        max-width: 100%;
        animation: none; /* Disable floating on mobile */
    }
    .contact-popup-form .wpcf7{
        margin: 0;
    }

    .wpcf7:hover {
        transform: none; /* Disable hover transform on mobile */
    }
    
    .form-title {
        font-size: 20px;
        margin-bottom: 8px;
    }
    
    .form-desc {
        font-size: 13px;
        margin-bottom: 18px;
    }
    
    .wpcf7-form-control {
        padding: 12px 15px;
        font-size: 14px;
    }
    
    .wpcf7-text,
    .wpcf7-tel,
    .wpcf7-email {
        height: 45px;
    }
    
    .wpcf7-textarea {
        min-height: 80px;
    }
    
    .wpcf7-submit {
        padding: 12px 25px;
        font-size: 15px;
    }
}

@media (max-width: 480px) {
    .wpcf7 {
        padding: 20px 10px;
        margin: 10px;
    }
    .contact-popup-form .wpcf7{
        margin: 0;
    }
    .form-title {
        font-size: 20px;
    }
    
    .form-desc {
        font-size: 13px;
    }
}

/* Loading State */
.wpcf7-form.sending .wpcf7-submit {
    opacity: 0.7;
    cursor: not-allowed;
}

.wpcf7-form.sending .wpcf7-submit:hover {
    transform: none;
    box-shadow: none;
}

/* Success Animation */
.wpcf7-form.sent .wpcf7-submit {
    background: linear-gradient(135deg, #27ae60 0%, #2ecc71 100%);
    animation: successPulse 0.6s ease-in-out;
}

@keyframes successPulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

/* Error Animation */
.wpcf7-form.invalid .wpcf7-not-valid {
    animation: errorShake 0.5s ease-in-out;
}

@keyframes errorShake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    75% { transform: translateX(5px); }
}

/* Accessibility Improvements */
.wpcf7-form-control:focus {
    outline: 2px solid #028848;
    outline-offset: 2px;
}

/* High Contrast Mode Support */
@media (prefers-contrast: high) {
    .wpcf7-form-control {
        border-width: 3px;
    }
    
    .wpcf7-submit {
        border: 2px solid #000000;
    }
}

/* Reduced Motion Support */
@media (prefers-reduced-motion: reduce) {
    .wpcf7-form-control,
    .wpcf7-submit {
        transition: none;
    }
    
    .wpcf7-spinner {
        animation: none;
    }
}

.wpcf7-not-valid-tip{
    margin-top: 12px;
}

/* Contact Popup Button Styles */
.contact-popup-wrapper {
    display: inline-block;
    margin: 25px 0;
    text-align: center;
    width: 100%;
}

.contact-popup-btn {
    background: #dc2626;
    color: #ffffff;
    border: none;
    padding: 12px 24px;
    font-size: 16px;
    font-weight: 700;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-family: 'Roboto', 'Inter', 'Source Sans Pro', 'Segoe UI', 'Helvetica Neue', Arial, sans-serif;
    box-shadow: 0 4px 15px rgba(220, 38, 38, 0.3);
    position: relative;
    overflow: hidden;
}

.contact-popup-btn:hover {
    background: #b91c1c;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(220, 38, 38, 0.4);
}

.contact-popup-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 10px rgba(220, 38, 38, 0.3);
}

/* Contact Popup Modal Styles */
.contact-popup-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.contact-popup-modal.show {
    opacity: 1;
    visibility: visible;
}

.contact-popup-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
}

.contact-popup-container {
    position: relative;
    z-index: 2;
    max-width: 450px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    transform: scale(0.8);
    transition: transform 0.3s ease;
}

.contact-popup-modal.show .contact-popup-container {
    transform: scale(1);
}

.contact-popup-content {
    background: #f8fffe;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
    border: 1px solid rgba(2, 136, 72, 0.2);
    position: relative;
    overflow: hidden;
}

.contact-popup-close {
    display: none;
}


/* Form title styling */
.contact-popup-form .form-title {
    font-size: 18px;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 12px;
    text-align: center;
    line-height: 1.3;
}

.contact-popup-form .form-desc {
    font-size: 15px;
    color: #7f8c8d;
    margin-bottom: 20px;
    text-align: center;
    line-height: 1.4;
}

/* Form controls styling */
.contact-popup-form .wpcf7-form-control-wrap {
    display: block;
    margin-bottom: 12px;
    position: relative;
}

.contact-popup-form .wpcf7-form-control {
    width: 100%;
    padding: 12px 15px;
    border-radius: 6px;
    font-size: 14px;
    font-family: 'Roboto', 'Inter', 'Source Sans Pro', 'Segoe UI', 'Helvetica Neue', Arial, sans-serif;
    background: #ffffff;
    box-sizing: border-box;
    outline: none;
    font-weight: 400;
}

.contact-popup-form .wpcf7-form-control:focus {
    border-color: rgba(2, 136, 72, 0.6);
    background: #ffffff;
    box-shadow: 0 0 0 2px rgba(2, 136, 72, 0.1);
}

.contact-popup-form .wpcf7-form-control::placeholder {
    color: rgba(44, 62, 80, 0.6);
    font-weight: 400;
}

/* Input Fields */
.contact-popup-form .wpcf7-text,
.contact-popup-form .wpcf7-tel,
.contact-popup-form .wpcf7-email {
    height: 42px;
    line-height: 1.4;
}

/* Textarea */
.contact-popup-form .wpcf7-textarea {
    min-height: 70px;
    resize: vertical;
    line-height: 1.4;
    background-color: #ffffff;
    border: 1px solid rgba(44, 62, 80, 0.3);
}

.contact-popup-form .wpcf7-textarea:focus {
    border-color: rgba(2, 136, 72, 0.6);
    background-color: #ffffff;
    box-shadow: 0 0 0 2px rgba(2, 136, 72, 0.1);
}

/* Submit Button */
.contact-popup-form .wpcf7-submit {
    background: linear-gradient(135deg, #028848 0%, #1e8449 100%);
    color: #ffffff;
    border: none;
    padding: 12px 20px;
    font-size: 14px;
    font-weight: 600;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    width: 100%;
    margin-top: 8px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(2, 136, 72, 0.3);
}

.contact-popup-form .wpcf7-submit:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(2, 136, 72, 0.4);
    background: linear-gradient(135deg, #1e8449 0%, #028848 100%);
}

.contact-popup-form .wpcf7-submit:active {
    transform: translateY(0);
}

.contact-popup-modal-open {
    overflow: hidden;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .contact-popup-container {
        width: 95%;
        max-width: 400px;
        max-height: 85vh;
    }
    
    .contact-popup-content {
        border-radius: 10px;
    }
    
    .contact-popup-btn {
        padding: 10px 20px;
        font-size: 14px;
    }
    
    .contact-popup-form .form-title {
        font-size: 16px;
    }
    
    .contact-popup-form .form-desc {
        font-size: 12px;
    }
}

@media (max-width: 480px) {
    .contact-popup-container {
        max-width: 350px;
    }
    
    .contact-popup-form .wpcf7-form-control {
        padding: 10px 12px;
        font-size: 13px;
    }
    
    .contact-popup-form .wpcf7-submit {
        padding: 10px 15px;
        font-size: 13px;
    }
}

/* Contact Popup Button Styles */
.contact-popup-wrapper {
    display: inline-block;
    margin: 20px 0;
}

.contact-popup-btn {
    background: #dc2626;
    color: #ffffff;
    border: none;
    padding: 12px 24px;
    font-size: 16px;
    font-weight: 700;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-family: 'Roboto', 'Inter', 'Source Sans Pro', 'Segoe UI', 'Helvetica Neue', Arial, sans-serif;
    box-shadow: 0 4px 15px rgba(220, 38, 38, 0.3);
    position: relative;
    overflow: hidden;
}

.contact-popup-btn:hover {
    background: #b91c1c;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(220, 38, 38, 0.4);
}

.contact-popup-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 10px rgba(220, 38, 38, 0.3);
}

/* Contact Popup Modal Styles */
.contact-popup-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.contact-popup-modal.show {
    opacity: 1;
    visibility: visible;
}

.contact-popup-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
}

.contact-popup-container {
    position: relative;
    z-index: 2;
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    transform: scale(0.8);
    transition: transform 0.3s ease;
}

.contact-popup-modal.show .contact-popup-container {
    transform: scale(1);
}

.contact-popup-content {
    background: #ffffff;
    border-radius: 15px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    position: relative;
    overflow: hidden;
}

.contact-popup-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: rgba(0, 0, 0, 0.1);
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 24px;
    color: #666;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 10;
}

.contact-popup-close:hover {
    background: rgba(0, 0, 0, 0.2);
    color: #333;
    transform: rotate(90deg);
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .contact-popup-container {
        width: 95%;
        max-height: 95vh;
    }
    
    .contact-popup-content {
        border-radius: 15px;
    }
    

    
    .contact-popup-btn {
        padding: 10px 20px;
        font-size: 14px;
    }
}

@media (max-width: 480px) {
    
    .contact-popup-close {
        top: 10px;
        right: 10px;
        width: 35px;
        height: 35px;
        font-size: 20px;
    }
}
