.topbar {

    display: flex;

    justify-content: center;

    align-items: center;

    width: 100%;

    margin-left: 0;

    margin-top: -8px;

    padding: 4px 12px;

    background:
        linear-gradient(
            135deg,
            #1e3a8a,
            #2563eb
        );

    color: white;

    position: sticky;

    top: 0;

    z-index: 9999;
}
/* =====================================
   PREMIUM NAV TOOLBAR
===================================== */

.nav-toolbar {

    display: flex;

    align-items: center;

    justify-content: center;

    gap: 14px;

    width: 100%;

    padding: 5px 10px;
}
/* ICON BUTTON */

.nav-icon-btn {

    position: relative;

    background: transparent !important;

    border: none !important;

    color: white;

    font-size: 20px;

    min-width: 34px;

    height: 34px;

    padding: 0 10px;

    border-radius: 12px;

    display: inline-flex;

    align-items: center;

    justify-content: center;

    white-space: nowrap;

    cursor: pointer;

    transition: all 0.22s ease;
}

.nav-icon-btn:hover {

    background:
        rgba(255,255,255,0.16) !important;

    transform: translateY(-1px);
}

/* DIVIDER */

.nav-divider {

    width: 1px;

    height: 24px;

    background:
        rgba(255,255,255,0.18);
}

/* PAGE INFO */

.page-info {

    color: white;

    font-weight: 600;

    font-size: 15px;

    min-width: 72px;

    text-align: center;
}

/* HOVER LABEL */

.nav-icon-btn::after {

    content: attr(data-label);

    position: absolute;

    bottom: -42px;

    left: 50%;

    transform:
        translateX(-50%);

    background: rgba(0,0,0,0.88);

    color: white;

    padding: 6px 10px;

    border-radius: 8px;

    font-size: 12px;

    white-space: nowrap;

    opacity: 0;

    pointer-events: none;

    transition: 0.18s ease;
}

.nav-icon-btn:hover::after {

    opacity: 1;
}

/* SECTIONS */
.nav-left,
.nav-center,
.nav-right {

    display: flex;

    align-items: center;

    gap: 10px;

    flex-wrap: nowrap;
}

/* CENTER ALIGN */
.nav-center {

    justify-content: center;

    flex: 1;
}

/* BUTTONS */
.topbar button {

    background: rgba(255,255,255,0.15);

    color: white;

    border: 1px solid rgba(255,255,255,0.18);

    padding: 8px 14px;

    border-radius: 10px;

    cursor: pointer;

    font-weight: 600;

    transition: all 0.2s ease;

    backdrop-filter: blur(4px);
}

.topbar button:hover {

    background: white;

    color: #1e3a8a;

    transform: translateY(-1px);
}

.page-info {
    font-weight: bold;
}

.viewer-container {

    width: 70vw;

    max-width: 1800px;

    margin: 10px auto;

    padding: 0;
}

.main-view {

    position: relative;

    width: 100%;

    min-height: 300px;

    background:
        linear-gradient(
            180deg,
            #f8fafc,
            #eef2ff
        );

    padding: 2px;

    border-radius: 6px;

    box-shadow:
        0 10px 30px rgba(15,23,42,0.08);

    overflow: hidden;
}

#mainImage {

    width: 100%;

    height: auto;

    display: block;

    transform-origin: center center;

    border-radius: 14px;

    box-shadow:
        0 8px 24px rgba(0,0,0,0.12);

    background: white;

    cursor: grab;

    touch-action: manipulation;

    opacity: 1;

    transition:
        opacity 0.25s ease,
        transform 0.18s cubic-bezier(0.22, 1, 0.36, 1);

    position: relative;

    left: 0;

    top: 0;
}

.viewer-container {
    width: 100%;
}

/* CROP BOX */
#cropBox {
    position:absolute;
    border:2px dashed red;
    background: rgba(255,0,0,0.1);
    display:none;
    cursor:move;
}

