/* ── Home fixes (2026-10-18 design review) ─────────────────────────────────
   Loaded after style.css and home.css on index.html only. */

/* Main CTA plays a first chapter (js/library.js initHeroPlay). */
.hero-play { gap: .55rem; }
.hero-play svg { flex: none; }

/* The sample card stays out of the layout until /samples gives it a book
   (display:flex on .hero-sample used to beat the hidden attribute). */
.hero-sample[hidden] { display: none; }

/* "What listeners are playing" is a two-column list, not a scroller: no
   right-edge fade (it clipped column 2). The seasonal row keeps its fade. */
.hero-featured.lp-rank { -webkit-mask-image: none; mask-image: none; }

/* Library heading: display serif, on the same container as the hero and the
   rest of the guest page (1180px content, like Browse by genre). */
#library-section .section-header h2 {
  font-family: var(--font-display); font-weight: 500; font-size: 1.85rem; line-height: 1.15;
}
body:has(#guest-hero:not(.hidden)) #library-section {
  max-width: calc(1180px + 3rem); padding-left: 1.5rem; padding-right: 1.5rem;
}
/* Free-book banner: same width as the hub and the library below it. */
.fb-banner-inner { max-width: 1152px; }

/* Library cards: title, then "Author · Genre"; length only on the cover. */
.book-card .book-info .book-title {
  font-family: var(--font-display); font-size: 1rem; font-weight: 600; line-height: 1.25;
  color: var(--text); margin-bottom: 3px;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.book-card .book-info .author { font-size: .78rem; font-weight: 400; color: var(--text-3); }
/* The nowrap "Author · Genre" line must not widen a shelf card. */
.shelf-row .book-card { min-width: 0; }

/* A free account's claimed book. */
.tag-yours {
  position: absolute; left: 8px; top: 8px; z-index: 2;
  padding: 3px 8px; border-radius: 999px;
  background: var(--accent); color: #171310;
  font-size: .68rem; font-weight: 700; letter-spacing: .02em; line-height: 1.3; white-space: nowrap;
}
.tag-yours--inline { position: static; align-self: flex-start; margin-top: 4px; padding: 1px 7px; font-size: .66rem; }

/* Continue card when the next chapter is past a free account's chapters. */
.home-kicker--lock { display: inline-flex; align-items: flex-start; gap: 6px; }
.home-kicker--lock svg { flex: none; margin-top: 1px; }
.home-hero-fine { margin: 8px 0 0; font-size: .76rem; color: var(--text-3); }
.home-alt {
  display: flex; align-items: center; gap: 10px;
  margin: 14px 0 0; padding-top: 12px; border-top: 1px solid var(--border);
  font-size: .84rem; line-height: 1.4; color: var(--text-2);
}
.home-alt a, .home-alt-link { color: var(--accent); font-weight: 600; }
.home-alt-link {
  background: none; border: 0; padding: 0; font: inherit; font-weight: 600; cursor: pointer;
  text-decoration: underline; text-underline-offset: 2px;
}
.home-alt-cover { flex: none; line-height: 0; border-radius: 2px; overflow: hidden; }
.home-alt-cover img { width: 28px; height: 42px; object-fit: cover; display: block; }

/* Single column (tablet and phone): the pitch and the free-book band
   (2026-10-24), then the ranked list; the sample card,
   the three features and the rest follow. */
@media (max-width: 960px) {
  .guest-hero { display: flex; flex-direction: column; }
  .guest-hero .hero-inner { display: contents; }
  .guest-hero > :not(.hero-glow), .guest-hero .hero-copy, .guest-hero .hero-sample { width: 100%; box-sizing: border-box; }
  .guest-hero .hero-copy { order: 0; }
  .guest-hero #lp-free { order: 2; }
  .guest-hero #hero-featured { order: 3; margin-top: 2.25rem; }
  .guest-hero #hero-sample { order: 4; margin-top: 2.5rem; }
  .guest-hero .lp-why { order: 5; }
  .guest-hero #lp-seasonal { order: 6; }
}

@media (max-width: 640px) {
  .guest-hero { padding-top: 1.75rem; }
  .hero-copy { gap: 14px; }
  .hero-headline { font-size: 2.3rem; }
  .hero-sub { font-size: .98rem; line-height: 1.5; }
  .hero-ctas { gap: .25rem; }
  /* The free-book band follows straight after the hero on phones, so its
     button replaces the hero's second CTA here. */
  .hero-ctas .hero-browse { display: none; }
  .hero-checks { display: none; }
  .guest-hero #hero-featured { margin-top: 1.5rem; padding-top: 20px; }
  .lp-rank-list { margin-top: .5rem; }

  /* Three features as a compact list. */
  .lp-why { margin-top: 2.5rem; }
  .lp-why-item, .lp-why-item + .lp-why-item {
    display: grid; grid-template-columns: 26px minmax(0, 1fr); column-gap: 14px; padding: 1rem 0;
  }
  .lp-why-icon { grid-row: span 2; margin-top: 2px; }
  .lp-why-item h2 { margin: 0 0 .2rem; font-size: 1.1rem; }
  .lp-why-item p { font-size: .86rem; line-height: 1.5; }
  .lp-why-item .lp-why-use { grid-column: 2; margin-top: .6rem !important; padding-top: .6rem; }

  .guest-hero #hero-featured .hero-featured-more { white-space: nowrap; margin-left: 12px; }
  #library-section .section-header h2 { font-size: 1.5rem; }
  /* Same 16px gutter as the hero and the signed-in hub. */
  #library-section, body:has(#guest-hero:not(.hidden)) #library-section { padding-left: 1rem; padding-right: 1rem; }

  /* Free-book banner: fan and title on one row, one-line body, full-width
     button. */
  .fb-banner-inner {
    display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center;
    gap: 12px 16px; padding: 16px 44px 16px 16px;
  }
  .fb-banner-text { display: contents; }
  .fb-banner-fan { grid-column: 1; grid-row: 1; height: 60px; padding-left: 4px; }
  .fb-banner-title { grid-column: 2; grid-row: 1; font-size: 1.2rem; line-height: 1.2; }
  .fb-banner-fan:empty + .fb-banner-text .fb-banner-title { grid-column: 1 / -1; }
  .fb-banner-sub { grid-column: 1 / -1; margin-right: -28px; }
  .fb-banner-cta { grid-column: 1 / -1; width: calc(100% + 28px); justify-content: center; }
}
