/**
 * smgr/css/pages/eltapado.css — estilos del mini-juego "El Tapado"
 * portado al chrome "Foco". Mismo recipe que masomenos.css:
 *   · :root con las variables --g-* sin scope (custom props globales inofensivas).
 *   · body { background } del original pasa a .game-scope { background }.
 *   · TODO el resto de selectores prefijado con ".game-scope " para aislar.
 *   · Reset de aislamiento arriba (img, button) contra rincon.css.
 *   · Se elimina .logo-main (era del chrome del sitio clásico).
 */

/* ===== Variables del juego (globales, sin scope) ===== */
:root { --g-navy:#1e3a5f; --g-navy2:#2c5282; --g-orange:#ed8936; --g-ok:#16a34a; --g-close:#f59e0b; --g-bad:#ef4444;
    --g-bg:#eef2f8; --g-surface:#fff; --g-border:#e2e8f0; --g-muted:#64748b; --g-ink:#0f172a; }

/* ===== Reset de aislamiento (contrarresta rincon.css dentro del juego) ===== */
.game-scope img { max-width: none; }
.game-scope button { font: inherit; }

/* Fondo inmersivo del juego (antes en body). Solo cubre el área de juego. */
.game-scope { background: var(--g-bg); }

.game-scope #et-app { max-width: 860px; margin: 16px auto 40px; padding: 0 12px; font-family: Roboto, sans-serif; color: var(--g-ink); }
.game-scope #state-game, .game-scope #state-over { max-width: 640px; margin-left: auto; margin-right: auto; }

/* hero */
.game-scope .et-hero { background:linear-gradient(135deg,var(--g-navy),var(--g-navy2)); color:#fff; border-radius:16px; padding:26px 22px; text-align:center; position:relative; overflow:hidden; box-shadow:0 4px 16px rgba(15,23,42,.08); }
.game-scope .et-hero .wm { font-family:'Space Grotesk',sans-serif; font-weight:700; font-size:clamp(2rem,7vw,2.7rem); letter-spacing:-.02em; line-height:1; }
.game-scope .et-hero .wm b { color:var(--g-orange); font-weight:700; }
.game-scope .et-hero .hero-lockup { display:block; height:74px; max-width:92%; margin:0 auto; }
.game-scope .et-hero .sub { margin:12px auto 0; max-width:470px; opacity:.92; font-size:14.5px; line-height:1.45; }
.game-scope .challenge-badge { display:inline-block; background:var(--g-orange); color:#1f2937; font-weight:700; font-size:12px; letter-spacing:.06em; padding:4px 12px; border-radius:999px; margin-bottom:8px; }

/* landing */
.game-scope .et-card { background:var(--g-surface); border-radius:16px; box-shadow:0 4px 16px rgba(15,23,42,.07); padding:20px; }
.game-scope .et-body { margin-top:14px; }
.game-scope .guest-block { margin:0 auto 16px; max-width:340px; }
.game-scope .guest-block label { font-size:13px; font-weight:700; color:var(--g-muted); display:block; margin-bottom:4px; }
.game-scope .guest-block input { width:100%; padding:11px 13px; border:2px solid var(--g-border); border-radius:10px; font-size:16px; }
.game-scope .guest-block input:focus { outline:none; border-color:var(--g-navy2); }
.game-scope .guest-hint { font-size:12px; color:var(--g-muted); margin-top:4px; }
.game-scope .guest-err { display:none; font-size:12px; color:#dc2626; font-weight:600; margin-top:4px; }
.game-scope .guest-block.error input { border-color:#dc2626; box-shadow:0 0 0 3px rgba(220,38,38,.15); }
.game-scope .guest-block.error .guest-hint { display:none; }
.game-scope .guest-block.error .guest-err { display:block; }
.game-scope .mode-picker { display:grid; grid-template-columns:1fr 1fr; gap:12px; }
.game-scope .mode-card { background:#f8fafc; border:2px solid var(--g-border); border-radius:14px; padding:16px; cursor:pointer; display:flex; flex-direction:column; gap:9px; transition:.15s; }
.game-scope .mode-card:hover { transform:translateY(-2px); box-shadow:0 8px 20px rgba(30,58,95,.12); background:#fff; }
.game-scope .mode-daily:hover { border-color:var(--g-orange); } .game-scope .mode-libre:hover { border-color:var(--g-navy2); }
.game-scope .mc-head { display:flex; align-items:center; gap:10px; font-weight:700; font-size:16px; }
.game-scope .mc-ico { width:32px; height:32px; border-radius:9px; display:inline-flex; align-items:center; justify-content:center; font-size:16px; flex:0 0 32px; }
.game-scope .mode-daily .mc-ico { background:#fed7aa; color:#c2410c; } .game-scope .mode-libre .mc-ico { background:#dbeafe; color:var(--g-navy2); }
.game-scope .mc-desc { font-size:12.5px; color:#475569; line-height:1.4; }
.game-scope .mc-rec { font-size:12px; color:#475569; padding:5px 9px; background:#fff; border-radius:6px; border:1px dashed #cbd5e1; }
.game-scope .mc-cta { margin-top:auto; align-self:stretch; text-align:center; font-weight:700; font-size:13.5px; color:#fff; padding:10px; border-radius:10px; }
.game-scope .mode-daily .mc-cta { background:linear-gradient(135deg,var(--g-orange),#dd6b20); } .game-scope .mode-libre .mc-cta { background:linear-gradient(135deg,var(--g-navy2),var(--g-navy)); }
.game-scope .mode-card.done { background:#f1f5f9; border-color:#cbd5e1; } .game-scope .mode-card.done .mc-ico { background:#dcfce7; color:var(--g-ok); }
.game-scope .mode-card.highlight { border-color:var(--g-navy2); box-shadow:0 4px 14px rgba(44,82,130,.14); }
.game-scope .mc-cta.ghost { background:#e2e8f0; color:var(--g-navy); }
.game-scope .et-hub { text-align:center; margin-top:16px; } .game-scope .et-hub a { color:var(--g-muted); font-weight:600; font-size:13px; text-decoration:none; } .game-scope .et-hub a:hover { text-decoration:underline; }

/* landing leaderboards */
.game-scope .et-boards { display:grid; grid-template-columns:repeat(3,1fr); gap:12px; margin-top:18px; }
.game-scope .board { background:#f8fafc; border:1px solid var(--g-border); border-radius:12px; padding:12px 14px; }
.game-scope .board h4 { margin:0 0 2px; font-size:13px; font-weight:700; color:var(--g-navy); text-transform:uppercase; letter-spacing:.04em; }
.game-scope .board-sub { font-size:11px; color:var(--g-muted); margin:0 0 8px; }
.game-scope .board .nm-sub { color:var(--g-muted); font-weight:400; }
.game-scope .board ol { margin:0; padding-left:0; list-style:none; counter-reset:r; }
.game-scope .board li { display:flex; justify-content:space-between; gap:8px; font-size:13px; padding:3px 0; border-bottom:1px dashed #e8edf3; counter-increment:r; }
.game-scope .board li:last-child { border-bottom:none; }
.game-scope .board li .nm { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.game-scope .board li .nm::before { content:counter(r) ". "; color:var(--g-muted); }
.game-scope .board li .st { font-weight:700; color:var(--g-ok); font-family:'Space Grotesk',sans-serif; white-space:nowrap; }
.game-scope .board .empty { font-size:12px; color:var(--g-muted); padding:6px 0; }
.game-scope .board-all { display:inline-block; margin-top:9px; font-size:12.5px; font-weight:700; color:var(--g-navy2); text-decoration:none; }
.game-scope .board-all:hover { text-decoration:underline; } .game-scope .board-all i { font-size:11px; margin-left:3px; }
@media (max-width:560px){ .game-scope .et-boards { grid-template-columns:1fr; } }

/* ===== game ===== */
.game-scope #state-game { display:none; }
.game-scope .et-top { display:flex; align-items:center; justify-content:space-between; margin-bottom:12px; gap:8px; }
.game-scope .et-top .mode-pill { font-size:12px; font-weight:700; color:#fff; background:var(--g-navy2); padding:4px 11px; border-radius:999px; }
.game-scope .et-top .mode-pill.daily { background:var(--g-orange); color:#1f2937; }
.game-scope .et-top .left { font-family:'Space Grotesk',sans-serif; font-weight:700; font-size:15px; }
.game-scope .et-top .left b { font-size:22px; color:var(--g-navy2); }
.game-scope .et-guess-btn { display:flex; align-items:center; justify-content:center; gap:9px; width:100%; background:linear-gradient(135deg,var(--g-navy2),var(--g-navy)); color:#fff; border:none; border-radius:12px; padding:14px; font-weight:700; font-size:16px; cursor:pointer; margin-bottom:14px; }
.game-scope .et-guess-btn:disabled { opacity:.5; cursor:default; }
.game-scope .et-table-wrap { overflow-x:auto; -webkit-overflow-scrolling:touch; padding-bottom:4px; }
.game-scope .et-table { display:inline-block; min-width:100%; }
.game-scope .et-row { display:grid; grid-template-columns:100px repeat(7,56px); gap:5px; margin-bottom:5px; }
.game-scope .et-head .et-th { font-size:9px; font-weight:700; text-transform:uppercase; color:var(--g-muted); text-align:center; align-self:end; line-height:1.05; padding-bottom:2px; }
.game-scope .et-name { font-size:12px; font-weight:600; display:flex; align-items:center; padding:0 7px; background:#f1f5f9; border-radius:8px; overflow:hidden; white-space:nowrap; text-overflow:ellipsis; }
.game-scope .et-name.ok { background:#dcfce7; color:#065f46; }
.game-scope .et-tile { height:54px; border-radius:8px; display:flex; flex-direction:column; align-items:center; justify-content:center; text-align:center; font-size:10px; font-weight:700; color:#fff; line-height:1.08; padding:2px; }
/* OJO: NO usar la clase `close` (Bootstrap 3 .close => opacity:.2 + float:right). Prefijo et-. */
.game-scope .et-tile.et-hit { background:var(--g-ok); } .game-scope .et-tile.et-close { background:var(--g-close); color:#1f2937; } .game-scope .et-tile.et-miss { background:#64748b; }
.game-scope .et-tile .ar { font-size:13px; line-height:1; }
.game-scope .et-tile .tt-sh { width:19px; height:19px; background:#fff; border-radius:3px; object-fit:contain; margin:1px; }
.game-scope .et-empty-hint { text-align:center; color:var(--g-muted); font-size:12.5px; line-height:1.45; padding:14px 4px; }
.game-scope .et-surrender { display:block; margin:14px auto 0; background:#eef2f8; color:var(--g-navy); border:none; border-radius:10px; padding:9px 16px; font-weight:700; font-size:13.5px; cursor:pointer; }

/* search modal (móvil: anclado arriba + cap visualViewport) */
.game-scope .et-search-back { position:fixed; inset:0; background:rgba(15,23,42,.5); display:none; align-items:flex-start; justify-content:center; z-index:9999; }
.game-scope .et-search-back.et-open { display:flex; }
@media (min-width:560px){ .game-scope .et-search-back.et-open { align-items:center; } }
.game-scope .et-search { background:#fff; width:100%; max-width:520px; border-radius:0 0 16px 16px; max-height:80vh; display:flex; flex-direction:column; }
@media (min-width:560px){ .game-scope .et-search { border-radius:16px; } }
.game-scope .et-search-head { padding:14px 16px; border-bottom:1px solid var(--g-border); }
.game-scope .et-search-crit { font-size:13px; color:var(--g-muted); }
.game-scope .et-search-crit b { color:var(--g-navy); }
.game-scope .et-search-head input { width:100%; margin-top:8px; padding:11px 13px; border:2px solid var(--g-border); border-radius:10px; font-size:16px; }
.game-scope .et-search-head input:focus { outline:none; border-color:var(--g-navy2); }
.game-scope .et-search-close { float:right; background:none; border:none; font-size:22px; color:#94a3b8; cursor:pointer; line-height:1; }
.game-scope .et-results { overflow-y:auto; padding:6px 8px 14px; min-height:0; -webkit-overflow-scrolling:touch; }
.game-scope .et-result { display:flex; align-items:center; gap:10px; padding:10px 10px; border-bottom:1px solid #f1f5f9; cursor:pointer; }
.game-scope .et-result:hover { background:#f7fafc; }
.game-scope .et-result .rn { font-weight:600; font-size:14.5px; }
.game-scope .et-search-msg { padding:14px; text-align:center; color:#94a3b8; font-size:13px; }
.game-scope .et-toast { padding:8px 14px; margin:0 12px; background:#fef3c7; color:#92400e; border-radius:8px; font-size:13px; font-weight:600; }

/* ===== over ===== */
.game-scope #state-over { display:none; }
.game-scope .over-card { background:var(--g-surface); border-radius:16px; box-shadow:0 4px 16px rgba(15,23,42,.07); padding:24px 20px; text-align:center; }
.game-scope .over-card .msg { font-family:'Space Grotesk',sans-serif; font-weight:700; font-size:24px; }
.game-scope .over-card .res { font-size:14px; color:var(--g-muted); margin-top:4px; }
.game-scope .et-reveal { display:flex; align-items:center; gap:13px; justify-content:center; background:#f8fafc; border:1px solid var(--g-border); border-radius:12px; padding:13px 16px; margin:16px 0; text-align:left; }
.game-scope .et-reveal img { width:50px; height:50px; object-fit:contain; background:#fff; border-radius:7px; flex:0 0 50px; }
.game-scope .et-reveal .rv-nom { font-family:'Space Grotesk',sans-serif; font-weight:700; font-size:18px; line-height:1.1; }
.game-scope .et-reveal .rv-meta { font-size:12.5px; color:var(--g-muted); margin-top:3px; }
.game-scope .over-emoji { font-size:18px; line-height:1.25; letter-spacing:2px; margin:8px 0 14px; white-space:pre; font-family:'Apple Color Emoji','Segoe UI Emoji',sans-serif; }
.game-scope .over-actions { display:flex; flex-wrap:wrap; gap:10px; justify-content:center; margin-top:6px; }
.game-scope .et-btn { border:none; border-radius:11px; padding:12px 18px; font-weight:700; font-size:15px; cursor:pointer; display:inline-flex; align-items:center; gap:8px; }
.game-scope .et-btn.primary { background:var(--g-navy2); color:#fff; } .game-scope .et-btn.ghost { background:#eef2f8; color:var(--g-navy); }
.game-scope .share-grid { display:flex; flex-wrap:wrap; gap:10px; justify-content:center; margin-top:14px; }
.game-scope .share-grid button { width:46px; height:46px; border-radius:50%; border:none; color:#fff; font-size:18px; cursor:pointer; }
.game-scope .sh-x{background:#000}.game-scope .sh-wa{background:#25d366}.game-scope .sh-tg{background:#229ed9}.game-scope .sh-fb{background:#1877f2}.game-scope .sh-copy{background:#64748b}
.game-scope .share-hint { font-size:12px; color:var(--g-muted); margin-top:8px; }
.game-scope .vuelve { font-size:13px; color:var(--g-muted); margin-top:10px; display:none; }

/* share card offscreen */
.game-scope .share-card { position:fixed; left:-20000px; top:0; width:1200px; height:675px; background:linear-gradient(135deg,#1e3a5f,#2c5282); color:#fff; font-family:'Space Grotesk',Roboto,sans-serif; padding:54px 64px; box-sizing:border-box; }
.game-scope .share-card .sc-top { font-size:34px; font-weight:700; } .game-scope .share-card .sc-top b { color:#f6ad55; }
.game-scope .share-card .sc-mark { height:58px; vertical-align:middle; margin-right:16px; }
.game-scope .share-card .sc-wm { vertical-align:middle; } .game-scope .share-card .sc-tag { opacity:.85; font-size:22px; font-weight:500; margin-left:6px; vertical-align:middle; }
.game-scope .share-card .sc-mode { float:right; font-size:18px; background:rgba(255,255,255,.15); padding:6px 16px; border-radius:999px; }
.game-scope .share-card .sc-emoji { font-size:46px; line-height:1.18; letter-spacing:6px; margin-top:26px; white-space:pre; font-family:'Apple Color Emoji','Segoe UI Emoji',sans-serif; }
.game-scope .share-card .sc-score { font-size:40px; margin-top:22px; } .game-scope .share-card .sc-score b { color:#86efac; }
.game-scope .share-card .sc-cta { position:absolute; bottom:48px; left:64px; right:64px; display:flex; justify-content:space-between; align-items:flex-end; }
.game-scope .share-card .sc-cta .l1 { font-size:28px; font-weight:700; } .game-scope .share-card .sc-cta .l2 { font-size:21px; opacity:.85; }

@media (max-width:560px){ .game-scope .mode-picker { grid-template-columns:1fr 1fr; } }