/* resize handle */
#cropBox::after {
    content:"";
    position:absolute;
    width:12px;
    height:12px;
    background:red;
    right:-6px;
    bottom:-6px;
    cursor:se-resize;
}

.date-item {
    padding:8px;
    margin:4px 0;
    background:#f2f2f2;
    border-radius:6px;
    cursor:pointer;
    text-align:center;
}

.date-item:hover {
    background:#0d6efd;
    color:white;
}


/* CORNER HANDLES */
.handle {
    position:absolute;
    width:15px;
    height:15px;
    background:white;
    border:2px solid red;
    border-radius:2px;
    z-index:1000;
}

/* corners */
.tl { top:-7px; left:-7px; cursor:nwse-resize; }
.tr { top:-7px; right:-7px; cursor:nesw-resize; }
.bl { bottom:-7px; left:-7px; cursor:nesw-resize; }
.br { bottom:-7px; right:-7px; cursor:nwse-resize; }

/* 📅 CALENDAR BOX */
.calendar-box {
    position: absolute;
    background: white;
    padding: 12px;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.2);
    z-index: 9999;
    width: 260px;

    transform: scale(0.9);
    opacity: 0;
    transition: all 0.2s ease;
}

.calendar-box.show {
    transform: scale(1);
    opacity: 1;
}
/* HEADER */
.cal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    font-weight: bold;
}

/* GRID */
.cal-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 5px;
}

/* DAY CELL */
.cal-day {
    padding: 8px;
    text-align: center;
    border-radius: 6px;
    cursor: pointer;
    transition: 0.2s;
}

/* DISABLED */
.cal-day.disabled {
    background: #eee;
    color: #aaa;
    cursor: not-allowed;
}

/* AVAILABLE */
.cal-day.active {
    background: #0d6efd;
    color: white;
}

/* HOVER */
.cal-day.active:hover {
    transform: scale(1.1);
}

#calendarBtn {
    display: flex;
    align-items: center;
    gap: 6px;
    font-weight: bold;
    white-space: nowrap;   /* 🔥 prevent breaking into next line */
}

/* mobile bigger handles */
@media (max-width:768px){
    .handle {
        width:18px;
        height:18px;
    }
}

/* THUMBNAILS */
/* THUMBNAILS */
.sidebar {

    height: auto;

    min-height: 120px;

    display: flex;

    align-items: center;

    overflow-x: auto;

    gap: 10px;

    padding: 10px 12px;

    background: #cbd5e1;

    margin-top: 10px;

    border-radius: 18px;

    box-shadow:
        inset 0 2px 8px rgba(0,0,0,0.10),
        0 4px 14px rgba(15,23,42,0.08);
}

.thumb {

    width: 120px;

    cursor: pointer;

    margin-right: 4px;

    display: flex;

    align-items: center;

    justify-content: center;
}

.thumb img {

    width: 100%;

    border-radius: 10px;

    transition: all 0.2s ease;

    box-shadow:
        0 2px 10px rgba(0,0,0,0.08);
}

.thumb.active img {

    border: 3px solid #2563eb;

    transform: scale(1.04);

    box-shadow:
        0 8px 20px rgba(37,99,235,0.25);
}

/* SHARE PANEL */
#cropShareBar {
    position:absolute;
    display:none;
    flex-direction:column;
    gap:6px;
    background:rgba(0,0,0,0.6);
    padding:8px;
    border-radius:10px;
    backdrop-filter: blur(6px);
    z-index:99999;
}

/* BUTTON */
.share-btn {
    width:28px;
    height:28px;
    border-radius:8px;
    border:none;
    cursor:pointer;
    background:white;
    display:flex;
    align-items:center;
    justify-content:center;
}

.share-btn img {
    width:15px;
    height:15px;
}


/* 📱 MOBILE BIGGER BUTTONS */
@media (max-width: 768px) {
    /* 📱 HIDE PAGE NAV IN MOBILE */

    html,
    body {
        overflow-x: hidden;
    }

    #navPrevBtn,
    #navNextBtn,
    .page-info {

        display: none;
    }
    .share-btn {
        width:28px;
        height:28px;
        border-radius:8px;
    }

    .share-btn img {
        width:15px;
        height:15px;
    }
}

