﻿/* Custom CSS for Complaint Management System */

:root {
    --primary-color: #0d6efd;
    --secondary-color: #6c757d;
    --success-color: #198754;
    --danger-color: #dc3545;
    --warning-color: #ffc107;
    --info-color: #0dcaf0;
    --light-color: #f8f9fa;
    --dark-color: #212529;
    --border-radius: 0.5rem;
    --box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
    --box-shadow-lg: 0 1rem 3rem rgba(0, 0, 0, 0.175);
}

/* Global Styles */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: var(--dark-color);
}

.bg-gradient-primary {
    background: linear-gradient(135deg, var(--primary-color) 0%, #0056b3 100%);
}

/* Hero Section */
.hero-section {
    min-height: 70vh;
    display: flex;
    align-items: center;
}

.hero-icon {
    font-size: 15rem;
    opacity: 0.1;
    animation: float 3s ease-in-out infinite;
}

.about-icon {
    font-size: 12rem;
    color: var(--primary-color);
    opacity: 0.2;
    animation: float 3s ease-in-out infinite reverse;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-20px);
    }
}

/* Feature Cards */
.feature-card {
    background: white;
    padding: 2rem;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid #e9ecef;
}

    .feature-card:hover {
        transform: translateY(-5px);
        box-shadow: var(--box-shadow-lg);
    }

.feature-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, var(--primary-color), #0056b3);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    color: white;
    font-size: 2rem;
}

.feature-card h4 {
    color: var(--dark-color);
    margin-bottom: 1rem;
    font-weight: 600;
}

.feature-card p {
    color: var(--secondary-color);
    margin-bottom: 0;
}

/* Statistics */
.stat-item {
    padding: 1rem;
}

.stat-icon {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: bold;
    color: var(--dark-color);
    margin-bottom: 0.5rem;
}

.stat-label {
    color: var(--secondary-color);
    font-size: 1.1rem;
    margin-bottom: 0;
}

/* Forms */
.form-container {
    max-width: 500px;
    margin: 0 auto;
    padding: 2rem;
    background: white;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow-lg);
}

.form-floating {
    margin-bottom: 1rem;
}

.form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.25);
}

.btn-primary {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    padding: 0.75rem 2rem;
    font-weight: 500;
    border-radius: var(--border-radius);
}

    .btn-primary:hover {
        background-color: #0056b3;
        border-color: #0056b3;
    }

/* Dashboard Styles */
.dashboard-card {
    background: white;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    padding: 1rem;
    margin-bottom: 1rem;
    border: 1px solid #e9ecef;
    transition: box-shadow 0.3s ease;
}

    .dashboard-card:hover {
        box-shadow: var(--box-shadow-lg);
    }

.dashboard-stat {
    text-align: center;
}

.dashboard-stat-icon {
    font-size: 3rem;
    margin-bottom: 0.7rem;
}

.dashboard-stat-number {
    font-size: 2.5rem;
    font-weight: bold;
    margin-bottom: 0.5rem;
}

