/* ============================================
   ENVIROFLOW LEAD CAPTURE POPUP
   Professional, high-converting design
   ============================================ */

#efLeadOverlay {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 99999;
    opacity: 0;
    transition: opacity 0.3s ease;
}

#efLeadOverlay.ef-visible {
    opacity: 1;
}

.ef-popup-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.ef-popup-container {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.9);
    width: 95%;
    max-width: 520px;
    max-height: 90vh;
    overflow-y: auto;
    background: #ffffff;
    border-radius: 20px;
    box-shadow: 0 32px 64px rgba(0, 0, 0, 0.3), 0 0 0 1px rgba(0, 0, 0, 0.05);
    padding: 36px 32px 28px;
    transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

#efLeadOverlay.ef-visible .ef-popup-container {
    transform: translate(-50%, -50%) scale(1);
}

.ef-popup-close {
    position: absolute;
    top: 12px;
    right: 16px;
    width: 36px;
    height: 36px;
    border: none;
    background: #f3f4f6;
    border-radius: 50%;
    font-size: 22px;
    color: #6b7280;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    line-height: 1;
}

.ef-popup-close:hover {
    background: #ef4444;
    color: #fff;
    transform: rotate(90deg);
}

/* Badge */
.ef-popup-badge {
    display: inline-block;
    padding: 5px 14px;
    background: rgba(239, 68, 68, 0.1);
    color: #ef4444;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    border-radius: 100px;
    margin-bottom: 16px;
    animation: pulse-badge 2s infinite;
}

@keyframes pulse-badge {
    0%, 100% { box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.2); }
    50% { box-shadow: 0 0 0 6px rgba(239, 68, 68, 0); }
}

/* Icon */
.ef-popup-icon {
    font-size: 48px;
    margin-bottom: 12px;
    filter: drop-shadow(0 4px 8px rgba(0,0,0,0.1));
}

/* Title */
.ef-popup-title {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    font-size: 28px;
    font-weight: 900;
    color: #111827;
    line-height: 1.15;
    margin-bottom: 6px;
    letter-spacing: -0.02em;
}

.ef-popup-subtitle {
    font-size: 15px;
    color: #6b7280;
    margin-bottom: 20px;
    line-height: 1.5;
}

/* Value Items */
.ef-popup-value {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 24px;
}

.ef-value-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    transition: all 0.2s;
}

.ef-value-item:hover {
    border-color: #3b82f6;
    background: rgba(59, 130, 246, 0.03);
}

.ef-value-icon {
    font-size: 24px;
    flex-shrink: 0;
}

.ef-value-item div {
    flex: 1;
    min-width: 0;
}

.ef-value-item strong {
    display: block;
    font-size: 14px;
    font-weight: 700;
    color: #111827;
    line-height: 1.3;
}

.ef-value-item span {
    font-size: 12px;
    color: #9ca3af;
}

.ef-value-price {
    font-size: 14px;
    font-weight: 800;
    color: #10b981;
    white-space: nowrap;
    flex-shrink: 0;
}

.ef-value-price s {
    color: #d1d5db;
    font-weight: 400;
    font-size: 12px;
    margin-left: 4px;
}

/* CTA Button */
.ef-popup-cta {
    width: 100%;
    padding: 16px 24px;
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    color: #fff;
    border: none;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 800;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    cursor: pointer;
    transition: all 0.2s;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

.ef-popup-cta:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(37, 99, 235, 0.4);
}

.ef-popup-cta:active {
    transform: translateY(0);
}

.ef-popup-cta:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.ef-popup-secondary {
    width: 100%;
    padding: 12px;
    background: transparent;
    color: #6b7280;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    cursor: pointer;
    transition: all 0.2s;
    margin-top: 8px;
}

.ef-popup-secondary:hover {
    background: #f9fafb;
    border-color: #d1d5db;
}

.ef-popup-cta-group {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.ef-popup-disclaimer {
    text-align: center;
    font-size: 12px;
    color: #9ca3af;
    margin-top: 12px;
}

/* Form */
.ef-popup-form {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 16px;
    margin-bottom: 4px;
}

.ef-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.ef-form-field input,
.ef-form-field select {
    width: 100%;
    padding: 12px 14px;
    border: 2px solid #e5e7eb;
    border-radius: 10px;
    font-size: 14px;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    color: #111827;
    background: #fff;
    transition: all 0.2s;
    -webkit-appearance: none;
    appearance: none;
}

.ef-form-field select {
    background: #fff 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='%236b7280' d='M2 4l4 4 4-4'/%3E%3C/svg%3E") no-repeat right 14px center;
    padding-right: 36px;
}

.ef-form-field input:focus,
.ef-form-field select:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.12);
}

.ef-form-field input::placeholder {
    color: #9ca3af;
}

/* Success step */
.ef-popup-success-icon {
    font-size: 64px;
    margin-bottom: 12px;
    animation: success-bounce 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes success-bounce {
    0% { transform: scale(0); }
    50% { transform: scale(1.2); }
    100% { transform: scale(1); }
}

.ef-popup-next-steps {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin: 20px 0;
    text-align: left;
}

.ef-next-step {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 12px;
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    border-radius: 10px;
}

.ef-step-num {
    width: 28px;
    height: 28px;
    background: #10b981;
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    font-weight: 800;
    flex-shrink: 0;
}

.ef-next-step strong {
    display: block;
    font-size: 14px;
    color: #111827;
    line-height: 1.3;
}

.ef-next-step span {
    font-size: 12px;
    color: #6b7280;
}

/* Steps center alignment */
.ef-popup-step {
    text-align: center;
}

/* Scrollbar */
.ef-popup-container::-webkit-scrollbar {
    width: 4px;
}

.ef-popup-container::-webkit-scrollbar-thumb {
    background: #d1d5db;
    border-radius: 2px;
}

/* Mobile */
@media (max-width: 600px) {
    .ef-popup-container {
        width: 97%;
        max-width: 100%;
        padding: 28px 20px 24px;
        border-radius: 16px;
        max-height: 95vh;
    }
    
    .ef-popup-title {
        font-size: 22px;
    }
    
    .ef-form-row {
        grid-template-columns: 1fr;
    }
    
    .ef-value-item {
        padding: 10px 12px;
    }
    
    .ef-value-price {
        font-size: 12px;
    }
    
    .ef-popup-cta {
        font-size: 15px;
        padding: 14px 20px;
    }
}
