/* =============================================================================
   ADMIN CSS — MegaComparateur Back-Office
   Préfixe : adm-
   Scope : pages admin uniquement (layout.ejs, login.ejs, users.ejs, unauthorized.ejs)
   Ne pas modifier site.css pour ces styles.
   ============================================================================= */

/* ── RESET ADMIN BODY ─────────────────────────────────────────────────────── */

.adm-body {
  margin: 0;
  padding: 0;
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  background: #f1f5f9;
  min-height: 100vh;
  display: flex;
  color: #111827;
  -webkit-font-smoothing: antialiased;
}

/* ── LAYOUT PRINCIPAL ─────────────────────────────────────────────────────── */

.adm-layout {
  display: flex;
  width: 100%;
  min-height: 100vh;
}

/* ── SIDEBAR ──────────────────────────────────────────────────────────────── */

.adm-sidebar {
  width: 260px;
  flex-shrink: 0;
  background: #0f172a;
  color: #cbd5e1;
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0;
  left: 0;
  height: 100vh;
  z-index: 100;
  overflow-y: auto;
  transition: transform 0.3s ease;
}

/* Brand */
.adm-sidebar-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 20px 20px 16px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}

.adm-sidebar-logo {
  width: 38px;
  height: 38px;
  object-fit: contain;
  border-radius: 8px;
  flex-shrink: 0;
  display: block;
}

.adm-brand-name {
  display: block;
  font-size: 14px;
  font-weight: 700;
  color: #f1f5f9;
  line-height: 1.2;
}

.adm-brand-sub {
  display: block;
  font-size: 11px;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-weight: 500;
}

/* Navigation */
.adm-nav {
  flex: 1;
  padding: 16px 12px;
}

.adm-nav-section-label {
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #475569;
  padding: 0 10px;
  margin: 8px 0 6px;
  display: block;
}

.adm-nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  border-radius: 8px;
  text-decoration: none;
  color: #94a3b8;
  font-size: 13.5px;
  font-weight: 500;
  transition: background 0.15s, color 0.15s;
  margin-bottom: 2px;
}

.adm-nav-item:hover {
  background: rgba(255,255,255,0.07);
  color: #e2e8f0;
}

.adm-nav-item--active {
  background: rgba(59, 130, 246, 0.15);
  color: #93c5fd;
  border-left: 3px solid #3b82f6;
  padding-left: 9px;
}

.adm-nav-item--active:hover {
  background: rgba(59, 130, 246, 0.2);
  color: #93c5fd;
}

.adm-nav-icon {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  opacity: 0.75;
}

.adm-nav-item--active .adm-nav-icon {
  opacity: 1;
}

/* Footer sidebar */
.adm-sidebar-footer {
  padding: 16px;
  border-top: 1px solid rgba(255,255,255,0.06);
}