/* 📱 MOBILE NAVBAR FIX */
@media (max-width: 768px) {

    .topbar {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
        padding: 8px;
    }

    .nav-left,
    .nav-center,
    .nav-right {
        display: flex;

        align-items: center;

        justify-content: center;

        gap: 8px;

        flex-wrap: nowrap;

        overflow-x: auto;
    }

    .topbar button {

        flex: 0 0 auto;

        font-size: 13px;

        padding: 6px 10px;

        white-space: nowrap;
    }

    .page-info {
        font-size: 13px;
    }
}

@media (max-width: 768px) {

    .sidebar {

        min-height: 140px;

        padding: 6px 8px;

        gap: 8px;

        align-items: center;

        background: #cbd5e1;
    }

    .thumb {

        width: 20vw;

        flex-shrink: 0;

        margin-right: 4px;

        display: flex;

        align-items: center;

        justify-content: center;
    }

    .thumb img {

        width: 100%;

        height: auto;

        border-radius: 8px;
    }
}


/* 📱 MOBILE CLEAN MENU */
.mobile-menu-btn {
    display: none;
}

.floating-crop-btn {
    display: none;
}

/* 💻 PREMIUM CENTER TOOLBAR */
.mobile-menu {

    display: flex;

    justify-content: center;

    width: 100%;
}

@media (max-width: 768px) {
    /* 📱 FIXED BOTTOM TOOLBAR */
    .mobile-menu {

        position: fixed !important;

        left: 0;

        right: 0;

        bottom: 0;

        z-index: 2147483647;

        width: 100%;

        max-width: 100vw;

        overflow-x: hidden;

        flex: none !important;

        box-sizing: border-box;
    }


    /* 📱 MOBILE PREMIUM TOOLBAR */

    .nav-toolbar {

        display: flex;

        align-items: center;

        justify-content: center;

        gap: 6px;

        padding: 8px 12px;

        border-radius: 0px;

        background:
            rgba(0,0,0,0.72);

        backdrop-filter: blur(12px);

        box-shadow:
            0 4px 18px rgba(0,0,0,0.28);

        width: 100%;

        box-sizing: border-box;

        flex-wrap: nowrap;

        overflow-x: auto;

        max-width: 100vw;

        -webkit-overflow-scrolling: touch;
    }

    /* 📱 MOBILE ICONS */

    .nav-icon-btn {

        width: 32px;

        height: 32px;

        font-size: 16px;
    }

    /* 📱 MOBILE LABEL HIDE */

    .nav-icon-btn::after {

        display: none;
    }


    /* 🔥 FLOATING CROP BUTTON */
    .floating-crop-btn {
        display: block;
        position: fixed !important;
        left: max(16px, env(safe-area-inset-left));

        bottom: max(90px, env(safe-area-inset-bottom));

        z-index: 2147483647;

        background: #0d6efd;
        color: white;
        border: none;
        border-radius: 999px;
        padding: 14px 18px;

        font-weight: bold;
        box-shadow: 0 4px 12px rgba(0,0,0,0.3);
        pointer-events: auto;

        transform: translate3d(0,0,0);

        will-change: transform;

        backface-visibility: hidden;
    }
    /* 🔥 HIDE DESKTOP CROP BUTTON IN MOBILE */
    .desktop-crop-btn {
        display: none;
    }
    .viewer-container {
        padding: 0;
    }

    .main-view {
        padding: 0;
    }

    #mainImage {
        width: 100%;
    }
}

/* 🌙 DARK MODE BUTTON SPACING */
.dark-toggle-btn {
    margin-left: 10px;
}

/* ⚡ PAGE LOADING EFFECT */
.image-loading {
    opacity: 0.75;
}


/* ⚡ SMOOTH E-PAPER PAGE SLIDE */

.page-swipe-left {
    animation: pageSlideLeft 0.38s cubic-bezier(0.22, 0.61, 0.36, 1);
}

