/* Marshal Service — thème sobriété / institutionnel */
:root {
  --bg-deep: #0a1628;
  --bg-panel: rgba(13, 28, 48, 0.92);
  --navy-mid: #132238;
  --gold: #b8860b;
  --gold-bright: #d4af37;
  --gold-muted: rgba(212, 175, 55, 0.35);
  --text-main: #e8eaf0;
  --text-soft: rgba(232, 234, 240, 0.75);
  --border-rule: rgba(212, 175, 55, 0.45);
  --font-display: Georgia, "Times New Roman", Times, serif;
  --font-ui: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font-ui);
  color: var(--text-main);
  background: var(--bg-deep);
  background-image:
    radial-gradient(ellipse 120% 80% at 50% -30%, rgba(30, 58, 95, 0.45) 0%, transparent 55%),
    repeating-linear-gradient(
      -45deg,
      transparent,
      transparent 2px,
      rgba(212, 175, 55, 0.03) 2px,
      rgba(212, 175, 55, 0.03) 4px
    );
}

a {
  color: var(--gold-bright);
  text-decoration: none;
  transition: color 0.15s ease, opacity 0.15s ease;
}

a:hover {
  color: #f0d878;
}

/* ---------- En-tête ---------- */
.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.5rem;
  border-bottom: 3px solid var(--border-rule);
  background: linear-gradient(180deg, rgba(15, 32, 55, 0.98) 0%, rgba(10, 22, 40, 0.95) 100%);
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.35);
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.875rem;
  text-decoration: none;
  color: inherit;
}

.brand:hover {
  opacity: 0.92;
}

.brand-logo {
  height: 56px;
  width: auto;
  object-fit: contain;
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.4));
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.05;
}

.brand-title {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-main);
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
}

.brand-sub {
  font-size: 0.65rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--gold);
  margin-top: 0.2rem;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-shrink: 0;
}

.header-user {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.6rem;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-soft);
}

.btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.55rem 1rem;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold-bright);
  background: transparent;
  border: 1px solid var(--gold-muted);
  border-radius: 2px;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.btn-ghost:hover {
  color: var(--text-main);
  border-color: var(--gold-bright);
  background: rgba(212, 175, 55, 0.12);
}

.btn-ghost-small {
  padding: 0.45rem 0.85rem;
  font-size: 0.65rem;
}

.alert-error {
  margin: 0 0 1.25rem;
  padding: 0.65rem 0.85rem;
  font-size: 0.85rem;
  line-height: 1.45;
  text-align: left;
  color: #fcdcdc;
  background: rgba(139, 0, 0, 0.35);
  border: 1px solid rgba(255, 107, 107, 0.45);
  border-radius: 2px;
}

.alert-success {
  margin: 0 0 1.25rem;
  padding: 0.65rem 0.85rem;
  font-size: 0.87rem;
  line-height: 1.45;
  color: #d4fce8;
  background: rgba(0, 121, 64, 0.28);
  border: 1px solid rgba(46, 204, 113, 0.5);
  border-radius: 2px;
}