.adm-user {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.adm-user-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: linear-gradient(135deg, #3b82f6, #8b5cf6);
  color: #fff;
  font-weight: 700;
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.adm-user-name {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: #e2e8f0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.adm-user-role {
  display: inline-block;
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 2px 7px;
  border-radius: 20px;
  margin-top: 2px;
}

.adm-user-role.adm-role-admin {
  background: rgba(59, 130, 246, 0.2);
  color: #93c5fd;
}

.adm-user-role.adm-role-editor {
  background: rgba(16, 185, 129, 0.2);
  color: #6ee7b7;
}

.adm-logout-btn {
  display: block;
  width: 100%;
  padding: 8px 12px;
  background: rgba(239, 68, 68, 0.1);
  color: #fca5a5;
  border: 1px solid rgba(239, 68, 68, 0.2);
  border-radius: 8px;
  text-decoration: none;
  font-size: 12.5px;
  font-weight: 600;
  text-align: center;
  transition: background 0.15s, color 0.15s;
  box-sizing: border-box;
}

.adm-logout-btn:hover {
  background: rgba(239, 68, 68, 0.2);
  color: #f87171;
}

/* ── MAIN AREA ────────────────────────────────────────────────────────────── */

.adm-main {
  margin-left: 260px;
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* Topbar */
.adm-topbar {
  height: 60px;
  background: #fff;
  border-bottom: 1px solid #e5e7eb;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 28px;
  position: sticky;
  top: 0;
  z-index: 50;
  flex-shrink: 0;
}

.adm-topbar-left {
  display: flex;
  align-items: center;
  gap: 16px;
}

.adm-menu-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
  border-radius: 6px;
  color: #6b7280;
}

.adm-menu-toggle:hover {
  background: #f3f4f6;
}

.adm-topbar-title {
  font-size: 15px;
  font-weight: 600;
  color: #111827;
  margin: 0;
}

.adm-topbar-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

.adm-topbar-user-badge {
  display: flex;
  align-items: center;
  gap: 8px;
}

.adm-topbar-avatar {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: linear-gradient(135deg, #3b82f6, #8b5cf6);
  color: #fff;
  font-weight: 700;
  font-size: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.adm-topbar-name {
  font-size: 13px;
  font-weight: 600;
  color: #374151;
}

/* Content area */
.adm-content {
  flex: 1;
  padding: 28px;
  overflow-y: auto;
}

/* ── PAGE OVERLAY mobile ──────────────────────────────────────────────────── */

.adm-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.4);
  z-index: 99;
}

/* ── PAGE: LOGIN ──────────────────────────────────────────────────────────── */

.adm-login-page {
  position: fixed;
  inset: 0;
  overflow: auto;
  overflow-x: hidden;
  background-color: #06091a;
  background-image:
    radial-gradient(ellipse at 10% 60%, rgba(220,38,38,0.14) 0%, transparent 52%),
    radial-gradient(ellipse at 90% 20%, rgba(59,130,246,0.09) 0%, transparent 52%),
    linear-gradient(rgba(255,255,255,0.022) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.022) 1px, transparent 1px);
  background-size: auto, auto, 40px 40px, 40px 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px 16px;
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  -webkit-font-smoothing: antialiased;
  box-sizing: border-box;
}

.adm-login-card {
  background: #fff;
  border-radius: 20px;
  padding: 36px 40px;
  width: 100%;
  max-width: 420px;
  box-sizing: border-box;
  overflow: hidden;
  box-shadow:
    0 0 0 1px rgba(255,255,255,0.07),
    0 24px 56px rgba(0,0,0,0.55),
    0 4px 16px rgba(0,0,0,0.3);
  position: relative;
  z-index: 1;
}

/* ── Logo + titre sur la même ligne ──────────────────────────────────────── */

.adm-login-logo-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-bottom: 18px;
  overflow: hidden;
}

.adm-login-logo {
  height: 36px;
  width: auto;
  flex-shrink: 0;
  object-fit: contain;
  display: block;
}

.adm-login-brand-title {
  font-size: 12px;
  font-weight: 700;
  color: #0f172a;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  line-height: 1.35;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

/* ── Sous-titre + badge ──────────────────────────────────────────────────── */

.adm-login-header {
  text-align: center;
  margin-bottom: 24px;
}

.adm-login-subtitle {
  font-size: 13px;
  color: #6b7280;
  margin: 0 0 12px;
  font-weight: 400;
}

.adm-login-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #dc2626;
  font-size: 10px;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: 0.07em;
}

.adm-login-badge svg {
  flex-shrink: 0;
}

/* Séparateur */
.adm-login-divider {
  height: 1px;
  background: #f1f5f9;
  margin: 0 0 28px;
}

/* Message d'erreur */
.adm-login-error {
  background: #fef2f2;
  border: 1px solid #fecaca;
  border-radius: 10px;
  padding: 12px 16px;
  margin-bottom: 22px;
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.adm-login-error-icon {
  color: #ef4444;
  flex-shrink: 0;
  margin-top: 1px;
}

.adm-login-error-text {
  font-size: 13.5px;
  color: #b91c1c;
  font-weight: 500;
  line-height: 1.4;
}

/* Champs */
.adm-form-group {
  margin-bottom: 18px;
}

.adm-label {
  display: block;
  font-size: 12.5px;
  font-weight: 600;
  color: #374151;
  margin-bottom: 6px;
  letter-spacing: 0.01em;
}

.adm-input-wrap {
  position: relative;
}

.adm-input-icon {
  position: absolute;
  left: 13px;
  top: 50%;
  transform: translateY(-50%);
  color: #9ca3af;
  pointer-events: none;
  display: flex;
  align-items: center;
}

.adm-input {
  width: 100%;
  padding: 11px 14px 11px 40px;
  border: 1.5px solid #e5e7eb;
  border-radius: 10px;
  font-size: 14px;
  font-family: inherit;
  color: #111827;
  background: #f9fafb;
  transition: border-color 0.18s, box-shadow 0.18s, background 0.18s;
  box-sizing: border-box;
  outline: none;
}

.adm-input:focus {
  border-color: #dc2626;
  box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.1);
  background: #fff;
}

