#drawCanvas {
  width: 100%; /* Responsive width */
  height: 100%; /* Maintain aspect ratio if needed */
  display: block; /* Removes inline spacing */
  touch-action: none; /* Prevent touch scroll on mobile */
  background: white;
}

#canvas-wrapper {
  aspect-ratio: 4 / 3;
  width: 100%;
  margin: 10px;
  margin-top: 0;
}



#doodledum-container {
  display: flex;
  justify-content: center;
  flex-direction: column;
  align-items: center;
  width: 100%;
}
#widget {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 10px;
}

#widget.hidden {
  display: none;
}
#drawing-controls {
  display: flex;
  flex-direction: column;
  justify-content: space-evenly;
  align-items: center;
  width: 100%;
  margin: 0 10px;
  padding: 5px;
  background: #13132a;
}

.mobile-button {
  display: none;
}

.swatch {
  border-radius: 50%;
  width: 25px;
  height: 25px;
  cursor: pointer;
  border: 1px solid #ccc;
}

.brushSizeBtn {
  padding: 5px 8px;
  font-size: 14px;
  cursor: pointer;
}

#draw-eraser-container,
#brushSizeControls {
  display: flex;
}

#drawBtn,
#eraserBtn,
#fillBtn,
.brushSizeBtn {
  border-radius: 50%;
  margin: 1px;
  border: none;
  width: 32px;
  height: 32px;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: white;
  cursor: pointer;
}

#fixedPalette {
  flex-grow:1;
  display: grid;
  grid-template-columns: repeat(9, 1fr); /* 9 columns */
  gap: 5px;
  background: grey;
  border-radius: 20px;
  padding: 6px;
  max-width: 600px;
}
.colorBtn {
  border-radius: 50%;
  width: 100%; /* Fill the width of the grid cell */
  aspect-ratio: 1; /* Keep buttons square (1:1 ratio) */
  border: none;
  box-sizing: border-box;
  max-width: 60px;
}

.colorBtn.active {
  border: 2px solid black;
}

#drawBtn.active,
#eraserBtn.active,
#fillBtn.active,
.brushSizeBtn.active {
  background-color: #eb5497;
}

.brushPreview {
  display: block;
  width: 70%;
  background: #000;
  border-radius: 2px;
}

#brush-controls {
  display: flex;
  justify-content: center;
  width:100%;
}

#color-controls div {
  padding: 5px;
}

#top-pane{
  display: flex;
  justify-content: space-between;
  padding: 5px 10px;
  width:100%;
}

#clear-undo-controls {
  display: flex;
  justify-content: space-between;
}

#clearBtn,
#undoBtn, #redoBtn {
  margin: 1px;
  border-radius: 50%;
  border-width: 2px;
  width: fit-content;
  height:fit-content;
}

#clearBtn {
  padding:px 5px 3px 5px;
}
#undoBtn {
}

#save-button-container {
  display: flex;
  justify-content: space-between;
  width: 100%;
}

#saveBtn,
#cancelBtn,
#saveBtn-mob,
#cancelBtn-mob {
  border: 2px solid white;
  background: transparent;
  width: 71px;
  color:#71bbe9;
}

#saveBtn,
#cancelBtn{
    margin-bottom:20px;
}

#colorHistory {
  display: flex;
  gap: 5px;
}


@media screen and (max-width: 578px) {

  #fixedPalette {
  grid-template-columns: repeat(7, 1fr);
  }
}

@media screen and (max-width: 990px) {

    .mobile-button {
    display: initial;
  }
  .desktop-button {
    display: none;
  }
  
}