/* Reset et base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Helvetica Neue', sans-serif;
    background: linear-gradient(135deg, #000000 0%, #1a1a1a 50%, #2d2d2d 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Page de login */
.login-container {
    width: 100%;
    max-width: 450px;
    padding: 20px;
}

.logo-container {
    text-align: center;
    margin-bottom: 30px;
}

.logo-container img {
    height: 60px;
    width: auto;
    filter: brightness(0) invert(1);
}

.login-box {
    background: white;
    border-radius: 12px;
    padding: 40px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.logo-in-box {
    text-align: center;
    margin-bottom: 30px;
}

.logo-in-box img {
    height: 50px;
    width: auto;
}

.login-box h1 {
    color: #333;
    margin-bottom: 10px;
    font-size: 28px;
    text-align: center;
}

.subtitle {
    color: #666;
    text-align: center;
    margin-bottom: 30px;
    font-size: 16px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: #333;
    font-weight: 500;
    font-size: 14px;
}

.form-group input {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 15px;
    transition: border-color 0.3s;
}

.form-group input:focus {
    outline: none;
    border-color: #000;
}

.btn {
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s;
    text-decoration: none;
    display: inline-block;
}

.btn-primary {
    background: #000;
    color: white;
    width: 100%;
    padding: 14px;
    font-size: 16px;
}

.btn-primary:hover {
    background: #333;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.4);
}

.btn-secondary {
    background: #6c757d;
    color: white;
}

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

.btn-danger {
    background: #dc3545;
    color: white;
}

.btn-danger:hover {
    background: #c82333;
}

.btn-info {
    background: #17a2b8;
    color: white;
}

.btn-info:hover {
    background: #138496;
}

.btn-small {
    padding: 6px 12px;
    font-size: 13px;
}

.alert {
    padding: 12px 16px;
    border-radius: 8px;
    margin-bottom: 20px;
    font-size: 14px;
}

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

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

/* Admin dashboard */
.admin-body {
    background: #f5f5f7;
    display: block;
    min-height: 100vh;
    padding: 0;
}

.admin-header {
    background: white;
    padding: 20px 40px;
    border-bottom: 1px solid #e0e0e0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.admin-header h1 {
    color: #333;
    font-size: 24px;
    font-weight: 600;
}

.admin-container {
    max-width: 1200px;
    margin: 40px auto;
    padding: 0 40px;
}

.card {
    background: white;
    border-radius: 12px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.card h2 {
    color: #333;
    font-size: 20px;
    margin-bottom: 20px;
    font-weight: 600;
}

.add-client-form .form-row {
    display: grid;
    grid-template-columns: 1fr 1fr auto;
    gap: 15px;
    align-items: end;
}

.clients-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}

.clients-table th {
    background: #f8f9fa;
    padding: 12px;
    text-align: left;
    font-weight: 600;
    color: #333;
    border-bottom: 2px solid #e0e0e0;
    font-size: 14px;
}

.clients-table td {
    padding: 16px 12px;
    border-bottom: 1px solid #e0e0e0;
    font-size: 14px;
    color: #555;
}

.clients-table tr.inactive {
    opacity: 0.6;
}

.clients-table tr:hover {
    background: #f8f9fa;
}

.actions-cell {
    white-space: nowrap;
}

.actions-cell form {
    display: inline;
    margin-right: 5px;
}

.badge {
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
    display: inline-block;
}

.badge-active {
    background: #d4edda;
    color: #155724;
}

.badge-inactive {
    background: #f8d7da;
    color: #721c24;
}

.badge-info {
    background: #d1ecf1;
    color: #0c5460;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
}

.modal-content {
    background: white;
    margin: 5% auto;
    border-radius: 12px;
    width: 90%;
    max-width: 800px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.3);
}

.modal-header {
    padding: 20px 30px;
    border-bottom: 1px solid #e0e0e0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h2 {
    margin: 0;
    font-size: 20px;
    color: #333;
}

.modal-body {
    padding: 30px;
    max-height: 500px;
    overflow-y: auto;
}

.close {
    color: #999;
    font-size: 32px;
    font-weight: 300;
    cursor: pointer;
    line-height: 1;
}

.close:hover {
    color: #333;
}

.log-entry {
    padding: 20px;
    border-bottom: 1px solid #e0e0e0;
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 15px;
    font-size: 14px;
}

.log-entry:last-child {
    border-bottom: none;
}

.log-label {
    color: #666;
    font-weight: 500;
}

.log-value {
    color: #333;
}

/* Responsive */
@media (max-width: 768px) {
    .add-client-form .form-row {
        grid-template-columns: 1fr;
    }

    .admin-container {
        padding: 0 20px;
    }

    .clients-table {
        font-size: 12px;
    }

    .clients-table th,
    .clients-table td {
        padding: 8px;
    }

    .log-entry {
        grid-template-columns: 1fr;
        gap: 10px;
    }
}
