/* ==========================================================================
   mm-esports.css — Capa de estilo "esports" para las páginas del plugin
   (login, registro, perfil y lista pública de torneos).
   Reutiliza el sistema visual de la landing: Montserrat + Orbitron,
   fondo oscuro con glows azul/cian, rejilla tenue y tarjetas glass.
   La URL del logo es relativa a este archivo (assets/mm-logo.png).
   ========================================================================== */

/* ---- Panel oscuro a todo lo ancho -----------------------------------------
   v1.5.3: se cambió de la técnica "left:50%; margin:-50vw" a position:fixed.
   La técnica anterior solo funciona si el contenedor del tema está
   perfectamente centrado con margin:auto; si la página usa una plantilla
   con sidebar o un layout distinto (como pasaba en /login/), el cálculo
   sale descuadrado y el panel se ve encogido y pegado a un lado.
   position:fixed ancla el panel directamente a la ventana del navegador,
   así que funciona sin importar la plantilla o el tema que se use. ------- */
.mmt-auth-wrap {
    position: fixed;
    top: 0; left: 0;
    /* v1.5.12: el margen SÍ desplaza a un elemento position:fixed. Al quedar como
       hijo directo de <body>, el tema/Elementor le metían un margin-top (~40px) que
       hacía arrancar el panel más abajo y dejaba una franja del fondo arriba. Se
       fuerza margin:0. (No usar left/right/width aquí: eso es lo que en v1.5.1
       encogía el panel; margin:0 no afecta el ancho.) */
    margin: 0 !important;
    width: 100vw;
    max-width: none !important;
    height: 100vh;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    /* v1.5.10: se subió de 999999 a casi el máximo entero. Algunos headers
       "sticky" del tema o de Elementor usan z-index muy alto y quedaban por
       encima del panel, tapando la parte de arriba de los formularios. Con
       este valor el panel queda por delante de cualquier barra realista;
       la barra de admin de WP sigue visible gracias al offset de más abajo. */
    z-index: 2147483000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 48px 18px;
    box-sizing: border-box;
    font-family: 'Montserrat', system-ui, sans-serif;
    color: #dbe6ff;
    background:
        radial-gradient(circle at 12% 18%, rgba(23,76,255,.22), transparent 34%),
        radial-gradient(circle at 86% 12%, rgba(0,190,255,.16), transparent 30%),
        radial-gradient(circle at 50% 120%, rgba(23,76,255,.18), transparent 55%),
        #030713;
}
/* La barra de admin de WordPress es position:fixed y tiene más prioridad
   visual que nuestro panel, así que sin esto tapa permanentemente los
   primeros 32px (46px en móvil) del panel sin importar el scroll. */
body.admin-bar .mmt-auth-wrap { top: 32px; height: calc(100vh - 32px); }
@media screen and (max-width: 782px) {
    body.admin-bar .mmt-auth-wrap { top: 46px; height: calc(100vh - 46px); }
}
/* rejilla tenue sobre el panel */
.mmt-auth-wrap::before {
    content: "";
    position: absolute; inset: 0;
    pointer-events: none;
    background-image:
        linear-gradient(rgba(255,255,255,.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,.03) 1px, transparent 1px);
    background-size: 46px 46px;
    -webkit-mask-image: linear-gradient(to bottom, black, transparent 88%);
            mask-image: linear-gradient(to bottom, black, transparent 88%);
}

/* ---- Tarjeta glass -------------------------------------------------------- */
.mmt-auth-wrap .mmt-card {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 440px;
    background: linear-gradient(150deg, rgba(255,255,255,.055), rgba(255,255,255,.02));
    border: 1px solid rgba(120,170,255,.28);
    border-radius: 18px;
    padding: 30px 28px 26px;
    box-shadow: 0 24px 70px rgba(3,10,35,.6), inset 0 1px 0 rgba(255,255,255,.06);
    backdrop-filter: blur(9px);
    -webkit-backdrop-filter: blur(9px);
}
.mmt-auth-wrap.mmt-auth-wide .mmt-card { max-width: 720px; }

/* logo arriba de la tarjeta */
.mmt-auth-wrap .mmt-card::before {
    content: "";
    display: block;
    height: 92px;
    margin: 0 auto 14px;
    background: url(mm-logo.png) center/contain no-repeat;
    filter: drop-shadow(0 0 18px rgba(79,220,255,.35));
}

