/* ============================================================
   RESPONSIVE.CSS
   Media queries for TMME at non-desktop widths.
   Loaded LAST so unlayered rules override all @layer rules.
   Desktop ↔ mobile flip at max-width: 800px plus tighter
   steps below.
   ============================================================ */

/* ── Swiper navigation: override default blue with neutral grey ── */
.swiper-button-next,
.swiper-button-prev {
  color: rgb(121, 121, 121);
  --swiper-navigation-color: rgb(121, 121, 121);
}

/* ── Featured Authors arrows: top-aligned, scaled 40%, translated ±54px outside container ── */
/* Double-class selector beats Swiper's injected 1-class rules */
.swiper-featured-authors-buttons.swiper-button-next,
.swiper-featured-authors-buttons.swiper-button-prev {
  top: 0;
  margin-top: 0;
}
.swiper-button-next-featured-authors {
  transform: matrix(0.4, 0, 0, 0.4, 54, 0);
}
.swiper-button-prev-featured-authors {
  transform: matrix(0.4, 0, 0, 0.4, -54, 0);
}

/* ── SEO copy: fix horizontal padding to match original (35px) at all viewports.
   Must live here (unlayered) so it beats the layered home.css rules. ── */
.seo-copy .container { padding: 0 80px; }

/* ── Sticky header: only rendered on mobile (≤920px) ── */
@media (min-width: 921px) {
  .sticky-header { display: none; }
}

/* ── Sticky header: burger + drawer (applies at ≤800px since sticky header
   is display:none above 800px via the min-width:801px rule above) ── */
@media (max-width: 1100px) {
  /* Inner: relative so logo can be absolutely centred */
  .sticky-header__inner { padding: 0 16px; gap: 0; position: relative; }
  .sticky-burger { display: flex; flex-shrink: 0; }

  /* Logo centred absolutely between burger and icons */
  .sticky-logo {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
  }

  /* Icons pinned to right */
  .sticky-icons { margin-left: auto; }

  /* Drawer: hidden by default */
  .sticky-nav-list { display: none; }

  /* Drawer: open state — full redesign */
  .sticky-nav-list.is-open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 56px;
    left: 0;
    right: 0;
    background: #fff;
    border-top: 2px solid var(--color-border);
    box-shadow: 0 12px 32px rgba(0,0,0,0.12);
    z-index: 101;
    padding: 0;
    height: auto;
    max-height: calc(100dvh - 56px);
    overflow-y: auto;
  }

  /* All list items full-width */
  .sticky-nav-list li { height: auto; width: 100%; }

  /* Main nav links — uppercase, dark, with hover */
  .sticky-nav-list a {
    display: block;
    width: 100%;
    height: auto;
    padding: 14px 20px;
    color: var(--color-dark);
    font-size: 13px;
    letter-spacing: 0.06em;
    border-bottom: 1px solid var(--color-border);
    transition: background 0.12s ease;
  }
  .sticky-nav-list li:not(.sticky-nav-sep):not(.sticky-nav-account) a:hover {
    background: rgba(0,0,0,0.03);
  }

  /* Separator — thick rule with extra breathing room */
  .sticky-nav-sep {
    height: 0;
    border: none;
    border-top: 6px solid var(--color-cream);
    margin: 0;
    padding: 0;
    list-style: none;
  }

  /* Account section — cream background, visually distinct */
  .sticky-nav-account { background: var(--color-cream); }
  .sticky-nav-account a {
    color: var(--color-secondary);
    font-size: var(--font-size-base);
    letter-spacing: 0.03em;
    text-transform: none;
    border-bottom: 1px solid rgba(0,0,0,0.06);
    padding: 13px 20px;
    transition: background 0.12s ease, color 0.12s ease;
  }
  .sticky-nav-account a:hover { background: rgba(0,0,0,0.04); color: var(--color-dark); }

  /* Sign In — orange accent for quick scannability */
  .sticky-nav-account--signin a { color: var(--color-orange); }
  .sticky-nav-account--signin a:hover { color: var(--color-dark); }
}