.page-swipe-right {
    animation: pageSlideRight 0.38s cubic-bezier(0.22, 0.61, 0.36, 1);
}


/* NEXT PAGE
   Current page moves in from the right */

@keyframes pageSlideLeft {

    from {
        transform: translateX(90px);
        opacity: 0.75;
    }

    to {
        transform: translateX(0);
        opacity: 1;
    }
}


/* PREVIOUS PAGE
   Current page moves in from the left */

@keyframes pageSlideRight {

    from {
        transform: translateX(-90px);
        opacity: 0.75;
    }

    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* -------------------------
   ARTICLE REGION
------------------------- */

.article-hotspot {

    position: absolute;

    border: 2px solid transparent;

    background: rgba(0,255,136,0.01);

    pointer-events: auto;

    cursor: pointer;

    transition: 0.2s;
}

.article-hotspot:hover {

    border-color: #00ff88;

    background: rgba(0,255,136,0.18);

    box-shadow: 0 0 12px rgba(0,255,136,0.5);
}

/* -------------------------
   ARTICLE POPUP
------------------------- */

#articlePopup {

    position: fixed;

    left: 0;
    top: 0;

    width: 100%;
    height: 100%;

    display: none;

    z-index: 9999;
}


/* DARK BACKGROUND */

#popupOverlay {

    position: absolute;

    width: 100%;
    height: 100%;

    background: rgba(0,0,0,0.82);

    backdrop-filter: blur(3px);
}


/* CONTENT */
#popupContent {

    position: absolute;

    left: 50%;
    top: 50%;

    transform:
        translate(-50%, -50%);

    width: 75vw;

    max-width: 1200px;

    height: 85vh;

    background: white;

    border-radius: 18px;

    overflow: hidden;

    z-index: 2;

    display: flex;

    align-items: center;

    justify-content: center;

    transition: 0.25s ease;
}

/* VIEWPORT */

#popupImageViewport {

    width: 100%;

    height: 100%;

    overflow: auto;

    display: flex;

    align-items: center;

    justify-content: flex-start;

    background: #111;

    padding: 20px;
}

/* FULLSCREEN ZOOM MODE */
#popupContent.zoomed {

    position: fixed;

    left: 0;
    top: 0;

    transform: none;

    width: 100vw;

    max-width: none;

    height: 100vh;

    border-radius: 0;
}

/* IMAGE */

#popupArticleImage {

    max-width: 100%;

    max-height: 100%;

    width: auto;

    height: auto;

    border-radius: 10px;

    object-fit: contain;
}

/* IMAGE IN ZOOM MODE */

#popupContent.zoomed
#popupArticleImage {

    max-width: none;

    max-height: 95vh;

    width: auto;

    height: auto;

    object-fit: contain;
}

/* CLOSE BUTTON */

#closePopupBtn {

    position: fixed;

    top: 20px;
    right: 20px;

    width: 48px;
    height: 48px;

    border: none;

    border-radius: 50%;

    background: rgba(255,255,255,0.95);

    color: black;

    cursor: pointer;

    font-size: 22px;

    font-weight: bold;

    z-index: 99999;

    box-shadow:
        0 4px 14px rgba(0,0,0,0.25);
}


/* ZOOM BUTTON */
#zoomToggleBtn {

    position: fixed;

    top: 20px;
    right: 80px;

    width: 48px;
    height: 48px;

    border: none;

    border-radius: 50%;

    background: rgba(0,0,0,0.72);

    color: white;

    font-size: 18px;

    cursor: pointer;

    z-index: 99999;

    box-shadow:
        0 4px 14px rgba(0,0,0,0.35);

    opacity: 1;

    transition: 0.2s;
}


.subscription-test-box {

    background: #dc2626;

    color: white;

    padding: 14px;

    text-align: center;

    font-size: 18px;

    font-weight: bold;
}

/* 🔒 ARCHIVE LOCK */

