/* Variables CSS */
:root {
    --primary: #0D1B2A;
    --secondary: #6C757D;
    --background: #F8F9FA;
    --accent: #415A77;
    --danger: #E74C3C;
    --success: #27AE60;
    --warning: #F39C12;
}

/* Styles généraux */
body {
    font-family: 'Roboto', sans-serif;
    background-color: var(--background);
}

/* Navigation */
.navbar-blur {
    backdrop-filter: blur(10px);
    background: rgba(13, 27, 42, 0.95);
    transition: all 0.3s ease;
}

.navbar-blur.shadow-lg {
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

/* Cards */
.card-hover {
    transition: all 0.3s ease-in-out;
}

.card-hover:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
}

/* Boutons */
.btn-primary {
    background: linear-gradient(135deg, var(--accent) 0%, var(--primary) 100%);
    color: white;
    padding: 1rem 2rem;
    border: none;
    border-radius: 10px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(65, 90, 119, 0.3);
}

.btn-primary:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.btn-secondary {
    background: var(--secondary);
    color: white;
    padding: 0.5rem 1rem;
    border: none;
    border-radius: 6px;
    font-size: 0.8rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-secondary:hover {
    background: #5a6268;
}

/* Formulaires */
.form-input {
    width: 100%;
    padding: 1rem;
    border: 2px solid #e5e7eb;
    border-radius: 10px;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: white;
}

.form-input:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(65, 90, 119, 0.1);
}

.form-input:read-only {
    background: #f8f9fa;
    cursor: not-allowed;
}

/* Sidebar */
.sidebar {
    background: white;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    border: 1px solid #e5e7eb;
}

.nav-item {
    padding: 1rem 1.5rem;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    margin-bottom: 0.5rem;
    text-decoration: none;
    color: inherit;
}

.nav-item:hover {
    background: rgba(65, 90, 119, 0.1);
    text-decoration: none;
    color: inherit;
}

.nav-item.active {
    background: var(--accent);
    color: white;
    text-decoration: none;
}

.nav-item.active:hover {
    color: white;
}

/* User info */
.user-info {
    background: linear-gradient(135deg, var(--accent) 0%, var(--primary) 100%);
    color: white;
    padding: 1.5rem;
    border-radius: 15px;
    margin-bottom: 2rem;
}

/* Main cards */
.main-card {
    background: white;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    border: 1px solid #e5e7eb;
}

/* Stats cards */
.stats-card {
    background: white;
    border-radius: 10px;
    padding: 1.5rem;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    border: 1px solid #e5e7eb;
    text-align: center;
    transition: all 0.3s ease;
}

.stats-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
}

.stats-number {
    font-size: 2rem;
    font-weight: bold;
    margin-bottom: 0.5rem;
}

.stats-label {
    color: var(--secondary);
    font-size: 0.9rem;
}

/* Report cards */
.report-card {
    background: white;
    border-radius: 10px;
    padding: 1.5rem;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    border: 1px solid #e5e7eb;
    transition: all 0.3s ease;
}

.report-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
}

/* Contact cards */
.contact-card {
    background: white;
    border-radius: 10px;
    padding: 2rem;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    border: 1px solid #e5e7eb;
    text-align: center;
    transition: all 0.3s ease;
}

.contact-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
}

.contact-icon {
    background: linear-gradient(135deg, var(--accent) 0%, var(--primary) 100%);
    color: white;
    width: 80px;
    height: 80px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    margin: 0 auto 1.5rem;
}

/* Classification selector */
.class-selector {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    margin-bottom: 2rem;
}

