/* BM Feedback Manager - Frontend Styles */

.bm-feedback-form-container {
    max-width: 100%;
    margin: 0 auto;
}

.bm-feedback-form-title {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 12px;
    color: #1f2937;
    line-height: 1.3;
    background: linear-gradient(135deg, #1f2937, #4b5563);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.bm-feedback-form-description {
    font-size: 16px;
    color: #6b7280;
    margin-bottom: 32px;
    line-height: 1.7;
}

.bm-feedback-form {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.bm-feedback-field {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.bm-feedback-field-label {
    font-size: 15px;
    font-weight: 600;
    color: #374151;
    display: flex;
    align-items: center;
    gap: 6px;
    letter-spacing: 0.2px;
}

.bm-required {
    color: #ef4444;
    font-weight: bold;
}

.bm-feedback-field-input {
    width: 100%;
    padding: 12px 16px;
    font-size: 15px;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-family: inherit;
    background: #ffffff;
}

.bm-feedback-field-input:hover {
    border-color: #d1d5db;
}

.bm-feedback-field-input:focus {
    outline: none;
    border-color: #6b7280;
    box-shadow: none;
    transform: translateY(-1px);
}

.bm-feedback-field-input::placeholder {
    color: #999;
}

textarea.bm-feedback-field-input {
    resize: vertical;
    min-height: 140px;
    line-height: 1.6;
}

select.bm-feedback-field-input {
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 14 14'%3E%3Cpath fill='%238b5cf6' d='M7 10L2 5h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    padding-right: 45px;
}

.bm-feedback-radio-group,
.bm-feedback-checkbox-group {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.bm-feedback-radio-label,
.bm-feedback-checkbox-label {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 15px;
    color: #374151;
    cursor: pointer;
    padding: 12px 16px;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    background: #ffffff;
}

.bm-feedback-radio-label:hover,
.bm-feedback-checkbox-label:hover {
    background-color: #f9fafb;
    border-color: #d1d5db;
    transform: translateX(2px);
}

.bm-feedback-radio-label input[type="radio"],
.bm-feedback-checkbox-label input[type="checkbox"] {
    margin: 0;
    cursor: pointer;
}

input[type="file"].bm-feedback-field-input {
    padding: 14px;
    cursor: pointer;
    background: #f9fafb;
    border: 2px dashed #d1d5db;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

input[type="file"].bm-feedback-field-input:hover {
    border-color: #6b7280;
    background: #f3f4f6;
    transform: translateY(-1px);
}

.bm-field-description {
    font-size: 13px;
    color: #6b7280;
    margin: 8px 0 0;
    font-style: normal;
    font-weight: 500;
}

.bm-field-help-text {
    font-size: 13px;
    color: #6b7280;
    margin: 4px 0;
    line-height: 1.5;
}

.bm-file-list {
    margin-top: 12px;
    padding: 12px;
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
}

.bm-file-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    background: #ffffff;
    border-radius: 6px;
    margin-bottom: 8px;
    transition: all 0.2s ease;
}

.bm-file-item:last-child {
    margin-bottom: 0;
}

.bm-file-item:hover {
    background: #f3f4f6;
}

.bm-file-icon {
    font-size: 20px;
    flex-shrink: 0;
}

.bm-file-name {
    flex: 1;
    font-size: 14px;
    color: #374151;
    font-weight: 500;
    word-break: break-word;
}

.bm-file-size {
    font-size: 13px;
    color: #6b7280;
    flex-shrink: 0;
    margin-right: 4px;
}

.bm-file-remove {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    border: none;
    background: #ef4444;
    color: #ffffff;
    font-size: 16px;
    font-weight: 700;
    line-height: 1;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: all 0.2s ease;
    padding: 0;
    margin-left: auto;
    vertical-align: middle;
}

.bm-file-remove:hover {
    background: #dc2626;
    transform: scale(1.1);
}

.bm-file-remove:active {
    transform: scale(0.95);
}

.bm-feedback-submit-wrapper {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-top: 10px;
}

/* Button alignment support */
.bm-submit-align-left .bm-feedback-submit-wrapper {
    justify-content: flex-start;
}

.bm-submit-align-center .bm-feedback-submit-wrapper {
    justify-content: center;
}

.bm-submit-align-right .bm-feedback-submit-wrapper {
    justify-content: flex-end;
}

.bm-feedback-submit-btn {
    padding: 12px 28px;
    font-size: 15px;
    font-weight: 600;
    color: #fff;
    background: #374151;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-family: inherit;
    display: inline-block;
}

.bm-feedback-submit-btn:hover {
    background: #1f2937;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.bm-feedback-submit-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.bm-feedback-submit-btn:disabled {
    background: #9ca3af;
    cursor: not-allowed;
    transform: none;
}

.bm-feedback-loading {
    display: inline-flex;
    align-items: center;
}

.bm-feedback-loading .spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(107, 114, 128, 0.3);
    border-top-color: #6b7280;
    border-radius: 50%;
    animation: bm-spin 0.8s linear infinite;
}

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

.bm-feedback-message {
    padding: 18px 24px;
    border-radius: 12px;
    font-size: 15px;
    margin-top: 20px;
    font-weight: 500;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.bm-feedback-message.success {
    background: linear-gradient(135deg, #d1fae5, #a7f3d0);
    color: #065f46;
    border: 2px solid #6ee7b7;
}

.bm-feedback-message.error {
    background: linear-gradient(135deg, #fee2e2, #fecaca);
    color: #991b1b;
    border: 2px solid #fca5a5;
}

/* Validation Styles */
.bm-feedback-field-input.error {
    border-color: #ef4444;
    background: #fef2f2;
}

.bm-feedback-field-input.error:focus {
    box-shadow: 0 0 0 4px rgba(239, 68, 68, 0.15);
}

.bm-feedback-field-error {
    font-size: 13px;
    color: #dc2626;
    margin-top: 6px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 6px;
}

.bm-feedback-field-error::before {
    content: '⚠';
    font-size: 14px;
}

/* Responsive */
@media (max-width: 768px) {
    .bm-feedback-form-title {
        font-size: 24px;
    }
    
    .bm-feedback-form-description {
        font-size: 14px;
    }
    
    .bm-feedback-submit-btn {
        width: 100%;
    }
    
    .bm-feedback-submit-wrapper {
        flex-direction: column;
        align-items: stretch;
    }
}

/* Accessibility */
.bm-feedback-field-input:focus-visible {
    outline: none;
    border-color: #6b7280;
}

.bm-feedback-radio-label:focus-within,
.bm-feedback-checkbox-label:focus-within {
    border-color: #6b7280;
}
