/**
 * Leads Manager - Frontend Forms CSS
 *
 * @package BananaProperty\LeadsManager
 */

/* Form Container */
.lm-form {
    max-width: 600px;
    margin: 0 auto;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

/* Agent Header Section - Inspired by homepage-hero.css */
.lm-agent-header {
    background: linear-gradient(135deg, rgba(52, 152, 219, 0.95) 50%, rgba(41, 128, 185, 0.95) 100%);
    padding: 30px 25px;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 30px;
}

.lm-agent-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 20% 50%, rgba(255, 255, 255, 0.05) 0%, transparent 50%),
        radial-gradient(circle at 80% 50%, rgba(255, 255, 255, 0.05) 0%, transparent 50%);
    pointer-events: none;
}

/* Agent Picture Wrapper - Left Side */
.lm-agent-pic-wrapper {
    position: relative;
    z-index: 1;
    flex-shrink: 0;
}

/* Agent Picture Container */
.lm-agent-pic {
    position: relative;
    display: inline-block;
}

.lm-agent-pic img {
    width: 90px;
    height: 90px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid rgba(255, 255, 255, 1);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: block;
}

.lm-agent-pic img:hover {
    filter: brightness(1.15);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4);
}

/* Agent Info Section - Right Side */
.lm-agent-info {
    position: relative;
    z-index: 1;
    flex: 1;
    text-align: left;
}

.lm-agent-name {
    font-size: 26px;
    font-weight: 700;
    margin: 0 0 10px 0;
    line-height: 1.2;
    color: #ffffff;
}

.lm-agent-response {
    font-size: 14px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.9);
    margin: 0;
}

/* Form Wrapper */
.lm-form-wrapper {
    padding: 30px 25px;
    width: 100%;
}

/* Form Fields */
.lm-form-field {
    margin-bottom: 20px;
}

.lm-form-field label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #374151;
    font-size: 14px;
}

.lm-required {
    color: #ef4444;
}

.lm-input,
.lm-textarea,
.lm-select {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    font-size: 15px;
    font-family: inherit;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
    background: #ffffff;
    box-sizing: border-box;
}

.lm-input:focus,
.lm-textarea:focus,
.lm-select:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

.lm-input::placeholder,
.lm-textarea::placeholder {
    color: #9ca3af;
}

.lm-textarea {
    resize: vertical;
    min-height: 120px;
}

.lm-field-description {
    margin-top: 6px;
    font-size: 13px;
    color: #6b7280;
}

/* Radio and Checkbox */
.lm-radio-group,
.lm-checkbox-group {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.lm-radio-label,
.lm-checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 15px;
    color: #374151;
}

.lm-radio,
.lm-checkbox {
    cursor: pointer;
    width: 18px;
    height: 18px;
    margin-right:6px;
}

/* Submit Button */
.lm-form-submit {
    margin-top: 25px;
}

.lm-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 28px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s ease;
}

.lm-btn-primary {
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    color: #ffffff;
    width: 100%;
    box-shadow: 0 4px 12px rgba(52, 152, 219, 0.3);
}

.lm-btn-primary:hover {
    background: linear-gradient(135deg, #2980b9 0%, #2574a9 100%);
    box-shadow: 0 6px 20px rgba(52, 152, 219, 0.4);
    transform: translateY(-2px);
}

.lm-btn-primary:active {
    transform: translateY(0);
}

/* CAPTCHA */
.lm-captcha-wrapper {
    margin: 20px 0;
}

/* Messages */
.lm-form-message {
    padding: 12px 16px;
    border-radius: 8px;
    margin-bottom: 20px;
    font-weight: 500;
    font-size: 14px;
}

.lm-form-message-success {
    background: #d1fae5;
    color: #065f46;
    border: 2px solid #10b981;
}

.lm-form-message-error {
    background: #fee2e2;
    color: #991b1b;
    border: 2px solid #ef4444;
}

.lm-field-error {
    color: #ef4444;
    font-size: 13px;
    margin-top: 6px;
    display: block;
}

.lm-form-error {
    background: #fee2e2;
    color: #991b1b;
    border: 2px solid #ef4444;
    padding: 16px;
    border-radius: 8px;
    text-align: center;
    font-weight: 500;
}

/* Loading State */
.lm-form-wrapper.loading {
    opacity: 0.6;
    pointer-events: none;
}

.lm-form-wrapper.loading .lm-btn-primary::after {
    content: '...';
    animation: loading 1s infinite;
}

@keyframes loading {
    0%, 20% { content: '.'; }
    40% { content: '..'; }
    60%, 100% { content: '...'; }
}

/* Responsive */
@media (max-width: 768px) {
    .lm-form {
        margin: 1rem;
        border-radius: 8px;
    }

    .lm-agent-header {
        padding: 25px 20px;
        flex-direction: column;
        text-align: center;
        gap: 20px;
    }

    .lm-agent-pic img {
        width: 80px;
        height: 80px;
    }

    .lm-agent-info {
        text-align: center;
    }

    .lm-agent-name {
        font-size: 24px;
    }

    .lm-form-wrapper {
        padding: 25px 20px;
    }
}

@media (max-width: 480px) {
    .lm-form {
        margin: 0.5rem;
        border-radius: 8px;
    }

    .lm-agent-header {
        padding: 20px 15px;
        gap: 15px;
    }

    .lm-agent-pic img {
        width: 70px;
        height: 70px;
        border-width: 2px;
    }

    .lm-agent-name {
        font-size: 22px;
    }

    .lm-agent-response {
        font-size: 13px;
    }

    .lm-form-wrapper {
        padding: 20px 15px;
    }

    .lm-input,
    .lm-textarea,
    .lm-select {
        padding: 10px 14px;
        font-size: 14px;
    }

    .lm-btn {
        padding: 12px 24px;
        font-size: 15px;
    }
}
