/* Feedback Page Styles */

.feedback-page {
    min-height: 100vh;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    padding: 2rem 0;
}

.feedback-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* Page Header */
.page-header {
    text-align: center;
    margin-bottom: 2rem;
    padding: 3rem 0 1.5rem 0;
}

.page-header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 1rem;
    font-family: 'Playfair Display', serif;
}

.page-header h1 i {
    margin-right: 1rem;
    color: #667eea;
}

.page-header p {
    font-size: 1.2rem;
    color: #64748b;
    max-width: 600px;
    margin: 0 auto;
}

/* Loading Section */
.loading-section {
    text-align: center;
    padding: 4rem 0;
}

.loading-spinner {
    margin-bottom: 1rem;
}

.loading-spinner i {
    font-size: 2rem;
    color: #667eea;
}

/* Section Headers */
.section-header {
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid #e2e8f0;
}

.section-header h2 {
    font-size: 1.8rem;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
}

.section-header h2 i {
    margin-right: 0.8rem;
    color: #667eea;
}

.section-header p {
    color: #64748b;
    font-size: 1rem;
}

/* Submit Feedback Section */
.submit-feedback-section {
    background: white;
    border-radius: 20px;
    padding: 2.5rem;
    margin-bottom: 3rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    border: 1px solid #e2e8f0;
}

/* Feedback Form */
.feedback-form .form-group {
    margin-bottom: 1.5rem;
}

.feedback-form label {
    display: flex;
    align-items: center;
    font-weight: 600;
    color: #374151;
    margin-bottom: 0.5rem;
    font-size: 0.95rem;
}

.feedback-form label i {
    margin-right: 0.5rem;
    color: #667eea;
    width: 16px;
}

.feedback-form input,
.feedback-form select,
.feedback-form textarea {
    width: 100%;
    padding: 0.875rem 1rem;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 1rem;
    transition: all 0.3s ease;
    font-family: 'Inter', sans-serif;
}

.feedback-form input:focus,
.feedback-form select:focus,
.feedback-form textarea:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.feedback-form textarea {
    resize: vertical;
    min-height: 120px;
    line-height: 1.6;
}

.char-counter {
    text-align: right;
    font-size: 0.875rem;
    color: #64748b;
    margin-top: 0.25rem;
}

.char-counter.warning {
    color: #f59e0b;
}

.char-counter.danger {
    color: #ef4444;
}

.form-actions {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e2e8f0;
}

/* Feedback History Section */
.feedback-history-section {
    background: white;
    border-radius: 20px;
    padding: 2.5rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    border: 1px solid #e2e8f0;
}

.history-controls {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.filter-select {
    padding: 0.5rem 0.75rem;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    background: white;
    font-size: 0.875rem;
    min-width: 150px;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 4rem 2rem;
    color: #64748b;
}

.empty-icon {
    font-size: 4rem;
    margin-bottom: 1.5rem;
    opacity: 0.5;
}

.empty-state h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: #374151;
}

/* Feedback List */
.feedback-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.feedback-item {
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 1.5rem;
    background: #fafbfc;
    transition: all 0.3s ease;
    cursor: pointer;
}

.feedback-item:hover {
    border-color: #667eea;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.15);
}

.feedback-item-header {
    display: flex;
    justify-content: between;
    align-items: flex-start;
    margin-bottom: 1rem;
}

.feedback-item-title {
    flex: 1;
}

.feedback-item-title h4 {
    font-size: 1.1rem;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 0.25rem;
}

.feedback-item-meta {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 0.875rem;
    color: #64748b;
    margin-bottom: 0.5rem;
}

.feedback-type {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 500;
    text-transform: uppercase;
}

.feedback-type.bug {
    background: #fef2f2;
    color: #dc2626;
}

.feedback-type.feature {
    background: #f0f9ff;
    color: #0284c7;
}

.feedback-type.improvement {
    background: #f0fdf4;
    color: #16a34a;
}

.feedback-type.complaint {
    background: #fefce8;
    color: #ca8a04;
}

.feedback-type.compliment {
    background: #fdf4ff;
    color: #a21caf;
}

.feedback-type.other {
    background: #f1f5f9;
    color: #475569;
}

.feedback-priority {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.5rem;
    border-radius: 8px;
    font-size: 0.75rem;
    font-weight: 500;
}

.feedback-priority.low {
    background: #f1f5f9;
    color: #64748b;
}

.feedback-priority.medium {
    background: #fef3c7;
    color: #d97706;
}