/* ---------- Espace sécurisé (menu latéral) ---------- */
body.is-secure-app {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

body.is-secure-app .site-footer {
  margin-top: auto;
}

.secure-app {
  display: flex;
  flex: 1;
  align-items: stretch;
  width: 100%;
  min-height: calc(100vh - 73px);
}

.secure-sidebar {
  flex-shrink: 0;
  width: 272px;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding: 0.75rem 0.65rem 1.25rem;
  background: rgba(8, 18, 32, 0.97);
  border-right: 1px solid rgba(212, 175, 55, 0.22);
  box-shadow: 4px 0 24px rgba(0, 0, 0, 0.25);
  transition: width 0.22s ease, padding 0.22s ease;
}

.secure-sidebar.is-collapsed {
  width: 56px;
  padding-left: 0.35rem;
  padding-right: 0.35rem;
  overflow: hidden;
}

.sidebar-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 2.25rem;
  margin: 0;
  padding: 0;
  font-size: 1.1rem;
  line-height: 1;
  color: var(--gold-bright);
  background: rgba(212, 175, 55, 0.08);
  border: 1px solid rgba(212, 175, 55, 0.25);
  border-radius: 2px;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.sidebar-toggle:hover {
  background: rgba(212, 175, 55, 0.16);
  border-color: var(--gold-bright);
}

.secure-sidebar.is-collapsed .sidebar-toggle {
  width: 100%;
}

.secure-nav {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  flex: 1;
}

/* Sections repliables — même ligne visuelle que le portail (or / marine) */
.secure-nav-section {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.secure-nav-section + .secure-nav-section {
  margin-top: 0.35rem;
  padding-top: 0.65rem;
  border-top: 1px solid rgba(212, 175, 55, 0.14);
}

.secure-nav-section-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  width: 100%;
  margin: 0;
  padding: 0.35rem 0.5rem 0.4rem;
  font-family: var(--font-display);
  font-size: 0.7rem;
  font-weight: 400;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  text-align: left;
  color: var(--gold);
  background: transparent;
  border: none;
  border-radius: 0;
  cursor: pointer;
  transition: color 0.15s ease;
}

.secure-nav-section-toggle:hover {
  color: var(--gold-bright);
}

.secure-nav-section.has-active .secure-nav-section-toggle,
.secure-nav-section.is-open .secure-nav-section-toggle {
  color: var(--gold-bright);
}

.secure-nav-section-label {
  flex: 1;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.secure-nav-section-chevron {
  flex-shrink: 0;
  width: 0.4rem;
  height: 0.4rem;
  margin-top: -0.1rem;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: rotate(45deg);
  opacity: 0.55;
  transition: transform 0.2s ease, opacity 0.15s ease;
}

.secure-nav-section.is-open .secure-nav-section-chevron {
  transform: rotate(-135deg);
  margin-top: 0.12rem;
  opacity: 0.9;
}

.secure-nav-section-body {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.22s ease;
}

.secure-nav-section.is-open .secure-nav-section-body {
  grid-template-rows: 1fr;
}

.secure-nav-section-body > .secure-nav-group {
  overflow: hidden;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  padding: 0.15rem 0 0.35rem 0.65rem;
  margin-left: 0.15rem;
  border-left: 1px solid rgba(212, 175, 55, 0.2);
}

.secure-nav-group {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

/* Menu réduit : icônes centrées, carrées, sans double cadre au survol */
.secure-sidebar.is-collapsed .secure-nav {
  align-items: center;
  gap: 0.2rem;
}

.secure-sidebar.is-collapsed .secure-nav-section {
  align-items: center;
  width: 100%;
  margin: 0;
  padding: 0;
  border: none;
}

.secure-sidebar.is-collapsed .secure-nav-section + .secure-nav-section {
  margin-top: 0.35rem;
  padding-top: 0.35rem;
  border-top: 1px solid rgba(212, 175, 55, 0.12);
}

.secure-sidebar.is-collapsed .secure-nav-section-toggle {
  display: none;
}

.secure-sidebar.is-collapsed .secure-nav-section-body {
  display: block;
  width: 100%;
  overflow: visible;
}

.secure-sidebar.is-collapsed .secure-nav-section-body > .secure-nav-group {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
  padding: 0;
  margin: 0;
  border: none;
  overflow: visible;
  min-height: unset;
}

.secure-nav-row {
  display: flex;
  align-items: stretch;
  gap: 0.45rem;
}

/* Lien menu : pleine largeur de la barre latérale (gauche → droite) */
.secure-nav > .secure-nav-link {
  align-self: stretch;
  width: 100%;
  box-sizing: border-box;
}

.secure-nav-link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.65rem 0.85rem;
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-soft);
  border: 1px solid transparent;
  border-radius: 2px;
  text-decoration: none;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.secure-nav-link:hover {
  color: var(--text-main);
  background: rgba(212, 175, 55, 0.08);
  border-color: rgba(212, 175, 55, 0.2);
}

.secure-nav-link.is-active {
  color: var(--text-main);
  background: rgba(212, 175, 55, 0.15);
  border-color: rgba(212, 175, 55, 0.35);
}

.secure-nav-icon {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  font-size: 1.2rem;
  line-height: 1;
  color: var(--gold-bright);
  background: rgba(212, 175, 55, 0.1);
  border: 1px solid rgba(212, 175, 55, 0.28);
  border-radius: 2px;
}

.secure-nav-link:hover .secure-nav-icon {
  color: #f0d878;
  background: rgba(212, 175, 55, 0.18);
  border-color: rgba(212, 175, 55, 0.45);
}

.secure-nav-link.is-active .secure-nav-icon {
  color: var(--bg-deep);
  background: linear-gradient(180deg, var(--gold-bright) 0%, #a67c00 100%);
  border-color: rgba(255, 255, 255, 0.25);
}

.secure-nav-label {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  transition: opacity 0.15s ease, max-width 0.22s ease;
}

.secure-sidebar.is-collapsed .secure-nav-label {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
  opacity: 0;
  pointer-events: none;
}

.secure-sidebar.is-collapsed .secure-nav-row {
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
}

.secure-sidebar.is-collapsed .secure-nav-link {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.35rem;
  height: 2.35rem;
  margin: 0 auto;
  padding: 0;
  gap: 0;
  flex-shrink: 0;
  box-sizing: border-box;
  border: 1px solid rgba(212, 175, 55, 0.28);
  background: rgba(212, 175, 55, 0.1);
}

.secure-sidebar.is-collapsed .secure-nav-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  margin: 0;
  padding: 0;
  font-size: 1.05rem;
  line-height: 1;
  border: none;
  background: transparent;
  box-sizing: border-box;
}

.secure-sidebar.is-collapsed .secure-nav-link:hover {
  color: var(--text-main);
  background: rgba(212, 175, 55, 0.18);
  border-color: rgba(212, 175, 55, 0.45);
}

.secure-sidebar.is-collapsed .secure-nav-link:hover .secure-nav-icon {
  color: #f0d878;
  background: transparent;
  border: none;
}

.secure-sidebar.is-collapsed .secure-nav-link.is-active {
  color: var(--text-main);
  background: rgba(212, 175, 55, 0.22);
  border-color: var(--gold-bright);
}

.secure-sidebar.is-collapsed .secure-nav-link.is-active .secure-nav-icon {
  color: var(--gold-bright);
  background: transparent;
  border: none;
  box-shadow: none;
}

.secure-sidebar.is-collapsed .btn-nav-plus {
  width: 100%;
  min-height: 2.25rem;
}

.btn-nav-plus {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.65rem;
  flex-shrink: 0;
  font-size: 1.25rem;
  font-weight: 700;
  line-height: 1;
  color: var(--bg-deep);
  text-decoration: none;
  background: linear-gradient(180deg, var(--gold-bright) 0%, #a67c00 100%);
  border-radius: 2px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
}

.btn-nav-plus:hover {
  filter: brightness(1.06);
}

.secure-main {
  flex: 1;
  min-width: 0;
  padding: 1.5rem 1.75rem 2.5rem;
}

.secure-main--empty {
  padding: 0;
}

.secure-main--centered {
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding: 2rem 1.5rem 2.5rem;
}

/* Liste / tableaux : toute la largeur utile à droite du menu */
.secure-main--centered.secure-main--wide {
  display: block;
  padding: 1.75rem 2rem 2.5rem;
}

.secure-main--wide .secure-list-wrap {
  width: 100%;
  max-width: none;
  margin: 0;
}

.secure-list-wrap .secure-panel {
  width: 100%;
  padding: 2rem 2.25rem;
  min-height: min(70vh, 640px);
}

.secure-list-wrap h1,
.secure-list-wrap .secure-meta {
  text-align: left;
}

/* Création d’identifiant : panneau plus large qu’avant */
.secure-form-wrap {
  width: 100%;
  max-width: 720px;
  margin: 0 auto;
}

.secure-form-wrap:not(.secure-list-wrap) .secure-panel {
  padding: 2rem 2.25rem;
}

.secure-form-wrap .secure-panel {
  width: 100%;
}

.secure-form-wrap:not(.secure-list-wrap) h1,
.secure-form-wrap:not(.secure-list-wrap) .secure-meta {
  text-align: center;
}

.secure-form-wrap:not(.secure-list-wrap) .secure-meta {
  margin-bottom: 0.25rem;
}

.secure-panel-wide {
  max-width: 42rem;
}

.btn-primary-inline {
  min-width: unset;
}

.marshal-form {
  margin-top: 1.5rem;
}

.marshal-form-stack .form-two {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

@media (max-width: 640px) {
  .marshal-form-stack .form-two {
    grid-template-columns: 1fr;
  }
}

.secure-form-actions {
  display: flex;
  justify-content: center;
  margin-top: 1.75rem;
}

/* Liste des marshal */
.marshal-search {
  margin: 1.25rem 0 1.5rem;
}

.marshal-search-field {
  margin-bottom: 0;
  max-width: 480px;
}

.marshal-table-wrap {
  overflow-x: auto;
  margin-top: 0.5rem;
}

.marshal-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.85rem;
}

.marshal-table th,
.marshal-table td {
  padding: 0.65rem 0.75rem;
  text-align: left;
  border-bottom: 1px solid rgba(212, 175, 55, 0.15);
}

.marshal-table th {
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
  background: rgba(10, 22, 40, 0.5);
}

.marshal-table tbody tr:hover {
  background: rgba(212, 175, 55, 0.05);
}

.marshal-table-empty {
  text-align: center;
  color: var(--text-soft);
  padding: 2rem 1rem !important;
}

.marshal-table-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem;
  white-space: nowrap;
}

.marshal-inline-form {
  display: inline;
  margin: 0;
}

.btn-danger-ghost {
  color: #ff9a9a;
  border-color: rgba(255, 120, 120, 0.35);
}

.btn-danger-ghost:hover {
  color: #fff;
  background: rgba(160, 40, 40, 0.45);
  border-color: rgba(255, 120, 120, 0.55);
}

.marshal-muted {
  color: rgba(232, 234, 240, 0.35);
  font-size: 0.85rem;
}

.marshal-optional {
  font-weight: 400;
  text-transform: none;
  letter-spacing: 0;
  color: var(--text-soft);
  font-size: 0.75rem;
}

.marshal-hint {
  margin: 0.35rem 0 0;
  font-size: 0.72rem;
  color: var(--text-soft);
}

.marshal-ring-readonly {
  margin: 0.25rem 0 0;
  font-size: 1rem;
  font-weight: 600;
  color: var(--gold);
}

.audit-log-filter {
  margin-bottom: 0.75rem;
}

.audit-log-filter select {
  width: 100%;
  max-width: 22rem;
}

.audit-log-count {
  margin: 0 0 0.75rem;
}

.audit-log-date {
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.audit-log-table td:nth-child(4) {
  max-width: 28rem;
  word-break: break-word;
}

.audit-badge {
  display: inline-block;
  padding: 0.2rem 0.5rem;
  border-radius: 3px;
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  background: rgba(201, 162, 39, 0.15);
  color: var(--gold);
  border: 1px solid rgba(201, 162, 39, 0.35);
}

.audit-badge--user-create,
.audit-badge--user-update,
.audit-badge--user-delete {
  background: rgba(80, 140, 220, 0.15);
  border-color: rgba(100, 160, 240, 0.4);
  color: #9ec5ff;
}

.audit-badge--suspect-create,
.audit-badge--suspect-update,
.audit-badge--suspect-delete {
  background: rgba(180, 90, 60, 0.18);
  border-color: rgba(220, 120, 80, 0.4);
  color: #f0b090;
}

.audit-badge--report-create,
.audit-badge--report-update,
.audit-badge--report-delete {
  background: rgba(100, 180, 120, 0.15);
  border-color: rgba(120, 200, 140, 0.4);
  color: #a8e0b8;
}

.audit-badge--mail-send {
  background: rgba(160, 120, 200, 0.15);
  border-color: rgba(180, 140, 220, 0.4);
  color: #d4b8f0;
}

.audit-badge--auth-login {
  background: rgba(120, 120, 130, 0.2);
  border-color: rgba(160, 160, 170, 0.35);
  color: rgba(232, 234, 240, 0.85);
}

.audit-log-pagination {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.5rem 0.65rem;
  margin: 0.75rem 0 1rem;
}

.audit-log-count-pages {
  color: var(--text-soft);
}

.audit-log-page-nums {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.25rem;
}

.audit-log-page-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2rem;
  height: 2rem;
  padding: 0 0.4rem;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-main);
  text-decoration: none;
  border: 1px solid var(--border-rule);
  border-radius: 3px;
  background: rgba(0, 0, 0, 0.2);
}

.audit-log-page-num:hover {
  border-color: var(--gold);
  color: var(--gold);
}

.audit-log-page-num.is-current {
  background: rgba(201, 162, 39, 0.2);
  border-color: var(--gold);
  color: var(--gold);
  cursor: default;
}

.audit-log-page-ellipsis {
  padding: 0 0.35rem;
  color: var(--text-soft);
  font-size: 0.85rem;
}

.audit-log-page-nav.is-disabled {
  opacity: 0.35;
  pointer-events: none;
}

.marshal-dialog {
  width: min(720px, calc(100vw - 2rem));
  max-height: calc(100vh - 2rem);
  padding: 0;
  border: 1px solid var(--border-rule);
  border-top: 4px solid var(--gold);
  background: var(--navy-mid);
  color: var(--text-main);
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.55);
}

