/* La minicarte repliable (minimap-ui.mjs, étape 3, tâche 9 b ; brief 03-ennemis-client-brief.md § 8.7, variante C du 31/10) : en haut à gauche,
   sous les jauges ; l'onglet de 44 × 44 px au-dessus du bord gauche du cadre, le cadre un rectangle de verre de 168 × 96 px (réglé au bureau par
   la session). Replié, l'onglet garde le chiffre gravé ambre (charte § 5) et l'anneau du cas le plus pressant ; jamais la couleur seule (le corail
   est plein, la fusée ambre pointillée). Cachée, onglet compris, en vue épurée, combat, entrée, connexion, film et intérieur. */
.halo-preview .minimap { --minimap-width: 168px; --minimap-height: 96px; --minimap-gap: 4px; position: fixed; top: calc(var(--vitals-top) + var(--vitals-height) + 12px);
  left: var(--edge); z-index: 6; display: flex; flex-direction: column; align-items: flex-start; gap: var(--minimap-gap); pointer-events: none; color: #f0e1c5; }
/* Au bureau, 240 × 136 px (maquette grand écran du 01/11) et en haut à droite, sous le bouton du menu (choix du 02/11 : le tchat tient la
   colonne sous les jauges) ; l'onglet au-dessus de son bord droit. Au téléphone, le tchat est dans la barre : elle reste sous les jauges. */
@media (min-width: 721px) and (pointer: fine) {
  .halo-preview .minimap { --minimap-width: 240px; --minimap-height: 136px; left: auto; right: var(--edge); top: calc(var(--vitals-top) + 44px + 12px); align-items: flex-end; }
  .halo-preview .minimap-frame { transform-origin: calc(100% - 22px) 0; }
}
/* Le volet de fouille sous la mini-carte ouverte, au bureau (recette 10 a7h, 17/11 : le plafond de map.css, 100dvh − 325 px, date d'avant la
   mini-carte ; à 1440 × 900 le sélecteur « Pour » allongeait le volet de 70 px sous elle) : son bas au pied de la barre du bas (hud.css),
   au-dessus des boutons du coin ; son haut au moins 8 px sous la mini-carte ouverte (vitals-top + 56 px, puis l'onglet 44, l'écart 4 et le
   cadre 136 : 248 px avec les 8). Les petites hauteurs gardent leur placement (style.css, max-height: 560px). */
@media (min-width: 721px) and (pointer: fine) and (min-height: 561px) {
  .halo-preview .poi-panel { bottom: var(--hud-bar-bottom, 80px); max-height: min(480px, calc(100dvh - var(--hud-bar-bottom, 80px) - var(--vitals-top) - 248px)); }
}
.halo-preview .minimap[hidden], .halo-preview .minimap [hidden] { display: none !important; }
.halo-preview:is(.clean-view, .combat-open, .entry-open, .auth-open, .intro-open, .is-interior) .minimap { display: none !important; }

.halo-preview .minimap-tab { position: relative; box-sizing: border-box; display: grid; place-items: center; width: 44px; height: 44px; padding: 0; pointer-events: auto;
  border: 1px solid rgb(203 201 177 / 24%); border-radius: 8px; background: rgb(15 34 38 / 78%); color: #9cc6bd; cursor: pointer;
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); }
.halo-preview .minimap-compass { display: block; overflow: visible; }
.halo-preview .minimap-chevron { position: absolute; top: 4px; right: 4px; color: #c4ccbf; transition: transform 200ms ease; }
.halo-preview .minimap-tab[aria-expanded="true"] .minimap-chevron { transform: rotate(180deg); }
/* Le chiffre gravé : le nombre seul, ambre, sans fond, au coin bas (comme .chat-mobile-unread) ; jamais « 0 » (caché à zéro). */
.halo-preview .minimap-count { position: absolute; bottom: 4px; right: 5px; color: #e2bc7e; font-size: 10px; font-weight: 700; line-height: 1; font-variant-numeric: tabular-nums; pointer-events: none; }

/* L'anneau d'appel de 2 px autour de l'onglet ; il respire trois fois à l'arrivée d'un nouvel appel, puis reste fixe. */
.halo-preview .minimap-tab[data-call]::before, .halo-preview .minimap-tab[data-call]::after { content: ""; position: absolute; inset: -4px; box-sizing: border-box;
  border: 2px solid #e8836f; border-radius: 11px; pointer-events: none; }
.halo-preview .minimap-tab[data-call="fusee"]::before, .halo-preview .minimap-tab[data-call="fusee"]::after { border: 2px dashed #e2bc7e; }
.halo-preview .minimap-tab[data-call]::after { opacity: 0; }
.halo-preview .minimap-tab[data-call].is-calling::after { animation: minimap-breathe 1.6s ease-out 3; animation-iteration-count: 3; }
@keyframes minimap-breathe { from { transform: scale(1); opacity: .9; } to { transform: scale(1.3); opacity: 0; } }

/* Le cadre : un seul bouton « Ouvrir la carte » ; le canevas le remplit. Repliée : fondu et échelle de 200 ms, puis hors d'atteinte. */
.halo-preview .minimap-frame { position: relative; box-sizing: border-box; display: block; width: var(--minimap-width); height: var(--minimap-height); padding: 0; overflow: hidden;
  border: 1px solid rgb(203 201 177 / 28%); border-radius: 8px; background: rgb(15 34 38 / 78%); cursor: pointer; pointer-events: auto;
  box-shadow: 0 8px 26px rgb(0 0 0 / 28%); transform-origin: 22px 0; opacity: 0; transform: scale(.92); visibility: hidden;
  transition: opacity 200ms ease, transform 200ms ease, visibility 0s linear 200ms; }
.halo-preview .minimap.is-open .minimap-frame { opacity: 1; transform: none; visibility: visible; transition: opacity 200ms ease, transform 200ms ease, visibility 0s; }
.halo-preview .minimap:not(.is-open) .minimap-frame { pointer-events: none; }
.halo-preview .minimap-canvas { display: block; width: 100%; height: 100%; pointer-events: none; }
/* Hors ligne : tracé gelé, cadre à 60 % ; l'onglet le dit dans sa bulle d'aide (« Liaison interrompue. »). */
.halo-preview .minimap.is-offline .minimap-frame { opacity: .6; }
.halo-preview .minimap-description { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

.halo-preview .minimap :is(.minimap-tab, .minimap-frame):focus-visible { outline: 2px solid #a4cdc0; outline-offset: 2px; }
.halo-preview .minimap-tab:focus-visible { background: rgb(43 63 60 / 92%); border-color: rgb(170 205 195 / 40%); }
@media (hover: hover) {
  .halo-preview .minimap-tab:hover { background: rgb(43 63 60 / 92%); border-color: rgb(170 205 195 / 40%); }
  .halo-preview .minimap.is-open .minimap-frame:hover { border-color: rgb(170 205 195 / 45%); }
}
/* Mouvement réduit : pliage instantané, aucun souffle ; l'anneau fixe de 3 px et un petit point plein sur son bord haut. */
@media (prefers-reduced-motion: reduce) {
  .halo-preview .minimap-frame, .halo-preview .minimap.is-open .minimap-frame, .halo-preview .minimap-chevron { transition: none; }
  .halo-preview .minimap-tab[data-call]::before { border-width: 3px; }
  .halo-preview .minimap-tab[data-call]::after, .halo-preview .minimap-tab[data-call].is-calling::after { animation: none !important; inset: auto; left: 50%; top: -6px; width: 7px; height: 7px;
    margin-left: -3.5px; border: 0; border-radius: 50%; background: #e8836f; opacity: 1; transform: none; }
  .halo-preview .minimap-tab[data-call="fusee"]::after { border: 0; background: #e2bc7e; }
}
