/* Lead Modal Popup Styles */
.lead-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(8px);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    visibility: hidden;
    opacity: 0;
    transition: visibility 0.2s, opacity 0.3s ease;
}

.lead-modal-overlay.active {
    visibility: visible;
    opacity: 1;
}

.lead-modal-container {
    background: white;
    max-width: 500px;
    width: 90%;
    border-radius: 28px;
    overflow: hidden;
    box-shadow: 0 30px 50px rgba(0, 0, 0, 0.3);
    transform: scale(0.95);
    transition: transform 0.3s cubic-bezier(0.2, 0.9, 0.4, 1.1);
}

.lead-modal-overlay.active .lead-modal-container {
    transform: scale(1);
}

.modal-header-custom {
    background: #097232;
    padding: 20px 24px;
    color: white;
    position: relative;
}

.close-modal {
    position: absolute;
    right: 20px;
    top: 18px;
    font-size: 28px;
    cursor: pointer;
    background: none;
    border: none;
    color: white;
    opacity: 0.8;
    transition: 0.2s;
    line-height: 1;
}

.close-modal:hover {
    opacity: 1;
    transform: scale(1.05);
}

.modal-body-custom {
    padding: 28px 24px 32px;
}

.modal-body-custom .counsel-form .form-control,
.modal-body-custom .counsel-form .form-select {
    border-radius: 40px;
    border: 1px solid #e2e8f0;
    padding: 12px 20px;
    font-size: 0.95rem;
}

.modal-body-custom .counsel-phone-group {
    border: 1px solid #e2e8f0;
    border-radius: 60px;
}

.btn-submit-modal {
    background-color: #097232;
    padding: 12px;
    font-weight: 700;
    border-radius: 60px;
    border: none;
    transition: 0.2s;
}

.btn-submit-modal:hover {
    background-color: #055a27;
    transform: translateY(-2px);
}

.success-message {
    background: #e1f7e6;
    color: #097232;
    border-radius: 60px;
    padding: 12px;
    text-align: center;
    font-weight: 500;
}

@media (max-width: 576px) {
    .modal-body-custom {
        padding: 20px;
    }
    
    .modal-header-custom h4 {
        font-size: 1.2rem;
    }
}

/* Ensure modal starts hidden */
.lead-modal-overlay {
    visibility: hidden !important;
    opacity: 0 !important;
    pointer-events: none !important;
}

.lead-modal-overlay.active {
    visibility: visible !important;
    opacity: 1 !important;
    pointer-events: auto !important;
}