.document-thumbnail-list {
    width: {{ thumbnail_width }}px;
    margin: auto;
}

.document-thumbnail-list a.fancybox span.instance-image-widget span.lazyload-spinner-container {
    height: 100% !important;
}

.document-thumbnail-list div.text-center div.fa-4x {
    font-size: 0;
}

#mainContainer .toolbar {
    padding: 0;
    margin: 0;
    border: 0;
}

.pdfjs-fragment-rect {
    position: absolute;
    border: 2px solid #2196F3;
    background-color: rgba(33, 150, 243, 0.1);
    pointer-events: auto;
    cursor: move;
    z-index: 100;
    box-sizing: border-box;
}

/* Persisted fragment comment button (on margin, same as selection) */
.pdfjs-fragment-persisted-button {
  position: absolute;
}

/* Persisted fragment highlights (after reload / multiple fragments) */
.fragment-highlight-persisted {
    border: 2px solid #2196F3;
    background-color: rgba(33, 150, 243, 0.1);
    box-sizing: border-box;
}

@keyframes fragment-highlight-blink-once {
    0% { box-shadow: 0 0 0 0 rgba(33, 150, 243, 0); }
    50% { box-shadow: 0 0 0 3px rgba(33, 150, 243, 0.65); }
    100% { box-shadow: 0 0 0 0 rgba(33, 150, 243, 0); }
}

.fragment-highlight-persisted.fragment-highlight-blink-once {
    animation: fragment-highlight-blink-once 0.6s ease-in-out 1;
}

.pdfjs-fragment-button {
    position: absolute;
    width: 24px;
    height: 24px;
    border-radius: 12px;
    background-color: #2196F3;
    color: white;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    z-index: 101;
    transition: transform 0.2s;
    padding: 0;
    line-height: 1;
}

.pdfjs-fragment-button:hover {
    transform: scale(1.1);
    background-color: #1976D2;
}

.pdfjs-resize-handle {
    position: absolute;
    width: 8px;
    height: 8px;
    background-color: white;
    border: 2px solid #2196F3;
    border-radius: 4px;
    z-index: 102;
}

.pdfjs-resize-handle.nw {
    top: -4px;
    left: -4px;
    cursor: nw-resize;
}

.pdfjs-resize-handle.n {
    top: -4px;
    left: 50%;
    transform: translateX(-50%);
    cursor: n-resize;
}

.pdfjs-resize-handle.ne {
    top: -4px;
    right: -4px;
    cursor: ne-resize;
}

.pdfjs-resize-handle.e {
    right: -4px;
    top: 50%;
    transform: translateY(-50%);
    cursor: e-resize;
}

.pdfjs-resize-handle.se {
    bottom: -4px;
    right: -4px;
    cursor: se-resize;
}

.pdfjs-resize-handle.s {
    bottom: -4px;
    left: 50%;
    transform: translateX(-50%);
    cursor: s-resize;
}

.pdfjs-resize-handle.sw {
    bottom: -4px;
    left: -4px;
    cursor: sw-resize;
}

.pdfjs-resize-handle.w {
    left: -4px;
    top: 50%;
    transform: translateY(-50%);
    cursor: w-resize;
}