.archive-lock-box {

    background: white;

    margin: 30px auto;

    padding: 30px;

    max-width: 500px;

    border-radius: 16px;

    text-align: center;

    box-shadow:
        0 4px 20px rgba(0,0,0,0.15);
}

.archive-lock-box h2 {

    margin-bottom: 15px;

    color: #dc2626;
}

.archive-lock-box p {

    margin-bottom: 20px;

    font-size: 16px;
}

.archive-login-btn {

    display: inline-block;

    padding: 10px 20px;

    background: #2563eb;

    color: white;

    text-decoration: none;

    border-radius: 10px;

    font-weight: bold;
}

.archive-login-btn:hover {

    background: #1d4ed8;
}

/* =====================================
   IMAGE SIDE NAVIGATION
===================================== */

.image-nav-btn {

    position: fixed;

    top: 50%;

    transform: translateY(-50%);

    z-index: 99999;

    width: 54px;

    height: 54px;

    border: none;

    border-radius: 50%;

    background: rgba(0,0,0,0.55);

    color: white;

    font-size: 32px;

    cursor: pointer;

    display: flex;

    align-items: center;

    justify-content: center;

    transition: all 0.2s ease;
}

/* HOVER */

.image-nav-btn:hover {

    opacity: 1;

    transform:
        translateY(-50%)
        scale(1.08);

    background:
        rgba(37,99,235,0.88);
}

/* LEFT */

.image-prev-btn {

    left: max(20px, calc((100vw - 70vw) / 2 - 50px));
}

/* RIGHT */

.image-next-btn {

    right: max(20px, calc((100vw - 70vw) / 2 - 50px));
}

/* HIDE BUTTON */

.image-nav-btn.hidden {

    display: none;
}

/* MOBILE */

@media (max-width: 768px) {

    .image-nav-btn {

        display: none;
    }
}


html,
body {
    overflow-x: hidden;
}

/* ==========================================
   EDITION DROPDOWN
========================================== */
/* =====================================
   PREMIUM EDITION DROPDOWN
===================================== */

.edition-dropdown {

    position: absolute;

    display: none;

    width: 340px;

    max-width: 90vw;

    max-height: 70vh;

    overflow-y: auto;

    background: #ffffff;

    border-radius: 14px;

    box-shadow:
        0 14px 40px rgba(0,0,0,.22);

    border: 1px solid #dbe3ef;

    padding: 14px;

    z-index: 99999;
}

/* =====================================
   SECTION
===================================== */

.edition-section{

    margin-bottom:4px;

}

.edition-section:last-child{

    margin-bottom:0;

}

/* =====================================
   SECTION HEADER
===================================== */

.edition-section-header{

    display:flex;

    align-items:center;

    gap:8px;

    padding:6px 10px;

    background:#f8fafc;

    border-radius:10px;

    cursor:pointer;

    font-size:13px;

    font-weight:600;

    color:#1e3a8a;

    transition:.20s;

    user-select:none;

}

.edition-section-header:hover{

    background:#eaf2ff;

}

.edition-arrow{

    width:18px;

    text-align:center;

    transition:.25s;

}

/* =====================================
   GRID
===================================== */

.edition-grid{

    display:none;

    grid-template-columns:
        repeat(2,minmax(0,1fr));

    gap:3px;

    padding:4px 2px;
}



/* ==========================================
   EDITION MENU
========================================== */

.edition-group{

    margin-bottom:16px;
}

.edition-group:last-child{

    margin-bottom:0;
}

.edition-group-title{

    font-size:14px;

    font-weight:700;

    color:#1e3a8a;

    padding:8px 10px;

    margin-bottom:6px;

    border-bottom:1px solid #dbe3ef;
}

.edition-item{

    display:flex;

    align-items:center;

    justify-content:flex-start;

    min-height:26px;

    padding:4px 6px;

    border-radius:6px;

    text-decoration:none;

    background:#f8fafc;

    color:#374151;

    transition:.20s;

    text-align:left;

    font-size:13px;

    white-space:nowrap;

}

.edition-item:hover{

    background:#2563eb;

    color:white;

}