/* ────────────────────────────────────────────────────────────
   1280px — light squish: container padding shrinks
   ──────────────────────────────────────────────────────────── */
@media (max-width: 1280px) {
  .container { padding: 0 24px; }
  .featured-authors__inner { padding: 0 24px; }
  .header-body__inner { padding: 24px 40px 24px 50px; }
}

/* ────────────────────────────────────────────────────────────
   1024px — tighter chrome (hero/blog now driven by aspect-ratio)
   ──────────────────────────────────────────────────────────── */
@media (max-width: 1024px) {
  .header-body { height: auto; }
  .header-body__inner { padding: 16px 40px 16px 50px; gap: 70px; }
  .nav-list a { padding: 12px 14px; font-size: 14px; }
  .category-bar__pills { grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 12px; width: 100%; }
}

/* ────────────────────────────────────────────────────────────
   801–1100px — intermediate tier (kept lean — aspect-ratio
   handles hero/mission/blog/split-banner sizing automatically)
   Original site stays 4-up products and 6-up pills here.
   ──────────────────────────────────────────────────────────── */
@media (max-width: 1100px) and (min-width: 801px) {
  .featured-authors__inner { padding: 0 20px; min-width: 0; }
  .header-body__inner { padding: 24px 40px 24px 50px; gap: 70px; min-width: 0; }

  /* Search form caps at a reasonable width so it doesn't dominate the row */
  .search-form { max-width: 480px; }

  /* Pills: stay 6-up; allow text wrap to 2 lines at very tight widths
     (the longest label, "Church Resources", needs ~111px single-line) */
  .category-bar__pills {
    grid-template-columns: repeat(6, minmax(0, 148px));
    gap: 12px;
    width: 100%;
  }
  .pill {
    white-space: normal;
    text-align: center;
    padding: 6px 10px;
    line-height: 1.2;
    font-size: 13px;
  }

  /* Nav: max-width keeps overflow-x: auto working; site-nav's justify-content: center centres it */
  .nav-list {
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: none;
    max-width: 100%;
  }
  .nav-list::-webkit-scrollbar { display: none; }
  .nav-list a { padding: 12px 8px; font-size: 13px; }
  /* The scrolling bar clips anything below it, so its dropdowns could never be seen here (921-1100px; below
     921 the phone menu takes over) and only let the bar scroll into blank space. The links still open
     their pages. */
  @media (min-width: 921px) {
    .nav-list .nav-dropdown { display: none; }
  }

  /* Stay 4-up like the original; figures stay flexible (no fixed cap) */
  .product-item { width: calc((100% - 60px) / 4); padding: 0; }
  .product-figure { max-width: 240px; }
  .product-figure img { max-width: 240px; }
}

/* ────────────────────────────────────────────────────────────
   ≤ 920px — mobile header: picture logo, burger, drawer nav
   (eliminates any intermediate range where icons can overflow)
   ──────────────────────────────────────────────────────────── */
