.admin-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
}

.stat-card {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 20px;
    transition: border-color 0.2s ease;
}

.stat-card:hover {
    border-color: rgba(255, 255, 255, 0.15);
}

.stat-value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 8px 0;
    font-variant-numeric: tabular-nums;
}

.stat-label {
    color: var(--text-secondary);
    font-size: 0.85rem;
    font-weight: 500;
}

.admin-section {
    margin-bottom: 2rem;
}

.section-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--border);
}

.admin-table {
    width: 100%;
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 10px;
    overflow: hidden;
}

.admin-table table {
    width: 100%;
    border-collapse: collapse;
}

.admin-table th {
    background: rgba(255, 255, 255, 0.02);
    padding: 12px 16px;
    text-align: left;
    color: var(--text-secondary);
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 600;
    border-bottom: 1px solid var(--border);
}

.admin-table td {
    padding: 12px 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    color: var(--text-primary);
    font-size: 0.9rem;
}

.admin-table tr:last-child td {
    border-bottom: none;
}

.admin-table tr:hover {
    background: rgba(255, 255, 255, 0.02);
}

.badge {
    display: inline-block;
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.3px;
}

.badge.admin {
    background: rgba(245, 158, 11, 0.15);
    color: #fbbf24;
    border: 1px solid rgba(245, 158, 11, 0.3);
}

.badge.user {
    background: rgba(100, 116, 139, 0.15);
    color: #94a3b8;
    border: 1px solid rgba(100, 116, 139, 0.3);
}

.admin-form {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 2rem;
}

.form-row {
    display: flex;
    gap: 10px;
    align-items: flex-end;
}

.form-row .form-group {
    flex: 1;
    margin: 0;
}

.form-row button {
    padding: 10px 20px;
    white-space: nowrap;
}

.success-message {
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid rgba(16, 185, 129, 0.3);
    color: #10b981;
    padding: 12px 16px;
    border-radius: 8px;
    margin-bottom: 1rem;
    font-size: 0.9rem;
}

.error-message {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #f87171;
    padding: 12px 16px;
    border-radius: 8px;
    margin-bottom: 1rem;
    font-size: 0.9rem;
}
/* Badges de statut de voiture */
.car-status-badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 0.8rem;
    font-weight: 600;
}

.car-available {
    background: rgba(74, 222, 128, 0.15);
    color: #4ade80;
    border: 1px solid rgba(74, 222, 128, 0.3);
}

.car-soon {
    background: rgba(251, 191, 36, 0.15);
    color: #fbbf24;
    border: 1px solid rgba(251, 191, 36, 0.3);
}

.car-busy {
    background: rgba(239, 68, 68, 0.15);
    color: #f87171;
    border: 1px solid rgba(239, 68, 68, 0.3);
}

/* Badges de statut général */
.general-status-badge {
    display: inline-block;
    padding: 5px 12px;
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 600;
}

.status-active {
    background: rgba(74, 222, 128, 0.15);
    color: #4ade80;
    border: 1px solid rgba(74, 222, 128, 0.3);
}

.status-unavailable {
    background: rgba(239, 68, 68, 0.15);
    color: #f87171;
    border: 1px solid rgba(239, 68, 68, 0.3);
}

.status-repair {
    background: rgba(251, 191, 36, 0.15);
    color: #fbbf24;
    border: 1px solid rgba(251, 191, 36, 0.3);
}

.status-invisible {
    background: rgba(100, 116, 139, 0.15);
    color: #94a3b8;
    border: 1px solid rgba(100, 116, 139, 0.3);
}

.status-default {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-secondary);
    border: 1px solid var(--border);
}

/* Container pour statut + bouton */
.status-with-edit {
    display: flex;
    align-items: center;
    gap: 8px;
}

