/* Round 31 (2026-10-31): typography + layout polish from the page-by-page desktop and mobile audit.
   Enqueued after woo-bridge.css. Each block names the component and the defect it corrects;
   values reuse the --v2-* tokens so the apothecary look (Fraunces display, Sora text, navy + mango) is unchanged. */

/* 1. Content pages and posts: one heading scale where H1 > H2 > H3 at every width.
   Before: H2 used clamp(1.7rem, 9vw, 2.45rem), so on a 390px phone a question heading rendered
   at 35px in a 311px column (10-11 characters a line, 4-5 lines), and on desktop H2 outgrew the H1. */
/* Scope: the title block that heads a copy column (page.php, index.php singulars, page-wholesale.php),
   the copy column's own H2s, and the answer capsule. Widget headings nested in sections keep their sizes. */
.v2-route .v2-content-band .store-section-heading:has(+ .v2-copy-stack) h1,
.v2-route .v2-content-band > h1 {
  font-size: clamp(1.72rem, 1.18rem + 2.1vw, 2.6rem);
  line-height: 1.1;
  max-width: var(--v2-h1-copy-column, 43rem);
  text-wrap: balance;
}
.v2-route .v2-content-band .v2-copy-stack > h2 {
  font-size: clamp(1.36rem, 1.06rem + 1.15vw, 1.95rem);
  line-height: 1.16;
  max-width: 32ch;
  margin-bottom: .55em;
  text-wrap: balance;
}
/* The answer capsule restates the page question; it sits in a padded box, so it runs a step smaller.
   The end-of-guide "Questions readers ask" and "Cite this page" panels inherited the same 9vw H2 (35px on
   phones, bigger than the article's own H2s); they take the capsule size too. */
.v2-route .v2-content-band .v2-copy-stack .yaow-answer > h2:not(.yaow-answer__q),
.v2-route .v2-content-band .v2-copy-stack :is(.yaow-asked, .yaow-cite) > h2 {
  font-size: clamp(1.24rem, 1.02rem + .85vw, 1.6rem);
  line-height: 1.18;
  max-width: none;
  text-wrap: balance;
}
.v2-route .v2-content-band .v2-copy-stack > h3 {
  line-height: 1.3;
  margin-bottom: .45em;
  text-wrap: balance;
}

/* 2. Reading rhythm: list items and table cells inherited 1.2 leading while paragraphs use 1.68. */
.v2-route .v2-copy-stack > :is(ul, ol) > li,
.v2-route .v2-copy-stack .yaow-takeaways li,
.v2-route .yaow-answer li {
  line-height: 1.6;
}
.v2-route .v2-copy-stack > :is(ul, ol) > li + li { margin-top: .35em; }
.v2-route :is(.yaow-table, .wp-block-table) :is(td, th) {
  line-height: 1.42;
  vertical-align: top;
}
.v2-route .v2-info-card p + p,
.v2-route .yaow-woo-band .v2-copy-stack .v2-info-card > p + p { margin-top: .75em; }

/* 2b. In-content card rows (Subscribe & Save plans, Contact cards). The contact page's fixed four-track row
   also caught the three subscription plans: three 216px cards beside an empty fourth track, plan text at
   1-3 words a line and two-line buttons. Auto-fit keeps Contact at four across and lets three plans fill. */
@media (min-width: 1041px) {
  .v2-route .yaow-woo-band .v2-copy-stack .v2-seo-cards { grid-template-columns: repeat(auto-fit, minmax(12rem, 1fr)); }
}
.v2-route .v2-copy-stack .v2-info-card .store-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.75rem;
  padding: .55rem 1rem;
  line-height: 1.25;
  text-align: center;
}

/* 3. Wide comparison tables (4+ columns) squeezed each cell to two-word lines on phones and cut the
   price column mid-word. They already scroll sideways; give them a real minimum width and keep the
   "swipe" region obvious with an edge shadow. Two- and three-column spec tables are left alone. */
