/* sell-first 28 Nov 2026: buy buttons above the fold, UK + US side by side. Navy and gold. */
.sf-btns{display:flex;gap:.6rem;flex:1 1 auto;min-width:0}
.sf-btn,.btn.sf-btn{flex:1 1 0;min-width:0;min-height:48px;display:inline-flex;align-items:center;justify-content:center;text-align:center;font-weight:700;font-size:1rem;line-height:1.15;padding:.5rem .7rem;border-radius:6px;border:2px solid #E2A85C;background:transparent;color:#0E1118;text-decoration:none}
.sf-btn:hover{background:rgba(226,168,92,.22);border-color:#cf9b3a}
.sf-btn.sf-primary,.btn.sf-btn.sf-primary{background:#E2A85C;color:#111;border-color:#E2A85C}
.sf-btn.sf-primary:hover{background:#cf9b3a;border-color:#cf9b3a}
.sf-fmt{display:flex;align-items:center;gap:.75rem;margin:0 0 .6rem}
.sf-fmt-name{flex:0 0 6.2rem;font-weight:700}
.sf-fmt-name a{color:inherit}
.sf-buy{margin:1rem 0 1.1rem;max-width:34rem}
.sf-buy .affiliate-note,.sf-buy .ku,.sf-buy .amazon-disclosure{margin:.3rem 0 0;font-size:.85rem}
.sf-next-lead{margin:0 0 .7rem;font-weight:600}
/* book pages */
.book-page .book-header,.book-page .book-header-picture .book-header{max-height:200px}
@media (max-width:640px){
  .book-page{padding-top:.5rem}
  .book-page .book-header,.book-page .book-header-picture .book-header{max-height:84px;margin-bottom:.6rem}
  .book-page .book-header-picture{margin-bottom:.6rem}
  .book-page .book-layout{display:grid;grid-template-columns:104px minmax(0,1fr);column-gap:1rem;row-gap:0;align-items:start}
  .book-page .book-body{display:contents}
  .book-page .book-body>*{grid-column:1/-1}
  .book-page .book-cover{grid-column:1;grid-row:1/span 5;max-width:104px}
  .book-page .book-body>.ps,.book-page .book-body>h1,.book-page .book-body>.sub,.book-page .book-body>.date,.book-page .book-body>.hook{grid-column:2}
  .book-page .book-body>.sub{margin:.1rem 0;font-size:.95rem}
  .book-page .book-body>h1{font-size:1.45rem;max-width:none}
  .book-page .book-body>.hook{font-size:.98rem;margin:.2rem 0 .5rem}
  .book-page .book-body>.date{margin:.3rem 0}
  .sf-fmt{flex-wrap:wrap;gap:.3rem;margin-bottom:.5rem}
  .sf-fmt-name{flex:1 1 100%}
  .sf-btn,.btn.sf-btn{min-height:46px;font-size:.98rem;padding:.4rem .4rem}
}
/* home lead bar and start here */
.sf-lead,.sf-band{display:flex;align-items:center;justify-content:center;gap:.5rem 1.25rem;flex-wrap:wrap;padding:.7rem 1rem;background:#0E1118;color:#F4EEE2;border-bottom:1px solid rgba(226,168,92,.5);text-align:center}
.sf-lead a,.sf-band a{color:#E2A85C}
.sf-lead-text,.sf-band-text{margin:0;font-size:1rem}
.sf-lead .sf-fmt,.sf-band .sf-fmt{margin:0}
.sf-lead .sf-fmt-name,.sf-band .sf-fmt-name{flex:0 0 auto;color:#F4EEE2}
.sf-lead .sf-btn,.sf-band .sf-btn{min-width:9rem;border-color:#E2A85C}
.sf-lead .sf-btn.sf-primary,.sf-band .sf-btn.sf-primary{color:#111}
.sf-band{margin-top:3rem;border-top:1px solid rgba(226,168,92,.5);border-bottom:0;flex-direction:column;padding:1.6rem 1rem}
.sf-band .affiliate-note{margin:.2rem 0 0;font-size:.85rem;color:#d8d0c4;flex-basis:100%}
.start-here-actions.sf-buy{margin:.6rem 0 .3rem;max-width:30rem}
/* Editor fix 2 (29 Nov): Start here sits on the dark navy page, so labels and outlined buttons use the light cream (#F4EEE2) and gold (#E2A85C) of the house palette; the primary gold buttons keep dark text */
.start-here .sf-fmt-name{color:#F4EEE2}
.start-here .sf-fmt{flex-wrap:nowrap}
.start-here .sf-btn{white-space:nowrap;min-width:7.6rem;color:#F4EEE2}
.start-here .sf-btn.sf-primary,.start-here .btn.sf-btn.sf-primary{color:#111}
.start-here .sf-btn:not(.sf-primary):hover{color:#fff}
@media (max-width:640px){.start-here .sf-fmt{flex-wrap:wrap}.start-here .sf-btn{min-width:0}}
@media (max-width:640px){
  .sf-lead{padding:.55rem .75rem;gap:.35rem .75rem}
  .sf-lead-text{font-size:.95rem}
  .sf-lead .sf-fmt{width:100%;gap:.5rem;flex-wrap:nowrap}
  .sf-lead .sf-fmt-name{flex:0 0 auto}
  .sf-lead .sf-btns{flex:1 1 auto}
  .sf-lead .sf-btn{min-width:0;min-height:44px}
  .sf-band .sf-fmt{width:100%;flex-wrap:nowrap}
  .sf-band .sf-fmt-name{flex:0 0 auto}
}
/* 404 */
.sf-404-buy{width:min(100%,26rem);margin:0 0 .5rem}
.sf-404-buy .sf-fmt{justify-content:center}
.sf-404-buy .sf-btn{color:#111}
main .sf-band-text a{color:#6F4E12}
/* ===== FIX-1129 (Philip 29 Nov 22:47 via the PM) ===== */
/* 1. One small, muted Amazon Associates line in the shared footer (#a9a49b on #080a0d, AA contrast) */
.foot .amazon-disclosure{margin:0;color:#a9a49b;font-size:.78rem;line-height:1.4;max-width:60ch}
/* 2. Card grids: equal-height cards; fixed 5:8 cover box (every cover is 800x1280); label, title, series in one order
      directly under the cover, aligned across each row (subgrid); buttons/links pinned to the card bottom. */
/* Library, Coming soon (covers and text-only tiles) */
.library{align-items:stretch;row-gap:clamp(1.25rem,3vw,1.75rem)}
.library>li.book{display:flex;flex-direction:column;min-width:0}
.library .book-btn,.library .book-static{display:flex;flex-direction:column;flex:1 1 auto;width:100%}
.library .book-btn picture,.library .book-static picture{display:block}
.library .book-btn img,.library .book-static img,.library .cover-placeholder{display:block;width:100%;height:auto;aspect-ratio:5/8;object-fit:cover}
.library .meta{margin-top:.55rem;gap:.2rem}
.library .meta .badge{align-self:flex-start;justify-self:start}
@supports (grid-template-rows:subgrid){
  .library>li.book{display:grid;grid-row:span 4;grid-template-rows:subgrid;row-gap:0}
  .library .book-btn,.library .book-static{display:grid;grid-row:1/-1;grid-template-rows:subgrid;row-gap:0}
  .library .book-btn>picture,.library .book-btn>img,.library .book-static>picture,.library .book-static>img,.library .book-static>.cover-placeholder{grid-row:1;margin-bottom:.55rem}
  .library .meta{display:grid;grid-row:2/-1;grid-template-rows:subgrid;row-gap:.2rem;margin-top:0;align-content:start;align-items:start}
}
.library .bt{line-height:1.25}
/* Hero posters (Out now, Book 1s): fixed cover box so Safari srcset sizing cannot shift a caption */
.ts-posters .poster img{aspect-ratio:5/8;object-fit:cover}
@media(max-width:820px){
  .ts-posters,.ts-posters:has(.poster:nth-child(4)){align-items:stretch;row-gap:14px}
  .ts-posters .poster{align-self:stretch}
  .ts-posters .poster-link{width:100%}
  .ts-posters .poster img,.ts-posters:has(.poster:nth-child(4)) .poster img{width:min(28vw,100%);max-width:100%;height:auto;max-height:none}
  .ts-posters .poster figcaption{display:flex;flex-direction:column;align-items:center;gap:.12rem;width:100%;min-width:0;margin-top:.4rem}
  .ts-posters .poster-title,.ts-posters .poster-status,.ts-posters .poster-ser{min-height:0}
  @supports (grid-template-rows:subgrid){
    .ts-posters .poster{display:grid;grid-row:span 4;grid-template-rows:subgrid;row-gap:0}
    .ts-posters .poster-link{display:grid;grid-row:1/-1;grid-template-rows:subgrid;row-gap:0;justify-items:center}
    .ts-posters .poster-link>img{grid-row:1;margin-bottom:.4rem}
    .ts-posters .poster figcaption{display:grid;grid-row:2/-1;grid-template-rows:subgrid;row-gap:.12rem;margin-top:0;align-content:start;align-items:start}
  }
}
/* Read an extract: equal-height cards, link at the bottom */
.previews{align-items:stretch}
.preview>div{display:flex;flex-direction:column;align-self:stretch;min-width:0}
.preview .link{margin-top:auto;padding-top:.5rem;align-self:flex-start}
/* Series rail: no stagger, equal heights, reading order at the bottom */
.series-rail{align-items:stretch}
.series-rail article,.series-rail article:nth-child(even){transform:none;display:flex;flex-direction:column}
.series-rail .series-order{margin-top:auto;padding-top:.6rem}
/* Characters and places: equal-height tiles */
.cast-grid,.places-grid{align-items:stretch}
.cast-grid>li,.places-grid>li{display:flex;flex-direction:column}
.cast-grid>li>article,.places-grid>li>figure{flex:1 1 auto}
.library>li.book[hidden]{display:none}

/* ===== KINDLE-1130: Kindle Instant Preview facade + homepage 'Read a sample' ===== */
.sf-sample{margin:1.15rem 0 1.35rem;max-width:40rem;scroll-margin-top:5.5rem}
.sf-sample-heading{margin:0 0 .65rem;font-size:1.2rem;line-height:1.3}
.sf-sample-facade{margin:0}
.sf-sample-load{min-width:min(100%,14rem)}
.sf-sample-fallback{margin:.6rem 0 0}
.sf-sample-frame{display:block;width:100%;max-width:100%;height:550px;border:1px solid rgba(226,168,92,.7);background:#0E1118;border-radius:6px}
/* Homepage Out Now tiles (hero posters sit on dark navy; Latest releases on paper) */
.ts-posters .sf-sample-home{margin-top:.4rem;width:100%;max-width:100%;box-sizing:border-box;min-height:44px;font-size:.82rem;padding:.35rem .4rem;color:#F4EEE2;border-color:#E2A85C;text-decoration:none}
.ts-posters .sf-sample-home:hover{color:#fff;background:rgba(226,168,92,.22)}
.showcase-item{display:flex;flex-direction:column}
.showcase-item .sf-sample-home{margin:.75rem 0 0;align-self:flex-start;min-width:12rem;min-height:44px;color:#0E1118}
@media (max-width:820px){
  /* Keep the 5:8 cover box; pin the sample button under the caption as a fifth row */
  .ts-posters .sf-sample-home{margin-top:.35rem;font-size:.78rem}
  @supports (grid-template-rows:subgrid){
    .ts-posters .poster{display:grid;grid-row:span 5;grid-template-rows:subgrid;row-gap:0}
    .ts-posters .poster-link{display:grid;grid-row:1 / span 4;grid-template-rows:subgrid;row-gap:0;justify-items:center}
    .ts-posters .poster-link>img{grid-row:1;margin-bottom:.4rem}
    .ts-posters .poster figcaption{display:grid;grid-row:2 / span 3;grid-template-rows:subgrid;row-gap:.12rem;margin-top:0;align-content:start;align-items:start}
    .ts-posters .sf-sample-home{grid-row:5;width:100%;justify-self:stretch}
  }
}
@media (max-width:640px){
  .sf-sample-frame{height:550px}
  .showcase-item .sf-sample-home{width:100%;max-width:16rem}
}
@media (prefers-reduced-motion:reduce){
  .sf-sample,.sf-sample *,.sf-sample-home,.sf-sample-frame,.sf-sample-load{
    transition:none !important;
    animation:none !important
  }
}
/* KINDLE-1130b: balanced title wraps; visible focus on the loaded sample */
.poster-title,.live-title,.book-page h1,.library .bt{text-wrap:balance}
.sf-sample-facade:focus,.sf-sample-frame:focus{outline:3px solid #E2A85C;outline-offset:3px}
