/* ───────────────────────────────────────────────────────────────────────────
   AutoPause — feuille de style unique, sans build.
   Ordre : variables, base, mise en page, composants, écrans, impression.
   Le thème sombre suit le système et peut être forcé par [data-theme].
   ─────────────────────────────────────────────────────────────────────────── */

:root {
  --brand: #1d4ed8;
  --brand-strong: #1e3a8a;
  --brand-soft: #dbeafe;
  --accent: #f59e0b;
  --accent-soft: #fef3c7;
  /* Encre ambre pour le texte et les graphiques porteurs de sens : l'ambre de
     remplissage tombe à 2,15:1 sur blanc, donc illisible. Mesuré, pas estimé. */
  --accent-ink: #b45309;
  --success: #047857;
  --success-soft: #d1fae5;
  --danger: #dc2626;
  --danger-soft: #fee2e2;

  --bg: #f4f6fa;
  --surface: #ffffff;
  --surface-2: #f9fafb;
  --text: #111827;
  --muted: #5c6b7e;
  --border: #e2e8f0;
  /* Bordure des composants interactifs : WCAG 1.4.11 exige 3:1 pour ce qui
     permet d'identifier un champ ou un bouton. La bordure décorative des cartes
     et des séparateurs reste claire, elle ne porte aucune information. */
  --border-strong: #8293a9;
  --shadow: 0 1px 2px rgb(15 23 42 / 6%), 0 8px 24px -12px rgb(15 23 42 / 18%);
  --shadow-sm: 0 1px 2px rgb(15 23 42 / 8%);

  --radius: 14px;
  --radius-sm: 9px;
  --radius-pill: 999px;
  --header-height: 60px;
  --nav-height: 62px;
  --sidebar-width: 232px;
  --max-width: 1240px;
  --gutter: clamp(.75rem, 2vw, 1.5rem);

  /* Zones sûres des écrans à encoche. Avec viewport-fit=cover et une barre
     d'état translucide, le contenu commence sous l'horloge et sous la barre
     de gestes : sans ces marges, l'en-tête passe derrière l'heure et le bas
     de page devient inatteignable au défilement. */
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --safe-left: env(safe-area-inset-left, 0px);
  --safe-right: env(safe-area-inset-right, 0px);

  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, monospace;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --brand: #60a5fa;
    --brand-strong: #93c5fd;
    --brand-soft: #17233c;
    --accent: #fbbf24;
    --accent-soft: #3a2c0c;
    /* En thème sombre l'ambre atteint 10:1 : aucune encre distincte nécessaire. */
    --accent-ink: #fbbf24;
    --success: #34d399;
    --success-soft: #0d2f24;
    --danger: #f87171;
    --danger-soft: #3a1717;

    --bg: #0b1220;
    --surface: #121c2f;
    --surface-2: #0f1829;
    --text: #e6ebf4;
    --muted: #94a3b8;
    --border: #24334d;
    --border-strong: #526891;
    --shadow: 0 1px 2px rgb(0 0 0 / 40%), 0 10px 30px -14px rgb(0 0 0 / 70%);
    --shadow-sm: 0 1px 2px rgb(0 0 0 / 45%);
  }
}

:root[data-theme="dark"] {
  --brand: #60a5fa;
  --brand-strong: #93c5fd;
  --brand-soft: #17233c;
  --accent: #fbbf24;
  --accent-soft: #3a2c0c;
  --accent-ink: #fbbf24;
  --success: #34d399;
  --success-soft: #0d2f24;
  --danger: #f87171;
  --danger-soft: #3a1717;

  --bg: #0b1220;
  --surface: #121c2f;
  --surface-2: #0f1829;
  --text: #e6ebf4;
  --muted: #94a3b8;
  --border: #24334d;
  --border-strong: #526891;
  --shadow: 0 1px 2px rgb(0 0 0 / 40%), 0 10px 30px -14px rgb(0 0 0 / 70%);
  --shadow-sm: 0 1px 2px rgb(0 0 0 / 45%);
}

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

/* L'attribut `hidden` doit gagner contre toute règle de composant : la règle
   `[hidden] { display: none }` du navigateur est moins spécifique qu'un
   `.btn { display: inline-flex }`, et le bouton restait visible. */
[hidden] { display: none !important; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  /* `contain` et non `none` : le rebond élastique est conservé — c'est lui qui
     rend la fin de défilement douce — mais l'enchaînement vers le document
     parent est bloqué. La barre du bas ne s'en trouve plus décollée depuis
     qu'elle appartient au flux : le rebond l'emmène avec le contenu. */
  overscroll-behavior-y: contain;
}

body {
  margin: 0;
  /* Coquille d'application : une colonne qui occupe au moins tout l'écran. La
     mise en page s'étire, ce qui pousse la barre du bas contre le bord même
     quand la page est presque vide — un élément `fixed` n'offrait pas cette
     garantie et pouvait sembler flotter. */
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  min-height: 100dvh;
  /* manipulation : supprime le double-tap pour zoomer, et avec lui le délai de
     300 ms qu'il impose à chaque appui. Le défilement et le pincement système
     ne sont pas affectés par cette règle. */
  touch-action: manipulation;
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.5;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 { margin: 0 0 .4em; line-height: 1.25; font-weight: 650; letter-spacing: -.01em; }
h1 { font-size: 1.5rem; }
h2 { font-size: 1.15rem; }
h3 { font-size: 1rem; }
p { margin: 0 0 .8em; }
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }
small { font-size: .82rem; }

:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
  border-radius: 4px;
}

.sprite { display: none; }

