/*
Theme Name: Ecobridge
Theme URI: https://example.com/ecobridge
Author: Your Name
Author URI: https://example.com
Description: A modern WordPress theme for sustainable energy solutions including heat pumps, solar panels, and electric vehicles.
Version: 1.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: ecobridge
*/

/* Import Tailwind CSS - will be enqueued via CDN in functions.php */

/* Additional custom styles can be added here */
body {
    margin: 0;
    padding: 0;
}

/* CF7 Custom Form Styles - Complete Version */
.cf7-icon-form {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    width: 100%;
}

.cf7-form-wrapper {
    background-color: white;
    border-radius: 12px;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
    padding: 24px;
    border: 2px solid #a7f3d0;
    max-width: 100%;
    box-sizing: border-box;
}

@media (min-width: 768px) {
    .cf7-form-wrapper {
        border-radius: 16px;
        padding: 32px;
    }
}

@media (min-width: 1024px) {
    .cf7-form-wrapper {
        padding: 48px;
    }
}

/* Grid Layout */
.cf7-grid {
    display: block;
    margin-bottom: 24px;
}

@media (min-width: 768px) {
    .cf7-grid {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 24px;
    }
}

.cf7-field {
    margin-bottom: 24px;
}

/* Labels */
.cf7-label {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #374151;
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 8px;
    line-height: 1.25;
}

.cf7-label svg {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
}

.cf7-label .lucide-user,
.cf7-label .lucide-message-square:first-of-type {
    color: #059669;
}

.cf7-label .lucide-mail,
.cf7-label .lucide-message-square:last-of-type {
    color: #2563eb;
}

/* Form Inputs */
.cf7-form-wrapper input[type="text"].cf7-input,
.cf7-form-wrapper input[type="email"].cf7-input {
    width: 100%;
    height: 36px;
    border-radius: 6px;
    border: 2px solid #e5e7eb;
    padding: 0 12px;
    font-size: 16px;
    background-color: white;
    transition: all 0.2s ease;
    outline: none;
    box-sizing: border-box;
    margin: 0;
    font-family: inherit;
}

.cf7-form-wrapper input[type="text"].cf7-input:focus,
.cf7-form-wrapper input[type="email"].cf7-input:focus {
    border-color: #10b981;
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.1);
}

.cf7-form-wrapper input[type="email"].cf7-input:focus {
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

/* Textarea */
.cf7-form-wrapper textarea.cf7-textarea {
    width: 100%;
    min-height: 150px;
    border-radius: 6px;
    border: 2px solid #e5e7eb;
    padding: 12px;
    font-size: 16px;
    line-height: 1.5;
    background-color: white;
    transition: all 0.2s ease;
    outline: none;
    box-sizing: border-box;
    margin: 0;
    resize: vertical;
    font-family: inherit;
}

.cf7-form-wrapper textarea.cf7-textarea:focus {
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

/* Error States */
.cf7-form-wrapper .wpcf7-not-valid.cf7-input,
.cf7-form-wrapper .wpcf7-not-valid.cf7-textarea {
    border-color: #ef4444;
}

/* Submit Button */
.cf7-form-wrapper input[type="submit"].cf7-submit {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    white-space: nowrap;
    border-radius: 6px;
    font-weight: 500;
    outline: none;
    width: 100%;
    background: linear-gradient(to right, #10b981, #3b82f6);
    color: white;
    padding: 20px 16px 20px 50px;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    transform: translateY(0);
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    font-size: 16px;
    line-height: 1.5;
    text-align: center;
    margin-top: 8px;
    position: relative;
    font-family: inherit;
}

@media (min-width: 768px) {
    .cf7-form-wrapper input[type="submit"].cf7-submit {
        padding: 24px 16px 24px 56px;
        font-size: 18px;
    }
}

.cf7-form-wrapper input[type="submit"].cf7-submit:hover {
    background: linear-gradient(to right, #0da271, #2563eb);
    transform: scale(1.02);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

/* Button Icon */
.cf7-form-wrapper input[type="submit"].cf7-submit::before {
    content: '';
    position: absolute;
    left: 20px;
    top: 50%;
    transform: translateY(-50%);
    width: 20px;
    height: 20px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M14.536 21.686a.5.5 0 0 0 .937-.024l6.5-19a.496.496 0 0 0-.635-.635l-19 6.5a.5.5 0 0 0-.024.937l7.93 3.18a2 2 0 0 1 1.112 1.11z'%3E%3C/path%3E%3Cpath d='m21.854 2.147-10.94 10.939'%3E%3C/path%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;
}

@media (min-width: 768px) {
    .cf7-form-wrapper input[type="submit"].cf7-submit::before {
        width: 24px;
        height: 24px;
        left: 24px;
    }
}

/* Note text */
.cf7-note {
    font-size: 12px;
    line-height: 1;
    color: #6b7280;
    text-align: center;
    margin-top: 12px;
    margin-bottom: 0;
}

@media (min-width: 768px) {
    .cf7-note {
        font-size: 14px;
        margin-top: 16px;
    }
}

/* Validation Styles */
.cf7-form-wrapper .wpcf7-not-valid-tip {
    color: #ef4444;
    font-size: 14px;
    margin-top: 4px;
    display: block;
}

.cf7-form-wrapper .wpcf7-response-output {
    margin: 16px 0 0 0;
    padding: 16px;
    border-radius: 6px;
    font-size: 14px;
    border-width: 1px;
    text-align: center;
}

.cf7-form-wrapper .wpcf7-mail-sent-ok {
    border-color: #10b981;
    background-color: #d1fae5;
    color: #065f46;
}

.cf7-form-wrapper .wpcf7-validation-errors,
.cf7-form-wrapper .wpcf7-mail-sent-ng {
    border-color: #ef4444;
    background-color: #fee2e2;
    color: #7f1d1d;
}

/* Loading State */
.cf7-form-wrapper .wpcf7-spinner {
    display: none;
}

.cf7-form-wrapper .wpcf7-form.sending input[type="submit"].cf7-submit {
    opacity: 0.7;
    cursor: not-allowed;
    pointer-events: none;
}

/* Remove default CF7 styles */
.cf7-icon-form div.wpcf7 {
    margin: 0;
    padding: 0;
}

.cf7-icon-form .wpcf7-form-control-wrap {
    margin: 0;
    padding: 0;
    display: block;
    width: 100%;
}

.cf7-icon-form br {
    display: none;
}

/* Ensure form is responsive */
@media (max-width: 767px) {
    .cf7-form-wrapper {
        padding: 20px;
    }
    
    .cf7-field {
        margin-bottom: 20px;
    }
}
