/* ===== GŁÓWNE STYLE SYSTEMU ===== */
:root {
    --primary-color: #667eea;
    --secondary-color: #764ba2;
    --success-color: #10b981;
    --warning-color: #f59e0b;
    --danger-color: #ef4444;
    --dark-bg: #1f2937;
    --light-bg: #f3f4f6;
    --text-dark: #374151;
    --text-light: #6b7280;
    --white: #ffffff;
    --shadow-sm: 0 5px 15px rgba(0,0,0,0.1);
    --shadow-md: 0 8px 25px rgba(0,0,0,0.15);
    --shadow-lg: 0 20px 60px rgba(0,0,0,0.3);
    --border-radius-sm: 10px;
    --border-radius-md: 15px;
    --border-radius-lg: 20px;
    --transition-fast: 0.3s;
}

/* ===== STYL LOGOWANIA ===== */
.login-body {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

.login-card {
    background: rgba(255, 255, 255, 0.95);
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-lg);
    padding: 40px;
    width: 100%;
    max-width: 400px;
    animation: slideUp 0.5s ease-out;
}

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

.login-header {
    text-align: center;
    margin-bottom: 30px;
}

.login-header h2 {
    color: var(--text-dark);
    font-weight: 600;
    margin-bottom: 10px;
}

.login-header p {
    color: var(--text-light);
    font-size: 14px;
}

.login-form .form-control {
    border: 2px solid #e0e0e0;
    border-radius: var(--border-radius-sm);
    padding: 12px 15px;
    transition: all var(--transition-fast);
}

.login-form .form-control:focus {
    border-color: var(--primary-color);
    box-shadow: none;
}

.btn-login {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    border: none;
    border-radius: var(--border-radius-sm);
    padding: 12px;
    color: var(--white);
    font-weight: 600;
    width: 100%;
    transition: transform var(--transition-fast);
}

.btn-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(102, 126, 234, 0.4);
}

.input-group-text {
    background: transparent;
    border: 2px solid #e0e0e0;
    border-right: none;
    border-radius: var(--border-radius-sm) 0 0 var(--border-radius-sm);
}

