/* Grid Container */
#grid-container {
  width: 100%;
  background-color: #000; /* black background for gutter */
  padding: 8px;
  border: 2px solid #ccc;
  box-sizing: border-box;
}

/* Grid Layout */
.grid-container {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-template-rows: repeat(8, auto);
  gap: 4px;
  width: 100%;
}

/* Individual Cell */
.grid-cell {
  min-height: 3em;
  position: relative;
  border: 1px solid #ccc;
  border-radius: 6px;
  padding: 8px;
  text-align: center;
  background-color: #f8f8f8;
  transition: background-color 0.2s;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 1.5em;
}

/* Key Indicator */
.key-indicator {
  color: red;
  font-size: 0.75em;
  position: absolute;
  top: 4px;
  left: 6px;
  font-weight: bold;
  text-align: left;
}

/* Word + Prefix */
.word-combo {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  gap: 0.3em;
  flex-wrap: wrap;
  font-size: 1em;
  font-weight: bold;
}

.next-prefix {
  color: red;
  font-size: 1em;
  font-weight: bold;
  white-space: nowrap;
}

/* Text Input */
.text-box {
  width: 100%;
  padding: 8px;
  font-size: 1.5em;
  margin-top: 16px;
}

/* Special Cells */
.grid-cell.muwords {
  background-color: #004d00;
  color: white;
  font-weight: bold;
  pointer-events: none;
}

.grid-cell.settings {
  background-color: #002b80;
  color: white;
  font-weight: bold;
  pointer-events: none;
}

/* Reactive cells alternate rows */
.grid-cell.reactive.row-even {
  background-color: #ffffff;
}
.grid-cell.reactive.row-odd {
  background-color: #e0f7fa;
}

/* Press states */
.grid-cell.reactive.highlight {
  background-color: #d0f0ff !important;
}
.grid-cell.reactive.long-press {
  background-color: #ffe0cc !important;
}
.grid-cell.reactive:hover {
  outline: 2px solid #aaa;
}
.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 999;
}

.modal-content {
  background: white;
  padding: 2em;
  border-radius: 8px;
  box-shadow: 0 0 10px black;
  max-width: 90%;
  max-height: 90%;
}

.hidden {
  display: none;
}

