/* style.css - Design épuré gris clair */

:root {
    /* Couleurs */
    --primary: #555555;
    --primary-dark: #333333;
    --primary-light: #f5f5f5;
    --secondary: #666666;
    --success: #66bb6a;
    --warning: #ffa726;
    --danger: #ef5350;
    
    /* Gris */
    --gray-50: #F9FAFB;
    --gray-100: #F3F4F6;
    --gray-200: #E5E7EB;
    --gray-300: #D1D5DB;
    --gray-400: #9CA3AF;
    --gray-600: #4B5563;
    --gray-700: #374151;
    --gray-900: #111827;
    
    /* Espacements compacts */
    --spacing-xs: 0.25rem;
    --spacing-sm: 0.5rem;
    --spacing-md: 0.75rem;
    --spacing-lg: 1rem;
    --spacing-xl: 1.5rem;
    --spacing-2xl: 2rem;
    
    /* Typographie */
    --font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Segoe UI', 'Inter', sans-serif;
    
    /* Ombres subtiles */
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.04);
    --shadow-md: 0 3px 6px -1px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 8px 12px -2px rgba(0, 0, 0, 0.1);
    
    /* Border radius */
    --radius-sm: 0.25rem;
    --radius-md: 0.375rem;
    --radius-lg: 0.5rem;
    --radius-xl: 0.75rem;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-family);
    background-color: #FFFFFF;
    color: var(--gray-900);
    line-height: 1.5;
    font-size: 12px;
    -webkit-font-smoothing: antialiased;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: var(--spacing-lg);
}

/* HEADER */
.header {
    background: #333333;
    border-bottom: 1px solid var(--gray-200);
    padding: var(--spacing-md) 0;
    margin-bottom: var(--spacing-xl);
    color: white;
}

.header-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-lg);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.1rem;
    font-weight: 700;
    color: white;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
}

/* BOUTONS - NOUVEAU STYLE GRIS CLAIR */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 5px 12px;
    font-family: var(--font-family);
    font-size: 0.82rem;
    font-weight: 500;
    border-radius: 4px;
    border: 1px solid #cccccc;
    background-color: #f8f8f8;
    color: #333333;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
    width: auto;
    min-width: fit-content;
}

.btn:hover {
    background-color: #eeeeee;
    border-color: #aaaaaa;
    transform: none;
}

.btn-primary {
    background-color: #f0f0f0;
    border-color: #bbbbbb;
    color: #000000;
}

.btn-primary:hover {
    background-color: #e5e5e5;
    border-color: #999999;
}

.btn-secondary {
    background-color: #ffffff;
    border-color: #dddddd;
    color: #666666;
}

.btn-danger {
    background-color: #fff5f5;
    border-color: #feb2b2;
    color: #c53030;
}

.btn-danger:hover {
    background-color: #fed7d7;
    border-color: #fc8181;
}

.btn-sm {
    padding: 4px 12px;
    font-size: 0.8rem;
}

.btn-lg {
    padding: 12px 24px;
    font-size: 1rem;
}

/* CARDS */
.card {
    background: white;
    border: 1px solid var(--gray-200);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
}

.card-header {
    padding: var(--spacing-lg);
    border-bottom: 1px solid var(--gray-200);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.card-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--gray-900);
}

.card-body {
    padding: var(--spacing-lg);
}

/* BADGES */
.badge {
    display: inline-block;
    padding: 0.2rem 0.6rem;
    font-size: 0.75rem;
    font-weight: 600;
    border-radius: 4px;
    background: var(--gray-100);
    color: var(--gray-700);
    border: 1px solid var(--gray-200);
}

.badge-cat {
    background: #f0f0f0;
    color: #333;
}

/* FORMULAIRES */
.form-group {
    margin-bottom: var(--spacing-lg);
}

.form-label {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--gray-700);
    margin-bottom: var(--spacing-xs);
}

.form-input,
.form-select,
.form-textarea {
    width: 100%;
    padding: 0.4rem 0.6rem;
    border: 1px solid var(--gray-300);
    border-radius: 4px;
    font-family: var(--font-family);
    font-size: 0.82rem;
    transition: border-color 0.2s;
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
    outline: none;
    border-color: #999;
}

/* MODALS */
.modal-overlay {
    position: fixed; top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0, 0, 0, 0.5); display: none; align-items: center; justify-content: center; z-index: 2000;
}
.modal-card { 
    background: white; border-radius: 8px; padding: 2rem; 
    max-width: 500px; width: 90%; 
    box-shadow: 0 10px 40px rgba(0,0,0,0.2); 
    color: var(--gray-900); 
}

/* UTILITAIRES */
.flex { display: flex; }
.flex-col { flex-direction: column; }
.justify-between { justify-content: space-between; }
.justify-end { justify-content: flex-end; }
.items-center { align-items: center; }
.gap-sm { gap: 0.5rem; }
.gap-md { gap: 1rem; }
.gap-lg { gap: 1.5rem; }
.mt-sm { margin-top: 0.5rem; }
.mt-md { margin-top: 1rem; }
.mt-lg { margin-top: 1.5rem; }
.mt-xl { margin-top: 2rem; }
.mb-sm { margin-bottom: 0.5rem; }
.mb-md { margin-bottom: 1rem; }
.mb-lg { margin-bottom: 1.5rem; }
.grid { display: grid; }
.grid-cols-2 { grid-template-columns: repeat(2, 1fr); }
.grid-cols-4 { grid-template-columns: repeat(4, 1fr); }
.hidden { display: none; }
.text-sm { font-size: 0.82rem; }
.text-secondary { color: var(--secondary); }
.table-responsive { overflow-x: auto; }

/* INFO ITEMS (page détail) */
.info-item { display: flex; flex-direction: column; gap: 2px; margin-bottom: 0.6rem; }
.info-label { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.5px; color: var(--gray-400); font-weight: 600; }
.info-value { font-size: 0.88rem; color: var(--gray-900); }

.spinner {
    border: 3px solid var(--gray-200);
    border-top-color: #666;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
}

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