.marshal-dialog::backdrop {
  background: rgba(0, 0, 0, 0.65);
}

.marshal-dialog-form {
  padding: 2rem 2.25rem 1.75rem;
}

.marshal-dialog-form h2 {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 400;
  margin: 0 0 1.25rem;
}

.marshal-dialog-actions {
  display: flex;
  justify-content: flex-end;
  gap: 0.75rem;
  margin-top: 1.5rem;
}

@media (max-width: 720px) {
  .secure-app {
    flex-direction: column;
  }

  .secure-sidebar {
    width: 100%;
    border-right: none;
    border-bottom: 1px solid rgba(212, 175, 55, 0.22);
  }

  .secure-sidebar.is-collapsed {
    width: 100%;
  }

  .secure-sidebar.is-collapsed .secure-nav-label {
    opacity: 1;
    max-width: none;
    pointer-events: auto;
  }

  .secure-sidebar.is-collapsed .secure-nav-row {
    flex-direction: row;
  }

  .secure-main {
    padding: 1rem 1rem 2rem;
  }
}

.secure-banner {
  display: inline-block;
  font-size: 0.62rem;
  letter-spacing: 0.42em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.75rem;
}

.secure-panel {
  padding: 1.75rem 1.75rem;
  background: var(--bg-panel);
  border: 1px solid var(--border-rule);
  border-top: 4px solid var(--gold);
  box-shadow: 0 24px 48px rgba(0, 0, 0, 0.35);
}

.secure-panel h1 {
  font-family: var(--font-display);
  font-size: 1.65rem;
  font-weight: 400;
  margin: 0 0 0.75rem;
}

.secure-status {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8rem;
  color: var(--text-soft);
  margin-bottom: 1.25rem;
}

.secure-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #2ecc71;
  box-shadow: 0 0 10px rgba(46, 204, 113, 0.6);
}

.secure-meta {
  font-size: 0.82rem;
  line-height: 1.65;
  color: var(--text-soft);
  margin: 0;
}

