/* Styles modernes pour Supervision Maj Linux */

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    padding: 0;
    background: linear-gradient(135deg, #e3f2fd 0%, #f3e5f5 100%);
    min-height: 100vh;
    color: #333;
}

header {
    background: rgba(255, 255, 255, 0.98);
    color: #333;
    padding: 1rem;
    text-align: center;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

nav {
    margin-top: 1rem;
}

nav a {
    color: #4facfe;
    margin: 0 1rem;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s;
}

nav a:hover {
    color: #3a9eea;
    text-decoration: underline;
}

.user-info {
    font-size: 0.9rem;
    margin-top: 0.5rem;
    color: #666;
}

main {
    max-width: 1200px;
    margin: 2rem auto;
    padding: 2rem;
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
}

.login-container {
    max-width: 400px;
    margin: 5rem auto;
    padding: 2rem;
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    text-align: center;
}

.form-group {
    margin-bottom: 1.5rem;
    text-align: left;
}



label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #555;
}

input, select {
    width: calc(100% - 1.5rem);
    padding: 0.75rem;
    border: 2px solid #e1e5e9;
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.3s;
}

input:focus, select:focus {
    outline: none;
    border-color: #4facfe;
    box-shadow: 0 0 0 2px rgba(79, 172, 254, 0.2);
}

button {
    background: #4facfe;
    color: white;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 500;
    transition: background-color 0.2s, transform 0.2s;
}

button:hover {
    background: #3a9eea;
    transform: translateY(-1px);
}

.add-btn {
    background: #4CAF50;
    padding: 0.5rem 1rem;
    font-size: 0.9rem;
}

.add-btn:hover {
    background: #45a049;
}

.icon-btn {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.2rem;
    padding: 0.25rem;
    margin: 0 0.25rem;
    border-radius: 4px;
    transition: background-color 0.2s;
}

.icon-btn:hover {
    background-color: #f0f0f0;
}

.edit-btn:hover {
    background-color: #e3f2fd;
}

.password-btn:hover {
    background-color: #fff3e0;
}

.delete-btn:hover {
    background-color: #ffebee;
}

.error {
    color: #d32f2f;
    margin-bottom: 1rem;
    padding: 0.75rem;
    background: #ffebee;
    border: 1px solid #ffcdd2;
    border-radius: 8px;
    font-weight: 500;
}

.success {
    color: #2e7d32;
    margin-bottom: 1rem;
    padding: 0.75rem;
    background: #e8f5e8;
    border: 1px solid #c8e6c9;
    border-radius: 8px;
    font-weight: 500;
}

table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 1rem;
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    font-size: 0.9rem;
}

th {
    background: #f8f9fa;
    color: #333;
    padding: 0.75rem;
    text-align: left;
    font-weight: 600;
    border-bottom: 2px solid #e9ecef;
    font-size: 0.85rem;
}

td {
    padding: 0.75rem;
    border-bottom: 1px solid #e1e5e9;
    font-size: 0.85rem;
}

tbody tr:hover {
    background-color: #f8f9fa;
}

.actions-cell {
    text-align: center;
}

.status-online {
    color: #2e7d32;
    font-weight: 500;
}

.status-offline {
    color: #d32f2f;
    font-weight: 500;
}

.status-error {
    color: #f57c00;
    font-weight: 500;
}

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

.modal-content {
    background: white;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    padding: 1.5rem;
    border-radius: 12px;
    width: 90%;
    max-width: 600px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.15);
    animation: modalFadeIn 0.3s ease-out;
    margin: 0 !important;
}

@keyframes modalFadeIn {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}

.close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.2s;
}

.close:hover {
    color: #4facfe;
}

h2, h3 {
    color: #333;
    margin-bottom: 1.5rem;
}

.actions {
    text-align: right;
    margin-bottom: 2rem;
}

.tabs {
    display: flex;
    margin-bottom: 2rem;
    border-bottom: 1px solid #e9ecef;
}

.tabs a {
    padding: 0.75rem 1rem;
    text-decoration: none;
    color: #666;
    border-bottom: 2px solid transparent;
    transition: color 0.3s, border-color 0.3s;
}

.tabs a.active {
    color: #4facfe;
    border-bottom-color: #4facfe;
}

.tabs a:hover {
    color: #4facfe;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

.pagination {
    text-align: center;
    margin-top: 1rem;
}

.pagination a {
    display: inline-block;
    padding: 0.5rem 0.75rem;
    margin: 0 0.25rem;
    text-decoration: none;
    color: #4facfe;
    border: 1px solid #4facfe;
    border-radius: 4px;
    transition: background-color 0.2s;
}

.pagination a:hover, .pagination a.active {
    background-color: #4facfe;
    color: white;
}