#pdf-wrapper {
    margin: 2rem auto 1.5rem;
    max-width: 900px;
    width: 100%;
    padding: 1rem 1.25rem 1.5rem;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 30px;
    border: 1px solid rgba(150, 200, 170, 0.15);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
}

#pdf-toolbar {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.45rem 0.75rem;
    margin-bottom: 0.75rem;
    background: rgba(255, 255, 255, 0.85);
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.7);
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.06);
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

#pdf-toolbar button,
#open-tab,
#download-pdf {
    padding: 0.25rem 0.7rem;
    border-radius: 999px;
    border: 1px solid rgba(150, 200, 170, 0.35);
    background: rgba(255, 255, 255, 0.95);
    cursor: pointer;
    font-size: 0.9rem;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    transition:
        background-color 0.2s ease,
        border-color 0.2s ease,
        color 0.2s ease,
        box-shadow 0.2s ease;
}

#pdf-toolbar button:hover,
#open-tab:hover,
#download-pdf:hover {
    background: #f8fffa;
    border-color: rgb(156, 197, 161);
    color: rgb(46, 46, 46);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06);
}

#zoom-level {
    min-width: 4ch;
    text-align: right;
    font-size: 0.9rem;
    cursor: pointer;
    user-select: none;
    color: black;
    text-decoration: none;
    border-bottom: 3px solid transparent;
    border-radius: 3px;
    transition:
        color 0.2s ease,
        border-bottom-color 0.2s ease;
}

#zoom-level:hover {
    border-bottom-color: rgb(156, 197, 161);
    color: rgb(46, 46, 46);
}

#page-info {
    margin-left: auto;
    font-size: 0.85rem;
    color: #444;
}

#pdf-container {
    margin-top: 0.75rem;
    height: auto;
    overflow: hidden;
    background: #e5f3ea;
    border-radius: 22px;
    padding: 0.75rem;
    position: relative;
}

#pdf-container .page {
    margin: 0 auto;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.08);
    background: #ffffff;
    border-radius: 6px;
}

@media (max-width: 900px) {
    #pdf-wrapper {
        padding: 0.75rem 0.75rem 1rem;
        margin-top: 1.25rem;
    }

    #pdf-toolbar {
        flex-wrap: wrap;
        gap: 0.4rem;
    }

    #page-info {
        margin-left: 0;
        width: 100%;
        text-align: right;
        font-size: 0.8rem;
        opacity: 0.9;
    }
}

@media (max-width: 600px) {
    #pdf-wrapper {
        padding: 0.6rem 0.6rem 0.9rem;
        border-radius: 24px;
    }

    #pdf-toolbar {
        justify-content: center;
        text-align: center;
    }

    #pdf-toolbar button,
    #open-tab,
    #download-pdf {
        font-size: 0.85rem;
        padding: 0.2rem 0.6rem;
    }

    #pdf-container {
        padding: 0.5rem;
    }
}
