/* General Styling */
body {
  margin: 0;
  font-family: Arial, sans-serif;
  display: flex;
  height: 100vh;
}

#container {
  display: grid;
  grid-template-columns: 1fr 3fr 1fr;
  height: 100%;
}

/* Left Sidebar: Toolbox */
#left-sidebar {
  background-color: #f3f3f3;
  padding: 10px;
  border-right: 2px solid #ccc;
  overflow-y: auto;
}

#gif-library, #bg-library {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.gif-item, .bg-item {
  width: 60px;
  height: 60px;
  object-fit: contain;
  cursor: grab;
  border: 1px solid #ccc;
  border-radius: 4px;
  padding: 5px;
  background-color: #fff;
}

.expand-toggle {
  cursor: pointer;
  color: blue;
  text-decoration: underline;
  margin-top: 10px;
}

/* Canvas Styling */
#canvas {
  background-color: #eaeaea;
  border: 2px dashed #ccc;
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}

#canvas img, #canvas p, #canvas audio {
  position: absolute;
  cursor: move;
}

#canvas img {
  max-width: 150px;
}

#canvas h3 {
  pointer-events: none;
}

/* Close Button */
button {
  font-family: inherit;
}

button.close-btn {
  position: absolute;
  right: 0;
  top: 0;
  background: red;
  color: white;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  width: 20px;
  height: 20px;
  font-size: 12px;
  text-align: center;
  z-index: 10;
}

/* Toolbar Styling */
#text-toolbar {
  position: fixed;
  background: #fff;
  border: 1px solid #ccc;
  padding: 5px;
  border-radius: 5px;
  display: flex;
  gap: 5px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
  z-index: 1000;
}

/* Template Selector */
#template-selector {
  position: fixed;
  top: 10px;
  left: 10px;
  background: #fff;
  border: 1px solid #ccc;
  padding: 10px;
  border-radius: 5px;
  z-index: 1000;
}

#template-selector label {
  margin-right: 10px;
}

#template-selector select,
#template-selector button {
  margin-right: 5px;
  padding: 5px;
  font-size: 14px;
}
