.book-preview-host {
    clear: both;
    width: 0;
    height: 0;
    overflow: hidden;
}

.book-preview-shell[hidden] {
    display: none !important;
}

.book-preview-shell {
    position: fixed;
    inset: 0;
    z-index: 6000;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100vh;
    height: 100dvh;
    padding: 24px;
    color: #222;
    isolation: isolate;
}

.book-preview-shell.is-opening,
.book-preview-shell.is-closing {
    pointer-events: none;
}

.book-preview-backdrop {
    position: absolute;
    inset: 0;
    display: block;
    width: 100%;
    height: 100%;
    padding: 0;
    border: 0;
    outline: 0;
    background: rgba(0, 0, 0, .66);
    opacity: 1;
    transition: opacity .38s ease-out;
}

.book-preview-dialog {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    width: calc(100% - 16px);
    max-width: 1170px;
    height: min(760px, calc(100vh - 48px));
    height: min(760px, calc(100dvh - 48px));
    min-height: min(600px, calc(100vh - 48px));
    min-height: min(600px, calc(100dvh - 48px));
    margin: 0;
    padding: 20px;
    overflow: hidden;
    border: 0;
    border-radius: 4px;
    background: #f0f0f0;
    box-shadow: 0 24px 70px rgba(0, 0, 0, .42);
    outline: 0 !important;
    opacity: 1;
    transform: translate3d(0, 0, 0) scale(1, 1);
    transform-origin: center;
    transition: opacity .3s ease-out, transform .52s cubic-bezier(.22, .74, .18, 1);
    will-change: opacity, transform;
}

.book-preview-shell.is-opening:not(.is-animating) .book-preview-backdrop,
.book-preview-shell.is-closing.is-animating .book-preview-backdrop {
    opacity: 0;
}

.book-preview-shell.is-opening:not(.is-animating) .book-preview-dialog,
.book-preview-shell.is-closing.is-animating .book-preview-dialog {
    opacity: 0;
    transform: translate3d(var(--book-preview-origin-x, 0), var(--book-preview-origin-y, 34px), 0) scale(var(--book-preview-origin-scale-x, .35), var(--book-preview-origin-scale-y, .35));
}

.book-preview-flight {
    position: fixed;
    z-index: 2;
    display: block;
    max-width: none;
    max-height: none;
    margin: 0;
    padding: 0;
    pointer-events: none;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    object-fit: fill;
    opacity: 1;
    transform: translate3d(0, 0, 0) scale(1, 1);
    transform-origin: left top;
    transition: opacity .3s ease-out, transform .52s cubic-bezier(.22, .74, .18, 1);
    will-change: opacity, transform;
}

.book-preview-shell.is-opening.is-animating .book-preview-flight,
.book-preview-shell.is-closing:not(.is-animating) .book-preview-flight {
    opacity: 0;
    transform: translate3d(var(--book-preview-flight-x, 0), var(--book-preview-flight-y, 0), 0) scale(var(--book-preview-flight-scale-x, 1), var(--book-preview-flight-scale-y, 1));
}

.book-preview-header {
    flex: 0 0 auto;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
    padding: 0 0 18px;
    border-bottom: 1px solid #d2d2d2;
}

.book-preview-heading {
    margin: 0;
    padding: 0;
    color: #222;
    font-family: PlayfairBold, Georgia, serif;
    font-size: 28px;
    line-height: 1.25;
    text-align: left;
    background: none;
}

.book-preview-status {
    margin: 5px 0 0;
    color: #666;
    font-family: Arial, Helvetica, sans-serif;
    font-size: 14px;
    padding: 0;
}

.book-preview-actions {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    gap: 8px;
}

.book-preview-action,
.book-preview-close,
.book-preview-arrow,
.book-preview-thumb,
.book-preview-trigger {
    -webkit-appearance: none;
    appearance: none;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    cursor: pointer;
    font-family: Arial, Helvetica, sans-serif;
}

.book-preview-action {
    min-height: 40px;
    padding: 8px 14px;
    color: #fff;
    background: #222;
    font-size: 14px;
    text-transform: uppercase;
}

