/* Compact, cover-first bookstore. */
:root { --rk-text: #11243a; --rk-text-soft: #617086; --rk-border: #dce1e7; --rk-accent: #ce7909; --rk-link: #19334c; }
body { background: #fff; color: #11243a; font-family: 'Segoe UI', Arial, sans-serif; }
h1,h2,h3,h4,h5,.btn,.navbar-brand { font-family: inherit; }
a { color: #17334e; }
.site-shell { min-height: 100vh; display: flex; flex-direction: column; }
.site-main { flex: 1; }
.site-shell > .site-main > .container,.site-header .container,.store-footer .container { width: calc(100% - 72px); max-width: 1480px; }
.site-header { background-color: #0d2332; border-bottom: 1px solid #263a48; box-shadow: none; }
.site-header::before { opacity: .55; background-image: linear-gradient(110deg, transparent, #284855); }
.site-header .navbar { min-height: 76px; padding: 10px 0; }
.site-header .bookish-brand { gap: 10px; color: #fff !important; font-size: 25px; font-weight: 700; letter-spacing: -.7px; margin-right: 30px; }
.site-header .bookish-brand img { width: 38px; height: 38px; }
.site-header .nav-link { font-family: inherit; font-size: 14px; text-shadow: none; color: #fff !important; }
.site-header .account-nav .nav-link { font-size: 13px; }
.site-header .navbar-collapse { background: transparent; border: 0; padding: 0; margin: 0; }
.site-main > .catalog-page { padding-top: 0 !important; padding-bottom: 30px !important; }
.catalog-toolbar { display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid #dce1e7; gap: 24px; }
.catalog-tabs { display: flex; align-self: stretch; gap: 16px; overflow-x: auto; }
.catalog-tabs a { text-decoration: none; color: #526177; font-size: 14px; padding: 22px 10px 16px; border-bottom: 3px solid transparent; }
.catalog-tabs a.active { font-weight: 700; color: #102339; border-color: #d18414; }
.catalog-search { display: flex; align-items: center; position: relative; width: 290px; }
.catalog-search .form-control { background: #fff; font-size: 13px; padding: 9px 12px 9px 38px; border: 1px solid #cfd7e0; }
.catalog-search button { position: absolute; left: 6px; top: 1px; border: 0; background: transparent; color: #17334e; font-size: 26px; line-height: 32px; }
.catalog-filters { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding-top: 19px; }
.genre-filters { display: flex; flex-wrap: wrap; gap: 9px; }
.genre-chip { border: 1px solid #dce1e7; border-radius: 24px; padding: 7px 15px; font-size: 13px; text-decoration: none; color: #526177; white-space: nowrap; }
.genre-chip.active { border-color: #d18414; background: #fff2dc; color: #14263b; font-weight: 600; }
.genre-chip:hover { border-color: #d18414; color: #12293e; }
.catalog-count { color: #526177; font-size: 14px; white-space: nowrap; }
.catalog-sort { display: flex; justify-content: flex-end; align-items: center; gap: 8px; margin: 14px 0 20px; font-size: 12px; color: #526177; }
.catalog-sort .form-select { width: 180px; font-size: 12px; }
.store-grid { display: grid; grid-template-columns: repeat(6,minmax(0,1fr)); gap: 30px 22px; }
.store-card { display: flex; flex-direction: column; min-width: 0; background: none; border: none; border-radius: 0; box-shadow: none; height: 100%; }
.store-cover-link { display: block; padding: 0; background: #f2f4f5; aspect-ratio: 2 / 3; min-height: 0; border-radius: 3px; overflow: hidden; box-shadow: 0 2px 5px #11243a25; }
.store-cover { display: block; height: 100%; width: 100%; max-width: 100%; object-fit: contain; box-shadow: none; transition: transform .18s ease; }
.store-cover-link:hover .store-cover { transform: scale(1.025); }
.store-cover-placeholder { display: grid; place-items: center; width: 100%; height: 100%; min-height: 0; padding: 20px; text-align: center; color: #f1ca80; background: #17323d; font-family: Georgia,serif; font-size: 22px; }
.store-card-info { padding: 12px 0 10px; }
.store-card .book-reviews { font-size: 13px; line-height: 1.4; }
.store-card h3 { margin: 0 0 6px; font-size: 14px; line-height: 1.35; letter-spacing: -.2px; }
.store-card h3 a { text-decoration: none; color: #11243a; }
.store-card h3 a:hover { text-decoration: underline; }
.store-card-author,.store-card-genre { font-size: 13px; line-height: 1.4; color: #617086; margin: 2px 0; }
.store-card-author a { color: inherit; text-decoration: none; }
.store-card-author a:hover { text-decoration: underline; }
.get-book-button { margin-top: auto; padding: 8px 10px; border: 1px solid #dfb16d; border-radius: 4px; color: #895009; background: #fff8ed; font: 600 13px 'Segoe UI',sans-serif; display: flex; justify-content: center; text-align: center; align-items: center; }
.get-book-button:hover { background: #d08310; color: #fff; border-color: #d08310; }
.catalog-pagination { display: flex; justify-content: center; gap: 10px; margin-top: 30px; }
.catalog-pagination a { min-width: 36px; padding: 7px 12px; border: 1px solid #dce1e7; border-radius: 4px; text-decoration: none; font-size: 14px; text-align: center; }
.catalog-pagination a.active { background: #cf7d0a; border-color: #cf7d0a; color: white; }
.catalog-empty { padding: 60px 0; text-align: center; color: #617086; }
.store-footer { border-top: 1px solid #dce1e7; padding: 14px 0; font-size: 13px; }
.store-footer .container { display: flex; align-items: center; gap: 30px; }
.footer-brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 700; font-size: 17px; margin-right: auto; }
.store-footer span { color: #617086; }
.site-main .btn-primary { background: #17334e; color: #fff; border: 1px solid #17334e; box-shadow: none; text-shadow: none; padding: .5rem 1rem; }
.site-main .btn-primary:hover { background: #244d6e; }
.site-main .btn-outline-dark { border-color: #cfd7e0; color: #17334e; }
.form-control,.form-select { background: #fff; border-color: #cfd7e0; }
.purchase-modal .modal-dialog { max-width: 860px; }
.purchase-modal .modal-content { background: #fff; border: none; border-radius: 5px; box-shadow: 0 20px 70px #0004; }
.purchase-modal .btn-close { position: absolute; top: 22px; right: 22px; z-index: 2; }
.purchase-modal .modal-body { padding: 64px 64px 30px; }
.purchase-book { display: grid; grid-template-columns: 156px minmax(0,1fr); gap: 35px; }
.purchase-cover img { width: 100%; height: auto; border-radius: 3px; box-shadow: 0 2px 6px #0002; }
.purchase-info h2 { font-family: Georgia,serif; font-size: clamp(28px,4vw,42px); line-height: 1.1; letter-spacing: -1px; margin: 4px 0 10px; }
.purchase-author { font-size: 19px; margin-bottom: 24px; }
.purchase-author a { text-decoration: none; }
.purchase-prompt { color: #617086; font-size: 14px; margin-bottom: 18px; }
.marketplace-links { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 10px; }
.marketplace-button { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 12px 10px; border-radius: 4px; background: #de4036; color: #fff; text-align: center; text-decoration: none; }
.marketplace-button:hover { background: #bd2f27; color: #fff; }
.marketplace-button strong { font-size: 15px; }
.marketplace-button > span { font-size: 11px; margin-top: 3px; opacity: .9; }
.purchase-details-link { margin-top: 36px; padding: 26px 0 5px; border-top: 1px solid #dce1e7; text-align: center; }
.purchase-details-link a { font-size: 16px; color: #122b3f; text-underline-offset: 3px; }
.purchase-message { margin: 20px 0 35px; }
@media(min-width:1600px) { .store-grid { gap: 36px 28px; } }
@media(max-width:1100px) { .store-grid { grid-template-columns: repeat(4,minmax(0,1fr)); } .site-header .bookish-brand { font-size: 21px; margin-right: 20px; } }
@media(max-width:767px) { .site-shell > .site-main > .container,.site-header .container,.store-footer .container { width: calc(100% - 32px); } .store-grid { grid-template-columns: repeat(3,minmax(0,1fr)); gap: 24px 16px; } .catalog-toolbar { flex-wrap: wrap; gap: 0; padding-bottom: 14px; } .catalog-tabs { width: 100%; } .catalog-tabs a { padding: 16px 7px 12px; } .catalog-search { width: 100%; margin-top: 14px; } .catalog-filters { align-items: flex-start; } .catalog-count { padding-top: 8px; } .genre-filters { flex-wrap: nowrap; overflow-x: auto; padding-bottom: 5px; } .purchase-modal .modal-body { padding: 55px 25px 25px; } .purchase-book { grid-template-columns: 110px minmax(0,1fr); gap: 22px; } .marketplace-links { grid-template-columns: 1fr; } .store-footer span { display: none; } }
@media(max-width:480px) { .store-grid { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 25px 16px; } .site-header .bookish-brand { font-size: 21px; } .site-header .navbar { min-height: 70px; } .store-card h3 { font-size: 14px; } .purchase-book { grid-template-columns: 1fr; } .purchase-cover { width: 105px; } .purchase-info h2 { font-size: 32px; } .purchase-author { margin-bottom: 15px; } .marketplace-links { grid-template-columns: repeat(2,minmax(0,1fr)); } .catalog-tabs { gap: 12px; } }
@media(prefers-reduced-motion:reduce) { .store-cover { transition: none; } }
/* Secondary pages use the same visual rhythm as Browse Books. */
.catalog-filters { margin-bottom: 25px; }
.catalog-tabs { gap: 12px; }
.filter-summary { color: #617086; font-size: 13px; margin: -4px 0 24px; }
.filter-summary a { margin-left: 15px; }
.author-grid { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 24px; }
.author-card { border: 1px solid #e0e5ea; border-radius: 6px; background: #fff; }
.author-card .card-body { height: 100%; display: flex; flex-direction: column; align-items: flex-start; padding: 24px; }
.author-card h2 { font-size: 19px; margin: 0 0 9px; }
.author-card h2 a { text-decoration: none; }
.author-card p { color: #617086; font-size: 14px; line-height: 1.6; }
.author-card-actions { margin-top: auto; padding-top: 15px; display: flex; flex-wrap: wrap; align-items: center; gap: 15px; }
.author-card-actions .btn { padding: 7px 14px; font-size: 13px; }
.explore-books { font-size: 13px; font-weight: 600; text-decoration: none; }
.series-reading-link { display: inline-block; border: 1px solid #e4caa4; border-radius: 4px; background: #fff8ec; padding: 10px 15px; color: #8a540d; text-decoration: none; font-size: 14px; }
.store-price { color: #ce7909; font-size: 18px; font-weight: 700; margin: 8px 0 0; }
.bb-book-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 24px; }
.bb-book-body { padding: 24px; }
.bb-book-cover { width: 100px; max-height: 150px; object-fit: contain; float: left; margin: 0 18px 16px 0; border-radius: 3px; }
.bb-book-content { font-size: 14px; line-height: 1.6; }
.bb-book-content h2 { font-size: 19px; }
.bb-book-content > .mt-auto { clear: both; padding-top: 16px; }
.site-main article.row { margin-top: 22px !important; margin-bottom: 32px; }
.site-main article.row > .col-md-9 { padding-left: 36px; }
@media(max-width:1100px) { .author-grid,.bb-book-grid { grid-template-columns: repeat(2,minmax(0,1fr)); } }
@media(max-width:767px) { .site-main article.row > .col-md-9 { padding-left: 12px; } .catalog-tabs { gap: 6px; } .catalog-tabs a { font-size: 13px; } }
@media(max-width:480px) { .author-grid,.bb-book-grid { grid-template-columns: 1fr; } }
.site-header .bookish-brand { display: flex; align-items: center; }