.edition-item.active{

    background:#2563eb;

    color:white;

    font-weight:700;

}

/* =====================================
   EDITION BUTTON
===================================== */

.edition-menu-btn {

    background: rgba(255,255,255,0.15);

    color: white;

    border: 1px solid rgba(255,255,255,0.18);

    padding: 8px 16px;

    border-radius: 10px;

    font-weight: 600;

    font-size: 14px;

    cursor: pointer;

    white-space: nowrap;

    transition: all 0.22s ease;

    backdrop-filter: blur(6px);
}

.edition-menu-btn:hover {

    background: white;

    color: #1e3a8a;

    transform: translateY(-1px);
}

@media (max-width:768px){

    /* Hide desktop edition button on mobile */

    #editionMenuBtn{

        display:none;

    }

    .edition-dropdown{

        width:95%;

        left:2.5%!important;

    }

    .edition-grid{

        grid-template-columns:1fr;

    }

}

/* ==========================================
   MOBILE FLOATING EDITION BUTTON
========================================== */

.mobile-edition-toggle{

    display:none;

}

@media (max-width:768px){

    .mobile-edition-toggle{

        display:flex;

        align-items:center;

        justify-content:center;

        position:fixed;

        top:12px;

        left:12px;

        width:40px;

        height:40px;

        border:none;

        border-radius:8px;

        background:transparent;

        color:#ffffff;

        font-size:28px;

        font-weight:700;

        cursor:pointer;

        z-index:10001;

    }

}

/* ===============================
   MOBILE EDITION BUTTON
================================ */

.mobile-edition-fab{

    display:none;

}

@media (max-width:768px){

    .mobile-edition-fab{

        display:flex;

        align-items:center;

        justify-content:center;

        position:fixed;

        top:12px;

        left:12px;

        width:42px;

        height:42px;

        border:none;

        border-radius:50%;

        background:#ffffff;

        color:#222;

        font-size:24px;

        cursor:pointer;

        box-shadow:0 3px 10px rgba(0,0,0,.20);

        z-index:999999;

    }

}

/* ==========================================
   MOBILE EDITION PANEL
========================================== */

@media (max-width:768px){

    .edition-dropdown{

        left:8px !important;

        width: 220px !important;

        top:30px !important;

        padding:8px;

        border-radius:6px;

    }

    .edition-section{

        margin-bottom:2px;

    }

    .edition-section-header{

        padding:8px 10px;

        font-size:14px;

        border-radius:8px;

    }

    .edition-grid{

        grid-template-columns:1fr;

        gap:1px;

        padding:2px 0;

    }

    .edition-item{

        min-height:22px;

        padding:2px 5px;

        font-size:13px;

        line-height:1.2;

        border-radius:2px;

        margin:0;

    }

}

/* ==========================================
   🔥 E-PAPER PAGE LOADING SCREEN
   ========================================== */

#pageLoadingOverlay {

    position: absolute;

    left: 0;
    right: 0;
    top: 0;
    bottom: 0;

    width: auto;
    height: auto;

    display: none;

    align-items: center;
    justify-content: center;

    flex-direction: column;

    background: #ffffff;

    z-index: 50;

    border-radius: 14px;
}


/* LOADING TEXT */

#pageLoadingOverlay .loading-text {

    font-size: 18px;

    font-weight: 600;

    color: #555;

    margin-bottom: 14px;

}


/* LOADING CIRCLE */

#pageLoadingOverlay .loading-spinner {

    width: 32px;
    height: 32px;

    border: 4px solid #ddd;

    border-top-color: #555;

    border-radius: 50%;

    animation:
        pageLoadingSpin 0.8s linear infinite;
}


/* SPINNER ANIMATION */

@keyframes pageLoadingSpin {

    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }

}


/* ==========================================
   MOBILE
   ========================================== */

@media (max-width: 768px) {

    #pageLoadingOverlay .loading-text {

        font-size: 16px;

    }

    #pageLoadingOverlay .loading-spinner {

        width: 28px;
        height: 28px;

        border-width: 3px;

    }

}