/* ===== STYLE DASHBOARDU ===== */
.dashboard-body {
    background: var(--light-bg);
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

/* Sidebar */
.sidebar {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    min-height: 100vh;
    color: var(--white);
    position: fixed;
    width: 280px;
    transition: all var(--transition-fast);
    box-shadow: 2px 0 10px rgba(0,0,0,0.1);
    z-index: 1000;
}

.sidebar-header {
    padding: 30px 20px;
    text-align: center;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.sidebar-menu {
    padding: 20px 0;
}

.sidebar-menu a {
    color: rgba(255,255,255,0.8);
    padding: 15px 25px;
    display: block;
    text-decoration: none;
    transition: all var(--transition-fast);
    font-size: 16px;
    border-left: 3px solid transparent;
}

.sidebar-menu a:hover, .sidebar-menu a.active {
    background: rgba(255,255,255,0.1);
    color: var(--white);
    border-left-color: var(--white);
}

.sidebar-menu a i {
    margin-right: 10px;
    width: 25px;
}

/* User info w sidebarze */
.user-info {
    display: flex;
    align-items: center;
    padding: 20px;
    border-top: 1px solid rgba(255,255,255,0.1);
    position: absolute;
    bottom: 0;
    width: 100%;
}

.user-avatar {
    width: 45px;
    height: 45px;
    border-radius: 12px;
    background: rgba(255,255,255,0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    margin-right: 15px;
}

.user-details {
    flex: 1;
}

.user-name {
    font-weight: 600;
    margin-bottom: 2px;
}

.user-email {
    font-size: 12px;
    opacity: 0.8;
}

/* Main content */
.main-content {
    margin-left: 280px;
    padding: 30px;
}

/* Karty statystyk */
.stat-card {
    background: var(--white);
    border-radius: var(--border-radius-md);
    padding: 25px;
    box-shadow: var(--shadow-sm);
    transition: transform var(--transition-fast);
    margin-bottom: 20px;
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
}

.stat-icon {
    width: 60px;
    height: 60px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    margin-bottom: 15px;
}

.stat-value {
    font-size: 28px;
    font-weight: 600;
    margin-bottom: 5px;
}

.stat-label {
    color: var(--text-light);
    font-size: 14px;
}

/* Badge status dla zgłoszeń */
.badge-status {
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
}

.badge-new { 
    background: #fef3c7; 
    color: #92400e; 
}

.badge-in_progress { 
    background: #dbeafe; 
    color: #1e40af; 
}

.badge-resolved { 
    background: #d1fae5; 
    color: #065f46; 
}

/* Lista ostatnich zgłoszeń */
.recent-reports {
    background: var(--white);
    border-radius: var(--border-radius-md);
    padding: 20px;
    box-shadow: var(--shadow-sm);
}

.recent-reports h5 {
    margin-bottom: 20px;
    color: var(--text-dark);
    font-weight: 600;
}

.report-item {
    padding: 15px;
    border-bottom: 1px solid #e5e7eb;
    transition: background var(--transition-fast);
}

.report-item:hover {
    background: #f9fafb;
}

.report-item:last-child {
    border-bottom: none;
}

/* ===== STYLE DLA ZARZĄDZANIA PLIKAMI ===== */
.file-card {
    transition: transform var(--transition-fast), box-shadow var(--transition-fast);
    border: none;
    border-radius: var(--border-radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
}

.file-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
}

.file-icon {
    font-size: 48px;
    color: var(--primary-color);
}

.upload-area {
    border: 2px dashed #dee2e6;
    border-radius: var(--border-radius-md);
    padding: 40px;
    text-align: center;
    background: #f8f9fa;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.upload-area:hover {
    border-color: var(--primary-color);
    background: #e8f0fe;
}

.upload-area i {
    font-size: 48px;
    color: var(--text-light);
}

.file-actions {
    position: absolute;
    top: 10px;
    right: 10px;
    opacity: 0;
    transition: opacity var(--transition-fast);
}

.file-card:hover .file-actions {
    opacity: 1;
}

/* ===== STYLE DLA ZGŁOSZEŃ ===== */
.report-card {
    transition: transform var(--transition-fast), box-shadow var(--transition-fast);
    border: none;
    border-radius: var(--border-radius-md);
    box-shadow: var(--shadow-sm);
    margin-bottom: 20px;
}

.report-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}

.report-header {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: var(--white);
    padding: 15px;
    border-radius: var(--border-radius-md) var(--border-radius-md) 0 0;
}

.report-body {
    padding: 20px;
}

.comment-section {
    background: #f8f9fa;
    border-radius: var(--border-radius-sm);
    padding: 15px;
    margin-top: 15px;
}

.comment {
    border-bottom: 1px solid #dee2e6;
    padding: 10px 0;
}

.comment:last-child {
    border-bottom: none;
}

.comment-author {
    font-weight: 600;
    color: #495057;
}

.comment-date {
    font-size: 12px;
    color: var(--text-light);
}

/* ===== MEDIA QUERIES - RESPONSYWNOŚĆ ===== */
@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
        position: fixed;
    }
    
    .sidebar.active {
        transform: translateX(0);
    }
    
    .main-content {
        margin-left: 0;
    }
    
    .login-card {
        margin: 20px;
        padding: 30px;
    }
    
    .stat-card {
        margin-bottom: 15px;
    }
}

@media (max-width: 576px) {
    .main-content {
        padding: 15px;
    }
    
    .report-header h6 {
        font-size: 14px;
    }
    
    .stat-value {
        font-size: 24px;
    }
}

/* ===== POMOCNICZE KLASY ===== */
.text-gradient {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.bg-gradient {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
}

.animate-pulse {
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* ===== STYLE DLA TABEL ===== */
.dataTables_wrapper {
    padding: 20px 0;
}

.table-hover tbody tr:hover {
    background-color: rgba(102, 126, 234, 0.05);
}

/* ===== CUSTOM SCROLLBAR ===== */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-color);
}

/* ===== SEKCJA PLIKÓW W ZGŁOSZENIACH ===== */
.files-section {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 15px;
    margin-top: 15px;
}

.file-item {
    background: white;
    transition: transform 0.2s, box-shadow 0.2s;
    cursor: pointer;
}

.file-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

/* ===== MODAL PODGLĄDU OBRAZKA ===== */
#imagePreviewModal .modal-content {
    border: none;
    border-radius: 15px;
    overflow: hidden;
}

#imagePreviewModal .modal-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

#imagePreviewModal .btn-close {
    filter: brightness(0) invert(1);
}

#imagePreviewModal .modal-body {
    background: #f8f9fa;
    padding: 0;
}

#imagePreviewModal .modal-footer {
    border-top: 1px solid #dee2e6;
    padding: 15px;
}