::selection {
    background: #6656a8;
    color: #fff;
    text-shadow: none;
}
body.home-page .popularity-hero { background: #17143b; }
body.home-page .hero-background {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    pointer-events: none;
}
body.home-page .popularity-hero::before {
    z-index: 1;
    background:
        linear-gradient(to bottom, transparent 82%, #17143b 100%),
        linear-gradient(90deg, rgba(9,7,30,.35), rgba(9,7,30,.1) 48%, rgba(9,7,30,.48)),
        linear-gradient(180deg, rgba(12,8,36,.12), rgba(12,8,36,.32));
}
body.home-page .popularity-hero > .shell { z-index: 2; }
body:not(.account-auth-page):not(.icloud-profile-page) {
    --action-height: 44px;
    --action-radius: 999px;
    --space-small: 12px;
    --space-medium: 24px;
    --space-section: 64px;
}
body:not(.account-auth-page):not(.icloud-profile-page) :is(.solid-button,.light-button,.quiet-button,.danger-button,.save-book-form:not(.save-book-form--compact) .save-book-button) {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-height: var(--action-height);
    max-width: 100%;
    padding: 10px 20px;
    border: 1px solid transparent;
    border-radius: var(--action-radius);
    font-size: .875rem;
    font-weight: 600;
    line-height: 1.35;
    text-align: center;
    white-space: normal;
    transition: background-color .18s, border-color .18s, box-shadow .18s;
}
body:not(.account-auth-page):not(.icloud-profile-page) :is(.solid-button,.light-button) {
    color: #111321;
    background: #fff;
    box-shadow: none;
}
body:not(.account-auth-page):not(.icloud-profile-page) :is(.solid-button,.light-button):hover {
    color: #111321;
    background: #ece9fa;
    transform: none;
}
body:not(.account-auth-page):not(.icloud-profile-page) :is(.quiet-button,.save-book-form:not(.save-book-form--compact) .save-book-button) {
    color: #f6f3ff;
    background: transparent;
    border-color: rgba(216,210,249,.35);
}
body:not(.account-auth-page):not(.icloud-profile-page) :is(.quiet-button,.save-book-form:not(.save-book-form--compact) .save-book-button):hover {
    background: rgba(216,210,249,.08);
    border-color: #b8afd9;
}
body:not(.account-auth-page):not(.icloud-profile-page) .danger-button {
    color: #fff;
    background: #af2940;
    border-color: #af2940;
}
body:not(.account-auth-page):not(.icloud-profile-page) .danger-button:hover { background: #c13149; }
body:not(.account-auth-page):not(.icloud-profile-page) :is(.solid-button,.light-button,.quiet-button,.danger-button,.save-book-button):disabled {
    opacity: .5;
    cursor: not-allowed;
}
body:not(.account-auth-page):not(.icloud-profile-page) :is(.book-primary-actions,.review-form-actions) { gap: var(--space-small); }
body:not(.account-auth-page):not(.icloud-profile-page) :is(.section-heading,.reader-tools) { gap: var(--space-medium); }
body:not(.account-auth-page):not(.icloud-profile-page) .section-heading { margin-bottom: var(--space-medium); }
body:not(.account-auth-page):not(.icloud-profile-page) :is(.review-section,.comment-section,.library-section) { padding-top: var(--space-section); }
body:not(.account-auth-page):not(.icloud-profile-page) :is(.catalog-redesign.shell,.detail-page,.reader-page) { padding-top: 56px; padding-bottom: 80px; }
body:not(.account-auth-page):not(.icloud-profile-page) .interaction-form { padding: var(--space-medium); }
body:not(.account-auth-page):not(.icloud-profile-page) .save-book-form--compact .save-book-button { width: 44px; height: 44px; min-height: 44px; }
body:not(.account-auth-page):not(.icloud-profile-page) :is(.shelf-book,.catalog-book-cover,.catalog-grid,.detail-cover,.featured-item) .book-cover {
    height: auto;
    aspect-ratio: 2 / 3;
    border-radius: 6px;
    background: #1c1b36;
    border: 1px solid rgba(214,208,249,.13);
}
body:not(.account-auth-page):not(.icloud-profile-page) :is(.shelf-book,.catalog-book-cover,.catalog-grid,.detail-cover,.featured-item) .book-cover img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}
body:not(.account-auth-page):not(.icloud-profile-page) .shelf-book-title,
body:not(.account-auth-page):not(.icloud-profile-page) .catalog-book-title {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
    white-space: normal;
    line-height: 1.4;
    min-height: 2.8em;
}
body:not(.account-auth-page):not(.icloud-profile-page) .catalog-book-author {
    display: block;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}
@media (max-width: 720px) {
    body.home-page {
        color-scheme: dark;
        color: #faf9ff;
        background: #17143b;
    }
    body.home-page .hero-background { object-position: 48% center; }
    body.home-page .site-header { color: #faf9ff; background: rgba(23,20,59,.92); }
    body.home-page :is(.brand,.catalog-dropdown > summary,.nav-account) { color: #faf9ff; }
    body.home-page .nav-search { color: #faf9ff; background: rgba(255,255,255,.065); border-color: rgba(224,219,255,.22); }
    body.home-page .nav-search input { color: #faf9ff; }
    body.home-page .nav-search input::placeholder { color: #c0bdd8; }
    body.home-page .nav-search button { color: #faf9ff; }
    body.home-page .home-library { color: #faf9ff; background: #17143b; }
    body:not(.account-auth-page):not(.icloud-profile-page) { --space-section: 40px; --space-medium: 20px; }
    body:not(.account-auth-page):not(.icloud-profile-page) :is(.catalog-redesign.shell,.detail-page,.reader-page) { padding-top: 32px; padding-bottom: 56px; }
    body:not(.account-auth-page):not(.icloud-profile-page) .book-overview { gap: 24px; padding-bottom: 40px; }
}
@media (prefers-reduced-motion: reduce) {
    body:not(.account-auth-page):not(.icloud-profile-page) :is(.solid-button,.light-button,.quiet-button,.danger-button,.save-book-button) { transition: none; }
}