@media (max-width: 920px) {
  /* Swap to picture logo */
  .logo .logo-icon { display: none; }
  .logo-text { display: none; }
  .logo-full-mobile { display: block; height: 36px; width: auto; }

  /* Header bar — logo left | burger right */
  .header-body { height: auto; }
  .header-body__inner {
    padding: 16px 20px;
    flex-wrap: nowrap;
    gap: 0;
    justify-content: space-between;
    min-height: 0;
  }
  .logo { order: 1; }
  .search-form { display: none; }
  .header-icons { display: none; }
  .nav-burger { display: inline-flex; order: 2; }

  /* Nav drawer — matches book-header mobile design */
  .site-nav { height: auto; position: relative; }
  .nav-list {
    display: none;
    flex-direction: column;
    width: 100%;
    height: auto;
    background: #fff;
    border-top: 1px solid var(--color-border);
    box-shadow: 0 8px 24px rgba(0,0,0,0.1);
    z-index: 200;
    overflow: visible;
    padding: 8px 0 16px;
    justify-content: flex-start;
    align-items: stretch;
  }
  .nav-list.is-open { display: flex; }
  .nav-list li { width: 100%; height: auto; flex-shrink: 0; flex-direction: column; align-items: stretch; }
  .nav-list > li:not(.nav-mobile-search):not(.nav-mobile-icons) > a {
    display: block;
    width: 100%;
    padding: 20px;
    font-size: 13px;
    letter-spacing: 3.3px;
    text-transform: uppercase;
    text-align: center;
    border-bottom: 1px solid rgba(0,0,0,0.05);
    white-space: nowrap;
  }

  /* Remove border after the last nav link (SALE) — specificity matches base rule */
  .nav-list > li:not(.nav-mobile-search):not(.nav-mobile-icons):nth-last-child(3) > a { border-bottom: none; }

  /* Mobile search in dropdown — centred */
  .nav-mobile-search { display: block; padding: 20px 20px; }
  .nav-mobile-search .search-form { display: flex; width: 100%; max-width: 480px; margin: 0 auto; }
  .nav-mobile-search .search-input { height: 48px; font-size: 15px; padding: 10px 14px; }
  .nav-mobile-search .search-btn { height: 48px; padding: 0 16px; }

  /* Mobile icons in dropdown */
  .nav-list .nav-mobile-icons { display: flex; flex-direction: row; justify-content: center; align-items: center; gap: 24px; padding: 20px 12px; }
  .nav-mobile-icons a { display: flex; align-items: center; justify-content: center; color: var(--color-body); padding: 8px; }
  .nav-list .nav-mobile-icons a svg { width: 24px; height: 24px; }

  /* Sub-dropdowns: click-triggered only, rendered inline (prevents overflow) */
  .nav-list .nav-dropdown {
    position: static;
    display: none;
    transform: none;
    width: 100%;
    min-width: 0;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    box-shadow: none;
    background: rgba(0,0,0,0.03);
    padding: 8px 0 8px;
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transition: none;
  }
  /* Suppress hover trigger on mobile */
  .nav-list li:hover .nav-dropdown { display: none; transform: none; }
  /* Show only when parent li has is-expanded (set by click) */
  .nav-list li.is-expanded > .nav-dropdown { display: block; }
  /* Groups: side-by-side if they fit, centered, text left-aligned within */
  .nav-list .nav-groups { flex-direction: row; flex-wrap: wrap; gap: 0; justify-content: center; align-items: flex-start; }
  .nav-list .nav-group { padding: 12px 24px; min-width: 140px; }
  .nav-list .nav-group__heading { font-size: 10px; margin-bottom: 6px; }
  .nav-list .nav-group__list a { font-size: 13px; padding: 5px 0; letter-spacing: 0.02em; text-align: left; display: block; }
  /* Expand/collapse: no text indicator */
  .nav-list > li > a.has-dropdown::after { content: none; }
  .nav-list > li.is-expanded > a.has-dropdown::after { content: none; }
}

/* ────────────────────────────────────────────────────────────
   ≤ 800px — flip to mobile layout
   (matches original site's `min-width: 801px` desktop flip)
   ──────────────────────────────────────────────────────────── */
