.steam-profile-trigger {
  min-height: 42px;
  padding: 4px 9px 4px 5px;
  display: flex;
  align-items: center;
  gap: 8px;
  border: 1px solid #5e4931;
  background: #15130f;
  color: #eee3d1;
  font: 700 0.8rem Roboto;
  cursor: pointer;
}
/* L'avatar et sa pastille « en jeu » (verte, qui pulse doucement) */
.acc-face {
  position: relative;
  display: block;
  flex: none;
}
.acc-online {
  position: absolute;
  right: -4px;
  bottom: -4px;
  width: 11px;
  height: 11px;
  border: 2px solid #15130f;
  border-radius: 50%;
  background: #5cc27a;
  animation: acc-online 2s ease-out infinite;
}
.acc-online[hidden] {
  display: none;
}
@keyframes acc-online {
  from {
    box-shadow: 0 0 0 0 #5cc27acc;
  }
  to {
    box-shadow: 0 0 0 7px #5cc27a00;
  }
}
@media (prefers-reduced-motion: reduce) {
  .acc-online {
    animation: none;
  }
}
.steam-profile-trigger img {
  width: 31px;
  height: 31px;
  object-fit: cover;
  border: 1px solid #8b673a;
}
.steam-profile-trigger svg {
  width: 15px;
  height: 15px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
}
.steam-profile-trigger span {
  max-width: 112px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.steam-account.open .steam-profile-menu {
  opacity: 1;
  visibility: visible;
  transform: none;
}
.steam-profile-menu {
  position: absolute;
  right: 0;
  top: calc(100% + 10px);
  background: #12100df5;
  border: 1px solid #674e31;
  box-shadow: 0 14px 28px #000b;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px);
  transition: 0.2s;
  width: 290px; /* 255 px avant le minimum de 12,8 px : le pied (Paramètres, Se déconnecter) n'y tenait plus */
  padding: 0;
  overflow: hidden;
}
.steam-link-help {
  margin: 0 12px 8px;
  padding: 12px;
  background: #1b160f;
  border: 1px solid #5c462d;
}
.steam-link-help > small {
  display: block;
  padding: 0;
  border: 0;
  color: #c6934e;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
}
.steam-link-help > strong {
  display: block;
  margin-top: 5px;
  color: #efa948;
  font-size: 17px;
}
.steam-link-help p {
  margin: 6px 0 0;
  color: #b3a795;
  font-size: 13px;
  line-height: 1.45;
}
.steam-link-token {
  display: flex;
  gap: 7px;
  margin-top: 8px;
}
.steam-link-token code {
  flex: 1;
  padding: 7px 8px;
  background: #090806;
  color: #f0e4d2;
  font: 700 14px monospace;
  letter-spacing: 0.09em;
}
.steam-link-token button {
  border: 1px solid #785a34;
  background: #241b11;
  color: #e3a34b;
  padding: 0 9px;
  font: 700 0.8rem Roboto;
  text-transform: uppercase;
  cursor: pointer;
}
.steam-account {
  position: relative;
  height: 42px;
  display: flex;
  align-items: center;
  line-height: 1;
}
.steam-account > #steam-login {
  height: 42px;
  display: flex;
  align-items: center;
  line-height: 1;
  padding-block: 0;
}

/* Téléphone : le bouton du compte est à gauche de l'écran ; aligné sur lui, le menu (255 px) débordait à gauche.
   Il s'ancre à l'écran, sous l'en-tête, avec la marge des pages. */
@media (max-width: 600px) {
  .steam-profile-menu {
    position: fixed;
    top: var(--head);
    left: 16px;
    right: 16px;
    width: auto;
  }
}