.icon {
  width: 1.15em;
  height: 1.15em;
  flex: none;
  vertical-align: -.18em;
}
.icon--lg { width: 1.5em; height: 1.5em; }
.icon--xl { width: 2em; height: 2em; }

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

.skip-link {
  position: absolute;
  left: -9999px;
  z-index: 100;
  padding: .6rem 1rem;
  background: var(--surface);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow);
}
.skip-link:focus { left: 1rem; top: 1rem; }

/* ── Mise en page ───────────────────────────────────────────────────────── */

.app-header {
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  gap: .75rem;
  /* La hauteur inclut la barre d'état, et le remplissage haut y descend le
     contenu : l'en-tête peint donc lui-même la zone de l'horloge, dans la
     couleur du thème, au lieu de passer dessous. */
  height: calc(var(--header-height) + var(--safe-top));
  padding: var(--safe-top) calc(var(--gutter) + var(--safe-right)) 0 calc(var(--gutter) + var(--safe-left));
  background: color-mix(in srgb, var(--surface) 88%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: .55rem;
  font-weight: 700;
  font-size: 1.02rem;
  color: var(--text);
  letter-spacing: -.02em;
}
.brand:hover { text-decoration: none; }
.brand img { width: 28px; height: 28px; border-radius: 8px; }
.brand span { display: none; }
@media (min-width: 560px) { .brand span { display: inline; } }

.header-search { flex: 1; max-width: 460px; }
.header-actions { display: flex; align-items: center; gap: .4rem; margin-left: auto; }

.layout {
  display: flex;
  flex: 1 1 auto;
  gap: clamp(1rem, 2vw, 2rem);
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  /* La barre du bas étant dans le flux, plus besoin de réserver sa hauteur :
     arrivé en bas de page, le contenu est intégralement lisible et la barre le
     suit. Elle ne le recouvre qu'en cours de défilement. */
  padding:
    clamp(1rem, 2vw, 1.75rem)
    calc(var(--gutter) + var(--safe-right))
    1.5rem
    calc(var(--gutter) + var(--safe-left));
}
@media (min-width: 900px) {
  .layout { padding-bottom: 3rem; }
}

.sidebar { display: none; }
@media (min-width: 900px) {
  .sidebar {
    display: block;
    flex: 0 0 var(--sidebar-width);
    align-self: flex-start;
    position: sticky;
    top: calc(var(--header-height) + var(--safe-top) + 1.25rem);
  }
}

.sidebar-nav { display: flex; flex-direction: column; gap: 2px; }
.sidebar-nav a {
  display: flex;
  align-items: center;
  gap: .65rem;
  padding: .58rem .7rem;
  border-radius: var(--radius-sm);
  color: var(--muted);
  font-weight: 550;
}
.sidebar-nav a:hover { background: var(--surface); color: var(--text); text-decoration: none; }
.sidebar-nav a[aria-current="page"] { background: var(--brand-soft); color: var(--brand); }
.sidebar-group {
  margin: 1.1rem 0 .3rem;
  padding: 0 .7rem;
  font-size: .7rem;
  font-weight: 700;
  letter-spacing: .09em;
  text-transform: uppercase;
  color: var(--muted);
}

.content { flex: 1 1 auto; min-width: 0; }

.page-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: .75rem;
  margin-bottom: 1.1rem;
}
.page-head p { margin: .15rem 0 0; color: var(--muted); }

/* Barre de navigation basse, propre aux petits écrans. */
.bottom-nav {
  position: sticky;
  bottom: 0;
  z-index: 40;
  display: flex;
  height: calc(var(--nav-height) + var(--safe-bottom));
  padding-bottom: var(--safe-bottom);
  background: color-mix(in srgb, var(--surface) 92%, transparent);
  backdrop-filter: blur(12px);
  border-top: 1px solid var(--border);
}
@media (min-width: 900px) { .bottom-nav { display: none; } }
.bottom-nav a {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  font-size: .66rem;
  font-weight: 600;
  color: var(--muted);
}
/* Le contenu qui défile sous la barre s'estompe au lieu d'être coupé net. */
.bottom-nav::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 100%;
  height: 22px;
  pointer-events: none;
  background: linear-gradient(to top, color-mix(in srgb, var(--bg) 92%, transparent), transparent);
}
.bottom-nav a:hover { text-decoration: none; }
.bottom-nav a[aria-current="page"] { color: var(--brand); }
.bottom-nav .icon { width: 1.35em; height: 1.35em; }

/* ── Composants ─────────────────────────────────────────────────────────── */

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}
.card--pad { padding: clamp(.9rem, 2vw, 1.25rem); }
.card__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .75rem;
  padding: .85rem 1.1rem;
  border-bottom: 1px solid var(--border);
}
.card__head h2 { margin: 0; font-size: 1rem; }
.card__body { padding: 1.1rem; }
.card__foot {
  padding: .75rem 1.1rem;
  border-top: 1px solid var(--border);
  background: var(--surface-2);
  border-radius: 0 0 var(--radius) var(--radius);
}

.grid { display: grid; gap: clamp(.7rem, 1.5vw, 1rem); }
.grid--stats { grid-template-columns: repeat(auto-fit, minmax(158px, 1fr)); }
.grid--areas { grid-template-columns: repeat(auto-fill, minmax(288px, 1fr)); }
.grid--two { grid-template-columns: 1fr; }
@media (min-width: 860px) { .grid--two { grid-template-columns: 1.4fr 1fr; } }