@media (max-width: 800px) {

  /* Container */
  .container { padding: 0 36px; }

  .mission-banner-img {
    aspect-ratio: 1800 / 650; /* the wide file's own shape; "auto" left no room until it loaded */
    max-height: none;
    height: auto;
    width: 100%;
  }

  /* Category bar — vertical stack */
  .category-bar { height: auto; margin: 16px 0 24px; overflow: visible; padding-top: 10px; padding-left: 0; padding-right: 0; }
  .category-bar__inner {
    flex-direction: column;
    align-items: center;
    gap: 25px;
  }
  .category-bar__label { font-size: 18px; text-align: center; font-family: var(--font-body); text-transform: uppercase; }
  .category-bar__pills {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 12px;
    width: 100%;
  }
  .pill { font-size: 13px; padding: 8px 12px; white-space: normal; text-align: center; line-height: 1.2; }

  /* Split banners — stack and reset the aspect-ratio cap from base rule */
  .split-banners {
    flex-direction: column;
    height: auto;
    aspect-ratio: auto;
    max-height: none;
    gap: 8px;
    margin: 8px 0 48px;
  }
  .split-banner { min-height: 200px; aspect-ratio: auto; }

  /* Mission banner — aspect-ratio in home.css handles scaling */

  /* Product grid: 2-up with gap; add-to-cart always visible (no hover on touch) */
  .product-grid {
    padding: 16px 0 8px;
    margin: 0;
    gap: 16px 16px;
  }
  .product-item { width: calc((100% - 16px) / 2); padding: 0; }
  .container.product-section { padding: 0 32px; }
  .product-figure {
    width: 100%;
    height: auto;
    aspect-ratio: auto;
    max-width: 100%;
    overflow: visible;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    background: transparent;
  }
  /* the light-grey square is the cover link here, so Add to Cart sits under it (as on the Books page);
     min-height 0: without it a tall cover stretches the square */
  .product-cover-link {
    height: auto;
    aspect-ratio: 1 / 1;
    min-height: 0;
    overflow: hidden;
    background: rgb(242, 241, 239);
    padding: 10% 18%;
  }
  .product-figure img {
    width: 100%;
    height: 100%;
    max-width: 100%;
    object-fit: contain;
  }
  .product-title { font-size: 13px; }
  .product-info { padding: 8px 3% 10px; }

  /* Add-to-cart: full-width at bottom of card, black, gap above (no hover on touch) */
  .product-figcaption {
    position: static;
    opacity: 1;
    background: transparent;
    width: 100%;
    transition: none;
    padding: 0;
    margin: 12px 0 0;
  }
  /* a soft-charcoal pill, a little narrower than the card (owner, 19 Nov 2026: option 5, "black may be too harsh") */
  .add-to-cart-btn {
    width: 86%;
    margin: 0 auto;
    padding: 8px 12px;
    font-size: 14px;
    letter-spacing: 0.3px;
    display: block;
    text-align: center;
    background: rgb(62, 62, 62);
    border-color: rgb(62, 62, 62);
    border-radius: 999px;
  }
  .add-to-cart-btn:hover { background: rgb(40, 40, 40); border-color: rgb(40, 40, 40); }
  /* Quick View hidden on mobile — no hover on touch */
  .quick-view-btn { display: none; }

  /* Section tabs — scroll on small screens, scrollbar hidden */
  .section-tabs { overflow-x: auto; scrollbar-width: none; -ms-overflow-style: none; }
  .section-tabs::-webkit-scrollbar { display: none; }
  .tab-link { margin-right: 20px; font-size: 13px; }

  /* Featured authors — section padding matches reference (64px) at all viewports */

  /* SEO copy */
  .seo-copy { padding: 36px 0; }
  .seo-copy__text { max-width: none; }

  /* Section margins */
  .product-section,
  .blog-section { margin: 0 auto 48px; }

  /* ── FOOTER (TMME) — centred (owner, 17 Nov 2026): brand row, then Shop+Browse / Services+Support ── */
  .site-footer { padding: 48px 20px 0; }
  .footer__main {
    grid-template-columns: 1fr 1fr;
    grid-template-areas:
      "brand    brand"
      "shop     browse"
      "services support";
    gap: 40px 24px;
    width: auto;
    max-width: 440px;
    margin: 0 auto;
    text-align: center;
  }
  .footer__brand { grid-area: brand; align-items: center; text-align: center; }
  .footer__nav:nth-of-type(1) { grid-area: shop; }
  .footer__nav:nth-of-type(2) { grid-area: browse; }
  .footer__nav:nth-of-type(3) { grid-area: services; }
  .footer__nav:nth-of-type(4) { grid-area: support; }
  .footer__brand,
  .footer__nav {
    display: flex;
    flex-direction: column;
    align-items: center;
  }
  .footer__logo { margin: 0 auto 16px; }
  .footer__tagline { max-width: 260px; margin: 0 auto; text-wrap: balance; }
  .footer__nav-label { text-align: center; }
  .footer__nav-list { align-items: center; text-align: center; }
  .footer__bar {
    flex-direction: column;
    text-align: center;
    gap: 12px;
    padding: 20px 0;
  }
  .footer__legal-links {
    flex-direction: row;
    justify-content: center;
    flex-wrap: wrap;
    gap: 16px;
  }

  /* Newsletter */
  .newsletter { padding: 40px 16px; }
  .newsletter__form { max-width: 360px; margin-left: auto; margin-right: auto; }
  .newsletter__sub { max-width: 320px; }

  /* Instagram bar — handled in instagram-bar.css; nothing extra needed here */

  /* Features bar */
  .features-bar__inner { grid-template-columns: repeat(3, 1fr); gap: 28px 20px; }

  /* Legacy footer-signup (kept for safety in case any stale page references it) */
  .footer-signup__inner { flex-direction: column; align-items: center; gap: 12px; text-align: center; }
  .footer-signup { height: auto; padding: 20px 16px; }
  .footer-signup__heading,
  .footer-signup__sub { margin: 0; white-space: normal; }
  .footer-signup__form { margin-left: 0; }
  .footer-links__inner { flex-wrap: wrap; gap: 24px; padding: 32px 0 0; }
  .footer-col { flex: 0 0 calc(50% - 12px); padding: 0; text-align: center; }
  .footer-col__list { align-items: center; }
  .footer-social { justify-content: center; }
}