/* ---------- Contenu plein écran centré ---------- */
.hero {
  min-height: calc(100vh - 88px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2rem 1.5rem 4rem;
  text-align: center;
}

.hero-inner {
  max-width: 36rem;
  padding: 2.5rem 2rem;
  background: var(--bg-panel);
  border: 1px solid var(--border-rule);
  border-top: 4px solid var(--gold);
  box-shadow:
    0 0 0 1px rgba(0, 0, 0, 0.2),
    0 24px 48px rgba(0, 0, 0, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.hero-frame {
  position: relative;
}

.hero-frame::before,
.hero-frame::after {
  content: "";
  position: absolute;
  width: 12px;
  height: 12px;
  border-color: var(--gold-muted);
  border-style: solid;
  pointer-events: none;
}

.hero-frame::before {
  top: -6px;
  left: -6px;
  border-width: 2px 0 0 2px;
}

.hero-frame::after {
  bottom: -6px;
  right: -6px;
  border-width: 0 2px 2px 0;
}

.hero-kicker {
  font-size: 0.7rem;
  letter-spacing: 0.35em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 1rem;
}

.hero h1 {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 4vw, 2rem);
  font-weight: 400;
  letter-spacing: 0.02em;
  margin: 0 0 0.75rem;
  line-height: 1.3;
}

.hero-lead {
  font-size: 0.95rem;
  color: var(--text-soft);
  line-height: 1.6;
  margin: 0 0 2rem;
}

/* Boutons */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 200px;
  padding: 0.85rem 2rem;
  font-family: var(--font-ui);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--bg-deep);
  background: linear-gradient(180deg, var(--gold-bright) 0%, #a67c00 100%);
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 2px;
  cursor: pointer;
  box-shadow:
    0 2px 0 rgba(0, 0, 0, 0.35),
    0 4px 12px rgba(0, 0, 0, 0.25);
  transition: transform 0.12s ease, box-shadow 0.12s ease, filter 0.12s ease;
}

.btn-primary:hover {
  filter: brightness(1.08);
  box-shadow:
    0 2px 0 rgba(0, 0, 0, 0.35),
    0 6px 20px rgba(212, 175, 55, 0.25);
}

.btn-primary:active {
  transform: translateY(1px);
}

.btn-primary:focus-visible {
  outline: 2px solid var(--gold-bright);
  outline-offset: 3px;
}

/* Pied de page */
.site-footer {
  padding: 1rem 1.5rem;
  text-align: center;
  font-size: 0.7rem;
  letter-spacing: 0.06em;
  color: rgba(232, 234, 240, 0.4);
  border-top: 1px solid rgba(212, 175, 55, 0.15);
  background: rgba(10, 22, 40, 0.6);
}

/* ---------- Page connexion ---------- */
.auth-layout {
  min-height: calc(100vh - 88px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem 1.5rem 3rem;
}

.auth-card {
  width: 100%;
  max-width: 420px;
  padding: 2rem 2rem 2.25rem;
  background: var(--bg-panel);
  border: 1px solid var(--border-rule);
  border-top: 4px solid var(--gold);
  box-shadow: 0 24px 48px rgba(0, 0, 0, 0.35);
}

.auth-card h1 {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 400;
  margin: 0 0 0.35rem;
  text-align: center;
}

.auth-card .auth-sub {
  text-align: center;
  font-size: 0.8rem;
  color: var(--text-soft);
  margin: 0 0 1.75rem;
}

.form-group {
  margin-bottom: 1.15rem;
}

.form-group label {
  display: block;
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.4rem;
}

.form-group input {
  width: 100%;
  padding: 0.65rem 0.75rem;
  font-size: 1rem;
  font-family: var(--font-ui);
  color: var(--text-main);
  background: rgba(10, 22, 40, 0.85);
  border: 1px solid rgba(212, 175, 55, 0.25);
  border-radius: 2px;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.form-group input::placeholder {
  color: rgba(232, 234, 240, 0.35);
}

.form-group input:focus {
  outline: none;
  border-color: var(--gold-bright);
  box-shadow: 0 0 0 1px rgba(212, 175, 55, 0.25);
}

.form-group select {
  width: 100%;
  padding: 0.65rem 0.75rem;
  font-size: 1rem;
  font-family: var(--font-ui);
  color: var(--text-main);
  background: rgba(10, 22, 40, 0.85);
  border: 1px solid rgba(212, 175, 55, 0.25);
  border-radius: 2px;
  cursor: pointer;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.form-group select:focus {
  outline: none;
  border-color: var(--gold-bright);
  box-shadow: 0 0 0 1px rgba(212, 175, 55, 0.25);
}

.auth-actions {
  margin-top: 1.5rem;
}

.auth-actions .btn-primary {
  width: 100%;
  min-width: unset;
}

.back-link {
  display: block;
  text-align: center;
  margin-top: 1.25rem;
  font-size: 0.8rem;
  color: var(--text-soft);
}

.back-link a {
  font-weight: 500;
}

.auth-notice {
  margin-top: 1.75rem;
  padding-top: 1.25rem;
  border-top: 1px solid rgba(212, 175, 55, 0.15);
  font-size: 0.72rem;
  line-height: 1.45;
  color: rgba(232, 234, 240, 0.5);
  text-align: center;
}

/* ---------- Mailbox sécurisée ---------- */
.mailbox-page-wrap {
  max-width: none;
}

.mailbox-page-wrap.secure-list-wrap .secure-panel.mailbox-panel {
  padding: 2.25rem 2.5rem 2.75rem;
}

.mailbox-panel {
  width: 100%;
  min-height: min(70vh, 680px);
}

.mailbox-header {
  margin-bottom: 2rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid rgba(212, 175, 55, 0.25);
}

.mailbox-header-title {
  display: flex;
  align-items: flex-start;
  gap: 1.25rem;
}

.mailbox-header-icon {
  font-size: 1.65rem;
  line-height: 1;
  color: var(--gold-bright);
  margin-top: 0.15rem;
}

.mailbox-header h1 {
  font-family: var(--font-display);
  font-size: 1.45rem;
  font-weight: 400;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin: 0 0 0.5rem;
  color: var(--gold-bright);
}

.mailbox-header-sub {
  margin: 0;
  font-size: 0.8rem;
  line-height: 1.5;
  color: var(--text-soft);
  letter-spacing: 0.02em;
}

.mailbox-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin-bottom: 2rem;
}

.mailbox-tab {
  display: inline-flex;
  align-items: center;
  padding: 0.65rem 1.25rem;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--text-soft);
  background: rgba(13, 28, 48, 0.5);
  border: 1px solid rgba(212, 175, 55, 0.18);
  border-radius: 2px;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.mailbox-tab:hover {
  color: var(--text-main);
  border-color: var(--gold-muted);
}

.mailbox-tab.is-active {
  color: var(--text-main);
  background: rgba(212, 175, 55, 0.12);
  border-color: var(--gold-bright);
}

.mailbox-tab-new {
  color: var(--bg-deep);
  background: linear-gradient(180deg, var(--gold-bright) 0%, #a67c00 100%);
  border-color: rgba(255, 255, 255, 0.2);
}

.mailbox-tab-new.is-active,
.mailbox-tab-new:hover {
  color: var(--bg-deep);
  filter: brightness(1.05);
}

.mailbox-flash {
  margin: 0 0 1.5rem;
}

.mailbox-layout {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 2.25rem;
  align-items: start;
}

.mailbox-status-panel {
  padding: 1.5rem 1.35rem;
  background: rgba(10, 22, 40, 0.45);
  border: 1px solid rgba(212, 175, 55, 0.15);
  border-top: 2px solid var(--gold);
  border-radius: 2px;
}

.mailbox-status-title {
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold);
  margin: 0 0 1.35rem;
}

.mailbox-status-list {
  list-style: none;
  margin: 0 0 1.75rem;
  padding: 0;
}

.mailbox-status-list li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: 0.75rem 0;
  font-size: 0.85rem;
  line-height: 1.4;
  color: var(--text-soft);
  border-bottom: 1px solid rgba(212, 175, 55, 0.08);
}

.mailbox-status-list li:last-child {
  border-bottom: none;
}

.mailbox-badge-unread {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.5rem;
  padding: 0.15rem 0.45rem;
  font-size: 0.75rem;
  color: #fff;
  background: #c0392b;
  border-radius: 999px;
  box-shadow: 0 0 10px rgba(192, 57, 43, 0.45);
}

.mailbox-warning {
  display: flex;
  gap: 0.65rem;
  margin: 0;
  padding: 0.85rem 1rem;
  font-size: 0.75rem;
  line-height: 1.55;
  color: var(--gold-bright);
  background: rgba(184, 134, 11, 0.08);
  border: 1px solid rgba(212, 175, 55, 0.22);
  border-radius: 2px;
}

.mailbox-content-panel {
  padding: 0.25rem 0.5rem 0 0;
  min-height: 280px;
  background: transparent;
  border: none;
  box-shadow: none;
}

.mailbox-content-title {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 400;
  margin: 0 0 1.75rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-main);
}

.mailbox-content-panel > .secure-meta {
  margin: -1rem 0 2rem;
  line-height: 1.55;
}

.mail-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.mail-item {
  display: block;
  padding: 1.35rem 1.5rem;
  text-decoration: none;
  color: inherit;
  background: rgba(10, 22, 40, 0.4);
  border: 1px solid rgba(212, 175, 55, 0.12);
  border-radius: 2px;
  transition: border-color 0.15s ease, background 0.15s ease;
}

.mail-item:hover {
  border-color: var(--gold-bright);
  background: rgba(212, 175, 55, 0.06);
}

.mail-item--unread {
  border-color: rgba(212, 175, 55, 0.45);
  box-shadow: inset 3px 0 0 var(--gold-bright);
}

.mail-item-read {
  border-color: rgba(212, 175, 55, 0.35);
}

.mail-item-head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-start;
  gap: 0.85rem 1.25rem;
  margin-bottom: 0.85rem;
}