.stack { display: flex; flex-direction: column; gap: 1.1rem; }
.row { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; }
.spacer { flex: 1 1 auto; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .45rem;
  padding: .52rem .9rem;
  font: inherit;
  font-weight: 600;
  color: var(--text);
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: background-color .14s ease, border-color .14s ease, transform .14s ease;
}
.btn:hover { background: var(--surface-2); text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn[disabled] { opacity: .55; cursor: not-allowed; }
.btn--primary {
  color: #fff;
  background: var(--brand);
  border-color: transparent;
}
/* En thème sombre, --brand devient une teinte claire : le texte du bouton doit
   alors être foncé pour rester lisible. */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .btn--primary { color: #06101f; }
}
:root[data-theme="dark"] .btn--primary { color: #06101f; }
.btn--primary:hover { background: color-mix(in srgb, var(--brand) 88%, black); }
.btn--ghost { background: transparent; border-color: transparent; color: var(--muted); }
.btn--ghost:hover { background: var(--surface-2); color: var(--text); }
.btn--danger { color: var(--danger); border-color: color-mix(in srgb, var(--danger) 35%, transparent); }
.btn--danger:hover { background: var(--danger-soft); }
.btn--sm { padding: .34rem .6rem; font-size: .84rem; }
.btn--icon { padding: .45rem; }
.btn--block { width: 100%; }
.btn--active { background: var(--brand-soft); border-color: var(--brand); color: var(--brand); }

.chip {
  display: inline-flex;
  align-items: center;
  gap: .35rem;
  padding: .28rem .6rem;
  font-size: .8rem;
  font-weight: 600;
  color: var(--muted);
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  white-space: nowrap;
}
.chip--on { color: var(--brand); background: var(--brand-soft); border-color: color-mix(in srgb, var(--brand) 40%, transparent); }
.chip--road { color: #fff; background: var(--brand); border-color: transparent; letter-spacing: .02em; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .chip--road { color: #06101f; } }
:root[data-theme="dark"] .chip--road { color: #06101f; }
.chip--visited { color: var(--success); background: var(--success-soft); border-color: color-mix(in srgb, var(--success) 35%, transparent); }
.chip--accent { color: color-mix(in srgb, var(--accent) 78%, var(--text)); background: var(--accent-soft); border-color: color-mix(in srgb, var(--accent) 40%, transparent); }
.chip--muted { opacity: .8; }
a.chip:hover { text-decoration: none; border-color: var(--brand); color: var(--brand); }

.chip-row { display: flex; flex-wrap: wrap; gap: .35rem; }
.stat {
  padding: .9rem 1rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}
.stat__label {
  display: flex;
  align-items: center;
  gap: .4rem;
  font-size: .78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .05em;
  color: var(--muted);
}
.stat__value {
  margin-top: .3rem;
  font-size: 1.7rem;
  font-weight: 700;
  letter-spacing: -.03em;
  font-variant-numeric: tabular-nums;
}
.stat__hint { font-size: .82rem; color: var(--muted); }

.progress {
  height: 8px;
  overflow: hidden;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
}
.progress__bar {
  height: 100%;
  background: linear-gradient(90deg, var(--brand), color-mix(in srgb, var(--brand) 55%, var(--accent)));
  border-radius: var(--radius-pill);
  transition: width .4s ease;
}

.bars { display: flex; align-items: flex-end; gap: 4px; height: 78px; }
.bars__item { flex: 1; display: flex; flex-direction: column; justify-content: flex-end; gap: 4px; text-align: center; }
.bars__bar {
  background: color-mix(in srgb, var(--brand) 75%, transparent);
  border-radius: 5px 5px 2px 2px;
  min-height: 3px;
}
.bars__label { font-size: .62rem; color: var(--muted); }

.stars { display: inline-flex; gap: 1px; font-size: .95rem; line-height: 1; }
.star { color: var(--border); }
.star--on { color: var(--accent-ink); }
.stars--empty { font-size: .82rem; color: var(--muted); }

/* Carte d'aire : le composant le plus vu de l'application. */
.area {
  display: flex;
  flex-direction: column;
  gap: .6rem;
  padding: .95rem 1rem 1rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  transition: border-color .15s ease, transform .15s ease, box-shadow .15s ease;
}
.area:hover { border-color: color-mix(in srgb, var(--brand) 45%, var(--border)); box-shadow: var(--shadow); }
.area--visited { border-left: 3px solid var(--success); }
.area__head { display: flex; align-items: flex-start; justify-content: space-between; gap: .6rem; }
.area__title { margin: 0; font-size: 1rem; font-weight: 650; }
.area__title a { color: var(--text); }
.area__title a:hover { color: var(--brand); text-decoration: none; }
.area__meta { display: flex; flex-wrap: wrap; gap: .3rem .55rem; font-size: .84rem; color: var(--muted); }
.area__services { display: flex; flex-wrap: wrap; gap: .3rem; }
.area__services .chip { padding: .22rem .5rem; font-size: .75rem; }
.area__actions { display: flex; gap: .4rem; margin-top: auto; padding-top: .2rem; }

.list { display: flex; flex-direction: column; }
.list__item {
  display: flex;
  align-items: center;
  gap: .8rem;
  padding: .8rem 1.1rem;
  border-bottom: 1px solid var(--border);
}
.list__item:last-child { border-bottom: 0; }
.list__item:hover { background: var(--surface-2); }
.list__main { flex: 1; min-width: 0; }
.list__title { font-weight: 600; }
.list__sub { font-size: .84rem; color: var(--muted); }

.table-scroll { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: .9rem; }
th, td { padding: .6rem .75rem; text-align: left; border-bottom: 1px solid var(--border); vertical-align: middle; }
th { font-size: .76rem; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); font-weight: 700; }
tbody tr:hover { background: var(--surface-2); }
td.numeric, th.numeric { text-align: right; font-variant-numeric: tabular-nums; }

/* ── Formulaires ────────────────────────────────────────────────────────── */

.field { display: flex; flex-direction: column; gap: .3rem; margin-bottom: .9rem; }
.field label { font-size: .85rem; font-weight: 600; }
.field small { color: var(--muted); }
.field--inline { flex-direction: row; align-items: center; gap: .55rem; }

input[type="text"], input[type="email"], input[type="password"], input[type="date"],
input[type="number"], input[type="search"], textarea {
  /* Safari peint ses propres décorations à l'intérieur des champs — loupe,
     bouton d'effacement, ombre interne. Elles se superposaient à l'icône du
     gabarit et laissaient des traits dans le champ de recherche. */
  -webkit-appearance: none;
  appearance: none;
  background-image: none;
}

input[type="text"], input[type="email"], input[type="password"], input[type="date"],
input[type="number"], input[type="search"], select, textarea {
  width: 100%;
  padding: .55rem .7rem;
  font: inherit;
  /* 16 px est un seuil, pas une préférence : en dessous, iOS agrandit toute la
     page dès la mise au point du champ, et n'en revient pas seul. La règle vaut
     même viewport verrouillé, certaines versions ignorant maximum-scale. */
  font-size: 16px;
  color: var(--text);
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  transition: border-color .14s ease, box-shadow .14s ease;
}
input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 20%, transparent);
}
textarea { min-height: 88px; resize: vertical; }

/* Safari applique à `type="search"` ses propres décorations — loupe interne et
   bouton d'effacement — qui se superposaient à l'icône du gabarit. */
input[type="search"] {
  -webkit-appearance: none;
  appearance: none;
}
input[type="search"]::-webkit-search-decoration,
input[type="search"]::-webkit-search-cancel-button,
input[type="search"]::-webkit-search-results-button,
input[type="search"]::-webkit-search-results-decoration {
  -webkit-appearance: none;
  display: none;
}

/* opacity: 1 est nécessaire : Firefox rend le texte indicatif translucide par
   défaut, ce qui le rendait presque illisible sur fond clair. */
::placeholder {
  color: var(--muted);
  opacity: 1;
}
input[type="checkbox"], input[type="radio"] { width: 1.05rem; height: 1.05rem; accent-color: var(--brand); }

.search {
  position: relative;
  display: flex;
  align-items: center;
}
.search .icon { position: absolute; left: .65rem; color: var(--muted); pointer-events: none; }
.search input { padding-left: 2.1rem; border-radius: var(--radius-pill); background: var(--surface-2); }

.form-grid { display: grid; gap: .9rem; grid-template-columns: 1fr; }
@media (min-width: 640px) { .form-grid--two { grid-template-columns: 1fr 1fr; } }

.rating { display: flex; flex-wrap: wrap; align-items: center; gap: .8rem; }

/* Ordre décroissant dans le document, réaffiché à l'endroit : c'est ce qui rend
   possible « l'étoile choisie et toutes les précédentes » en CSS seule. */
.rating__stars {
  display: flex;
  flex-direction: row-reverse;
  justify-content: flex-end;
  gap: .1rem;
}
.rating__stars input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}
.rating__stars label {
  padding: .1rem .12rem;
  font-size: 1.65rem;
  line-height: 1;
  color: var(--border-strong);
  cursor: pointer;
  transition: color .12s ease, transform .12s ease;
}
.rating__stars input:checked ~ label { color: var(--accent-ink); }
.rating__stars label:hover,
.rating__stars label:hover ~ label { color: var(--accent-ink); }
.rating__stars label:active { transform: scale(.92); }
.rating__stars input:focus-visible + label {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
  border-radius: 4px;
}

