/* Édition 08 · Sombre sculpté. Ce fichier n’habille l’interface existante qu’en mode dark. */
html[data-appearance="dark"] {
  color-scheme: dark;
  --cream: #0D0D0D;
  --ink: rgba(255,255,255,.87);
  --green: #004D40;
  --lime: #81C784;
  --muted: rgba(255,255,255,.60);
  --line: transparent;
  --paper: #151515;
  --gold: #81C784;
  --surface: #151515;
  --surface-hi: #2A2A2A;
  --surface-low: rgba(0,0,0,.4);
  --accent: #81C784;
  --accent-container: #004D40;
  --shadow-raised: -6px -6px 12px #2A2A2A, 8px 8px 16px rgba(0,0,0,.4);
  --shadow-inset: inset -4px -4px 9px rgba(42,42,42,.72), inset 5px 5px 10px rgba(0,0,0,.52);
  background: #0D0D0D;
  color: rgba(255,255,255,.87);
}
html[data-appearance="dark"] body {
  min-height: 100vh;
  color: rgba(255,255,255,.87);
  background: #0D0D0D;
}
html[data-appearance="dark"] .app { isolation: isolate; }
html[data-appearance="dark"] p,
html[data-appearance="dark"] .help,
html[data-appearance="dark"] .version,
html[data-appearance="dark"] .section-title > span,
html[data-appearance="dark"] .score-item small,
html[data-appearance="dark"] .offline,
html[data-appearance="dark"] footer summary { color: rgba(255,255,255,.60); }
html[data-appearance="dark"] h1,
html[data-appearance="dark"] h2,
html[data-appearance="dark"] h3,
html[data-appearance="dark"] .hero h1,
html[data-appearance="dark"] .how strong,
html[data-appearance="dark"] label,
html[data-appearance="dark"] .brand,
html[data-appearance="dark"] .section-title h2,
html[data-appearance="dark"] footer,
html[data-appearance="dark"] .notice { color: rgba(255,255,255,.87); }
html[data-appearance="dark"] .hero h1 em,
html[data-appearance="dark"] .arrow,
html[data-appearance="dark"] .mode-card .arrow,
html[data-appearance="dark"] .mode-number { color: #81C784; }
html[data-appearance="dark"] .live-dot { background: #81C784; box-shadow: 0 0 0 4px rgba(129,199,132,.16); }
html[data-appearance="dark"] .topbar,
html[data-appearance="dark"] footer { border-color: transparent; }
html[data-appearance="dark"] .brand img { border-radius: 12px; box-shadow: var(--shadow-raised); }
html[data-appearance="dark"] .secret-card,
html[data-appearance="dark"] .mini-card,
html[data-appearance="dark"] .universe,
html[data-appearance="dark"] .mode-card,
html[data-appearance="dark"] .panel,
html[data-appearance="dark"] .score-item,
html[data-appearance="dark"] .word-card,
html[data-appearance="dark"] .lock-art,
html[data-appearance="dark"] .sound-controls,
html[data-appearance="dark"] #taboo-paused,
html[data-appearance="dark"] #relay-wait,
html[data-appearance="dark"] .audio-settings-panel,
html[data-appearance="dark"] .link-card {
  border: 0;
  border-radius: 24px;
  background: #151515;
  color: rgba(255,255,255,.87);
  box-shadow: var(--shadow-raised);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}
html[data-appearance="dark"] .mode-card {
  min-height: 120px;
  padding: 24px 18px;
  text-align: left;
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease;
}
html[data-appearance="dark"] .mode-card:hover,
html[data-appearance="dark"] .universe:hover { transform: translateY(-2px); box-shadow: -4px -4px 9px #2A2A2A, 6px 6px 12px rgba(0,0,0,.42); }
html[data-appearance="dark"] .mode-card:active,
html[data-appearance="dark"] .universe:active,
html[data-appearance="dark"] .primary:active,
html[data-appearance="dark"] .secondary:active,
html[data-appearance="dark"] .responses button:active { transform: translateY(1px); box-shadow: var(--shadow-inset); }
html[data-appearance="dark"] .mode-number { flex: 0 0 auto; font: 700 48px/1 system-ui, sans-serif; letter-spacing: -1px; opacity: 1; }
html[data-appearance="dark"] .mode-card strong { color: rgba(255,255,255,.87); }
html[data-appearance="dark"] .mode-card small,
html[data-appearance="dark"] .universe-body > span:not(.eyebrow),
html[data-appearance="dark"] .universe small { color: rgba(255,255,255,.60); }
html[data-appearance="dark"] .mode-card.featured,
html[data-appearance="dark"] .universe.civil,
html[data-appearance="dark"] .primary,
html[data-appearance="dark"] .word-card,
html[data-appearance="dark"] .secret-card {
  background: #004D40;
  color: rgba(255,255,255,.87);
}
html[data-appearance="dark"] .mode-card.featured { box-shadow: -5px -5px 10px #155d51, 7px 7px 14px rgba(0,0,0,.48); }
html[data-appearance="dark"] .mode-card.featured .mode-number,
html[data-appearance="dark"] .mode-card.featured strong,
html[data-appearance="dark"] .universe.civil strong,
html[data-appearance="dark"] .universe.civil .arrow { color: #81C784; }
html[data-appearance="dark"] .universe-icon,
html[data-appearance="dark"] .step-number,
html[data-appearance="dark"] .rule-pills span,
html[data-appearance="dark"] .stat-pill,
html[data-appearance="dark"] #timesup .tu-round-results,
html[data-appearance="dark"] #link-panel-status {
  border: 0; border-radius: 24px; background: #151515; color: rgba(255,255,255,.87); box-shadow: -3px -3px 7px #252525, 4px 4px 8px rgba(0,0,0,.34);
}
html[data-appearance="dark"] .how { border-color: transparent; }
html[data-appearance="dark"] .primary,
html[data-appearance="dark"] .secondary,
html[data-appearance="dark"] .file-label,
html[data-appearance="dark"] .responses button,
html[data-appearance="dark"] .audio-settings-trigger,
html[data-appearance="dark"] .audio-panel-close,
html[data-appearance="dark"] #connect-devices,
html[data-appearance="dark"] #taboo-pause,
html[data-appearance="dark"] .link-card button,
html[data-appearance="dark"] .link-device,
html[data-appearance="dark"] #link-disconnect {
  min-height: 44px;
  border: 0;
  border-radius: 24px;
  color: rgba(255,255,255,.87);
  background: #151515;
  box-shadow: var(--shadow-raised);
}
html[data-appearance="dark"] .primary { background: #004D40; color: #fff; font-weight: 700; }
html[data-appearance="dark"] .primary:hover,
html[data-appearance="dark"] .mode-card.featured:hover { background: #07594c; }
html[data-appearance="dark"] .secondary,
html[data-appearance="dark"] .file-label,
html[data-appearance="dark"] .responses button,
html[data-appearance="dark"] #connect-devices,
html[data-appearance="dark"] #taboo-pause { background: #151515; }
html[data-appearance="dark"] .secondary:hover,
html[data-appearance="dark"] .file-label:hover,
html[data-appearance="dark"] .responses button:hover,
html[data-appearance="dark"] .audio-settings-trigger:hover { background: #1b1b1b; }
html[data-appearance="dark"] .responses button:first-child { background: #004D40; color: #fff; }
html[data-appearance="dark"] .responses button:nth-child(2) { background: #151515; }
html[data-appearance="dark"] .danger,
html[data-appearance="dark"] .taboo-buttons .danger { color: #ffb4ab; }
html[data-appearance="dark"] .taboo-buttons .danger,
html[data-appearance="dark"] .notice { background: #251b19; }
html[data-appearance="dark"] input,
html[data-appearance="dark"] select,
html[data-appearance="dark"] textarea,
html[data-appearance="dark"] .link-pane input:not([type=checkbox]),
html[data-appearance="dark"] .link-pane textarea {
  color: rgba(255,255,255,.87); background: #151515; border: 0; border-radius: 24px; box-shadow: var(--shadow-inset); min-height: 50px;
}
html[data-appearance="dark"] input::placeholder,
html[data-appearance="dark"] textarea::placeholder { color: rgba(255,255,255,.45); }
html[data-appearance="dark"] input[type="checkbox"],
html[data-appearance="dark"] input[type="range"] { accent-color: #81C784; }
html[data-appearance="dark"] input[type="checkbox"] { width: 22px; min-width: 22px; height: 22px; min-height: 22px; padding: 0; }
html[data-appearance="dark"] .word-card { box-shadow: var(--shadow-inset); }
html[data-appearance="dark"] .word-card > span,
html[data-appearance="dark"] .category-pill,
html[data-appearance="dark"] .timer-row strong { color: #81C784; }
html[data-appearance="dark"] .word { color: rgba(255,255,255,.87); }
html[data-appearance="dark"] .score-item { background: #151515; }
html[data-appearance="dark"] .score-item.active { background: #004D40; border: 0; box-shadow: inset -3px -3px 7px rgba(129,199,132,.12), inset 4px 4px 8px rgba(0,0,0,.34); }
html[data-appearance="dark"] .avatar { background: #004D40; color: #81C784; }
html[data-appearance="dark"] .timer-row strong { background: #151515; border: 0; box-shadow: var(--shadow-raised); }
html[data-appearance="dark"] .timer-row strong.urgent { background: #321f1c; color: #ffb4ab; }
html[data-appearance="dark"] .taboo-list li { border: 0; border-radius: 24px; background: #251b19; color: #ffb4ab; }
html[data-appearance="dark"] .private-panel { border-top: 0; }
html[data-appearance="dark"] .tu-rules { border-color: transparent !important; }
html[data-appearance="dark"] .tu-rules strong { color: #81C784 !important; }
html[data-appearance="dark"] .sound-controls { border: 0; padding: 13px 15px; }
html[data-appearance="dark"] .sound-controls label,
html[data-appearance="dark"] .audio-row,
html[data-appearance="dark"] .audio-settings-panel summary { color: rgba(255,255,255,.87); }
html[data-appearance="dark"] .sound-controls button { min-height: 44px; border: 0; border-radius: 24px; background: #151515; color: rgba(255,255,255,.87); box-shadow: var(--shadow-raised); }
html[data-appearance="dark"] .audio-settings-panel { z-index: 1001; background: #151515; }
html[data-appearance="dark"] .audio-row { border-color: transparent; }
html[data-appearance="dark"] .audio-panel-close { background: #004D40; }
html[data-appearance="dark"] .link-overlay { background: rgba(0,0,0,.76); }
html[data-appearance="dark"] .link-card { border: 0; background: #151515; }
html[data-appearance="dark"] .link-eyebrow { color: #81C784; }
html[data-appearance="dark"] .link-note,
html[data-appearance="dark"] .link-pane p,
html[data-appearance="dark"] .link-pane small { color: rgba(255,255,255,.60); }
html[data-appearance="dark"] .link-tabs { border-radius: 24px; background: #0D0D0D; box-shadow: var(--shadow-inset); }
html[data-appearance="dark"] .link-tabs button[aria-selected="true"],
html[data-appearance="dark"] .link-actions button:first-child { background: #004D40; color: #fff; }
html[data-appearance="dark"] .link-unavailable { border: 0; border-radius: 24px; background: #2b2419; color: #f3c878 !important; }
html[data-appearance="dark"] #link-panel-status[data-connected="true"] { background: #004D40; color: #fff; }
html[data-appearance="dark"] #link-disconnect { color: #ffb4ab; }
html[data-appearance="dark"] #taboo-countdown { background: rgba(13,13,13,.98); color: rgba(255,255,255,.87); }
html[data-appearance="dark"] #taboo-countdown .countdown-number { color: #81C784; }
html[data-appearance="dark"] #taboo-countdown p { color: rgba(255,255,255,.60); }
html[data-appearance="dark"] .toast { border: 0; border-radius: 24px; background: #151515; color: rgba(255,255,255,.87); box-shadow: -3px -3px 8px #2A2A2A, 5px 5px 10px rgba(0,0,0,.44); }
html[data-appearance="dark"] .notice { color: rgba(255,255,255,.87); }
html[data-appearance="dark"] :focus-visible { outline: 3px solid #81C784 !important; outline-offset: 4px !important; }
html[data-appearance="dark"] button:disabled { opacity: .45; }
html[data-appearance="dark"] .mode-card .arrow { right: 13px; top: 10px; }
html[data-appearance="dark"] .celebration-mark { color: #81C784; }
html[data-appearance="dark"] .stat-pill { box-shadow: -2px -2px 5px #252525, 3px 3px 6px rgba(0,0,0,.3); }
html[data-appearance="dark"] .rule-pills span,
html[data-appearance="dark"] .universe-strip span { border: 0; background: #151515; box-shadow: -2px -2px 5px #252525, 3px 3px 6px rgba(0,0,0,.3); }
html[data-appearance="dark"] .text-button { color: #81C784; }
html[data-appearance="dark"] .home-tools .secondary { min-height: 50px; }
html[data-appearance="dark"] #timesup .panel { box-shadow: var(--shadow-raised); }
html[data-appearance="dark"] .gamebar { color: rgba(255,255,255,.60); }

/* Contrôles de thème : neutres en crème, assortis au sculpté en sombre. */
.appearance-trigger {
  position: fixed; z-index: 900; right: max(14px, env(safe-area-inset-right)); bottom: max(14px, env(safe-area-inset-bottom));
  min-width: 48px; min-height: 48px; padding: 10px 15px; border: 0; border-radius: 24px;
  background: #f6f3e9; color: #163d31; font: 700 13px/1.2 system-ui, sans-serif; cursor: pointer;
  box-shadow: 0 4px 18px rgba(0,0,0,.24);
}
.appearance-trigger:focus-visible,.appearance-option:focus-visible,.appearance-close:focus-visible { outline: 3px solid #81C784; outline-offset: 4px; }
.appearance-shade { position: fixed; inset: 0; z-index: 1000; display: grid; place-items: center; overflow: auto; padding: max(20px,env(safe-area-inset-top)) 18px max(20px,env(safe-area-inset-bottom)); background: rgba(0,0,0,.58); }
.appearance-dialog { position: relative; width: min(100%,440px); max-height: min(88dvh,680px); overflow: auto; padding: 30px; border: 0; border-radius: 24px; background: #f6f3e9; color: #163d31; box-shadow: 0 20px 60px rgba(0,0,0,.35); font-family: system-ui,sans-serif; }
.appearance-dialog h2 { margin: 0 42px 8px 0; font-size: 24px; }
.appearance-dialog p { margin: 0 0 20px; line-height: 1.5; color: #52675c; }
.appearance-close { position: absolute; top: 16px; right: 16px; min-width: 44px; min-height: 44px; border: 0; border-radius: 24px; color: inherit; background: rgba(22,61,49,.09); font-size: 25px; cursor: pointer; }
.appearance-options { display: grid; gap: 14px; }
.appearance-option { min-height: 64px; padding: 16px 18px; border: 0; border-radius: 24px; background: #f6f3e9; color: #163d31; box-shadow: -4px -4px 9px rgba(255,255,255,.92), 6px 6px 12px rgba(22,61,49,.16); text-align: left; font: 700 15px system-ui,sans-serif; cursor: pointer; }
.appearance-option[aria-pressed="true"] { box-shadow: inset -3px -3px 7px rgba(255,255,255,.86), inset 4px 4px 9px rgba(22,61,49,.15); }
html[data-appearance="dark"] .appearance-trigger { color: rgba(255,255,255,.87); background: #151515; box-shadow: -4px -4px 9px #2A2A2A, 6px 6px 12px rgba(0,0,0,.45); }
html[data-appearance="dark"] .appearance-shade { background: rgba(0,0,0,.72); }
html[data-appearance="dark"] .appearance-dialog { background: #151515; color: rgba(255,255,255,.87); box-shadow: var(--shadow-raised); }
html[data-appearance="dark"] .appearance-dialog p { color: rgba(255,255,255,.60); }
html[data-appearance="dark"] .appearance-close,
html[data-appearance="dark"] .appearance-option { background: #151515; color: rgba(255,255,255,.87); box-shadow: var(--shadow-raised); }
html[data-appearance="dark"] .appearance-option[aria-pressed="true"] { color: #81C784; background: #004D40; box-shadow: var(--shadow-inset); }
@media (max-width: 600px) {
  html[data-appearance="dark"] .mode-card { padding: 20px 16px; }
  html[data-appearance="dark"] .panel { border-radius: 24px; }
  .appearance-dialog { padding: 26px 20px; }
  .appearance-trigger { right: max(10px,env(safe-area-inset-right)); bottom: max(10px,env(safe-area-inset-bottom)); }
}
@media (max-width: 350px) {
  html[data-appearance="dark"] .mode-number { font-size: 48px; }
  html[data-appearance="dark"] .mode-card { gap: 12px; padding: 18px 13px; }
  .appearance-trigger { min-width: 48px; min-height: 48px; padding: 9px 12px; }
  .appearance-dialog { padding: 24px 16px; }
}
@media (prefers-reduced-motion: reduce) {
  .appearance-trigger,.appearance-option { transition: none !important; }
}

/* Finition édition 8 : système tactile homogène et emplacements non recouvrants. */
html[data-appearance="dark"] { font-family: Roboto, system-ui, sans-serif; --shadow-inset: inset -6px -6px 12px #2A2A2A, inset 8px 8px 16px rgba(0,0,0,.40); }
html[data-appearance="dark"] :is(button,input,select,textarea,summary,.brand img,.avatar,.timer-row strong,.universe-strip span,.rule-pills span,.stat-pill,.step-number,.universe-icon,.category-pill,.taboo-list li) { border-radius:24px; border:0; }
html[data-appearance="dark"] :is(button,summary,.taboo-list li) { box-shadow:var(--shadow-raised); }
html[data-appearance="dark"] :is(button,summary):active { box-shadow:var(--shadow-inset); }
html[data-appearance="dark"] :is(.text-button,summary) { background:#151515; padding:12px 16px; }
html[data-appearance="dark"] :is(.universe-strip span,.rule-pills span,.stat-pill,.category-pill) { display:inline-flex; align-items:center; justify-content:center; min-height:32px; padding:8px 16px; background:#151515; box-shadow:-4px -4px 8px #2A2A2A,6px 6px 12px rgba(0,0,0,.4); }
html[data-appearance="dark"] :is(input,select,textarea,.word-card) { box-shadow:var(--shadow-raised); }
html[data-appearance="dark"] :is(input,select,textarea):focus { box-shadow:var(--shadow-inset); }
html[data-appearance="dark"] :is(.mode-card small,.universe small) { opacity:1; }
html[data-appearance="dark"] :is(.hero h1 em,.word,.secret-card b,.lock-art) { font-family:Roboto,system-ui,sans-serif; }
html[data-appearance="dark"] :is(.secret-card,.word-card) { background:#151515; }
html[data-appearance="dark"] .mode-grid { gap:24px; }
html[data-appearance="dark"] :is(#two-choice,#four-choice) .mode-card { margin:24px 0; }
html[data-appearance="dark"] :is(.responses,.taboo-buttons) { gap:16px; }
html[data-appearance="dark"] .sound-controls { gap:16px; }
html[data-appearance="dark"] .sound-controls label { min-height:44px; }
html[data-appearance="dark"] .audio-row { min-height:44px; }
html[data-appearance="dark"] .scoreboard { gap:16px; }
html[data-appearance="dark"] .gamebar { flex-wrap:wrap; gap:16px; }
.topbar { flex-wrap:wrap; height:auto; min-height:100px; padding:16px 0; gap:12px; }
.topbar .brand { flex:1; }
.topbar .appearance-trigger { position:static; z-index:auto; flex:0 0 auto; }
@media(max-width:600px) { .topbar { min-height:88px; gap:12px; } .topbar .appearance-trigger { min-height:44px; font-size:11px; padding:10px 14px; } .topbar .version { letter-spacing:.5px; } html[data-appearance="dark"] .panel { padding:24px 16px; } html[data-appearance="dark"] .home-tools { gap:16px; } }
@media(max-width:380px) { .topbar .appearance-trigger { margin-left:auto; } .topbar .brand { min-width:180px; } html[data-appearance="dark"] .section-title { gap:12px; } html[data-appearance="dark"] .mode-number { font-size:48px; } }

.relay-running .topbar,.timesup-running .topbar { display:flex; justify-content:flex-end; min-height:56px; padding:6px 0; }
.relay-running .topbar :is(.brand,.version),.timesup-running .topbar :is(.brand,.version) { display:none; }
html[data-appearance="dark"] :is(#link-state,#timesup .tu-round-results) { border:0; border-radius:24px; background:#151515; color:rgba(255,255,255,.87); box-shadow:var(--shadow-raised); }
html[data-appearance="dark"] .rule-pills { gap:16px; }
html[data-appearance="dark"] :is(.brand img,.avatar,.timer-row strong) { border-radius:24px; }
html[data-appearance="dark"] #taboo-countdown .countdown-number { font-family:Roboto,system-ui,sans-serif; }

/* Édition 12 — mêmes proportions dans le thème sculpté. */
html[data-appearance="dark"] .mode-badge{border:0;color:#81c784;background:#151515;box-shadow:-3px -3px 7px #252525,4px 4px 8px rgba(0,0,0,.34)}
html[data-appearance="dark"] .featured .mode-badge{color:#c4efbd;background:#004d40;box-shadow:inset -2px -2px 5px rgba(129,199,132,.08),inset 3px 3px 6px rgba(0,0,0,.25)}
html[data-appearance="dark"] #taboo-countdown .countdown-number{border-color:rgba(129,199,132,.28);box-shadow:inset 0 0 0 9px rgba(129,199,132,.045),0 0 0 10px rgba(129,199,132,.07)}
html[data-appearance="dark"] :is(#two-choice,#four-choice) .mode-badge{font-size:16px}
html[data-appearance="dark"] #two-choice .mode-badge:not([aria-label="Deux manches"]){font-size:19px}
html[data-appearance="dark"] #two-choice .mode-badge[aria-label="Deux manches"]{font-size:20px}

/* Édition 18 — verre émeraude/bleu roi, solaire brutal et actions de jeu tactiles. */
html[data-appearance="glass"]{color-scheme:dark;--cream:#0b426f;--ink:#fff;--green:#a9f5d8;--lime:#b8ffdc;--muted:rgba(255,255,255,.78);--line:rgba(255,255,255,.25);--paper:rgba(255,255,255,.13);--surface:rgba(255,255,255,.12);--accent:#a9f5d8;background:#087e9b;color:#fff}
html[data-appearance="glass"] body{min-height:100vh;color:#fff;background:linear-gradient(132deg,#087e9b 0%,#125db3 54%,#242181 100%);background-attachment:fixed}
html[data-appearance="glass"] .app{min-height:100vh;background:transparent}
html[data-appearance="glass"] :is(#home,#two-choice,#three-choice,#four-choice,#game,#timesup) :is(h1,h2,h3,p,label,.section-title>span,.mode-card strong,.mode-card small,.score-item,.gamebar,.help,.eyebrow,.tu-rules){color:#fff}
html[data-appearance="glass"] :is(#home,#two-choice,#three-choice,#four-choice,#game) :is(.mode-card,.universe,.panel,.score-item,.secret-card,.mini-card,.word-card,.lock-art,.sound-controls,#taboo-paused,#relay-wait){border:1px solid rgba(255,255,255,.42);border-radius:24px;background:linear-gradient(145deg,rgba(255,255,255,.21),rgba(255,255,255,.09));color:#fff;box-shadow:0 16px 38px rgba(4,24,83,.19),inset 0 1px 0 rgba(255,255,255,.38);-webkit-backdrop-filter:blur(14px);backdrop-filter:blur(14px)}
html[data-appearance="glass"] #timesup .panel,html[data-appearance="glass"] #timesup .tu-round-results,html[data-appearance="glass"] #timesup .tu-scores .score-item{border:1px solid rgba(255,255,255,.42);border-radius:24px;background:linear-gradient(145deg,rgba(255,255,255,.21),rgba(255,255,255,.09));color:#fff;box-shadow:0 16px 38px rgba(4,24,83,.19),inset 0 1px 0 rgba(255,255,255,.38);-webkit-backdrop-filter:blur(14px);backdrop-filter:blur(14px)}
html[data-appearance="glass"] :is(#home,#two-choice,#three-choice,#four-choice,#game,#timesup) :is(.primary,.secondary,.file-label,.responses button,.taboo-buttons button,#taboo-pass,#taboo-pause,.text-button,.tu-round-announcement button){min-height:50px;border:1px solid rgba(255,255,255,.52);border-radius:18px;color:#fff;background:rgba(255,255,255,.13);box-shadow:0 7px 18px rgba(8,24,74,.22),inset 0 1px 0 rgba(255,255,255,.2)}
html[data-appearance="glass"] :is(#home,#two-choice,#three-choice,#four-choice,#game,#timesup) :is(.primary,#taboo-correct,.responses button:first-child){color:#062e45;background:linear-gradient(135deg,#b5fadd,#d5fff0);font-weight:850}
html[data-appearance="glass"] :is(#home,#two-choice,#three-choice,#four-choice,#game,#timesup) :is(.primary,.secondary,.responses button,.taboo-buttons button,#taboo-pass,#taboo-pause,.text-button):active{transform:translateY(2px);box-shadow:inset 0 2px 6px rgba(5,30,80,.28)}
html[data-appearance="glass"] #home .secret-card,html[data-appearance="glass"] #game .word-card{background:linear-gradient(145deg,rgba(255,255,255,.24),rgba(14,69,133,.25));}
html[data-appearance="glass"] :is(#home,#two-choice,#three-choice,#four-choice,#game,#timesup) :is(.mode-number,.arrow,.category-pill,.timer-row strong,.avatar,.mode-badge){color:#c4ffe5}
html[data-appearance="glass"] #game .score-item.active,html[data-appearance="glass"] #timesup .tu-scores .score-item.active{border-color:#cbffe8;background:rgba(160,255,219,.22);box-shadow:0 0 0 2px rgba(195,255,232,.22),0 12px 28px rgba(5,28,79,.2)}
html[data-appearance="glass"] :is(#home,#two-choice,#three-choice,#four-choice,#game,#timesup) :focus-visible{outline:3px solid #e1fff2!important;outline-offset:4px!important}
html[data-appearance="glass"] .settings-dialog{border:1px solid rgba(255,255,255,.35);color:#fff;background:linear-gradient(145deg,#125b91,#272576);box-shadow:0 22px 70px rgba(0,0,0,.4)}
html[data-appearance="glass"] .settings-header h2,html[data-appearance="glass"] .settings-section h3,html[data-appearance="glass"] .settings-field label,html[data-appearance="glass"] .settings-motion-row label{color:#fff}
html[data-appearance="glass"] .settings-section,html[data-appearance="glass"] .settings-header{border-color:rgba(255,255,255,.25)}
html[data-appearance="glass"] .settings-field,html[data-appearance="glass"] .settings-motion-row,html[data-appearance="glass"] .settings-close,html[data-appearance="glass"] .settings-done{color:#fff;background:rgba(255,255,255,.12);border-color:rgba(255,255,255,.28)}

html[data-appearance="brutal"]{color-scheme:light;--cream:#fff8dc;--ink:#111;--green:#ffd000;--lime:#39ff14;--muted:#3c3420;--line:#111;--paper:#fff;--surface:#fff;--accent:#ffd000;background:#fff8dc;color:#111}
html[data-appearance="brutal"] body{min-height:100vh;color:#111;background:radial-gradient(circle at 86% 2%,#ffe471 0,transparent 28%),#fff8dc}
html[data-appearance="brutal"] .app{min-height:100vh;background:transparent}
html[data-appearance="brutal"] :is(#home,#two-choice,#three-choice,#four-choice,#game,#timesup) :is(h1,h2,h3,p,label,.section-title>span,.mode-card strong,.mode-card small,.score-item,.gamebar,.help,.eyebrow,.tu-rules){color:#111}
html[data-appearance="brutal"] :is(#home,#two-choice,#three-choice,#four-choice,#game) :is(.mode-card,.universe,.panel,.score-item,.secret-card,.mini-card,.word-card,.lock-art,.sound-controls,#taboo-paused,#relay-wait){border:3px solid #111;border-radius:10px;background:#fff;color:#111;box-shadow:6px 6px 0 #111}
html[data-appearance="brutal"] #timesup .panel,html[data-appearance="brutal"] #timesup .tu-round-results,html[data-appearance="brutal"] #timesup .tu-scores .score-item{border:3px solid #111;border-radius:10px;background:#fff;color:#111;box-shadow:6px 6px 0 #111}
html[data-appearance="brutal"] :is(#home,#two-choice,#three-choice,#four-choice,#game,#timesup) :is(.primary,.secondary,.file-label,.responses button,.taboo-buttons button,#taboo-pass,#taboo-pause,.text-button,.tu-round-announcement button){min-height:52px;border:3px solid #111;border-radius:7px;color:#111;background:#fff;box-shadow:5px 5px 0 #111;font-weight:850}
html[data-appearance="brutal"] :is(#home,#two-choice,#three-choice,#four-choice,#game,#timesup) :is(.primary,#taboo-correct,.responses button:first-child){background:#ffd000;color:#111}
html[data-appearance="brutal"] :is(#home,#two-choice,#three-choice,#four-choice,#game,#timesup) :is(.primary,.secondary,.responses button,.taboo-buttons button,#taboo-pass,#taboo-pause,.text-button):active{transform:translate(3px,3px);box-shadow:2px 2px 0 #111}
html[data-appearance="brutal"] #home .secret-card,html[data-appearance="brutal"] #game .word-card{background:#39ff14;color:#111}
html[data-appearance="brutal"] :is(#home,#two-choice,#three-choice,#four-choice,#game,#timesup) :is(.mode-number,.arrow,.category-pill,.timer-row strong,.avatar,.mode-badge){color:#111}
html[data-appearance="brutal"] #game .score-item.active,html[data-appearance="brutal"] #timesup .tu-scores .score-item.active{background:#ffd000;box-shadow:inset 0 0 0 2px #111,5px 5px 0 #111}
html[data-appearance="brutal"] :is(#home,#two-choice,#three-choice,#four-choice,#game,#timesup) :focus-visible{outline:3px solid #111!important;outline-offset:4px!important}
html[data-appearance="brutal"] .settings-dialog{border:3px solid #111;border-radius:10px;color:#111;background:#fff8dc;box-shadow:8px 8px 0 #111}
html[data-appearance="brutal"] .settings-header h2,html[data-appearance="brutal"] .settings-section h3,html[data-appearance="brutal"] .settings-field label,html[data-appearance="brutal"] .settings-motion-row label{color:#111}
html[data-appearance="brutal"] .settings-section,html[data-appearance="brutal"] .settings-header{border-color:#111}
html[data-appearance="brutal"] .settings-field,html[data-appearance="brutal"] .settings-motion-row,html[data-appearance="brutal"] .settings-close,html[data-appearance="brutal"] .settings-done{color:#111;border:2px solid #111;border-radius:7px;background:#fff;box-shadow:3px 3px 0 #111}

/* Tactile relay layout: large +1 first, pass/pause separated, and team rows wrap to six. */
.taboo-buttons{display:flex;flex-direction:column;gap:12px}
#taboo-correct{min-height:68px!important;font-size:clamp(20px,5vw,26px)!important;font-weight:900!important;letter-spacing:.01em}
#taboo-wrong{min-height:56px!important}
#taboo-pass{display:flex;align-items:center;justify-content:center;box-sizing:border-box;width:100%;min-height:58px;margin-top:24px;padding:14px 16px;font-size:16px;font-weight:800}
#pass-help{margin:10px auto 22px;max-width:36rem}
#taboo-pause{min-height:56px;padding:13px 16px;font-size:15px;font-weight:750}
#game .scoreboard,#timesup .tu-scores{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,135px),1fr));gap:12px;max-width:100%}
#game .score-item,#timesup .tu-scores .score-item{box-sizing:border-box;min-width:0;overflow-wrap:anywhere}
#timesup .tu-round-results{margin:16px 0;padding:16px;border-radius:18px}
.tu-round-announcement{width:min(100%,560px);margin:clamp(12px,4vh,30px) auto;padding:clamp(20px,5vw,34px);border:1px solid var(--line);border-radius:24px;background:var(--paper);color:var(--ink);box-shadow:var(--shadow-raised);text-align:center}
.tu-round-announcement[hidden]{display:none!important}
.tu-round-announcement h1,.tu-round-announcement h2{margin:0 0 12px}
.tu-round-announcement p{margin:8px 0;line-height:1.5}
html[data-appearance="glass"] .tu-round-announcement{border-color:rgba(255,255,255,.48);background:rgba(255,255,255,.16);color:#fff;box-shadow:0 18px 40px rgba(4,24,83,.2);-webkit-backdrop-filter:blur(14px);backdrop-filter:blur(14px)}
html[data-appearance="brutal"] .tu-round-announcement{border:3px solid #111;border-radius:10px;background:#fff;box-shadow:6px 6px 0 #111;color:#111}
@media(max-width:600px){html[data-appearance="glass"] :is(#home,#two-choice,#three-choice,#four-choice,#game,#timesup) :is(.mode-card,.universe,.panel,.score-item,.secret-card,.mini-card,.word-card,.lock-art,.sound-controls,#taboo-paused,#relay-wait),html[data-appearance="glass"] #timesup .tu-round-results,html[data-appearance="glass"] #timesup .panel{backdrop-filter:none;-webkit-backdrop-filter:none}}
@media(max-width:350px){.taboo-buttons{gap:10px}#taboo-correct{min-height:64px!important}#taboo-pass,#taboo-pause{min-height:54px}#game .scoreboard,#timesup .tu-scores{gap:8px}}
@media(prefers-reduced-motion:reduce){.taboo-buttons :is(button),#taboo-pass,#taboo-pause,#game .score-item,#timesup .tu-scores .score-item{transition:none!important;animation:none!important}}
html[data-motion="reduce"] .taboo-buttons :is(button),html[data-motion="reduce"] #taboo-pass,html[data-motion="reduce"] #taboo-pause{transition:none!important;animation:none!important}

/* E18: garde physique entre la validation et la passe, dans tous les thèmes. */
#timesup .tu-turn-actions{display:grid!important;grid-template-columns:1fr!important;gap:28px!important;column-gap:28px!important;row-gap:28px!important}
html[data-appearance] :is(#three-choice) .mode-card{min-height:108px}

#timesup .tu-turn-actions .tu-action-found{min-height:68px!important}
#timesup .tu-turn-actions .tu-action-pass{min-height:56px!important}
#taboo-play :is(#taboo-pass,#taboo-pause){min-height:56px!important}

#timesup .tu-turn-actions>button{margin:0!important;width:100%}

/* Édition30 : libellé lisible sur la carte solaire, sans modifier ses couleurs approuvées. */
html[data-appearance="brutal"] #game .word-card>span{color:#111}

/* Édition30 — R16/R17 : lisibilité locale, surfaces et identité inchangées. */
html:not([data-appearance]) #game .word-card :is(#secret-word,#secret-category),
html[data-appearance="cream"] #game .word-card :is(#secret-word,#secret-category) {color:var(--cream)}
html[data-appearance="glass"] #settings-dialog :is(.audio-row,.audio-settings-panel label,.audio-settings-panel summary),
html[data-appearance="glass"] #test-sound {color:var(--a28-global-ink)}
