/* Contrôles Maze Event, sur le modèle du dashboard MFA, en violet Maze.
   Champs soulignés à trait d’accent, menus déroulants à flèche dessinée, interrupteurs à la place des
   cases à cocher. Boutons et badges « contour + halo » dans l’espace de gestion uniquement. */
:root {
  --ctl-line: var(--accent, #989bfb);
  --ctl-border: #3a4256;
  --ctl-success: var(--green, #76d9ae);
  --ctl-warning: var(--yellow, #e2bf77);
  --ctl-danger: var(--red, #f48b9a);
}

/* Champs texte : fond transparent, souligné, trait violet qui s’étend depuis la gauche au focus. */
:root
  body
  :is(
    input:not([type]),
    input[type="text"],
    input[type="number"],
    input[type="search"],
    input[type="email"],
    input[type="password"],
    input[type="url"],
    input[type="tel"],
    input[type="date"],
    input[type="time"],
    input[type="datetime-local"],
    textarea
  ) {
  --field-line: var(--ctl-line);
  border: 0;
  border-bottom: 1px solid var(--ctl-border);
  border-radius: 0;
  background: linear-gradient(var(--field-line), var(--field-line)) left bottom /
    0 2px no-repeat transparent;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  color: var(--text);
  transition:
    background-size 0.3s cubic-bezier(0.6, -0.28, 0.735, 0.045),
    border-color 0.15s;
}
:root
  body
  :is(
    input:not([type]),
    input[type="text"],
    input[type="number"],
    input[type="search"],
    input[type="email"],
    input[type="password"],
    input[type="url"],
    input[type="tel"],
    input[type="date"],
    input[type="time"],
    input[type="datetime-local"],
    textarea
  ):is(:focus, :focus-visible) {
  outline: none;
  background-size: 100% 2px;
  border-bottom-color: transparent;
}
:root body :is(input, textarea, select):hover:not(:disabled, :focus) {
  border-bottom-color: #566079;
}
:root body :is(input, textarea, select):user-invalid {
  --field-line: var(--ctl-danger);
  border-bottom-color: var(--ctl-danger);
}
:root body :is(input, textarea)::placeholder {
  color: #737a8c;
  opacity: 1;
}
:root body :is(input, textarea, select):disabled {
  opacity: 0.45;
  cursor: not-allowed;
}
:root body .search-box input {
  background-color: transparent;
}

/* Menus déroulants : même champ souligné, flèche dessinée à droite (flèche native masquée). */
:root body select {
  --field-line: var(--ctl-line);
  appearance: none;
  -webkit-appearance: none;
  border: 0;
  border-bottom: 1px solid var(--ctl-border);
  border-radius: 0;
  padding-right: 34px;
  background:
    linear-gradient(var(--field-line), var(--field-line)) left bottom / 0 2px
      no-repeat,
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8' fill='none' stroke='%23989bfb' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 1.5l5 5 5-5'/%3E%3C/svg%3E")
      right 12px center / 11px 8px no-repeat,
    transparent;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  color: var(--text);
  cursor: pointer;
  transition:
    background-size 0.3s cubic-bezier(0.6, -0.28, 0.735, 0.045),
    border-color 0.15s;
}
:root body select:is(:focus, :focus-visible) {
  outline: none;
  background-size:
    100% 2px,
    11px 8px;
  border-bottom-color: transparent;
}
:root body select option {
  background: #101520;
  color: var(--text);
}

/* Interrupteur unique (modèle Uiverse) : contour, rond blanc, halo violet une fois coché. */
:root body input[type="checkbox"] {
  appearance: none;
  -webkit-appearance: none;
  position: relative;
  display: inline-block;
  flex: none;
  box-sizing: border-box;
  width: 3.5em;
  min-width: 3.5em;
  height: 2em;
  min-height: 2em;
  margin: 0;
  padding: 0;
  font-size: 12px;
  vertical-align: middle;
  border: 1px solid #4a4f5e;
  border-radius: 50px;
  background: transparent;
  cursor: pointer;
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}
:root body input[type="checkbox"]::after {
  content: "";
  position: absolute;
  left: 0.2em;
  bottom: 0.2em;
  width: 1.4em;
  height: 1.4em;
  border-radius: 50px;
  background: #fff;
  transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
}
:root body input[type="checkbox"]:checked {
  border-color: var(--ctl-line);
  box-shadow: 0 0 1.2em color-mix(in srgb, var(--ctl-line) 80%, transparent);
}
:root body input[type="checkbox"]:checked::after {
  transform: translateX(1.5em);
}
:root body input[type="checkbox"]:focus-visible {
  outline: 2px solid var(--ctl-line);
  outline-offset: 3px;
}
.check-field {
  gap: 12px;
  min-height: 44px;
  cursor: pointer;
}

/* Boutons « contour + halo » : fond transparent, contour fin, halo de la couleur d’intention au survol. */
body.dashboard .btn,
dialog.modal .btn {
  --btn-tone: var(--ctl-line);
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: #dfe1ea;
  box-shadow: none;
  transition:
    border-color 0.2s,
    color 0.2s,
    box-shadow 0.2s;
}
body.dashboard .btn.primary,
dialog.modal .btn.primary {
  border-color: var(--ctl-line);
  color: #fff;
}
body.dashboard .btn.danger,
dialog.modal .btn.danger {
  --btn-tone: var(--ctl-danger);
  border-color: color-mix(in srgb, var(--ctl-danger) 60%, transparent);
  color: var(--ctl-danger);
}
body.dashboard .btn:hover:not(:disabled),
dialog.modal .btn:hover:not(:disabled) {
  background: transparent;
  border-color: var(--btn-tone);
  box-shadow: 0 0 12px color-mix(in srgb, var(--btn-tone) 50%, transparent);
  color: #fff;
}
body.dashboard .btn.danger:hover:not(:disabled),
dialog.modal .btn.danger:hover:not(:disabled) {
  color: var(--ctl-danger);
}
body.dashboard .btn:active:not(:disabled),
dialog.modal .btn:active:not(:disabled) {
  background: color-mix(in srgb, var(--btn-tone) 8%, transparent);
}

/* Badges : rectangle fin, contour et texte de la couleur d’état. */
body.dashboard .badge,
dialog.modal .badge {
  --badge-tone: #c3c6ff;
  background: transparent;
  border: 1px solid color-mix(in srgb, var(--badge-tone) 60%, transparent);
  border-radius: 3px;
  color: var(--badge-tone);
  letter-spacing: 0.03em;
}
:is(body.dashboard, dialog.modal)
  .badge:is(
    .active,
    .live,
    .confirmed,
    .accepted,
    .received,
    .approved,
    .paid,
    .paid_cash
  ) {
  --badge-tone: var(--ctl-success);
}
:is(body.dashboard, dialog.modal) .badge:is(.pending, .sent, .leave) {
  --badge-tone: var(--ctl-warning);
}
:is(body.dashboard, dialog.modal)
  .badge:is(.cancelled, .declined, .departed, .rejected, .refused) {
  --badge-tone: var(--ctl-danger);
}
:is(body.dashboard, dialog.modal) .badge:is(.draft, .finished, .completed) {
  --badge-tone: #9aa0b3;
}
:is(body.dashboard, dialog.modal) .badge.live {
  box-shadow: 0 0 10px color-mix(in srgb, var(--badge-tone) 45%, transparent);
}

@media (prefers-reduced-motion: reduce) {
  :root body :is(input, textarea, select, .btn),
  :root body input[type="checkbox"]::after {
    transition: none;
  }
}

/* ——— Contacts, services et banque ——— */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}
.toolbar {
  flex-wrap: wrap;
}
.inline-select select {
  min-width: 190px;
}
.section-title {
  font-size: 17px;
  margin: 0 0 12px;
}
.group-status {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 18px;
}
.duty-pill {
  --pill: #9aa0b3;
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 4px 8px;
  padding: 5px 10px;
  border: 1px solid color-mix(in srgb, var(--pill) 55%, transparent);
  border-radius: 3px;
  color: var(--pill);
  font-size: 11px;
  font-weight: 600;
  white-space: nowrap;
}
.duty-pill i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: currentColor;
}
.duty-pill.on {
  --pill: var(--ctl-success);
  box-shadow: 0 0 10px color-mix(in srgb, var(--pill) 35%, transparent);
}
.duty-pill.on i {
  animation: duty-pulse 1.8s ease-in-out infinite;
}
.duty-pill small {
  color: var(--muted);
  font-weight: 400;
}
@keyframes duty-pulse {
  50% {
    opacity: 0.35;
  }
}
@media (prefers-reduced-motion: reduce) {
  .duty-pill.on i {
    animation: none;
  }
}
.contact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 14px;
}
.contact-card {
  display: grid;
  gap: 14px;
  align-content: start;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--panel);
}
.contact-card.is-on {
  border-color: color-mix(in srgb, var(--ctl-success) 40%, var(--line));
}
.contact-top {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}
.contact-top strong {
  display: block;
  font-size: 15px;
}
.grade-chip {
  display: inline-block;
  margin-top: 4px;
  color: var(--accent);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.contact-card dl {
  display: grid;
  gap: 8px;
  margin: 0;
}
.contact-card dl div {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
}
.contact-card dt {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--muted);
  font-size: 12px;
}
.contact-card dd {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin: 0;
  font-weight: 600;
}
.contact-card dd a {
  color: var(--text);
  text-decoration: underline;
  text-decoration-color: color-mix(in srgb, var(--accent) 60%, transparent);
  text-underline-offset: 3px;
}
.contact-card button.icon-btn.copy {
  width: 30px;
  height: 30px;
}
.amount.in {
  color: var(--ctl-success);
}
.amount.out {
  color: var(--ctl-danger);
}
.tabs {
  display: flex;
  gap: 4px;
  margin: 28px 0 16px;
  border-bottom: 1px solid var(--line);
  overflow-x: auto;
}
.tabs .tab {
  border: 0;
  border-bottom: 2px solid transparent;
  background: transparent;
  color: var(--muted);
  padding: 12px 16px;
  font-weight: 600;
  white-space: nowrap;
}
.tabs .tab[aria-selected="true"] {
  border-bottom-color: var(--accent);
  color: var(--text);
}
.tabs .tab:hover {
  color: var(--text);
}
.pager {
  margin-top: 14px;
}
@media (min-width: 1001px) {
  .stats:has(> .stat:nth-child(5)) {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
  .stats:has(> .stat:nth-child(3)):not(:has(> .stat:nth-child(4))) {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
.contact-card > .duty-pill {
  justify-self: start;
}
.stats:has(> .stat:nth-child(5)) .stat strong {
  font-size: clamp(20px, 1.9vw, 27px);
}
@media (max-width: 600px) {
  .toolbar > select,
  .toolbar > .inline-select,
  .toolbar > .inline-select select {
    flex: 1 1 100%;
    width: 100%;
  }
}

/* Barres de défilement fines partout. */
* {
  scrollbar-width: thin;
  scrollbar-color: #3a4256 transparent;
}
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: #3a4256;
  border-radius: 6px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--accent);
}
::-webkit-scrollbar-button {
  display: none;
}

/* Fermeture : une simple croix, sans contour. */
.modal-head [data-close] {
  border: 0;
  background: transparent;
  color: #c6cbdc;
}
.modal-head [data-close]:hover {
  color: #fff;
  background: transparent;
}

/* Photo de profil : rond cliquable, icône d’envoi tant qu’il n’y a pas de photo. */
.avatar-upload {
  display: flex;
  align-items: center;
  gap: 18px;
  cursor: pointer;
}
.avatar-ring {
  flex: none;
  display: grid;
  place-items: center;
  width: 84px;
  height: 84px;
  overflow: hidden;
  border: 1px dashed #5a6380;
  border-radius: 50%;
  color: var(--accent);
  transition:
    border-color 0.2s,
    box-shadow 0.2s;
}
.avatar-ring img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.avatar-upload:hover .avatar-ring,
.avatar-upload:focus-within .avatar-ring {
  border-color: var(--accent);
  border-style: solid;
  box-shadow: 0 0 16px #989bfb55;
}
.avatar-upload-text {
  display: grid;
  gap: 4px;
}
.avatar-upload-text strong {
  font-size: 17px;
}
.avatar-upload-text small {
  color: var(--muted);
  font-size: 12px;
}
:root body input:disabled {
  opacity: 0.55;
  border-bottom-style: dashed;
}

/* Affiches d’événement dans le dashboard. */
.poster-thumb {
  display: block;
  width: 54px;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 4px;
  border: 1px solid var(--line);
}
.poster-field {
  display: flex;
  gap: 18px;
  align-items: flex-start;
}
.poster-field > img {
  flex: none;
  width: 110px;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 6px;
  border: 1px solid var(--line);
}
.poster-field > div {
  flex: 1;
  display: grid;
  gap: 12px;
}
dialog.modal:focus {
  outline: none;
}

/* ——— Dashboard : logo, fond « halo violet » et bandeau photo des pages ——— */
/* Le PNG du logo est carré avec le logo en bande centrale : recadrage sur la bande. */
body.dashboard .sidebar .brand img {
  width: 168px;
  height: 56px;
  margin-left: 8px;
  object-fit: cover;
}
body.dashboard .sidebar {
  background: linear-gradient(180deg, #989bfb12, transparent 45%), #0b0e15;
}
body.dashboard .main-shell {
  min-height: 100dvh;
  background:
    radial-gradient(900px 420px at 88% -8%, #989bfb26, transparent 65%),
    radial-gradient(600px 320px at 10% 105%, #989bfb12, transparent 70%),
    linear-gradient(#ffffff05 1px, transparent 1px) 0 0 / 56px 56px,
    linear-gradient(90deg, #ffffff05 1px, transparent 1px) 0 0 / 56px 56px,
    #0d1018;
  background-attachment: fixed;
}
body.dashboard .topbar {
  background: #0d1018b3;
  backdrop-filter: blur(12px);
}
body.dashboard
  :is(.panel, .stat, .activity-card, .moderation-card, .contact-card) {
  background-color: #161b27e0;
  backdrop-filter: blur(6px);
}
.page-band {
  isolation: isolate;
  overflow: hidden;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  min-height: 230px;
  margin: -36px calc(-1 * var(--page-gutter)) 28px;
  padding: 40px var(--page-gutter) 30px;
  border-bottom: 1px solid var(--line);
}
.page-band > .arena-backdrop {
  z-index: -2;
  object-position: 60% 45%;
}
.page-band::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(90deg, #0a0e1bf2 0%, #0a0e1b99 50%, #0a0e1b40),
    linear-gradient(0deg, #0d1018 0%, transparent 65%);
}
.page-band h1 {
  width: fit-content;
  max-width: 100%;
  margin: 0;
  padding-right: 0.1em;
  font-family: "Archivo", "Arial Black", Arial, sans-serif;
  font-size: clamp(32px, 3.4vw, 52px);
  font-style: italic;
  font-weight: 900;
  letter-spacing: 0.045em;
  line-height: 1.05;
  text-transform: uppercase;
  color: #f7f7ff;
}
@supports (background-clip: text) or (-webkit-background-clip: text) {
  .page-band h1 {
    background: linear-gradient(105deg, #fff 4%, var(--accent) 48%, #fff 96%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
  }
}
.page-band .band-subtitle {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 14px 0 0;
  max-width: none;
  font-size: 11px;
  font-weight: 600;
  line-height: 1.6;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #c6cbdc;
}
.page-band .band-subtitle::before {
  content: "";
  flex: none;
  width: 32px;
  height: 1px;
  background: var(--accent);
  box-shadow: 0 0 8px #989bfb;
}
/* Action du bandeau : libellé en capitales, icône dans un rond violet. */
.page-band .page-heading-action .btn {
  min-height: 44px;
  padding: 0;
  border: 0;
  background: none;
  box-shadow: none;
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  flex-direction: row-reverse;
  gap: 12px;
}
.page-band .page-heading-action .btn svg {
  box-sizing: content-box;
  width: 16px;
  height: 16px;
  padding: 8px;
  border: 1px solid var(--accent);
  border-radius: 50%;
  box-shadow: 0 0 12px #989bfb66;
  transition: transform 0.2s;
}
.page-band .page-heading-action .btn:hover {
  color: var(--accent);
  background: none;
  box-shadow: none;
}
.page-band .page-heading-action .btn:hover svg {
  transform: rotate(90deg);
}
@media (max-width: 1000px) {
  .page-band {
    margin-top: -26px;
    min-height: 190px;
  }
}
@media (max-width: 600px) {
  .page-band {
    flex-direction: column;
    align-items: flex-start;
    min-height: 200px;
    padding-bottom: 22px;
  }
  .page-band .band-subtitle {
    font-size: 10px;
    gap: 10px;
  }
  .page-band .page-heading-action,
  .page-band .page-heading-action .btn {
    width: auto;
  }
}
.pill-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.duty-pill.busy {
  --pill: #f0a35e;
}

/* Réservations : qui gère quoi et historique des actions. */
.row-actions {
  white-space: nowrap;
  text-align: right;
}
.reservation-state {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.timeline {
  list-style: none;
  margin: 18px 0;
  padding: 0 0 0 18px;
  border-left: 1px solid var(--line);
  display: grid;
  gap: 14px;
}
.timeline li {
  position: relative;
  display: grid;
  gap: 2px;
  font-size: 13px;
}
.timeline li::before {
  content: "";
  position: absolute;
  left: -23px;
  top: 5px;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #0d1018;
  border: 1px solid var(--accent);
}
.timeline li.taken::before {
  background: var(--accent);
  box-shadow: 0 0 8px #989bfb;
}
.timeline li.completed::before {
  border-color: var(--green);
  background: var(--green);
}
.timeline li.cancelled::before {
  border-color: var(--red);
  background: var(--red);
}
.timeline span {
  color: var(--muted);
  font-size: 12px;
}
.timeline em {
  color: #c6cbdc;
  font-size: 12px;
}
.reservation-items {
  margin: 12px 0;
  padding-left: 18px;
  display: grid;
  gap: 4px;
  font-size: 13px;
}
.weapon-thumb {
  width: 72px;
  height: 28px;
  object-fit: cover;
  border-radius: 3px;
}
tr.is-muted td {
  opacity: 0.5;
}

/* L’attribut hidden l’emporte toujours sur un display défini par une classe. */
[hidden] {
  display: none !important;
}

/* Mes infos et payes */
.me-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr);
  gap: 18px;
  align-items: start;
}
.me-card .range-facts {
  padding: 0 22px 18px;
}
.pay-totals {
  display: flex;
  flex-wrap: wrap;
  gap: 14px 40px;
  margin: 6px 0 26px;
}
.pay-totals > div {
  display: grid;
  gap: 4px;
}
.pay-totals strong {
  font-size: 22px;
}
.pay-totals small {
  color: var(--muted);
}
@media (max-width: 1000px) {
  .me-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}
.reservation-flight {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 10px 0 0;
  font-weight: 600;
}
.reservation-flight svg {
  color: var(--accent, #989bfb);
}
.item-balance {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 10px;
  margin: 0 0 18px;
}
.item-balance div {
  display: grid;
  gap: 4px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #0b0e17;
}
.item-balance strong {
  font-size: 20px;
}
.item-balance small {
  color: var(--muted);
}
.vehicle-state {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
  color: #c6cbdc;
  font-size: 12px;
}
tr.is-selected td {
  background: #989bfb12;
}

/* ——— Équipe : documents, contrat, pôles, fiche employé ——— */
.id-documents {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 340px), 1fr));
  gap: 16px;
}
.id-document {
  position: relative;
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: linear-gradient(135deg, #989bfb12, transparent 60%), #0b0e17;
}
.id-document figcaption {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 10px;
}
.id-document figcaption small {
  color: var(--muted);
  font-size: 11px;
}
/* Format des cartes en jeu (≈ 2:1) : la photo entière, sans recadrage. */
.id-document img,
.id-placeholder {
  width: 100%;
  aspect-ratio: 2 / 1;
  border-radius: 8px;
  object-fit: contain;
  background: #07090f;
}
.id-placeholder {
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 10px;
  padding: 16px;
  border: 1px dashed #989bfb55;
  color: var(--muted);
  font-size: 13px;
  text-align: center;
}
.id-placeholder svg {
  color: #989bfb;
}
.id-upload {
  justify-self: start;
  cursor: pointer;
}
.contract-doc {
  max-width: 820px;
  padding: 28px 32px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #0b0e17;
}
.contract-doc header {
  display: grid;
  gap: 6px;
  padding-bottom: 14px;
  margin-bottom: 8px;
  border-bottom: 1px solid #989bfb55;
}
.contract-doc header h3 {
  margin: 0;
  font-family: "Archivo", "Arial Black", Arial, sans-serif;
  font-style: italic;
  font-size: 22px;
  text-transform: uppercase;
}
.contract-body {
  max-height: 560px;
  overflow: auto;
  padding-right: 6px;
  color: #d5d9e6;
  font-size: 14px;
  line-height: 1.65;
}
.contract-body h4 {
  margin: 22px 0 6px;
  color: #c3c6ff;
  font-size: 13px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.contract-body h5 {
  margin: 14px 0 4px;
  font-size: 14px;
}
.contract-body p {
  margin: 0 0 6px;
}
.contract-body ul {
  margin: 0 0 8px;
  padding-left: 20px;
}
.contract-doc footer {
  margin-top: 14px;
}
.pole-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 380px), 1fr));
  gap: 16px;
}
.pole-card .pole-pages {
  padding: 0 22px;
}
.pole-members {
  display: grid;
  margin: 12px 0 0;
  padding: 0 22px;
  list-style: none;
}
.pole-members li {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 10px;
  padding: 10px 0;
  border-top: 1px solid var(--line);
}
.pole-members li > span:nth-child(2) {
  display: grid;
}
.pole-members small {
  color: var(--muted);
}
.pole-actions {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.pole-add {
  display: flex;
  gap: 10px;
  padding: 14px 22px 20px;
}
.pole-add select {
  flex: 1;
  min-width: 0;
}
.employee-file {
  display: grid;
  /* Une colonne à la largeur de la fenêtre : un tableau large défile dans son cadre
     au lieu d’élargir la fiche. */
  grid-template-columns: minmax(0, 1fr);
  gap: 22px;
}
.employee-file [data-pane] {
  min-width: 0;
}
.file-summary {
  display: flex;
  align-items: center;
  gap: 14px;
}
.file-summary > div {
  display: grid;
  gap: 4px;
}
.file-summary small {
  color: var(--muted);
}
.file-title {
  margin: 0 0 12px;
  font-size: 13px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #c3c6ff;
}
.check-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 22px;
  margin: 0;
  padding: 0;
  border: 0;
}
.check-list legend {
  margin-bottom: 8px;
  font-size: 12px;
  color: var(--muted);
}
.hr-timeline li.hired::before,
.hr-timeline li.rehired::before {
  background: #5fd39a;
}
.hr-timeline li.left::before {
  background: #ff8094;
}
@media (max-width: 600px) {
  .contract-doc {
    padding: 20px 18px;
  }
  .pole-members li {
    grid-template-columns: auto minmax(0, 1fr) auto;
  }
  .pole-members li .badge {
    grid-column: 2;
    justify-self: start;
  }
}

/* Œil des champs mot de passe (connexion, inscription, changement). */
.password-field {
  position: relative;
  display: block;
}
.password-field input {
  width: 100%;
  padding-right: 44px;
}
.password-eye {
  position: absolute;
  top: 50%;
  right: 4px;
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  transform: translateY(-50%);
  border: 0;
  background: none;
  color: var(--muted, #a1a9bb);
  cursor: pointer;
}
.password-eye:hover,
.password-eye[aria-pressed="true"] {
  color: #989bfb;
}

/* Champs remplis automatiquement par le navigateur : pas de fond gris ni de texte collé,
   le style fin du site est conservé (le fond jaune/gris de Chrome est différé à l’infini). */
input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus {
  -webkit-text-fill-color: var(--text, #f1f2f8);
  caret-color: var(--text, #f1f2f8);
  transition:
    background-color 600000s 0s,
    color 600000s 0s;
}
input:autofill {
  background: transparent;
}

/* Robustesse du mot de passe : barre fine qui s’allonge et change de couleur. */
.pw-strength {
  display: grid;
  gap: 6px;
  margin-top: -6px;
}
.pw-bar {
  height: 3px;
  border-radius: 3px;
  background: #ffffff14;
  overflow: hidden;
}
.pw-bar i {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  transition:
    width 0.35s cubic-bezier(0.2, 0.8, 0.2, 1),
    background-color 0.35s ease;
}
.pw-strength small {
  min-height: 14px;
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted, #a1a9bb);
  transition: color 0.35s ease;
}
.pw-strength[data-level="1"] .pw-bar i {
  width: 25%;
  background: #ff6b7f;
}
.pw-strength[data-level="2"] .pw-bar i {
  width: 50%;
  background: #f5b94c;
}
.pw-strength[data-level="3"] .pw-bar i {
  width: 75%;
  background: #989bfb;
}
.pw-strength[data-level="4"] .pw-bar i {
  width: 100%;
  background: #5fd39a;
}
.pw-strength[data-level="1"] small {
  color: #ff8b9a;
}
.pw-strength[data-level="4"] small {
  color: #7fe0b0;
}
@media (prefers-reduced-motion: reduce) {
  .pw-bar i {
    transition: none;
  }
}
.temp-password {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}
.temp-password > div {
  display: grid;
  gap: 4px;
}
.temp-password small {
  color: var(--muted);
}
.temp-code {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin: 14px 0;
  padding: 14px 18px;
  border: 1px solid #989bfb55;
  border-radius: 10px;
  background: #0b0e17;
}
.temp-code code {
  font-size: 24px;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: #fff;
  user-select: all;
}
@media (max-width: 600px) {
  .temp-password {
    flex-direction: column;
    align-items: stretch;
  }
}

/* Tableau partagé : bandeau de filtre, une valeur par colonne, pagination numérotée. */
.data-table {
  overflow: hidden;
}
.data-table tbody > tr[hidden],
.responsive-table tr[hidden] {
  display: none !important;
}
.table-band {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--line);
  background: linear-gradient(90deg, #989bfb12, transparent 70%);
}
.table-band .search-box {
  flex: 1 1 260px;
  max-width: 380px;
}
.table-band .search-box input {
  min-height: 40px;
}
.table-band .search-box svg {
  top: 12px;
}
.pagination {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 16px;
  padding: 12px 18px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 12px;
}
.pagination:empty {
  display: none;
}
.pagination.server {
  border: 1px solid #2b354c;
  background: #151c29;
}
.pagination-summary {
  font-variant-numeric: tabular-nums;
}
.pagination-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.page-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-width: 36px;
  height: 36px;
  padding: 0 11px;
  border: 1px solid #3a4459;
  border-radius: 6px;
  background: #ffffff05;
  color: var(--text);
  font: inherit;
  font-size: 12px;
  font-variant-numeric: tabular-nums;
  cursor: pointer;
  transition:
    border-color 0.15s,
    background 0.15s,
    color 0.15s,
    transform 0.15s;
}
.page-btn:hover:not(:disabled) {
  border-color: var(--accent);
  background: #989bfb1c;
}
.page-btn:active:not(:disabled) {
  transform: translateY(1px);
}
.page-btn.current {
  border-color: var(--accent);
  background: var(--accent);
  color: #10121c;
  font-weight: 700;
}
.page-btn:disabled {
  opacity: 0.38;
  cursor: default;
}
.page-btn:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
.cell-mono {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 12px;
  color: #c9cdf9;
  white-space: nowrap;
}
.cell-muted {
  color: var(--muted);
}
@media (max-width: 700px) {
  .page-btn span {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip-path: inset(50%);
  }
  .pagination {
    justify-content: center;
  }
}
/* Barre de filtres d’une vue : posée comme bandeau au-dessus de son tableau. */
.toolbar.filter-band {
  margin-bottom: 0;
  padding: 14px 18px;
  border: 1px solid #2b354c;
  border-bottom: 0;
  border-radius: 7px 7px 0 0;
  background: linear-gradient(90deg, #989bfb14, transparent 70%), #151c29;
  justify-content: flex-start;
}
.toolbar.filter-band .search-box input,
.toolbar.filter-band select {
  min-height: 42px;
}
.toolbar.filter-band .search-box svg {
  top: 13px;
}
.toolbar.filter-band > .btn,
.toolbar.filter-band > a.btn {
  margin-left: auto;
}
.toolbar.filter-band + * > .data-table,
.toolbar.filter-band + .data-table {
  border-top-left-radius: 0;
  border-top-right-radius: 0;
}
.toolbar.filter-band + * > .empty-state,
.toolbar.filter-band + * > .empty {
  border-top-left-radius: 0;
  border-top-right-radius: 0;
}
.toolbar.filter-band + p {
  margin: 0;
  padding: 0 18px 14px;
  border: 1px solid #2b354c;
  border-top: 0;
  border-bottom: 0;
  background: #151c29;
}
.pagination.server {
  margin-top: 0;
  border-top: 0;
  border-radius: 0 0 7px 7px;
}
*:has(+ .pagination.server) > .data-table {
  border-bottom-left-radius: 0;
  border-bottom-right-radius: 0;
}
.cell-wrap {
  white-space: normal;
  min-width: 240px;
  max-width: 460px;
}
@media (max-width: 600px) {
  .toolbar.filter-band {
    padding: 12px;
  }
}
.pagination .page-btn.current,
dialog .pagination .page-btn.current {
  border-color: var(--accent);
  background: var(--accent);
  color: #10121c;
}
td .duty-pill {
  flex-wrap: nowrap;
}
/* Cellule d’actions : reste une cellule de tableau (un display:flex sur le td
   décale la bordure de la ligne) ; les boutons sont espacés par une marge. */
td.row-actions > * + * {
  margin-left: 8px;
}
td > .row-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: nowrap;
}
@media (max-width: 600px) {
  td > .row-actions,
  td.row-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: flex-start;
  }
  td.row-actions > * + * {
    margin-left: 0;
  }
  .responsive-table td.row-actions,
  .responsive-table td:has(> .row-actions) {
    grid-column: 1/-1;
  }
}
.pagination.server + .section-title {
  margin-top: 28px;
}

/* Menu du dashboard : recherche, catégories qui défilent, profil toujours visible. */
.sidebar,
body.dashboard .sidebar {
  overflow: hidden;
}
.nav-search {
  position: relative;
  display: block;
  margin: 18px 0 14px;
  flex: none;
}
.nav-search svg {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: #8890a6;
  pointer-events: none;
}
.nav-search input {
  width: 100%;
  min-height: 40px;
  padding: 0 12px 0 36px;
  border: 1px solid #273044;
  border-radius: 6px;
  background: #ffffff06;
  color: var(--text);
  font: inherit;
  font-size: 12px;
  transition:
    border-color 0.15s,
    background 0.15s;
}
.nav-search input:focus {
  outline: none;
  border-color: var(--accent);
  background: #989bfb10;
}
.nav-search input::-webkit-search-cancel-button {
  filter: grayscale(1) brightness(1.6);
}
.nav-scroll {
  flex: 1;
  min-height: 0;
  margin: 0 -16px;
  padding: 0 16px 8px;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: #3a4560 transparent;
}
.nav-scroll::-webkit-scrollbar {
  width: 5px;
}
.nav-scroll::-webkit-scrollbar-thumb {
  background: #3a4560;
  border-radius: 5px;
}
.nav-scroll::-webkit-scrollbar-thumb:hover {
  background: var(--accent);
}
.nav-scroll .nav-label {
  margin-top: 4px;
}
.nav-scroll .nav-link.active::before {
  left: -16px;
}
.nav-empty {
  padding: 8px 12px;
  color: var(--muted);
  font-size: 12px;
}
.sidebar-bottom {
  flex: none;
  margin-top: 0;
  padding-top: 4px;
  background: inherit;
}
.sidebar .nav-section[hidden],
.sidebar .nav-link[hidden] {
  display: none;
}

/* Bandeau des pages du dashboard : titre centré sur la hauteur de la photo. */
body.dashboard .page-band {
  align-items: center;
  padding-block: 32px;
}
@media (max-width: 600px) {
  body.dashboard .page-band {
    justify-content: center;
    padding-block: 28px;
  }
}
/* Écran peu haut (tablette AVA en 720p, ≈ 598 px) : bandeau photo abaissé pour
   laisser la place au contenu. */
@media (min-width: 601px) and (max-height: 700px) {
  body.dashboard .page-band {
    min-height: 130px;
    margin-bottom: 20px;
    padding-block: 20px;
  }
  body.dashboard .page-band h1 {
    font-size: clamp(28px, 3vw, 40px);
  }
}
/* Fiche utilisateur : photo cliquable, bouton pour la retirer. */
.user-avatar label {
  cursor: pointer;
  border-radius: 50%;
}
.user-avatar .avatar-ring {
  width: 96px;
  height: 96px;
}
.user-avatar:hover .avatar-ring {
  border-color: #5a6380;
  box-shadow: none;
}
.user-avatar label:hover .avatar-ring,
.user-avatar label:focus-within .avatar-ring {
  border-color: var(--accent);
  border-style: solid;
  box-shadow: 0 0 16px #989bfb55;
}
.user-avatar #remove-avatar {
  justify-self: start;
  padding: 0;
  color: var(--red);
  font-size: 12px;
}
.temp-password.danger-zone {
  padding: 14px 16px;
  border: 1px solid #f48b9a40;
  border-radius: 6px;
  background: #f48b9a0a;
}
.temp-password.danger-zone strong {
  color: #f6a3af;
}

/* Fenêtres du dashboard : en-tête façon bandeau (photo de l’arène, titre des pages,
   trait lumineux fondu sous le titre). */
body.dashboard dialog.modal .modal-head {
  align-items: center;
  padding: 30px 28px 26px;
  border-bottom: 1px solid #989bfb33;
  background:
    linear-gradient(90deg, #0a0e1bf5 0%, #0a0e1bb3 55%, #0a0e1b55),
    linear-gradient(0deg, #171e2c 0%, #171e2cd9 22%, transparent 80%),
    url(/assets/maze-arena-night.webp) 60% 42% / cover,
    #171e2c;
  background-clip: padding-box;
  backdrop-filter: none;
}
body.dashboard dialog.modal .modal-head h2 {
  position: relative;
  width: fit-content;
  max-width: 100%;
  padding-right: 0.1em;
  font-family: "Archivo", "Arial Black", Arial, sans-serif;
  font-size: 28px;
  font-style: italic;
  font-weight: 900;
  letter-spacing: 0.04em;
  line-height: 1.05;
  text-transform: uppercase;
  overflow-wrap: anywhere;
  color: #f7f7ff;
}
@supports (background-clip: text) or (-webkit-background-clip: text) {
  body.dashboard dialog.modal .modal-head h2 {
    background: linear-gradient(105deg, #fff 4%, var(--accent) 48%, #fff 96%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
  }
}
body.dashboard dialog.modal .modal-head h2::after {
  content: "";
  position: absolute;
  left: 0.05em;
  bottom: -9px;
  width: 46%;
  min-width: 80px;
  height: 2px;
  border-radius: 2px;
  background: linear-gradient(90deg, var(--accent), #989bfb00);
  box-shadow: 0 0 12px #989bfbaa;
}
body.dashboard dialog.modal .modal-head .eyebrow {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 10px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.18em;
  color: #c6cbdc;
}
body.dashboard dialog.modal .modal-head .eyebrow::before {
  content: "";
  flex: none;
  width: 28px;
  height: 1px;
  background: var(--accent);
  box-shadow: 0 0 8px #989bfb;
}
@media (max-width: 600px) {
  body.dashboard dialog.modal .modal-head {
    padding: 24px 20px 22px;
  }
  body.dashboard dialog.modal .modal-head h2 {
    font-size: 21px;
  }
}
/* Téléphone couché : en-tête compact, sans surtitre. */
@media (max-width: 1000px) and (max-height: 500px) and (orientation: landscape) {
  body.dashboard dialog.modal .modal-head {
    padding: 14px 18px 18px;
  }
  body.dashboard dialog.modal .modal-head .eyebrow {
    display: none;
  }
  body.dashboard dialog.modal .modal-head h2 {
    font-size: 19px;
  }
}
/* Bouton d’action de page déplacé dans le bandeau de filtre (ou sa propre barre). */
.page-heading-action.in-band {
  margin-left: auto;
  padding: 0;
}
.page-heading-action.page-actions {
  display: flex;
  justify-content: flex-end;
  margin: 0 0 18px;
  padding: 0;
}
@media (max-width: 600px) {
  .page-heading-action.in-band {
    margin-left: 0;
    width: 100%;
  }
  .page-heading-action.in-band .btn {
    width: 100%;
    justify-content: center;
  }
}
/* Actions en icônes dans les tableaux (voir, modifier, télécharger, supprimer). */
.icon-actions {
  display: flex;
  justify-content: flex-end;
  gap: 6px;
}
.icon-actions .icon-btn {
  width: 36px;
  height: 36px;
  border: 1px solid #3a4459;
  border-radius: 6px;
  background: #ffffff05;
  color: #c6cbdc;
  transition:
    border-color 0.15s,
    color 0.15s,
    background 0.15s;
}
.icon-actions .icon-btn:hover {
  border-color: var(--accent);
  color: #fff;
  background: #989bfb1c;
}
.icon-actions .icon-btn.danger:hover {
  border-color: var(--red);
  color: var(--red);
  background: #f48b9a14;
}
.icon-actions .icon-btn:disabled {
  opacity: 0.5;
}
/* Aperçu d’un devis : la feuille A4 sur fond sombre, défilable. */
.quote-preview {
  display: grid;
  place-items: center;
  min-height: 200px;
  max-height: min(70vh, 900px);
  overflow: auto;
  padding: 16px;
  border-radius: 8px;
  background: #0b0e15;
}
.quote-preview img {
  display: block;
  width: 100%;
  max-width: 640px;
  height: auto;
  box-shadow: 0 10px 40px #0008;
}
.quote-preview-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 16px;
}

/* Création / modification d’un devis : formulaire à gauche, aperçu en direct à droite. */
.modal.quote-modal {
  width: min(1320px, calc(100vw - 28px));
}
.quote-modal .modal-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 520px);
  gap: 24px;
  align-items: start;
}
.quote-live {
  position: sticky;
  top: 0;
}
.quote-live .eyebrow {
  margin: 0 0 10px;
}
.quote-live .quote-preview {
  max-height: calc(90vh - 190px);
  place-items: start center;
}
.quote-live canvas {
  display: block;
  width: 100%;
  height: auto;
  box-shadow: 0 10px 40px #0008;
}
@media (max-width: 1100px) {
  .quote-modal .modal-body {
    grid-template-columns: 1fr;
  }
  .quote-live {
    position: static;
  }
}

/* ——— Événement : une ligne par activité associée (grille des lignes de devis) ——— */
.quote-line.activity-line {
  grid-template-columns: 1fr 32px;
}

/* ——— Fiche employé : onglets dans la fenêtre, semaine choisie ——— */
.file-tabs {
  margin: 0;
}
.week-toolbar {
  flex-wrap: wrap;
  gap: 12px;
}
.week-toolbar .calendar-tools strong {
  min-width: 0;
}
.rank-top {
  color: var(--accent);
}

/* ——— Recrutement : réponses d’une candidature, éditeur de questions ——— */
.application-answers {
  display: grid;
  gap: 14px;
  margin: 0;
}
.application-answers div {
  display: grid;
  gap: 4px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
}
.application-answers dt {
  color: var(--muted);
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.application-answers dd {
  margin: 0;
  line-height: 1.55;
  white-space: pre-wrap;
}
.question-line {
  display: grid;
  gap: 12px;
  margin: 0 0 14px;
  padding: 16px 20px;
}
.question-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}
@media (min-width: 1001px) {
  .stats.recap-stats:has(> .stat:nth-child(5)) {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

/* Recrutement : aperçu de la photo de la page, entière (paysage ou portrait). */
.recruitment-photo-field .photo-preview img {
  display: block;
  width: 180px;
  max-height: 240px;
  object-fit: contain;
  border: 1px solid var(--line);
  border-radius: 6px;
}

/* Parties en direct : lien unique du HUD, à copier. */
.notice.hud-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}
.notice.hud-link code {
  color: var(--text);
  overflow-wrap: anywhere;
}
h2.section-title.section-space {
  margin-top: 30px;
}
.storage-pills {
  margin-bottom: 18px;
}
/* Nom long (item de coffre…) : passe à la ligne au lieu d’élargir le tableau. */
td.cell-name {
  white-space: normal;
  min-width: 200px;
  max-width: 260px;
}

/* ——— Suivi des vols : carte GTA V, appareils en direct, replay ——— */
.aviation-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 18px;
  align-items: start;
}
.aviation-map-panel {
  position: relative;
  overflow: hidden;
  padding: 0;
}
.gta-map {
  height: min(70vh, 720px);
  min-height: 420px;
  background: #0f9ec4;
  z-index: 0;
}
.gta-map .leaflet-control-zoom a {
  background: #151c29;
  color: #e7e9f5;
  border-color: #2b354c;
}
.gta-map .leaflet-control-zoom a:hover {
  background: #989bfb33;
}
.ac-marker {
  background: none;
  border: 0;
}
.ac-marker svg {
  display: block;
  filter: drop-shadow(0 2px 4px #000a);
  transition: transform 0.3s linear;
}
.leaflet-tooltip.ac-label {
  padding: 5px 9px;
  border: 1px solid #989bfb66;
  border-radius: 6px;
  background: #0d0f1ae6;
  color: #e7e9f5;
  font:
    11px/1.35 Inter,
    system-ui,
    sans-serif;
  box-shadow: 0 4px 14px #0007;
}
.leaflet-tooltip.ac-label::before {
  display: none;
}
.map-empty {
  position: absolute;
  left: 50%;
  bottom: 22px;
  transform: translateX(-50%);
  z-index: 500;
  display: grid;
  justify-items: center;
  gap: 4px;
  padding: 14px 20px;
  border: 1px solid #989bfb55;
  border-radius: 10px;
  background: #0d0f1ae6;
  color: #c6cbdc;
  font-size: 12px;
  text-align: center;
}
.map-empty[hidden] {
  display: none;
}
.map-empty strong {
  color: #fff;
  font-size: 14px;
}
.map-empty svg {
  color: var(--accent);
}
.aviation-side {
  max-height: min(70vh, 720px);
  overflow: auto;
}
.live-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: #ff8a9a;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.live-pill i {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #ff5f73;
  animation: live-blink 1.4s ease-in-out infinite;
}
@keyframes live-blink {
  50% {
    opacity: 0.25;
  }
}
.ac-row {
  display: grid;
  grid-template-columns: 10px minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 12px 18px;
  border: 0;
  border-top: 1px solid var(--line);
  background: none;
  color: var(--text);
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.ac-row:hover {
  background: #989bfb12;
}
.ac-row > i {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}
.ac-row span {
  display: grid;
  gap: 2px;
  min-width: 0;
}
.ac-row strong {
  font-size: 13px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.ac-row small {
  color: var(--muted);
  font-size: 11px;
}
.ac-num {
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.ac-none {
  padding: 0 18px 18px;
}
.replay-top {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}
.replay-title {
  color: #c6cbdc;
  font-size: 13px;
}
.replay-title strong {
  color: #fff;
}
.replay-facts {
  padding: 0 20px;
}
.replay-now {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  margin: 18px 20px 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: var(--line);
}
.replay-now div {
  display: grid;
  gap: 4px;
  padding: 12px;
  background: #151c29;
}
.replay-now span {
  color: var(--muted);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.replay-now strong {
  font-size: 17px;
  font-variant-numeric: tabular-nums;
}
.replay-panel {
  margin-top: 18px;
  padding: 16px 18px;
}
.replay-controls {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}
.replay-controls input[type="range"] {
  flex: 1 1 260px;
  accent-color: var(--accent);
}
.replay-speeds {
  display: flex;
  gap: 6px;
}
.pause-glyph {
  display: inline-block;
  width: 10px;
  height: 12px;
  border-left: 3px solid currentColor;
  border-right: 3px solid currentColor;
}
.alt-profile {
  display: block;
  width: 100%;
  height: 120px;
  margin-top: 14px;
  cursor: crosshair;
}
@media (max-width: 1100px) {
  .aviation-layout {
    grid-template-columns: minmax(0, 1fr);
  }
  .aviation-side {
    max-height: none;
  }
}
@media (max-width: 600px) {
  .gta-map {
    height: 60vh;
    min-height: 320px;
  }
}

/* ——— Lieux sur la carte (pages du site, dashboard) ——— */
.places-map.gta-map {
  height: 420px;
  min-height: 0;
  border: 1px solid var(--line);
  border-radius: 10px;
}
.place-marker {
  background: none;
  border: 0;
}
.place-marker svg {
  display: block;
  filter: drop-shadow(0 3px 5px #000b);
}
.places-list {
  display: grid;
  gap: 8px;
  margin: 12px 0 0;
  padding: 0;
  list-style: none;
}
.places-list li {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff05;
}
.place-focus {
  display: flex;
  flex: 1;
  align-items: center;
  gap: 12px;
  min-width: 0;
  padding: 0;
  border: 0;
  background: none;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.place-focus strong {
  display: block;
  font-size: 14px;
}
.place-focus small {
  display: block;
  color: var(--muted);
  font-size: 12px;
}
.place-pin {
  display: grid;
  place-items: center;
  flex: none;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #989bfb22;
  color: var(--accent);
}
.places-hint {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 12px;
}
.place-popup {
  display: grid;
  gap: 6px;
  min-width: 160px;
}
.place-popup p {
  margin: 0;
  color: #c6cbdc;
}
.gta-map .leaflet-popup-content-wrapper,
.gta-map .leaflet-popup-tip {
  background: #0d0f1af0;
  color: #e7e9f5;
  border: 1px solid #989bfb55;
}
.gta-map .leaflet-popup-content {
  margin: 12px 14px;
  font:
    13px/1.4 Inter,
    system-ui,
    sans-serif;
}
.gta-map a.leaflet-popup-close-button {
  color: #c6cbdc;
}
.check-group {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 22px;
  margin: 0;
  padding: 0;
  border: 0;
}
.check-group legend {
  width: 100%;
  margin-bottom: 8px;
  padding: 0;
  color: var(--muted);
  font-size: 12px;
}
.places-admin-map.gta-map {
  height: min(56vh, 560px);
  min-height: 360px;
}

/* ——— Éditeur de cartes (vue du dessus façon Call of Duty) ——— */
.map-editor {
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr) 300px;
  height: calc(100vh - 120px);
  min-height: 560px;
  border: 1px solid var(--line);
  border-radius: 12px;
  overflow: hidden;
  background: #0b0e15;
}
.map-tools {
  display: grid;
  align-content: start;
  gap: 6px;
  padding: 12px 8px;
  background: #10141f;
  border-right: 1px solid var(--line);
}
.map-tool {
  min-height: 46px;
  padding: 4px;
  border: 1px solid #2b3347;
  border-radius: 10px;
  background: #151b29;
  color: #c9ccdc;
  font:
    700 11px Inter,
    system-ui,
    sans-serif;
  cursor: pointer;
}
.map-tool.on,
.map-tool:hover {
  border-color: var(--accent);
  background: #989bfb22;
  color: #fff;
}
.map-stage {
  position: relative;
  min-width: 0;
}
.map-top {
  position: absolute;
  inset: 12px 12px auto;
  z-index: 2;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}
.map-name {
  flex: 1 1 200px;
  min-width: 0;
  padding: 6px 0;
  border: 0;
  border-bottom: 1px solid transparent;
  background: none;
  color: #fff;
  font:
    900 italic 22px "Archivo",
    "Arial Black",
    sans-serif;
}
.map-name:focus {
  outline: none;
  border-bottom-color: var(--accent);
}
.map-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
}
.map-sub {
  color: #8a90a6;
  font-size: 12px;
}
.map-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  border: 1px solid #2b3347;
  border-radius: 8px;
  background: #151b29;
  color: #c9ccdc;
  font:
    600 12px Inter,
    system-ui,
    sans-serif;
  cursor: pointer;
}
.map-svg {
  display: block;
  width: 100%;
  height: 100%;
  cursor: crosshair;
  outline: none;
  user-select: none;
  touch-action: none;
}
.map-cursor,
.map-help {
  position: absolute;
  z-index: 2;
  padding: 5px 9px;
  border-radius: 6px;
  background: #0b0e15cc;
  color: #c9ccdc;
  font:
    600 11px Inter,
    system-ui,
    sans-serif;
  pointer-events: none;
}
.map-cursor {
  right: 12px;
  bottom: 12px;
}
.map-help {
  left: 50%;
  bottom: 12px;
  transform: translateX(-50%);
}
.map-side {
  display: grid;
  align-content: start;
  gap: 10px;
  padding: 14px;
  overflow: auto;
  background: #10141f;
  border-left: 1px solid var(--line);
  font-size: 13px;
}
.map-side h3 {
  margin: 8px 0 0;
  color: var(--accent);
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.map-layer {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 8px;
  padding: 7px 9px;
  border: 1px solid #232a3a;
  border-radius: 8px;
  background: #141a27;
}
.map-layer small,
.map-calib-row small {
  color: #8a90a6;
}
.map-panel {
  display: grid;
  gap: 8px;
}
.map-panel p {
  margin: 0;
}
.map-row,
.map-seg {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.map-calib-row {
  display: grid;
  gap: 4px;
  padding: 8px 0;
  border-bottom: 1px solid #232a3a;
}
.map-ok {
  color: #6ff0ad;
}
.me-boundary {
  fill: #15171c;
  stroke: #ff5a3c;
  stroke-width: 2;
}
.me-block {
  fill: #bfc3cc;
  fill-opacity: 0.55;
  stroke: #fff;
  stroke-width: 1.4;
  cursor: move;
}
.me-wall {
  fill: none;
  stroke: #fff;
  stroke-width: 2.4;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.me-wall-hit {
  fill: none;
  stroke: transparent;
  stroke-width: 12;
  cursor: move;
}
.me-spawn {
  fill: #ff4747;
  fill-opacity: 0.25;
  cursor: move;
}
.me-spawn.blue {
  fill: #4da3ff;
}
.me-flag {
  cursor: move;
}
.me-flag text {
  font:
    900 italic 20px "Archivo",
    "Arial Black",
    sans-serif;
}
.me-label {
  fill: #e7e9f5;
  font:
    700 13px Inter,
    system-ui,
    sans-serif;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: move;
}
.is-selected.me-block,
.is-selected.me-spawn,
.is-selected.me-boundary,
.me-wall.is-selected {
  stroke: var(--accent);
  stroke-width: 2.5;
}
.me-flag.is-selected circle {
  stroke-dasharray: 6 4;
}
.me-label.is-selected {
  fill: var(--accent);
}
.me-handle {
  fill: var(--accent);
  stroke: #0b0e15;
  cursor: grab;
}
.me-draft {
  fill: #989bfb22;
  stroke: var(--accent);
  stroke-width: 2;
  stroke-dasharray: 6 4;
}
.me-calib circle {
  fill: #ffd24a;
  stroke: #0b0e15;
  stroke-width: 2;
}
.me-calib text {
  fill: #0b0e15;
  font:
    800 11px Inter,
    system-ui,
    sans-serif;
}
.me-scale line {
  stroke: #fff;
  stroke-width: 2;
}
.me-scale text {
  fill: #c9ccdc;
  font:
    600 11px Inter,
    system-ui,
    sans-serif;
}
.dom-map-pick {
  max-width: 420px;
  margin-bottom: 12px;
}
@media (max-width: 1100px) {
  .map-editor {
    grid-template-columns: 64px minmax(0, 1fr);
    height: auto;
  }
  .map-stage {
    height: 70vh;
  }
  .map-side {
    grid-column: 1 / -1;
    border-left: 0;
    border-top: 1px solid var(--line);
  }
}

/* ——— Titres des cartes du dashboard : même style que les titres de la vitrine
   (Archivo italique, capitales, dégradé blanc → violet → blanc) ——— */
body.dashboard .panel-head h2,
body.dashboard .section-title {
  width: fit-content;
  max-width: 100%;
  padding-right: 0.1em;
  font-family: "Archivo", "Arial Black", Arial, sans-serif;
  font-size: 17px;
  font-style: italic;
  font-weight: 900;
  letter-spacing: 0.04em;
  line-height: 1.15;
  text-transform: uppercase;
  overflow-wrap: anywhere;
  color: #f7f7ff;
}
@supports (background-clip: text) or (-webkit-background-clip: text) {
  body.dashboard .panel-head h2,
  body.dashboard .section-title {
    background: linear-gradient(105deg, #fff 4%, var(--accent) 48%, #fff 96%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
  }
}
@media (forced-colors: active) {
  body.dashboard .panel-head h2,
  body.dashboard .section-title {
    background: none;
    color: CanvasText;
  }
}

/* ——— Accueil de l’équipe : statut de service, stats personnelles, en service, classement ——— */
.home-title {
  width: fit-content;
  max-width: 100%;
  padding-right: 0.1em;
  font-family: "Archivo", "Arial Black", Arial, sans-serif;
  font-style: italic;
  font-weight: 900 !important;
  letter-spacing: 0.035em;
  text-transform: uppercase;
  color: #f7f7ff;
}
@supports (background-clip: text) or (-webkit-background-clip: text) {
  .home-title {
    background: linear-gradient(105deg, #fff 4%, var(--accent) 48%, #fff 96%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
  }
}
.home-hero p strong {
  color: #fff;
}
.home-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.home-status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border: 1px solid #ffffff2a;
  border-radius: 999px;
  background: #0d1220b0;
  font-size: 11px;
  color: #c4cadd;
}
.home-status i {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #6c7086;
}
.home-status.is-on {
  border-color: #52d6a066;
  color: #b8f0d6;
}
.home-status.is-on i {
  background: #52d6a0;
  box-shadow: 0 0 10px #52d6a0;
  animation: home-pulse 2s ease-in-out infinite;
}
@keyframes home-pulse {
  50% {
    opacity: 0.45;
  }
}
@media (prefers-reduced-motion: reduce) {
  .home-status.is-on i {
    animation: none;
  }
}
.home-stats .stat {
  color: inherit;
  text-decoration: none;
  transition:
    border-color 0.2s,
    transform 0.2s;
}
.home-stats .stat:hover {
  border-color: #989bfb66;
  transform: translateY(-2px);
}
.stat-of {
  margin-left: 2px;
  font-size: 0.55em;
  color: var(--muted);
}
.duty-now {
  display: grid;
  gap: 4px;
}
.duty-now-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 9px 0;
  border-bottom: 1px solid var(--line);
}
.duty-now-row:last-child {
  border-bottom: 0;
}
.duty-now-row > span:not(.avatar) {
  flex: 1;
  min-width: 0;
}
.duty-now-row strong,
.rank-who strong {
  display: block;
  font-size: 13px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.duty-now-row small,
.rank-who small {
  display: block;
  margin-top: 2px;
  font-size: 11px;
  color: var(--muted);
}
.duty-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #52d6a0;
  box-shadow: 0 0 8px #52d6a088;
}
.duty-dot.busy {
  background: #f5c26b;
  box-shadow: 0 0 8px #f5c26b88;
}
.home-ranking .rank-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
}
.rank-grid > div {
  padding: 20px 22px 22px;
}
.rank-grid > div + div {
  border-left: 1px solid var(--line);
}
.rank-title {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 14px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
}
.rank-list {
  display: grid;
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.rank-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 9px 12px;
  border: 1px solid transparent;
  border-radius: 9px;
}
.rank-row.is-me {
  border-color: #989bfb55;
  background: var(--accent-soft);
}
.rank-pos {
  flex: none;
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: 1px solid var(--line);
  font-size: 12px;
  font-weight: 800;
  color: var(--muted);
}
.rank-pos.pos-1 {
  border-color: #f5c26b;
  color: #f5c26b;
  box-shadow: 0 0 12px #f5c26b44;
}
.rank-pos.pos-2 {
  border-color: #c9cede;
  color: #e3e6f0;
}
.rank-pos.pos-3 {
  border-color: #d39a6a;
  color: #e6b08a;
}
.rank-who {
  flex: 1;
  min-width: 0;
}
.rank-bar {
  display: block;
  height: 4px;
  margin-top: 7px;
  border-radius: 4px;
  background: #ffffff10;
  overflow: hidden;
}
.rank-bar span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #6f72e6, var(--accent));
  transition: width 0.6s ease;
}
.rank-value {
  flex: none;
  font-size: 14px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}
.rank-me,
.rank-empty {
  margin: 12px 0 0;
  font-size: 12px;
  color: var(--muted);
}
@media (max-width: 900px) {
  .home-ranking .rank-grid {
    grid-template-columns: 1fr;
  }
  .rank-grid > div + div {
    border-left: 0;
    border-top: 1px solid var(--line);
  }
}

/* Barre du haut : cloche et déconnexion sans contour, l’icône seule. */
body.dashboard .topbar-actions .icon-btn {
  border-color: transparent;
  background: transparent;
  box-shadow: none;
}
body.dashboard .topbar-actions .icon-btn:hover,
body.dashboard .topbar-actions .icon-btn:focus-visible {
  background: #ffffff0d;
}

/* ——— Banque : compte Maze en tête, graphique par jour, principaux motifs ——— */
.bank-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.3fr);
  gap: 24px;
  align-items: center;
  margin-bottom: 15px;
  padding: 26px 28px;
  border: 1px solid #3a4661;
  border-radius: 10px;
  background: radial-gradient(120% 140% at 0% 0%, #989bfb22, transparent 60%),
    var(--panel);
}
.bank-hero-main {
  display: grid;
  gap: 8px;
  justify-items: start;
}
.bank-balance {
  font-family: "Archivo", "Arial Black", Arial, sans-serif;
  font-size: clamp(32px, 3.6vw, 46px);
  font-style: italic;
  font-weight: 900;
  letter-spacing: 0.02em;
  line-height: 1.05;
  padding-right: 0.1em;
  color: #f7f7ff;
}
@supports (background-clip: text) or (-webkit-background-clip: text) {
  .bank-balance {
    background: linear-gradient(105deg, #fff 4%, var(--accent) 60%, #fff 110%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
  }
}
.bank-hero-main .text-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 4px;
}
.bank-hero-figures {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px;
  border: 1px solid var(--line);
  border-radius: 9px;
  overflow: hidden;
  background: var(--line);
}
.bank-hero-figures > div {
  display: grid;
  gap: 8px;
  padding: 16px;
  background: #151620;
  font-size: 18px;
  font-weight: 700;
}
.bank-hero-figures span:first-child {
  font-size: 11px;
  font-weight: 500;
  color: var(--muted);
}
.bank-stats {
  grid-template-columns: repeat(3, 1fr);
}
.bank-stats .stat {
  text-align: left;
  font: inherit;
  color: inherit;
  cursor: pointer;
  transition:
    border-color 0.2s,
    transform 0.2s;
}
.bank-stats .stat:hover {
  border-color: #989bfb66;
  transform: translateY(-2px);
}
.bank-legend {
  display: flex;
  gap: 16px;
  font-size: 12px;
  color: var(--muted);
}
.bank-legend span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}
.bank-legend i {
  width: 10px;
  height: 10px;
  border-radius: 3px;
}
.bank-legend i.in,
.bank-up i,
.reason-bar.in span {
  background: #52d6a0;
}
.bank-legend i.out,
.bank-down i,
.reason-bar.out span {
  background: #f48b9a;
}
.bank-chart {
  position: relative;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 4px 12px;
}
.bank-axis {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 220px;
  font-size: 10px;
  color: var(--muted);
  text-align: right;
}
.bank-cols {
  display: flex;
  gap: 2px;
  height: 220px;
  border-top: 1px dashed #ffffff12;
  border-bottom: 1px dashed #ffffff12;
}
.bank-col {
  position: relative;
  flex: 1;
  min-width: 0;
  display: grid;
  grid-template-rows: 1fr 1fr;
  outline: none;
  border-radius: 4px;
}
.bank-col:hover,
.bank-col:focus-visible {
  background: #ffffff0a;
}
.bank-up,
.bank-down {
  display: flex;
  padding: 0 18%;
}
.bank-up {
  align-items: flex-end;
  border-bottom: 1px solid #ffffff30;
}
.bank-down {
  align-items: flex-start;
}
.bank-up i,
.bank-down i {
  display: block;
  width: 100%;
  min-height: 0;
}
.bank-up i {
  border-radius: 4px 4px 0 0;
}
.bank-down i {
  border-radius: 0 0 4px 4px;
}
.bank-dates {
  grid-column: 2;
  display: flex;
  justify-content: space-between;
  font-size: 10px;
  color: var(--muted);
}
.bank-tip {
  position: absolute;
  top: -6px;
  transform: translate(-50%, -100%);
  margin-left: calc(var(--axis, 0px));
  padding: 7px 10px;
  border: 1px solid #3a4661;
  border-radius: 7px;
  background: #11131c;
  font-size: 11px;
  white-space: nowrap;
  pointer-events: none;
  box-shadow: 0 10px 30px #0008;
}
.bank-reasons {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 23px;
}
.reason-list {
  display: grid;
  gap: 14px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.reason-list li {
  display: flex;
  align-items: center;
  gap: 14px;
}
.reason-name {
  flex: 1;
  min-width: 0;
}
.reason-name strong {
  display: block;
  font-size: 13px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.reason-name small {
  font-size: 11px;
  color: var(--muted);
}
.reason-bar {
  display: block;
  height: 4px;
  margin-top: 7px;
  border-radius: 4px;
  background: #ffffff10;
  overflow: hidden;
}
.reason-bar span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
}
@media (max-width: 1000px) {
  .bank-hero,
  .bank-reasons {
    grid-template-columns: 1fr;
  }
  .bank-hero-figures {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .bank-stats {
    grid-template-columns: 1fr;
  }
}

/* Menu déroulant avec recherche (searchableSelect) : même champ que les menus, liste
   filtrée en dessous. */
.combo {
  position: relative;
}
:root body input.combo-input {
  --field-line: var(--ctl-line);
  border: 0;
  border-bottom: 1px solid var(--ctl-border);
  border-radius: 0;
  padding-right: 34px;
  background:
    linear-gradient(var(--field-line), var(--field-line)) left bottom / 0 2px
      no-repeat,
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8' fill='none' stroke='%23989bfb' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 1.5l5 5 5-5'/%3E%3C/svg%3E")
      right 12px center / 11px 8px no-repeat,
    transparent;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  color: var(--text);
  transition:
    background-size 0.3s cubic-bezier(0.6, -0.28, 0.735, 0.045),
    border-color 0.15s;
}
:root body input.combo-input:focus {
  outline: none;
  background-size:
    100% 2px,
    11px 8px;
  border-bottom-color: transparent;
}
.combo-list {
  position: absolute;
  z-index: 20;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  max-height: 240px;
  overflow-y: auto;
  margin: 0;
  padding: 4px;
  list-style: none;
  border: 1px solid #3a4256;
  border-radius: 10px;
  background: #101520;
  box-shadow: 0 16px 40px #000a;
}
.combo-list li {
  padding: 9px 12px;
  border-radius: 7px;
  font-size: 12px;
  cursor: pointer;
}
.combo-list li.is-active,
.combo-list li:hover {
  background: #989bfb22;
}
.combo-list li.is-chosen {
  color: var(--accent);
  font-weight: 700;
}
.combo-list .combo-empty {
  color: var(--muted);
  cursor: default;
}
/* Options avec pastille de couleur (rôles Discord) et précision discrète (catégorie). */
.combo-list li[role="option"] {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}
.combo-label {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.combo-hint {
  flex: none;
  max-width: 45%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--muted);
  font-size: 10px;
  font-weight: 400;
  opacity: 0.75;
}
.combo-dot {
  flex: none;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--dot, var(--muted));
}
/* Menu à un choix : pastille du rôle choisi devant le texte du champ. */
.combo.has-dot::before {
  content: "";
  position: absolute;
  z-index: 1;
  left: 12px;
  top: 50%;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--dot, var(--muted));
  transform: translateY(-50%);
  pointer-events: none;
}
:root body .combo.has-dot input.combo-input {
  padding-left: 30px;
}
/* Choix multiple (multiSelect) : étiquettes retirables au-dessus du champ de recherche. */
.chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 6px 0 8px;
}
.chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 4px 4px 10px;
  border: 1px solid color-mix(in srgb, var(--accent) 45%, transparent);
  border-radius: 100px;
  background: color-mix(in srgb, var(--accent) 12%, transparent);
  color: var(--text);
  font-size: 12px;
  line-height: 1.2;
}
/* Étiquette d’un rôle Discord : capsule teintée de la couleur du rôle, avec sa pastille. */
.chip.dot-chip {
  gap: 6px;
  padding-left: 8px;
  border-color: color-mix(in srgb, var(--dot, var(--muted)) 55%, transparent);
  background: color-mix(in srgb, var(--dot, var(--muted)) 16%, transparent);
}
.chip button {
  display: inline-grid;
  place-items: center;
  width: 20px;
  height: 20px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
}
.chip button:hover,
.chip button:focus-visible {
  background: color-mix(in srgb, var(--accent) 25%, transparent);
  color: var(--text);
}

/* ——— Pôles : onglet par pôle, en-tête (groupe RP, ouverture), semaine du pôle ——— */
.pole-switch {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}
.pole-tab {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 9px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--panel);
  color: var(--muted);
  font: inherit;
  font-size: 13px;
  font-weight: 600;
}
.pole-tab small {
  padding: 1px 7px;
  border-radius: 999px;
  background: #ffffff10;
  font-size: 11px;
}
.pole-tab.is-active {
  border-color: #989bfb88;
  background: var(--accent-soft);
  color: var(--text);
}
.pole-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #6c7086;
}
.pole-dot.on {
  background: var(--green);
  box-shadow: 0 0 8px var(--green);
}
.pole-hero {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 15px;
  padding: 22px 24px;
  border: 1px solid #3a4661;
  border-radius: 10px;
  background: radial-gradient(120% 140% at 0% 0%, #989bfb1f, transparent 60%),
    var(--panel);
}
.pole-hero .eyebrow {
  display: block;
  margin-bottom: 6px;
}
.pole-name {
  width: fit-content;
  margin: 0 0 8px;
  padding-right: 0.1em;
  font-family: "Archivo", "Arial Black", Arial, sans-serif;
  font-size: clamp(24px, 2.6vw, 32px);
  font-style: italic;
  font-weight: 900;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: #f7f7ff;
}
@supports (background-clip: text) or (-webkit-background-clip: text) {
  .pole-name {
    background: linear-gradient(105deg, #fff 4%, var(--accent) 48%, #fff 96%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
  }
}
.pole-hero .pill-row {
  margin-top: 10px;
}
.pole-open {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 12px;
  color: var(--muted);
  white-space: nowrap;
}
.pole-open i {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #6c7086;
}
.pole-open.on {
  color: #b8f0d6;
}
.pole-open.on i {
  background: var(--green);
  box-shadow: 0 0 8px var(--green);
}
/* Factures puis services, en pleine largeur : le motif des factures doit se lire. */
.pole-columns {
  display: grid;
  grid-template-columns: 1fr;
  gap: 23px;
}
.pole-columns > .panel {
  min-width: 0;
}
.panel > .pole-add {
  padding: 16px 22px;
  border-top: 1px solid var(--line);
}
.pole-add .combo {
  flex: 1;
}

/* ——— Ma semaine et récap : notes de frais, absences, commentaires ——— */
.myweek-grid,
.recap-claims {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  gap: 23px;
  align-items: start;
}
.recap-claims-side {
  display: grid;
  gap: 23px;
}
.claim-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 12px;
}
.claim-card {
  display: grid;
  gap: 12px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #151620;
}
.claim-card.pending {
  border-color: #e2bf7755;
}
.claim-top {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}
.claim-top strong {
  display: block;
  font-size: 13px;
}
.claim-top small {
  font-size: 11px;
  color: var(--muted);
}
.claim-amount {
  flex: none;
  font-size: 16px;
  font-weight: 800;
  color: var(--accent);
}
.claim-proofs,
.proof-thumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.claim-proof {
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: none;
  cursor: zoom-in;
}
.claim-proof img,
.proof-thumb img {
  display: block;
  width: 64px;
  height: 64px;
  object-fit: cover;
}
.claim-ref {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 8px;
  margin: 8px 0 0;
  font-size: 13px;
}
.claim-ref small {
  flex-basis: 100%;
  font-size: 12px;
}
.claim-ref-code {
  padding: 2px 10px;
  border: 1px dashed #989bfb;
  border-radius: 6px;
  background: #989bfb1a;
  color: #c9cbff;
  font:
    700 13px ui-monospace,
    Consolas,
    monospace;
  letter-spacing: 0.04em;
  cursor: copy;
}
.claim-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.claim-actions {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-left: auto;
}
.proof-full {
  display: block;
  max-width: 100%;
  max-height: 70vh;
  margin: 0 auto;
  border-radius: 8px;
}
.proof-label {
  display: block;
  margin-bottom: 8px;
  font-size: 11px;
  color: #c0c0d1;
}
.proof-drop {
  display: grid;
  justify-items: center;
  gap: 4px;
  padding: 20px;
  border: 1px dashed #989bfb66;
  border-radius: 12px;
  background: #989bfb0d;
  text-align: center;
  cursor: pointer;
  transition:
    border-color 0.2s,
    background 0.2s;
}
.proof-drop svg {
  color: var(--accent);
}
.proof-drop small {
  color: var(--muted);
  font-size: 11px;
}
.proof-drop:hover,
.proof-drop:focus-visible,
.proof-drop.is-over {
  border-color: var(--accent);
  background: #989bfb1f;
  outline: none;
}
.proof-thumbs {
  margin-top: 10px;
}
.proof-thumb {
  position: relative;
  display: grid;
  place-items: center;
  width: 64px;
  height: 64px;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  font-size: 10px;
}
.proof-thumb .icon-btn {
  position: absolute;
  top: 2px;
  right: 2px;
  width: 22px;
  height: 22px;
  min-height: 0;
  padding: 0;
  background: #000a;
}
.absence-list,
.comment-list {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.absence-list li {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  font-size: 13px;
}
.absence-when {
  display: inline-flex;
  flex: none;
  align-items: center;
  gap: 6px;
  font-weight: 700;
  color: var(--accent);
}
.absence-what {
  flex: 1;
  min-width: 0;
}
.comment-list li {
  padding: 12px 14px;
  border-left: 2px solid var(--accent);
  border-radius: 0 10px 10px 0;
  background: #ffffff06;
}
.comment-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
}
.comment-list p {
  margin: 0;
  font-size: 13px;
  line-height: 1.6;
  white-space: pre-wrap;
}
.comment-form {
  display: grid;
  gap: 10px;
  justify-items: end;
  margin-top: 14px;
}
.danger-text {
  color: var(--red);
}
.claim-empty {
  margin: 0;
}

/* ——— Récap semaine : statut de paye et récap IA ——— */
.pay-cell {
  display: grid;
  justify-items: start;
  gap: 6px;
}
.pay-cell small {
  margin: 0;
  max-width: 190px;
  white-space: normal;
}
.ai-running {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 14px;
  color: var(--yellow);
}
.ai-team {
  margin: 0 0 16px;
  line-height: 1.6;
}
.ai-list {
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  margin-bottom: 12px;
}
.ai-card {
  align-content: start;
}
.ai-summary,
.ai-pay p {
  margin: 0;
  font-size: 13px;
  line-height: 1.55;
}
.ai-points h3 {
  margin: 0 0 4px;
  font-size: 12px;
  color: var(--muted);
}
.ai-points ul {
  margin: 0;
  padding-left: 18px;
  font-size: 13px;
  line-height: 1.5;
}
.ai-pay {
  display: grid;
  gap: 4px;
  padding-top: 10px;
  border-top: 1px solid var(--line);
}
@media (max-width: 1000px) {
  .myweek-grid,
  .recap-claims {
    grid-template-columns: 1fr;
  }
}

/* Coffres : nom à renommer d’un clic, rattachement dans la colonne, journal en fenêtre. */
.storage-name {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 4px 6px;
  margin: -4px -6px;
  border: 1px solid transparent;
  border-radius: 6px;
  background: none;
  color: var(--text);
  font: inherit;
  font-weight: 700;
  text-align: left;
  cursor: text;
}
.storage-name svg {
  flex: none;
  color: var(--muted);
  opacity: 0;
  transition: opacity 0.15s;
}
.storage-name:hover,
.storage-name:focus-visible {
  border-color: var(--line);
  background: #ffffff08;
}
.storage-name:hover svg,
.storage-name:focus-visible svg {
  opacity: 1;
}
:root body input.storage-name-input {
  min-width: 220px;
  padding: 6px 8px;
  font-weight: 700;
}
:root body select.storage-owner {
  min-width: 170px;
  padding-top: 8px;
  padding-bottom: 8px;
  font-size: 12px;
}
.modal.storage-modal {
  width: min(1200px, calc(100vw - 28px));
}
.stock-actions {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 12px;
}

/* ——— Dev · Webhooks : filtres et payload JSON ——— */
.dev-filters select {
  max-width: 320px;
}
.payload-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}
.payload-head span {
  display: grid;
  gap: 4px;
}
.payload-json {
  max-height: min(65vh, 720px);
  margin: 0;
  padding: 16px;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #0b0e15;
  color: #d7dbf0;
  font:
    12px/1.55 ui-monospace,
    SFMono-Regular,
    Menlo,
    Consolas,
    monospace;
  white-space: pre;
}
#copy-payload.is-copied {
  border-color: var(--green);
  color: var(--green);
}

/* ——— Dev · Pistes : position en direct et carte des pistes ——— */
.runway-top {
  display: grid;
  grid-template-columns: minmax(260px, 340px) 1fr;
  gap: 18px;
  align-items: stretch;
}
.runway-live {
  display: grid;
  align-content: start;
  gap: 6px;
  padding: 20px;
}
.runway-live strong {
  font-size: 18px;
  font-variant-numeric: tabular-nums;
}
.runway-steps {
  margin: 10px 0 0;
  padding-left: 18px;
  font-size: 13px;
  line-height: 1.6;
  color: var(--muted, #a9adc4);
}
.runway-map {
  min-height: 420px;
}
.runway-end {
  display: grid;
  grid-template-columns: repeat(3, 1fr) auto;
  gap: 10px;
  align-items: end;
}
.runway-width {
  grid-template-columns: 1fr auto auto;
}
.runway-width .is-done {
  border-color: #76d9ae;
  color: #76d9ae;
}
.runway-more {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 10px;
}
.runway-preview strong {
  color: #c3c5ff;
}
@media (max-width: 900px) {
  .runway-top,
  .runway-end {
    grid-template-columns: 1fr;
  }
}

/* ——— Dev · Bureau : cartes, markers, étapes ——— */
.bz-dev-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: end;
  margin-bottom: 16px;
}
.bz-dev-bar .field {
  min-width: 220px;
}
.bz-marker-row,
.bz-step-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr) auto;
  gap: 10px;
  align-items: end;
  margin-bottom: 8px;
}
.bz-step-row {
  grid-template-columns: 2fr 1.4fr 1.4fr 1fr auto;
}
.bz-dev-fivem {
  padding: 18px;
  margin-bottom: 16px;
}
.bz-dev-fivem code,
.data-table code {
  color: #c3c5ff;
}
@media (max-width: 900px) {
  .bz-marker-row,
  .bz-step-row {
    grid-template-columns: 1fr;
  }
}