/* ────────────────────────────────────────────────────────────
   ≤ 719px — featured authors: less space under the section
   ──────────────────────────────────────────────────────────── */
@media (max-width: 719px) {
  .featured-authors { padding-bottom: 52px; }
}

/* ────────────────────────────────────────────────────────────
   ≤ 700px — blog stacks to single column
   (original keeps 3-up down to ~700px; below that single col)
   ──────────────────────────────────────────────────────────── */
@media (max-width: 700px) {
  .blog-grid { flex-direction: column; gap: 48px; }
  .dew-more .blog-grid { margin-top: 48px; }
  .blog-card { padding: 0; }
}

/* ────────────────────────────────────────────────────────────
   577px–701px — split banners: explicit aspect ratio
   ──────────────────────────────────────────────────────────── */
@media (min-width: 577px) and (max-width: 701px) {
  .split-banner { aspect-ratio: 1280 / 600; min-height: unset; }
}

/* ────────────────────────────────────────────────────────────
   ≤ 576px — single column, tightest mobile
   ──────────────────────────────────────────────────────────── */
@media (max-width: 576px) {
  .container { padding: 0 12px; }
  .container.blog-section { padding-left: 36px; padding-right: 36px; }

  /* Hero — switch to natural height so portrait mobile crop displays correctly */
  .main-homepage-banner {
    aspect-ratio: auto;
    max-height: none;
    height: auto;
  }
  .main-homepage-banner .swiper-slide { height: auto; }
  .main-homepage-banner .swiper-slide > a { height: auto; }
  .main-homepage-banner picture { height: auto; }
  .hero-img { height: auto; }

  /* Category pills — 3+3 */
  .category-bar__pills { grid-template-columns: repeat(3, 1fr); }

  /* Header */
  .header-body__inner { padding: 10px 40px 10px 50px; gap: 8px; }
  .header-icons { gap: 12px; }

  /* Product grid: stay 2-up but tighter */
  .product-grid { margin: 0; padding: 12px 0 4px; }
  .product-item { padding: 0; }
  .product-figure,
  .product-figure img { max-width: 100%; }
  .product-title { font-size: 12px; line-height: 16px; }
  .product-author { font-size: 12px; line-height: 16px; }

  /* Mid-page banner: the phone file is square (1080x1080); a fixed ratio keeps its room while it loads */
  .mission-banner-img { aspect-ratio: 1 / 1; max-height: none; height: auto; }

  /* Split banners — portrait mobile images (500×600) */
  .split-banner { aspect-ratio: 500 / 600; min-height: unset; }

  /* Section tabs */
  .tab-link { margin-right: 16px; }
  .section-heading-lg { font-size: 14px; margin-bottom: 24px; }
  .blog-section > .blog-section__tabs { margin-bottom: 24px; }

  /* TMME footer — instagram bar collapses to single tile + brand */
  .instagram-bar { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .instagram-bar__item:nth-child(n+2) { display: none; }
  .features-bar__inner { grid-template-columns: 1fr; gap: 24px; }

  /* Legacy footer columns (kept for safety in case any stale page references them) */
  .footer-col { flex: 0 0 100%; }
}

/* ────────────────────────────────────────────────────────────
   ≤ 400px — tiny screens
   ──────────────────────────────────────────────────────────── */
@media (max-width: 400px) {
  .header-icons { gap: 10px; }
  .category-bar__pills { grid-template-columns: repeat(2, 1fr); }
  .pill { padding: 8px 8px; font-size: 12px; }
}

/* ── Blog section bottom padding: must be unlayered and after all media queries so it
   wins source-order over the .container padding shorthand which zeros padding-bottom ── */
.blog-section { padding-bottom: clamp(28px, calc(67px - 4vw), 52px); }
@media (max-width: 900px) {
  .blog-section { padding-bottom: 15px; }
}

/* ── Mobile product carousel (slick) ───────────────────────────
   prod-carousel-desktop  = normal grid, hidden at ≤599px until View More opens the row (two across)
   prod-carousel-mobile   = slick carousel, hidden above 599px
   Unlayered rules here beat the @layer components rules in
   product-card.css without needing !important.
   ─────────────────────────────────────────────────────────── */
.prod-carousel-mobile {
  list-style: none;
  margin: 0;
  padding: 0;
  display: none;
}

@media (max-width: 599px) {
  .prod-carousel-desktop { display: none; }
  .prod-carousel-mobile  { display: block; }
  .prod-carousel-mobile.product-grid--tab-hidden { display: none; }
  .prod-carousel-mobile .product-item--hidden { display: flex; }
  .prod-carousel-mobile .product-item { width: 100%; }
  .container.product-section { padding: 0 8px; margin-bottom: 32px; }
  /* Titles stop after two lines and authors after one, so the cards in a swipe row end at nearly the same height
     and VIEW MORE sits close under every pair (owner, 19 Nov 2026: "the empty space above and after the button is
     too much"). The full title is on the book page. */
  .product-section .product-title { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
  .product-section .product-author { max-width: 100%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  /* Align tab headers with the book picture edges (slides have 10px padding each side) */
  .container.product-section .section-tabs { margin: 0 10px; }
  /* Top/bottom spacing matching .product-grid { padding: 24px 0 8px } */
  .prod-carousel-mobile { padding-top: 24px; padding-bottom: 0; }
  /* 10px per side per slide = 20px gap between adjacent cards (matches desktop grid gap: 20px) */
  .prod-carousel-mobile .slick-slide { padding: 0 10px; }
  /* Arrows: no background, CSS chevron, centered on book image (37%), half-outside image edge (-4px = 10px image-edge minus 14px half-button) */
  .prod-carousel-mobile .slick-prev,
  .prod-carousel-mobile .slick-next {
    background: transparent;
    border: 0;
    -webkit-appearance: none;
    appearance: none;
    top: 37%;
    width: 28px;
    height: 28px;
  }
  .prod-carousel-mobile .slick-prev { left: 2px; z-index: 1; }
  .prod-carousel-mobile .slick-next { right: 2px; z-index: 1; }
  .prod-carousel-mobile .slick-prev:before,
  .prod-carousel-mobile .slick-next:before {
    content: '';
    display: inline-block;
    width: 12px;
    height: 12px;
    border-right: 2px solid #aaa;
    border-top: 2px solid #aaa;
    opacity: 1;
  }
  .prod-carousel-mobile .slick-prev:before { transform: rotate(-135deg); }
  .prod-carousel-mobile .slick-next:before { transform: rotate(45deg); }
}

/* Dropdown list links: higher specificity beats the .nav-list a breakpoint overrides above */
.nav-list .nav-dropdown__list a,
.nav-list .nav-group__list a { font-size: 15px; }

/* Touch screens wider than 800px (a tablet held sideways) have no hover either, so their book
   cards get the phone layout from the 800px block above: Add to Cart under the cover, no Quick View. */
@media (hover: none) and (min-width: 801px) {
  .product-figure {
    height: auto;
    aspect-ratio: auto;
    overflow: visible;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    background: transparent;
  }
  /* the cover in a light-grey square, as in the 800px block, so the cards and their buttons line up; option B's
     margins, the phones' 10% / 18% (owner, 21 Nov 2026: "yes, use option B margins") */
  .product-cover-link { height: auto; aspect-ratio: 1 / 1; min-height: 0; overflow: hidden; background: rgb(242, 241, 239); padding: 10% 18%; }
  .product-figure img {
    width: 100%;
    height: 100%;
    max-width: 100%;
    object-fit: contain;
  }
  .product-figcaption {
    position: static;
    opacity: 1;
    background: transparent;
    width: 100%;
    transition: none;
    padding: 0;
    margin: 12px 0 0;
  }
  /* the same pill as in the 800px block */
  .add-to-cart-btn {
    width: 86%;
    margin: 0 auto;
    padding: 8px 12px;
    font-size: 14px;
    letter-spacing: 0.3px;
    background: rgb(62, 62, 62);
    border-color: rgb(62, 62, 62);
    border-radius: 999px;
  }
  .quick-view-btn { display: none; }
}

/* Phones (owner, 21 Nov 2026: option 6, "same look for 'show less'"): View More, Show Less and Show All are
   round chevron buttons with their name under them. View More opens the swipe row into the row's books two
   across (product-section--expanded, js/product-grid.js); Show Less folds it back. */
@media (max-width: 599px) {
  /* .more-section: the featured authors and Dew Arabia, same buttons (owner, 21 Nov 2026: "change all") */
  .product-section .show-more-prods, .more-section .show-more-prods {
    position: relative; border: 0; border-radius: 0; background: none; color: rgb(62, 62, 62);
    font-size: 11px; letter-spacing: 1.8px; padding: 50px 6px 0; margin: 12px auto 0;
  }
  .product-section .show-more-prods:hover, .more-section .show-more-prods:hover { background: none; }
  .product-section .show-more-prods::before, .more-section .show-more-prods::before {
    content: ''; position: absolute; left: 50%; top: 0; width: 40px; height: 40px; margin-left: -20px;
    border-radius: 50%; border: 1px solid rgb(62, 62, 62); box-sizing: border-box;
  }
  .product-section .show-more-prods::after, .more-section .show-more-prods::after {
    position: absolute; left: 50%; top: 13px; width: 8px; height: 8px; margin-left: -5px;
    border-right-width: 1.5px; border-bottom-width: 1.5px; transform: rotate(45deg);
  }
  .product-section .show-less-prods::after, .more-section .show-less-prods::after { top: 17px; transform: rotate(-135deg); }
  .product-section .show-all-prods::after, .more-section .show-all-prods::after { top: 15px; margin-left: -6px; transform: rotate(-45deg); }
  .product-section .show-after, .more-section .show-after { gap: 36px; }
  .product-section .show-after .show-more-prods, .more-section .show-after .show-more-prods { margin: 12px 0 0; }
  .product-section--expanded .prod-carousel-mobile { display: none; }
  .product-section--expanded .prod-carousel-desktop:not(.product-grid--tab-hidden) { display: flex; }
}
