@import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap");

:root {
    --reader-bg: #101a16;
    --reader-panel: rgba(255, 255, 255, 0.94);
    --reader-text: #17211d;
    --reader-muted: #63736b;
    --reader-line: #d9e1dc;
    --reader-brand: #173f32;
    --reader-brand-hover: #2f6f4e;
    --reader-shadow: 0 -18px 42px rgba(0, 0, 0, 0.18);
    --reader-radius: 8px;
}

* {
    box-sizing: border-box;
}

html {
    overflow: hidden;
}

html,
body {
    width: 100%;
    height: 100%;
    margin: 0;
    background: var(--reader-bg);
    color: var(--reader-text);
    font-family: "Inter", Arial, sans-serif;
    font-size: 16px;
    line-height: 1.55;
}

a {
    color: var(--reader-brand);
    text-decoration-color: rgba(23, 63, 50, 0.35);
    text-underline-offset: 0.18em;
}

a:hover,
a:focus {
    color: var(--reader-brand-hover);
}

#pdf-show {
    width: 100%;
    height: 100vh;
    padding-bottom: 70px;
    background: #202824;
}

#pdf-show embed,
#pdf-show iframe,
#pdf-show object {
    width: 100%;
    height: 100%;
}

#opt-footer {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 10000;
    width: 100%;
    padding: 0.7rem 0;
    background: var(--reader-panel);
    border-top: 1px solid var(--reader-line);
    box-shadow: var(--reader-shadow);
    backdrop-filter: blur(14px);
}

#opt-footer .container {
    max-width: 980px;
}

#opt-footer .btn-group {
    display: inline-flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.45rem;
}

#opt-footer .btn {
    border: 0;
    border-radius: var(--reader-radius) !important;
    background: var(--reader-brand) !important;
    color: #fff !important;
    font-size: 0.92rem;
    font-weight: 800;
    line-height: 1.2;
    padding: 0.68rem 0.9rem;
    box-shadow: 0 10px 24px rgba(23, 63, 50, 0.18);
}

#opt-footer .btn:hover,
#opt-footer .btn:focus {
    background: var(--reader-brand-hover) !important;
    color: #fff !important;
}

.modal-content {
    border: 1px solid var(--reader-line);
    border-radius: var(--reader-radius);
    box-shadow: 0 24px 70px rgba(0, 0, 0, 0.22);
}

.modal-header,
.modal-footer {
    border-color: var(--reader-line);
}

.modal-title {
    color: var(--reader-text);
    font-weight: 800;
}

.modal-body p,
.modal-body li {
    color: var(--reader-muted);
}

.modal-body ul {
    padding-left: 1.1rem;
}

li {
    list-style: none;
}

.img-thumbnail {
    margin: 0 1rem 1rem 0;
    border: 1px solid var(--reader-line);
    border-radius: var(--reader-radius);
    box-shadow: 0 12px 28px rgba(23, 63, 50, 0.12);
}

.lista-capitulos {
    width: 100%;
    max-height: min(48vh, 420px);
    overflow-y: auto;
    overflow-x: hidden;
    padding-right: 0.35rem;
}

.lista-capitulos ol {
    padding-left: 1.2rem;
}

.lista-capitulos ol li {
    margin-bottom: 0.85rem;
    padding-bottom: 0.85rem;
    border-bottom: 1px solid var(--reader-line);
}

.badge-info {
    background: var(--reader-brand-hover);
}

@media (max-width: 767.98px) {
    #pdf-show {
        padding-bottom: 132px;
    }

    #opt-footer .btn-group,
    #opt-footer .btn {
        width: 100%;
    }

    #opt-footer .btn {
        justify-content: center;
    }

    .img-thumbnail.float-left {
        float: none !important;
        display: block;
        margin: 0 auto 1rem;
        width: min(220px, 100%);
    }
}
