#medaille-combat {
  position: fixed;
  z-index: 8;
  inset: clamp(88px, 27vh, 164px) calc(8px + env(safe-area-inset-right)) auto calc(8px + env(safe-area-inset-left));
  display: grid;
  justify-items: center;
  pointer-events: none;
}
body:not(.jeu) #medaille-combat, body.naufrage #medaille-combat { display: none; }

.medaille-elimination {
  --metal: #eeb87a;
  --fond-medaille: #3d2521;
  position: relative;
  display: flex;
  align-items: center;
  min-width: min(178px, 100%);
  max-width: min(276px, 100%);
  gap: 10px;
  padding: 6px 14px 6px 7px;
  white-space: nowrap;
  color: #fff3df;
  background: linear-gradient(100deg, var(--fond-medaille), #121e28 70%);
  border: 1px solid var(--metal);
  border-radius: 35px 11px 11px 35px;
  box-shadow: inset 0 0 0 2px #10182086, 0 4px 0 #0a1016, 0 9px 22px #0009;
  animation: medaille-entree 2.65s both;
}
.medaille-elimination[data-palier="2"] { --metal: #cce9f6; --fond-medaille: #254856; }
.medaille-elimination[data-palier="3"] { --metal: #ffdf84; --fond-medaille: #674226; }
.medaille-elimination[data-palier="4"] { --metal: #ffc190; --fond-medaille: #722f25; }
.medaille-elimination[data-palier="5"] { --metal: #edc3ff; --fond-medaille: #592f6d; }
.medaille-elimination .medaille-sceau {
  flex: none;
  width: 43px;
  height: 43px;
  display: grid;
  place-items: center;
  border: 2px solid var(--metal);
  border-radius: 50%;
  background: radial-gradient(circle, var(--fond-medaille), #101820 73%);
  box-shadow: inset 0 0 0 2px #101820, inset 0 0 0 3px var(--metal);
  color: var(--metal);
}
.medaille-sceau svg { width: 24px; height: 24px; }
.medaille-texte { display: grid; gap: 2px; min-width: 0; }
.medaille-titre { color: var(--metal); font-size: 16px; font-weight: 900; line-height: 1.08; }
.medaille-cible, .medaille-promotion {
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: 12px;
  line-height: 1.2;
}
.medaille-cible { color: #f7e8d5; font-weight: 600; }
.medaille-promotion { color: #ffe293; font-weight: 800; }
.medaille-promotion:empty { display: none; }
#grade-combat {
  margin: 8px 0;
  padding: 6px 9px;
  border: 1px solid #f4d58d70;
  border-radius: 9px;
  background: #060f187a;
  color: #f4d58d;
  font-size: 12px;
  font-weight: 750;
}
#grade-combat:empty { display: none; }

@keyframes medaille-entree {
  0% { opacity: 0; transform: translateY(-9px) scale(.83); }
  8% { opacity: 1; transform: translateY(0) scale(1.035); }
  14%, 87% { opacity: 1; transform: translateY(0) scale(1); }
  100% { opacity: 0; transform: translateY(-4px) scale(.99); }
}

@media (max-height: 460px) {
  .medaille-elimination { gap: 7px; padding: 5px 10px 5px 6px; }
  .medaille-elimination .medaille-sceau { width: 35px; height: 35px; }
  .medaille-sceau svg { width: 19px; height: 19px; }
  .medaille-titre { font-size: 14px; }
  .medaille-cible, .medaille-promotion { font-size: 11px; }
}
@media (prefers-reduced-motion: reduce) {
  .medaille-elimination { animation-name: medaille-fondu; }
}
@keyframes medaille-fondu {
  0%, 100% { opacity: 0; }
  8%, 87% { opacity: 1; }
}