/* === La carte du compte (layout/account.js, buildMenu) ===================== */
.steam-account .steam-profile-menu {
  width: 290px;
}
.acc-head {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  border-bottom: 1px solid #4a3a28;
  background: radial-gradient(circle at 0 0, #3a2a1688, transparent 70%), linear-gradient(135deg, #211b13, #12100d);
}
.acc-head img,
.acc-head__avatar {
  flex: none;
  width: 48px;
  height: 48px;
  border: 1px solid #7a5a32;
  object-fit: cover;
}
.acc-head__avatar {
  display: grid;
  place-items: center;
  color: #cfc3b2;
}
.acc-head__avatar svg {
  width: 24px;
  height: 24px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
}
.acc-head div {
  display: grid;
  gap: 3px;
  min-width: 0;
}
.acc-head strong {
  overflow: hidden;
  color: #f1e6d5;
  font-size: 15px;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.acc-rank {
  justify-self: start;
  padding: 2px 8px;
  border: 1px solid #5c4a35;
  color: #b9ab96;
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}
.acc-rank.is-lecheur {
  border-color: #e0a445;
  background: linear-gradient(160deg, #d7963c, #9a5f22);
  color: #170f07;
  box-shadow: 0 0 12px #d68f3755;
}
.acc-head small {
  color: #a99c89;
  font-size: 0.8rem;
}
.acc-links {
  display: grid;
  padding: 6px;
}
.acc-links a,
.acc-discord {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 9px 10px;
  color: #ded3c2;
  font-size: 13px;
  transition:
    background 0.15s,
    color 0.15s;
}
.acc-links svg {
  flex: none;
  width: 17px;
  height: 17px;
  fill: none;
  stroke: #c89146;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.acc-links a:hover {
  background: #2a2117;
  color: #f0b45c;
}
/* La liaison Discord, en première ligne */
.acc-discord {
  margin-bottom: 4px;
  border-bottom: 1px solid #3a2f22;
  color: #a99c89;
  font-size: 0.8rem;
}
.acc-links .acc-discord svg {
  fill: currentColor;
  stroke: none;
}
/* Bien débuter, pas encore tout vert : la ligne en tête du menu et la pastille du bouton */
.acc-guide {
  display: flex;
  align-items: center;
  gap: 11px;
  margin-bottom: 4px;
  padding: 9px 10px;
  border-bottom: 1px solid #3a2f22;
  color: #f0c27a;
  font-size: 0.8rem;
  font-weight: 700;
}
.acc-guide[hidden],
.acc-badge[hidden] {
  display: none;
}
.acc-guide b {
  margin-left: auto;
  padding: 1px 7px;
  background: #e4a64e;
  color: #17110a;
  font-size: 0.8rem;
}
.acc-guide:hover {
  background: #2a2117;
}
.steam-profile-trigger {
  position: relative;
}
.acc-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  width: 10px;
  height: 10px;
  border: 2px solid #15130f;
  border-radius: 50%;
  background: #e4a64e;
  box-shadow: 0 0 8px #e4a64e;
}
.acc-discord.is-linked {
  color: #8fd6a2;
}
.acc-discord b {
  margin-left: auto;
  color: #e4a64e;
  font-weight: 700;
}
a.acc-discord:hover {
  background: #2a2117;
}
.acc-foot {
  display: flex;
  justify-content: space-between;
  border-top: 1px solid #3a2f22;
  background: #0c0b09;
}
.acc-foot a,
.acc-logout {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 11px 12px;
  border: 0;
  background: none;
  color: #cfc3b2;
  font: 700 0.8rem Roboto, sans-serif;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  /* Sur une ligne chacun (à 12,8 px, « Se déconnecter » passait sur deux) */
  white-space: nowrap;
  cursor: pointer;
}
.acc-foot svg {
  width: 15px;
  height: 15px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.acc-foot a:hover {
  color: #f0b45c;
}
.acc-logout:hover {
  color: var(--red-text);
}

/* Le menu du compte en sections, comme les menus du haut (8 oct.) */
.acc-section {
  margin: 0;
  padding: 10px 10px 4px;
  color: #c89146;
  font: 700 0.8rem/1 "Roboto Condensed", sans-serif;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.acc-section:not(:first-of-type) {
  margin-top: 4px;
  border-top: 1px solid #2f271d;
}
.acc-links a {
  border-left: 3px solid transparent;
}
.acc-links a:hover {
  border-left-color: rgba(201, 145, 70, 0.6);
}

/* Connexion Steam ratée : un bandeau sous l'en-tête, fermable (layout/account.js, showLoginFailed) */
.login-failed {
  position: fixed;
  z-index: 600; /* devant le bandeau du vote ou de l'aperçu de l'équipe (599) */
  top: calc(var(--head) + 12px);
  left: 50%;
  display: flex;
  align-items: center;
  gap: 4px;
  width: max-content;
  max-width: calc(100vw - 32px);
  transform: translateX(-50%);
  border-left-color: #c0492b;
  background: #1a140e;
  box-shadow: 0 8px 24px rgba(var(--shadow-rgb), 0.45);
  font-size: 0.95rem;
}
/* Sous le bandeau du vote ou de l'aperçu de l'équipe quand il est là (46 px) */
body:has(.vote-banner:not([hidden])) .login-failed {
  top: calc(var(--head) + 58px);
}
.login-failed > i:first-child {
  color: #e0674a;
}
.login-failed__close {
  margin-left: 8px;
  padding: 4px 6px;
  border: 0;
  background: none;
  color: var(--muted);
  cursor: pointer;
}
.login-failed__close:hover,
.login-failed__close:focus-visible {
  color: var(--parchment);
}