.mail-item-from {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: none;
  color: var(--text-main);
}

.mail-unread-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--gold-bright);
  box-shadow: 0 0 8px rgba(212, 175, 55, 0.6);
}

.mail-item-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.mail-badge {
  font-size: 0.58rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.2rem 0.5rem;
  border-radius: 2px;
  border: 1px solid transparent;
}

.mail-badge-class-standard {
  color: var(--text-soft);
  border-color: rgba(232, 234, 240, 0.25);
  background: rgba(10, 22, 40, 0.5);
}

.mail-badge-class-confidentiel {
  color: #fcdcdc;
  border-color: rgba(255, 120, 120, 0.5);
  background: rgba(139, 0, 0, 0.35);
}

.mail-badge-class-restreint {
  color: #ffe9b0;
  border-color: rgba(212, 175, 55, 0.55);
  background: rgba(184, 134, 11, 0.25);
}

.mail-badge-priority {
  color: #fff;
  border-color: rgba(255, 80, 80, 0.6);
  background: rgba(180, 30, 30, 0.55);
  box-shadow: 0 0 8px rgba(255, 80, 80, 0.25);
}

.mail-item-subject {
  margin: 0 0 0.65rem;
  font-size: 1.05rem;
  font-weight: 500;
  line-height: 1.4;
  color: var(--text-main);
}

.mail-item-date {
  margin: 0;
  font-size: 0.75rem;
  color: var(--text-soft);
  opacity: 0.85;
}

.mail-item-body {
  margin-top: 1.75rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(212, 175, 55, 0.12);
  font-size: 0.95rem;
  line-height: 1.75;
  color: var(--text-main);
}

.mailbox-read-actions {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  margin-top: 1.25rem;
}

.mailbox-read-actions .mailbox-inline-form {
  margin: 0;
  display: flex;
  flex: 0 0 auto;
}

.mailbox-read-actions .mailbox-action-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  min-height: 1.85rem;
  padding: 0.3rem 0.65rem;
  font-size: 0.78rem;
  line-height: 1.2;
  text-decoration: none;
  white-space: nowrap;
}

.mailbox-list-meta {
  margin-bottom: 0.5rem;
}

.mailbox-pagination {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.5rem 0.65rem;
  margin: 0.75rem 0 1rem;
}

.mailbox-page-nums {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.25rem;
}

.mailbox-page-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2rem;
  height: 2rem;
  padding: 0 0.4rem;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-main);
  text-decoration: none;
  border: 1px solid var(--border-rule);
  border-radius: 3px;
  background: rgba(0, 0, 0, 0.2);
}

.mailbox-page-num:hover {
  border-color: var(--gold);
  color: var(--gold);
}

.mailbox-page-num.is-current {
  background: rgba(201, 162, 39, 0.2);
  border-color: var(--gold);
  color: var(--gold);
}

.mailbox-page-ellipsis {
  padding: 0 0.35rem;
  color: var(--text-soft);
}

.mailbox-page-nav.is-disabled {
  opacity: 0.35;
  pointer-events: none;
}

.mailbox-compose-form {
  max-width: 640px;
}

.mailbox-compose-form .form-group {
  margin-bottom: 1.5rem;
}

.mailbox-compose-form .form-two {
  gap: 1.5rem;
  margin-bottom: 0.25rem;
}

.mailbox-compose-form select,
.mailbox-compose-form input {
  margin-top: 0.15rem;
}

.mailbox-recipients-hint {
  margin: 0.35rem 0 0.5rem;
  font-size: 0.85rem;
  color: var(--text-muted);
  line-height: 1.45;
}

.mailbox-recipients-hint kbd {
  padding: 0.1rem 0.35rem;
  font-size: 0.8rem;
  font-family: var(--font-ui);
  background: rgba(10, 22, 40, 0.6);
  border: 1px solid rgba(212, 175, 55, 0.25);
  border-radius: 2px;
}

.mailbox-compose-form select {
  color-scheme: dark;
}

.mailbox-recipients-select {
  width: 100%;
  padding: 0.5rem 0.65rem;
  color: var(--text-main);
  background-color: rgba(10, 22, 40, 0.95);
  border: 1px solid rgba(212, 175, 55, 0.3);
  font-size: 0.95rem;
  line-height: 1.45;
}

.mailbox-recipients-select:not(:focus) {
  overflow: hidden;
}

.mailbox-recipients-select:focus {
  border-color: var(--gold-bright);
  box-shadow: 0 0 0 1px rgba(212, 175, 55, 0.25);
}

.mailbox-recipients-select option {
  color: var(--text-main);
  background-color: #132238;
  padding: 0.35rem 0.5rem;
}

.mailbox-recipients-select option:checked {
  background-color: #2d4f73;
  color: #ffffff;
  font-weight: 600;
}