.adm-input:focus + .adm-input-icon,
.adm-input-wrap:focus-within .adm-input-icon {
  color: #dc2626;
}

.adm-input.adm-input--password {
  padding-right: 44px;
}

.adm-pw-toggle {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  color: #9ca3af;
  transition: color 0.15s;
  display: flex;
  align-items: center;
}

.adm-pw-toggle:hover {
  color: #dc2626;
}

/* Ligne "Se souvenir de moi" */
.adm-login-remember-wrap {
  margin-bottom: 22px;
  margin-top: -4px;
}

.adm-remember {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: #4b5563;
  cursor: pointer;
  user-select: none;
  font-weight: 500;
}

.adm-remember input[type="checkbox"] {
  width: 15px;
  height: 15px;
  accent-color: #dc2626;
  cursor: pointer;
  flex-shrink: 0;
}

/* Bouton principal rouge */
.adm-submit-btn {
  width: 100%;
  padding: 13px;
  background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%);
  color: #fff;
  border: none;
  border-radius: 10px;
  font-size: 14.5px;
  font-weight: 700;
  font-family: inherit;
  letter-spacing: 0.01em;
  cursor: pointer;
  transition: background 0.18s, box-shadow 0.18s, transform 0.12s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  position: relative;
  overflow: hidden;
}

.adm-submit-btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,0.08) 0%, transparent 60%);
  pointer-events: none;
}

.adm-submit-btn:hover:not(:disabled) {
  background: linear-gradient(135deg, #b91c1c 0%, #991b1b 100%);
  box-shadow: 0 6px 20px rgba(220, 38, 38, 0.4);
  transform: translateY(-1px);
}

.adm-submit-btn:active:not(:disabled) {
  transform: translateY(0) scale(0.99);
  box-shadow: 0 2px 8px rgba(220, 38, 38, 0.3);
}

.adm-submit-btn:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.adm-submit-spinner {
  display: none;
  width: 16px;
  height: 16px;
  border: 2.5px solid rgba(255,255,255,0.35);
  border-top-color: #fff;
  border-radius: 50%;
  animation: adm-spin 0.65s linear infinite;
  flex-shrink: 0;
}

.adm-submit-btn.adm-loading .adm-submit-spinner {
  display: block;
}

.adm-submit-btn.adm-loading .adm-btn-text {
  opacity: 0.75;
}

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

/* Footer de la card */
.adm-login-footer {
  margin-top: 24px;
  text-align: center;
  font-size: 11.5px;
  color: #9ca3af;
  line-height: 1.6;
}

.adm-login-footer a {
  color: #9ca3af;
  text-decoration: none;
}

.adm-login-footer a:hover {
  color: #6b7280;
}

/* ── PAGE: USERS ──────────────────────────────────────────────────────────── */

.adm-page-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
  flex-wrap: wrap;
  gap: 12px;
}

.adm-page-title {
  font-size: 20px;
  font-weight: 700;
  color: #111827;
  margin: 0;
}

.adm-page-subtitle {
  font-size: 13px;
  color: #6b7280;
  margin: 4px 0 0;
}

.adm-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 18px;
  border-radius: 8px;
  font-size: 13.5px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  border: none;
  text-decoration: none;
  transition: background 0.15s, transform 0.1s;
  white-space: nowrap;
}

.adm-btn:active { transform: scale(0.98); }