.feedback-priority.high {
    background: #fee2e2;
    color: #dc2626;
}

.feedback-priority.urgent {
    background: #fecaca;
    color: #b91c1c;
    animation: pulse 2s infinite;
}

.feedback-status {
    display: inline-flex;
    align-items: center;
    padding: 0.375rem 0.75rem;
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 500;
    margin-left: auto;
}

.feedback-status.pending {
    background: #fef3c7;
    color: #92400e;
}

.feedback-status.reviewing {
    background: #dbeafe;
    color: #1e40af;
}

.feedback-status.replied {
    background: #d1fae5;
    color: #047857;
}

.feedback-status.resolved {
    background: #f0fdf4;
    color: #166534;
}

.feedback-status.closed {
    background: #f1f5f9;
    color: #475569;
}

.feedback-item-content {
    margin-bottom: 1rem;
}

.feedback-item-preview {
    color: #64748b;
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.feedback-item-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.875rem;
    color: #64748b;
}

.feedback-reply-indicator {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.feedback-reply-indicator.has-reply {
    color: #059669;
}

.feedback-reply-indicator i {
    font-size: 0.75rem;
}

/* Feedback Detail Modal */
.feedback-detail-modal {
    max-width: 800px;
    max-height: 90vh;
    overflow-y: auto;
}

.feedback-detail-content {
    padding: 1rem 0;
}

.feedback-detail-header {
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #e2e8f0;
}

.feedback-detail-meta {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin: 1rem 0;
}

.feedback-detail-meta-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
}

.feedback-detail-meta-item strong {
    color: #374151;
}

.feedback-detail-content-text {
    background: #f8fafc;
    padding: 1.5rem;
    border-radius: 8px;
    border-left: 4px solid #667eea;
    margin: 1.5rem 0;
    line-height: 1.6;
    white-space: pre-wrap;
}

.feedback-reply-section {
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e2e8f0;
}

.feedback-reply-section h4 {
    color: #374151;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.feedback-reply-content {
    background: #f0fdf4;
    padding: 1.5rem;
    border-radius: 8px;
    border-left: 4px solid #22c55e;
    line-height: 1.6;
    white-space: pre-wrap;
}

.feedback-reply-time {
    font-size: 0.875rem;
    color: #64748b;
    margin-top: 0.5rem;
}

/* Load More */
.load-more-container {
    text-align: center;
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e2e8f0;
}

/* Notifications */
.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    padding: 1rem 1.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    max-width: 400px;
    z-index: 1000;
    animation: slideInRight 0.3s ease;
}

@keyframes slideInRight {
    from { transform: translateX(100%); }
    to { transform: translateX(0); }
}

.notification.success {
    border-left: 4px solid #22c55e;
}

.notification.error {
    border-left: 4px solid #ef4444;
}

.notification.warning {
    border-left: 4px solid #f59e0b;
}

.notification.info {
    border-left: 4px solid #3b82f6;
}

.notification-content {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex: 1;
}

.notification-icon {
    font-size: 1.25rem;
}

.notification.success .notification-icon {
    color: #22c55e;
}

.notification.error .notification-icon {
    color: #ef4444;
}

.notification.warning .notification-icon {
    color: #f59e0b;
}

.notification.info .notification-icon {
    color: #3b82f6;
}

.notification-close {
    background: none;
    border: none;
    font-size: 1rem;
    color: #64748b;
    cursor: pointer;
    padding: 0.25rem;
}

.notification-close:hover {
    color: #374151;
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 1000;
    justify-content: center;
    align-items: center;
    animation: fadeIn 0.3s ease;
}

