#ia-processing-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999;
    pointer-events: none;
    background: none;
    display: none;
}

body.waiting-vert {
    cursor: url('../assets/cursors/vertical.png') 16 16, auto !important;
}

body.waiting-hor {
    cursor: url('../assets/cursors/horizontal.png') 16 16, auto !important;
}

body.waiting-vert #ia-processing-overlay,
body.waiting-hor #ia-processing-overlay {
    display: block !important;
}

/* Fallback para navegadores sem suporte */
@supports not (cursor: url()) {
    #ia-processing-overlay {
        cursor: wait !important;
    }
}

.game-container {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 50px;
  margin-bottom: 10px;
}

.cell {
  width: 50px;
  height: 50px;
  background: white;
  border: 1px solid #ddd;
  display: flex;
  align-items: center;
  justify-content: center;
}

.cell:hover {
  background: #f8f8f8;
  transform: scale(1.0);
}

.temp-piece {
  opacity: 0.5;
  margin-top: 2px;
  margin-left: 2px;
  pointer-events: none;
}

/* Estilo base do dominó */
.domino-vertical, .domino-horizontal {
  position: absolute;
  border-radius: 5px;
  border: 1px solid black; /* Para destacar a peça */   
  z-index: 10;
}

/* Vertical: cobre 2 células em altura */
.domino-vertical {
  width: 90%;
  height: 190%; /* Ocupar duas células verticalmente */
  background-color:rgb(118, 118, 153); /* Azul */ 
}

/* Horizontal: cobre 2 células em largura */
.domino-horizontal {
  width: 190%; /* Ocupar duas células horizontalmente */
  height: 90%;
  background-color: rgb(240, 136, 136); /* Vermelho */
}

.domino-horizontal .move-number,
.domino-vertical .move-number {
  font-size: 18px;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
  z-index: 3;
}

.cell.highlight-possible {
  background-color: #f5f2ec; /* azul claro suave */
  box-shadow: inset 0 0 3px rgba(0, 0, 0, 0.3);
  transition: background-color 0.2s;
}
  
#possible-moves {
  display: flex;
  gap: 10px;
  margin-bottom: 10px;
}

  /* Stocks */

.stock-panel {
  padding: 1rem;
  border-radius: 15px;
  min-width: 150px;
}

.stock-panel, .main-area {
  flex: 0 1 auto; /* Mantém proporções naturais */
}

.stock-panel h2 {
  margin: 0 0 1rem 0;
  color: #666;
  font-size: 1.2rem;
}

#verticalStock.hidden,
#horizontalStock.hidden {
  display: none;
}

#vertical-moves.hidden,
#horizontal-moves.hidden {
  display: none;
}

.pieces-vertical {
  display: grid;
  grid-template-columns: repeat(4, 20px);
  gap: 12px;
  margin-top: 10px;
}

.pieces-horizontal {
  display: grid;
  grid-template-columns: repeat(3, 50px);
  gap: 12px;
  margin-top: 10px;
}

.piece-vertical-peq {
  width: 25px;
  height: 50px;
  background-color: rgb(118, 118, 153);
  border-radius: 2px;
}

.piece-horizontal-peq {
  width: 50px;
  height: 25px;
  background-color: rgb(240, 136, 136);
  border-radius: 1px;
}

.piece .move-number {
  position: absolute;
  font-size: 0.7em;
  font-weight: bold;
  z-index: 2;
  pointer-events: none;
  background: transparent;
  padding: 4px 2px;
  border-radius: 4px;
}

/* Indicadores de status */
.turn-indicator {
  text-align: center;
  margin-bottom: 1rem;
}

#current-turn {
  font-size: 2rem;
  vertical-align: middle;
}

#remaining-moves {
  font-size: 1.5rem;
  color: #666;
}

/* Modo responsivo */
@media (max-width: 768px) {
  .game-container {
      flex-direction: column;
      align-items: center;
  }
  
  .quadratic-board {
      grid-template-columns: repeat(var(--board-size), 40px); /* Células menores */
  }

  .cell {
      width: 35px;
      height: 35px;
  }
}