/* Logos Editorial — JetReader Premium UI */

/* Avoid a white flash while the standalone reader mounts. */
body.jetreader-page.logos-jr-dark-reader,
body.jetreader-page.logos-jr-dark-reader #jetreader-page-app {
    background: #030712 !important;
}

/* Brand palette and card polish inside the public library. */
.logos-jr-premium-ui .jetreader-frontend {
    --jr-p50: #fff5f5;
    --jr-p200: #fecaca;
    --jr-p500: #dc2626;
    --jr-p600: #b91c1c;
    --jr-p700: #991b1b;
}

.logos-jr-premium-ui .jetreader-frontend .jr-card {
    background: #111827 !important;
    border-color: rgba(255,255,255,.10) !important;
    box-shadow: 0 10px 26px rgba(0,0,0,.22) !important;
    overflow: hidden;
}

.logos-jr-premium-ui .jetreader-frontend .jr-card:hover {
    transform: translateY(-2px);
    border-color: rgba(255,255,255,.18) !important;
    box-shadow: 0 16px 34px rgba(0,0,0,.32) !important;
}

/* Books should look like books: preserve the whole cover instead of cropping it. */
.logos-jr-premium-ui .jetreader-frontend .jr-card > div:first-child {
    background: #0b1220 !important;
    aspect-ratio: 2 / 3;
    height: auto !important;
}
.logos-jr-premium-ui .jetreader-frontend .jr-card > div:first-child img {
    object-fit: contain !important;
    background: #0b1220;
}
.logos-jr-premium-ui .jetreader-frontend .jr-card h3 {
    color: #f3f4f6 !important;
}

/* Dark detail modal, consistent with the Streamit shell. */
.logos-jr-premium-ui .jetreader-frontend .jr-info-modal {
    --jr-modal-bg: #111827;
    --jr-modal-title: #f9fafb;
    --jr-modal-text: #e5e7eb;
    --jr-modal-meta: #9ca3af;
    --jr-modal-desc: #d1d5db;
    --jr-modal-divider: #374151;
    --jr-modal-badge-bg: #1f2937;
    border: 1px solid rgba(255,255,255,.10);
}

/* Reader: small premium refinements without replacing JetReader's native UI. */
.logos-jr-premium-ui .jetreader-modal-root {
    --logos-jr-accent: #dc2626;
}
.logos-jr-premium-ui .jetreader-modal-root .jr-reader-toolbar-grid,
.logos-jr-premium-ui .jetreader-modal-root .jr-mobile-toolbar {
    backdrop-filter: blur(10px);
}

/* JetReader 1.1.1 already has native zoom. Make it unmistakable/touch friendly. */
.logos-jr-zoom-enhanced .jetreader-modal-root .jr-btn-zoom-in,
.logos-jr-zoom-enhanced .jetreader-modal-root .jr-btn-zoom-out {
    width: 34px !important;
    height: 34px !important;
    min-width: 34px !important;
    font-size: 20px !important;
    line-height: 1 !important;
    border-radius: 8px !important;
}
.logos-jr-zoom-enhanced .jetreader-modal-root .jr-btn-zoom-fit {
    min-height: 34px !important;
    border-radius: 8px !important;
}

/* Slightly more readable toolbar targets on mobile. */
@media (max-width: 639px) {
    .logos-jr-premium-ui .jetreader-modal-root .jr-mobile-toolbar {
        padding-left: 8px !important;
        padding-right: 8px !important;
        gap: 4px !important;
    }
    .logos-jr-zoom-enhanced .jetreader-modal-root .jr-btn-zoom-in,
    .logos-jr-zoom-enhanced .jetreader-modal-root .jr-btn-zoom-out {
        width: 32px !important;
        height: 32px !important;
        min-width: 32px !important;
    }
}

/* Visible but discreet membership cue for visitors without access. */
.logos-jr-premium-ui .jetreader-frontend .logos-jr-locked {
    position: relative;
}
.logos-jr-premium-ui .jetreader-frontend .logos-jr-locked::before {
    content: "🔒";
    font-size: 11px;
    margin-right: 4px;
}