.edit-status-btn {
    background: transparent;
    border: 1px solid var(--border);
    padding: 6px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.edit-status-btn svg {
    width: 16px;
    height: 16px;
    stroke: var(--text-secondary);
    transition: stroke 0.2s ease;
}

.edit-status-btn:hover {
    background: rgba(74, 144, 226, 0.1);
    border-color: var(--primary);
}

.edit-status-btn:hover svg {
    stroke: var(--primary);
}

/* Modal */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(10, 14, 26, 0.85);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    padding: 20px;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 16px;
    width: 100%;
    max-width: 600px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
    transform: scale(0.9);
    transition: transform 0.3s ease;
}

.modal-overlay.active .modal-content {
    transform: scale(1);
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
    border-bottom: 1px solid var(--border);
}

.modal-header h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0;
}

.modal-header .icon {
    width: 24px;
    height: 24px;
    stroke: var(--primary);
}

.modal-close {
    background: transparent;
    border: none;
    padding: 8px;
    cursor: pointer;
    border-radius: 8px;
    transition: background 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-close svg {
    width: 20px;
    height: 20px;
    stroke: var(--text-secondary);
    transition: stroke 0.2s ease;
}

.modal-close:hover {
    background: rgba(239, 68, 68, 0.1);
}

.modal-close:hover svg {
    stroke: #f87171;
}

.modal-body {
    padding: 24px;
}

.car-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 16px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    margin-bottom: 24px;
}

.car-info strong {
    font-size: 1.1rem;
    color: var(--text-primary);
}

/* Options de statut */
.status-options {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    margin-top: 8px;
}

.status-option {
    cursor: pointer;
}

.status-option input[type="radio"] {
    display: none;
}

.status-option-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 16px;
    border-radius: 12px;
    border: 2px solid var(--border);
    transition: all 0.2s ease;
    background: var(--bg-card);
}

.status-option-card svg {
    width: 28px;
    height: 28px;
    stroke-width: 2;
    transition: stroke 0.2s ease;
}

.status-option-card span {
    font-size: 0.9rem;
    font-weight: 600;
    transition: color 0.2s ease;
}

.status-option:hover .status-option-card {
    transform: translateY(-2px);
}

.status-option input[type="radio"]:checked + .status-option-card {
    border-width: 2px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* Couleurs spécifiques des cartes de statut */
.status-option-card.status-active {
    border-color: rgba(74, 222, 128, 0.3);
}

.status-option-card.status-active svg {
    stroke: #4ade80;
}

.status-option-card.status-active span {
    color: #4ade80;
}

.status-option input[type="radio"]:checked + .status-option-card.status-active {
    background: rgba(74, 222, 128, 0.1);
    border-color: #4ade80;
}

.status-option-card.status-unavailable {
    border-color: rgba(239, 68, 68, 0.3);
}

.status-option-card.status-unavailable svg {
    stroke: #f87171;
}

.status-option-card.status-unavailable span {
    color: #f87171;
}

.status-option input[type="radio"]:checked + .status-option-card.status-unavailable {
    background: rgba(239, 68, 68, 0.1);
    border-color: #f87171;
}

.status-option-card.status-repair {
    border-color: rgba(251, 191, 36, 0.3);
}

.status-option-card.status-repair svg {
    stroke: #fbbf24;
}

.status-option-card.status-repair span {
    color: #fbbf24;
}

.status-option input[type="radio"]:checked + .status-option-card.status-repair {
    background: rgba(251, 191, 36, 0.1);
    border-color: #fbbf24;
}

.status-option-card.status-offline {
    border-color: rgba(100, 116, 139, 0.3);
}

.status-option-card.status-offline svg {
    stroke: #94a3b8;
}

.status-option-card.status-offline span {
    color: #94a3b8;
}

.status-option input[type="radio"]:checked + .status-option-card.status-offline {
    background: rgba(100, 116, 139, 0.1);
    border-color: #94a3b8;
}

/* Actions du modal */
.modal-actions {
    display: flex;
    gap: 12px;
    margin-top: 24px;
}

.modal-actions button {
    flex: 1;
    margin: 0;
}

/* Responsive */
@media (max-width: 600px) {
    .status-options {
        grid-template-columns: 1fr;
    }
    
    .modal-content {
        max-height: 95vh;
    }
    
    .modal-header,
    .modal-body {
        padding: 16px;
    }
}