/* Frontend Styles */
.afb-form-wrapper {
    max-width: 800px;
    margin: 0 auto;
    padding: 30px;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.afb-progress-bar {
    height: 6px;
    background: #e9ecef;
    border-radius: 3px;
    margin-bottom: 15px;
    overflow: hidden;
}

.afb-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #0073aa, #005a87);
    transition: width 0.3s ease;
}

.afb-step-indicator {
    text-align: center;
    margin-bottom: 30px;
    font-size: 14px;
    color: #666;
}

.afb-current-step {
    font-size: 18px;
    font-weight: 600;
    color: #0073aa;
}

.afb-step {
    display: none;
}

.afb-step.active {
    display: block;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.afb-step-title {
    font-size: 24px;
    font-weight: 600;
    margin-bottom: 25px;
    color: #333;
}

.afb-field-wrapper {
    margin-bottom: 25px;
}

.afb-field-label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    font-size: 14px;
    color: #333;
}

.afb-field-label.required::after {
    content: " *";
    color: #dc3232;
}

.afb-field-description {
    font-size: 12px;
    color: #666;
    margin-top: 5px;
    font-style: italic;
}

.afb-field-input,
.afb-field-select,
.afb-field-textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    transition: border-color 0.2s ease;
    box-sizing: border-box;
}

.afb-field-input:focus,
.afb-field-select:focus,
.afb-field-textarea:focus {
    outline: none;
    border-color: #0073aa;
    box-shadow: 0 0 0 3px rgba(0, 115, 170, 0.1);
}

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

.afb-field-error {
    border-color: #dc3232 !important;
}

.afb-error-message {
    color: #dc3232;
    font-size: 12px;
    margin-top: 5px;
}

.afb-radio-group,
.afb-checkbox-group {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.afb-radio-option,
.afb-checkbox-option {
    display: flex;
    align-items: center;
    gap: 10px;
}

.afb-radio-option input[type="radio"],
.afb-checkbox-option input[type="checkbox"] {
    margin: 0;
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.afb-radio-option label,
.afb-checkbox-option label {
    cursor: pointer;
    margin: 0;
    font-weight: normal;
}

.afb-form-navigation {
    display: flex;
    gap: 15px;
    margin-top: 30px;
    padding-top: 30px;
    border-top: 1px solid #e9ecef;
}

.afb-btn {
    padding: 12px 30px;
    border: none;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.afb-btn-prev {
    background: #f5f5f5;
    color: #333;
}

.afb-btn-prev:hover {
    background: #e9e9e9;
}

.afb-btn-next,
.afb-btn-submit {
    background: #0073aa;
    color: #fff;
    margin-left: auto;
}

.afb-btn-next:hover,
.afb-btn-submit:hover {
    background: #005a87;
}

.afb-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.afb-form-messages {
    margin-top: 20px;
}

.afb-message {
    padding: 15px 20px;
    border-radius: 4px;
    margin-bottom: 15px;
}

.afb-message-success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.afb-message-error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.afb-message-warning {
    background: #fff3cd;
    color: #856404;
    border: 1px solid #ffeaa7;
}

.afb-loading {
    position: relative;
    pointer-events: none;
    opacity: 0.6;
}

.afb-loading::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 30px;
    height: 30px;
    margin: -15px 0 0 -15px;
    border: 3px solid rgba(0, 115, 170, 0.2);
    border-top-color: #0073aa;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.afb-field-wrapper.hidden {
    display: none;
}

/* File upload */
.afb-file-upload {
    border: 2px dashed #ddd;
    border-radius: 4px;
    padding: 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s ease;
}

.afb-file-upload:hover {
    border-color: #0073aa;
    background: #f9f9f9;
}

.afb-file-upload input[type="file"] {
    display: none;
}

.afb-file-name {
    margin-top: 10px;
    font-size: 13px;
    color: #666;
}

/* Responsive */
@media (max-width: 768px) {
    .afb-form-wrapper {
        padding: 20px;
    }
    
    .afb-step-title {
        font-size: 20px;
    }
    
    .afb-form-navigation {
        flex-direction: column;
    }
    
    .afb-btn-next,
    .afb-btn-submit {
        margin-left: 0;
        order: -1;
    }
}
/* Acceptance field */
.afb-acceptance-wrapper {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.afb-acceptance-wrapper input[type="checkbox"] {
    margin-top: 4px;
    width: 18px;
    height: 18px;
    flex-shrink: 0;
}

.afb-acceptance-wrapper label {
    cursor: pointer;
    margin: 0;
    font-weight: normal;
    font-size: 14px;
}

/* HTML content field */
.afb-html-content {
    padding: 15px;
    background: #f9f9f9;
    border-radius: 4px;
    border-left: 4px solid #0073aa;
}

.afb-html-content h1,
.afb-html-content h2,
.afb-html-content h3 {
    margin-top: 0;
}

/* Honeypot - hidden from users */
.afb-honeypot {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

/* reCAPTCHA */
.afb-recaptcha-wrapper {
    margin: 20px 0;
}

/* Time and URL inputs */
input[type="time"],
input[type="url"] {
    width: 100%;
}