.remove-btn {
  position: absolute;
  top: 4px;
  right: 6px;
  background: #c00;
  color: white;
  border: none;
  border-radius: 50%;
  font-size: 1rem;
  cursor: pointer;
  width: 22px;
  height: 22px;
  line-height: 20px;
  padding: 0;
}
.orientation-icon {
  margin-top: 4px;
  font-size: 0.9rem;
  color: #88ccff;
  text-align: center;
}
.page-number {
  position: absolute;
  top: 4px;
  left: 6px;
  background: rgba(0, 0, 0, 0.6);
  color: #fff;
  font-size: 0.75rem;
  padding: 2px 5px;
  border-radius: 4px;
}
.image-to-pdf-page {
  max-width: 900px;
  margin: 2rem auto;
  padding: 0 1rem;
  color: #ddd;
  font-family: 'Segoe UI', sans-serif;
}
.image-to-pdf-page h1 {
  font-size: 2rem;
  margin-bottom: 0.5rem;
}
.image-to-pdf-page h2 {
  font-size: 1.3rem;
  margin-top: 2rem;
  margin-bottom: 0.5rem;
}
.tool-description {
  color: #aaa;
  margin-bottom: 1rem;
}
.upload-section {
  border: 2px dashed #555;
  padding: 1rem;
  border-radius: 8px;
  background-color: #1a1a1a;
  text-align: center;
}
.upload-label {
  display: inline-block;
  margin-bottom: 0.5rem;
  font-weight: bold;
  color: #8fd4ff;
  cursor: pointer;
}
.upload-label i {
  margin-right: 6px;
}
#imageInput {
  display: none;
}
.drop-zone {
  margin-top: 0.5rem;
  padding: 1rem;
  background-color: #222;
  border-radius: 6px;
  color: #ccc;
  font-size: 0.95rem;
  cursor: pointer;
}
.drop-zone:hover {
  background-color: #2c2c2c;
}
.image-preview-section {
  margin-top: 2rem;
}
.image-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding: 0;
  margin-top: 0.5rem;
  list-style: none;
}
.image-list li {
  background: #2a2a2a;
  border: 1px solid #444;
  border-radius: 6px;
  width: 120px;
  padding: 0.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  transition: transform 0.2s ease;
  cursor: grab;
  position: relative;
}
.image-list li.dragging {
  opacity: 0.4;
  transform: scale(1.02);
}
.image-list img {
  max-width: 100%;
  max-height: 100px;
  object-fit: contain;
  border-radius: 4px;
}
.image-list span {
  margin-top: 4px;
  font-size: 0.8rem;
  color: #aaa;
  text-align: center;
  word-break: break-word;
}
.drag-note {
  font-size: 0.85rem;
  color: #888;
  margin-top: 0.5rem;
}
.drag-handle {
  position: absolute;
  top: 4px;
  left: 6px;
  color: #888;
  font-size: 1.2rem;
  pointer-events: none;
}
.drop-placeholder {
  background: rgba(100, 100, 255, 0.08);
  border: 2px dashed #66c;
  border-radius: 6px;
  width: 120px;
  height: 150px;
}
.pdf-settings {
  margin-top: 2rem;
}
.settings-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 1rem;
}
.setting-group {
  display: flex;
  flex-direction: column;
}
.setting-group label {
  font-size: 0.9rem;
  margin-bottom: 0.3rem;
}
.setting-group input[type="number"],
.setting-group select,
.setting-group input[type="text"] {
  background-color: #1e1e1e;
  border: 1px solid #444;
  border-radius: 4px;
  color: #eee;
  padding: 0.4rem;
}
.setting-group input[type="range"] {
  width: 100%;
}
.checkbox-group {
  flex-direction: row;
  align-items: center;
  gap: 0.5rem;
}
.checkbox-group input[type="checkbox"] {
  transform: scale(1.2);
}
.preset-controls {
  display: flex;
  gap: 0.5rem;
  align-items: center;
  margin-top: 1rem;
}
.preset-controls button {
  padding: 0.4rem 0.8rem;
  border: none;
  background-color: #3a3a3a;
  color: #ccc;
  border-radius: 4px;
  cursor: pointer;
}
.preset-controls button:hover {
  background-color: #444;
}
.status-message {
  font-size: 0.85rem;
  color: #888;
}
.status-message.small {
  font-size: 0.75rem;
}
.generate-section {
  margin-top: 2rem;
  text-align: center;
}
.custom-filename {
  margin-bottom: 1rem;
}
.custom-filename input {
  padding: 0.4rem 0.6rem;
  background-color: #1e1e1e;
  color: #eee;
  border: 1px solid #444;
  border-radius: 4px;
  width: 250px;
  max-width: 100%;
}
.btn-primary {
  padding: 0.6rem 1.2rem;
  background-color: #4a90e2;
  color: #fff;
  border: none;
  border-radius: 6px;
  font-size: 1rem;
  cursor: pointer;
}
.btn-primary i {
  margin-right: 6px;
}
.btn-primary:hover {
  background-color: #357ab7;
}
.progress-container {
  margin-top: 1rem;
  background: #333;
  border-radius: 4px;
  overflow: hidden;
  height: 12px;
}
.progress-bar {
  height: 100%;
  background: #4a90e2;
  width: 0%;
  transition: width 0.3s ease;
}
.image-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(10, 10, 10, 0.85);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}
.image-modal.hidden {
  display: none;
}
.image-modal img {
  max-width: 90%;
  max-height: 90%;
  border-radius: 6px;
  box-shadow: 0 0 10px #000;
}
.close-modal {
  position: absolute;
  top: 1rem;
  right: 2rem;
  font-size: 2rem;
  color: #eee;
  cursor: pointer;
}
.tool-section.how-to-use {
  margin-top: 3rem;
  background-color: #1e1e1e;
  padding: 1.5rem;
  border-radius: 8px;
  border: 1px solid #333;
}
.tool-section.how-to-use h2 {
  font-size: 1.2rem;
  margin-bottom: 0.8rem;
}
.tool-section.how-to-use ul {
  padding-left: 1.2rem;
}
.tool-section.how-to-use li {
  margin-bottom: 0.5rem;
  font-size: 0.95rem;
}
.tool-section.how-to-use strong {
  color: #8fd4ff;
}
