@font-face { font-family: 'Roboto'; font-weight: 100; font-display: swap; src: url('lib/fuentes/roboto-100.woff2') format('woff2'); }
@font-face { font-family: 'Roboto'; font-weight: 300; font-display: swap; src: url('lib/fuentes/roboto-300.woff2') format('woff2'); }
@font-face { font-family: 'Roboto'; font-weight: 400; font-display: swap; src: url('lib/fuentes/roboto-400.woff2') format('woff2'); }

html, body { height: 100%; }

body {
  margin: 0;
  overflow: hidden;
  font-family: 'Roboto', 'Segoe UI', sans-serif;
  background: #fff;
}

#nube {
  position: fixed;
  inset: 0;
  display: block;
}

[hidden] { display: none !important; }

.inicio {
  position: fixed;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 18px;
  z-index: 10;
}

.boton-iniciar {
  padding: 20px 30px;
  font-size: 38px;
  font-family: inherit;
  font-weight: 100;
  cursor: pointer;
  border: none;
  border-radius: 5px;
  background-color: #007BFF;
  color: white;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}
.boton-iniciar:disabled { opacity: .6; cursor: progress; }
.boton-iniciar .gruesa { font-weight: 400; }

.campo-clave {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  font-weight: 300;
  color: #555;
}
.campo-clave input {
  font: 300 18px/1.2 'Roboto', 'Segoe UI', sans-serif;
  padding: 8px 12px;
  width: 260px;
  text-align: center;
  border: 1px solid #bbb;
  border-radius: 5px;
}

.mensaje-inicio {
  min-height: 1.4em;
  margin: 0;
  color: #c62828;
  font-weight: 400;
}

.toast {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  max-width: 92vw;
  box-sizing: border-box;
  font-weight: 200;
  background-color: #FF5733;
  color: white;
  padding: 20px;
  border-radius: 8px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  opacity: 0;
  transition: opacity 0.5s ease;
  z-index: 1000;
  display: flex;
  align-items: center;
  font-size: 50px;
}
.toast.visible { opacity: 1; }
.toast .gruesa { font-weight: 400; }
.toast .trofeo {
  flex: none;
  width: 100px;
  height: 100px;
  margin-right: 30px;
  fill: currentColor;
}

.final {
  position: fixed;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 20;
  pointer-events: none;
  text-align: center;
}
.final-titulo {
  margin: 0;
  padding: 20px 40px;
  font-size: 56px;
  font-weight: 300;
  color: #fff;
  background: #007BFF;
  border-radius: 8px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}
.final-detalle {
  margin: 16px 0 0;
  padding: 6px 14px;
  font-size: 22px;
  font-weight: 300;
  color: #333;
  background: rgba(255, 255, 255, .85);
  border-radius: 5px;
}

.aviso-conexion {
  position: fixed;
  top: 12px;
  right: 12px;
  z-index: 1100;
  max-width: 40vw;
  padding: 8px 14px;
  font-size: 15px;
  color: #fff;
  background: #b26a00;
  border-radius: 5px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, .25);
}
.aviso-conexion.grave { background: #c62828; }

.panel {
  position: fixed;
  left: 12px;
  bottom: 12px;
  z-index: 1050;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  max-width: calc(100vw - 24px);
  padding: 8px 10px;
  font-size: 14px;
  color: #333;
  background: rgba(255, 255, 255, .92);
  border: 1px solid #ddd;
  border-radius: 6px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, .12);
  transition: opacity .4s ease;
}
.panel.dormido { opacity: 0; }
.panel.dormido:hover, .panel.dormido:focus-within { opacity: 1; }
.panel button {
  font: 400 14px 'Roboto', 'Segoe UI', sans-serif;
  padding: 6px 12px;
  cursor: pointer;
  color: #fff;
  background: #007BFF;
  border: none;
  border-radius: 4px;
}
.panel button:disabled { opacity: .5; cursor: default; }
.panel #probar-correo, .panel #reenviar { background: #6c757d; }
.contadores { padding: 0 4px; }
