/*
 * Estilos para INDEX 100
 *
 * Este archivo define el aspecto retro del encabezado y la cuadrícula
 * de 100 píxeles. La página no tiene explicaciones ni textos adicionales;
 * sólo el título y el tablero interactivo.
 */

/* Reset básico */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html, body {
  height: 100%;
}

body {
  font-family: 'Press Start 2P', monospace;
  background-color: #f7f9fc;
  color: #333;
  display: flex;
  flex-direction: column;
}

/* Cabecera retro */
.site-header {
  background-color: #0a174d;
  color: #fff;
  text-align: center;
  padding: 1rem 0;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.site-header h1 {
  font-size: 2rem;
  letter-spacing: 2px;
}

/* Contenedor principal */
.content {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

/* Cuadrícula de 100 píxeles */
.grid {
  display: grid;
  /* Define 10 columnas y 10 filas iguales */
  grid-template-columns: repeat(10, 1fr);
  grid-template-rows: repeat(10, 1fr);
  width: min(90vw, 600px);
  height: min(90vw, 600px);
  border: 2px solid #b3c7ff;
}

.grid-cell {
  position: relative;
  width: 100%;
  height: 100%;
  background-color: #e0e7ff;
  border: 1px solid #b3c7ff;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.grid-cell img.logo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  margin: 0;
  padding: 0;
}

.grid-cell .cell-content {
  font-size: 0.5rem;
  text-align: center;
  color: #0a174d;
  padding: 0px;
}

/* Modal overlay */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

.modal[aria-hidden="false"] {
  display: flex;
}

.modal-dialog {
  background-color: #fff;
  border-radius: 8px;
  width: 90%;
  max-width: 400px;
  padding: 1.5rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
  font-family: Arial, sans-serif;
  color: #333;
}

.modal-dialog h2 {
  margin-bottom: 0.5rem;
  font-size: 1.25rem;
}

#modal-price, #new-price {
  margin: 0.5rem 0;
  font-weight: bold;
  color: #0a174d;
}

form label {
  display: block;
  margin-bottom: 0.25rem;
}

input[type="file"] {
  display: block;
  margin-bottom: 0.75rem;
}

.button-row {
  display: flex;
  justify-content: space-between;
  margin-top: 1rem;
}

.btn {
  padding: 0.5rem 1rem;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-size: 1rem;
}

.btn.primary {
  background-color: #0a174d;
  color: #fff;
}

.btn.secondary {
  background-color: #e0e0e0;
  color: #333;
}

.btn.primary:hover {
  background-color: #08123a;
}

.btn.secondary:hover {
  background-color: #c7c7c7;
}