/* ---- Tipografía ----------------------------------------------------------- */
.mmt-auth-wrap .mmt-h {
    font-family: 'Orbitron', sans-serif;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .5px;
    font-size: 22px;
    line-height: 1.2;
    text-align: center;
    margin: 0 0 6px;
    background: linear-gradient(90deg, #ffffff, #69b0ff, #174cff);
    -webkit-background-clip: text; background-clip: text;
    -webkit-text-fill-color: transparent;
}
.mmt-auth-wrap .mmt-sub {
    font-family: 'Orbitron', sans-serif;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .5px;
    font-size: 13px;
    color: #7fb0ff;
    margin: 20px 0 10px;
    padding-bottom: 6px;
    border-bottom: 1px solid rgba(120,170,255,.18);
}
.mmt-auth-wrap .mmt-muted { text-align: center; color: #93a6cc; font-size: 13px; margin: 0 0 18px; }
.mmt-auth-wrap .mmt-help  { color: #8394b8; font-size: 11px; }

/* ---- Formularios ---------------------------------------------------------- */
.mmt-auth-wrap .mmt-form { display: flex; flex-direction: column; gap: 13px; }
.mmt-auth-wrap .mmt-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 13px; }
@media (max-width: 520px){ .mmt-auth-wrap .mmt-grid { grid-template-columns: 1fr; } }

.mmt-auth-wrap .mmt-label {
    display: flex; flex-direction: column; gap: 6px;
    font-size: 12.5px; font-weight: 600; color: #b9c8ea;
}
.mmt-auth-wrap .mmt-input {
    width: 100%; box-sizing: border-box;
    padding: 11px 13px;
    background: rgba(8,16,38,.72);
    border: 1px solid rgba(120,170,255,.25);
    border-radius: 10px;
    color: #eaf1ff;
    font-size: 14px;
    font-family: inherit;
    transition: border-color .15s, box-shadow .15s, background .15s;
}
.mmt-auth-wrap .mmt-input::placeholder { color: #6c7ea6; }
.mmt-auth-wrap .mmt-input:focus {
    outline: none;
    border-color: #4fdcff;
    background: rgba(8,16,38,.95);
    box-shadow: 0 0 0 3px rgba(79,220,255,.18);
}
.mmt-auth-wrap select.mmt-input option { background: #0b1533; color: #eaf1ff; }
.mmt-auth-wrap .mmt-checkbox { display: flex; align-items: center; gap: 8px; font-size: 13px; color: #b9c8ea; }

/* ---- Botones -------------------------------------------------------------- */
.mmt-auth-wrap .mmt-btn {
    display: inline-block;
    font-family: 'Orbitron', sans-serif;
    font-weight: 700; text-transform: uppercase; letter-spacing: .5px;
    border: none; border-radius: 11px;
    padding: 12px 18px; font-size: 13px;
    cursor: pointer; text-decoration: none; text-align: center;
    transition: filter .15s, transform .05s, box-shadow .15s;
}
.mmt-auth-wrap .mmt-btn-primary {
    color: #061024;
    background: linear-gradient(135deg, #4fdcff, #174cff);
    box-shadow: 0 8px 24px rgba(23,76,255,.4);
}
.mmt-auth-wrap .mmt-btn-primary:hover { filter: brightness(1.08); }
.mmt-auth-wrap .mmt-btn-primary:active { transform: translateY(1px); }
.mmt-auth-wrap .mmt-btn-block { display: block; width: 100%; margin-top: 4px; }
.mmt-auth-wrap .mmt-btn-link {
    background: transparent; color: #7fb0ff; box-shadow: none;
    text-transform: none; font-family: 'Montserrat', sans-serif; font-weight: 600;
}
.mmt-auth-wrap .mmt-btn-link:hover { color: #b9d4ff; }

/* ---- Pie / enlaces / alertas --------------------------------------------- */
.mmt-auth-wrap .mmt-auth-foot { margin-top: 18px; text-align: center; font-size: 13px; color: #93a6cc; }
.mmt-auth-wrap .mmt-auth-foot a { color: #4fdcff; text-decoration: none; font-weight: 600; }
.mmt-auth-wrap .mmt-auth-foot a:hover { text-decoration: underline; }
.mmt-auth-wrap .mmt-sep { margin: 0 8px; color: #46567c; }

.mmt-auth-wrap .mmt-alert {
    border-radius: 10px; padding: 11px 13px; font-size: 13px; margin-bottom: 14px;
}
.mmt-auth-wrap .mmt-alert-error {
    background: rgba(231,76,60,.14);
    border: 1px solid rgba(231,76,60,.5);
    color: #ffb4ab;
}
.mmt-auth-wrap .mmt-alert-success {
    background: rgba(39,174,96,.14);
    border: 1px solid rgba(39,174,96,.5);
    color: #9be8bd;
}

/* ==========================================================================
   Lista pública de torneos [mm_torneos] con el mismo aire esports
   (se combina con los estilos base del shortcode; aquí solo el "tema").
   ========================================================================== */
.mmt-torneos.mmt-esports { color: #dbe6ff; }
.mmt-torneos.mmt-esports .mmt-tcard {
    background: linear-gradient(150deg, rgba(255,255,255,.055), rgba(255,255,255,.02));
    border: 1px solid rgba(120,170,255,.24);
    box-shadow: 0 16px 44px rgba(3,10,35,.4);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}
.mmt-torneos.mmt-esports .mmt-tcard h3 {
    font-family: 'Orbitron', sans-serif; text-transform: uppercase;
    font-size: 16px; letter-spacing: .3px; color: #eaf1ff;
}
.mmt-torneos.mmt-esports .mmt-tmeta { color: #9db0d6; }
.mmt-torneos.mmt-esports .mmt-enroll-btn {
    font-family: 'Orbitron', sans-serif; text-transform: uppercase; letter-spacing: .4px;
    background: linear-gradient(135deg, #4fdcff, #174cff); color: #061024;
    box-shadow: 0 8px 22px rgba(23,76,255,.38);
}

/* Panel oscuro contenedor de la lista pública de torneos */
.mmt-esports-panel {
    position: relative;
    left: 50%; right: 50%;
    margin-left: -50vw; margin-right: -50vw;
    width: 100vw;
    padding: 54px 18px;
    box-sizing: border-box;
    font-family: 'Montserrat', system-ui, sans-serif;
    background:
        radial-gradient(circle at 12% 12%, rgba(23,76,255,.20), transparent 34%),
        radial-gradient(circle at 88% 10%, rgba(0,190,255,.14), transparent 30%),
        #030713;
}
.mmt-esports-panel::before {
    content: ""; position: absolute; inset: 0; pointer-events: none;
    background-image:
        linear-gradient(rgba(255,255,255,.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,.03) 1px, transparent 1px);
    background-size: 46px 46px;
    -webkit-mask-image: linear-gradient(to bottom, black, transparent 90%);
            mask-image: linear-gradient(to bottom, black, transparent 90%);
}
.mmt-esports-panel .mmt-torneos { position: relative; z-index: 1; }
.mmt-esports-panel .mmt-empty { color: #93a6cc; }

/* ==========================================================================
   PORTAL INTERNO (vistas de juego, listados, detalle) — tema esports
   Los estilos en línea del motor se neutralizan con selectores de atributo
   [style*="..."] + !important. Los colores del tablero (chessboard.js) van
   por clase, así que NO se ven afectados.
   ========================================================================== */
.mmt-esports-portal {
    position: relative;
    left: 50%; right: 50%; margin-left: -50vw; margin-right: -50vw; width: 100vw;
    min-height: 100vh;
    padding: 0 0 60px;
    box-sizing: border-box;
    font-family: 'Montserrat', system-ui, sans-serif;
    color: #dbe6ff;
    background:
        radial-gradient(circle at 10% 8%, rgba(23,76,255,.18), transparent 34%),
        radial-gradient(circle at 90% 6%, rgba(0,190,255,.12), transparent 30%),
        #030713;
}
.mmt-esports-portal::before {
    content: ""; position: fixed; inset: 0; pointer-events: none; z-index: 0;
    background-image:
        linear-gradient(rgba(255,255,255,.025) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,.025) 1px, transparent 1px);
    background-size: 48px 48px;
    -webkit-mask-image: linear-gradient(to bottom, black, transparent 80%);
            mask-image: linear-gradient(to bottom, black, transparent 80%);
}
.mmt-esports-portal > * { position: relative; z-index: 1; }

/* --- Cabecera / navegación / rol --- */
.mmt-esports-portal .mmt-portal-header {
    display: flex; align-items: center; justify-content: space-between;
    flex-wrap: wrap; gap: 10px;
    padding: 16px 22px;
    background: rgba(6,12,30,.72);
    border-bottom: 1px solid rgba(120,170,255,.18);
    backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
}
.mmt-esports-portal .mmt-brand-link {
    font-family: 'Orbitron', sans-serif; font-weight: 800; text-transform: uppercase;
    letter-spacing: .5px; font-size: 18px; text-decoration: none;
    background: linear-gradient(90deg, #fff, #69b0ff, #174cff);
    -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
}
.mmt-esports-portal .mmt-portal-nav { display: flex; gap: 16px; align-items: center; flex-wrap: wrap; }
.mmt-esports-portal .mmt-portal-nav a { color: #b9c8ea; text-decoration: none; font-weight: 600; font-size: 14px; }
.mmt-esports-portal .mmt-portal-nav a:hover { color: #4fdcff; }
.mmt-esports-portal .mmt-logout-link { color: #ff9b8f !important; }
.mmt-esports-portal .mmt-portal-rolebar { padding: 10px 22px 0; }
.mmt-esports-portal .mmt-rolebar-badge {
    display: inline-block; font-family: 'Orbitron', sans-serif; font-size: 11px; font-weight: 700;
    text-transform: uppercase; letter-spacing: .5px; color: #061024;
    background: linear-gradient(135deg, #4fdcff, #174cff); border-radius: 999px; padding: 4px 12px;
}

/* --- Contenido: dar aire y centrar como en el resto --- */
.mmt-esports-portal .mmt-portal-body,
.mmt-esports-portal .mmt-portal-content { padding: 18px 22px; }

/* --- Neutralizar fondos claros en línea -> glass --- */
.mmt-esports-portal [style*="background:#fff"],
.mmt-esports-portal [style*="background:#f8f9fa"],
.mmt-esports-portal [style*="background:#f5f5f5"],
.mmt-esports-portal [style*="background:#eee"],
.mmt-esports-portal .mmt-card {
    background: linear-gradient(150deg, rgba(255,255,255,.06), rgba(255,255,255,.02)) !important;
    border-color: rgba(120,170,255,.22) !important;
    color: #dbe6ff !important;
    box-shadow: 0 12px 34px rgba(3,10,35,.35) !important;
}
/* Restaurar semánticos de alerta (el selector #fff atrapa #fff3cd / #fff5f5) */
.mmt-esports-portal [style*="background:#fff3cd"] { background: rgba(240,173,78,.16) !important; border-color: rgba(240,173,78,.5) !important; color: #ffe1a6 !important; }
.mmt-esports-portal [style*="background:#fff5f5"],
.mmt-esports-portal [style*="background:#fdf0ef"] { background: rgba(231,76,60,.16) !important; border-color: rgba(231,76,60,.5) !important; color: #ffb4ab !important; }
.mmt-esports-portal [style*="background:#d1ecf1"] { background: rgba(52,152,219,.16) !important; border-color: rgba(52,152,219,.5) !important; color: #a9dcf5 !important; }

/* --- Texto oscuro en línea -> claro --- */
.mmt-esports-portal [style*="color:#2c3e50"],
.mmt-esports-portal [style*="color:#333"],
.mmt-esports-portal [style*="color:#222"],
.mmt-esports-portal [style*="color:#555"],
.mmt-esports-portal [style*="color:#444"] { color: #e7eeff !important; }
.mmt-esports-portal [style*="color:#7f8c8d"],
.mmt-esports-portal [style*="color:#999"],
.mmt-esports-portal [style*="color:#888"],
.mmt-esports-portal [style*="color:#666"],
.mmt-esports-portal [style*="color:#bbb"] { color: #9db0d6 !important; }

/* --- Botones .wcp-btn: conservan su color semántico, ganan estilo --- */
.mmt-esports-portal .wcp-btn {
    font-family: 'Orbitron', sans-serif; font-weight: 700; letter-spacing: .3px;
    border: none; border-radius: 10px; color: #fff; cursor: pointer;
    box-shadow: 0 6px 18px rgba(3,10,35,.35);
}
.mmt-esports-portal h1, .mmt-esports-portal h2, .mmt-esports-portal h3 {
    font-family: 'Orbitron', sans-serif;
}

/* --- Tablero: fondo del contenedor para que respire en oscuro --- */
.mmt-esports-portal #player-board, .mmt-esports-portal #arb-board {
    background: rgba(6,12,30,.4);
    border-radius: 12px;
    padding: 6px;
    box-shadow: 0 16px 44px rgba(3,10,35,.5);
}
/* Chips de tablas / banners ya cubiertos por los overrides de fondo/alerta. */

/* Enlaces genéricos dentro del portal */
.mmt-esports-portal a { color: #7fb0ff; }

/* ==========================================================================
   FIX v1.3.2 — full-bleed real + panel de contenido oscuro
   El CSS base pone .mmt-portal max-width:1200px y .mmt-portal-main #f8fafc;
   eso recortaba el fondo (se veía a la izquierda) y dejaba el texto claro
   sobre panel blanco (ilegible). Aquí se corrige.
   ========================================================================== */
.mmt-esports-portal {
    max-width: none !important;
    margin: 0 -50vw !important;      /* full-bleed de verdad */
    padding: 0 0 60px !important;
}
.mmt-esports-portal .mmt-portal-header { border-radius: 0 !important; }
.mmt-esports-portal .mmt-portal-rolebar {
    max-width: 1200px; margin: 0 auto; padding-left: 22px; padding-right: 22px;
}
.mmt-esports-portal .mmt-portal-main {
    background: transparent !important;   /* deja ver el fondo oscuro */
    max-width: 1200px;
    margin: 0 auto;
    padding: 18px 22px;
    box-shadow: none !important;
}

/* ============================================================
   v1.5.0 — completar tema en registro y creador de torneos
   ============================================================ */
/* Rejilla de 2 columnas del registro (usa .mmt-grid-2) */
.mmt-auth-wrap .mmt-grid-2 { display:grid; grid-template-columns:1fr 1fr; gap:13px; }
@media (max-width:520px){ .mmt-auth-wrap .mmt-grid-2 { grid-template-columns:1fr; } }
/* Selects e inputs de fecha/tel en auth: modo oscuro nativo */
.mmt-auth-wrap .mmt-input,
.mmt-auth-wrap input, .mmt-auth-wrap select, .mmt-auth-wrap textarea { color-scheme: dark; }
.mmt-auth-wrap select.mmt-input { -webkit-appearance:none; appearance:none;
    background-image:linear-gradient(45deg,transparent 50%,#7fb0ff 50%),linear-gradient(135deg,#7fb0ff 50%,transparent 50%);
    background-position:calc(100% - 18px) 50%,calc(100% - 12px) 50%;background-size:6px 6px,6px 6px;background-repeat:no-repeat; }

/* --- Inputs del portal (creador de torneos, emparejamiento manual, etc.) --- */
.mmt-esports-portal input[type="text"],
.mmt-esports-portal input[type="number"],
.mmt-esports-portal input[type="date"],
.mmt-esports-portal input[type="email"],
.mmt-esports-portal input[type="tel"],
.mmt-esports-portal input[type="password"],
.mmt-esports-portal select,
.mmt-esports-portal textarea {
    background: rgba(8,16,38,.7) !important;
    border: 1px solid rgba(120,170,255,.28) !important;
    color: #eaf1ff !important;
    color-scheme: dark;
    border-radius: 8px !important;
}
.mmt-esports-portal input::placeholder,
.mmt-esports-portal textarea::placeholder { color:#6c7ea6 !important; }
.mmt-esports-portal input:focus,
.mmt-esports-portal select:focus,
.mmt-esports-portal textarea:focus {
    outline:none !important;
    border-color:#4fdcff !important;
    box-shadow:0 0 0 3px rgba(79,220,255,.16) !important;
}
.mmt-esports-portal select option { background:#0b1533; color:#eaf1ff; }
.mmt-esports-portal label { color:#cfe0ff; }
.mmt-esports-portal .mmt-help { color:#8394b8; }

/* ============================================================
   v1.5.1 — fondo oscuro robusto (evita el blanco del tema) +
   menú en páginas de auth + mejor contraste de etiquetas
   ============================================================ */
/* Fondo oscuro a nivel de página y neutraliza contenedores del tema */
body.mmt-esports-body { background:#030713 !important; }
body.mmt-esports-body .entry-content,
body.mmt-esports-body .site-content,
body.mmt-esports-body .content-area,
body.mmt-esports-body #content,
body.mmt-esports-body #primary,
body.mmt-esports-body #main,
body.mmt-esports-body main,
body.mmt-esports-body .wp-block-post-content,
body.mmt-esports-body .page-content,
body.mmt-esports-body article,
body.mmt-esports-body .elementor-widget-container { background:transparent !important; }

/* Auth: layout en columna con nav arriba y tarjeta centrada.
   IMPORTANTE: no tocar left/right/margin/width aquí — esas propiedades
   son las que logran el "pantalla completa" (100vw) definido arriba en
   .mmt-auth-wrap. En v1.5.1 este bloque las sobrescribía con !important
   y volvía a encoger el panel al ancho de la columna del tema. */
.mmt-auth-wrap {
    flex-direction:column; padding-top:0;
    /* v1.5.13: cuando la tarjeta es más alta que la pantalla, centrar el grupo
       (justify-content:center, heredado) recorta la parte de arriba y el scroll
       no llega a ella. Alineamos arriba; el centrado "si cabe" lo hace la tarjeta
       con margin:auto más abajo. */
    justify-content: flex-start;
}
/* v1.5.6: se cambió el centrado de .mmt-auth-center de align-items/justify-content
   a margin:auto en .mmt-card. Con align-items:center, cuando el formulario (registro
   o perfil) es más alto que la pantalla, la parte de arriba de la tarjeta (donde
   está el logo) queda recortada o inaccesible incluso con scroll — es un problema
   conocido de flexbox al centrar contenido que desborda. margin:auto centra igual
   cuando el contenido cabe, y cuando no cabe se ve completo desde arriba con scroll
   normal, sin recortar nada. */
.mmt-auth-center { flex:1 0 auto; display:flex; width:100%; padding: 10px 0; }
.mmt-auth-center .mmt-card { margin: auto; }
.mmt-auth-nav {
    position:relative; z-index:2; width:100%; max-width:1180px; margin:0 auto;
    display:flex; align-items:center; justify-content:space-between; gap:14px; padding:18px 6px;
}
.mmt-auth-brand img { height:48px; width:auto; display:block; filter:drop-shadow(0 0 12px rgba(79,220,255,.35)); }
.mmt-auth-navlinks { display:flex; gap:18px; align-items:center; flex-wrap:wrap; }
.mmt-auth-navlinks a { color:#b9c8ea; text-decoration:none; font-weight:600; font-size:14px; }
.mmt-auth-navlinks a:hover { color:#4fdcff; }

/* Etiquetas/títulos del portal con mejor contraste (creador de torneos, etc.) */
.mmt-esports-portal label { color:#dbe6ff !important; }
.mmt-esports-portal h1, .mmt-esports-portal h2, .mmt-esports-portal h3 { color:#eaf1ff; }

/* ============================================================
   v1.6.0 — Mis partidas + visor de repeticiones
   ============================================================ */
.mmt-history-title, .mmt-replay-title { color:#eaf2ff; margin:0 0 16px; }
.mmt-history-list { display:flex; flex-direction:column; gap:10px; }
.mmt-history-row {
    display:flex; align-items:center; gap:14px; flex-wrap:wrap;
    background:rgba(20,28,48,.6); border:1px solid rgba(79,220,255,.15);
    border-radius:12px; padding:12px 16px;
}
.mmt-history-main { display:flex; align-items:center; gap:10px; flex-wrap:wrap; flex:1 1 260px; }
.mmt-history-opp { color:#d7e3ff; }
.mmt-history-col { color:#8ea3c8; font-size:13px; }
.mmt-history-meta { display:flex; flex-direction:column; gap:2px; color:#8ea3c8; font-size:12px; text-align:right; }
.mmt-history-actions { margin-left:auto; }
.mmt-badge { font-size:12px; font-weight:700; padding:3px 10px; border-radius:999px; letter-spacing:.3px; }
.mmt-badge-win     { background:rgba(46,204,113,.18); color:#4ee89a; }
.mmt-badge-loss    { background:rgba(231,76,60,.16);  color:#ff7a6b; }
.mmt-badge-draw    { background:rgba(241,196,15,.16); color:#ffd65a; }
.mmt-badge-done    { background:rgba(120,140,180,.18);color:#b9c8ea; }
.mmt-badge-pending { background:rgba(79,220,255,.16); color:#4fdcff; }
.mmt-tag-dragon { font-size:11px; font-weight:800; letter-spacing:.5px; color:#c9a6ef;
    border:1px solid rgba(201,166,239,.5); border-radius:6px; padding:1px 7px; }
.mmt-btn-sm { font-size:13px; padding:7px 14px; }
.mmt-btn-ghost { background:transparent; border:1px solid rgba(79,220,255,.4); color:#4fdcff; }

.mmt-replay { max-width:560px; margin:0 auto; }
.mmt-replay-head { display:flex; align-items:center; gap:14px; margin-bottom:14px; flex-wrap:wrap; }
.mmt-replay-title { font-size:20px; }
.mmt-replay-title span { color:#8ea3c8; font-weight:400; font-size:15px; }
.mmt-replay-board {
    width:100%; max-width:480px; aspect-ratio:1/1; margin:0 auto;
    display:grid; grid-template-columns:repeat(8,1fr); grid-template-rows:repeat(8,1fr);
    border:2px solid rgba(79,220,255,.35); border-radius:8px; overflow:hidden;
    box-shadow:0 0 24px rgba(79,220,255,.15);
}
.mmt-sq { position:relative; display:flex; align-items:center; justify-content:center; }
.mmt-sq.light { background:#e9edf5; }
.mmt-sq.dark  { background:#5b7290; }
.mmt-sq img { width:88%; height:88%; object-fit:contain; user-select:none; pointer-events:none; }
.mmt-replay-controls { display:flex; align-items:center; justify-content:center; gap:8px; margin-top:14px; }
.mmt-replay-counter { min-width:60px; text-align:center; color:#b9c8ea; font-variant-numeric:tabular-nums; }

/* ============================================================
   v1.7.0 — Sala de espera
   ============================================================ */
.mmt-lobby { max-width:720px; margin:0 auto; }
.mmt-lobby-head { display:flex; align-items:baseline; justify-content:space-between; gap:12px; flex-wrap:wrap;
    background:rgba(20,28,48,.6); border:1px solid rgba(79,220,255,.15); border-radius:12px; padding:14px 18px; margin-bottom:14px; }
.mmt-lobby-name { font-size:18px; font-weight:700; color:#eaf2ff; }
.mmt-lobby-round { color:#b9c8ea; }
.mmt-lobby-round strong { color:#4fdcff; }
.mmt-lobby-pairing { background:rgba(46,204,113,.10); border:1px solid rgba(46,204,113,.35); border-radius:12px;
    padding:14px 18px; margin-bottom:16px; color:#d7e3ff; display:flex; flex-direction:column; gap:8px; align-items:flex-start; }
.mmt-lobby-gamestate { color:#8ea3c8; font-size:14px; }
.mmt-lobby-players-title { color:#b9c8ea; margin-bottom:8px; font-weight:600; }
.mmt-lobby-players-head { display:flex; align-items:center; justify-content:space-between; gap:12px; flex-wrap:wrap; margin-bottom:10px; }
.mmt-lobby-count { display:inline-block; background:rgba(79,220,255,.16); color:#4fdcff; border-radius:999px; padding:1px 9px; font-size:13px; margin-left:4px; }
.mmt-lobby-search { background:rgba(10,16,30,.6); border:1px solid rgba(79,220,255,.25); border-radius:9px; color:#eaf2ff; padding:7px 12px; font-size:13px; min-width:180px; outline:none; }
.mmt-lobby-search:focus { border-color:rgba(79,220,255,.6); }
.mmt-lobby-grid { display:grid; grid-template-columns:repeat(auto-fill,minmax(180px,1fr)); gap:8px; max-height:340px; overflow-y:auto; padding-right:4px; }
.mmt-lobby-player { display:flex; align-items:center; gap:10px; background:rgba(20,28,48,.6); border:1px solid rgba(79,220,255,.15); border-radius:10px; padding:7px 11px; color:#d7e3ff; font-size:14px; }
.mmt-lobby-player.me { border-color:rgba(79,220,255,.6); background:rgba(79,220,255,.08); }
.mmt-lobby-avatar { flex:0 0 auto; width:30px; height:30px; border-radius:50%; display:flex; align-items:center; justify-content:center;
    font-size:12px; font-weight:800; color:#0a1020; background:linear-gradient(135deg,#4fdcff,#7aa0ff); letter-spacing:.3px; }
.mmt-lobby-player.me .mmt-lobby-avatar { background:linear-gradient(135deg,#ffd65a,#ff9f43); }
.mmt-lobby-pname { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.mmt-lobby-noresult { color:#8ea3c8; font-size:13px; padding:10px 2px; }

/* v1.7.2 — resaltado de la última jugada en el tablero */
#player-board .mmt-hl { box-shadow: inset 0 0 0 4px rgba(255,214,64,.75); }

/* v1.9.0 — sala: lista de partidas + visor de espectador */
.mmt-lobby-games { margin-top:16px; }
.mmt-lobby-glist { display:flex; flex-direction:column; gap:8px; }
.mmt-lobby-game { display:flex; align-items:center; justify-content:space-between; gap:12px;
    background:rgba(20,28,48,.6); border:1px solid rgba(79,220,255,.15); border-radius:9px; padding:9px 13px; color:#d7e3ff; font-size:14px; }
.mmt-lobby-game small { color:#8ea3c8; }
.mmt-lobby-game em { color:#4fdcff; font-style:normal; }
.mmt-watch-clocks { display:flex; align-items:center; justify-content:center; gap:14px; margin:6px 0 12px; }
.mmt-watch-clock { font-variant-numeric:tabular-nums; font-weight:700; color:#eaf2ff; background:rgba(20,28,48,.7);
    border:1px solid rgba(79,220,255,.25); border-radius:8px; padding:6px 12px; }
.mmt-watch-vs { color:#8ea3c8; }

/* v1.9.2 — clasificación y resultados (vista del jugador) */
.mmt-standings { max-width:720px; margin:0 auto; }
.mmt-standings-title { color:#b9c8ea; font-weight:700; font-size:15px; margin:10px 0 10px; }
.mmt-table-wrap { overflow-x:auto; border:1px solid rgba(79,220,255,.15); border-radius:12px; }
.mmt-table { width:100%; border-collapse:collapse; font-size:14px; color:#d7e3ff; }
.mmt-table thead th { background:rgba(20,28,48,.8); color:#9fb3d9; text-align:center; padding:10px 8px; font-weight:600; position:sticky; top:0; }
.mmt-table thead th:nth-child(2), .mmt-table tbody td:nth-child(2) { text-align:left; }
.mmt-table tbody td { text-align:center; padding:9px 8px; border-top:1px solid rgba(79,220,255,.08); }
.mmt-table .mmt-pts { font-weight:800; color:#4fdcff; }
.mmt-table .mmt-row-me { background:rgba(79,220,255,.10); }
.mmt-table .mmt-row-me td { color:#eaf2ff; }
.mmt-table em { color:#4fdcff; font-style:normal; }
.mmt-round-block { margin-bottom:14px; }
.mmt-round-head { color:#b9c8ea; font-weight:600; margin:0 0 6px; }
.mmt-round-now { background:rgba(46,204,113,.16); color:#4ee89a; border-radius:999px; padding:1px 8px; font-size:12px; margin-left:6px; }
.mmt-round-games { display:flex; flex-direction:column; gap:6px; }
.mmt-result-row { display:flex; align-items:center; gap:12px; background:rgba(20,28,48,.6); border:1px solid rgba(79,220,255,.12);
    border-radius:9px; padding:8px 12px; color:#d7e3ff; font-size:14px; }
.mmt-result-row.mine { border-color:rgba(79,220,255,.5); }
.mmt-result-players { flex:1; }
.mmt-result-players small { color:#8ea3c8; }
.mmt-result-score { font-weight:800; color:#eaf2ff; min-width:44px; text-align:center; }
.mmt-result-watch { text-decoration:none; }

/* v1.9.4 — sala de espera con pestañas (estilo torneo) */
.mmt-tabs { display:flex; gap:6px; border-bottom:1px solid rgba(79,220,255,.15); margin:16px 0 14px; flex-wrap:wrap; }
.mmt-tab { background:transparent; border:none; border-bottom:3px solid transparent; color:#9fb3d9; font-weight:600;
    font-size:15px; padding:9px 14px; cursor:pointer; border-radius:6px 6px 0 0; }
.mmt-tab:hover { color:#d7e3ff; background:rgba(79,220,255,.06); }
.mmt-tab.active { color:#4fdcff; border-bottom-color:#4fdcff; }
.mmt-tabpanel { animation:mmtFade .15s ease; }
@keyframes mmtFade { from { opacity:0; } to { opacity:1; } }
.mmt-lobby-game.mine { border-color:rgba(79,220,255,.55); background:rgba(79,220,255,.08); }
.mmt-lobby-gscore { font-weight:800; color:#eaf2ff; min-width:40px; text-align:center; }
.mmt-lobby-game em { color:#4fdcff; font-style:normal; }

/* v1.9.5 — sub-pestañas por ronda */
.mmt-subtabs { display:flex; gap:6px; flex-wrap:wrap; margin:4px 0 12px; }
.mmt-subtab { background:rgba(20,28,48,.6); border:1px solid rgba(79,220,255,.18); color:#9fb3d9;
    font-weight:600; font-size:13px; padding:6px 12px; border-radius:999px; cursor:pointer; }
.mmt-subtab:hover { color:#d7e3ff; }
.mmt-subtab.active { background:rgba(79,220,255,.16); color:#4fdcff; border-color:rgba(79,220,255,.5); }
.mmt-round-panel { animation:mmtFade .15s ease; }

/* ============================================================
   v1.13.6 — Detalle de torneo (panel del árbitro/admin)
   El PHP ya no usa !important en los colores en línea de esta
   vista, así que las reglas del tema de arriba sí los alcanzan.
   Todo queda acotado a .mmt-td (contenedor vivo del detalle).
   ============================================================ */

/* --- Botones: base que faltaba (.wcp-btn venía del plugin de clases) --- */
.mmt-td .wcp-btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 6px;
    padding: 9px 16px; font-size: 12px; line-height: 1.2;
    border: none; border-radius: 10px; color: #fff;
    cursor: pointer; text-decoration: none; white-space: nowrap;
    transition: filter .15s, transform .05s, opacity .15s;
}
.mmt-td .wcp-btn:hover { filter: brightness(1.12); }
.mmt-td .wcp-btn:active { transform: translateY(1px); }
.mmt-td .wcp-btn:disabled { opacity: .55; cursor: wait; filter: none; transform: none; }

/* --- Encabezado del torneo --- */
.mmt-td .mmt-td-head { gap: 14px; flex-wrap: wrap; }
.mmt-td .mmt-td-head h2 { font-size: 20px; line-height: 1.25; }
.mmt-td .mmt-td-actions { flex-wrap: wrap; justify-content: flex-end; }
.mmt-esports-portal .mmt-td .mmt-td-subcard { box-shadow: none !important; }

/* --- Rejilla principal: la columna de jugadores no debe aplastar a las rondas --- */
.mmt-td .mmt-td-grid > * { min-width: 0; }

/* --- Pestañas de ronda: usan .mmt-subtab; aquí solo icono alineado --- */
.mmt-td .mmt-subtab { display: inline-flex; align-items: center; gap: 5px; font-family: 'Montserrat', system-ui, sans-serif; }

/* --- Filas de pareo --- */
.mmt-td .mmt-td-game {
    display: flex; justify-content: space-between; align-items: center; gap: 10px;
    padding: 10px 12px; margin-bottom: 8px; border-radius: 9px;
    border: 1px solid #e5e8ee;
}
.mmt-td .mmt-td-game.is-call { border-left: 4px solid #e74c3c; background: #fff5f5; }
.mmt-td .mmt-td-game-info { flex: 1; min-width: 0; }
.mmt-td .mmt-td-players { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.mmt-td .mmt-td-game-meta { font-size: 11px; color: #7f8c8d; margin-top: 3px; }
.mmt-td .mmt-td-game-actions { display: flex; gap: 6px; flex-shrink: 0; }
.mmt-td .mmt-td-game-actions .wcp-btn { padding: 6px 12px; }
.mmt-esports-portal .mmt-td .mmt-td-game {
    background: rgba(20,28,48,.55); border-color: rgba(120,170,255,.16);
}
.mmt-esports-portal .mmt-td .mmt-td-game.is-call {
    background: rgba(231,76,60,.14); border-color: rgba(231,76,60,.45); border-left-color: #ff6b5b;
}
.mmt-esports-portal .mmt-td .mmt-td-game-meta { color: #9db0d6; }
.mmt-esports-portal .mmt-td .mmt-td-game-meta strong { color: #eaf2ff; }

/* --- Aviso de fallo FIDE dentro de la ronda --- */
.mmt-esports-portal .mmt-td .mmt-td-alert { color: #ffb4ab !important; }

/* --- Tabla de posiciones --- */
.mmt-td .mmt-td-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.mmt-td .mmt-td-table th,
.mmt-td .mmt-td-table td { padding: 6px 6px; text-align: left; white-space: nowrap; }
.mmt-td .mmt-td-table .c { text-align: center; }
.mmt-td .mmt-td-table thead tr { border-bottom: 2px solid #e5e8ee; }
.mmt-td .mmt-td-table tbody tr { border-bottom: 1px solid #f2f3f6; }
.mmt-td .mmt-td-table tr.is-top { font-weight: 600; }
.mmt-td .mmt-td-table .pts { font-weight: 800; color: #2c3e50; }
.mmt-td .mmt-td-table .w   { color: #27ae60; }
.mmt-td .mmt-td-table .d   { color: #7f8c8d; }
.mmt-td .mmt-td-table .l   { color: #e74c3c; }
.mmt-td .mmt-td-table .h2h { color: #d35400; }
.mmt-td .mmt-td-table .tb  { color: #8e44ad; }
.mmt-td .mmt-td-plink { color: inherit; text-decoration: underline; text-underline-offset: 2px; }
.mmt-esports-portal .mmt-td .mmt-td-table { color: #d7e3ff; }
.mmt-esports-portal .mmt-td .mmt-td-table thead th { color: #9fb3d9; font-weight: 600; }
.mmt-esports-portal .mmt-td .mmt-td-table thead tr { border-bottom-color: rgba(120,170,255,.22); }
.mmt-esports-portal .mmt-td .mmt-td-table tbody tr { border-bottom-color: rgba(120,170,255,.08); }
.mmt-esports-portal .mmt-td .mmt-td-table tbody tr:hover { background: rgba(79,220,255,.05); }
.mmt-esports-portal .mmt-td .mmt-td-table .pts { color: #4fdcff; }
.mmt-esports-portal .mmt-td .mmt-td-table .w   { color: #4ee89a; }
.mmt-esports-portal .mmt-td .mmt-td-table .d   { color: #9db0d6; }
.mmt-esports-portal .mmt-td .mmt-td-table .l   { color: #ff7a6b; }
.mmt-esports-portal .mmt-td .mmt-td-table .h2h { color: #ffb070; }
.mmt-esports-portal .mmt-td .mmt-td-table .tb  { color: #c9a6ef; }
.mmt-esports-portal .mmt-td .mmt-td-plink { color: #eaf2ff !important; }
.mmt-esports-portal .mmt-td .mmt-td-plink:hover { color: #4fdcff !important; }

/* --- Lista de jugadores --- */
.mmt-td .mmt-td-player {
    display: flex; align-items: center; gap: 7px; flex-wrap: wrap;
    padding: 7px 0; font-size: 13px; border-bottom: 1px solid #f2f3f6;
}
.mmt-td .mmt-td-player:last-child { border-bottom: none; }
.mmt-td .mmt-td-player.is-excluded { opacity: .55; }
.mmt-td .mmt-td-player.is-excluded .mmt-td-pname { text-decoration: line-through; }
.mmt-td .mmt-td-pname { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.mmt-td .mmt-td-status { margin-left: auto; font-size: 11px; color: #aaa; }
.mmt-td .mmt-td-status.on { color: #27ae60; }
.mmt-td .mmt-td-player .wcp-btn { padding: 4px 10px; font-size: 11px; }
.mmt-esports-portal .mmt-td .mmt-td-player { border-bottom-color: rgba(120,170,255,.10); }
.mmt-esports-portal .mmt-td .mmt-td-pname { color: #e7eeff; }
.mmt-esports-portal .mmt-td .mmt-td-status { color: #6c7ea6; }
.mmt-esports-portal .mmt-td .mmt-td-status.on { color: #4ee89a; }
/* punto de conexión "desconectado" (#ccc) más discreto en oscuro */
.mmt-esports-portal .mmt-td span[title="Desconectado"][style*="border-radius:50%"] { background: #46567c !important; }

/* --- Solicitudes de inscripción (panel amarillo): correo legible --- */
.mmt-esports-portal .mmt-td .mmt-enroll-approve small { color: #d9c08a !important; }
.mmt-esports-portal .mmt-td .mmt-pending-row { border-top-color: rgba(240,173,78,.25) !important; }

/* --- Modal "No se pudo generar la ronda": fondo sólido --- */
.mmt-td .mmt-td-modal { backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px); }
.mmt-td .mmt-td-modal > div { box-shadow: 0 24px 70px rgba(0,0,0,.45); }
.mmt-td .mmt-td-modal-foot { border-top: 1px solid #eee; }
.mmt-esports-portal .mmt-td .mmt-td-modal > div {
    background: #0b1533 !important;
    border: 1px solid rgba(120,170,255,.3) !important;
    color: #dbe6ff !important;
}
.mmt-esports-portal .mmt-td .mmt-td-modal h3 { color: #ff8a7a !important; }
.mmt-esports-portal .mmt-td .mmt-td-modal-foot { border-top-color: rgba(120,170,255,.18); }
.mmt-esports-portal .mmt-td .mmt-td-modal .wcp-btn[style*="background:none"] { box-shadow: none; }

/* --- Responsivo --- */
@media (max-width: 860px) {
    .mmt-td .mmt-td-grid { grid-template-columns: 1fr !important; }
    .mmt-td .mmt-td-actions { justify-content: flex-start; width: 100%; }
}
@media (max-width: 600px) {
    .mmt-td .mmt-td-headcard { padding: 16px !important; }
    .mmt-td .mmt-td-actions .wcp-btn { flex: 1 1 calc(50% - 8px); }
    .mmt-td .mmt-td-game { flex-direction: column; align-items: stretch; }
    .mmt-td .mmt-td-game-actions { justify-content: flex-end; }
    .mmt-td .mmt-td-manual-grid { grid-template-columns: 1fr 1fr !important; }
    .mmt-td .mmt-td-manual-grid > .wcp-btn { grid-column: 1 / -1; }
}

/* ============================================================
   v1.13.7 — tarjetas del detalle por clase (no por [style*=])
   Al cambiar de pestaña el JS tocaba element.style y el navegador
   reescribía el atributo como "background: rgb(255, 255, 255)",
   con lo que [style*="background:#fff"] dejaba de coincidir y la
   tarjeta volvía a blanco. Ahora la visibilidad va por clase y el
   tema oscuro se aplica por .mmt-td-card.
   ============================================================ */
.mmt-td .is-hidden { display: none !important; }
.mmt-esports-portal .mmt-td .mmt-td-card {
    background: linear-gradient(150deg, rgba(255,255,255,.06), rgba(255,255,255,.02)) !important;
    border-color: rgba(120,170,255,.22) !important;
    color: #dbe6ff !important;
    box-shadow: 0 12px 34px rgba(3,10,35,.35) !important;
}
.mmt-esports-portal .mmt-td #wct-manual-pair-panel { border-color: rgba(79,220,255,.55) !important; }

/* ============================================================
   v1.13.8 — Tabla unificada de jugadores (Elo + Parear)
   ============================================================ */
.mmt-td .mmt-td-roster h3 { flex-wrap: wrap; }
.mmt-td .mmt-td-roster-count {
    margin-left: auto; font-family: 'Montserrat', system-ui, sans-serif;
    font-size: 11px; font-weight: 600; padding: 2px 9px; border-radius: 999px;
    background: rgba(39,174,96,.12); color: #27ae60;
}
.mmt-td .mmt-td-roster-help { font-size: 11.5px; line-height: 1.45; color: #7f8c8d; margin: -4px 0 10px; }
.mmt-td .mmt-td-roster-wrap { max-height: 520px; overflow-y: auto; margin: 0 -4px; padding: 0 4px; }
.mmt-td .mmt-td-roster-table { width: 100%; border-collapse: collapse; font-size: 13px; table-layout: fixed; }
.mmt-td .mmt-td-roster-table th {
    font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: .4px;
    text-align: left; padding: 4px 4px 6px; border-bottom: 2px solid #e5e8ee;
    position: sticky; top: 0; z-index: 1; background: inherit;
}
.mmt-td .mmt-td-roster-table th:nth-child(2) { width: 74px; }
.mmt-td .mmt-td-roster-table th:nth-child(3) { width: 56px; }
.mmt-td .mmt-td-roster-table .c { text-align: center; }
.mmt-td .mmt-td-roster-table td { padding: 5px 4px; border-bottom: 1px solid #f2f3f6; vertical-align: middle; }
.mmt-td .mmt-td-roster-table tr:last-child td { border-bottom: none; }
.mmt-td .mmt-td-pcell { display: flex; align-items: center; gap: 7px; min-width: 0; }
.mmt-td .mmt-td-pcell .mmt-td-pname { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mmt-td .mmt-td-dot { flex: 0 0 7px; width: 7px; height: 7px; border-radius: 50%; background: #ccc; }
.mmt-td .mmt-td-dot.on { background: #2ecc71; box-shadow: 0 0 6px rgba(46,204,113,.6); }
.mmt-td .mmt-td-prow.is-excluded .mmt-td-pname { text-decoration: line-through; opacity: .5; }
.mmt-td .mmt-td-prow.is-excluded .mmt-td-elo { opacity: .5; }

/* Elo */
.mmt-td input.mmt-td-elo {
    width: 64px; padding: 4px 6px !important; font-size: 13px; text-align: center;
    font-variant-numeric: tabular-nums; -moz-appearance: textfield;
    border: 1px solid #d5d9e0; border-radius: 6px; transition: border-color .2s, box-shadow .2s;
}
.mmt-td input.mmt-td-elo::-webkit-outer-spin-button,
.mmt-td input.mmt-td-elo::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.mmt-td input.mmt-td-elo.is-saving { opacity: .6; }
.mmt-td input.mmt-td-elo.is-saved { border-color: #2ecc71 !important; box-shadow: 0 0 0 3px rgba(46,204,113,.2) !important; }
.mmt-td input.mmt-td-elo.is-error { border-color: #e74c3c !important; box-shadow: 0 0 0 3px rgba(231,76,60,.2) !important; }

/* Casilla Parear (interruptor) */
.mmt-td .mmt-td-check { position: relative; display: inline-block; width: 34px; height: 19px; cursor: pointer; vertical-align: middle; }
.mmt-td .mmt-td-check input { position: absolute; opacity: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; z-index: 1; }
.mmt-td .mmt-td-check span {
    position: absolute; inset: 0; border-radius: 999px; background: #c9ced6; transition: background .18s;
}
.mmt-td .mmt-td-check span::after {
    content: ""; position: absolute; top: 2px; left: 2px; width: 15px; height: 15px; border-radius: 50%;
    background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.3); transition: transform .18s;
}
.mmt-td .mmt-td-check input:checked + span { background: #27ae60; }
.mmt-td .mmt-td-check input:checked + span::after { transform: translateX(15px); }
.mmt-td .mmt-td-check input:focus-visible + span { box-shadow: 0 0 0 3px rgba(79,220,255,.35); }
.mmt-td .mmt-td-check input:disabled + span { opacity: .5; }

/* Tema oscuro */
.mmt-esports-portal .mmt-td .mmt-td-roster-help { color: #8394b8; }
.mmt-esports-portal .mmt-td .mmt-td-roster-count { background: rgba(46,204,113,.14); color: #4ee89a; }
.mmt-esports-portal .mmt-td .mmt-td-roster-table th { color: #9fb3d9; border-bottom-color: rgba(120,170,255,.22); background: #0d1428; }
.mmt-esports-portal .mmt-td .mmt-td-roster-table td { border-bottom-color: rgba(120,170,255,.08); }
.mmt-esports-portal .mmt-td .mmt-td-roster-table tbody tr:hover { background: rgba(79,220,255,.05); }
.mmt-esports-portal .mmt-td .mmt-td-dot { background: #46567c; }
.mmt-esports-portal .mmt-td .mmt-td-dot.on { background: #2ecc71; }
.mmt-esports-portal .mmt-td .mmt-td-check span { background: #2a3654; }
.mmt-esports-portal .mmt-td .mmt-td-check input:checked + span { background: #1fae63; }
.mmt-esports-portal .mmt-td .mmt-td-warn { color: #ffb4ab !important; }

/* ============================================================
   v1.13.9 — Jugadores como pestaña (árbitro) + partidas estilo lichess
   ============================================================ */
/* Árbitro: la tabla de jugadores ahora ocupa todo el ancho */
.mmt-td .mmt-td-roster-wrap { max-height: none; overflow: visible; }
.mmt-td .mmt-td-roster-table th:nth-child(2) { width: 90px; }
.mmt-td .mmt-td-roster-table th:nth-child(3) { width: 70px; }
.mmt-td a.mmt-td-pgn { margin-left: auto; text-decoration: none; }

/* --- Mis partidas --- */
.mmt-mygames { max-width: 900px; margin: 0 auto; }
.mmt-mg-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.mmt-mg-filters { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-bottom: 12px; }
.mmt-mg-row { position: relative; padding-left: 22px; }
.mmt-mg-color { position: absolute; left: 9px; top: 50%; transform: translateY(-50%); width: 6px; height: 60%; border-radius: 3px; }
.mmt-mg-color.w { background: #e9edf5; }
.mmt-mg-color.b { background: #10151f; border: 1px solid #5b7290; }
.mmt-mg-score { font-weight: 800; color: #eaf2ff; font-variant-numeric: tabular-nums; }
.mmt-mg-tlink { color: #9fb3d9 !important; text-decoration: none; }
.mmt-mg-tlink:hover { color: #4fdcff !important; text-decoration: underline; }
.mmt-history-actions { display: flex; gap: 6px; flex-wrap: wrap; }
.mmt-mg-help { color: #8ea3c8; font-size: 13px; margin: 0 0 12px; }
.mmt-mg-rank { display: flex; flex-direction: column; align-items: center; min-width: 70px; line-height: 1.15; }
.mmt-mg-rank .pos { font-family: 'Orbitron', sans-serif; font-weight: 800; font-size: 18px; color: #4fdcff; }
.mmt-mg-rank .of, .mmt-mg-rank .pts { font-size: 11px; color: #8ea3c8; }
.mmt-mg-rank .pts { color: #d7e3ff; font-weight: 700; }

/* --- Repetición estilo lichess --- */
.mmt-replay.mmt-rp { max-width: 1060px; }
.mmt-rp .mmt-replay-head { justify-content: space-between; }
.mmt-rp-event { display: flex; flex-direction: column; align-items: flex-end; text-align: right; gap: 2px; }
.mmt-rp-event a { color: #eaf2ff !important; font-weight: 700; text-decoration: none; }
.mmt-rp-event a:hover { color: #4fdcff !important; }
.mmt-rp-event span { color: #8ea3c8; font-size: 12.5px; }
.mmt-rp-layout { display: grid; grid-template-columns: minmax(0, 560px) minmax(240px, 1fr); gap: 18px; align-items: start; }
.mmt-rp-boardcol { min-width: 0; }
.mmt-rp .mmt-replay-board { max-width: 560px; }
.mmt-rp-player { display: flex; align-items: center; gap: 8px; padding: 7px 4px; color: #d7e3ff; font-size: 14px; }
.mmt-rp-pc { width: 12px; height: 12px; border-radius: 3px; flex: 0 0 12px; }
.mmt-rp-pc.w { background: #e9edf5; }
.mmt-rp-pc.b { background: #10151f; border: 1px solid #5b7290; }
.mmt-rp-name { font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mmt-rp-elo { color: #8ea3c8; font-size: 12px; }
.mmt-rp-clock { margin-left: auto; font-variant-numeric: tabular-nums; font-weight: 700; color: #b9c8ea;
    background: rgba(20,28,48,.7); border: 1px solid rgba(79,220,255,.18); border-radius: 7px; padding: 3px 10px; min-width: 64px; text-align: center; }
.mmt-rp-clock.turn { color: #061024; background: #4fdcff; border-color: #4fdcff; }
.mmt-sq.hl::before { content: ""; position: absolute; inset: 0; background: rgba(255,214,64,.42); }
.mmt-sq img { position: relative; z-index: 1; }
.mmt-coord { position: absolute; font-size: 10px; font-weight: 700; line-height: 1; opacity: .75; pointer-events: none; z-index: 2; }
.mmt-coord.r { top: 3px; left: 3px; }
.mmt-coord.f { bottom: 2px; right: 3px; }
.mmt-sq.light .mmt-coord { color: #5b7290; }
.mmt-sq.dark .mmt-coord  { color: #e9edf5; }

.mmt-rp-side { background: rgba(20,28,48,.6); border: 1px solid rgba(79,220,255,.15); border-radius: 12px; overflow: hidden; display: flex; flex-direction: column; }
.mmt-rp-moves { display: grid; grid-template-columns: 44px 1fr 1fr; max-height: 430px; overflow-y: auto; font-size: 14px; }
.mmt-rp-moves .n { color: #6c7ea6; background: rgba(6,12,30,.45); padding: 5px 8px; text-align: right; font-variant-numeric: tabular-nums; }
.mmt-rp-moves .mv { background: transparent; border: none; color: #d7e3ff; text-align: left; padding: 5px 10px; cursor: pointer; font: inherit; font-weight: 600; }
.mmt-rp-moves .mv:hover { background: rgba(79,220,255,.10); }
.mmt-rp-moves .mv.cur { background: rgba(79,220,255,.22); color: #fff; }
.mmt-rp-moves .mv.empty { cursor: default; }
.mmt-rp-empty { grid-column: 1 / -1; padding: 16px; color: #8ea3c8; font-size: 13px; }
.mmt-rp-result { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 10px; border-top: 1px solid rgba(79,220,255,.12); }
.mmt-rp-result strong { font-size: 18px; color: #eaf2ff; }
.mmt-rp-result span { font-size: 12px; color: #8ea3c8; font-style: italic; }
.mmt-rp-actions { display: flex; gap: 8px; padding: 10px; border-top: 1px solid rgba(79,220,255,.12); flex-wrap: wrap; }
.mmt-rp-actions .mmt-btn { flex: 1 1 auto; text-align: center; }
.mmt-rp-pgn { padding: 0 10px 10px; }
.mmt-rp-pgn summary { cursor: pointer; color: #8ea3c8; font-size: 12px; padding: 4px 0; }
.mmt-rp-pgn textarea { width: 100%; box-sizing: border-box; font-family: ui-monospace, monospace; font-size: 11px; resize: vertical; }

@media (max-width: 820px) {
    .mmt-rp-layout { grid-template-columns: 1fr; }
    .mmt-rp-moves { max-height: 220px; }
    .mmt-rp-event { align-items: flex-start; text-align: left; }
}

/* ============================================================
   v1.13.12 — Resultados por default y selector rápido
   ============================================================ */
.mmt-td .mmt-td-res.is-forfeit { color: #e67e22; }
.mmt-esports-portal .mmt-td .mmt-td-res.is-forfeit { color: #ffb070; }
.mmt-td select.mmt-td-ressel {
    width: auto; max-width: 150px; padding: 5px 8px !important; font-size: 12px; border-radius: 8px;
    border: 1px solid #d5d9e0; cursor: pointer;
}
.mmt-esports-portal .mmt-td select.mmt-td-ressel {
    background: #0d1428 !important; color: #dbe6ff !important; border-color: rgba(120,170,255,.3) !important;
}
.mmt-esports-portal .mmt-td select.mmt-td-ressel option,
.mmt-esports-portal .mmt-td select.mmt-td-ressel optgroup { background: #0d1428; color: #dbe6ff; }
@media (max-width: 600px) { .mmt-td select.mmt-td-ressel { max-width: none; flex: 1 1 100%; } }

/* ============================================================
   v1.13.13 — Administración de liga
   ============================================================ */
.mml-info { margin-top: 12px; padding: 12px 14px; border-radius: 10px; font-size: 13px;
    background: #f7f9fc; border: 1px solid #e5e8ee; display: flex; flex-direction: column; gap: 10px; }
.mml-info-row { line-height: 1.5; }
.mml-info .mml-muted { color: #7f8c8d; }
.mml-linkbox { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: 4px; }
.mml-linkbox > a:first-child { word-break: break-all; font-weight: 600; }
.mml-info code { padding: 2px 8px; border-radius: 4px; background: #eef2f8; }
.mml-check { display: flex; align-items: center; gap: 8px; cursor: pointer; }
.mml-check input { width: auto; margin: 0; }
.wcp-btn.mml-mini { padding: 4px 10px !important; font-size: 11px !important; background: #7f8c8d; }
.mml-preview-title { margin: 18px 0 10px; font-size: 15px; }
.mml-jornada { background: #f7f9fc; }
.mml-jlink { color: #2c3e50; }

.mmt-esports-portal .mml-info { background: rgba(20,28,48,.6); border-color: rgba(79,220,255,.18); color: #dbe6ff; }
.mmt-esports-portal .mml-info .mml-muted { color: #8ea3c8; }
.mmt-esports-portal .mml-info strong { color: #eaf2ff; }
.mmt-esports-portal .mml-linkbox > a:first-child { color: #4fdcff !important; }
.mmt-esports-portal .mml-info code { background: rgba(6,12,30,.7); color: #cfe0ff; border: 1px solid rgba(120,170,255,.2); }
.mmt-esports-portal .mml-preview-title { color: #9fb3d9; }
.mmt-esports-portal .mml-jornada { background: rgba(20,28,48,.55) !important; border: 1px solid rgba(120,170,255,.16) !important; }
.mmt-esports-portal .mml-jlink { color: #eaf2ff !important; }

/* ============================================================
   v1.13.18 — Juego limpio (anti-trampas)
   ============================================================ */
.mmt-fp-card, .mmt-fp-panel { color: #dbe6ff; }
.mmt-fp-card { background: rgba(20,28,48,.6); border: 1px solid rgba(79,220,255,.18); border-radius: 12px; padding: 14px; margin-bottom: 15px; }
.mmt-fp-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-bottom: 8px; }
.mmt-fp-head h4 { margin: 0; font-size: 14px; color: #eaf2ff; }
.wcp-btn.mmt-fp-btn { background: #2d6cdf; padding: 7px 14px; font-size: 12px; }
.wcp-btn.mmt-fp-btn.sm { padding: 4px 10px; font-size: 11px; }
.wcp-btn.mmt-fp-btn.ghost { background: transparent; border: 1px solid rgba(79,220,255,.4) !important; color: #4fdcff; text-decoration: none; }
.mmt-fp-status { font-size: 12px; color: #9fb3d9; min-height: 1em; }
.mmt-fp-status.is-saving { color: #4fdcff; font-weight: 700; }
.mmt-fp-player { padding: 10px 0; border-top: 1px solid rgba(120,170,255,.12); }
.mmt-fp-ph { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.mmt-fp-ph strong { color: #eaf2ff; font-size: 14px; }
.mmt-fp-pc { width: 11px; height: 11px; border-radius: 3px; }
.mmt-fp-pc.w { background: #e9edf5; } .mmt-fp-pc.b { background: #10151f; border: 1px solid #5b7290; }
.mmt-fp-stats { display: flex; flex-wrap: wrap; gap: 6px 14px; margin-top: 6px; font-size: 12px; color: #9fb3d9; }
.mmt-fp-stats b { color: #eaf2ff; }
.mmt-fp-muted { color: #7f8fb3; }
.mmt-fp-level { display: inline-block; font-size: 11px; font-weight: 700; padding: 2px 9px; border-radius: 999px; white-space: nowrap; }
.mmt-fp-level.suspect { background: rgba(231,76,60,.18); color: #ff8a7a; border: 1px solid rgba(231,76,60,.5); }
.mmt-fp-level.review  { background: rgba(240,173,78,.16); color: #ffcf7a; border: 1px solid rgba(240,173,78,.45); }
.mmt-fp-level.clean   { background: rgba(46,204,113,.12); color: #4ee89a; border: 1px solid rgba(46,204,113,.35); }
.mmt-fp-level.nodata  { background: rgba(120,140,180,.14); color: #9fb3d9; border: 1px solid rgba(120,140,180,.3); }
.mmt-fp-flags { list-style: none; margin: 6px 0 0 !important; padding: 0 !important; display: flex; flex-direction: column; gap: 3px; }
.mmt-fp-flags li { font-size: 12px; padding-left: 16px; position: relative; color: #cfd8ea; margin: 0 !important; }
.mmt-fp-flags li::before { content: ""; position: absolute; left: 3px; top: 6px; width: 7px; height: 7px; border-radius: 50%; }
.mmt-fp-flags li.red::before { background: #ff6b5b; } .mmt-fp-flags li.amber::before { background: #f0ad4e; } .mmt-fp-flags li.info::before { background: #7f8fb3; }
.mmt-fp-flags li.red { color: #ffb4ab; }
.mmt-fp-note { font-size: 11.5px; color: #8394b8; margin: 10px 0 0; line-height: 1.5; }
.mmt-fp-sub { margin: 16px 0 8px; font-size: 13px; color: #9fb3d9; }
.mmt-fp-wrap { overflow-x: auto; border: 1px solid rgba(120,170,255,.16); border-radius: 10px; }
.mmt-fp-table { width: 100%; border-collapse: collapse; font-size: 12.5px; }
.mmt-fp-table th, .mmt-fp-table td { padding: 8px 10px; text-align: center; border-bottom: 1px solid rgba(120,170,255,.1); color: #dbe6ff; vertical-align: top; }
.mmt-fp-table thead th { font-size: 11px; color: #9fb3d9; background: rgba(6,12,30,.7); white-space: nowrap; }
.mmt-fp-table .l { text-align: left; }
.mmt-fp-table small { color: #8394b8; }
.mmt-fp-cell { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.mmt-fp-mini { font-size: 11.5px; color: #9fb3d9; margin-top: 3px; }
.mmt-fp-actions { white-space: nowrap; }
.mmt-fp-actions .mmt-fp-btn { margin: 0 2px 4px; }

/* v1.13.19 — títulos del panel de juego limpio con la tipografía del portal */
.mmt-fp-panel h3, .mmt-fp-panel h4, .mmt-fp-card h4, .mmt-fp-sub {
    font-family: 'Montserrat', system-ui, sans-serif !important; color: #9fb3d9; letter-spacing: 0; text-transform: none;
}
.mmt-fp-panel h3 { color: #eaf2ff; }

/* ============================================================
   v1.13.21 — Grabaciones de cámara
   ============================================================ */
.mmt-rec { border-top: 1px solid rgba(120,170,255,.12); margin-top: 10px; }
.mmt-rec-keep { display: flex; align-items: center; gap: 6px; font-size: 12px; color: #9fb3d9; cursor: pointer; }
.mmt-rec-keep input { width: auto; margin: 0; }
.mmt-rec-player { padding: 6px 0; }
.mmt-rec-ph { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 4px; }
.mmt-rec-ph strong { color: #eaf2ff; font-size: 13px; }
.mmt-rec-ph small { font-size: 11px; }
.mmt-rec-part { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 12px; color: #cfd8ea; padding: 4px 0; }
.mmt-rec-part span:first-child { flex: 1 1 200px; }
.mmt-rec-video { width: 100%; max-height: 300px; border-radius: 8px; background: #000; margin: 4px 0 8px; display: block; }
