/* Manuel « Comment jouer » (colonne de gauche), salles privées, orientation des vidéos */
.table { grid-template-columns: auto minmax(0, 1fr) 330px; }
.manual { width: 290px; height: 100vh; overflow-y: auto; padding: 12px 12px 24px; display: grid; align-content: start; gap: 6px;
  background: var(--surface-a); border-right: 1px solid var(--line); font-size: 13px; line-height: 1.45; }
.manual-head { display: flex; align-items: center; justify-content: space-between; padding-bottom: 8px; border-bottom: 1px solid var(--line); margin-bottom: 4px; }
.manual-head h2 { font-size: 17px; letter-spacing: .05em; }
.manual-head button { padding: 2px 8px; box-shadow: none; }
.manual details { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 0 10px; }
.manual summary { display: flex; align-items: center; justify-content: space-between; gap: 8px; cursor: pointer; padding: 8px 0; font: 700 13px/1.2 var(--f-display); letter-spacing: .04em; color: var(--fg); list-style: none; }
.manual summary::-webkit-details-marker { display: none; }
.manual summary::after { content: "▸"; flex: none; color: var(--muted); transition: transform .2s; }
.manual details[open] summary::after { transform: rotate(90deg); }
.manual details[open] { padding-bottom: 8px; }
.manual p, .manual ol { margin: 0 0 6px; color: var(--muted); }
.manual ol { padding-left: 18px; }
.manual b { color: var(--fg); font-weight: 600; }
.manual-toggle { position: fixed; z-index: 30; left: 8px; bottom: 8px; display: none; align-items: center; gap: 6px; padding: 7px 12px; border-radius: 999px;
  background: var(--surface); border: 1px solid var(--accent); color: var(--fg); box-shadow: var(--shadow-hover); font: 600 13px/1 var(--f-body); }
body.manual-closed .manual { display: none; }
body.manual-closed .manual-toggle { display: inline-flex; }

/* salles privées */
.room-row { display: flex; align-items: stretch; gap: 6px; }
.room-row input { flex: 1; min-width: 0; }
.wanted .room-row .btn { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; font-weight: 600; white-space: nowrap; padding: 0 12px; background: rgb(255 250 235 / .7); color: var(--ink); border: 1.5px solid #8a6a3a; box-shadow: none; }
.invite { display: grid; gap: 4px; }
.wanted .invite span { font-size: 12px; font-weight: 600; }
.wanted .invite input { font-size: 13px; }
.room-err { margin: 0; color: #8e1f1b; font-weight: 600; font-size: 13px; }
.secure { margin: 2px 0 0; font-size: 12px; text-align: center; }
.wanted .secure { margin-top: 4px; color: var(--ink); opacity: .85; font-weight: 500; line-height: 1.35; text-wrap: balance; }
.wanted .secure, .wanted .secure * { -webkit-text-fill-color: currentColor; text-decoration: none; }
.panel .secure { text-align: left; }
.box.invite input { background: var(--sunken); }

/* orientation des vidéos (sur son propre écran) */
.orient { display: grid; gap: 4px; font: 700 13px/1 var(--f-display); letter-spacing: .06em; color: var(--muted); }
.orow { display: grid; grid-template-columns: 82px 1fr 1fr; gap: 4px; align-items: center; font: 500 12px/1 var(--f-body); letter-spacing: 0; }
.orow b { color: var(--fg); font-weight: 600; }
.orow i { font-style: normal; color: var(--gold); }
.orow button.on { background: var(--gold); color: #111; border-color: var(--gold); }

@media (max-width: 1100px) {
  /* écrans moyens et mobiles : le manuel devient un tiroir par-dessus la table */
  .table { grid-template-columns: minmax(0, 1fr) 330px; }
  .manual { position: fixed; z-index: 55; left: 0; top: 0; bottom: 0; box-shadow: 10px 0 30px rgb(0 0 0 / .5); }
}
@media (max-width: 800px) {
  .table { grid-template-columns: minmax(0, 1fr); }
  .manual { width: min(320px, 88vw); }
}

/* le panneau ne déborde jamais à droite */
.panel { min-width: 0; overflow-x: hidden; }
.panel > * { min-width: 0; }
.log li { overflow-wrap: anywhere; }

/* téléphone comme caméra */
.phone { display: grid; gap: 6px; }
.phone .qr { background: #fff; border-radius: var(--radius); padding: 6px; width: 180px; justify-self: center; }
.phone .qr svg { display: block; width: 100%; height: auto; }
.phone input { background: var(--sunken); }

/* coupure réseau */
.reconnect { position: absolute; right: 12px; top: 12px; z-index: 25; padding: 6px 14px; border-radius: 999px; background: rgb(120 70 10 / .92); border: 1px solid var(--gold); color: #fff; font-size: 13px; font-weight: 600; box-shadow: var(--shadow-hover); }

/* base de cartes : suggestions et texte officiel */
.card-suggest { position: relative; z-index: 5; display: grid; max-height: 260px; overflow-y: auto; margin-top: -2px; border: 1px solid var(--accent); border-radius: var(--radius); background: var(--surface); box-shadow: var(--shadow-hover); }
.card-suggest button { display: grid; grid-template-columns: auto 1fr; gap: 0 8px; align-items: baseline; text-align: left; border: 0; border-bottom: 1px solid var(--line); border-radius: 0; box-shadow: none; background: transparent; padding: 6px 8px; }
.card-suggest button:hover, .card-suggest button.on { background: color-mix(in srgb, var(--accent) 14%, transparent); }
.card-suggest b { font: 600 11px/1.3 var(--f-mono, monospace); color: var(--gold); }
.card-suggest .cs-name { font-weight: 600; display: flex; align-items: center; gap: 3px; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.card-suggest .cs-name i { width: 8px; height: 8px; border-radius: 50%; flex: none; }
.card-suggest small { grid-column: 2; color: var(--muted); font-size: 11px; }
.zm-text { display: grid; gap: 3px; padding: 7px 9px; border-radius: var(--radius); background: var(--sunken); border: 1px solid var(--line); font-size: 12px; line-height: 1.4; }
.zm-text b { font-size: 12px; }
.zm-text small { color: var(--muted); }
.zm-text p { margin: 2px 0 0; white-space: pre-line; color: var(--fg); }
details.zm-text summary { cursor: pointer; color: var(--muted); }
.zmenu { max-height: calc(100vh - 16px); overflow-y: auto; }
.free-tag { display: inline-block; padding: 0 6px; border-radius: 999px; border: 1px solid #ffb15c; color: #ffb15c; font-size: 11px; }
.log li.free::after { content: " · saisie libre"; color: #ffb15c; font-size: 11px; }
