/*
 * En-tête (DA2) : solde de Klaw Coins avec sa pièce, compteur « en ligne », compte avec avatar rond.
 * Et page Jouer : « Partie sans Elo » mise en valeur, visible aussi sur téléphone.
 * Chargé après da2.css et navigation-mobile.css : ces règles l'emportent.
 */

/* ---------- Klaw Coins : une pièce dorée, le nombre en gras ---------- */
html.da2 .kc-entete:not([hidden]) {
  display: inline-flex; align-items: center; gap: 8px; min-height: 42px; padding: 0 14px 0 6px;
  background: linear-gradient(135deg, rgb(251 191 36 / .16), rgb(251 191 36 / .05));
  border: 1px solid rgb(251 191 36 / .38); border-radius: 99px;
  color: #ffe08a; font: 800 15px/1 var(--f-chiffre, var(--f-titre)); text-decoration: none;
  transition: border-color .15s, box-shadow .15s, transform .15s;
}
html.da2 .kc-entete::before {
  content: "K"; display: grid; place-items: center; flex: none; width: 30px; height: 30px; border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #fff1a8, #fbbf24 52%, #b7791f);
  box-shadow: inset 0 0 0 2px rgb(0 0 0 / .18), 0 2px 8px rgb(251 191 36 / .35);
  color: #3d2a00; font: 900 14px/1 var(--f-titre);
}
html.da2 .kc-entete::after { content: none; }
html.da2 .kc-entete:hover, html.da2 .kc-entete:focus-visible { border-color: #fbbf24; box-shadow: 0 0 0 3px rgb(251 191 36 / .14); transform: translateY(-1px); }

/* ---------- En ligne : point vert qui pulse, chiffre en avant ---------- */
html.da2 .en-ligne-r {
  gap: 9px; padding: 0 15px 0 12px;
  background: linear-gradient(135deg, rgb(52 211 153 / .14), rgb(52 211 153 / .04));
  border: 1px solid rgb(52 211 153 / .32); color: var(--gris);
}
html.da2 .en-ligne-r b { color: var(--texte); font: 800 15px/1 var(--f-chiffre, var(--f-titre)); }
html.da2 .en-ligne-r .point-r { position: relative; width: 9px; height: 9px; background: var(--ok); animation: none; box-shadow: 0 0 8px rgb(52 211 153 / .8); }
html.da2 .en-ligne-r .point-r::after { content: ""; position: absolute; inset: -4px; border: 2px solid var(--ok); border-radius: 50%; opacity: 0; animation: onde-en-ligne 2s ease-out infinite; }
@keyframes onde-en-ligne { 0% { transform: scale(.5); opacity: .8; } 100% { transform: scale(1.6); opacity: 0; } }

/* ---------- Compte : pilule avec avatar rond ---------- */
html.da2 .puce-compte { gap: 9px; padding: 4px 14px 4px 4px; border-radius: 99px; }
html.da2 .puce-compte img, html.da2 .puce-compte .avatar, html.da2 .puce-compte > :first-child:not(span) { width: 34px; height: 34px; border-radius: 50%; object-fit: cover; }

/* ---------- Page Jouer : « Partie sans Elo » en valeur ---------- */
html.da2 .puce-r[data-sans-elo] {
  gap: 7px; color: #c7f9ea; font-weight: 700;
  background: linear-gradient(135deg, rgb(52 211 153 / .2), rgb(56 189 248 / .12));
  border-color: rgb(52 211 153 / .5);
}
html.da2 .puce-r[data-sans-elo]::before { content: "⚡"; font-size: 14px; }
html.da2 .puce-r[data-sans-elo]:hover, html.da2 .puce-r[data-sans-elo]:focus-visible { color: #fff; border-color: var(--ok); box-shadow: 0 0 0 3px rgb(52 211 153 / .16); }

@media (max-width: 767px) {
  html.da2 .liens-r { display: flex; justify-content: center; width: 100%; }
  html.da2 .liens-r .puce-r[href="#rangs"] { display: none; }
  html.da2 .liens-r .puce-r[data-sans-elo] { width: 100%; }
  html.da2 .kc-entete:not([hidden]) { min-height: 40px; padding-right: 12px; font-size: 14px; }
  html.da2 .kc-entete::before { width: 26px; height: 26px; font-size: 12px; }
  /* Une seule ligne d'en-tête : sur téléphone, le compte n'est plus que son avatar rond (le profil est aussi dans la barre du bas). */
  html.da2 .zone-compte { gap: 8px; }
  html.da2 .puce-compte { padding: 3px; }
  html.da2 .puce-compte span:not(.avatar) { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  html.da2 .en-ligne-r .point-r::after { animation: none; }
  html.da2 .kc-entete:hover { transform: none; }
}
