canvas {
  background-color: #fbfbfb;
  image-rendering: pixelated;
  border: 2x solid black;
  width: 616px;  /* Stretched width */
  height: 462; /* Stretched height */
  max-width: 100%; /* Don't stretch beyond container */
  max-height: 100%; /* Don't stretch beyond container */
}
canvas.pen1-cursor {
  cursor: url('/assets/pen1.png') 0 0, auto;
}
canvas.pen2-cursor {
  cursor: url('/assets/pen1.png') 0 0, auto;
}
canvas.checker-cursor {
  cursor: url('/assets/checker.png') 0 0, auto;
}
canvas.eraser-cursor {
  cursor: url('/assets/erasercursor.png') 0 0, auto;
}

.timeline-thumbnail.selected {
  outline: 2px solid #ae301f;
  outline-offset: -2px;
}


#tools {
  display: flex;
  justify-content: center; /* centers the group */
  align-items: center;
  gap: 10px; /* spacing between buttons */
  margin-top: 10px;
}

#tools img {
  width: 32px; /* or whatever size looks good */
  height: auto;
  cursor: pointer;
}
#tools1 {
  display: flex;
  justify-content: center; /* centers the group */
  align-items: center;
  gap: 10px;         /* Match height of all buttons */
}

#tools1 img {
  width: 116px; /* or whatever size looks good */
  height: auto;
  cursor: pointer;
}

#filename:focus {
  outline: none;
}

.tool-button {
  height: 32px;         /* Match height of all buttons */
  width: auto;          /* Natural width unless overridden */
  object-fit: contain;  /* Keeps image scaling clean */
  margin: 0 4px;
  vertical-align: middle;
}

  .image-row {
  display: flex;
  justify-content: center; /* centers the group of images */
  gap: 10px; /* optional spacing between images */
}

.image-row img {
  width: 171px;
  height: 128px;
  object-fit: contain; /* keeps aspect ratio cleanly */
}

  #timeline-section {
  margin-top: 20px;
  text-align: center;
}

#timeline-container {
  display: flex;
  overflow-x: auto;
  padding: 10px 0;
}

.timeline-thumbnail {
  width: 114px;   /* Set width to 171px */
  height: 86px;  /* Set height to 128px */
  margin: 0 5px;
  cursor: pointer;
  border: 1px solid #ccc;
}

.button-container {
  display: flex;
  align-items: center;
}

#undoButton,
#redoButton {
  height: 40px;
  width: auto;
  cursor: pointer;
}

#undoButton {
  margin-right: -2px; /* Adjust this value to set the space between the buttons */
}

#filename {
  font-size: 18px;
  text-align: center;
  cursor: pointer;
  margin-bottom: 10px;
}

#filename.editing {
  border: none;
  border-bottom: 2px solid white;
  border-radius: 0;
  outline: none;
}

.pen-red-cursor {
  cursor: url('/assets/redpen.png'), crosshair;
}

.parent {
  display: flex;
  align-items: center;
  width: 100%;
}

.page-counter {
  background-color: #ae301f;
  border-radius: 8px;
  padding: 5px 10px;
  align-items: center;
  margin-left: 75px;
  height: 100%;
  flex-grow: 1;
}

.red-text {
  color: white;
  margin: 0;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  width: 100%;
}

.center-text {
  text-align: center;
  color: white;
  margin: 0;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  width: 100%;
}

content img {
  transition: transform 0.3s ease; /* Smooth transition for scaling */
}

content img:hover {
  transform: scale(1.1); /* Scale image by 5% */
}

.film-header {
  position: relative;
  z-index: 1;
}

.film-header::before,
.film-header::after {
  content: "";
  display: block;
  position: absolute;
  left: 0;
  width: 100%;
  height: 24px; /* Adjust based on your image height */
  background-repeat: repeat-x;
  background-size: auto 100%;
  z-index: -1;
}

.film-header::before {
  top: -16px; /* Push above the header */
  background-image: url('/assets/railtop.png');
  border-top-left-radius: 8px; /* Apply border radius only to the top left */
  border-top-right-radius: 8px; /* Apply border radius only to the top right */
}

.film-header::after {
  bottom: -16px; /* Push below the header */
  background-image: url('/assets/railbottom.png');
  border-bottom-left-radius: 8px; /* Apply border radius only to the bottom left */
  border-bottom-right-radius: 8px; /* Apply border radius only to the bottom right */
}
#filename {
  opacity: 0.8; /* 80% transparent */
}

#filename:hover {
  opacity: 1; /* 100% when hovered */
}