.adm-btn-primary {
  background: #2563eb;
  color: #fff;
}
.adm-btn-primary:hover { background: #1d4ed8; }

.adm-btn-secondary {
  background: #f1f5f9;
  color: #374151;
  border: 1px solid #e5e7eb;
}
.adm-btn-secondary:hover { background: #e2e8f0; }

.adm-btn-danger {
  background: #fef2f2;
  color: #dc2626;
  border: 1px solid #fecaca;
}
.adm-btn-danger:hover { background: #fee2e2; }

.adm-btn-sm {
  padding: 5px 12px;
  font-size: 12px;
}

/* Alertes */
.adm-alert {
  padding: 12px 16px;
  border-radius: 10px;
  font-size: 13.5px;
  font-weight: 500;
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.adm-alert-error {
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #b91c1c;
}

.adm-alert-success {
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  color: #166534;
}

/* Tableau */
.adm-table-wrap {
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.07), 0 4px 16px rgba(0,0,0,0.04);
  overflow: hidden;
  margin-bottom: 28px;
}

.adm-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13.5px;
}

.adm-table thead {
  background: #f8fafc;
  border-bottom: 1px solid #e5e7eb;
}

.adm-table th {
  padding: 12px 16px;
  text-align: left;
  font-size: 11.5px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #6b7280;
  white-space: nowrap;
}

.adm-table td {
  padding: 13px 16px;
  border-bottom: 1px solid #f1f5f9;
  color: #374151;
  vertical-align: middle;
}

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

.adm-table tbody tr:hover td {
  background: #fafbfc;
}

/* User avatar inline */
.adm-table-user {
  display: flex;
  align-items: center;
  gap: 10px;
}

.adm-table-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: linear-gradient(135deg, #3b82f6, #8b5cf6);
  color: #fff;
  font-weight: 700;
  font-size: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.adm-table-user-name {
  font-weight: 600;
  color: #111827;
  font-size: 13.5px;
}

.adm-table-user-email {
  font-size: 12px;
  color: #9ca3af;
}

/* Badges */
.adm-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 11.5px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  white-space: nowrap;
}

.adm-badge-admin {
  background: rgba(59,130,246,0.1);
  color: #1d4ed8;
}

.adm-badge-editor {
  background: rgba(16,185,129,0.1);
  color: #065f46;
}

.adm-badge-active {
  background: rgba(16,185,129,0.1);
  color: #065f46;
}

.adm-badge-inactive {
  background: rgba(107,114,128,0.1);
  color: #4b5563;
}

/* Actions colonnes */
.adm-table-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

/* Formulaire ajout utilisateur */
.adm-card {
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.07), 0 4px 16px rgba(0,0,0,0.04);
  padding: 24px;
  margin-bottom: 28px;
}

.adm-card-title {
  font-size: 15px;
  font-weight: 700;
  color: #111827;
  margin: 0 0 20px;
  padding-bottom: 14px;
  border-bottom: 1px solid #f1f5f9;
}

.adm-form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  align-items: end;
}

.adm-form-field label {
  display: block;
  font-size: 12.5px;
  font-weight: 600;
  color: #374151;
  margin-bottom: 5px;
}

.adm-form-field input,
.adm-form-field select {
  width: 100%;
  padding: 9px 12px;
  border: 1.5px solid #e5e7eb;
  border-radius: 8px;
  font-size: 13.5px;
  font-family: inherit;
  color: #111827;
  background: #f9fafb;
  box-sizing: border-box;
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.adm-form-field input:focus,
.adm-form-field select:focus {
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59,130,246,0.1);
  background: #fff;
}

/* Inline role form */
.adm-role-form {
  display: flex;
  align-items: center;
  gap: 6px;
}

.adm-role-select {
  padding: 4px 8px;
  border: 1px solid #e5e7eb;
  border-radius: 6px;
  font-size: 12px;
  font-family: inherit;
  background: #f9fafb;
  color: #374151;
  cursor: pointer;
}

/* Soi-même — ligne surlignée */
.adm-table-row--self td {
  background: #eff6ff !important;
}

/* ── RÔLES & PERMISSIONS ──────────────────────────────────────────────────── */

.adm-roles-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 28px;
}

.adm-role-card {
  background: #fff;
  border-radius: 12px;
  padding: 18px 20px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.06);
  border-top: 3px solid transparent;
}