.dashboard-stat-label {
    color: var(--secondary-color);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Priority Colors */
.priority-low {
    color: var(--success-color);
}

.priority-medium {
    color: var(--warning-color);
}

.priority-high {
    color: #fd7e14;
}

.priority-critical {
    color: var(--danger-color);
}

.badge-priority-low {
    background-color: var(--success-color);
}

.badge-priority-medium {
    background-color: var(--warning-color);
    color: var(--dark-color);
}

.badge-priority-high {
    background-color: #fd7e14;
}

.badge-priority-critical {
    background-color: var(--danger-color);
}

/* Status Colors */
.status-pending {
    color: var(--info-color);
}

.status-in-progress {
    color: var(--warning-color);
}

.status-on-hold {
    color: #fd7e14;
}

.status-resolved {
    color: var(--success-color);
}

.status-closed {
    color: var(--secondary-color);
}

.status-reopened {
    color: var(--danger-color);
}

.status-assigned {
    color: #5f5fff;
}

.status-client-replied {
    color: #567189;
}

.badge-status-pending {
    background-color: var(--info-color);
}

.badge-status-in-progress {
    background-color: var(--warning-color);
    color: var(--dark-color);
}

.badge-status-on-hold {
    background-color: #fd7e14;
}

.badge-status-resolved {
    background-color: var(--success-color);
}

.badge-status-closed {
    background-color: var(--secondary-color);
}

.badge-status-reopened {
    background-color: var(--danger-color);
}

.badge-status-assigned {
    background-color: #5f5fff;
}
.badge-status-under-review {
    background-color: #607D8B;
}
.badge-status-client-replied {
    background-color: #567189;
}

/* Table Styles */
.table-responsive {
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
}
.form-label {
    margin-bottom: 0;
}
.table {
    margin-bottom: 0;
}

    .table th {
        background-color: var(--light-color);
        border-top: none;
        font-weight: 600;
        color: var(--dark-color);
        padding: 0.5rem 0.75rem;
    }

    .table td {
        padding: 0.3rem 0.75rem;
        vertical-align: middle;
    }

.table-hover tbody tr:hover {
    background-color: rgba(13, 110, 253, 0.05);
}

/* Timeline Styles */
.timeline {
    position: relative;
    padding-left: 2rem;
}

    .timeline::before {
        content: '';
        position: absolute;
        left: 1rem;
        top: 0;
        bottom: 0;
        width: 2px;
        background: var(--light-color);
    }

.timeline-item {
    position: relative;
    margin-bottom: 2rem;
    background: white;
    padding: 1.5rem;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    margin-left: 1rem;
}

    .timeline-item::before {
        content: '';
        position: absolute;
        left: -1.5rem;
        top: 1.5rem;
        width: 12px;
        height: 12px;
        background: var(--primary-color);
        border-radius: 50%;
        border: 3px solid white;
        box-shadow: 0 0 0 3px var(--light-color);
    }

.timeline-date {
    color: var(--secondary-color);
    font-size: 0.875rem;
    margin-bottom: 0.5rem;
}

.timeline-content h6 {
    color: var(--dark-color);
    margin-bottom: 0.5rem;
}

.timeline-content p {
    color: var(--secondary-color);
    margin-bottom: 0;
}

/* Sidebar */
.sidebar {
    background: white;
    box-shadow: var(--box-shadow);
    min-height: calc(100vh - 76px);
    padding: 1.5rem 0;
}

    .sidebar .nav-link {
        color: var(--dark-color);
        padding: 0.75rem 1.5rem;
        border-radius: 0;
        transition: all 0.3s ease;
    }

        .sidebar .nav-link:hover,
        .sidebar .nav-link.active {
            background-color: var(--primary-color);
            color: white;
        }

        .sidebar .nav-link i {
            width: 20px;
            margin-right: 0.5rem;
        }

/* Alerts */
.alert {
    border: none;
    border-radius: var(--border-radius);
    padding: 1rem 1.5rem;
}

.alert-dismissible .btn-close {
    padding: 1.25rem 1.5rem;
}

/* Loading Spinner */
.loading-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* File Upload */
.file-upload-area {
    border: 2px dashed #dee2e6;
    border-radius: var(--border-radius);
    padding: 2rem;
    text-align: center;
    transition: border-color 0.3s ease;
    cursor: pointer;
}

    .file-upload-area:hover {
        border-color: var(--primary-color);
    }

    .file-upload-area.dragover {
        border-color: var(--primary-color);
        background-color: rgba(13, 110, 253, 0.05);
    }

/* Modal Styles */
.modal-content {
    border: none;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow-lg);
}

.modal-header {
    background-color: var(--light-color);
    border-bottom: 1px solid #dee2e6;
    border-radius: var(--border-radius) var(--border-radius) 0 0;
}

.modal-footer {
    background-color: var(--light-color);
    border-top: 1px solid #dee2e6;
    border-radius: 0 0 var(--border-radius) var(--border-radius);
}

/* Responsive Design */
@media (max-width: 768px) {
    .hero-section {
        min-height: 50vh;
        text-align: center;
    }

    .hero-icon {
        font-size: 8rem;
    }

    .about-icon {
        font-size: 6rem;
    }

    .feature-card {
        margin-bottom: 2rem;
    }

    .dashboard-card {
        margin-bottom: 1rem;
    }

    .table-responsive {
        font-size: 0.875rem;
    }

    .sidebar {
        min-height: auto;
    }
}

@media (max-width: 576px) {
    .form-container {
        padding: 1.5rem;
        margin: 1rem;
    }

    .dashboard-stat {
        padding: 1rem;
    }

    .dashboard-stat-icon {
        font-size: 2rem;
    }

    .dashboard-stat-number {
        font-size: 1.8rem;
    }

    .timeline {
        padding-left: 1rem;
    }

    .timeline-item {
        margin-left: 0.5rem;
        padding: 1rem;
    }
}

/* Print Styles */
@media print {
    .navbar,
    .sidebar,
    .btn,
    .modal,
    .alert {
        display: none !important;
    }

    .container-fluid {
        padding: 0;
    }

    .dashboard-card {
        box-shadow: none;
        border: 1px solid #dee2e6;
        break-inside: avoid;
    }
}

/* Accessibility */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Focus styles for better accessibility */
.btn:focus,
.form-control:focus,
.nav-link:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .feature-card,
    .dashboard-card {
        border: 2px solid var(--dark-color);
    }

    .btn-primary {
        border: 2px solid var(--dark-color);
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
    :root {
        --light-color: #343a40;
        --dark-color: #f8f9fa;
    }

    body {
        background-color: #121212;
        color: var(--dark-color);
    }

    .feature-card,
    .dashboard-card,
    .form-container {
        background-color: #1e1e1e;
        border-color: #343a40;
    }

    .table th {
        background-color: #343a40;
    }

    .sidebar {
        background-color: #1e1e1e;
    }
}