.book-preview-action:hover,
.book-preview-action:focus-visible {
    background: #cb3340;
}

.book-preview-action:focus,
.book-preview-close:focus,
.book-preview-arrow:focus,
.book-preview-thumb:focus,
.book-preview-trigger:focus {
    outline: 0 !important;
    box-shadow: none;
}

.book-preview-action:focus-visible,
.book-preview-close:focus-visible,
.book-preview-arrow:focus-visible,
.book-preview-thumb:focus-visible,
.book-preview-trigger:focus-visible {
    outline: 3px solid #cb3340;
    outline-offset: 2px;
}

.book-preview-close {
    width: 40px;
    height: 40px;
    padding: 0;
    color: #777;
    background: #fff;
    font-size: 32px;
    font-weight: 300;
    line-height: 36px;
}

.book-preview-close:hover,
.book-preview-close:focus-visible {
    color: #fff;
    background: #cb3340;
}

.book-preview-stage-wrap {
    position: relative;
    flex: 1 1 520px;
    height: 520px;
    min-height: 0;
}

.book-preview-stage {
    position: relative;
    width: 100%;
    height: 100%;
    min-height: 0;
    padding: 0;
    overflow: hidden;
    border: 0;
    box-shadow: none;
    outline: 0 !important;
}

.book-preview-slide {
    position: absolute;
    inset: 25px 64px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    opacity: 1;
    transform: translateX(0);
    transition: opacity .28s ease, transform .38s cubic-bezier(.22, .61, .36, 1);
    will-change: opacity, transform;
}

.book-preview-slide.is-entering-next {
    opacity: 0;
    transform: translateX(16%);
}

.book-preview-slide.is-entering-prev {
    opacity: 0;
    transform: translateX(-16%);
}

.book-preview-slide.is-leaving-next {
    opacity: 0;
    transform: translateX(-16%);
}

.book-preview-slide.is-leaving-prev {
    opacity: 0;
    transform: translateX(16%);
}

.book-preview-arrow {
    position: absolute;
    top: 50%;
    z-index: 2;
    width: 46px;
    height: 70px;
    margin-top: -35px;
    padding: 0;
    color: #777;
    background: rgba(255, 255, 255, .85);
    font-size: 54px;
    font-weight: 300;
    line-height: 60px;
}

.book-preview-arrow:hover,
.book-preview-arrow:focus-visible {
    color: #fff;
    background: #cb3340;
}

.book-preview-arrow-prev {
    left: 0;
}

.book-preview-arrow-next {
    right: 0;
}

.book-preview-media {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    margin: 0;
}

.book-preview-image,
.book-preview-video {
    display: block;
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
}

.book-preview-video {
    width: 100%;
    max-width: 900px;
    background: #000;
}

.book-preview-info {
    display: grid;
    grid-template-columns: minmax(220px, 36%) minmax(0, 1fr);
    align-items: center;
    gap: 45px;
    width: 100%;
    max-width: 1050px;
    margin: 0 auto;
}

.book-preview-info-cover {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 0;
}

.book-preview-info-image {
    display: block;
    max-width: 100%;
    max-height: 430px;
    width: auto;
    height: auto;
    object-fit: contain;
}

.book-preview-info-copy {
    min-width: 0;
    font-family: Arial, Helvetica, sans-serif;
}

.book-preview-info-title {
    margin: 0 0 12px;
    padding: 0;
    color: #222;
    font-family: PlayfairBold, Georgia, serif;
    font-size: 31px;
    line-height: 1.25;
    text-align: left;
    background: none;
}

.book-preview-author {
    margin: 0 0 22px;
    font-family: Academy, Georgia, serif;
    font-size: 20px;
    font-style: italic;
    padding: 0;
}

.book-preview-author-link {
    color: #cb3340;
    font-family: Arial, Helvetica, sans-serif;
    font-style: normal;
    font-weight: 700;
}

.book-preview-description {
    margin: 0 0 12px;
    font-family: Academy, Georgia, serif;
    font-size: 20px;
    font-style: italic;
    line-height: 1.5;
    padding: 0;
}