.rating__clear {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  font-size: .84rem;
  color: var(--muted);
  cursor: pointer;
}
@media (pointer: coarse) {
  .rating__stars label { min-width: 44px; min-height: 44px; display: grid; place-items: center; }
  .rating__clear { min-height: 44px; }
}

/* ── Cibles tactiles ────────────────────────────────────────────────────── */

/*
 * `pointer: coarse` cible le doigt, pas la largeur d'écran : une tablette au
 * clavier garde donc l'interface dense, et un petit écran tactile obtient des
 * cibles confortables.
 *
 * Calibrage assumé : 44 px pour tout ce qu'on vise (Apple HIG), 36 px pour les
 * puces de filtre — elles forment une liste dense où 44 px doublerait la hauteur
 * du panneau, et restent très au-dessus du plancher de 24 px du critère WCAG
 * 2.5.8.
 */
@media (pointer: coarse) {
  .btn,
  .btn--sm,
  .pagination a,
  .pagination span {
    min-height: 44px;
  }

  .btn--icon {
    min-width: 44px;
  }

  label.chip {
    min-height: 36px;
  }

  /* Les liens d'une liste occupent toute la hauteur de leur rangée, ce qui donne
     une cible large sans agrandir la rangée. */
  .list__item { min-height: 52px; }
}

/* ── Messages ───────────────────────────────────────────────────────────── */

.alert {
  display: flex;
  align-items: flex-start;
  gap: .6rem;
  padding: .7rem .9rem;
  margin-bottom: 1rem;
  border: 1px solid;
  border-radius: var(--radius-sm);
  font-size: .92rem;
}
.alert--ok { color: color-mix(in srgb, var(--success) 80%, var(--text)); background: var(--success-soft); border-color: color-mix(in srgb, var(--success) 35%, transparent); }
.alert--error { color: color-mix(in srgb, var(--danger) 80%, var(--text)); background: var(--danger-soft); border-color: color-mix(in srgb, var(--danger) 35%, transparent); }
.alert--info { color: var(--muted); background: var(--surface-2); border-color: var(--border); }

