/* (17/11/2026) Practicar con la tabla del tema: tres juegos (tabla-practica.js) */
.tp-ov { position: fixed; inset: 0; z-index: 85; display: grid; place-items: center; padding: 18px; background: rgba(20, 16, 40, .5); backdrop-filter: blur(3px); animation: enter .2s both; }
.tp { width: min(780px, 100%); max-height: calc(100vh - 36px); display: flex; flex-direction: column; border-radius: 24px; overflow: hidden; background: var(--paper, #f8f3ea); box-shadow: 0 24px 60px rgba(20, 16, 40, .35); animation: enter .3s both; }
.tp-h { display: flex; align-items: center; gap: 12px; padding: 14px 16px 12px 18px; background: linear-gradient(135deg, #f07a1a, #e8542f); color: #fff; }
.tp-h img { width: 52px; height: auto; image-rendering: pixelated; margin: -6px 0 -10px; }
.tp-h > div { flex: 1; min-width: 0; display: grid; gap: 2px; }
.tp-tag { font: 800 17px/1.15 var(--display); }
.tp-h small { font-size: 13px; opacity: .9; font-weight: 600; }
.tp-x { width: 38px; height: 38px; border-radius: 12px; border: 0; background: rgba(255, 255, 255, .22); color: #fff; font-size: 16px; cursor: pointer; }
.tp-x:hover { background: rgba(255, 255, 255, .34); }
.tp-bar { height: 5px; background: rgba(240, 122, 26, .18); }
.tp-bar i { display: block; height: 100%; background: #f07a1a; transition: width .3s; }
.tp-b { padding: 20px 22px 8px; overflow: auto; }
.tp-menu { display: grid; gap: 12px; padding-bottom: 20px; }
.tp-mode { display: flex; align-items: center; gap: 14px; width: 100%; padding: 15px 16px; border-radius: 18px; border: 1.5px solid color-mix(in srgb, var(--mc) 35%, transparent); background: color-mix(in srgb, var(--mc) 9%, var(--card, #fff)); color: var(--ink); text-align: left; cursor: pointer; box-shadow: 0 3px 0 color-mix(in srgb, var(--mc) 35%, transparent); transition: transform .12s; }
.tp-mode:hover { transform: translateY(-2px); }
.tp-mode:active { transform: translateY(2px); box-shadow: none; }
.tp-mode .tp-mi { width: 46px; height: 46px; flex: none; display: grid; place-items: center; border-radius: 14px; background: var(--mc); font-size: 23px; }
.tp-mode span:not(.tp-mi) { flex: 1; display: grid; gap: 3px; }
.tp-mode b { font: 800 18px/1.15 var(--display); }
.tp-mode small { color: var(--ink-soft); font-size: 14px; }
.tp-mode i { font-style: normal; font-size: 20px; color: var(--mc); font-weight: 800; }
.tp-none { margin: 0 0 6px; padding: 10px 14px; border-radius: 12px; background: var(--tint-warn, #fff4d6); font-weight: 600; }
.tp-q { margin: 0 0 12px; font: 700 20px/1.3 var(--display); color: var(--ink); }
.tp-sub { margin: -4px 0 12px; }
.tp-col { display: inline-flex; align-items: center; gap: 4px; padding: 2px 9px; border-radius: 999px; background: color-mix(in srgb, var(--cc) 14%, transparent); color: color-mix(in srgb, var(--cc) 70%, var(--ink)); font: 700 12.5px/1.5 var(--text); white-space: nowrap; }
.tp-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 8px; padding: 10px; border-radius: 16px; border-left: 5px solid var(--fc); background: color-mix(in srgb, var(--fc) 7%, var(--card, #fff)); margin-bottom: 16px; }
.tp-cell { display: grid; gap: 6px; align-content: start; padding: 10px 12px; border-radius: 12px; background: var(--card, #fff); border: 1px solid var(--line); font-size: 15.5px; line-height: 1.4; }
.tp-cell.dist { border: 2px solid #f07a1a; background: #fff6ec; }
.tp-cell.dim { opacity: .62; font-size: 14px; }
.tp-cell.hole { border: 2px dashed #f07a1a; background: #fff6ec; }
.tp-cell.hole > div { font: 800 26px/1 var(--display); color: #f07a1a; text-align: center; padding: 6px 0; }
.tp-opts { display: grid; gap: 10px; }
.tp-opts.two { grid-template-columns: 1fr 1fr; }
.tp-opt { display: flex; align-items: flex-start; gap: 12px; width: 100%; padding: 12px 14px; border-radius: 14px; border: 1.5px solid var(--line); background: var(--card, #fff); color: var(--ink); font-size: 15.5px; line-height: 1.4; text-align: left; cursor: pointer; box-shadow: 0 2px 0 var(--line); }
.tp-opt:hover:not([disabled]) { border-color: #f07a1a; }
.tp-opt .tp-k { width: 26px; height: 26px; flex: none; display: grid; place-items: center; border-radius: 8px; background: var(--soft); font: 800 13px/1 var(--text); }
.tp-opt.ok { border-color: var(--good); background: var(--tint-good); }
.tp-opt.ok .tp-k { background: var(--good); color: #fff; }
.tp-opt.ko { border-color: var(--bad); background: var(--tint-bad); }
.tp-opt.ko .tp-k { background: var(--bad); color: #fff; }
.tp-opt.fold { opacity: .5; }
.tp-opt[disabled] { cursor: default; }
.tp-res { margin: 14px 0 10px; padding: 10px 14px; border-radius: 12px; font-weight: 800; }
.tp-res.ok { background: var(--tint-good); color: var(--good-ink); }
.tp-res.ko { background: var(--tint-bad); color: var(--bad-ink); }
.tp-ans { display: grid; gap: 6px; margin-bottom: 14px; padding: 12px 14px; border-radius: 14px; border-left: 5px solid var(--fc); background: color-mix(in srgb, var(--fc) 8%, var(--card, #fff)); font-size: 14.5px; line-height: 1.45; }
.tp-ans > b { font: 800 17px/1.2 var(--display); }
.tp-ans.two { grid-template-columns: 1fr 1fr; border: 0; padding: 0; background: none; }
.tp-ans.two > div { display: grid; gap: 4px; padding: 10px 12px; border-radius: 12px; border-left: 5px solid var(--fc); background: color-mix(in srgb, var(--fc) 8%, var(--card, #fff)); }
.tp-f { display: flex; justify-content: flex-end; align-items: center; gap: 10px; flex-wrap: wrap; padding: 12px 18px 16px; border-top: 1px solid var(--line); color: var(--ink-soft); font-size: 13.5px; }
.tp-next, .tp-alt { padding: 11px 18px; border-radius: 14px; font: 800 15px/1 var(--text); cursor: pointer; }
.tp-next { border: 0; background: #f07a1a; color: #fff; box-shadow: 0 4px 0 #c96a0e; }
.tp-next:active { transform: translateY(3px); box-shadow: 0 1px 0 #c96a0e; }
.tp-alt { border: 1.5px solid var(--line); background: var(--card, #fff); color: var(--ink); }
.tp-score { display: grid; justify-items: center; gap: 2px; padding: 8px 0 16px; }
.tp-score b { font: 800 56px/1 var(--display); color: #f07a1a; }
.tp-score b span { font-size: 28px; color: var(--ink-soft); }
.tp-score small { font-weight: 700; color: var(--ink-soft); }
.tp-fh { margin: 6px 0 8px; font: 800 15px/1.2 var(--display); }
.tp-fails { margin: 0 0 12px; padding: 0; list-style: none; display: grid; gap: 8px; }
.tp-fails li { padding: 9px 12px; border-radius: 12px; background: var(--card, #fff); border: 1px solid var(--line); font-size: 14.5px; line-height: 1.45; }
.tp-ft { display: inline-block; margin-right: 6px; padding: 1px 8px; border-radius: 999px; background: #fff0e0; color: #b4560c; font-size: 12px; font-weight: 800; }
.tp-fails em { color: var(--ink-soft); font-style: normal; }
.tp-perfect { text-align: center; font: 800 18px/1.3 var(--display); }
.rs-prac { background: #f07a1a !important; border-color: #c96a0e !important; color: #fff !important; box-shadow: 0 4px 0 #c96a0e !important; }
.rs-prac:active { transform: translateY(3px); box-shadow: 0 1px 0 #c96a0e !important; }
@media (max-width: 640px) {
  .tp-ov { padding: 0; align-items: end; }
  .tp { border-radius: 22px 22px 0 0; max-height: 94vh; }
  .tp-b { padding: 16px 14px 6px; }
  .tp-q { font-size: 18px; }
  .tp-opts.two, .tp-ans.two { grid-template-columns: 1fr; }
}
