/* PixelParty classic 32x32 canvas treatment.
   Kept isolated from the consolidated portal CSS so BlazeBoard and ZapBoard
   retain the cellular appearance of the original production pages. */

.classic-pixel-grid {
  display: grid;
  grid-template-columns: repeat(32, 1fr);
  grid-template-rows: repeat(32, 1fr);
  grid-gap: 1px;
  width: 600px;
  height: 600px;
  margin: 0 auto 14px;
  padding: 0;
  background: transparent;
  overflow: visible;
}

/* Deliberately undo the portal-wide border-box/appearance reset here.
   The old production canvas allowed each cell to retain its own visible
   white frame, which creates the stronger 'cellular' board appearance. */
.classic-pixel-grid .cell {
  box-sizing: content-box;
  background-color: #ddd;
  border: 1px solid #fff;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 12px;
  color: #333;
  width: auto;
  height: auto;
  min-width: 0;
  min-height: 0;
  margin: 0;
  padding: 0;
  border-radius: 0;
  position: relative;
  appearance: none;
  -webkit-appearance: none;
}

.classic-pixel-grid .cell:hover::after {
  content: attr(data-tooltip);
  display: block;
  position: absolute;
  background-color: #fff;
  color: #333;
  padding: 5px;
  border-radius: 5px;
  font-size: 12px;
  top: 0;
  left: 100%;
  margin-left: 10px;
  z-index: 20;
}

@media (max-width: 680px) {
  .classic-pixel-grid {
    width: calc(100vw - 28px);
    height: calc(100vw - 28px);
    max-width: 600px;
    max-height: 600px;
  }

  .classic-pixel-grid .cell {
    /* On small displays keep the same visible cell boundaries without
       allowing the content-box borders to widen the overall board. */
    box-sizing: border-box;
  }
}
