/* Updated style.css with Crazy Vibes */

/* Global Styles */
* {
  box-sizing: border-box;
}

.draw {
  font-family: "Roboto", sans-serif;
  margin: 0;
  height: 100vh;
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 100000;
  position: fixed;
}

.draw button,
input,
select {
  cursor: pointer;
}

.draw.hidden {
  display: none; /* Hide play button when video is playing */
}
.draw.show {
  display: flex;
  /* Hide play button when video is playing */
}

/* Canvas Styling */
canvas {
  border: 4px solid #fff;
  border-radius: 0px;
  box-shadow: 0 0 20px rgba(255, 255, 255, 0.5);
  width: 100vw;
  height: 100vh;
  background: transparent;
  /* cursor: crosshair black; */
  cursor: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAACXBIWXMAAAsTAAALEwEAmpwYAAABZklEQVR4nJWRu0pcQRyHj3hN9AUkqIlgGvMO2y5iJQxn5/vN2e2Ol9rOQhtv+AhiZacEb4koVqYKKRWvhZhGfIIUFhr+MOIB11WnGab4frdJkrefJmAa+AMMv4NLkjzPW6vV6idJZ5IegDtg5M0CwArwy3s/AJwXRIYbgqVSqUXSaAjhm6RbE8my7CtwEUV+vwavxdjdlUplsCgi6VLS1IudgXWDgT5JO8ByUSRN0x4bNqkHS/oOnD7CFlfSoiWxOsBqCKHzGeycawM2DM6yrFfSdoQXgH7gLzBZN7Z7gs+j82aEl+wNXEk6dM51PYPL5XJ77Hli3YCtuPJ8COGLOUs6yPP8Y113STPmXIQlzRks6RrYd859ePHLgGNJE5Jqkv4Bs2mafjZY0l6tVutoBPdJurfb3t77oQK82xCO8SeAG+dccxxrLMb+Yds0hKPAzzjYTex+ZBVedS4IHJqI9378scZ7zn9XedMjzk8QFwAAAABJRU5ErkJggg==")
      16 16,
    crosshair;
  user-select: none !important;
}

/* Toolbox Styling */
.toolbox {
  background: rgba(0, 0, 0, 0.648);
  box-shadow: 0 0 15px rgba(0, 0, 0, 0.5);
  border-radius: 12px;
  display: flex;
  flex-wrap: wrap;
  width: auto;
  max-width: 90vw;
  padding: 0.3rem;
  justify-content: center;
  position: absolute;
  top: 10px;
  z-index: 1;
  gap: 10px;
  animation: bounce 3s ease infinite;
  cursor: grabbing;
  user-select: none !important;
}

/* Add styling for the drag icon */
.drag-icon {
  cursor: grab;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
}

.drag-icon i {
  font-size: 20px;
}

/* When dragging, show the grabbing cursor */
.toolbox.dragging .drag-icon {
  cursor: grabbing;
}

/* Keyframes for bouncing toolbox */
/* @keyframes bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
} */

/* Toolbox Buttons */
.toolbox > * {
  background: linear-gradient(45deg, #ff6f91, #ff9671, #ffc75f, #f9f871);
  background-size: 200% 200%;
  color: #fff;
  border: none;
  font-size: 1.2rem;
  height: 50px;
  width: 50px;
  margin: 0.25rem;
  padding: 0.25rem;
  cursor: pointer black;
  border-radius: 50%;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
  transition: transform 0.3s, background-position 0.5s;
  animation: glowing 3s infinite;
}

/* Button Hover Effects */
.toolbox > *:hover {
  transform: scale(1.2) rotate(10deg);
  background-position: 100% 0%;
}

/* Glowing animation for buttons */
/* @keyframes glowing {
  0% { box-shadow: 0 0 5px #ff6f91, 0 0 15px #ff9671; }
  50% { box-shadow: 0 0 20px #ffc75f, 0 0 30px #f9f871; }
  100% { box-shadow: 0 0 5px #ff6f91, 0 0 15px #ff9671; }
} */

/* Active Eraser Button */
.toolbox #eraser.active {
  border: 2px solid #ff6f91;
  animation: pulse 1.5s infinite;
}

/* Pulse effect for active eraser */
@keyframes pulse {
  0% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.1);
  }
  100% {
    transform: scale(1);
  }
}

/* Brush Shape Dropdown */
#brushShape {
  background-color: #fff;
  color: white;
  border: 2px solid #ff9671;
  border-radius: 5px;
  font-size: 1rem;
  padding: 0.5rem;
  outline: none;
  transition: border-color 0.3s;
}

#brushShape:hover {
  border-color: #ffc75f;
}

/* Size Indicator */
#size {
  -webkit-appearance: none; /* Remove default arrow in WebKit browsers */
  -moz-appearance: none; /* Remove default arrow in Firefox */
  appearance: none; /* Remove default arrow in other browsers */
  background: white; /* Keep the background white */
  display: flex; /* Enable flexbox for centering */
  justify-content: center; /* Center horizontally */
  align-items: center; /* Center vertically */
  padding: 0.5rem 1rem;
  width: auto; /* Automatically adjusts the width based on content */
  border-radius: 10px;
  font-size: 1rem;
  color: #333;
  font-weight: bold;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.2);
  animation: pulse 2s infinite;
  text-align: center; /* Fallback for non-flexbox browsers */
  cursor: pointer;
  box-sizing: border-box; /* Ensures padding doesn't affect width calculation */
}

#color {
  padding: 8px; /* Padding around the input */
}

/* Active Eraser Button */
.toolbox #eraser.active {
  background-color: #fff; /* White background to match the canvas */
  border: 2px solid #f44336; /* Red border for visibility */
  box-shadow: 0 0 10px rgba(255, 255, 255, 0.6); /* Light shadow to give a pad-like effect */
  animation: pulse 1.5s infinite; /* Pulse animation to highlight active state */
}
/* Ensure select element is on top */
select {
  position: relative;
  z-index: 100; /* Ensure select is above the toolbox */
}

/* Toolbox is below select dropdown */
#toolbox {
  position: absolute;
  z-index: 10; /* Toolbox stays below select dropdown */
}