.empty {
  padding: 2.6rem 1.5rem;
  text-align: center;
  color: var(--muted);
}
.empty .icon { color: var(--border); }
.empty h3 { margin: .7rem 0 .3rem; color: var(--text); }

.toast-stack {
  position: fixed;
  left: 50%;
  bottom: calc(var(--nav-height) + 1rem + var(--safe-bottom));
  z-index: 60;
  display: flex;
  flex-direction: column;
  gap: .5rem;
  transform: translateX(-50%);
  width: min(92vw, 420px);
}
@media (min-width: 900px) { .toast-stack { bottom: 1.25rem; } }
.toast {
  display: flex;
  align-items: center;
  gap: .55rem;
  padding: .65rem .9rem;
  color: var(--text);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow);
  animation: toast-in .18s ease-out;
}
.toast .btn { margin-left: auto; flex: none; }
.toast--ok { border-color: color-mix(in srgb, var(--success) 45%, transparent); }
.toast--error { border-color: color-mix(in srgb, var(--danger) 45%, transparent); }
@keyframes toast-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

.offline-banner {
  display: none;
  position: sticky;
  top: calc(var(--header-height) + var(--safe-top));
  z-index: 29;
  align-items: center;
  gap: .5rem;
  padding: .5rem .9rem;
  font-size: .86rem;
  font-weight: 600;
  color: color-mix(in srgb, var(--accent) 80%, var(--text));
  background: var(--accent-soft);
  border-bottom: 1px solid color-mix(in srgb, var(--accent) 35%, transparent);
}
body.is-offline .offline-banner { display: flex; }

/* ── Filtres ─────────────────────────────────────────────────────────────── */

.filters { margin-bottom: .9rem; }

/* La recherche est l'action la plus fréquente : elle reste toujours visible. */
.filters__bar { display: flex; gap: .5rem; align-items: stretch; }
.filters__bar .search { flex: 1; }
.filters__bar .btn { flex: none; }

