/* Document popup viewer (assets/pdf-viewer.js). Shared by the public site and
   the admin shell, so it deliberately avoids depending on either stylesheet's
   variables. */

.pdfviewer-overlay {
    position: fixed;
    inset: 0;
    z-index: 2000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 2vh 2vw;
    background: rgba(0, 0, 0, 0.75);
}
.pdfviewer-overlay.show { display: flex; }

.pdfviewer-panel {
    display: flex;
    flex-direction: column;
    width: 100%;
    max-width: 1100px;
    height: 96vh;
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
}

.pdfviewer-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.6rem 0.75rem 0.6rem 1rem;
    background: #1d1c1c;
    color: #fff;
    font-family: Arial, Helvetica, sans-serif;
    font-size: 0.9rem;
}
.pdfviewer-title {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-weight: 600;
}
.pdfviewer-actions {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    flex: 0 0 auto;
}
.pdfviewer-btn {
    display: inline-block;
    padding: 0.25rem 0.6rem;
    border: 1px solid rgba(255, 255, 255, 0.35);
    border-radius: 4px;
    background: transparent;
    color: #fff;
    font: inherit;
    line-height: 1.4;
    text-decoration: none;
    cursor: pointer;
}
.pdfviewer-btn:hover,
.pdfviewer-btn:focus {
    background: #e5007d;
    border-color: #e5007d;
    color: #fff;
    text-decoration: none;
}
.pdfviewer-close {
    font-size: 1.15rem;
    line-height: 1;
    padding: 0.15rem 0.5rem 0.3rem;
}

.pdfviewer-frame {
    flex: 1 1 auto;
    width: 100%;
    border: 0;
    background: #f4f4f4;
}

.pdfviewer-hint {
    flex: 0 0 auto;
    padding: 0.4rem 1rem;
    background: #f4f4f4;
    border-top: 1px solid #e3e3e3;
    color: #666;
    font-family: Arial, Helvetica, sans-serif;
    font-size: 0.78rem;
    text-align: center;
}
.pdfviewer-hint a { color: #e5007d; }

@media (max-width: 576px) {
    .pdfviewer-overlay { padding: 0; }
    .pdfviewer-panel { height: 100vh; border-radius: 0; }
    .pdfviewer-title { display: none; }
}
