/* Le pendu — styles (mobile d'abord) */

/* Laisse la place au bouton FR/EN flottant ajouté par i18n.js */
header .container { padding-right: 6.5rem; }

.pd-scene {
    background: linear-gradient(160deg, #0f2a3d 0%, #123b52 60%, #17506a 100%);
    color: #eef6fb;
    border-radius: 18px;
    padding: 16px 12px;
    box-shadow: 0 12px 32px rgba(0, 0, 0, .18);
    max-width: 820px;
    margin: 0 auto;
}

.pd-barre {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: .6rem;
    margin-bottom: .8rem;
}

.pd-categorie { width: auto; max-width: 100%; flex: 1 1 12rem; }

.pd-scores { display: flex; gap: 1rem; font-size: 1.1rem; }
.pd-scores .fa-trophy { color: #facc15; }
.pd-scores .fa-skull { color: #fca5a5; }

.pd-plateau {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: .5rem;
    align-items: center;
}

.pd-dessin {
    width: 100%;
    max-width: 220px;
    height: auto;
    margin: 0 auto;
    display: block;
}

.pd-dessin line,
.pd-dessin circle,
.pd-dessin path {
    fill: none;
    stroke-width: 5;
    stroke-linecap: round;
}

.pd-potence { stroke: #c8a36b; }
.pd-personnage { stroke: #ffffff; }
.pd-visage path { stroke-width: 3; }

.pd-partie { opacity: 0; transition: opacity .3s ease; }
.pd-partie.pd-visible { opacity: 1; }
.pd-sauve .pd-personnage { stroke: #4ade80; }

.pd-infos { text-align: center; }

.pd-indice { color: #bcd7e6; margin-bottom: .6rem; }

.pd-mot {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: .2rem;
    margin-bottom: .8rem;
}

.pd-case {
    width: clamp(1.2rem, 6.5vw, 2.4rem);
    height: clamp(2rem, 9vw, 2.9rem);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-bottom: 4px solid #eef6fb;
    font-size: clamp(1.1rem, 5.5vw, 1.9rem);
    font-weight: 800;
}

.pd-case.pd-revelee { color: #fca5a5; }

.pd-essais { margin-bottom: .3rem; }
.pd-essais strong { font-variant-numeric: tabular-nums; }

.pd-message { min-height: 1.6em; font-weight: 700; font-size: 1.1rem; margin-bottom: .6rem; }
.pd-message.pd-gagne { color: #4ade80; }
.pd-message.pd-perdu { color: #fca5a5; }

.pd-clavier {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: .4rem;
    margin-top: 1rem;
}

.pd-touche {
    min-height: 48px;
    border: 0;
    border-radius: 10px;
    background: #eef6fb;
    color: #0f2a3d;
    font-size: 1.25rem;
    font-weight: 800;
    box-shadow: 0 3px 0 rgba(0, 0, 0, .35);
    touch-action: manipulation;
    -webkit-user-select: none;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
}

.pd-touche:active:not(:disabled) { transform: translateY(2px); box-shadow: 0 1px 0 rgba(0, 0, 0, .35); }
.pd-touche:focus-visible { outline: 3px solid #facc15; outline-offset: 2px; }
.pd-touche:disabled { box-shadow: none; }
.pd-touche:disabled:not(.pd-bonne):not(.pd-mauvaise) { opacity: .45; }
.pd-touche.pd-bonne { background: #22c55e; color: #fff; }
.pd-touche.pd-mauvaise { background: #475569; color: #cbd5e1; text-decoration: line-through; }

@media (min-width: 576px) {
    .pd-scene { padding: 24px; }
    .pd-plateau { grid-template-columns: 220px minmax(0, 1fr); gap: 1.5rem; }
    .pd-clavier { grid-template-columns: repeat(9, 1fr); }
}

@media (min-width: 768px) {
    .pd-clavier { grid-template-columns: repeat(13, 1fr); }
}

/* Petits téléphones : dessin plus compact pour garder le clavier à l'écran */
@media (max-width: 575.98px) {
    .pd-dessin { max-width: 150px; }
}
