/* Couleurs TrEC */
:root {
  --primary:#023aa6;
  --light:#f5f5f5;
  --dark:#222;
}

body {
  font-family: Arial, sans-serif;
  margin:0;
  background: var(--light);
}

.sidebar {
  width:220px;
  background: var(--primary);
  color:#fff;
  height:100vh;
  position: fixed;
  padding:20px;
}

.sidebar h2 { margin-bottom:30px; }
.sidebar a {
  display:block;
  color:#fff;
  text-decoration:none;
  margin:10px 0;
  padding:8px;
  border-radius:5px;
}
.sidebar a:hover { background: rgba(255,255,255,0.2); }

.main {
  margin-left:240px;
  padding:20px;
}

.card {
  background:#fff;
  border-radius:8px;
  padding:15px;
  margin-bottom:15px;
  box-shadow:0 2px 6px rgba(0,0,0,0.1);
}

.btn {
  display:inline-block;
  padding:10px 15px;
  background:var(--primary);
  color:#fff;
  border:none;
  border-radius:5px;
  cursor:pointer;
  text-decoration:none;
}
.btn:hover {
  background: #021f75;
}

input, textarea {
  width:100%;
  padding:10px;
  margin:5px 0 15px 0;
  border:1px solid #ccc;
  border-radius:5px;
}

body {
    font-family: Arial, sans-serif;
    background: #f4f6fb;
}

.card {
    background: white;
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 8px 20px rgba(0,0,0,.08);
    animation: fadeIn .6s ease;
}

.btn {
    background: #023aa6;
    color: white;
    padding: 10px 16px;
    border-radius: 8px;
    text-decoration: none;
    display: inline-block;
    transition: .3s;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(2,58,166,.4);
}

@keyframes fadeIn {
    from {opacity:0; transform:translateY(20px);}
    to {opacity:1;}
}

/* --- Users table styles --- */
.users-table {
  width:100%;
  border-collapse: collapse;
  background: transparent;
}
.users-table th, .users-table td {
  padding: 12px 14px;
  text-align: left;
  border-bottom: 1px solid rgba(30,40,60,0.06);
}
.users-table thead th {
  font-weight:700;
  color: #24303f;
  font-size: 13px;
}
.users-table tbody tr {
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 6px 14px rgba(19,25,35,0.04);
  transition: transform .18s ease, box-shadow .18s ease;
}
.users-table tbody tr:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 30px rgba(19,25,35,0.07);
}
.users-table img { border-radius: 6px; }

