/* Feedback Modal Styles - All classes prefixed with fb_ for namespace isolation */

/* Modal Overlay */
.fb-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    display: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.fb-modal-overlay.active {
    display: block;
    opacity: 1;
}

/* Modal Container */
.fb-modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.7);
    background-color: white;
    border-radius: 12px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    z-index: 1001;
    opacity: 0;
    transition: all 0.3s ease;
}

.fb-modal.active {
    transform: translate(-50%, -50%) scale(1);
    opacity: 1;
}

/* Modal Header */
.fb-modal-header {
    padding: 24px 24px 16px 24px;
    border-bottom: 1px solid #e5e7eb;
}

.fb-modal-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1f2937;
    margin: 0;
}

/* Modal Body */
.fb-modal-body {
    padding: 24px;
}

/* Form Group */
.fb-form-group {
    margin-bottom: 20px;
}

.fb-form-label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: #374151;
    margin-bottom: 8px;
}

.fb-form-input,
.fb-form-textarea,
.fb-form-select {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    font-size: 1rem;
    transition: all 0.2s ease;
    background-color: #fff;
}

.fb-form-input:focus,
.fb-form-textarea:focus,
.fb-form-select:focus {
    outline: none;
    border-color: #38bdf8;
    box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.1);
}

.fb-form-textarea {
    resize: vertical;
    min-height: 100px;
}

/* Star Rating */
.fb-star-rating {
    display: flex;
    gap: 4px;
}

.fb-star {
    font-size: 24px;
    color: #d1d5db;
    cursor: pointer;
    transition: color 0.2s ease;
}

.fb-star:hover,
.fb-star.active {
    color: #fbbf24;
}

.fb-star:hover ~ .fb-star {
    color: #d1d5db;
}

/* Modal Footer */
.fb-modal-footer {
    padding: 16px 24px 24px 24px;
    border-top: 1px solid #e5e7eb;
    display: flex;
    justify-content: flex-end;
    gap: 12px;
}

.fb-btn {
    padding: 12px 24px;
    border-radius: 8px;
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
}

.fb-btn-primary {
    background-color: #38bdf8;
    color: white;
}

.fb-btn-primary:hover {
    background-color: #0ea5e9;
}

.fb-btn-primary:disabled {
    background-color: #9ca3af;
    cursor: not-allowed;
}

.fb-btn-secondary {
    background-color: #f3f4f6;
    color: #374151;
    border: 1px solid #d1d5db;
}

.fb-btn-secondary:hover {
    background-color: #e5e7eb;
}

/* Error Messages */
.fb-error-message {
    color: #dc2626;
    font-size: 0.75rem;
    margin-top: 4px;
    display: none;
}

.fb-error-message.visible {
    display: block;
}

/* Loading State */
.fb-loading {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.fb-spinner {
    width: 16px;
    height: 16px;
    border: 2px solid #f3f4f6;
    border-top: 2px solid #38bdf8;
    border-radius: 50%;
    animation: fb-spin 1s linear infinite;
}

@keyframes fb-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Success Message */
.fb-success-message {
    background-color: #d1fae5;
    color: #065f46;
    padding: 12px 16px;
    border-radius: 8px;
    margin-bottom: 16px;
    display: none;
}

.fb-success-message.visible {
    display: block;
}

/* Responsive Design */
@media (max-width: 640px) {
    .fb-modal {
        width: 95%;
        margin: 20px;
    }

    .fb-modal-header,
    .fb-modal-body,
    .fb-modal-footer {
        padding-left: 20px;
        padding-right: 20px;
    }

    .fb-modal-footer {
        flex-direction: column;
    }

    .fb-btn {
        width: 100%;
    }
}

/* Animation for modal entrance */
.fb-modal-enter {
    animation: fb-modal-enter 0.3s ease-out;
}

@keyframes fb-modal-enter {
    0% {
        transform: translate(-50%, -50%) scale(0.7);
        opacity: 0;
    }
    100% {
        transform: translate(-50%, -50%) scale(1);
        opacity: 1;
    }
}