@media (max-width: 720px) {
  .v2-route .yaow-table table:has(tr > :nth-child(4)) { min-width: 38rem; }
  .v2-route .yaow-table:has(table tr > :nth-child(4)) {
    background:
      linear-gradient(90deg, var(--v2-surface, #fcfffb) 30%, transparent) left / 1.2rem 100% no-repeat local,
      linear-gradient(270deg, var(--v2-surface, #fcfffb) 30%, transparent) right / 1.2rem 100% no-repeat local,
      radial-gradient(farthest-side at 0 50%, rgba(8, 40, 58, .16), transparent) left / .6rem 100% no-repeat scroll,
      radial-gradient(farthest-side at 100% 50%, rgba(8, 40, 58, .16), transparent) right / .6rem 100% no-repeat scroll;
  }
  .v2-route .yaow-table:has(table tr > :nth-child(4)) :is(td, th) { font-size: .88rem; }
}

/* 4. Footer. Mobile gutter was .45rem (8px) against the 18px body gutter; the e-mail address ran
   into the phone number; the "Created by" link was a 44px flex box, which broke the sentence and
   stranded its full stop on its own line; and the 44px legal links wrapped with 1.3rem row gaps. */
@media (max-width: 720px) {
  .v2-route .store-footer { padding-inline: max(1.05rem, env(safe-area-inset-left)) max(1.05rem, env(safe-area-inset-right)); }
}
.v2-route .v2-footer-grid a[href^="mailto:"] { grid-column: 1 / -1; overflow-wrap: anywhere; }
.v2-route .v2-footer-signup > p { font-size: .88rem; line-height: 1.55; }
.v2-route .store-footer-bottom p { font-size: .82rem; line-height: 1.6; }
.v2-route .store-footer-bottom p a {
  display: inline;
  min-height: 0;
  padding: 0;
}
.v2-route .store-footer-bottom nav { row-gap: .1rem; column-gap: 1.1rem; }
@media (min-width: 721px) {
  .v2-route .store-footer-bottom { flex-wrap: wrap; align-items: center; row-gap: .4rem; }
  .v2-route .store-footer-bottom p { flex: 1 1 24rem; max-width: 38rem; }
  .v2-route .store-footer-bottom nav { flex: 0 1 auto; }
}

/* 5. Announcement bar on phones: the notice and the phone link each kept a 44px row, so the bar
   stacked into two loose lines (~73px) above the logo. 32px rows still clear the 24px target size. */
@media (max-width: 480px) {
  .v2-route .v2-topline { row-gap: 0; column-gap: .9rem; }
  .v2-route .v2-topline a { min-height: 2rem; }
}

/* 6. Product cards (shop, categories, related, upsells). On phones the two-column grid left titles
   ~138px wide at 17px, so names broke into 3-4 lines, and the "Seasonally out of stock" badge covered
   half the photo. Desktop: buttons sat at different heights and their labels hugged the left edge. */
.v2-route ul.products li.product { display: flex; flex-direction: column; }
.v2-route ul.products li.product > .button,
.v2-route ul.products li.product > .added_to_cart { margin-top: auto; }
.v2-route ul.products li.product .button { justify-content: center; text-align: center; }
@media (max-width: 600px) {
  .v2-route ul.products li.product { padding: .7rem .65rem .85rem !important; }
  .v2-route ul.products li.product .woocommerce-loop-product__title { font-size: .86rem; line-height: 1.28; }
  .v2-route ul.products li.product .price { font-size: .88rem; }
  .v2-route .yaow-card-badge {
    top: .5rem;
    left: .5rem;
    max-width: calc(100% - 1rem);
    padding: .16rem .45rem;
    font-size: .6rem;
    line-height: 1.25;
  }
}

/* 7. Product page, below the fold: the process steps, quotes, both FAQs and "Goes well with" each had
   their own width and centring (932 / 910 / 459px), so edges jumped and FAQ questions wrapped on
   desktop. One left edge, one column; the two FAQs sit side by side on wide screens. */
@media (min-width: 1041px) {
  .v2-route div.product > :is(.yaow-process, .yaow-quotes, .yaow-pairs, .woocommerce-tabs) {
    width: auto;
    max-width: none;
    margin-inline: 0;
  }
  /* div.product is a two-column grid (gallery | summary): English FAQ under the gallery, Spanish beside it.
     Selector weight matches woo-bridge's ".product.type-product > *:not(...)" full-row rule it overrides. */
  .v2-route .product.type-product > section.yaow-product-faq:not(.woocommerce-product-gallery):not(.summary):not(.yaow-specs) {
    grid-column: 1;
    width: auto;
    max-width: none;
    margin: 2.4rem 0 0;
  }
  .v2-route .product.type-product > section.yaow-product-faq--es:not(.woocommerce-product-gallery):not(.summary):not(.yaow-specs) { grid-column: 2; }
}

/* 8. Section headings that share a row with a "Full catalog" / "Read testimonials" link. On phones the
   link kept its width and the H2 was squeezed to ~10 characters a line ("The flavor / keeps people /
   coming / back."). Below 720px the heading takes the full row and the link drops under it. */
@media (max-width: 720px) {
  .v2-route .store-section-heading:has(> a) { grid-template-columns: minmax(0, 1fr); justify-items: start; row-gap: .55rem; }
  .v2-route .v2-bestseller-grid h3 { font-size: .86rem; line-height: 1.28; }
}

/* 9. Home page, desktop. The hero H1 ran at 4.85vw (70px at 1440) inside a ~470px column: five lines.
   Section headings sat in a centred 889px box while their cards spanned the full band, so headings and
   their "Full catalog" links floated in from the card edges. The subscription promo copy was boxed to
   ~336px (49px H2 over four lines next to empty space). The staggered "What is Seamoss?" cards are a
   deliberate 12-column layout and are left as designed. */
@media (min-width: 1041px) {
  .v2-route .v2-home-hero .store-hero-copy h1 { font-size: clamp(2.6rem, 3.45vw, 3.55rem); line-height: 1.04; }
  .home .v2-route main > section.v2-content-band > .store-section-heading { max-width: none; margin-inline: 0; }
  .v2-route .store-promo--custom { grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); }
  .v2-route .store-promo--custom .store-promo-copy { max-width: 34rem; }
  .v2-route .store-promo--custom .store-promo-copy h2 { font-size: clamp(2.1rem, 2.6vw, 2.7rem); line-height: 1.08; }
  .v2-route .v2-bestseller-grid h3 { font-size: .9rem; line-height: 1.3; }
}

/* 10. Empty-cart "New in store" block: WooCommerce's default dark button background behind the theme's
   navy link colour gave the Add to cart buttons a 1.09:1 contrast ratio (effectively invisible). */
.v2-route .wc-block-grid__product .wp-block-button__link,
.v2-route .wc-block-grid__product .add_to_cart_button {
  background: var(--v2-accent, #e86f1f);
  color: var(--v2-ink-deep, #041d2c);
  border-color: transparent;
}

/* 11. Blog index guide directory: 80 one-line links per page at 1.2 leading. */
.v2-route .yaow-directory li { line-height: 1.45; }

/* 12. Target size (WCAG 2.2, 2.5.8) for standalone small links and the password eye button. */
.v2-route .yaow-takeaways__jump,
.v2-route .product_meta :is(.posted_in, .tagged_as) a {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
}
.woocommerce form .show-password-input,
.woocommerce-page form .show-password-input {
  min-width: 24px;
  min-height: 24px;
}

/* r32 (2026-11-01): self-hosted vertical article video, centred and phone-sized. */
.v2-route .yaow-video--local { max-width: 360px; margin: 1.75rem auto; }
.v2-route .yaow-video--local video { display: block; width: 100%; height: auto; aspect-ratio: 9 / 16; border-radius: 12px; background: #0a2a40; }
.v2-route .yaow-video--local figcaption { text-align: center; }