.mailbox-compose-form textarea {
  width: 100%;
  min-height: 180px;
  margin-top: 0.15rem;
  padding: 0.85rem 1rem;
  font-size: 1rem;
  line-height: 1.55;
  font-family: var(--font-ui);
  color: var(--text-main);
  background: rgba(10, 22, 40, 0.5);
  border: 1px solid rgba(212, 175, 55, 0.2);
  border-radius: 2px;
  resize: vertical;
}

.mailbox-compose-form textarea:focus {
  outline: none;
  border-color: var(--gold-bright);
  box-shadow: 0 0 0 1px rgba(212, 175, 55, 0.2);
}

.mailbox-compose-actions {
  justify-content: flex-end;
  gap: 1rem;
  margin-top: 2.25rem;
  padding-top: 0.5rem;
}

.mailbox-back {
  margin-top: 2rem;
}

.marshal-table-empty {
  padding: 2.5rem 1rem;
  line-height: 1.5;
  color: var(--text-soft);
}

@media (max-width: 900px) {
  .mailbox-layout {
    grid-template-columns: 1fr;
  }
}

/* ---------- Tableau de bord ---------- */
.dashboard-wrap {
  max-width: none;
  margin: 0;
  width: 100%;
}

.dashboard-wrap .dashboard-panel {
  width: 100%;
  padding: 2.25rem 2.75rem 3rem;
  min-height: min(70vh, 640px);
}

.dashboard-wrap .dashboard-header h1,
.dashboard-wrap .dashboard-header .secure-meta {
  text-align: left;
}

.dashboard-header {
  margin-bottom: 2rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid rgba(212, 175, 55, 0.2);
}

.dashboard-header h1 {
  margin: 0 0 0.35rem;
  font-family: var(--font-display);
  font-size: 1.65rem;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.dashboard-profile {
  margin-bottom: 2.5rem;
  padding: 2.75rem 3.5rem;
  min-height: 12rem;
  width: 100%;
  box-sizing: border-box;
  background: rgba(10, 22, 40, 0.5);
  border: 1px solid rgba(212, 175, 55, 0.22);
  border-radius: 2px;
}

.dashboard-profile-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 2rem 4rem;
  margin: 0;
  width: 100%;
}

@media (min-width: 900px) {
  .dashboard-profile {
    padding: 3rem 4.5rem;
  }

  .dashboard-profile-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 2.5rem 3.5rem;
  }
}

.dashboard-profile-item {
  margin: 0;
  padding: 0.5rem 0;
}

.dashboard-profile-item dt {
  margin: 0 0 0.65rem;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gold-bright);
  opacity: 0.9;
}

.dashboard-profile-item dd {
  margin: 0;
  font-size: 1.45rem;
  font-weight: 500;
  line-height: 1.3;
  color: var(--text-main);
}

.dashboard-ring {
  display: inline-block;
  padding: 0.35rem 1rem;
  font-size: 1.15rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--gold-bright);
  background: rgba(212, 175, 55, 0.12);
  border: 1px solid rgba(212, 175, 55, 0.4);
  border-radius: 2px;
}

.dashboard-matricule {
  font-size: 1.25rem;
  color: var(--gold-bright);
  letter-spacing: 0.08em;
}

.dashboard-stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(14rem, 1fr));
  gap: 1.25rem;
}

.dashboard-stat-card {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  padding: 1.5rem 1.65rem;
  text-decoration: none;
  color: inherit;
  background: rgba(10, 22, 40, 0.4);
  border: 1px solid rgba(212, 175, 55, 0.15);
  border-radius: 2px;
  transition: border-color 0.15s ease, background 0.15s ease, transform 0.15s ease;
}

.dashboard-stat-card:hover {
  border-color: rgba(212, 175, 55, 0.45);
  background: rgba(212, 175, 55, 0.06);
  transform: translateY(-1px);
}

.dashboard-stat-card--alert {
  border-color: rgba(212, 175, 55, 0.45);
  box-shadow: inset 3px 0 0 var(--gold-bright);
}

.dashboard-stat-label {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--gold-bright);
}

.dashboard-stat-value {
  font-family: var(--font-display);
  font-size: 2.5rem;
  font-weight: 400;
  line-height: 1.1;
  color: var(--text-main);
}

.dashboard-stat-hint {
  font-size: 0.78rem;
  color: var(--text-muted, rgba(200, 210, 225, 0.65));
  margin-top: 0.25rem;
}

/* Fiche agent (liste marshal) */
.marshal-view-wrap .marshal-view-panel {
  padding: 2rem 2.25rem 3rem;
}

.marshal-view-header {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 1rem 1.5rem;
  margin-bottom: 2rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid rgba(212, 175, 55, 0.2);
}

.marshal-view-heading {
  flex: 1 1 12rem;
  min-width: 0;
}

.marshal-view-heading h1 {
  margin: 0 0 0.35rem;
  font-family: var(--font-display);
  font-size: 1.65rem;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.marshal-view-profile {
  margin-bottom: 2.5rem;
}

.marshal-view-profile .report-section-title {
  margin: 0 0 1.25rem;
}

.marshal-view-reports {
  margin-bottom: 2.5rem;
}

.marshal-view-reports .report-section-title {
  margin: 0 0 0.5rem;
}

.marshal-view-reports .report-section-hint {
  margin: 0 0 1rem;
}

/* ---------- Rapports opérationnels ---------- */
.report-page-wrap .secure-panel.report-panel {
  padding: 2.25rem 2.5rem 3rem;
  overflow: visible;
}

.report-page-wrap {
  overflow: visible;
}

.report-page-header {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1.25rem 2rem;
  margin-bottom: 2rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid rgba(212, 175, 55, 0.2);
}

.report-page-header h1 {
  margin: 0 0 0.35rem;
}

.report-form {
  margin-top: 0.5rem;
}

.report-section {
  margin-bottom: 2.75rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid rgba(212, 175, 55, 0.1);
}

.report-section:last-of-type {
  border-bottom: none;
  margin-bottom: 1rem;
}

.report-section-title {
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 400;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--gold-bright);
  margin: 0 0 1.25rem;
}

.report-section-hint {
  margin: -0.75rem 0 1.25rem;
  font-size: 0.8rem;
  line-height: 1.5;
  color: var(--text-soft);
}

.form-three {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}

@media (max-width: 900px) {
  .form-three {
    grid-template-columns: 1fr;
  }
}

.form-two--triple {
  grid-template-columns: 1fr 1fr auto;
  align-items: end;
}

@media (max-width: 768px) {
  .form-two--triple {
    grid-template-columns: 1fr;
  }
}

.report-form .form-group textarea,
.report-form textarea {
  width: 100%;
  min-height: 120px;
  margin-top: 0.2rem;
  padding: 0.85rem 1rem;
  font-size: 0.95rem;
  line-height: 1.55;
  font-family: var(--font-ui);
  color: var(--text-main);
  background: rgba(10, 22, 40, 0.5);
  border: 1px solid rgba(212, 175, 55, 0.2);
  border-radius: 2px;
  resize: vertical;
}