.modal-content {
    position: relative;
    background: white;
    border-radius: 15px;
    min-width: 500px;
    max-width: 90vw;
    max-height: 90vh;
    overflow: hidden;
    animation: slideInUp 0.3s ease;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.modal-header {
    padding: 1.5rem 2rem;
    border-bottom: 1px solid #eee;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--primary-color);
    color: white;
}

.modal-header h3 {
    margin: 0;
    font-size: 1.3rem;
    font-weight: 600;
}

.modal-close {
    background: none;
    border: none;
    color: white;
    font-size: 1.2rem;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 50%;
    transition: background-color 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
}

.modal-close:hover {
    background-color: rgba(255, 255, 255, 0.15);
}

.modal-body {
    padding: 2rem;
    max-height: calc(90vh - 120px);
    overflow-y: auto;
}

/* Feedback Detail Modal Specific Styles */
.feedback-detail-modal {
    min-width: 600px;
}

.feedback-detail-content {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.feedback-detail-header {
    background: #f8fafc;
    border-radius: 12px;
    padding: 1.5rem;
    border: 1px solid #e2e8f0;
}

.feedback-detail-meta {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1rem;
}

.feedback-detail-meta-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    color: #64748b;
}

.feedback-detail-meta-item i {
    color: var(--primary-color);
    width: 16px;
    text-align: center;
}

.feedback-detail-meta-item strong {
    color: #374151;
    font-weight: 600;
}

.feedback-detail-content-section {
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 1.5rem;
}

.feedback-detail-content-section h4 {
    margin: 0 0 1rem 0;
    font-size: 1.1rem;
    color: #374151;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.feedback-detail-content-section h4 i {
    color: var(--primary-color);
}

.feedback-detail-content-text {
    background: #f8fafc;
    border-radius: 8px;
    padding: 1rem;
    font-size: 0.95rem;
    line-height: 1.6;
    color: #475569;
    white-space: pre-wrap;
    word-break: break-word;
    border-left: 3px solid var(--primary-color);
}

.feedback-reply-section {
    background: #f0f9ff;
    border: 1px solid #bae6fd;
    border-radius: 12px;
    padding: 1.5rem;
}

.feedback-reply-section h4 {
    margin: 0 0 1rem 0;
    font-size: 1.1rem;
    color: #0369a1;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.feedback-reply-section h4 i {
    color: #0ea5e9;
}

.feedback-reply-content {
    background: white;
    border-radius: 8px;
    padding: 1rem;
    font-size: 0.95rem;
    line-height: 1.6;
    color: #475569;
    white-space: pre-wrap;
    word-break: break-word;
    border-left: 3px solid #0ea5e9;
    margin-bottom: 0.75rem;
}

.feedback-reply-time {
    font-size: 0.85rem;
    color: #64748b;
    font-style: italic;
}

/* Modal Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(-30px) scale(0.9);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* Modal Responsive Design */
@media (max-width: 768px) {
    .modal-content {
        min-width: auto;
        margin: 1rem;
        width: calc(100% - 2rem);
        max-height: calc(100vh - 2rem);
    }
    
    .feedback-detail-modal {
        min-width: auto;
    }
    
    .modal-header {
        padding: 1rem 1.5rem;
    }
    
    .modal-header h3 {
        font-size: 1.1rem;
    }
    
    .modal-body {
        padding: 1.5rem;
        max-height: calc(100vh - 160px);
    }
    
    .feedback-detail-meta {
        grid-template-columns: 1fr;
    }
    
    .feedback-detail-header,
    .feedback-detail-content-section,
    .feedback-reply-section {
        padding: 1rem;
    }
}

@media (max-width: 480px) {
    .modal-content {
        margin: 0.5rem;
        width: calc(100% - 1rem);
        border-radius: 12px;
    }
    
    .modal-header {
        padding: 1rem;
    }
    
    .modal-body {
        padding: 1rem;
    }
    
    .feedback-detail-meta-item {
        font-size: 0.85rem;
    }
    
    .feedback-detail-content-text,
    .feedback-reply-content {
        font-size: 0.9rem;
        padding: 0.75rem;
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .feedback-page {
        padding: 1rem 0;
    }
    
    .page-header h1 {
        font-size: 2rem;
    }
    
    .submit-feedback-section,
    .feedback-history-section {
        padding: 1.5rem;
        margin-bottom: 2rem;
    }
    
    .section-header {
        flex-direction: column;
        gap: 1rem;
    }
    
    .history-controls {
        width: 100%;
        justify-content: space-between;
    }
    
    .form-actions {
        flex-direction: column;
    }
    
    .feedback-item {
        padding: 1rem;
    }
    
    .feedback-item-header {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .feedback-item-meta {
        flex-wrap: wrap;
    }
    
    .feedback-detail-meta {
        grid-template-columns: 1fr;
    }
    
    .notification {
        left: 10px;
        right: 10px;
        max-width: none;
    }
}

@media (max-width: 480px) {
    .feedback-content {
        padding: 0 0.5rem;
    }
    
    .submit-feedback-section,
    .feedback-history-section {
        padding: 1rem;
        border-radius: 12px;
    }
    
    .page-header {
        padding: 1rem 0;
        margin-bottom: 2rem;
    }
}
