/* --- General Body and Container Styles --- */
.pdfword-body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background-color: #f3f4f6;
    color: #1f2937;
    margin: 0;
    padding: 2rem;
    height: 100vh;
    width: 100%;
    display: flex;
    justify-content: center;
}

.pdfword-body .merge-container {
    width: 100%;
    max-width: 900px;
    padding: 2.5rem 3rem;
    text-align: center;
}

/* --- Header Section --- */
.pdfword-body .tool-header h1 {
    font-size: 2.25rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: #5b21b6;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
}

.pdfword-body .tool-header h1 i {
    color: #5b21b6;
    font-size: 2.5rem;
}

.pdfword-body .tool-header p {
    font-size: 1.125rem;
    color: #6b7280;
    margin-bottom: 2rem;
    line-height: 1.5;
}

/* --- Upload Section --- */
.pdfword-body .upload-section {
    border: 3px dashed #e5e7eb;
    border-radius: 1rem;
    padding: 3rem 1.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 2rem;
}

.pdfword-body .upload-section:hover,
.pdfword-body .upload-section.highlight {
    border-color: #5b21b6;
    background-color: #c4b5fd;
}

.pdfword-body .drop-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

.pdfword-body .drop-content .bi-folder-plus {
    font-size: 4rem;
    color: #5b21b6;
    margin-bottom: 0.5rem;
}

.pdfword-body .drop-content p {
    font-size: 1.25rem;
    font-weight: 600;
    color: #4c1d95;
    margin: 0;
}

.pdfword-body .drop-content span {
    font-size: 1rem;
    color: #6b7280;
    font-weight: 500;
}

/* --- File List & Page Preview Styles --- */
#preview-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1.5rem;
    border: 2px solid #e5e7eb;
    border-radius: 1rem;
    padding: 1.5rem;
    background-color: #f9fafb;
    min-height: 150px;
}

.page-preview {
    position: relative;
    border: 2px solid transparent;
    border-radius: 0.5rem;
    overflow: hidden;
    cursor: pointer;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    transition: all 0.2s ease;
    width: 150px;
    background-color: #ffffff;
}

.page-preview:hover {
    transform: translateY(-4px);
    border-color: #5b21b6;
    box-shadow: 0 6px 12px -2px rgba(0, 0, 0, 0.1), 0 3px 6px -1px rgba(0, 0, 0, 0.06);
}

.page-preview img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
}

.drag-handle {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background-color: rgba(0, 0, 0, 0.6);
    color: white;
    padding: 4px 8px;
    font-size: 0.875rem;
    font-weight: 600;
    z-index: 10;
}

.remove-btn {
    position: absolute;
    top: 8px;
    right: 8px;
    background-color: rgba(255, 255, 255, 0.8);
    color: #ef4444;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 0.75rem;
    cursor: pointer;
    border: 1px solid #d1d5db;
    z-index: 10;
}

.remove-btn:hover {
    background-color: #ef4444;
    color: #ffffff;
}


/* --- Job Status & Buttons --- */
.spinner {
    border: 4px solid #e0e7ff;
    border-top: 4px solid #5b21b6;
    border-radius: 50%;
    width: 32px;
    height: 32px;
    animation: spin 1s linear infinite;
    margin: 2rem auto;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}
/* Add these styles to your rotate.css file to ensure consistency */

/* --- Action Buttons --- */
.action-buttons {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  margin-top: 2rem;
}

.btn {
  padding: 1rem 2rem;
  border-radius: 9999px;
  font-size: 1.125rem;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  justify-content: center;
  border: none;
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.05);
}

.btn-convert {
  background-color: #5b21b6;
  color: #ffffff;
}

.btn-download {
  background-color: #10b981;
  color: #ffffff;
}

.btn-download i,
.btn-convert i {
  margin-left: 0.5rem;
}


/* --- Utility Class --- */
.hidden {
    display: none !important;
}

/* --- Responsive Design --- */
@media (max-width: 768px) {
    .pdfword-body .merge-container {
        padding: 2rem 1.5rem;
    }

    .pdfword-body .tool-header h1 {
        font-size: 1.75rem;
    }

    .pdfword-body .tool-header p {
        font-size: 1rem;
    }

    .pdfword-body .btn {
        padding: 0.75rem 1.5rem;
        font-size: 1rem;
    }
}