/* Small header decorations; score and remaining hands are the main content. */
#modal[data-kind='result'] { width:min(500px,calc(100% - 28px)); padding:20px; background:var(--felt-pattern),var(--table-top); }
#modal[data-kind='result'] .modal-close { top:12px; right:12px; z-index:2; }
.result-panel { --result-accent:var(--gold); color:var(--felt-text); }
.result-panel[data-outcome='loss'] { --result-accent:color-mix(in srgb,var(--felt-text) 40%,#699eba 60%); }
.result-panel[data-outcome='draw'] { --result-accent:var(--felt-muted); }
.result-heading { display:flex; align-items:center; justify-content:space-between; gap:12px; min-height:68px; padding:0 32px 10px 0; border-bottom:1px solid var(--result-accent); }
.result-heading-copy { min-width:0; flex:1 1 auto; }
.result-heading .modal-title { margin:0 0 4px; padding:0; color:var(--felt-text); font-size:22px; line-height:1.25; white-space:normal; overflow-wrap:normal; }
.result-round { margin:0; color:var(--felt-muted); font-size:13px; line-height:1.4; }
.result-outcome { display:flex; align-items:center; justify-content:flex-end; gap:7px; flex:none; color:var(--result-accent); }
.result-outcome>strong { font-size:22px; line-height:1.2; white-space:nowrap; }
.result-badge-art { display:grid; place-items:center; width:60px; height:60px; flex:none; transform-origin:50% 65%; }
.result-badge-icon { display:block; width:100%; height:100%; object-fit:contain; image-rendering:pixelated; filter:drop-shadow(1px 2px 0 #0005); }
.result-panel .result-score { display:grid; grid-template-columns:minmax(0,1fr) auto minmax(0,1fr); gap:14px; margin:14px 16px 6px; color:var(--felt-text); }
.result-panel .result-score>div { min-width:0; gap:4px; }
.result-panel .result-score>div small { color:var(--felt-text); font-size:18px; line-height:1.3; max-width:100%; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.result-panel .result-score>div b { font-size:60px; line-height:1.05; text-shadow:3px 3px 0 #0006; }
.result-panel .result-score>span { color:var(--felt-muted); padding-top:24px; font-size:40px; line-height:1; }
.result-reason { margin:6px 0 12px; text-align:center; color:var(--felt-text); font-size:16px; line-height:1.5; text-wrap:pretty; }
.result-panel .result-hands { margin:12px 0; padding:0 12px; border:1px solid color-mix(in srgb,var(--result-accent) 55%,transparent); background:color-mix(in srgb,var(--table-top) 90%,#000 10%); }
.result-panel .result-hands>section { padding:9px 0; }
.result-panel .result-hands>section+section { border-top:1px solid color-mix(in srgb,var(--result-accent) 35%,transparent); }
.result-panel .result-hands>section>div:first-child { margin-bottom:6px; color:var(--felt-text); font-size:16px; }
.result-panel .result-hands>section>div:first-child>strong { min-width:0; overflow-wrap:anywhere; }
.result-panel .result-hands>section>div:first-child>span { flex:none; white-space:nowrap; color:var(--result-accent); font-size:17px; }
.result-panel .mini-hand>small { color:var(--felt-muted); font-size:16px; }
.result-panel .mini-hand { min-height:24px; }
.result-panel .choice-row { margin-top:14px; gap:10px; }
.result-panel .choice-row>button { min-height:44px; font-size:16px; }
.result-panel #result-fairness { margin-top:8px; font-size:14px; color:var(--result-accent); }
.result-panel .fives-round-gains { flex-wrap:wrap; gap:4px 12px; color:var(--felt-text); }
.result-panel .fives-round-gains>span { min-width:0; overflow-wrap:anywhere; }
.result-panel .settlement-note { margin:12px 0; padding:8px 12px; }
@media(max-width:470px) {
  #modal[data-kind='result'] { width:calc(100% - 24px); max-height:calc(100dvh - 24px); padding:17px 14px 14px; }
  #modal[data-kind='result'] .modal-close { top:8px; right:8px; width:27px; height:27px; }
  .result-heading { gap:8px; min-height:62px; padding-right:32px; padding-bottom:8px; }
  .result-heading .modal-title { font-size:20px; }
  .result-round { font-size:12px; }
  .result-badge-art { width:48px; height:48px; }
  .result-outcome { gap:3px; }
  .result-outcome>strong { font-size:18px; }
  .result-panel .result-score { margin:12px 6px 6px; gap:10px; }
  .result-panel .result-score>div small { font-size:17px; }
  .result-panel .result-score>div b { font-size:52px; }
  .result-panel .result-score>span { font-size:34px; padding-top:25px; }
  .result-reason { font-size:15px; margin-bottom:10px; }
  .result-panel .result-hands { padding-inline:11px; }
  .result-panel .result-hands>section>div:first-child { font-size:14px; }
  .result-panel .result-hands>section>div:first-child>span,.result-panel .mini-hand>small { font-size:14px; }
  .result-panel .choice-row { gap:10px; margin-top:12px; }
  .result-panel .choice-row>button { min-height:45px; font-size:16px; }
}
@media(prefers-reduced-motion:reduce) { .result-badge-art { transform:none !important; } }
.reduced-motion .result-badge-art { transform:none !important; }