.adm-role-card--admin  { border-top-color: #3b82f6; }
.adm-role-card--editor { border-top-color: #10b981; }

.adm-role-card-header {
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.adm-role-card-desc {
  font-size: 12px;
  color: #6b7280;
  font-weight: 500;
}

.adm-role-perms {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.adm-perm {
  font-size: 13px;
  color: #374151;
  display: flex;
  align-items: center;
  gap: 8px;
}

.adm-perm::before {
  content: '';
  width: 16px;
  height: 16px;
  border-radius: 50%;
  flex-shrink: 0;
  background-size: 10px 10px;
  background-repeat: no-repeat;
  background-position: center;
}

.adm-perm--yes::before {
  background-color: #dcfce7;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 10'%3E%3Cpath d='M2 5l2.5 2.5L8 3' stroke='%2316a34a' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round' fill='none'/%3E%3C/svg%3E");
}

.adm-perm--no::before {
  background-color: #fee2e2;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 10'%3E%3Cpath d='M3 3l4 4M7 3l-4 4' stroke='%23dc2626' stroke-width='1.5' stroke-linecap='round' fill='none'/%3E%3C/svg%3E");
}

.adm-perm--no {
  color: #9ca3af;
}

@media (max-width: 600px) {
  .adm-roles-grid {
    grid-template-columns: 1fr;
  }
}

/* ── MODAL ────────────────────────────────────────────────────────────────── */

.adm-modal-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.45);
  z-index: 200;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.adm-modal-backdrop.adm-modal--open {
  display: flex;
}

.adm-modal {
  background: #fff;
  border-radius: 16px;
  padding: 28px 32px;
  width: 100%;
  max-width: 480px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.25);
  position: relative;
  box-sizing: border-box;
}

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

.adm-modal-title {
  font-size: 17px;
  font-weight: 700;
  color: #111827;
  margin: 0;
}

.adm-modal-close {
  background: none;
  border: none;
  cursor: pointer;
  color: #9ca3af;
  padding: 4px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  transition: color 0.15s, background 0.15s;
}

.adm-modal-close:hover {
  color: #374151;
  background: #f3f4f6;
}

.adm-modal-body .adm-form-field {
  margin-bottom: 14px;
}

.adm-modal-footer {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid #f1f5f9;
}

/* ── PAGE: UNAUTHORIZED ───────────────────────────────────────────────────── */

.adm-unauth-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: calc(100vh - 60px);
  padding: 40px 24px;
}

.adm-unauth-card {
  background: #fff;
  border-radius: 20px;
  padding: 48px 40px;
  max-width: 480px;
  width: 100%;
  text-align: center;
  box-shadow: 0 4px 24px rgba(0,0,0,0.08);
}

.adm-unauth-icon {
  width: 64px;
  height: 64px;
  background: #fef2f2;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 24px;
}

.adm-unauth-title {
  font-size: 24px;
  font-weight: 700;
  color: #111827;
  margin: 0 0 10px;
}

.adm-unauth-text {
  font-size: 14px;
  color: #6b7280;
  line-height: 1.6;
  margin: 0 0 28px;
}

.adm-unauth-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

/* ── RESPONSIVE ───────────────────────────────────────────────────────────── */

@media (max-width: 768px) {
  .adm-sidebar {
    transform: translateX(-100%);
  }

  .adm-sidebar.adm-sidebar--open {
    transform: translateX(0);
  }

  .adm-overlay.adm-overlay--visible {
    display: block;
  }

  .adm-main {
    margin-left: 0;
  }

  .adm-menu-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .adm-content {
    padding: 16px;
  }

  .adm-login-card {
    padding: 28px 22px;
    border-radius: 16px;
    max-width: 100%;
  }

  .adm-table-wrap {
    overflow-x: auto;
  }

  .adm-table th,
  .adm-table td {
    padding: 10px 12px;
  }

  .adm-page-header {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 480px) {
  .adm-login-page {
    padding: 16px 12px;
    align-items: flex-start;
    padding-top: 32px;
  }

  .adm-login-card {
    padding: 24px 18px;
    border-radius: 16px;
    max-width: 100%;
  }

  .adm-login-logo {
    height: 30px;
  }

  .adm-login-brand-title {
    font-size: 11px;
  }

  .adm-table-actions {
    flex-direction: column;
    gap: 4px;
  }
}

@media (max-width: 360px) {
  .adm-login-card {
    padding: 20px 14px;
    border-radius: 12px;
  }

  .adm-login-logo-wrap {
    gap: 8px;
  }

  .adm-login-logo {
    height: 26px;
  }

  .adm-login-brand-title {
    font-size: 10px;
  }
}