.filters__panel {
  margin-top: .6rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.filters__panel > summary {
  display: flex;
  align-items: center;
  gap: .45rem;
  padding: .7rem .9rem;
  font-weight: 600;
  color: var(--muted);
  cursor: pointer;
  list-style: none;
}
.filters__panel > summary::-webkit-details-marker { display: none; }
.filters__panel > summary::after {
  content: "";
  width: .5rem;
  height: .5rem;
  margin-left: auto;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
  transition: transform .15s ease;
}
.filters__panel[open] > summary { color: var(--text); border-bottom: 1px solid var(--border); }
.filters__panel[open] > summary::after { transform: rotate(-135deg); }
@media (pointer: coarse) {
  .filters__panel > summary { min-height: 44px; }
}

.filters__count {
  display: grid;
  place-items: center;
  min-width: 1.4rem;
  height: 1.4rem;
  padding: 0 .35rem;
  font-size: .78rem;
  font-weight: 700;
  color: #fff;
  background: var(--brand);
  border-radius: var(--radius-pill);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .filters__count { color: #06101f; }
}
:root[data-theme="dark"] .filters__count { color: #06101f; }

.filters__grid {
  display: grid;
  gap: .8rem;
  grid-template-columns: 1fr;
  padding: .9rem;
}
@media (min-width: 560px) { .filters__grid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 900px) { .filters__grid { grid-template-columns: repeat(3, 1fr); } }
.filters__grid .field { margin-bottom: 0; }

.filters__services {
  margin: 0;
  padding: 0 .9rem .9rem;
  border: 0;
}
.filters__services legend {
  padding: 0 0 .5rem;
  font-size: .85rem;
  font-weight: 600;
}
.filters__hint { margin: .6rem 0 0; font-size: .82rem; color: var(--muted); }
.filters__panel .row { padding: 0 .9rem .9rem; }

/* État des filtres : visible sans ouvrir le panneau, et chaque puce se retire
   individuellement. */
.filters__active {
  display: flex;
  flex-wrap: wrap;
  gap: .4rem;
  margin-bottom: .9rem;
}
.filters__active .chip .icon { opacity: .7; }
.filters__active a.chip--on:hover { background: var(--danger-soft); border-color: var(--danger); color: var(--danger); }

.quick-actions {
  display: flex;
  flex-wrap: wrap;
  gap: .4rem;
  margin-bottom: 1.1rem;
}
.quick-actions .chip { font: inherit; font-size: .8rem; cursor: pointer; }
@media (pointer: coarse) {
  .quick-actions .chip { min-height: 36px; }
}

/* ── Chargement progressif de la liste ──────────────────────────────────── */

.load-more {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .5rem;
  padding: 1.4rem 0 .4rem;
}
/* Squelettes : ils donnent la forme de ce qui arrive, là où un mot
   « Chargement… » ne dit rien de la quantité ni de la durée. */
.skeleton {
  padding: .95rem 1rem 1rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}
.skeleton__line {
  height: .8rem;
  margin-bottom: .55rem;
  background: linear-gradient(90deg, var(--surface-2), var(--border), var(--surface-2));
  background-size: 200% 100%;
  border-radius: 4px;
  animation: skeleton 1.4s ease-in-out infinite;
}
.skeleton__line:nth-child(1) { width: 62%; height: 1rem; }
.skeleton__line:nth-child(2) { width: 38%; }
.skeleton__line:nth-child(3) { width: 82%; margin-bottom: 0; }

@keyframes skeleton {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* Une animation qui pulse en continu est exactement ce que ce réglage demande
   de supprimer. */
@media (prefers-reduced-motion: reduce) {
  .skeleton__line { animation: none; background: var(--surface-2); }
}

.load-more__status {
  margin: 0;
  min-height: 1.2em;
  font-size: .84rem;
  color: var(--muted);
  text-align: center;
}

/* ── Pagination ─────────────────────────────────────────────────────────── */

.pagination { display: flex; flex-wrap: wrap; align-items: center; gap: .3rem; justify-content: center; margin-top: 1.2rem; }
.pagination a, .pagination span {
  min-width: 2.2rem;
  padding: .38rem .55rem;
  text-align: center;
  font-size: .88rem;
  font-weight: 600;
  color: var(--muted);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
}
.pagination a:hover { color: var(--brand); border-color: var(--brand); text-decoration: none; }
.pagination [aria-current="page"] { color: #fff; background: var(--brand); border-color: transparent; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .pagination [aria-current="page"] { color: #06101f; } }
:root[data-theme="dark"] .pagination [aria-current="page"] { color: #06101f; }
.pagination .gap { border: 0; background: none; }

/* ── Carte ──────────────────────────────────────────────────────────────── */

.map-shell {
  position: relative;
  /* Leaflet attribue à ses calques des z-index jusqu'à 1000, bien au-dessus de
     la barre de navigation. `isolation` confine tout cet empilement dans le
     cadre de la carte, au lieu de le laisser concourir avec le reste de la page. */
  isolation: isolate;
  height: clamp(360px, calc(100vh - var(--header-height) - var(--nav-height) - 7rem), 760px);
  /* 100dvh exclut les barres du navigateur mobile, contrairement à 100vh. */
  height: clamp(360px, calc(100dvh - var(--header-height) - var(--safe-top)
    - var(--nav-height) - var(--safe-bottom) - 7rem), 760px);
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.map-shell--detail { height: 260px; }
.map { position: absolute; inset: 0; background: var(--surface-2); }
.map-overlay {
  position: absolute;
  top: .6rem; left: .6rem;
  z-index: 500;
  display: flex;
  flex-direction: column;
  gap: .4rem;
  max-width: calc(100% - 1.2rem);
}
.map-legend {
  display: flex;
  gap: .7rem;
  padding: .45rem .7rem;
  font-size: .78rem;
  font-weight: 600;
  background: color-mix(in srgb, var(--surface) 92%, transparent);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  box-shadow: var(--shadow-sm);
}
.map-legend span { display: inline-flex; align-items: center; gap: .3rem; }
.dot { width: .65rem; height: .65rem; border-radius: 50%; }
.dot--visited { background: var(--success); }
.dot--services { background: var(--brand); }
.dot--rest { background: var(--muted); }

.leaflet-container { font: inherit; background: var(--surface-2); }
.leaflet-popup-content-wrapper {
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--text);
  box-shadow: var(--shadow);
}
.leaflet-popup-tip { background: var(--surface); }
.leaflet-popup-content { margin: .7rem .85rem; font-size: .9rem; }
.leaflet-popup-content h4 { margin: 0 0 .3rem; }
.leaflet-bar a, .leaflet-bar a:hover { background: var(--surface); color: var(--text); border-color: var(--border); }
.leaflet-control-attribution { background: color-mix(in srgb, var(--surface) 85%, transparent) !important; color: var(--muted) !important; }
.leaflet-control-attribution a { color: var(--muted) !important; }

.area-pin {
  width: 12px; height: 12px;
  border: 2px solid var(--surface);
  border-radius: 50%;
  box-shadow: 0 1px 3px rgb(0 0 0 / 45%);
}
.area-pin--services { background: var(--brand); }
.area-pin--rest { background: var(--muted); }
.area-pin--visited { background: var(--success); }
.area-pin--big { width: 18px; height: 18px; }

/* ── Détail d'une aire ──────────────────────────────────────────────────── */

.detail-head { display: flex; flex-wrap: wrap; align-items: flex-start; gap: .8rem; margin-bottom: 1rem; }
.detail-head h1 { margin: 0; }
.service-group { margin-bottom: 1rem; }
.service-group h3 {
  margin: 0 0 .45rem;
  font-size: .76rem;
  text-transform: uppercase;
  letter-spacing: .07em;
  color: var(--muted);
}
.definition { display: grid; grid-template-columns: minmax(120px, 34%) 1fr; gap: .4rem .8rem; font-size: .9rem; }
.definition dt { color: var(--muted); }
.definition dd { margin: 0; }
.tags {
  max-height: 320px;
  overflow: auto;
  font-family: var(--mono);
  font-size: .78rem;
}
.tags div { display: flex; gap: .5rem; padding: .18rem 0; border-bottom: 1px dashed var(--border); }
.tags dt { flex: 0 0 42%; color: var(--muted); overflow-wrap: anywhere; }
.tags dd { margin: 0; overflow-wrap: anywhere; }

details.disclosure { border-top: 1px solid var(--border); padding-top: .7rem; margin-top: .7rem; }
details.disclosure summary { cursor: pointer; font-weight: 600; color: var(--muted); }
details.disclosure summary:hover { color: var(--text); }
details.disclosure[open] summary { margin-bottom: .7rem; color: var(--text); }

/* ── Bascule de parcours ─────────────────────────────────────────────────── */

.segmented {
  display: inline-flex;
  gap: 2px;
  margin-bottom: 1.1rem;
  padding: 3px;
  background: var(--surface-2);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-pill);
}
.segmented a {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  padding: .42rem .95rem;
  font-size: .9rem;
  font-weight: 600;
  color: var(--muted);
  border-radius: var(--radius-pill);
}
.segmented a:hover { color: var(--text); text-decoration: none; }
.segmented a[aria-current="page"] {
  color: var(--brand);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}
@media (pointer: coarse) {
  .segmented a { min-height: 40px; }
}

/* ── Index des autoroutes ────────────────────────────────────────────────── */

.grid--roads { grid-template-columns: repeat(auto-fill, minmax(252px, 1fr)); }

.road {
  display: flex;
  align-items: center;
  gap: .8rem;
  padding: .8rem .9rem;
  color: var(--text);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  transition: border-color .15s ease, box-shadow .15s ease;
}
.road:hover { border-color: var(--brand); box-shadow: var(--shadow); text-decoration: none; }
.road--done { border-left: 3px solid var(--success); }

/* Le numéro d'autoroute est repris de la signalisation : c'est le repère que
   cherche l'œil, il doit dominer la carte. */
.road__ref {
  display: grid;
  place-items: center;
  flex: none;
  min-width: 3rem;
  padding: .35rem .5rem;
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: .01em;
  color: #fff;
  background: var(--brand);
  border-radius: 8px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .road__ref { color: #06101f; }
}
:root[data-theme="dark"] .road__ref { color: #06101f; }

.road__body { display: flex; flex-direction: column; gap: .2rem; min-width: 0; flex: 1; }
.road__name {
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.road__count { font-size: .84rem; color: var(--muted); }
.road__done { color: var(--success); flex: none; }

/* ── Mise en route (carnet vide) ─────────────────────────────────────────── */

.onboard { margin-bottom: 1.1rem; }
.onboard__title {
  margin: 0 0 .35rem;
  font-size: clamp(1.5rem, 6vw, 2rem);
  letter-spacing: -.03em;
}
.onboard__lead {
  max-width: 46ch;
  margin: 0 0 1.3rem;
  font-size: 1rem;
  color: var(--muted);
}

.onboard__actions {
  display: flex;
  flex-direction: column;
  gap: .6rem;
  margin-bottom: 1.4rem;
}
@media (min-width: 720px) {
  .onboard__actions { flex-direction: row; }
  .onboard__actions > * { flex: 1; }
}

/* Rangées d'action : la cible fait toute la largeur, ce qui se vise au pouce
   sans regarder — condition d'usage de cette application. */
.onboard__action {
  display: flex;
  align-items: center;
  gap: .8rem;
  width: 100%;
  padding: .95rem 1rem;
  font: inherit;
  text-align: left;
  color: var(--text);
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  cursor: pointer;
  transition: border-color .15s ease, transform .15s ease, box-shadow .15s ease;
}
.onboard__action:hover {
  border-color: var(--brand);
  box-shadow: var(--shadow);
  text-decoration: none;
}
.onboard__action:active { transform: translateY(1px); }
.onboard__action > .icon:last-child { color: var(--muted); margin-left: auto; }

.onboard__icon {
  display: grid;
  place-items: center;
  flex: none;
  width: 2.6rem;
  height: 2.6rem;
  color: var(--brand);
  background: var(--brand-soft);
  border-radius: 12px;
}
.onboard__body { display: flex; flex-direction: column; gap: .1rem; min-width: 0; }
.onboard__label { font-weight: 650; }
.onboard__hint { font-size: .84rem; color: var(--muted); }

/* Les trois temps de la boucle d'usage, énoncés une fois pour toutes. */
.onboard__steps {
  display: flex;
  flex-direction: column;
  gap: .55rem;
  margin: 0;
  padding: 1.1rem 1.2rem;
  list-style: none;
  font-size: .92rem;
  color: var(--muted);
  background: var(--surface-2);
  border: 1px dashed var(--border-strong);
  border-radius: var(--radius);
}
.onboard__steps li { display: flex; align-items: center; gap: .6rem; }
.onboard__step {
  display: grid;
  place-items: center;
  flex: none;
  width: 1.5rem;
  height: 1.5rem;
  font-size: .78rem;
  font-weight: 700;
  color: var(--brand);
  background: var(--brand-soft);
  border-radius: 50%;
}

/* ── Guide d'installation ───────────────────────────────────────────────── */

/* Aiguillage par plateforme. app.js pose <html data-install="…"> ; sans
   JavaScript, aucun attribut n'est posé et les deux marches à suivre restent
   visibles, ce qui laisse le guide utilisable. */
[data-install-when="installed"],
[data-install-when="ready"] { display: none; }
:root[data-install="installed"] [data-install-when="installed"] { display: flex; }
:root[data-install="ready"] [data-install-when="ready"] { display: block; }
:root[data-install="installed"] [data-install-when="ios"],
:root[data-install="installed"] [data-install-when="manual"],
:root[data-install="ready"] [data-install-when="ios"],
:root[data-install="ready"] [data-install-when="manual"],
:root[data-install="ios"] [data-install-when="manual"],
:root[data-install="manual"] [data-install-when="ios"] { display: none; }

.install__head {
  display: flex;
  align-items: flex-start;
  gap: .9rem;
  margin-bottom: 1.1rem;
}
.install__icon img {
  border-radius: 14px;
  box-shadow: var(--shadow);
}
.install__title { margin: 0 0 .2rem; font-size: 1.05rem; }
.install__lead { margin: 0; font-size: .9rem; color: var(--muted); }
.install__note { margin: .6rem 0 0; font-size: .84rem; color: var(--muted); text-align: center; }

.install__done {
  display: flex;
  align-items: center;
  gap: .5rem;
  margin: 0;
  padding: .7rem .9rem;
  font-weight: 600;
  color: color-mix(in srgb, var(--success) 80%, var(--text));
  background: var(--success-soft);
  border: 1px solid color-mix(in srgb, var(--success) 35%, transparent);
  border-radius: var(--radius-sm);
}

.install__platform {
  margin: 1.2rem 0 .7rem;
  font-size: .74rem;
  font-weight: 700;
  letter-spacing: .07em;
  text-transform: uppercase;
  color: var(--muted);
}
.install__platform:first-child { margin-top: 0; }

.install__steps {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
.install__step { display: flex; gap: .75rem; }
.install__number {
  flex: none;
  display: grid;
  place-items: center;
  width: 1.6rem;
  height: 1.6rem;
  font-size: .82rem;
  font-weight: 700;
  color: #fff;
  background: var(--brand);
  border-radius: 50%;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .install__number { color: #06101f; }
}
:root[data-theme="dark"] .install__number { color: #06101f; }
.install__body { flex: 1; min-width: 0; }
.install__step-title { margin: .1rem 0 .15rem; font-weight: 600; }
.install__hint { margin: 0 0 .55rem; font-size: .84rem; color: var(--muted); }

/* Maquettes d'interface : uniquement du balisage et des icônes du sprite, donc
   nettes à toute densité d'écran et cohérentes avec le thème. */
.mock {
  overflow: hidden;
  font-size: .82rem;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 10px;
}
.mock__bar {
  display: flex;
  align-items: center;
  justify-content: space-around;
  gap: .4rem;
  padding: .5rem .7rem;
}
.mock__bar--top { justify-content: space-between; }
.mock__url {
  flex: 1;
  padding: .2rem .6rem;
  color: var(--muted);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
}
.mock__glyph {
  display: grid;
  place-items: center;
  width: 1.9rem;
  height: 1.9rem;
  color: var(--muted);
  border-radius: 8px;
}
/* La cible du geste : c'est tout l'intérêt de la maquette. */
.mock__glyph--target {
  color: var(--brand);
  background: var(--brand-soft);
  box-shadow: 0 0 0 2px var(--brand);
}
.mock__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .5rem;
  padding: .5rem .7rem;
  color: var(--muted);
  border-bottom: 1px solid var(--border);
}
.mock__row:last-child { border-bottom: 0; }
.mock__row span { display: inline-flex; align-items: center; gap: .45rem; }
.mock__row--target {
  font-weight: 650;
  color: var(--brand);
  background: var(--brand-soft);
}
.mock__topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .5rem;
  padding: .5rem .7rem;
  border-bottom: 1px solid var(--border);
}
.mock__cancel { color: var(--muted); }
.mock__sheet-title { font-weight: 650; }
.mock__confirm {
  font-weight: 700;
  color: var(--brand);
  padding: .1rem .45rem;
  background: var(--brand-soft);
  border-radius: 6px;
  box-shadow: 0 0 0 2px var(--brand);
}
.mock__preview {
  display: flex;
  align-items: center;
  gap: .55rem;
  padding: .6rem .7rem;
  font-weight: 600;
}
.mock__preview img { border-radius: 9px; }

/* Invitation du tableau de bord : mobile seulement, et jamais si déjà installée. */
.install-invite { margin-bottom: 1.1rem; }
@media (min-width: 900px) { .install-invite { display: none; } }
:root[data-install="installed"] .install-invite { display: none; }

.install-invite summary {
  cursor: pointer;
  font-weight: 600;
  color: var(--brand);
  list-style: none;
}
.install-invite summary::-webkit-details-marker { display: none; }
.install-invite summary::after {
  content: " ›";
  font-weight: 700;
}
.install-invite[open] summary::after { content: " ⌄"; }

/* ── Écran de connexion ─────────────────────────────────────────────────── */

.auth-shell {
  display: grid;
  place-items: center;
  min-height: 100vh;
  min-height: 100dvh;
  padding:
    max(1.5rem, var(--safe-top))
    max(1.5rem, var(--safe-right))
    max(1.5rem, var(--safe-bottom))
    max(1.5rem, var(--safe-left));
  background:
    radial-gradient(1100px 520px at 12% -8%, color-mix(in srgb, var(--brand) 22%, transparent), transparent),
    radial-gradient(900px 480px at 105% 8%, color-mix(in srgb, var(--accent) 16%, transparent), transparent),
    var(--bg);
}
.auth-card { width: min(100%, 412px); }
.auth-card .card { padding: clamp(1.3rem, 4vw, 2rem); }
.auth-logo { display: flex; align-items: center; gap: .6rem; justify-content: center; margin-bottom: 1.3rem; font-size: 1.2rem; font-weight: 700; }
.auth-logo img { width: 40px; height: 40px; border-radius: 11px; }
.auth-foot { margin-top: 1.1rem; text-align: center; font-size: .84rem; color: var(--muted); }

/* ── Divers ─────────────────────────────────────────────────────────────── */

.muted { color: var(--muted); }
.nowrap { white-space: nowrap; }
.numeric { font-variant-numeric: tabular-nums; }
.truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }
.inline-form { display: inline; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}

@media print {
  .app-header, .bottom-nav, .sidebar, .area__actions, .pagination, .toast-stack { display: none !important; }
  body { background: #fff; color: #000; }
  .card, .area { break-inside: avoid; box-shadow: none; }
}