.book-preview-book-link {
    margin-top: 10px !important;
}

.book-preview-thumbs {
    display: flex;
    gap: 8px;
    width: 100%;
    padding: 12px 0 4px;
    overflow-x: auto;
    overflow-y: hidden;
    overscroll-behavior-inline: contain;
    scrollbar-color: #888 #ddd;
}

.book-preview-thumb {
    position: relative;
    flex: 0 0 128px;
    width: 128px;
    height: 82px;
    padding: 4px 3px 7px;
    overflow: hidden;
    border: 0;
    background: #ddd;
    opacity: .68;
}

.book-preview-thumb:hover,
.book-preview-thumb:focus-visible,
.book-preview-thumb.is-active {
    background: #fff;
    opacity: 1;
}

.book-preview-thumb.is-active::after {
    position: absolute;
    right: 28%;
    bottom: 0;
    left: 28%;
    height: 3px;
    background: #cb3340;
    content: "";
}

.book-preview-thumb-image {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.book-preview-trigger {
    padding: 0;
    background: transparent;
}

.book-preview-trigger:focus-visible {
    box-shadow: 0 0 0 3px #cb3340;
}

[data-book-preview-programmatic-focus]:focus,
[data-book-preview-programmatic-focus]:focus-visible {
    outline: 0 !important;
    box-shadow: none !important;
}

.book-preview-close[data-book-preview-programmatic-focus]:focus-visible {
    color: #777;
    background: #fff;
}

.book-preview-trigger[aria-expanded="true"] .book-preview-look-inside {
    opacity: 0;
    visibility: hidden;
}

body.book-preview-open .book-preview-card-active .book-preview-look-inside,
body.book-preview-open .book-preview-card-active .pushcorner {
    display: none;
}

body.book-preview-open {
    overflow: hidden;
}

.book-preview-shell.is-fullscreen {
    position: fixed;
    inset: 0;
    z-index: 6000;
    height: 100vh;
    padding: 0;
    overflow: hidden;
}

.book-preview-shell.is-fullscreen .book-preview-dialog,
.book-preview-dialog:fullscreen,
.book-preview-dialog:-webkit-full-screen {
    display: flex;
    flex-direction: column;
    width: 100%;
    max-width: none;
    height: 100%;
    max-height: none;
    min-height: 0;
    padding: 18px;
    overflow: hidden;
    color: #222;
    background: #f0f0f0;
    border-radius: 0;
    box-shadow: none;
    opacity: 1;
    transform: none !important;
}

.book-preview-shell.is-fullscreen .book-preview-stage-wrap,
.book-preview-dialog:fullscreen .book-preview-stage-wrap,
.book-preview-dialog:-webkit-full-screen .book-preview-stage-wrap {
    flex: 1 1 auto;
    min-height: 0;
}

.book-preview-shell.is-fullscreen .book-preview-stage,
.book-preview-dialog:fullscreen .book-preview-stage,
.book-preview-dialog:-webkit-full-screen .book-preview-stage {
    height: 100%;
    min-height: 0;
}

.book-preview-shell.is-fullscreen .book-preview-slide,
.book-preview-dialog:fullscreen .book-preview-slide,
.book-preview-dialog:-webkit-full-screen .book-preview-slide {
    inset: 18px 64px;
}

.book-preview-shell.is-fullscreen .book-preview-media,
.book-preview-dialog:fullscreen .book-preview-media,
.book-preview-dialog:-webkit-full-screen .book-preview-media,
.book-preview-shell.is-fullscreen .book-preview-info,
.book-preview-dialog:fullscreen .book-preview-info,
.book-preview-dialog:-webkit-full-screen .book-preview-info {
    width: 100%;
    height: 100%;
    max-width: none;
}

.book-preview-shell.is-fullscreen .book-preview-image,
.book-preview-dialog:fullscreen .book-preview-image,
.book-preview-dialog:-webkit-full-screen .book-preview-image,
.book-preview-shell.is-fullscreen .book-preview-video,
.book-preview-dialog:fullscreen .book-preview-video,
.book-preview-dialog:-webkit-full-screen .book-preview-video {
    width: 100%;
    max-width: none;
    height: 100%;
    max-height: 100%;
    object-fit: contain;
}

.book-preview-shell.is-fullscreen .book-preview-info-image,
.book-preview-dialog:fullscreen .book-preview-info-image,
.book-preview-dialog:-webkit-full-screen .book-preview-info-image {
    max-height: 100%;
}

@media (max-width: 767px) {
    .book-preview-slide {
        overflow-x: hidden;
        overflow-y: auto;
    }

    .book-preview-info {
        gap: 25px;
    }

    .book-preview-info-title {
        font-size: 26px;
    }

    .book-preview-description {
        font-size: 17px;
    }
}

@media (max-width: 667px) {
    .book-preview-look-inside {
        display: none !important;
    }

    .book-preview-shell {
        padding: 0;
    }

    .book-preview-dialog {
        width: 100%;
        max-width: none;
        height: 100%;
        max-height: none;
        min-height: 0;
        margin: 0;
        padding: 10px 10px 8px;
        padding: max(10px, env(safe-area-inset-top)) 10px max(8px, env(safe-area-inset-bottom));
        overflow: hidden;
        background: #f0f0f0;
        border-radius: 0;
        box-shadow: none;
    }

    .book-preview-header {
        flex: 0 0 auto;
        gap: 8px;
        padding-bottom: 8px;
    }

    .book-preview-heading {
        max-width: 60vw;
        overflow: hidden;
        font-size: 18px;
        line-height: 1.2;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .book-preview-status {
        margin-top: 2px;
        font-size: 12px;
    }

    .book-preview-action {
        min-height: 36px;
        padding: 6px 9px;
        font-size: 11px;
    }

    .book-preview-close {
        width: 36px;
        height: 36px;
        font-size: 28px;
        line-height: 32px;
    }

    .book-preview-stage-wrap {
        flex: 1 1 auto;
        height: auto;
        min-height: 0;
    }

    .book-preview-stage {
        height: 100%;
        min-height: 0;
        padding: 0;
    }

    .book-preview-slide,
    .book-preview-shell.is-fullscreen .book-preview-slide,
    .book-preview-dialog:fullscreen .book-preview-slide,
    .book-preview-dialog:-webkit-full-screen .book-preview-slide {
        inset: 8px 34px;
        overflow-x: hidden;
        overflow-y: auto;
    }

    .book-preview-arrow {
        width: 30px;
        height: 58px;
        margin-top: -29px;
        font-size: 40px;
        line-height: 50px;
    }

    .book-preview-media {
        height: 100%;
        min-height: 0;
    }

    .book-preview-info {
        display: block;
        padding: 8px 0 16px;
    }

    .book-preview-info-cover {
        float: left;
        width: 35%;
        margin: 0 16px 8px 0;
    }

    .book-preview-info-image {
        max-height: 34vh;
    }

    .book-preview-info-title {
        margin-bottom: 6px;
        font-size: 21px;
    }

    .book-preview-author {
        margin-bottom: 10px;
        font-size: 16px;
    }

    .book-preview-description {
        margin-bottom: 9px;
        font-size: 15px;
        line-height: 1.35;
    }

    .book-preview-book-link {
        clear: both;
        display: inline-block;
        height: auto !important;
        min-height: 42px;
        margin: 8px 0 0 !important;
        padding: 0 15px !important;
        font-size: 13px !important;
        line-height: 40px !important;
    }

    .book-preview-thumbs {
        flex: 0 0 70px;
        padding: 5px 0 0;
    }

    .book-preview-thumb {
        flex-basis: 128px;
        width: 128px;
        height: 62px;
    }
}

@media (max-width: 374px) {
    .book-preview-heading {
        max-width: 48vw;
    }

    .book-preview-info-cover {
        width: 31%;
    }

    .book-preview-description {
        font-size: 14px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .book-preview-shell *,
    .book-preview-shell *::before,
    .book-preview-shell *::after {
        scroll-behavior: auto !important;
        transition-duration: .01ms !important;
    }
}
