
/* ==========================================================================
   FUENTES LOCALES OFICIALES (BLINDADAS AL 100% CONTRA ERRORES CORS)
   ========================================================================== */

/* 1. FUENTE MARVIN (PARA TÍTULOS Y BOTONES) */
@font-face {
    font-family: "Marvin";
    src: url("../fonts/Marvin-webfont.woff2") format("woff2"),
         url("../fonts/Marvin-webfont.woff") format("woff");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

/* 2. FUENTE DICEFONT (PARA LOS ICONOS DE DADOS ORIGINALES) */
@font-face {
    font-family: "dicefont";
    src: url("../fonts/dicefont.eot");
    src: url("../fonts/dicefont.eot?#iefix") format("embedded-opentype"),
         url("../fonts/dicefont.woff") format("woff"), 
         url("../fonts/dicefont.ttf") format("truetype"), 
         url("../fonts/dicefont.svg#dicefont") format("svg");
    font-weight: normal;
    font-style: normal;
}

/* --- ESTILOS GENERALES Y FONDO --- */
body {
    margin: 0;
    padding: 0;
    color: white;
    display: flex;
    flex-direction: column;
    align-items: center;
    min-height: 100vh;
    box-sizing: border-box;

    /* --- CAPA MAESTRA DE DOBLE FONDO (ILUMINACIÓN + TEXTURA) --- */
    background:#08f radial-gradient(#f1f9ff, #08f); /* Azul base oficial de fondo */
    background-image: 
        url("../img/light.png"),  /* Capa 1 (Arriba): Destello blanco superior */
        url("../img/bg-lg.png");  /* Capa 2 (Abajo): Mosaico geométrico de dados */
        
    background-repeat: 
        repeat-x,                 /* El destello solo se estira hacia los lados en el techo */
        repeat;                   /* El mosaico de dados se duplica en toda la pantalla */
        
    background-position: 
        top center,               /* Fijamos la luz en la parte más alta */
        center center;            /* Centramos el mosaico */
        
    background-size: 
        100% 100px,               /* Altura controlada para el difuminado superior */
        500px;                    /* Medida exacta oficial de la línea 9403 de tu captura */
}

/* --- ENCABEZADO --- */
header {
    text-align: center;
    margin-top: 20px;
    margin-bottom: 10px;
}
.logo-title {
    font-size: 3rem;
    color: #fffb00;
    text-shadow: 3px 3px 0px #b8860b, 5px 5px 0px rgba(0,0,0,0.4);
    margin: 0;
    letter-spacing: 2px;
    text-transform: uppercase;
}
.logo-subtitle {
    font-size: 1.1rem;
    color: white;
    font-family: "Marvin", Arial, sans-serif !important;
    font-weight: bold;
    text-transform: uppercase;
    margin-top: 5px;
    letter-spacing: 1px;
}

/* --- CONTENEDOR PRINCIPAL REJILLA (3 COLUMNAS) --- */
.main-layout {
    display: grid;
    grid-template-columns: 280px 1fr 280px;
    gap: 20px;
    width: 95%;
    max-width: 1300px;
    margin-bottom: 30px;
}

/* --- BARRAS LATERALES (STREAMERS / USUARIOS) --- */
.sidebar {
   /* background-color: #3182ce;*/
   background: rgba(0, 136, 255, 0.7);
    border: 3px solid #ebebeb;
    border-radius: 16px;
    padding: 15px;
    box-shadow: 0 8px 16px rgba(0,0,0,0.2);
    height: fit-content;
}
.sidebar h2 {
    font-size: 1.1rem;
    text-align: center;
    margin-top: 0;
    border-bottom: 2px solid rgba(255,255,255,0.2);
    padding-bottom: 10px;
    letter-spacing: 1px;
}

/* --- CONTENEDOR CENTRAL DEL JUEGO --- */
.game-center {
    display: flex;
    flex-direction: column;
    gap: 20px;
}
.card-panel {
    /*background-color: #4299e1;
    background: rgba(0, 136, 255, 0.45);*/
    background: rgba(225, 225, 225, 0.2);
    border: 4px solid #fff;
    border-radius: 20px;
    padding: 25px;
    box-shadow: 0 10px 20px rgba(0,0,0,0.15);
    text-align: center;
}
.panel-title {
    font-size: 1.6rem;
    font-family: "Marvin", Arial, sans-serif !important;
    text-shadow: -1px -1px 0 #08f, 1px -1px 0 #08f, -1px 1px 0 #08f, 3px 3px 0 #08f;
    letter-spacing: .02em;
    text-transform: uppercase;
    margin-top: 0;
    margin-bottom: 20px;
}

/* --- SELECTORES SUPERIORES --- */
.selectors-row {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 25px;
}
.mock-select {
    background-color: white;
    color: #2b6cb0;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 0.9rem;
    font-weight: bold;
    border: 2px solid #cbd5e0;
}

/* --- TABLERO DE DADOS --- */
.dice-board {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-bottom: 25px;
}

/* --- DADOS FÍSICOS CON PUNTOS (CSS PURE) --- */
.dice {
    width: 85px;
    height: 85px;
    border-radius: 18px;
    position: relative;
    box-shadow: inset -6px -6px 12px rgba(0,0,0,0.3), 3px 6px 10px rgba(0,0,0,0.3);
    border: 7px solid rgb(255 255 255);
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: repeat(3, 1fr);
    padding: 8px;
    box-sizing: border-box;
}
/* --- NUEVOS COLORES DE FONDO PARA LOS DADOS --- */
.d-rojo     { background-color: #ff0000; }
.d-naranja  { background-color: #ff7f00; }
.d-amarillo { background-color: #ffd700; }
.d-verde    { background-color: #008000; }
.d-azul     { background-color: #0000ff; }
.d-morado   { background-color: #800080; }


/* Puntos del dado */
.dot {
    background-color: white;
    border-radius: 50%;
    width: 14px;
    height: 14px;
    margin: auto;
    box-shadow: inset 1px 1px 2px rgba(0,0,0,0.6);
}

/* Ubicaciones de los puntos usando Grid de 3x3 */
.pos-1 { grid-area: 1 / 1; }
.pos-2 { grid-area: 1 / 3; }
.pos-3 { grid-area: 2 / 1; }
.pos-4 { grid-area: 2 / 2; } /* Centro */
.pos-5 { grid-area: 2 / 3; }
.pos-6 { grid-area: 3 / 1; }
.pos-7 { grid-area: 3 / 3; }

/* --- BOTÓN DE TIRAR NUEVO --- 
.btn-action {
    background-color: #ffcc00;
    color: #1a202c;
    border: 3px solid white;
    border-radius: 12px;
    padding: 14px 40px;
    font-size: 1.5rem;
    font-weight: bold;
    cursor: pointer;
    box-shadow: 0 6px 0px #cc9900, 0 8px 15px rgba(0,0,0,0.3);
    transition: all 0.1s ease;
    width: 90%;
    max-width: 400px;
    text-transform: uppercase;
    margin: 15px 0;
}
.btn-action:active {
    transform: translateY(4px);
    box-shadow: 0 2px 0px #cc9900, 0 4px 6px rgba(0,0,0,0.3);
}*/
/* --- BOTÓN DE TIRAR NUEVO (ESTILO ORIGINAL EXTRACTO DEVTOOLS) --- */
/* --- BOTÓN DE TIRAR NUEVO (ESTILO ORIGINAL DEVTOOLS CON HOVER INTEGRADO) --- */
.btn-action{
    width: calc(100% - 10px);
    max-width: 400px;
    margin: 15px auto;
    box-sizing: border-box;
    font-size: 22px;
    padding: 13px 0; /* Medida exacta de la página 21 */
    cursor: pointer;
    text-transform: uppercase;
    font-weight: bold;
    font-family: "Marvin", Arial, sans-serif;

    color: #fff;
    border-radius: 4px;
    letter-spacing: 0.02em;
    transition: background-position 0.15s ease, transform 0.1s ease; /* Transición suave para el brillo */
    display: block;

    /* Sombra de relieve tridimensional en el texto original */
    text-shadow: -1px -1px 0 #ca8a00, 1px -1px 0 #ca8a00, -1px 1px 0 #ca8a00, 2px 2px 0 #ca8a00;

    /* Degradado lineal oficial de la página 21 (El doble de alto) */
    background: rgb(255,215,0);
    background-image: linear-gradient(to bottom, rgb(255,235,0) 0%, rgb(255,215,0) 51%, rgb(255,244,188) 100%);
    background-size: auto 200%;

    /* Bordes tridimensionales semitransparentes oficiales */
    border-top: 3px solid #fff;
    border-right: 3px solid rgba(255,255,255,0.8);
    border-bottom: 3px solid rgba(255,255,255,0.8);
    border-left: 3px solid rgba(255,255,255,0.8);
}

/* --- EFECTO HOVER ORIGINAL: Desplaza el degradado para que brille al pasar el mouse --- */
.btn-action:hover, #btnRoll:hover, #roll-button:hover {
    background-position: bottom center; /* Sube el tono claro original de la línea 1461 */
}

/* Efecto de presión real al hacerle clic */
.btn-action:active, #btnRoll:active, #roll-button:active {
    transform: translateY(2px);
    border-top: 3px solid rgba(255, 255, 255, 0.3);
    border-bottom: 3px solid #fff;
}


/* --- CONTADOR NUMÉRICO --- */
.counter-display {
    font-size: 3.5rem;
    margin: 15px 0;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.4);
}

/* --- BLOQUES INFORMATIVOS INFERIORES --- */
.info-layout {
    width: 95%;
    max-width: 800px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-bottom: 5px;
}
.info-card {
    background-color: #2b6cb0;
    border: 3px solid #fff;
    border-radius: 16px;
    padding: 20px;
    font-family: Arial, sans-serif;
    font-size: 0.95rem;
    line-height: 1.5;
}
.info-card h3 {
    font-family: 'Arial Black', sans-serif;
    font-size: 1.2rem;
    margin-top: 0;
    text-align: center;
    color: #fff;
}

/* --- FOOTER LINKS --- */
footer {
    margin: 40px 0;
    text-align: center;
    font-family: Arial, sans-serif;
    font-size: 0.85rem;
}
.footer-links {
    margin-bottom: 15px;
}
.footer-links a {
    color: white;
    text-decoration: none;
    margin: 0 10px;
    font-weight: bold;
}
@keyframes pulse {
    0% { opacity: 0.7; }
    50% { opacity: 1; }
    100% { opacity: 0.7; }
}

/* --- ANIMACIÓN (GRIS MATE SIN BRILLOS) --- */
.dice-rolling {
    animation: shakeEffect 0.15s infinite alternate;
    background-color: #e2e8f0 !important; /* Gris ceniza mate exacto */
    border: 5px solid #fff !important; /* Borde gris plano sin relieve */
    box-shadow: none !important;            /* Eliminamos los brillos por completo */
    transform: scale(1.02);
}

/* El punto se mantiene blanco sólido e intenso para contrastar sobre el gris plano */
.dice-rolling .dot {
    background-color: #ffffff !important;
    opacity: 0.9 !important;               /* Blanco nítido y bien definido */
    transform: scale(0.9);
    box-shadow: 1px 1px 2px rgb(255 255 255) !important; /* Sutil sombra al punto para dar relieve */
}

@keyframes shakeEffect {
    0% { transform: translate(1px, 1px) rotate(0deg); }
    100% { transform: translate(-1px, -1px) rotate(0.5deg); }
}



/* ==========================================================================
   WIDGETS DE STREAMERS OFICIALES (CORREGIDO PARA TODO DISPOSITIVO)
   ========================================================================== */

/* Contenedor del perfil individual */
.streamer {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: flex-start !important;
    gap: 12px !important;
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    margin-bottom: 7px;
    padding: 6px 10px !important;
    text-decoration: none;
    color: #fff;
    box-sizing: border-box;
    transition: background 0.2s ease, border-color 0.2s ease;
    text-align: left !important;
    width: 100%;
    background: rgba(225, 225, 225, 0.2);
}

/* Estado activo/destacado cuando el streamer está LIVE */
.streamer_highlight {
    background: rgba(255, 255, 255, 0.15) !important;
    border-color: rgba(255, 255, 255, 0.5) !important;
}

/* Agrupador del avatar y su etiqueta Live */
.streamer-avatar-container {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    position: relative;
    flex-shrink: 0; /* Evita que se deforme en pantallas grandes */
}

/* Estilo y tamaño exacto para el contenedor del emoji */
.streamer-avatar {
    width: 38px;
    height: 38px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    border: 2px solid #fff;
    box-shadow: 0 2px 4px rgba(0,0,0,0.15);
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    font-size: 1.2rem; /* Tamaño óptimo para el emoji 👤 */
}

/* Alineación de los textos internos */
.streamer-info {
    display: flex !important;
    flex-direction: column !important;
    align-items: flex-start !important;
    text-align: left !important;
    line-height: 1.25;
    font-family: Arial, sans-serif;
}

.streamer-nickname {
    font-weight: bold;
    font-size: 0.95rem;
    color: #fff;
    display: flex !important;
    align-items: center !important;
    gap: 6px !important;
}

/* Estilo limpio para el Check Azul */
.streamer-badge-check {
    color: #4299e1; 
    background: #fff; 
    border-radius: 50%; 
    width: 13px; 
    height: 13px; 
    display: inline-flex !important; 
    justify-content: center !important; 
    align-items: center !important; 
    font-size: 0.65rem; 
    font-weight: bold;
    flex-shrink: 0;
}

.streamer-handle {
    font-size: 0.75rem;
    color: #cbd5e0;
    margin-top: 1px;
}

/* Medallón dinámico de "Live" ordenado abajo del avatar */
.live-indicator-badge {
    background-color: #e53e3e;
    color: white;
    padding: 1px 6px;
    border-radius: 10px;
    font-size: 0.62rem;
    font-weight: bold;
    letter-spacing: 0.3px;
    border: 1px solid #fff;
    margin-top: -6px;
    z-index: 2;
    text-shadow: 1px 1px 0 rgba(0,0,0,0.2);
    font-family: Arial, sans-serif;
    white-space: nowrap; /* Evita que la palabra se rompa en PC */
}