.class-option {
    padding: 1rem;
    border: 2px solid #e5e7eb;
    border-radius: 10px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.class-option:hover {
    border-color: var(--accent);
    background: rgba(65, 90, 119, 0.05);
}

.class-option.selected {
    border-color: var(--accent);
    background: var(--accent);
    color: white;
}

.class-normal { --class-color: var(--success); }
.class-alert { --class-color: var(--warning); }
.class-incident { --class-color: var(--danger); }
.class-urgent { --class-color: #8B0000; }

/* File upload */
.file-upload {
    border: 2px dashed #e5e7eb;
    border-radius: 10px;
    padding: 2rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.file-upload:hover {
    border-color: var(--accent);
    background: rgba(65, 90, 119, 0.05);
}

.file-upload.dragover {
    border-color: var(--accent);
    background: rgba(65, 90, 119, 0.1);
}

/* Table */
.table-container {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    border: 1px solid #e5e7eb;
}

.table-header {
    background: linear-gradient(135deg, var(--accent) 0%, var(--primary) 100%);
    color: white;
    padding: 1rem;
}

.table-row {
    border-bottom: 1px solid #e5e7eb;
    transition: all 0.3s ease;
}

.table-row:hover {
    background: rgba(65, 90, 119, 0.05);
}

.table-cell {
    padding: 1rem;
    vertical-align: top;
}

/* Badges */
.class-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
}

.class-normal {
    background: rgba(39, 174, 96, 0.1);
    color: var(--success);
}

.class-alert {
    background: rgba(243, 156, 18, 0.1);
    color: var(--warning);
}

.class-incident {
    background: rgba(231, 76, 60, 0.1);
    color: var(--danger);
}

.class-urgent {
    background: rgba(139, 0, 0, 0.1);
    color: #8B0000;
}

.status-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
}

.status-generated {
    background: rgba(39, 174, 96, 0.1);
    color: var(--success);
}

.status-pending {
    background: rgba(243, 156, 18, 0.1);
    color: var(--warning);
}

.status-error {
    background: rgba(231, 76, 60, 0.1);
    color: var(--danger);
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    margin-top: 2rem;
}

.pagination button {
    padding: 0.5rem 1rem;
    border: 1px solid #e5e7eb;
    background: white;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.pagination button:hover {
    background: var(--accent);
    color: white;
}

.pagination button.active {
    background: var(--accent);
    color: white;
}

/* FAQ */
.faq-item {
    background: white;
    border-radius: 10px;
    border: 1px solid #e5e7eb;
    margin-bottom: 1rem;
    overflow: hidden;
    transition: all 0.3s ease;
}

.faq-question {
    padding: 1.5rem;
    cursor: pointer;
    display: flex;
    justify-content: between;
    align-items: center;
    font-weight: 600;
    color: var(--primary);
}

.faq-question:hover {
    background: rgba(65, 90, 119, 0.05);
}

.faq-answer {
    padding: 0 1.5rem 1.5rem;
    color: var(--secondary);
    line-height: 1.6;
    display: none;
}

.faq-item.active .faq-answer {
    display: block;
}

.faq-item.active .faq-icon {
    transform: rotate(180deg);
}

.faq-icon {
    transition: transform 0.3s ease;
}

/* Alerts */
.alert {
    padding: 1rem;
    border-radius: 10px;
    margin-bottom: 1rem;
    display: none;
}

.alert-success {
    background: #efe;
    border: 1px solid #cfc;
    color: #3c3;
}

.alert-danger {
    background: #fee;
    border: 1px solid #fcc;
    color: #c33;
}

.alert-warning {
    background: #fff3cd;
    border: 1px solid #ffeaa7;
    color: #856404;
}

/* Scroll indicator */
.scroll-indicator {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: rgba(255,255,255,0.1);
    z-index: 1000;
}

.scroll-progress {
    height: 100%;
    background: linear-gradient(90deg, var(--accent) 0%, var(--primary) 100%);
    width: 0%;
    transition: width 0.3s ease;
}

/* Responsive */
@media (max-width: 768px) {
    .class-selector {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .sidebar {
        margin-bottom: 2rem;
    }
    
    .stats-card {
        margin-bottom: 1rem;
    }
    
    .contact-card {
        margin-bottom: 1rem;
    }
    
    .table-container {
        overflow-x: auto;
    }
    
    .login-form {
        padding: 2rem;
    }
    
    .login-image {
        display: none;
    }
}

@media (max-width: 480px) {
    .class-selector {
        grid-template-columns: 1fr;
    }
    
    .role-selector {
        grid-template-columns: 1fr;
    }
    
    .stats-number {
        font-size: 1.5rem;
    }
}

/* Animation des éléments */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in-up {
    animation: fadeInUp 0.6s ease-out;
}

/* Utility classes */
.text-primary { color: var(--primary); }
.text-secondary { color: var(--secondary); }
.text-accent { color: var(--accent); }
.text-success { color: var(--success); }
.text-danger { color: var(--danger); }
.text-warning { color: var(--warning); }

.bg-primary { background-color: var(--primary); }
.bg-secondary { background-color: var(--secondary); }
.bg-accent { background-color: var(--accent); }
.bg-success { background-color: var(--success); }
.bg-danger { background-color: var(--danger); }
.bg-warning { background-color: var(--warning); }

.border-primary { border-color: var(--primary); }
.border-secondary { border-color: var(--secondary); }
.border-accent { border-color: var(--accent); }

/* Feature icons */
.feature-icon {
    background: linear-gradient(135deg, var(--accent) 0%, var(--primary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Loading spinner */
.spinner {
    display: inline-block;
    width: 1rem;
    height: 1rem;
    border: 2px solid #ffffff;
    border-radius: 50%;
    border-top-color: transparent;
    animation: spin 1s ease-in-out infinite;
}

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

/* Tooltip */
.tooltip {
    position: relative;
    display: inline-block;
}

.tooltip .tooltiptext {
    visibility: hidden;
    width: 120px;
    background-color: #555;
    color: #fff;
    text-align: center;
    border-radius: 6px;
    padding: 5px;
    position: absolute;
    z-index: 1;
    bottom: 125%;
    left: 50%;
    margin-left: -60px;
    opacity: 0;
    transition: opacity 0.3s;
}

.tooltip:hover .tooltiptext {
    visibility: visible;
    opacity: 1;
}