.rb-books,
.rb-books * {
    box-sizing: border-box;
}

.rb-books {
    width: 100%;
    font-family: inherit;
    color: #1d1d1d;
}

.rb-books__cards {
    display: grid;
    grid-template-columns: minmax(0, 1.72fr) minmax(260px, 1fr);
    gap: 18px;
    align-items: stretch;
}

.rb-current,
.rb-archive {
    border: 1px solid rgba(87, 87, 87, .44);
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 5px 16px rgba(0, 0, 0, .07);
}

.rb-current {
    display: flex;
    align-items: stretch;
    justify-content: space-between;
    overflow: hidden;
    padding: 14px 6px 14px 20px;
}

.rb-current__content {
    min-width: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding-right: 18px;
}

.rb-current__actions {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 12px;
}

.rb-badge {
    display: inline-flex;
    align-items: center;
    padding: 6px 18px;
    border-radius: 999px;
    min-height: 34px;
    background: linear-gradient(135deg, #2868d9, #2d8def);
    color: #fff;
    font-size: 14px;
    font-weight: 300;
    line-height: 1;
    white-space: nowrap;
}

.rb-download {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    min-height: 34px;
    padding: 5px 16px 5px 18px;
    border: 1.5px solid #252525;
    border-radius: 999px;
    background: #fff;
    color: #202020 !important;
    font-size: 16px;
    line-height: 1;
    text-decoration: none !important;
    transition: background-color .18s ease, transform .18s ease, box-shadow .18s ease;
}

.rb-download:hover,
.rb-download:focus {
    background: #f5f8ff;
    color: #111 !important;
    text-decoration: none !important;
    box-shadow: 0 3px 10px rgba(0, 0, 0, .08);
    transform: translateY(-1px);
}

.rb-download__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    line-height: 1;
}

.rb-current__title {
    max-width: 680px;
    color: #202020;
    font-size: 18px;
    font-weight: 500;
    line-height: 1.2;
    text-transform: uppercase;
}

.rb-current__subtitle {
    margin-top: 6px;
    color: #a1a1a1;
    font-size: 14px;
    line-height: 1.25;
}

.rb-current__cover-wrap {
    flex: 0 0 108px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.rb-current__cover {
    display: block;
    max-width: 86px;
    max-height: 108px;
    width: auto;
    height: auto;
    object-fit: contain;
}

.rb-archive {
    width: 100%;
    padding: 18px 20px 18px 26px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    text-align: left;
    font: inherit;
    color: #1d1d1d;
}

button.rb-archive {
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}

button.rb-archive:hover,
button.rb-archive:focus {
    transform: translateY(-1px);
    border-color: rgba(37, 103, 217, .5);
    box-shadow: 0 7px 20px rgba(0, 0, 0, .09);
    outline: none;
}

.rb-archive__copy {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.rb-archive__title {
    font-size: 18px;
    font-weight: 500;
    line-height: 1.15;
    text-transform: uppercase;
}

.rb-archive__range {
    margin-top: 5px;
    font-size: 14px;
    line-height: 1.15;
}

.rb-archive__subtitle {
    margin-top: 9px;
    color: #a1a1a1;
    font-size: 12px;
    line-height: 1.15;
}

.rb-archive__arrow {
    flex: 0 0 52px;
    width: 52px;
    height: 52px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: #f1f1f1;
    color: #111;
    font-size: 34px;
    font-weight: 300;
    line-height: 1;
}

.rb-archive--empty {
    cursor: default;
}

.rb-modal {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 24px;
}

.rb-modal.is-open {
    display: flex;
}

.rb-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(21, 30, 45, .52);
}

.rb-modal__dialog {
    position: relative;
    z-index: 1;
    width: min(560px, 100%);
    max-height: calc(100vh - 48px);
    overflow: auto;
    border-radius: 18px;
    background: #fff;
    padding: 28px;
    box-shadow: 0 24px 70px rgba(0, 0, 0, .25);
}

.rb-modal__close {
    position: absolute;
    top: 13px;
    right: 15px;
    width: 38px;
    height: 38px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: #f1f1f1;
    color: #333;
    cursor: pointer;
    font-size: 28px;
    line-height: 38px;
}

.rb-modal__heading {
    padding-right: 44px;
    font-size: 28px;
    font-weight: 600;
    line-height: 1.15;
}

.rb-modal__note {
    margin-top: 7px;
    color: #858585;
    font-size: 15px;
}

.rb-modal__list {
    margin-top: 22px;
    border-top: 1px solid #e4e4e4;
}

.rb-modal__list a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 15px 4px;
    border-bottom: 1px solid #e4e4e4;
    color: #222 !important;
    font-size: 17px;
    text-decoration: none !important;
}

.rb-modal__list a:hover,
.rb-modal__list a:focus {
    color: #246ddc !important;
    text-decoration: none !important;
}

.rb-modal__download {
    color: #2774df;
    white-space: nowrap;
}

html.rb-modal-open,
body.rb-modal-open {
    overflow: hidden;
}

@media (max-width: 900px) {
    .rb-books__cards {
        grid-template-columns: minmax(0, 1.5fr) minmax(230px, .9fr);
        gap: 12px;
    }

    .rb-current__title,
    .rb-archive__title {
        font-size: 18px;
    }

    .rb-current__subtitle,
    .rb-archive__subtitle,
    .rb-badge,
    .rb-download {
        font-size: 14px;
    }

    .rb-archive__range {
        font-size: 16px;
    }
}

@media (max-width: 700px) {
    .rb-books__cards {
        grid-template-columns: 1fr;
    }

    .rb-current,
    .rb-archive {
        min-height: 118px;
    }

    .rb-current {
        padding-left: 16px;
    }

    .rb-current__cover-wrap {
        flex-basis: 92px;
    }

    .rb-current__cover {
        max-width: 72px;
        max-height: 96px;
    }

    .rb-archive {
        padding: 16px 18px;
    }
}

@media (max-width: 480px) {
    .rb-current__actions {
        gap: 8px;
    }

    .rb-badge,
    .rb-download {
        min-height: 31px;
        padding-top: 5px;
        padding-bottom: 5px;
    }

    .rb-current__title {
        font-size: 16px;
    }

    .rb-current__subtitle {
        font-size: 13px;
    }

    .rb-current__cover-wrap {
        flex-basis: 76px;
        padding-right: 2px;
    }

    .rb-current__cover {
        max-width: 62px;
        max-height: 84px;
    }

    .rb-archive__arrow {
        flex-basis: 44px;
        width: 44px;
        height: 44px;
        font-size: 28px;
    }

    .rb-modal {
        padding: 14px;
    }

    .rb-modal__dialog {
        padding: 22px 18px;
    }
}