.report-form textarea:focus {
  outline: none;
  border-color: var(--gold-bright);
  box-shadow: 0 0 0 1px rgba(212, 175, 55, 0.2);
}

.report-form .form-group input[type="file"] {
  margin-top: 0.35rem;
  font-size: 0.85rem;
  color: var(--text-soft);
}

.input-with-action {
  display: flex;
  gap: 0.65rem;
  align-items: stretch;
}

.input-with-action input {
  flex: 1;
}

.btn-inline {
  flex-shrink: 0;
  align-self: stretch;
  padding: 0.5rem 0.85rem;
  font-size: 0.72rem;
}

/* Agents : recherche + puces en ligne */
.report-agent-panel {
  width: 100%;
}

.report-agent-panel .marshal-search-field {
  max-width: 420px;
  margin-bottom: 0.75rem;
}

.report-agent-count {
  margin: 0 0 0.75rem;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--gold);
}

.report-agent-pick-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  list-style: none;
  margin: 0;
  padding: 0.85rem;
  max-height: none;
  overflow: visible;
  border: 1px solid rgba(212, 175, 55, 0.2);
  border-radius: 2px;
  background: rgba(10, 22, 40, 0.45);
}

.report-agent-pick-li {
  flex: 0 1 auto;
  margin: 0;
}

.report-agent-pick-li.is-filtered-out {
  display: none !important;
}

.report-agent-empty {
  margin: 0.65rem 0 0;
  padding: 0 0.85rem 0.85rem;
  font-size: 0.82rem;
  color: var(--gold-bright);
}

.report-agent-pick-item {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.45rem 0.75rem;
  font-size: 0.8rem;
  line-height: 1.3;
  white-space: nowrap;
  color: var(--text-main);
  background: rgba(13, 28, 48, 0.75);
  border: 1px solid rgba(212, 175, 55, 0.22);
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.12s ease, border-color 0.12s ease, box-shadow 0.12s ease;
  user-select: none;
}

.report-agent-pick-item:hover {
  border-color: rgba(212, 175, 55, 0.45);
  background: rgba(13, 28, 48, 0.95);
}

.report-agent-pick-item.is-selected {
  background: rgba(184, 134, 11, 0.28);
  border-color: var(--gold-bright);
  box-shadow: 0 0 0 1px rgba(212, 175, 55, 0.35);
  color: var(--text-main);
}

.report-agent-pick-item input {
  position: relative;
  z-index: 1;
  flex-shrink: 0;
  width: 0.95rem;
  height: 0.95rem;
  margin: 0;
  accent-color: var(--gold-bright);
  cursor: pointer;
}

.report-agent-pick-item span {
  pointer-events: none;
}

.report-field-textarea {
  width: 100%;
  max-width: 720px;
  min-height: 7rem;
  padding: 0.85rem 1rem;
  font-size: 0.92rem;
  line-height: 1.6;
  font-family: var(--font-ui);
  color: var(--text-main);
  background: rgba(10, 22, 40, 0.45);
  border: 1px solid rgba(212, 175, 55, 0.18);
  border-radius: 2px;
  resize: vertical;
}

.report-field-textarea--tall {
  min-height: 12rem;
}

.report-field-textarea:focus {
  outline: none;
  border-color: var(--gold-bright);
  box-shadow: 0 0 0 1px rgba(212, 175, 55, 0.2);
}

.report-checkbox-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 0.75rem;
  max-height: 280px;
  overflow-y: auto;
  padding: 0.5rem;
  background: rgba(10, 22, 40, 0.35);
  border: 1px solid rgba(212, 175, 55, 0.12);
  border-radius: 2px;
}

.report-checkbox-grid--compact {
  max-height: 200px;
}

.report-check-card {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  padding: 0.75rem 0.85rem;
  font-size: 0.82rem;
  line-height: 1.4;
  color: var(--text-main);
  background: rgba(13, 28, 48, 0.5);
  border: 1px solid rgba(212, 175, 55, 0.12);
  border-radius: 2px;
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease;
}

.report-check-card:hover {
  border-color: rgba(212, 175, 55, 0.35);
  background: rgba(13, 28, 48, 0.75);
}

.report-check-card input {
  margin-top: 0.2rem;
  accent-color: var(--gold);
}

.report-section--compact {
  margin-bottom: 2rem;
  padding-bottom: 1.5rem;
}

.report-section--compact .report-section-title {
  margin-bottom: 0.65rem;
}

.report-section--compact .report-section-hint {
  margin: -0.35rem 0 0.85rem;
}

.suspect-table-head,
.suspect-row--compact {
  display: grid;
  grid-template-columns: 1.4fr 0.9fr 1.6fr 2.25rem;
  gap: 0.5rem;
  align-items: center;
}

.suspect-table-head {
  max-width: 720px;
  margin-bottom: 0.35rem;
  padding: 0 0.15rem;
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gold);
}

.suspect-rows-compact {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  width: 100%;
  max-width: 100%;
  margin-bottom: 0.85rem;
}

.suspect-row--compact input[type="text"] {
  width: 100%;
  min-width: 0;
  padding: 0.55rem 0.65rem;
  font-size: 0.9rem;
  font-family: var(--font-ui);
  color: var(--text-main);
  background: rgba(10, 22, 40, 0.85);
  border: 1px solid rgba(212, 175, 55, 0.3);
  border-radius: 2px;
  box-sizing: border-box;
}

.suspect-row--compact input[type="text"]:focus {
  outline: none;
  border-color: var(--gold-bright);
}

.suspect-row--compact .btn-icon {
  min-width: 2.25rem;
  padding: 0.35rem 0;
  font-size: 1.1rem;
  line-height: 1;
}

@media (max-width: 640px) {
  .suspect-table-head {
    display: none;
  }

  .suspect-row--compact {
    grid-template-columns: 1fr 1fr auto;
    grid-template-rows: auto auto;
    gap: 0.4rem;
    padding: 0.5rem 0;
    border-bottom: 1px solid rgba(212, 175, 55, 0.08);
  }

  .suspect-row--compact input:nth-child(3) {
    grid-column: 1 / 3;
  }
}

.report-repeat-row {
  padding: 1.25rem 1.35rem;
  margin-bottom: 1rem;
  background: rgba(10, 22, 40, 0.35);
  border: 1px solid rgba(212, 175, 55, 0.1);
  border-radius: 2px;
}

.report-repeat-actions {
  display: flex;
  align-items: flex-end;
  padding-bottom: 0.15rem;
}

.report-form-actions {
  justify-content: flex-end;
  margin-top: 2rem;
}