.badge {
  display:inline-block;
  padding:6px 10px;
  border-radius:20px;
  font-size:12px;
  font-weight:600;
}
.badge--active { background: #e6f0ff; color: #023aa6; }
.badge--blocked { background: #fff1f0; color: #b1232a; }

.action-btns { display:flex; gap:8px; align-items:center; }
.action-btns a, .action-btns button { text-decoration:none; border:none; cursor:pointer; padding:8px 10px; border-radius:8px; font-size:14px; }
.btn-edit { background: #eef6ff; color:#023aa6; }
.btn-block { background: #fff7e6; color:#b36b00; }
.btn-delete { background: #fff1f0; color:#b1232a; }
.btn-edit:hover, .btn-block:hover, .btn-delete:hover { transform: translateY(-2px); box-shadow: 0 8px 20px rgba(2,58,166,0.06); }

/* --- Confirmation modal --- */
#confirm-modal { position:fixed; inset:0; display:flex; align-items:center; justify-content:center; z-index:9999; pointer-events:none; }
#confirm-modal .overlay { position:absolute; inset:0; background:rgba(10,14,22,0.45); backdrop-filter: blur(2px); opacity:0; transition:opacity .18s ease; }
#confirm-modal .modal { position:relative; width:420px; max-width:92%; background:#fff; border-radius:12px; padding:20px; box-shadow:0 18px 50px rgba(6,10,24,0.3); transform:translateY(12px) scale(.98); opacity:0; transition:all .22s cubic-bezier(.2,.9,.3,1); pointer-events:auto; }
#confirm-modal.show .overlay { opacity:1; }
#confirm-modal.show .modal { transform:translateY(0) scale(1); opacity:1; }
#confirm-modal .modal h3 { margin:0 0 6px 0; font-size:18px; }
#confirm-modal .modal p { margin:0 0 14px 0; color:#566070; }
#confirm-modal .modal .controls { display:flex; gap:10px; justify-content:flex-end; }
.btn-cancel { background:#f4f6fb; color:#24303f; padding:8px 12px; border-radius:8px; }
.btn-confirm { background:#023aa6; color:#fff; padding:8px 12px; border-radius:8px; }
.btn-confirm.danger { background:#b1232a; }

/* small responsiveness */
@media (max-width:520px){
  .users-table th:nth-child(1), .users-table td:nth-child(1) { display:none; }
}

/* --- Create / Edit form styles --- */
.form-wrap { display:flex; align-items:center; justify-content:center; padding:40px 16px; }
.form-card { width:100%; max-width:720px; background:linear-gradient(180deg,#ffffff 0%, #fbfdff 100%); border-radius:14px; padding:28px; box-shadow: 0 18px 50px rgba(6,10,24,0.08); }
.form-card h2 { margin-top:0; margin-bottom:12px; }
.form-row { display:flex; gap:12px; }
.form-row .col { flex:1; }
input[type="text"], input[type="email"], select { width:100%; padding:12px 14px; border:1px solid rgba(20,30,50,0.08); border-radius:10px; box-shadow:inset 0 1px 0 rgba(255,255,255,0.6); transition:box-shadow .15s ease, transform .08s ease, border-color .12s ease; }
input:focus, select:focus { outline:none; box-shadow:0 8px 20px rgba(2,58,166,0.06); border-color: rgba(2,58,166,0.18); transform:translateY(-1px); }
.form-actions { display:flex; gap:12px; justify-content:flex-end; margin-top:14px; }
.btn-primary { background: linear-gradient(180deg,#023aa6,#012a7a); color:#fff; padding:10px 16px; border-radius:10px; box-shadow: 0 8px 20px rgba(2,58,166,0.18); border:none; cursor:pointer; transition: transform .12s ease, box-shadow .12s ease; }
.btn-primary:hover { transform: translateY(-3px); box-shadow: 0 18px 40px rgba(2,58,166,0.22); }
.btn-ghost { background: transparent; border:1px solid rgba(20,30,50,0.08); color:#24303f; padding:10px 14px; border-radius:10px; }

/* --- Auth page --- */
.auth-page { min-height:100vh; display:flex; align-items:center; justify-content:center; background: linear-gradient(180deg,#f4f7ff 0%, #eef6ff 100%); }
.auth-page .form-card { max-width:420px; width:100%; padding:28px 22px; border-radius:14px; }
.auth-page h2 { text-align:center; margin-bottom:12px; color:var(--dark); }
.auth-page input { padding:12px 14px; border-radius:10px; }
.auth-page .form-actions { justify-content:space-between; gap:10px; margin-top:6px; }
.auth-page .card { margin-bottom:12px; }

/* --- Notifications / Toasts --- */
.toasts { position:fixed; top:20px; right:20px; display:flex; flex-direction:column; gap:10px; z-index:99999; }
.notification { min-width:260px; max-width:420px; padding:12px 14px; border-radius:10px; color:#fff; box-shadow:0 10px 30px rgba(10,14,22,0.16); display:flex; gap:12px; align-items:center; transform:translateY(-10px) scale(.98); opacity:0; animation:toastIn .32s cubic-bezier(.2,.9,.3,1) forwards; position:relative; overflow:hidden; }
.notification .tag { width:8px; height:40px; border-radius:6px; margin-right:8px; flex:0 0 8px; }
.notification .body { flex:1; font-weight:600; }
.notification .small { font-size:12px; font-weight:400; opacity:.95; }
.notification .close { background:transparent; border:none; color:inherit; cursor:pointer; font-size:16px; padding:6px; border-radius:6px; }
.notification--success { background: linear-gradient(90deg,#1aa260,#1ba77c); }
.notification--error { background: linear-gradient(90deg,#e34b4b,#d63939); }
.notification--info { background: linear-gradient(90deg,#2b8cff,#1d6fe6); }

@keyframes toastIn { from { opacity:0; transform: translateY(-6px) scale(.98); } to { opacity:1; transform: translateY(0) scale(1); } }
@keyframes toastOut { from { opacity:1; transform: translateY(0) scale(1); } to { opacity:0; transform: translateY(-8px) scale(.98); } }

@media (max-width:720px){
  .form-card { padding:18px; }
  .form-actions { justify-content:center; }
}