/* ——— Boîte mail ——— */
.mail-files {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}
.mail-files img {
  width: 96px;
  height: 72px;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid var(--line, #2a2f40);
}
.mail-attach {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}
.mail-attach .mail-files {
  flex-basis: 100%;
}
.application-mails {
  list-style: none;
  margin: 0 0 8px;
  padding: 0;
  display: grid;
  gap: 8px;
}
.application-mails li {
  display: grid;
  padding: 10px 12px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.03);
  border-left: 3px solid #989bfb;
}
.application-mails li.in {
  border-left-color: #5fd39a;
}
.application-mails span,
.application-mails small {
  color: var(--muted, #9aa0b5);
  font-size: 12.5px;
}
.decision-mail {
  border: 1px solid var(--line, #2a2f40);
  border-radius: 12px;
  padding: 6px 14px 14px;
  margin: 0;
}
.decision-mail legend {
  padding: 0 6px;
}
.decision-mail legend .check-field {
  min-height: 0;
}
/* Boîte mail : barre (dossiers + recherche alignés), conversations et lecture à côté. */
.mbx-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
  border-bottom: 1px solid var(--line, #2a2f40);
}
.mbx-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 2px;
}
.mbx-tab {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: -1px;
  padding: 11px 14px;
  border: 0;
  border-bottom: 2px solid transparent;
  background: none;
  color: var(--muted, #9aa0b5);
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}
.mbx-tab:hover {
  color: var(--text, #fff);
}
.mbx-tab[aria-selected="true"] {
  border-bottom-color: #989bfb;
  color: var(--text, #fff);
}
.mbx-count {
  min-width: 20px;
  padding: 1px 6px;
  border-radius: 999px;
  background: #ffffff1a;
  font-size: 11.5px;
  text-align: center;
}
.mbx-count.unread {
  background: #989bfb;
  color: #12131d;
}
.mbx-count.failed {
  background: #ff8a8a33;
  color: #ffb0b0;
}
.mbx-search {
  position: relative;
  display: flex;
  align-items: center;
  width: min(340px, 100%);
  margin-bottom: 6px;
  color: var(--muted, #9aa0b5);
}
.mbx-search svg {
  position: absolute;
  left: 2px;
  pointer-events: none;
}
.mbx-search input {
  flex: 1;
  min-width: 0;
  padding: 9px 8px 9px 26px;
  font: inherit;
}
.mbx-bar > .btn {
  margin-bottom: 8px;
}
.mbx {
  display: grid;
  grid-template-columns: minmax(300px, 400px) minmax(0, 1fr);
  gap: 16px;
  height: max(560px, calc(100vh - 330px));
}
.mbx-side,
.mbx-read {
  min-height: 0;
  border: 1px solid var(--line, #2a2f40);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.02);
}
.mbx-side {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.mbx-list {
  flex: 1;
  overflow-y: auto;
}
.mbx-side .pagination {
  margin: 0;
  padding: 8px 10px;
  border-top: 1px solid var(--line, #2a2f40);
}
.mbx-item {
  appearance: none;
  display: flex;
  gap: 12px;
  width: 100%;
  padding: 12px 14px;
  border: 0;
  border-bottom: 1px solid var(--line, #2a2f40);
  border-left: 3px solid transparent;
  background: none;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.mbx-item:hover {
  background: rgba(255, 255, 255, 0.03);
}
.mbx-item.on {
  border-left-color: #989bfb;
  background: rgba(152, 155, 251, 0.1);
}
.mbx-avatar {
  display: grid;
  flex: none;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: #2a2d42;
  color: #c9cbff;
  font-size: 13px;
  font-weight: 800;
}
.mbx-avatar.app {
  background: #989bfb33;
}
.mbx-main {
  display: grid;
  flex: 1;
  gap: 2px;
  min-width: 0;
}
.mbx-line {
  display: flex;
  justify-content: space-between;
  gap: 8px;
}
.mbx-line strong,
.mbx-subject,
.mbx-preview {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.mbx-line strong {
  font-weight: 600;
}
.mbx-line time {
  flex: none;
  color: var(--muted, #9aa0b5);
  font-size: 12px;
}
.mbx-subject {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13.5px;
}
.mbx-item.unread .mbx-line strong,
.mbx-item.unread .mbx-subject {
  color: #fff;
  font-weight: 800;
}
.mbx-dot {
  flex: none;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #989bfb;
}
.mbx-n {
  flex: none;
  padding: 0 6px;
  border-radius: 6px;
  background: #ffffff14;
  color: var(--muted, #9aa0b5);
  font-size: 11px;
  font-weight: 700;
}
.mbx-preview {
  color: var(--muted, #9aa0b5);
  font-size: 12.5px;
}
.mbx-tags {
  display: flex;
  gap: 6px;
}
.mbx-tags:empty {
  display: none;
}
.mbx-tag {
  padding: 1px 8px;
  border: 1px solid #ffffff26;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
}
.mbx-tag.app {
  border-color: #989bfb66;
  color: #c9cbff;
}
.mbx-tag.fail {
  border-color: #ff8a8a66;
  color: #ffb0b0;
}
.mbx-read {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.mbx-empty {
  display: grid;
  flex: 1;
  place-items: center;
  align-content: center;
  gap: 10px;
  color: var(--muted, #9aa0b5);
  text-align: center;
}
.mbx-head {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--line, #2a2f40);
}
.mbx-head h2 {
  margin: 0;
  font-size: 18px;
}
.mbx-head p {
  margin: 2px 0 0;
  color: var(--muted, #9aa0b5);
  font-size: 13px;
}
.mbx .mbx-back {
  display: none;
}
.mbx-msgs {
  display: grid;
  flex: 1;
  align-content: start;
  gap: 12px;
  overflow-y: auto;
  padding: 18px;
}
.mbx-msg {
  max-width: 82%;
  padding: 12px 14px;
  border-radius: 14px;
  background: #1f2236;
}
.mbx-msg.in {
  justify-self: start;
  border-bottom-left-radius: 4px;
}
.mbx-msg.out {
  justify-self: end;
  border-bottom-right-radius: 4px;
  background: #989bfb26;
}
.mbx-msg.failed {
  border: 1px solid #ff8a8a66;
}
.mbx-msg header {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 6px;
  font-size: 12.5px;
}
.mbx-msg header time,
.mbx-msg footer {
  color: var(--muted, #9aa0b5);
  font-size: 12px;
}
.mbx-msg h4 {
  margin: 0 0 4px;
}
.mbx-msg p {
  margin: 0;
  line-height: 1.55;
}
.mbx-msg footer {
  margin-top: 8px;
}
.mbx-reply {
  display: grid;
  gap: 8px;
  padding: 12px 18px 16px;
  border-top: 1px solid var(--line, #2a2f40);
}
.mbx-reply-head,
.mbx-reply-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.mbx-reply-head select {
  max-width: 260px;
}
.mbx-reply textarea {
  width: 100%;
  resize: vertical;
}
.mbx-reply .form-error:empty {
  display: none;
}
.mbx-templates > p {
  margin: 0 0 14px;
}
.mbx-tpl-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 14px;
}
.mbx-tpl {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 16px 18px;
  border: 1px solid var(--line, #2a2f40);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.02);
}
.mbx-tpl.auto {
  border-left: 3px solid #989bfb;
}
.mbx-tpl header,
.mbx-tpl footer {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.mbx-tpl-subject {
  margin: 0;
  font-weight: 700;
}
.mbx-tpl-text {
  flex: 1;
  display: -webkit-box;
  margin: 0;
  overflow: hidden;
  color: var(--muted, #9aa0b5);
  font-size: 13px;
  line-height: 1.5;
  -webkit-line-clamp: 6;
  -webkit-box-orient: vertical;
}
@media (max-width: 900px) {
  .mbx {
    grid-template-columns: minmax(0, 1fr);
    height: max(520px, calc(100vh - 260px));
  }
  .mbx.reading .mbx-side,
  .mbx:not(.reading) .mbx-read {
    display: none;
  }
  .mbx .mbx-back {
    display: inline-grid;
  }
  .mbx-tabs {
    flex-wrap: nowrap;
    overflow-x: auto;
    scrollbar-width: none;
  }
  .mbx-tab {
    flex: none;
  }
  .mbx-search {
    width: 100%;
  }
  .mbx-msg {
    max-width: 94%;
  }
}
/* Pages Notes de frais et Payes. */
.money-tip {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}
.money-tip svg {
  flex: none;
  margin-top: 2px;
}
.money-bar {
  align-items: flex-end;
}
.money-bar .inline-select {
  margin-bottom: 8px;
}
.money-proofs {
  display: flex;
  gap: 4px;
}
.money-proofs .claim-proof,
.money-proofs .claim-proof img {
  width: 40px;
  height: 40px;
}
.payslip-full {
  display: block;
  width: 100%;
  max-width: 520px;
  margin: 0 auto 12px;
  border-radius: 8px;
}
.money-status {
  min-width: 150px;
  max-width: 230px;
  white-space: normal;
}
.money-status small {
  display: block;
  white-space: normal;
  margin-top: 4px;
  font-size: 12px;
}
.money-actions {
  width: 1%;
}
.money-actions .btn {
  display: flex;
  justify-content: center;
  width: 100%;
  min-width: 96px;
  white-space: nowrap;
}
.money-actions .btn + .btn {
  margin-top: 6px;
}
.money-iban {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 4px;
  color: var(--muted, #9aa0b5);
  font-size: 12px;
}
.money-iban .claim-ref-code {
  padding: 1px 8px;
  font-size: 12px;
}
/* Devis envoyé par mail : aperçu de l’image jointe. */
.quote-mail-attach {
  display: grid;
  gap: 6px;
}
.quote-mail-thumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.quote-mail-thumb img {
  display: block;
  width: 180px;
  border: 1px solid var(--line, #2a2f40);
  border-radius: 6px;
}
/* Suggestions sous un champ (adresses mail, aérodromes…) : remplace le menu natif. */
.ac-host {
  position: relative;
}
.ac-list {
  position: absolute;
  z-index: 30;
  top: 100%;
  left: 0;
  right: 0;
  max-height: 264px;
  margin: 4px 0 0;
  padding: 4px;
  overflow-y: auto;
  list-style: none;
  background: #151a26;
  border: 1px solid #3a4256;
  border-radius: 8px;
  box-shadow: 0 14px 32px rgba(0, 0, 0, 0.45);
  scrollbar-width: thin;
}
.ac-list[hidden] {
  display: none;
}
.ac-item {
  display: flex;
  align-items: baseline;
  gap: 10px;
  min-height: 38px;
  padding: 9px 12px;
  border-left: 2px solid transparent;
  border-radius: 4px;
  color: var(--text, #f4f4f8);
  font-size: 14px;
  cursor: pointer;
}
.ac-item strong {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-weight: 600;
}
.ac-item small {
  margin-left: auto;
  flex: none;
  color: var(--muted, #999aaf);
  font-size: 12px;
}
.ac-item:hover,
.ac-item[aria-selected="true"] {
  background: #989bfb1f;
  border-left-color: var(--accent, #989bfb);
}
/* « Voir en tant que » (devs) : bouton de la barre du haut et bandeau d’aperçu. */
.preview-btn {
  white-space: nowrap;
}
.preview-banner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 14px;
  margin: 0 0 4px;
  padding: 10px 18px;
  border-bottom: 1px solid #989bfb55;
  background: linear-gradient(90deg, #989bfb26, #989bfb0d);
  color: var(--text, #f4f4f8);
  font-size: 13px;
}
.preview-banner > svg {
  flex: none;
  color: var(--accent, #989bfb);
}
.preview-banner > span {
  flex: 1;
  min-width: 220px;
}
.preview-presets {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.preview-poles {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  border: 0;
}
.preview-poles legend {
  margin-bottom: 8px;
  color: #c0c0d1;
  font-size: 12px;
}
.preview-pole {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 160px;
  align-items: center;
  gap: 12px;
}
@media (max-width: 640px) {
  .preview-btn span {
    display: none;
  }
}
/* ——— Licences pilotes : espace pilote et dossiers du pôle aviation ——— */
.lic-body {
  display: grid;
  gap: 18px;
  padding: 0 21px 21px;
}
.lic-steps {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 4px;
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: step;
}
.lic-steps li {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px 6px 6px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  font-size: 13px;
}
.lic-steps i,
.lic-checklist li > i {
  display: grid;
  place-items: center;
  flex: none;
  width: 22px;
  height: 22px;
  border: 1px solid var(--line);
  border-radius: 50%;
}
.lic-steps li.done {
  border-color: color-mix(in srgb, var(--green) 45%, var(--line));
  color: var(--text);
}
.lic-steps li.done i,
.lic-checklist li.done > i {
  border-color: var(--green);
  background: color-mix(in srgb, var(--green) 20%, transparent);
  color: var(--green);
}
.lic-kinds {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 240px), 1fr));
  gap: 12px;
  padding: 0 21px 21px;
}
.lic-kind {
  display: grid;
  gap: 6px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: color-mix(in srgb, var(--accent) 5%, transparent);
  color: var(--text);
  font: inherit;
  text-align: left;
  cursor: pointer;
  transition: border-color 0.15s;
}
.lic-kind strong {
  font-size: 18px;
}
.lic-kind small {
  color: var(--muted);
}
.lic-kind span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 6px;
  color: var(--accent);
  font-weight: 700;
}
.lic-kind:hover,
.lic-kind:focus-visible {
  border-color: var(--accent);
}
.lic-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 220px), 1fr));
  gap: 12px;
  padding: 0 21px 21px;
}
.lic-card {
  display: grid;
  gap: 6px;
  justify-items: start;
  padding: 18px;
  border: 1px solid color-mix(in srgb, var(--accent) 45%, var(--line));
  border-radius: 12px;
  background: linear-gradient(
    135deg,
    color-mix(in srgb, var(--accent) 16%, transparent),
    transparent 70%
  );
}
.lic-card.suspended,
.lic-card.revoked {
  border-color: var(--line);
  opacity: 0.75;
}
.lic-card-kind {
  color: var(--accent);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.lic-card strong {
  font-size: 22px;
  font-variant-numeric: tabular-nums;
}
.lic-card small {
  color: var(--muted);
}
.lic-dots {
  display: inline-flex;
  gap: 5px;
}
.lic-dots i {
  width: 10px;
  height: 10px;
  border: 1px solid var(--line);
  border-radius: 50%;
}
.lic-dots i.on {
  border-color: var(--green);
  background: var(--green);
}
.lic-file {
  display: grid;
  gap: 22px;
}
.lic-file h3 {
  margin: 0 0 10px;
  font-size: 15px;
}
.lic-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  align-items: center;
  color: var(--muted);
  font-size: 13px;
}
.lic-meta span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.lic-message {
  margin: 0;
  padding: 10px 14px;
  border-left: 3px solid var(--accent);
  border-radius: 6px;
  background: color-mix(in srgb, var(--accent) 8%, transparent);
  font-style: italic;
}
.lic-checklist {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.lic-checklist li {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
}
.lic-checklist small {
  display: block;
  color: var(--muted);
  font-size: 12px;
}
.lic-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 12px;
}
.lic-thread {
  display: grid;
  gap: 10px;
  max-height: 360px;
  overflow-y: auto;
  margin-bottom: 12px;
  scrollbar-width: thin;
}
.lic-mail {
  max-width: 88%;
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
}
.lic-mail.out {
  justify-self: end;
  border-color: color-mix(in srgb, var(--accent) 40%, var(--line));
  background: color-mix(in srgb, var(--accent) 8%, transparent);
}
.lic-mail header {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 6px;
  font-size: 13px;
}
.lic-mail header small {
  color: var(--muted);
}
.lic-mail p {
  margin: 0;
  font-size: 14px;
  line-height: 1.55;
  overflow-wrap: anywhere;
}
.lic-rights {
  display: grid;
  gap: 6px;
  margin: 10px 0 0;
  padding: 0;
  list-style: none;
  font-size: 13px;
}
.lic-rights li {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 12px;
}
.lic-rights small {
  color: var(--muted);
}
.lic-quiz-head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}
.lic-quiz-head .ct-tabs {
  margin: 0;
}
.lic-questions {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0 21px 21px;
  list-style: none;
}
.lic-questions > li {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 10px;
}
.lic-questions > li.off {
  opacity: 0.55;
}
.lic-questions ul {
  display: grid;
  gap: 3px;
  margin: 8px 0;
  padding: 0;
  list-style: none;
  color: var(--muted);
  font-size: 13px;
}
.lic-questions ul li {
  display: flex;
  align-items: center;
  gap: 6px;
}
.lic-questions ul li.good {
  color: var(--green);
  font-weight: 600;
}
.lic-q-side {
  display: flex;
  flex-wrap: wrap;
  align-content: start;
  justify-content: end;
  gap: 6px;
}
.lic-choices {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  border: 0;
}
.lic-choices legend {
  margin-bottom: 6px;
  color: #c0c0d1;
  font-size: 12px;
}
.lic-choice {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
}
.lic-choice .check-field {
  min-height: 0;
}
.lic-pick {
  display: grid;
  gap: 6px;
}
.lic-pick-row {
  display: flex;
  justify-content: space-between;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: transparent;
  color: var(--text);
  font: inherit;
  cursor: pointer;
}
.lic-pick-row:hover {
  border-color: var(--accent);
}
.lic-pick-row small {
  color: var(--muted);
}
@media (max-width: 600px) {
  .lic-checklist li,
  .lic-questions > li {
    grid-template-columns: auto minmax(0, 1fr);
  }
  .lic-checklist li > :last-child:not(div),
  .lic-q-side {
    grid-column: 1 / -1;
    justify-content: start;
  }
  .lic-mail {
    max-width: 100%;
  }
}
.lic-quiz-settings {
  padding: 0 21px 21px;
}
.lic-log {
  display: grid;
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 13px;
}
.lic-log li {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 12px;
}
.lic-log time {
  color: var(--accent);
  white-space: nowrap;
}
.lic-log em {
  color: var(--muted);
  font-style: normal;
}
@media (max-width: 600px) {
  .lic-log li {
    grid-template-columns: minmax(0, 1fr);
    gap: 0;
  }
}

/* ——— Sélecteur de semaine (pôles, Ma semaine, récap) ——— */
.week-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 18px;
  margin: 0 0 22px;
}
.week-action {
  margin-left: auto;
}
.week-pick {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--panel);
}
.week-step {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
}
.week-step:hover,
.week-step:focus-visible {
  background: color-mix(in srgb, var(--accent) 16%, transparent);
  color: var(--accent);
}
.week-now {
  display: grid;
  gap: 1px;
  min-width: 190px;
  padding: 0 10px;
  text-align: center;
}
.week-now span {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
}
.week-now strong {
  font-size: 15px;
  white-space: nowrap;
}
@media (max-width: 600px) {
  .week-pick {
    width: 100%;
    justify-content: space-between;
  }
  .week-now {
    min-width: 0;
  }
}

/* Fiche d’un membre (gérant de pôle) : rôle dans le pôle et actions. */
.member-facts {
  margin: 4px 0 22px;
}
.member-pole {
  margin: 8px 0 24px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 12px;
}
.member-pole span {
  font-weight: 600;
}
.member-pole-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
/* Stats d’une fiche : autant de cartes par ligne que la fenêtre en tient. */
.employee-file .stats {
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
}
.employee-file td.cell-wrap {
  white-space: normal;
  min-width: 140px;
}

/* Échelons ULM : Microlight → Airglider, barre des heures de vol. */
.lic-ladder {
  display: grid;
  gap: 10px;
}
.lic-ladder-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 14px;
}
.lic-bar {
  width: 100%;
  height: 10px;
  border: 0;
  border-radius: 999px;
  overflow: hidden;
  background: color-mix(in srgb, var(--line) 70%, transparent);
  appearance: none;
}
.lic-bar::-webkit-progress-bar {
  background: color-mix(in srgb, var(--line) 70%, transparent);
  border-radius: 999px;
}
.lic-bar::-webkit-progress-value {
  background: var(--accent);
  border-radius: 999px;
}
.lic-bar::-moz-progress-bar {
  background: var(--accent);
  border-radius: 999px;
}
/* Fiche d’un dossier de licence : un onglet à la fois. */
.lic-file {
  grid-template-columns: minmax(0, 1fr);
}
.lic-file [data-lic-pane] {
  display: grid;
  align-content: start;
  gap: 22px;
  min-width: 0;
  min-height: min(420px, 50vh);
}
.lic-file [data-lic-pane][hidden] {
  display: none;
}
.lic-file .file-tabs {
  margin: 0;
}

/* ——— SMS : conversation avec un client (page SMS et fiche réservation) ——— */
.res-sms h3 {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: baseline;
  margin: 18px 0 10px;
  font-size: 15px;
}
.sms-thread {
  display: grid;
  gap: 8px;
  max-height: 340px;
  overflow-y: auto;
  padding: 4px 2px 8px;
  scrollbar-width: thin;
}
.sms-bubble {
  justify-self: start;
  max-width: 78%;
  padding: 9px 13px;
  border-radius: 16px 16px 16px 4px;
  background: color-mix(in srgb, var(--line) 55%, transparent);
}
.sms-bubble.out {
  justify-self: end;
  border-radius: 16px 16px 4px 16px;
  background: color-mix(in srgb, var(--accent) 22%, transparent);
}
.sms-bubble.failed {
  outline: 1px solid color-mix(in srgb, var(--red) 60%, transparent);
}
.sms-bubble p {
  margin: 0;
  font-size: 14px;
  line-height: 1.5;
  overflow-wrap: anywhere;
}
.sms-bubble small {
  display: block;
  margin-top: 4px;
  font-size: 11px;
  color: var(--muted);
}
.sms-pics {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 6px;
}
.sms-pics img {
  width: 96px;
  height: 96px;
  object-fit: cover;
  border-radius: 8px;
}
.sms-reply {
  display: flex;
  gap: 10px;
  align-items: flex-end;
  margin-top: 10px;
}
.sms-reply textarea {
  flex: 1;
  min-width: 0;
  resize: vertical;
}
/* Nouveaux SMS du client sur une réservation (carte et ligne du tableau) : icône de
   discussion dans le style de la carte, compteur en pastille. */
.pending-side {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.sms-ping {
  position: relative;
  display: inline-grid;
  place-items: center;
  width: 30px;
  height: 30px;
  margin-left: 6px;
  border: 1px solid color-mix(in srgb, var(--accent) 55%, transparent);
  border-radius: 9px;
  background: color-mix(in srgb, var(--accent) 14%, transparent);
  color: var(--accent);
  vertical-align: middle;
  cursor: pointer;
  transition:
    background 0.2s,
    border-color 0.2s;
}
.sms-ping:hover,
.sms-ping:focus-visible {
  border-color: var(--accent);
  background: color-mix(in srgb, var(--accent) 24%, transparent);
}
.sms-ping b {
  position: absolute;
  top: -6px;
  right: -6px;
  display: grid;
  place-items: center;
  min-width: 17px;
  height: 17px;
  padding: 0 4px;
  border-radius: 999px;
  background: var(--accent);
  color: #11121a;
  font-size: 10px;
  font-weight: 800;
  line-height: 1;
}
.sms-ping::after {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  box-shadow: 0 0 0 0 color-mix(in srgb, var(--accent) 60%, transparent);
  animation: sms-ping 2s ease-out infinite;
}
@keyframes sms-ping {
  to {
    box-shadow: 0 0 0 8px transparent;
  }
}
@media (prefers-reduced-motion: reduce) {
  .sms-ping::after {
    animation: none;
  }
}

/* Sélecteur de boîte (mails, SMS) : Maze Event et les pôles. */
/* ——— Configuration · Pôles : une carte par entité (Maze Event et ses pôles) ——— */
.cfg-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 18px;
  margin-top: 18px;
}
.cfg-card {
  display: grid;
  gap: 14px;
  padding: 18px;
}
.cfg-card header {
  display: flex;
  align-items: center;
  gap: 14px;
}
.cfg-card header > div:nth-child(2) {
  flex: 1;
  min-width: 0;
}
.cfg-card h3 {
  margin: 0 0 2px;
  font-size: 17px;
}
.cfg-logo {
  display: grid;
  flex: none;
  place-items: center;
  width: 52px;
  height: 52px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: color-mix(in srgb, var(--accent) 12%, transparent);
  color: var(--accent);
  font-weight: 800;
}
.cfg-logo.large {
  width: 84px;
  height: 84px;
  border-radius: 18px;
}
.cfg-logo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.cfg-logo-field {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px;
}
.cfg-logo-field .field {
  flex: 1;
  min-width: 220px;
}
.cfg-card .range-facts {
  margin: 0;
}

/* ——— Configuration · Messages automatiques : un bloc par thème, cartes de texte ——— */
.msg-intro {
  margin: 18px 0 12px;
}
.msg-group {
  margin-top: 22px;
}
.msg-group-title {
  margin: 0 0 12px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.mbx-tpl-note {
  margin: 0;
  color: var(--muted);
  font-size: 12.5px;
  line-height: 1.45;
}
.mbx-tpl-actions {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}
.mbx-tpl.is-off .mbx-tpl-text,
.mbx-tpl.is-off .mbx-tpl-subject {
  opacity: 0.55;
}
.msg-switch {
  min-height: 0;
  color: var(--muted);
  font-size: 13px;
}
.msg-vars .chip-list {
  padding-bottom: 0;
}
.chip.msg-var {
  padding: 5px 11px;
  font: inherit;
  font-size: 12px;
  cursor: pointer;
}
.chip.msg-var:hover,
.chip.msg-var:focus-visible {
  border-color: var(--accent);
  background: color-mix(in srgb, var(--accent) 24%, transparent);
}
.msg-preview-box {
  margin-top: 8px;
  padding: 14px 16px;
  border: 1px dashed var(--line);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.02);
  font-size: 13.5px;
  line-height: 1.5;
}
.msg-preview-box p {
  margin: 0;
}
.msg-preview-box .mbx-tpl-subject:not(:empty) {
  margin-bottom: 8px;
}
#msg-count.is-over {
  color: var(--red);
}

/* ——— Dev · Items : bibliothèque des items (image et nom) ——— */
.item-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 14px;
}
.item-card {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--panel);
  text-align: center;
}
.item-image {
  display: grid;
  place-items: center;
  aspect-ratio: 1;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.03);
  color: var(--muted);
}
.item-image img {
  width: 78%;
  height: 78%;
  object-fit: contain;
}
.item-card figcaption {
  overflow-wrap: anywhere;
  font-size: 12.5px;
}

/* ——— Inventaire : détections, entités, modèles ——— */
.inv-actions {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 10px;
}
.inv-detect {
  margin-bottom: 18px;
  border-color: color-mix(in srgb, var(--accent) 55%, var(--line));
}
.inv-detect-list {
  display: grid;
  gap: 8px;
  padding: 0 18px 18px;
}
.inv-detect-item {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
}
.inv-detect-item > div {
  display: grid;
  flex: 1;
  min-width: 200px;
  gap: 2px;
}
.inv-detect-item small {
  color: var(--muted);
  font-size: 12px;
}
.inv-detect-icon {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: color-mix(in srgb, var(--accent) 16%, transparent);
  color: var(--accent);
}
.inv-detect-buttons {
  display: inline-flex;
  gap: 8px;
}
.inv-owner {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 14px 28px;
  margin: 0 0 4px;
}
.inv-owner .field {
  flex: 0 1 320px;
}
.inv-owner-name span {
  display: block;
  margin-bottom: 8px;
  font-size: 12px;
  color: #c0c0d1;
}
.inv-counts {
  display: flex;
  gap: 22px;
  margin: 0;
  padding-bottom: 10px;
  color: var(--muted);
  font-size: 13px;
}
.inv-counts b {
  margin-right: 6px;
  color: var(--text);
  font-size: 16px;
}
/* Menu déroulant d'un tableau partagé, à côté de la recherche (options.filters). */
.table-filter {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 0 1 260px;
}
.table-filter span {
  color: #c0c0d1;
  font-size: 12px;
  white-space: nowrap;
}
.table-filter select {
  flex: 1;
  min-width: 0;
  min-height: 40px;
}

/* Boîte mail et SMS : un seul cadre, la liste à gauche (boîte, dossier et recherche en
   champs soulignés, lignes soulignées) et la conversation à droite. */
.mbx.msg-frame {
  gap: 0;
  border: 1px solid var(--line, #2a2f40);
  border-radius: 14px;
  background: var(--panel, #101520);
  overflow: hidden;
}
.mbx.msg-frame .mbx-side,
.mbx.msg-frame .mbx-read {
  border: 0;
  border-radius: 0;
  background: none;
}
.mbx.msg-frame .mbx-side {
  border-right: 1px solid var(--line, #2a2f40);
}
.msg-side-head {
  display: grid;
  gap: 14px;
  padding: 18px 18px 14px;
}
.msg-side-head .field {
  margin: 0;
}
.msg-selects {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: end;
  gap: 14px;
}
.msg-selects > .msg-box {
  grid-column: 1 / -1;
}
.mbx.msg-frame .mbx-item {
  align-items: center;
  padding: 13px 18px;
  border-left: 0;
  border-bottom: 1px solid var(--ctl-border, #3a4256);
  background: linear-gradient(var(--accent, #989bfb), var(--accent, #989bfb))
    left bottom / 0 2px no-repeat;
  transition: background-size 0.3s;
}
.mbx.msg-frame .mbx-item:hover {
  background-color: rgba(255, 255, 255, 0.03);
}
.mbx.msg-frame .mbx-item.on {
  border-bottom-color: transparent;
  background-color: color-mix(in srgb, var(--accent, #989bfb) 8%, transparent);
  background-size: 100% 2px;
}
.mbx.msg-frame .mbx-avatar {
  background: color-mix(in srgb, var(--accent, #989bfb) 22%, transparent);
  color: #d9dafe;
}
.mbx-sub {
  overflow: hidden;
  color: #737a8c;
  font-size: 12px;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.msg-unread {
  display: grid;
  flex: none;
  place-items: center;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  border-radius: 10px;
  background: var(--accent, #989bfb);
  color: #0b0e16;
  font-size: 11px;
  font-weight: 800;
}
.mbx.msg-frame .mbx-head {
  flex-wrap: wrap;
  gap: 10px 14px;
  padding: 16px 22px;
}
.mbx.msg-frame .mbx-head > div {
  flex: 1;
  min-width: 160px;
}
.mbx.msg-frame .mbx-msgs {
  padding: 20px 22px;
}
.mbx.msg-frame .mbx-reply {
  padding: 14px 22px 18px;
}
/* Conversation SMS dans le cadre : fil qui défile, réponse en bas. */
.msg-chat {
  display: flex;
  flex: 1;
  flex-direction: column;
  min-height: 0;
}
.msg-chat .sms-thread {
  flex: 1;
  grid-template-rows: 1fr;
  max-height: none;
  padding: 20px 22px;
}
.msg-chat .sms-reply {
  margin: 0;
  padding: 14px 22px 18px;
  border-top: 1px solid var(--line, #2a2f40);
}
.msg-chat .sms-reply textarea {
  min-height: 44px;
  resize: none;
}
.msg-chat .sms-thread::before {
  content: "";
}
.sms-day {
  justify-self: center;
  margin: 6px 0 2px;
  color: #737a8c;
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

/* Tickets Discord : même cadre que la Boîte mail, conversation aux couleurs de Discord
   (salon du ticket : avatars, noms, badge APP du bot, embeds). */
.mbx-avatar img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
}
.mbx.msg-frame .mbx-tags {
  align-items: center;
  margin-top: 2px;
}
/* Listes du cadre (mails, SMS, tickets) : pagination en symboles, sur une ligne. */
.mbx-side .pagination {
  gap: 6px;
}
.mbx-side .pagination-buttons {
  flex-wrap: nowrap;
  gap: 4px;
}
.mbx-side .page-btn {
  min-width: 30px;
  height: 30px;
  padding: 0 6px;
}
.mbx-side .page-btn span {
  display: none;
}
.ticket-num {
  margin-left: 6px;
  color: var(--muted, #9aa0b5);
  font-size: 13px;
  font-weight: 600;
}
.ticket-chars {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 6px !important;
}
.dc-chat {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 8px 0 16px;
  color: #dbdee1;
  font-size: 15px;
  line-height: 1.375;
  scrollbar-width: thin;
}
.dc-day {
  display: flex;
  align-items: center;
  margin: 18px 16px 6px;
  color: #949ba4;
  font-size: 12px;
  font-weight: 600;
}
.dc-day::before,
.dc-day::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--line, #2a2f40);
}
.dc-day span {
  padding: 0 8px;
}
.dc-msg {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr);
  column-gap: 16px;
  padding: 4px 48px 2px 16px;
  margin-top: 14px;
}
.dc-msg.grouped {
  margin-top: 0;
  padding-top: 1px;
}
.dc-msg:hover {
  background: rgba(255, 255, 255, 0.03);
}
.dc-msg.deleted .dc-body {
  opacity: 0.5;
}
.dc-pp {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  overflow: hidden;
  background: #5865f2;
  color: #fff;
  font-size: 14px;
  font-weight: 700;
}
.dc-pp img,
.dc-embed-pp img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.dc-hover {
  visibility: hidden;
  align-self: center;
  color: #949ba4;
  font-size: 11px;
  text-align: right;
}
.dc-msg.grouped:hover .dc-hover {
  visibility: visible;
}
.dc-body {
  min-width: 0;
}
.dc-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
}
.dc-head strong {
  color: #f2f3f5;
  font-size: 15px;
  font-weight: 600;
}
.dc-head time {
  margin-left: 2px;
  color: #949ba4;
  font-size: 12px;
}
.dc-app {
  padding: 1px 5px;
  border-radius: 4px;
  background: #5865f2;
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  line-height: 15px;
}
.dc-text {
  overflow-wrap: anywhere;
  white-space: normal;
}
.dc-text.cmd {
  color: #949ba4;
}
.dc-text strong,
.dc-embed strong {
  color: #f2f3f5;
}
.dc-text a,
.dc-embed a {
  color: #00a8fc;
}
.dc-edited {
  color: #949ba4;
  font-size: 10px;
}
.dc-code {
  padding: 1px 4px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.045);
  font-size: 13px;
}
.dc-pre {
  margin: 4px 0;
  padding: 8px;
  border: 1px solid var(--line, #2a2f40);
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.045);
  font-size: 13px;
  white-space: pre-wrap;
}
.dc-emoji {
  width: 22px;
  height: 22px;
  vertical-align: -5px;
  object-fit: contain;
}
.dc-mention {
  padding: 0 2px;
  border-radius: 3px;
  background: rgba(88, 101, 242, 0.3);
  color: #c9cdfb;
  font-weight: 500;
}
.dc-embed {
  display: grid;
  gap: 6px;
  max-width: 520px;
  margin-top: 4px;
  padding: 8px 16px 12px 12px;
  border-left: 4px solid #989bfb;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.045);
  font-size: 14px;
}
.dc-embed.user {
  border-left-color: #ff0202;
}
.dc-embed-author {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
}
.dc-embed-pp {
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  overflow: hidden;
  background: #5865f2;
  color: #fff;
  font-size: 10px;
  font-weight: 700;
}
.dc-embed-title {
  color: #f2f3f5;
  font-weight: 600;
}
.dc-embed-text {
  overflow-wrap: anywhere;
}
.dc-embed-foot {
  color: #949ba4;
  font-size: 12px;
}
.dc-files {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 4px;
}
.dc-files img {
  max-width: 320px;
  max-height: 240px;
  border-radius: 8px;
  object-fit: contain;
}
.dc-file {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border: 1px solid var(--line, #2a2f40);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.045);
  color: #00a8fc;
  font-size: 14px;
}
.dc-reply {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 16px 16px;
  padding: 6px 8px 6px 14px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.05);
}
:root body .dc-reply textarea {
  flex: 1;
  min-width: 0;
  max-height: 200px;
  padding: 8px 0;
  border: 0;
  background: none;
  box-shadow: none;
  color: #dbdee1;
  font-size: 15px;
  resize: none;
}
.dc-reply .check-field {
  min-height: 0;
  color: #949ba4;
  font-size: 13px;
  white-space: nowrap;
}
/* Ticket SMS : réponse par SMS ou par mail en jeu. */
:root body .dc-reply select {
  width: auto;
  min-height: 0;
  padding: 6px 28px 6px 10px;
  font-size: 13px;
}
.ticket-closed {
  margin: 0;
  padding: 14px 22px 18px;
  border-top: 1px solid var(--line, #2a2f40);
  color: #949ba4 !important;
}

/* Statut d'un ticket : point animé (ouvert : pulsation verte, suspendu : orange, fermé :
   gris), à la place du badge encadré. */
.ticket-state {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--muted, #9aa0b5);
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}
.ticket-state i {
  position: relative;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #6b7280;
}
.ticket-state.open {
  color: #4ade80;
}
.ticket-state.open i {
  background: #4ade80;
}
.ticket-state.open i::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: #4ade80;
  animation: ticket-pulse 1.8s ease-out infinite;
}
.ticket-state.suspended {
  color: #fbbf24;
}
.ticket-state.suspended i {
  background: #fbbf24;
}
@keyframes ticket-pulse {
  from {
    transform: scale(1);
    opacity: 0.7;
  }
  to {
    transform: scale(3);
    opacity: 0;
  }
}
@media (prefers-reduced-motion: reduce) {
  .ticket-state.open i::after {
    animation: none;
  }
}
.mbx-head > .ticket-state {
  align-self: flex-start;
  margin-top: 6px;
}

/* Mes infos : bandeau d’identité, semaine choisie, onglets soulignés avec compteurs. */
.me-band {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 18px 22px;
  padding: 22px 26px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: linear-gradient(90deg, rgba(152, 155, 251, 0.14), transparent 60%),
    var(--panel);
}
.me-band .avatar {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  font-size: 22px;
  object-fit: cover;
}
.me-band-id {
  flex: 1;
  min-width: 220px;
}
.me-band-id h2 {
  margin: 0;
  font-family: "Archivo", "Arial Black", Arial, sans-serif;
  font-size: 26px;
  font-style: italic;
  font-weight: 900;
  text-transform: uppercase;
}
.me-band-id p {
  margin: 4px 0 0;
  color: var(--muted);
}
.me-band-tags {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}
.me-week {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 18px;
  margin: 22px 0 16px;
}
.me-week .week-bar {
  margin: 0;
}
.me-tabs {
  margin-top: 26px;
}
.me-tabs .tab {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.me-count {
  min-width: 20px;
  padding: 1px 6px;
  border-radius: 999px;
  background: #ffffff14;
  font-size: 11px;
  text-align: center;
}
.me-tabs .tab[aria-selected="true"] .me-count {
  background: color-mix(in srgb, var(--accent) 30%, transparent);
}

/* Contrats aviation : contrat en cours (2 étapes), contrats proposés en cartes, suivi. */
.ac-cur {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 18px 28px;
  padding: 22px 26px;
  border: 1px solid color-mix(in srgb, var(--accent) 35%, transparent);
  border-radius: 18px;
  background: linear-gradient(
      110deg,
      rgba(152, 155, 251, 0.16),
      transparent 60%
    ),
    var(--panel);
}
.ac-k {
  color: var(--accent);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.ac-cur h3 {
  margin: 6px 0 2px;
  font-family: "Archivo", "Arial Black", Arial, sans-serif;
  font-size: 24px;
  font-style: italic;
  font-weight: 900;
  text-transform: uppercase;
}
.ac-cur p {
  margin: 0;
  color: var(--muted);
}
.ac-steps {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 60px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
}
.ac-step {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.02);
}
.ac-step .n {
  display: grid;
  flex: none;
  place-items: center;
  width: 30px;
  height: 30px;
  border: 1px solid var(--line);
  border-radius: 50%;
  font-size: 13px;
  font-weight: 800;
}
.ac-step.done {
  border-color: rgba(74, 222, 128, 0.4);
}
.ac-step.done .n {
  border-color: #4ade80;
  background: #4ade80;
  color: #0b0e16;
}
.ac-step.now {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(152, 155, 251, 0.12);
}
.ac-step.now .n {
  border-color: var(--accent);
  background: var(--accent);
  color: #0b0e16;
}
.ac-step strong {
  display: block;
}
.ac-step small {
  color: var(--muted);
}
.ac-line {
  height: 2px;
  border-radius: 2px;
  background: linear-gradient(90deg, #4ade80, var(--accent));
}
.ac-rank {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}
.ac-rank article {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--panel);
}
.ac-rank b {
  display: block;
}
.ac-rank small {
  color: var(--muted);
}
.ac-rank em {
  margin-left: auto;
  color: var(--accent);
  font-size: 22px;
  font-style: normal;
  font-weight: 800;
}
.ac-ok {
  color: #4ade80;
  font-weight: 700;
}
.ac-ko {
  color: #fbbf24;
  font-weight: 700;
}
.ac-off {
  color: var(--muted);
  font-weight: 700;
}
@media (max-width: 700px) {
  .ac-steps {
    grid-template-columns: minmax(0, 1fr);
  }
  .ac-line {
    display: none;
  }
}

.ac-steps.three {
  grid-template-columns: minmax(0, 1fr) 40px minmax(0, 1fr) 40px minmax(0, 1fr);
}
/* Plus de trois étapes (survol, convoyage avec nettoyage…) : grille sans trait. */
.ac-steps.many {
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
}
.ac-plane-req,
.ac-reward {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.ac-plane-req {
  color: var(--text);
}
.ac-reward {
  color: var(--green);
}
.ac-clean {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 0;
  color: var(--accent);
  font-size: 12.5px;
  font-weight: 600;
}
@media (max-width: 900px) {
  .ac-steps.three {
    grid-template-columns: minmax(0, 1fr);
  }
  .ac-steps.three .ac-line {
    display: none;
  }
}

/* Contrats proposés en billets d'embarquement : apparition en cascade, avion qui fait
   l'aller-retour sur le trajet (SVG), talon détachable avec l'anneau d'expiration ;
   au survol le billet se soulève et le bouton se remplit. */
@keyframes ac-rise {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
@keyframes ac-dash {
  to {
    stroke-dashoffset: -24;
  }
}
.ac-tickets {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 420px), 1fr));
  gap: 16px;
}
.ac-ticket {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 132px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--panel);
  animation: ac-rise 0.5s both;
  transition:
    transform 0.25s,
    box-shadow 0.25s,
    border-color 0.25s;
}
.ac-ticket:nth-child(2) {
  animation-delay: 0.08s;
}
.ac-ticket:nth-child(3) {
  animation-delay: 0.16s;
}
.ac-ticket:nth-child(4) {
  animation-delay: 0.24s;
}
.ac-ticket:nth-child(5) {
  animation-delay: 0.32s;
}
.ac-ticket:nth-child(n + 6) {
  animation-delay: 0.4s;
}
.ac-ticket:hover,
.ac-ticket:focus-within {
  transform: translateY(-4px);
  border-color: color-mix(in srgb, var(--accent) 55%, transparent);
  box-shadow:
    0 18px 40px rgba(0, 0, 0, 0.35),
    0 0 0 1px color-mix(in srgb, var(--accent) 25%, transparent);
}
.ac-tk-main {
  display: grid;
  gap: 12px;
  min-width: 0;
  padding: 18px 20px;
}
.ac-tk-head {
  display: flex;
  align-items: baseline;
  gap: 10px;
}
.ac-tk-head b {
  font-size: 14px;
}
.ac-tk-head span {
  color: var(--muted);
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.ac-tk-route {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
}
.ac-tk-route strong {
  display: block;
  font-family: "Archivo", "Arial Black", Arial, sans-serif;
  font-size: 34px;
  font-style: italic;
  font-weight: 900;
  line-height: 1;
}
.ac-tk-route small {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
}
.ac-tk-route > div:last-child {
  text-align: right;
}
.ac-tk-path {
  width: 100%;
  height: 40px;
  overflow: visible;
}
.ac-tk-path > path {
  fill: none;
  stroke: color-mix(in srgb, var(--accent) 60%, transparent);
  stroke-width: 2;
  stroke-dasharray: 4 8;
  animation: ac-dash 0.8s linear infinite;
}
.ac-plane {
  fill: #fff;
  filter: drop-shadow(0 0 4px var(--accent));
}
.ac-tk-foot {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 12px;
  color: var(--muted);
  font-size: 11.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.ac-tk-foot .ac-clean {
  gap: 4px;
  font-size: 11.5px;
  letter-spacing: 0.08em;
}
.ac-tk-stub {
  position: relative;
  display: grid;
  justify-items: center;
  align-content: space-between;
  gap: 8px;
  padding: 18px 14px;
  border-left: 2px dashed rgba(255, 255, 255, 0.12);
  background: linear-gradient(180deg, rgba(152, 155, 251, 0.08), transparent);
  text-align: center;
}
/* Encoches du billet, au bord du talon. */
.ac-tk-stub::before,
.ac-tk-stub::after {
  content: "";
  position: absolute;
  left: -9px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--bg, #0b0e16);
}
.ac-tk-stub::before {
  top: -9px;
}
.ac-tk-stub::after {
  bottom: -9px;
}
.ac-ring {
  --p: 100;
  display: grid;
  place-items: center;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: conic-gradient(
    var(--accent) calc(var(--p) * 1%),
    rgba(255, 255, 255, 0.1) 0
  );
}
.ac-ring span {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--panel);
  font-size: 12.5px;
  font-weight: 800;
}
.ac-tk-stub small {
  color: var(--muted);
  font-size: 11px;
}
.ac-tk-stub .ac-take {
  width: 100%;
  padding: 9px 0;
  border: 1px solid var(--accent);
  border-radius: 10px;
  background: none;
  color: var(--text);
  font: inherit;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition:
    background 0.2s,
    color 0.2s;
}
.ac-ticket:hover .ac-take:not(:disabled),
.ac-tk-stub .ac-take:focus-visible {
  background: var(--accent);
  color: #0b0e16;
}
.ac-tk-stub .ac-take:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}
@media (prefers-reduced-motion: reduce) {
  .ac-ticket,
  .ac-tk-path > path {
    animation: none;
  }
}
@media (max-width: 520px) {
  .ac-ticket {
    grid-template-columns: minmax(0, 1fr);
  }
  .ac-tk-stub {
    grid-template-columns: auto 1fr auto;
    align-items: center;
    justify-items: start;
    gap: 14px;
    border-top: 2px dashed rgba(255, 255, 255, 0.12);
    border-left: 0;
    text-align: left;
  }
  .ac-tk-stub .ac-take {
    width: auto;
    padding: 9px 22px;
  }
  .ac-cur {
    grid-template-columns: minmax(0, 1fr);
    padding: 18px;
  }
  .ac-cur h3 {
    font-size: 20px;
    overflow-wrap: normal;
  }
  #ac-abandon {
    justify-self: start;
  }
  .ac-tk-stub::before,
  .ac-tk-stub::after {
    display: none;
  }
  .ac-tk-route strong {
    font-size: 26px;
  }
}

/* Fiche employé : bouton « Licencier » (ouvre Édition · Lettre) et lettre de départ
   dans l'historique. */
.file-fire {
  margin-left: auto;
}
.hr-timeline .hr-note {
  color: var(--muted);
  font-size: 13px;
  font-style: italic;
}
.hr-letter {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  width: fit-content;
  color: var(--accent);
  font-size: 13px;
  font-weight: 600;
}
@media (max-width: 820px) {
  .file-summary {
    flex-wrap: wrap;
  }
}

/* Documents (Mes documents, Édition) : document au format AVA à droite, sur fond
   sombre, avec le compteur de caractères et la barre « Récupérer en item ». */
.ed-k {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  color: var(--muted);
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}
.ed-k b {
  padding: 3px 10px;
  border: 1px solid rgba(159, 240, 196, 0.4);
  border-radius: 999px;
  color: #9ff0c4;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: none;
}
.ed-k b.over {
  border-color: rgba(255, 120, 120, 0.5);
  color: #ff9b9b;
}
.ed-stage {
  padding: 24px 28px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #0d1220;
}
.ed-stage .ava-paper {
  max-width: 600px;
  margin: 0 auto;
}
.ed-act {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
}
.ed-note {
  flex-basis: 100%;
  color: var(--muted);
  font-size: 12.5px;
  text-align: right;
}
body.dashboard .btn.ed-give:not(:disabled) {
  border-color: var(--accent);
  color: #fff;
  box-shadow: 0 0 14px rgba(152, 155, 251, 0.35);
}
.ed-act .btn svg {
  margin-right: 6px;
}
.docs {
  display: grid;
  grid-template-columns: minmax(280px, 360px) minmax(0, 1fr);
  gap: 22px;
  align-items: start;
}
.docs-list {
  display: grid;
  gap: 14px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--panel);
}
.docs-filters {
  display: grid;
  gap: 12px;
}
.docs-rows {
  display: grid;
  gap: 4px;
  max-height: 70vh;
  overflow: auto;
}
.docs-row {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 10px;
  border: 1px solid transparent;
  border-radius: 12px;
  background: none;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.docs-row i {
  display: grid;
  flex: none;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background: rgba(152, 155, 251, 0.12);
  color: var(--accent);
}
.docs-row span {
  display: grid;
  gap: 2px;
  min-width: 0;
}
.docs-row strong {
  overflow: hidden;
  font-size: 14px;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.docs-row small {
  color: var(--muted);
  font-size: 12px;
}
.docs-row:hover {
  background: rgba(255, 255, 255, 0.03);
}
.docs-row.on {
  border-color: rgba(152, 155, 251, 0.45);
  background: rgba(152, 155, 251, 0.1);
}
.docs-view {
  position: sticky;
  top: 12px;
  display: grid;
  gap: 12px;
}
@media (max-width: 900px) {
  .docs {
    grid-template-columns: minmax(0, 1fr);
  }
  .docs-view {
    position: static;
  }
  .ed-stage {
    padding: 14px 10px;
  }
}

/* Menu : groupe « Édition » qui se déplie sur ses pages. */
.nav-fold-head {
  width: 100%;
  border: 0;
  background: none;
  font-family: inherit;
  text-align: left;
  cursor: pointer;
}
.nav-fold-head > svg:last-child {
  margin-left: auto;
  transition: transform 0.2s;
}
.nav-fold.open .nav-fold-head {
  color: #fff;
}
.nav-fold.open .nav-fold-head > svg:last-child {
  transform: rotate(90deg);
}
.nav-sub {
  display: grid;
  gap: 2px;
  margin: 2px 0 6px 26px;
  padding-left: 12px;
  border-left: 1px solid #34405a;
}
.nav-sub[hidden] {
  display: none;
}
.nav-sub .nav-link {
  min-height: 0;
  padding: 7px 10px;
  font-size: 13.5px;
}
.nav-sub .nav-link.active::before {
  display: none;
}

/* Édition (contrat, devis, lettre) : champs à gauche, item à droite. */
.ed {
  display: grid;
  grid-template-columns: minmax(340px, 440px) minmax(0, 1fr);
  gap: 22px;
  align-items: start;
}
.ed-form {
  display: grid;
  align-content: start;
  gap: 16px;
  padding: 20px 22px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--panel);
}
.ed-form .field {
  min-width: 0;
}
.ed-pre {
  display: grid;
  gap: 6px;
  padding: 14px 16px;
  border: 1px dashed rgba(152, 155, 251, 0.4);
  border-radius: 12px;
  background: rgba(152, 155, 251, 0.08);
}
.ed-pre small {
  color: var(--muted);
  font-size: 12px;
}
.ed-2 {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 16px;
}
.ed-sec {
  margin: 4px 0 0;
  color: var(--accent);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}
.ed-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0;
  padding: 0;
  border: 0;
}
.ed-chips legend {
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 12.5px;
}
.ed-chips label {
  cursor: pointer;
}
.ed-chips input {
  position: absolute;
  opacity: 0;
}
.ed-chips span {
  display: inline-block;
  padding: 6px 12px;
  border: 1px solid #3c4660;
  border-radius: 999px;
  color: #aab2c8;
  font-size: 13px;
}
.ed-chips input:checked + span {
  border-color: var(--accent);
  background: rgba(152, 155, 251, 0.12);
  color: #fff;
}
.ed-chips input:focus-visible + span {
  outline: 2px solid var(--accent);
}
.ed-lines {
  display: grid;
  gap: 6px;
}
.ed-line {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 60px 96px 32px;
  gap: 10px;
  align-items: end;
}
.ed-line .icon-btn {
  margin-bottom: 4px;
}
.ed-add {
  justify-self: start;
  padding: 0;
}
.ed-check {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  color: var(--text);
  font-size: 13.5px;
  cursor: pointer;
}
.ed-check[hidden] {
  display: none;
}
.ed-check input {
  margin-top: 3px;
  accent-color: var(--accent);
}
.ed-check small {
  display: block;
  color: var(--muted);
  font-size: 12px;
}
.ed-prev {
  position: sticky;
  top: 12px;
  display: grid;
  gap: 12px;
}
.ed-error:empty {
  display: none;
}
.ed-error {
  margin: 0;
  text-align: right;
}
@media (max-width: 1000px) {
  .ed {
    grid-template-columns: minmax(0, 1fr);
  }
  .ed-prev {
    position: static;
  }
}
@media (max-width: 520px) {
  .ed-2 {
    grid-template-columns: minmax(0, 1fr);
  }
  .ed-form {
    padding: 16px;
  }
  .ed-line {
    grid-template-columns: minmax(0, 1fr) 52px 80px 32px;
    gap: 8px;
  }
}

/* Menu : rubriques (Mon espace, Maze Team, Manager…) qui s’ouvrent et se ferment. */
.sidebar .nav-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 4px 0;
  border: 0;
  background: none;
  font-family: inherit;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
}
.sidebar .nav-label:hover,
.sidebar .nav-label:focus-visible {
  color: #d7d8ff;
}
.sidebar .nav-label svg {
  color: var(--accent);
  transform: rotate(90deg);
  transition: transform 0.2s;
}
.nav-section.closed .nav-label svg {
  transform: none;
}
.nav-section.closed:not(.searching) .nav-group {
  display: none;
}
.nav-section.closed .nav-label {
  margin-bottom: 10px;
}

/* Fiche employé : état des rôles Discord. */
.discord-state {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 6px;
  color: var(--muted);
}
.discord-state svg {
  color: var(--accent);
}
.discord-state.ko,
.discord-state.ko svg {
  color: #ff9b9b;
}
.discord-state .text-btn {
  padding: 0;
  font-size: inherit;
}

/* Tablette AVA (≈ 960 à 1440 px de large) et petit ordinateur : tableaux plus serrés,
   et la colonne d’action (Fiche, Détails…) reste collée à droite, toujours visible
   même quand le tableau défile sur le côté. */
@media (min-width: 601px) and (max-width: 1500px) {
  .data-table .table-wrap th,
  .data-table .table-wrap td {
    padding-inline: 12px;
  }
  .data-table .table-wrap th:first-child,
  .data-table .table-wrap td:first-child {
    padding-left: 16px;
  }
  .data-table .responsive-table th.col-actions,
  .data-table .responsive-table td[data-label="Actions"] {
    position: sticky;
    right: 0;
    z-index: 1;
    padding-inline: 12px 16px;
    background: var(--panel);
    box-shadow: -14px 0 14px -14px #000c;
  }
}

/* Tablette AVA et petit ordinateur : le dashboard est dézoomé (tout est un peu plus
   petit) pour garder le menu de gauche toujours ouvert. Téléphone (≤ 600 px) : menu
   en tiroir, sans dézoom. Les tuiles des cartes se chevauchent d’un pixel (sans le mélange additif de Leaflet) pour ne pas
   laisser de fines lignes une fois dézoomées. */
@media (min-width: 601px) and (max-width: 1500px) {
  body.dashboard {
    zoom: 0.88;
  }
  body.dashboard .leaflet-tile-container img.leaflet-tile {
    width: 257px !important;
    height: 257px !important;
    mix-blend-mode: normal;
  }
}
@media (min-width: 601px) and (max-width: 1100px) {
  body.dashboard {
    zoom: 0.78;
  }
}
@media (min-width: 601px) and (max-width: 1000px) {
  body.dashboard .sidebar {
    transform: none;
    visibility: visible;
    width: 248px;
    inset-block: 0;
    padding-top: 24px;
    box-shadow: none;
    transition: none;
  }
  body.dashboard .sidebar .brand img {
    width: 142px;
  }
  body.dashboard .main-shell {
    margin-left: 248px;
  }
  body.dashboard .mobile-menu,
  body.dashboard .drawer-close,
  body.dashboard .nav-scrim {
    display: none !important;
  }
}

/* ——— Page Discord (Développeur) : état du bot, onglets, actions du règlement ——— */
.discord-stats {
  margin-bottom: 22px;
}
/* Couleur (embeds, messages du joueur) : pastille cliquable au lieu d’une barre. */
.discord-panel input[type="color"] {
  width: 72px;
  height: 40px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: transparent;
  cursor: pointer;
}
.discord-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}
.discord-actions .form-error {
  flex-basis: 100%;
  margin: 0;
}

/* Filtres en un clic avec leur nombre (Recrutement…), à réutiliser pour d’autres listes. */
.filter-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.filter-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 12px;
  border: 1px solid var(--line);
  border-radius: 100px;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-size: 12px;
  cursor: pointer;
}
.filter-pill b {
  min-width: 18px;
  padding: 1px 6px;
  border-radius: 100px;
  background: color-mix(in srgb, var(--accent) 14%, transparent);
  color: var(--text);
  font-size: 11px;
  text-align: center;
}
.filter-pill:hover,
.filter-pill:focus-visible {
  border-color: var(--accent);
  color: var(--text);
}
.filter-pill[aria-pressed="true"] {
  border-color: var(--accent);
  background: color-mix(in srgb, var(--accent) 12%, transparent);
  color: var(--text);
}
/* Recrutement : ligne d’un candidat dont la réponse n’est pas lue. */
.data-table tr.row-unread td:first-child {
  box-shadow: inset 3px 0 0 var(--red);
}
/* Conversation d’une candidature : hauteur limitée, défile. */
.application-thread {
  max-height: 360px;
  overflow-y: auto;
  margin-bottom: 12px;
}
/* Décisions d’une candidature : sous le nom du candidat, alignées à gauche. */
.form-actions.application-decisions {
  justify-content: flex-start;
  margin: 0 0 6px;
}

/* Téléphone et mail confirmés par un code : état sous le champ (profil, Utilisateurs)
   et bandeau du dashboard (coordonnées à confirmer). */
.contact-field {
  display: grid;
  align-content: start;
  gap: 8px;
}
.contact-state {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 10px;
  margin: 0;
  color: var(--muted, #a1a9bb);
  font-size: 12px;
}
.contact-banner {
  border-bottom-color: color-mix(
    in srgb,
    var(--yellow, #e2bf77) 40%,
    transparent
  );
  background: linear-gradient(
    90deg,
    color-mix(in srgb, var(--yellow, #e2bf77) 16%, transparent),
    color-mix(in srgb, var(--yellow, #e2bf77) 4%, transparent)
  );
}
.contact-banner > svg {
  color: var(--yellow, #e2bf77);
}

/* Événements (page Événements, Mes inscriptions) : fiche en deux colonnes de panneaux,
   listes (équipe, liens, tâches), cartes d’inscription. */
.page-heading-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.event-col {
  display: grid;
  gap: 18px;
  min-width: 0;
}
.event-panel .panel-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}
.event-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.event-cover {
  display: block;
  width: 100%;
  max-height: 220px;
  margin-bottom: 14px;
  border-radius: 8px;
  object-fit: cover;
}
.event-text {
  margin: 12px 0 0;
  color: var(--text);
  line-height: 1.6;
}
.event-list {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.event-list li {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
}
.event-list li > .event-item,
.event-list .check-field > span {
  display: grid;
  flex: 1;
  min-width: 0;
}
.event-list small {
  color: var(--muted);
}
.event-list .check-field {
  flex: 1;
  min-height: 0;
  align-items: center;
}
.event-list.tasks li.done strong {
  color: var(--muted);
  text-decoration: line-through;
}
.event-list.pick {
  max-height: 50vh;
  overflow: auto;
}
:root body .event-list .event-role {
  width: 180px;
}
.event-add {
  margin-top: 14px;
}
.event-note {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: start;
  margin-bottom: 14px;
}
.event-note .form-error {
  grid-column: 1 / -1;
  margin: 0;
}
.event-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 16px;
}
.event-card .event-cover {
  margin: 0;
  border-radius: 10px 10px 0 0;
}
.event-card h3 {
  margin: 0 0 4px;
}
@media (max-width: 1100px) {
  .event-grid {
    grid-template-columns: 1fr;
  }
}
