.dropzone-container {
    border: 2px dashed #cbd5e1;
    border-radius: 12px;
    padding: 45px 20px;
    text-align: center;
    background-color: #f8fafc;
    cursor: pointer;
    transition: all 0.2s ease;
}
.dropzone-container:hover, .dropzone-container.dragover {
    border-color: #3b82f6 !important;
    background-color: #eff6ff !important;
}
.dropzone-icon {
    font-size: 40px;
    margin-bottom: 12px;
    display: inline-block;
    color: #2563eb;
    line-height: 1;
}

/* Keep merge controls readable and usable on smaller screens. */
.pdf-merger-actions {
    align-items: stretch;
}
.pdf-merger-actions .btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-width: 0;
    padding: 10px 16px;
    line-height: 1.25;
    text-align: center;
    white-space: normal;
}
.pdf-merger-actions .btn i {
    flex: 0 0 auto;
}
.pdf-merger-actions #merge-btn {
    min-width: 0;
}
.pdf-merger-actions #clear-btn {
    flex: 0 0 auto;
}

@media (max-width: 767.98px) {
    .pdf-merger-actions {
        flex-direction: column;
        gap: 10px !important;
    }
    .pdf-merger-actions .btn,
    .pdf-merger-actions #merge-btn,
    .pdf-merger-actions #clear-btn {
        width: 100%;
        min-height: 56px;
        height: auto !important;
        flex: 1 1 auto;
        padding: 12px 16px;
    }
}

.pdf-list-container {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    background-color: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 20px;
    min-height: 180px;
}
.pdf-item-card {
    position: relative;
    width: 180px;
    height: 185px;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    background-color: #ffffff;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    overflow: hidden;
    box-shadow: 0 4px 6px -1px rgba(0,0,0,0.05);
    padding-top: 15px;
    cursor: grab;
    user-select: none;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.pdf-item-card:active {
    cursor: grabbing;
}
.pdf-item-card.dragging {
    opacity: 0.5;
    transform: scale(0.95);
    box-shadow: 0 10px 15px -3px rgba(0,0,0,0.1);
}
.pdf-item-icon-wrapper {
    width: 156px;
    height: 100px;
    border-radius: 8px;
    background: #f1f5f9;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 10px;
}
.pdf-item-icon {
    font-size: 32px;
    margin-bottom: 4px;
}
.pdf-item-name {
    font-size: 11px;
    font-weight: 600;
    color: #1e293b;
    text-align: center;
    width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.pdf-item-size {
    font-size: 10px;
    color: #64748b;
    margin-top: 2px;
}
.pdf-item-actions {
    display: flex;
    width: 100%;
    border-top: 1px solid #e2e8f0;
    margin-top: auto;
}
.pdf-item-actions .action-btn {
    flex: 1;
    border: none;
    background: transparent;
    padding: 6px 0;
    font-size: 11px;
    color: #64748b;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}
.pdf-item-actions .action-btn:hover {
    background-color: #f1f5f9;
    color: #1e293b;
}
.pdf-item-actions .remove-btn {
    border-left: 1px solid #e2e8f0;
    border-right: 1px solid #e2e8f0;
    color: #ef4444;
}
.pdf-item-actions .remove-btn:hover {
    background-color: #fef2f2;
    color: #dc2626;
}
.pdf-item-badge {
    position: absolute;
    top: 5px;
    left: 5px;
    background: #2563eb;
    color: #ffffff;
    font-size: 10px;
    font-weight: bold;
    border-radius: 4px;
    padding: 2px 6px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}