/* =========================================
   📱 COMMON HEADER MENU
   Hide old floating edition button
========================================= */

#mobileEditionBtn {
    display: none !important;
}


/* =========================================
   📱 VIEWER SIDE MENU
   ========================================= */

.viewer-mobile-menu {
    display: none;
}

@media (max-width: 768px) {

    .viewer-mobile-menu {
        position: fixed;

        top: 0;
        left: 0;

        width: 240px;
        max-width: 85vw;
        height: 100vh;

        background: #ffffff;

        z-index: 2147483646;

        overflow-y: auto;

        box-sizing: border-box;

        box-shadow: 4px 0 18px rgba(0, 0, 0, 0.18);
    }

    .viewer-mobile-menu-header {
        position: sticky;

        top: 0;

        display: flex;
        align-items: center;
        justify-content: space-between;

        height: 56px;

        padding: 0 16px;

        background: #ffffff;

        border-bottom: 1px solid #e5e7eb;

        box-sizing: border-box;

        font-size: 18px;
        font-weight: 700;

        color: #111827;
    }

    .viewer-mobile-menu-header button {
        width: 40px;
        height: 40px;

        border: none;
        background: none;

        font-size: 22px;

        color: #111827;

        cursor: pointer;
    }

    .viewer-mobile-menu-list {
        width: 100%;
    }

    .viewer-mobile-menu-item {
        width: 100%;

        min-height: 52px;

        padding: 0 18px;

        display: flex;
        align-items: center;

        gap: 14px;

        border: none;
        border-bottom: 1px solid #e5e7eb;

        background: #ffffff;

        color: #111827;

        font-size: 15px;
        font-weight: 600;

        text-align: left;

        cursor: pointer;
    }

    .viewer-mobile-menu-item span:first-child {
        width: 24px;

        text-align: center;

        font-size: 18px;
    }

    .viewer-mobile-menu-item:active {
        background: #f3f4f6;
    }

}

/* =========================================
   📱 VIEWER SECTIONS → EDITIONS MENU
   ========================================= */

@media (max-width: 768px) {

    .viewer-mobile-section {
        width: 100%;
        border-bottom: 1px solid #e5e7eb;
    }

    .viewer-mobile-section-btn {
        width: 100%;
        min-height: 52px;
        padding: 0 16px;

        display: flex;
        align-items: center;
        justify-content: space-between;

        border: none;
        background: #ffffff;
        color: #111827;

        font-size: 15px;
        font-weight: 700;
        text-align: left;

        cursor: pointer;
        box-sizing: border-box;
    }

    .viewer-mobile-section-btn:active {
        background: #f3f4f6;
    }

    .viewer-mobile-arrow {
        font-size: 24px;
        font-weight: 400;
        line-height: 1;

        transition: transform 0.2s ease;
    }

    .viewer-mobile-section-btn.active .viewer-mobile-arrow {
        transform: rotate(90deg);
    }

    .viewer-mobile-editions {
        display: none;
        width: 100%;
        background: #f8fafc;
    }

    .viewer-mobile-editions a {
        display: block;

        width: 100%;
        min-height: 46px;

        padding: 12px 16px 12px 38px;

        box-sizing: border-box;

        color: #374151;
        background: #f8fafc;

        border-top: 1px solid #e5e7eb;

        font-size: 14px;
        font-weight: 500;

        text-decoration: none;
    }

    .viewer-mobile-editions a:active {
        background: #e5e7eb;
    }

}

/* =========================================
   🔢 THUMBNAIL PAGE NUMBER
   ========================================= */

.thumb {
    position: relative;
}

.thumbnail-page-number {
    position: absolute;

    left: 50%;
    top: 50%;

    transform: translate(-50%, -50%);

    width: 32px;
    height: 32px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 50%;

    background: rgba(255, 255, 255, 0.82);

    color: #111827;

    font-size: 14px;
    font-weight: 700;

    line-height: 1;

    pointer-events: none;

    box-sizing: border-box;

    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.18);
}