.report-section--box {
  padding: 1.35rem 1.5rem;
  background: rgba(10, 22, 40, 0.45);
  border: 1px solid rgba(212, 175, 55, 0.22);
  border-radius: 2px;
}

.report-section--box .report-field-textarea {
  max-width: 100%;
}

.report-individuals-box,
.report-photos-box {
  margin-top: 0.5rem;
}

.report-photos-upload {
  margin-bottom: 1rem;
}

.report-form .report-file-input,
.report-file-input {
  display: block;
  width: 100%;
  max-width: 100%;
  padding: 0.65rem;
  font-size: 0.88rem;
  color: var(--text-main);
  background: rgba(10, 22, 40, 0.85);
  border: 1px solid rgba(212, 175, 55, 0.35);
  border-radius: 2px;
  cursor: pointer;
}

.report-form .report-file-input::file-selector-button,
.report-file-input::file-selector-button {
  margin-right: 0.85rem;
  padding: 0.45rem 0.75rem;
  font-family: var(--font-ui);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-main);
  background: rgba(184, 134, 11, 0.35);
  border: 1px solid rgba(212, 175, 55, 0.45);
  border-radius: 2px;
  cursor: pointer;
}

.photo-preview-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 1rem;
  margin-top: 1.25rem;
  max-width: 720px;
}

.photo-preview-item {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.photo-preview-item img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border: 1px solid rgba(212, 175, 55, 0.2);
  border-radius: 2px;
  background: rgba(0, 0, 0, 0.3);
}

.photo-caption-input {
  width: 100%;
  padding: 0.45rem 0.55rem;
  font-size: 0.78rem;
  color: var(--text-main);
  background: rgba(10, 22, 40, 0.6);
  border: 1px solid rgba(212, 175, 55, 0.18);
  border-radius: 2px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Vue rapport */
.report-back-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 2.5rem;
  height: 2.5rem;
  margin-top: 0.15rem;
  border: 1px solid rgba(212, 175, 55, 0.35);
  border-radius: 2px;
  color: var(--gold-bright);
  text-decoration: none;
  font-size: 1.35rem;
  line-height: 1;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.report-back-btn:hover {
  background: rgba(212, 175, 55, 0.08);
  border-color: rgba(212, 175, 55, 0.55);
}

.report-page-header--with-back {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
}

.report-view-header {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 1rem 1.5rem;
  margin-bottom: 2rem;
}

.report-view-heading {
  flex: 1 1 12rem;
  min-width: 0;
}

.report-view-ref code {
  font-size: 0.85rem;
  color: var(--gold-bright);
  letter-spacing: 0.04em;
}

.report-view-header h1 {
  margin: 0.35rem 0 0.5rem;
  font-family: var(--font-display);
  font-size: 1.65rem;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.report-view-actions {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  flex-wrap: wrap;
  margin-left: auto;
}

.report-delete-form {
  margin: 0;
  display: inline;
}

.btn-ghost-danger {
  color: #e8a0a0;
  border-color: rgba(232, 160, 160, 0.35);
}

.btn-ghost-danger:hover {
  background: rgba(180, 60, 60, 0.15);
  border-color: rgba(232, 160, 160, 0.55);
  color: #f5c4c4;
}

.report-edit-photo-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.report-edit-photo {
  margin: 0;
  width: 6.5rem;
  height: 6.5rem;
  overflow: hidden;
  border: 1px solid rgba(212, 175, 55, 0.2);
  border-radius: 2px;
}

.report-edit-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.report-view-grid {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.report-view-block {
  padding: 1.35rem 1.5rem;
  background: rgba(10, 22, 40, 0.35);
  border: 1px solid rgba(212, 175, 55, 0.1);
  border-radius: 2px;
}

.report-dl {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 0.65rem 1.25rem;
  margin: 0;
  font-size: 0.9rem;
}

.report-dl dt {
  color: var(--gold);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.report-dl dd {
  margin: 0;
  color: var(--text-main);
}

.report-prose {
  font-size: 0.95rem;
  line-height: 1.75;
  color: var(--text-main);
}

.report-subheading {
  margin: 1.5rem 0 0.75rem;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gold);
}

.report-tag-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.report-tag-list li {
  padding: 0.4rem 0.75rem;
  font-size: 0.82rem;
  background: rgba(13, 28, 48, 0.8);
  border: 1px solid rgba(212, 175, 55, 0.2);
  border-radius: 2px;
}

.report-link-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.report-link-list li {
  margin-bottom: 0.5rem;
}

.report-link-list a {
  color: var(--gold-bright);
  text-decoration: none;
  font-size: 0.9rem;
}

.report-link-list a:hover {
  text-decoration: underline;
}

.report-suspect-cards {
  display: grid;
  gap: 1rem;
}

.report-suspect-card {
  padding: 1rem 1.15rem;
  background: rgba(13, 28, 48, 0.5);
  border: 1px solid rgba(212, 175, 55, 0.12);
  border-radius: 2px;
}

.report-suspect-card h3 {
  margin: 0 0 0.35rem;
  font-size: 1rem;
  color: var(--text-main);
}

.report-suspect-alias {
  margin: 0 0 0.5rem;
  font-size: 0.82rem;
  color: var(--gold);
}

.report-suspect-card p {
  margin: 0.5rem 0 0;
  font-size: 0.88rem;
  line-height: 1.55;
}

.report-photo-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 1.25rem;
}

.report-photo-figure {
  margin: 0;
}

.report-photo-figure img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border: 1px solid rgba(212, 175, 55, 0.2);
  border-radius: 2px;
  transition: border-color 0.15s ease;
}

.report-photo-figure a:hover img {
  border-color: var(--gold-bright);
}

.report-photo-figure figcaption {
  margin-top: 0.5rem;
  font-size: 0.78rem;
  color: var(--text-soft);
}

.report-ref {
  font-size: 0.82rem;
  color: var(--gold-bright);
}

.report-id {
  font-size: 0.78rem;
  font-variant-numeric: tabular-nums;
  color: var(--text-soft);
}

.report-search-meta {
  margin: 0 0 0.75rem;
}

.report-badge {
  display: inline-block;
  padding: 0.2rem 0.5rem;
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border-radius: 2px;
  background: rgba(212, 175, 55, 0.15);
  color: var(--gold-bright);
}

.report-badge--clos {
  background: rgba(120, 140, 160, 0.25);
  color: var(--text-soft);
}

.report-badge--brouillon {
  background: rgba(100, 100, 120, 0.3);
}

.report-badge--en_cours {
  background: rgba(184, 134, 11, 0.2);
}

.report-badge--actif {
  background: rgba(45, 106, 79, 0.25);
  color: #7dcea0;
}

.report-badge--surveille {
  background: rgba(184, 134, 11, 0.22);
}

.report-badge--interpelle {
  background: rgba(155, 34, 38, 0.28);
  color: #f4a6a8;
}

.report-table code.report-ref {
  background: transparent;
  border: none;
  padding: 0;
}
