/* OMS Leica — outil dense et sobre. Une seule couleur d'accent (rouge Leica), réservée aux actions et aux statuts.
   Nommage Client-First : composants en snake (auth_card), utilitaires en kebab (text-size-small), combos en is-*. */
:root {
  --red: #cc0000; --red-dark: #a50000;
  --ink: #1e1e1e; --muted: #6b6f76; --line: #dcdee2; --bg: #f4f5f6; --surface: #fff;
  --ok: #1f7a3d; --warn: #b26a00;
  --gap: 12px;
}
* { box-sizing: border-box; }
body { margin: 0; font: 14px/1.45 system-ui, -apple-system, "Segoe UI", sans-serif; color: var(--ink); background: var(--bg); }
a { color: var(--red-dark); }
h1, h2 { margin: 0; line-height: 1.2; }

.page-wrapper { min-height: 100vh; }
.main-wrapper { max-width: 1100px; margin: 0 auto; padding: 24px 16px 48px; }
.text-size-small { font-size: 12px; }
.text-color-muted { color: var(--muted); }

.topbar { display: flex; align-items: center; gap: 24px; padding: 0 16px; height: 48px; background: var(--ink); color: #fff; }
.topbar a { color: #fff; text-decoration: none; }
.topbar_brand { display: flex; align-items: center; gap: 8px; font-weight: 600; letter-spacing: .02em; }
.topbar_dot { width: 10px; height: 10px; border-radius: 50%; background: var(--red); }
.topbar_nav { display: flex; gap: 16px; flex: 1; }
.topbar_nav a { opacity: .8; } .topbar_nav a:hover { opacity: 1; }
.topbar_user { display: flex; align-items: center; gap: 12px; }

.page_head { display: flex; align-items: center; justify-content: space-between; gap: var(--gap); margin-bottom: 16px; }
.page_title { font-size: 20px; font-weight: 600; }

.button { display: inline-block; padding: 7px 14px; border: 1px solid var(--red); border-radius: 3px; background: var(--red); color: #fff;
  font: inherit; font-weight: 500; text-decoration: none; cursor: pointer; }
.button:hover { background: var(--red-dark); border-color: var(--red-dark); }
.button.is-secondary { background: var(--surface); color: var(--ink); border-color: var(--line); }
.button.is-secondary:hover { border-color: var(--ink); }
.button.is-ghost { background: transparent; color: inherit; border-color: transparent; }
.topbar .button.is-ghost { color: #fff; opacity: .8; }
.button.is-danger { background: var(--surface); color: var(--red); border-color: var(--red); }
.button.is-danger:hover { background: var(--red); color: #fff; }
.button_row { display: flex; flex-wrap: wrap; gap: 8px; }

.alert { padding: 9px 12px; margin-bottom: var(--gap); border-left: 3px solid; background: var(--surface); }
.alert.is-ok { border-color: var(--ok); }
.alert.is-error { border-color: var(--red); }

.auth_card { max-width: 380px; margin: 72px auto 0; padding: 24px; background: var(--surface); border: 1px solid var(--line); border-top: 3px solid var(--red); }
.auth_title { font-size: 18px; margin-bottom: 16px; }

.form { display: grid; gap: 6px; }
.form_wide { max-width: 480px; margin-bottom: 24px; }
.form_label { font-weight: 500; margin-top: 8px; }
.form_input { width: 100%; padding: 7px 9px; border: 1px solid var(--line); border-radius: 3px; background: var(--surface); font: inherit; }
.form_input:focus { outline: 2px solid var(--red); outline-offset: -1px; }
.form_input[readonly] { background: var(--bg); color: var(--muted); }
.form .button { margin-top: 12px; justify-self: start; }
.form_fieldset { border: 0; padding: 0; margin: 8px 0 0; }
.form_check { display: inline-flex; align-items: center; gap: 6px; margin-right: 16px; }
.form_inline { display: flex; gap: 8px; }
.filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.filters .form_input { width: auto; min-width: 150px; }

.table_wrap { overflow-x: auto; background: var(--surface); border: 1px solid var(--line); }
.table { width: 100%; border-collapse: collapse; }
.table th { text-align: left; font-size: 12px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
.table th, .table td { padding: 8px 12px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.table tbody tr:hover { background: var(--bg); }
.table.is-compact { font-size: 13px; }
.table.is-compact th, .table.is-compact td { padding: 7px 8px; white-space: normal; vertical-align: top; }
.table.is-compact td:nth-child(2) { white-space: nowrap; }
.table_empty { text-align: center; color: var(--muted); padding: 24px; }
.table_mono { font-family: ui-monospace, Menlo, monospace; font-size: 12px; white-space: normal; max-width: 360px; word-break: break-all; }

.status { display: inline-block; padding: 1px 8px; border-radius: 10px; font-size: 12px; background: var(--bg); border: 1px solid var(--line); }
.status.is-actif { color: var(--ok); border-color: var(--ok); }
.status.is-invite { color: var(--warn); border-color: var(--warn); }
.status.is-suspendu, .status.is-verrou { color: var(--red); border-color: var(--red); }
.status.is-archive { color: var(--muted); }

.panel { margin: 0 0 16px; padding: 16px; background: var(--surface); border: 1px solid var(--line); max-width: 720px; }
.panel.is-danger { border-left: 3px solid var(--red); }
.panel_title { font-size: 14px; margin-bottom: 8px; }
.list { margin: 0; padding-left: 18px; }

.module_grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: var(--gap); margin-top: 16px; }
.module_card { padding: 16px; background: var(--surface); border: 1px solid var(--line); }
.module_title { font-size: 15px; margin-bottom: 6px; }

@media (max-width: 640px) { .topbar { gap: 12px; } .page_head { flex-direction: column; align-items: flex-start; } }
.module_title { display: flex; align-items: center; gap: 12px; font-size: 18px; margin-bottom: 8px; }
.module_title img { clip-path: circle(47%); transform: scale(1.06); flex: none; }   /* le jpg a un cadre noir autour du cercle rouge : on rogne dedans */
