/** Shopify CDN: Minification failed

Line 64:54 Unexpected "}"

**/
/* ==========================================================================
   YOJO COLLECTION — Premium Merchandising System
   Uses --yojo-* design tokens from yojo-design-system.css.
   No !important. No hardcoded colors. No hacks.
   ========================================================================== */


/* ---------------------------------------------------------------------------
   1. COLLECTION WRAPPER
   --------------------------------------------------------------------------- */

/* S3-11 / Phase 3 (2026-04-28): joins the page-frame system. Was 1200px max
   with 32px desktop / 16px mobile padding (3 different systems site-wide); now
   1280/64/32/20 mirroring PDP exactly via --yojo-page-* tokens. The
   --yojo-page-pad-x var resolves the breakpoint cascade in design-system.css,
   so no per-breakpoint override needed here. */
.yojo-collection {
  max-width: var(--yojo-page-max-w);
  margin: 0 auto;
  padding-inline: var(--yojo-page-pad-x);
  /* Wave 5 (2026-05-10): bottom padding was 0 → grid butted directly into
     footer with no breathing room. Restored a single section-gap so the
     page reads finished. Top padding still uses --yojo-page-top to keep
     the existing under-header rhythm. */
  padding-block: var(--yojo-page-top) var(--yojo-section-gap);
}


/* ---------------------------------------------------------------------------
   2. CATEGORY NAV (STICKY)
   --------------------------------------------------------------------------- */

.yojo-nav {
  /* D5 audit (Agent 4 / Mobile): was sticky at top:0 z:10 — collided
     with the sticky site header (z:999) and disappeared behind it on
     scroll. Now sticks under the header at 60px, z-index 500 so it sits
     above body content but below any nav dropdown.
     S3-11 / Phase 3: full-bleed margins/paddings re-keyed to
     --yojo-page-pad-x so they always match the wrapper's horizontal track,
     regardless of viewport (token cascade handles the breakpoint switch). */
  position: sticky;
  top: 60px;
  z-index: 500;
  background-color: var(--yojo-bg);
  border-bottom: 1px solid var(--yojo-border);
  margin: 0 calc(-1 * var(--yojo-page-pad-x));
  padding: 0 var(--yojo-page-pad-x);
}
@media (max-width: 767px) {
  .yojo-nav { top: 56px; }
}

/* (S3-11) Mobile @media override removed — full-bleed margin/padding for
   .yojo-nav are now keyed to --yojo-page-pad-x which cascades to 20px at
   <767 via the design-system breakpoint cascade. No per-breakpoint
   override needed.

   PARSE-ERROR LESSON (S3-11b): the original fix above left an unclosed
   inner ruleset (`@media { .yojo-nav { /* comment */ }` missing one `}`).
   That silently consumed the rest of the file as one malformed rule —
   only the first 4 top-level rules of yojo-collection.css were being
   parsed. The .yojo-collection-header__title H1 rule was inside the
   swallowed region and the global h1 clamp won. Fixed by deleting the
   empty wrapper entirely. Always run cssRules.length sanity-check after
   touching @media blocks. */

.yojo-nav__inner {
  display: flex;
  gap: var(--yojo-space-6);
  overflow-x: auto;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
  scroll-snap-type: x proximity;
  padding: var(--yojo-space-3) 0;
}

.yojo-nav__inner::-webkit-scrollbar {
  display: none;
}

/* D55 — pills killed. Flat text tabs. Active = underline, not pill. */
.yojo-nav__pill {
  flex-shrink: 0;
  scroll-snap-align: start;
  padding: 4px 0;
  border-radius: 0;
  background: transparent;
  font-size: 14px;
  font-weight: 400;
  color: #6b6b6b;
  text-decoration: none;
  white-space: nowrap;
  transition: color var(--yojo-duration) var(--yojo-ease);
  border-bottom: 2px solid transparent;
}

.yojo-nav__pill:hover {
  color: #111;
  background: transparent;
}

.yojo-nav__pill--active {
  background: transparent;
  color: #111;
  font-weight: 500;
  border-bottom-color: #111;
}

.yojo-nav__pill--active:hover {
  color: #111;
}


/* ---------------------------------------------------------------------------
   3. COLLECTION HEADER
   --------------------------------------------------------------------------- */

.yojo-header {
  display: flex;
  align-items: baseline;
  gap: var(--yojo-space-3);
  padding: var(--yojo-space-6) 0 var(--yojo-space-4);
}

/* -----------------------------------------------------------------------
   CATEGORY HERO (D5 wave 9 — redesigned)

   Two-column grid: copy left, motif right. Real presence (min-height),
   left-aligned typography, strong kicker + big display title + descriptor
   + meta strip. Per-category tint. Mobile stacks + halves the motif.
   ----------------------------------------------------------------------- */
/* D55 — Erewhon reset: white bg, no pills, no motif, no tinted accents.
   Clean typographic hero. Product photo (collection.image) on the side
   when set; otherwise the hero is copy-only. */
.yojo-cat-hero {
  margin: 0 0 var(--yojo-space-6);
  padding: 0;
  background: transparent;
  border-radius: 0;
  position: relative;
}

.yojo-cat-hero__grid {
  display: grid;
  grid-template-columns: 1.35fr 1fr;
  gap: var(--yojo-space-8);
  align-items: center;
  min-height: 240px;
  padding: var(--yojo-space-8) 0;
}

.yojo-cat-hero__copy {
  text-align: right;
  max-width: 560px;
}

.yojo-cat-hero__title {
  font-size: clamp(32px, 4.2vw, 48px);
  font-weight: 500;
  line-height: 1.08;
  color: #111;
  margin: 0 0 12px;
  letter-spacing: -0.005em;
}

.yojo-cat-hero__descriptor {
  font-size: clamp(15px, 1.2vw, 17px);
  line-height: 1.55;
  color: #6b6b6b;
  margin: 0 0 16px;
  max-width: 500px;
}

.yojo-cat-hero__intro {
  font-size: clamp(14px, 1.05vw, 15px);
  line-height: 1.6;
  color: #3a2f29;
  margin: 0 0 18px;
  max-width: 560px;
}

.yojo-cat-hero__intro p {
  margin: 0;
}

.yojo-cat-hero__meta {
  font-size: 13px;
  color: #6b6b6b;
  margin: 0;
  font-weight: 400;
}

/* Visual column — only renders when collection.image is set */
.yojo-cat-hero__visual {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-radius: 0;
  background: #f4f4f4;
}

.yojo-cat-hero__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

@media (max-width: 767px) {
  .yojo-cat-hero__grid {
    grid-template-columns: 1fr;
    gap: var(--yojo-space-5);
    padding: var(--yojo-space-6) 0 var(--yojo-space-5);
    min-height: 0;
  }
  .yojo-cat-hero__copy {
    order: 1;
    max-width: none;
  }
  .yojo-cat-hero__visual {
    order: 2;
    aspect-ratio: 16 / 9;
    max-height: 180px;
  }
  .yojo-cat-hero__title {
    font-size: 28px;
    line-height: 1.1;
    margin-bottom: 10px;
  }
  .yojo-cat-hero__descriptor {
    font-size: 14px;
    margin-bottom: 12px;
  }
}

.yojo-header__title {
  font-size: var(--yojo-text-lg);
  font-weight: var(--yojo-weight-medium);
  color: var(--yojo-text);
  margin: 0;
  line-height: var(--yojo-leading-tight);
}

.yojo-header__count {
  font-size: var(--yojo-text-sm);
  color: var(--yojo-text-muted);
  white-space: nowrap;
}

@media (max-width: 767px) {
  .yojo-header {
    padding: var(--yojo-space-4) 0 var(--yojo-space-3);
  }

  .yojo-header__title {
    font-size: var(--yojo-text-md);
  }
}


/* ---------------------------------------------------------------------------
   4. BUILDER HERO (COMPACT)
   --------------------------------------------------------------------------- */

.yojo-builder {
  display: flex;
  align-items: center;
  gap: var(--yojo-space-6);
  background-color: var(--yojo-surface);
  border-radius: var(--yojo-radius-md);
  padding: var(--yojo-space-4);
  margin-bottom: var(--yojo-space-6);
  text-decoration: none;
  color: var(--yojo-text);
  max-height: 120px;
  overflow: hidden;
  transition: background-color var(--yojo-duration) var(--yojo-ease);
}

.yojo-builder:hover {
  background-color: var(--yojo-bg-warm);
}

.yojo-builder__image {
  flex-shrink: 0;
  width: 100px;
  height: 100px;
  border-radius: var(--yojo-radius-md);
  overflow: hidden;
}

.yojo-builder__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.yojo-builder__content {
  flex: 1;
  min-width: 0;
}

.yojo-builder__label {
  display: block;
  font-size: var(--yojo-text-xs);
  color: var(--yojo-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: var(--yojo-space-1);
}

.yojo-builder__title {
  font-size: var(--yojo-text-md);
  font-weight: var(--yojo-weight-semibold);
  line-height: var(--yojo-leading-snug);
  margin: 0 0 var(--yojo-space-1);
}

.yojo-builder__desc {
  font-size: var(--yojo-text-sm);
  color: var(--yojo-text-muted);
  line-height: var(--yojo-leading-normal);
  margin: 0 0 var(--yojo-space-2);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.yojo-builder__cta {
  display: inline-flex;
  align-items: center;
  gap: var(--yojo-space-1);
  font-size: var(--yojo-text-sm);
  font-weight: var(--yojo-weight-medium);
  color: var(--yojo-accent-dark);
}

/* RTL: flip the arrow */
html[dir="rtl"] .yojo-builder__cta svg {
  transform: scaleX(-1);
}

@media (max-width: 767px) {
  .yojo-builder {
    gap: var(--yojo-space-4);
    padding: var(--yojo-space-3);
    max-height: 100px;
    margin-bottom: var(--yojo-space-4);
  }

  .yojo-builder__image {
    width: 80px;
    height: 80px;
  }

  .yojo-builder__title {
    font-size: var(--yojo-text-base);
  }

  .yojo-builder__desc {
    display: none;
  }
}


/* ---------------------------------------------------------------------------
   5. FILTER BAR
   --------------------------------------------------------------------------- */

.yojo-filters {
  padding-bottom: var(--yojo-space-4);
  border-bottom: 1px solid var(--yojo-border);
  margin-bottom: var(--yojo-space-6);
}

@media (max-width: 767px) {
  .yojo-filters {
    margin-bottom: var(--yojo-space-4);
  }
}


/* ---------------------------------------------------------------------------
   6. ACTIVE FILTER CHIPS
   --------------------------------------------------------------------------- */

.yojo-active-filters {
  display: flex;
  flex-wrap: wrap;
  gap: var(--yojo-space-2);
  padding-bottom: var(--yojo-space-4);
}

/* D55: active filter chips — flat, not pill. Black text on white with a
   thin border so they read as removable tokens, not colored bubbles. */
.yojo-filter-chip {
  display: inline-flex;
  align-items: center;
  gap: var(--yojo-space-1);
  padding: 4px 10px;
  font-size: 12px;
  font-weight: 400;
  color: #111;
  background-color: #ffffff;
  border: 1px solid #e5e5e5;
  border-radius: 0;
  text-decoration: none;
  transition: border-color var(--yojo-duration) var(--yojo-ease);
}

.yojo-filter-chip:hover {
  background-color: #ffffff;
  border-color: #111;
}

.yojo-filter-chip--clear {
  background-color: var(--yojo-dark);
  color: var(--yojo-dark-text);
}

.yojo-filter-chip--clear:hover {
  opacity: 0.85;
}


/* ---------------------------------------------------------------------------
   7. PRODUCT GRID
   --------------------------------------------------------------------------- */

.yojo-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  /* Wave 1.1 2026-04-19: tokenized to new Erewhon-parity grid gap scale
     (assets/yojo-tokens.css --grid-gap-*). Desktop 32px (was --yojo-space-6 = 24px).
     Column counts not changed in Wave 1.1 — columns belong to Wave 2 grid redesign. */
  gap: var(--grid-gap-desktop, 32px);
}

@media (max-width: 1023px) {
  .yojo-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: var(--grid-gap-tablet, 32px);
  }
}

@media (max-width: 767px) {
  .yojo-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: var(--grid-gap-mobile, 16px);
  }
}

.yojo-grid__empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: var(--yojo-space-16) 0;
  color: var(--yojo-text-muted);
  font-size: var(--yojo-text-base);
}

.yojo-link {
  color: var(--yojo-accent-dark);
  text-decoration: underline;
  text-underline-offset: 3px;
}


/* ---------------------------------------------------------------------------
   8. PRODUCT CARD
   --------------------------------------------------------------------------- */

/* D55 — Erewhon reset: white image bg, no borders, no hover lift, black
   text and price, cards stretch equal heights so ATC button aligns. */
.yojo-card {
  position: relative;
  display: flex;
  flex-direction: column;
  background: transparent;
}

.yojo-card__image {
  display: block;
  position: relative;
  border-radius: 0;
  border: none;
  overflow: hidden;
  background-color: #ffffff;
  transition: opacity 200ms ease;
}

/* D57 (2026-04-23): hover dim removed. Hover state = rest state. */
.no-touchevents .yojo-card:hover .yojo-card__image {
  transform: none;
  opacity: 1;
}

.yojo-card__image img,
.yojo-card__image .lazy-image img {
  transition: none;
}

.no-touchevents .yojo-card:hover .yojo-card__image img,
.no-touchevents .yojo-card:hover .yojo-card__image .lazy-image img {
  transform: none;
}

.yojo-card__image .lazy-image img {
  object-fit: contain;
}

.yojo-card__placeholder {
  width: 100%;
  aspect-ratio: 4 / 5;
  background-color: #f4f4f4;
  border-radius: 0;
}

.yojo-card__info {
  padding: var(--yojo-space-3) 0 0;
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
}

.yojo-card__vendor {
  display: block;
  font-size: var(--card-vendor-fs, 11px);
  line-height: var(--card-vendor-lh, 1.2);
  font-weight: 400;
  color: #6b6b6b;
  margin-bottom: 4px;
  text-transform: none;
  opacity: 1;
  /* Phase 3 D11: reserve the vendor row even when product.vendor is blank,
     so the grid rhythm is uniform across mixed content. */
  min-height: var(--card-vendor-min-h, 1.45em);
}

.yojo-card__title {
  /* Wave 1.1: all typographic properties (color, font-size, font-weight,
     line-height) are inherited from yojo-design-system.css .yojo-card__title
     rules. This file only retains layout-level concerns (line-clamp,
     margin, min-height, text-decoration). Keeping typography here caused
     @media breakpoint conflicts because yojo-collection.css loads after
     design-system.css and has no mobile override of its own. */
  text-decoration: none;
  margin-bottom: var(--yojo-space-1);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: var(--card-title-min-h, 2.8em);
}

.yojo-card__price {
  /* Wave 1.1: typography fully inherited from yojo-design-system.css.
     Local rules retained: layout (margin, min-height), tabular-nums, line-height
     reservation for the per-unit row. */
  margin-bottom: var(--yojo-space-2);
  font-variant-numeric: tabular-nums;
  min-height: var(--card-price-min-h, 2.36em);
}

/* P7-007 audit wave D1: per-unit price should sit on its own line under
   the main price on category tiles, not inline beside it. */
.yojo-card__price .product-price--unit {
  display: block;
  padding-inline-start: 0 !important;
  opacity: 0.62;
  font-size: 80%;
  margin-top: 0.125rem;
  font-weight: var(--yojo-weight-regular, 400);
}

/* D55: margin-top:auto pushes ATC to the card bottom so rows stay
   aligned even when titles wrap to different line counts. */
.yojo-card__action {
  margin-top: auto;
  padding-top: var(--yojo-space-2);
}

/* Phase 3 Step 6: .yojo-card__buy-btn retired. Markup now passes
   button_classes: 'button--small' to quick-buy, so the unified pill
   variant defined in yojo-design-system.css owns the visuals. */

.yojo-card__sold-out {
  display: block;
  text-align: center;
  font-size: var(--yojo-text-xs);
  color: var(--yojo-text-light);
  padding: var(--yojo-space-2) 0;
}

/* First-row emphasis (subtle, Erewhon-aligned): weight-only bump, no size override.
   Wave 1.1 2026-04-19: dropped `font-size: var(--yojo-text-base)` and
   replaced semibold (600) with medium (500) so emphasized cards stay in the
   same grid rhythm as non-emphasized ones. */
.yojo-card--emphasize .yojo-card__title {
  font-weight: 500;
}

/* Wave 3F: Erewhon-style hover is image-only crossfade (handled in
   yojo-design-system.css Wave 1). Remove the whole-card opacity dim —
   Erewhon keeps the card at full opacity while the secondary image
   crossfades underneath. */

/* Scroll reveal animation — consolidated to motion tokens */
.yojo-card {
  opacity: 0;
  transform: translateY(16px);
  transition:
    opacity var(--motion-duration-slow, 500ms) var(--motion-ease, cubic-bezier(0.25, 1, 0.5, 1)),
    transform var(--motion-duration-slow, 500ms) var(--motion-ease, cubic-bezier(0.25, 1, 0.5, 1));
}

.yojo-card.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* Wave 3F: stagger extended to 12 cards (3 rows × 4 cols) so a full
   above-the-fold screen reveals in a cascade. After 12 cards, everything
   reveals simultaneously — users don't notice beyond the first screen. */
.yojo-card:nth-child(1)  { transition-delay: 0s; }
.yojo-card:nth-child(2)  { transition-delay: 0.05s; }
.yojo-card:nth-child(3)  { transition-delay: 0.10s; }
.yojo-card:nth-child(4)  { transition-delay: 0.15s; }
.yojo-card:nth-child(5)  { transition-delay: 0.20s; }
.yojo-card:nth-child(6)  { transition-delay: 0.25s; }
.yojo-card:nth-child(7)  { transition-delay: 0.30s; }
.yojo-card:nth-child(8)  { transition-delay: 0.35s; }
.yojo-card:nth-child(9)  { transition-delay: 0.40s; }
.yojo-card:nth-child(10) { transition-delay: 0.45s; }
.yojo-card:nth-child(11) { transition-delay: 0.50s; }
.yojo-card:nth-child(12) { transition-delay: 0.55s; }

/* No-JS fallback */
.no-js .yojo-card {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  .yojo-card {
    opacity: 1;
    transform: none;
    transition: none;
  }
}


/* ---------------------------------------------------------------------------
   9. LOAD MORE
   --------------------------------------------------------------------------- */

.yojo-load-more {
  display: flex;
  justify-content: center;
  padding: var(--yojo-space-10) 0 var(--yojo-space-6);
}

.yojo-load-more__btn {
  padding: var(--yojo-space-3) var(--yojo-space-8);
  font-size: var(--yojo-text-sm);
  font-weight: var(--yojo-weight-medium);
  color: var(--yojo-text);
  background: transparent;
  border: 1px solid var(--yojo-border-strong);
  border-radius: var(--yojo-radius-md);
  cursor: pointer;
  transition: border-color var(--yojo-duration) var(--yojo-ease),
              color var(--yojo-duration) var(--yojo-ease);
}

.yojo-load-more__btn:hover {
  border-color: var(--yojo-text);
}

.yojo-load-more__btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.yojo-load-more--hidden {
  display: none;
}


/* ---------------------------------------------------------------------------
   10. RTL OVERRIDES
   --------------------------------------------------------------------------- */

html[dir="rtl"] .yojo-header {
  flex-direction: row;
}

html[dir="rtl"] .yojo-nav__inner {
  direction: rtl;
}

html[dir="rtl"] .yojo-card__info {
  text-align: right;
}


/* ---------------------------------------------------------------------------
   11. CLEANUP (2026-04-16)
   Hide duplicate product count printed by facets snippet.
   The count already appears in .yojo-header__count.
   --------------------------------------------------------------------------- */

.yojo-collection #CollectionProductCount,
.yojo-collection .section-heading--facets .collection-product-count,
.yojo-collection .section-heading--facets .section-heading__text {
  display: none !important;
}


/* ============================================================================
   WAVE 2.0 + 2.1 — COMPACT COLLECTION HEADER (2026-04-19)

   Replaces the killed yojo-category-hero + yojo-starter-shelf stack on
   collection pages. Single compact block: H1 + meta + sort inline.

   Target desktop pre-grid shell height: ~160 px (vs 1031 px pre-Wave-2).
   Source: design/wave2-spec-2026-04-19.md Option A.
   ============================================================================ */

.yojo-collection-header {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--collection-header-gap, 12px);
  /* S3-11: top breathing room moved up to .yojo-collection wrapper (page-frame
     pattern). Inner header keeps a tight 16px below the H1 line. */
  padding: 0 0 var(--yojo-space-4, 16px);
  margin: 0;
  border: 0;
  background: transparent;
}

.yojo-collection-header__copy {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: var(--yojo-space-2, 8px);
}

/* S3-11b: specificity bump from .yojo-collection-header__title (0,1,0) to
   .yojo-collection .yojo-collection-header__title (0,2,0) so this rule beats
   the global `h1, h1.h1, h1.h2, h1.h3 { font-size: clamp(26px, 3.6vw, 38px) }`
   declaration in yojo-design-system.css :416 (which has effective specificity
   (0,1,1) for this element via the `h1.h2` arm of the comma list — wait, no:
   the H1 here only matches `h1` alone (0,0,1). But empirically the clamp
   was winning at 38px. Bumping to (0,2,0) eliminates any specificity
   ambiguity from selector-list resolution edge cases). */
.yojo-collection .yojo-collection-header__title {
  margin: 0;
  padding: 0;
  font-size: var(--collection-header-title-fs-desktop);
  font-weight: var(--collection-header-title-fw);
  line-height: var(--collection-header-title-lh);
  letter-spacing: var(--yojo-page-h1-tracking);
  color: var(--collection-header-title-color, var(--color-ink, #212121));
}

.yojo-collection-header__meta {
  margin: 0;
  font-size: var(--collection-header-meta-fs, 13px);
  line-height: var(--collection-header-meta-lh, 1.4);
  color: var(--collection-header-meta-color, var(--color-ink-mute, #636262));
  font-weight: 400;
}

.yojo-collection-header__description {
  margin: 0;
  max-width: 640px;
  font-size: 15px;
  line-height: 1.5;
  color: var(--color-ink, #212121);
  font-weight: 400;
  /* Clamp long legacy collection.description content (e.g. paletas @ 692 chars)
     to 3 lines max to keep the header Erewhon-compact. Full description
     still available on the collection via SEO meta + rich text will render
     everywhere else the body_html is consumed. */
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Flatten the rich-text nested paragraphs/lists into inline display so
   the line-clamp measures lines consistently regardless of HTML structure. */
.yojo-collection-header__description p,
.yojo-collection-header__description ul,
.yojo-collection-header__description ol,
.yojo-collection-header__description li {
  display: inline;
  margin: 0;
  padding: 0;
  list-style: none;
}

.yojo-collection-header__description p:not(:last-child)::after,
.yojo-collection-header__description li:not(:last-child)::after {
  content: ' ';
}

.yojo-collection-header__description strong {
  font-weight: 500;
}

@media (max-width: 767px) {
  .yojo-collection-header__description {
    font-size: 14px;
    line-height: 1.45;
    -webkit-line-clamp: 2;
    line-clamp: 2;
  }
}

.yojo-collection-header__sort {
  flex: 0 0 auto;
}

@media (max-width: 767px) {
  .yojo-collection-header {
    /* S3-11: top breathing room moved to .yojo-collection wrapper. Inner header
       keeps a 12px below the H1 line for the meta row. */
    padding: 0 0 var(--yojo-space-3, 12px);
    align-items: stretch;
  }
  .yojo-collection .yojo-collection-header__title {
    /* Mobile cascade — --yojo-page-h1-size resolves to 28px at <767 via
       the design-system breakpoint cascade, and the legacy
       --collection-header-title-fs-mobile token now points to the same
       --yojo-page-h1-size (set in yojo-tokens.css). */
    font-size: var(--collection-header-title-fs-mobile);
  }
  .yojo-collection-header__sort {
    margin-top: var(--yojo-space-3, 12px);
    width: 100%;
  }
}


/* ============================================================================
   WAVE 2.2 — TOOLBAR ROW (snippets/yojo-collection-toolbar.liquid)

   Erewhon 1:1 single-row filter + sort toolbar bounded by hairline rules
   above and below. Both buttons are 13 px text-buttons with a vertical
   divider between them. Works identically at every viewport.
   ============================================================================ */

.yojo-toolbar {
  position: relative; /* anchor point for the sort dropdown panel */
  z-index: 20;        /* sit above grid stacking contexts (grid cards have their own transform context from stagger reveal) */
  display: flex;
  align-items: stretch;
  justify-content: space-between;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--color-gray-line, #D1CDC4);
  border-bottom: 1px solid var(--color-gray-line, #D1CDC4);
  background: var(--color-paper, #FCFBF9);
}

.yojo-toolbar__divider {
  flex: 0 0 auto;
  width: 1px;
  background: var(--color-gray-line, #D1CDC4);
}

.yojo-toolbar__btn {
  flex: 1 1 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 20px 16px;
  min-height: 56px;
  margin: 0;
  background: transparent;
  border: 0;
  border-radius: 0;
  font-family: inherit;
  font-size: 13px;
  font-weight: 400;
  line-height: 1;
  letter-spacing: 0.02em;
  color: var(--color-ink, #212121);
  text-transform: uppercase;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  transition: background var(--motion-duration, 180ms) var(--motion-ease, ease-out),
              color var(--motion-duration, 180ms) var(--motion-ease, ease-out);
}

.yojo-toolbar__btn:hover,
.yojo-toolbar__btn:focus-visible {
  background: rgba(0, 0, 0, 0.03);
}

.yojo-toolbar__btn:focus-visible {
  outline: 2px solid rgba(0, 0, 0, 0.6);
  outline-offset: -2px;
}

.yojo-toolbar__icon {
  flex: 0 0 auto;
  color: currentColor;
}

.yojo-toolbar__btn-label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.yojo-toolbar__count {
  display: inline-block;
  min-width: 18px;
  padding: 1px 5px;
  font-size: 11px;
  line-height: 1;
  background: var(--color-ink, #212121);
  color: var(--color-paper, #FCFBF9);
  border-radius: 999px;
  font-weight: 500;
}

@media (min-width: 1024px) {
  .yojo-toolbar__btn {
    padding: 23px 50px;
  }
}

/* ============================================================================
   WAVE 2.2 — SORT DISCLOSURE (<details> + <summary>)

   Replaces Wave 2.1's native <select>. Custom disclosure dropdown that
   matches Erewhon's "SORT BY ▾" pattern. Fade + slide-down panel
   animation on open. Zero JS.
   ============================================================================ */

.yojo-sort {
  position: relative;
  flex: 1 1 50%;
  display: flex;
  align-items: stretch;
  margin: 0;
}

.yojo-sort summary {
  list-style: none;
}

.yojo-sort summary::-webkit-details-marker,
.yojo-sort summary::marker {
  display: none;
  content: '';
}

.yojo-sort__trigger {
  flex: 1 1 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 20px 16px;
  min-height: 56px;
  font-family: inherit;
  font-size: 13px;
  font-weight: 400;
  line-height: 1;
  letter-spacing: 0.02em;
  color: var(--color-ink, #212121);
  text-transform: uppercase;
  cursor: pointer;
  user-select: none;
  outline: 0;
  transition: background var(--motion-duration, 180ms) var(--motion-ease, ease-out);
}

.yojo-sort__trigger:hover,
.yojo-sort[open] .yojo-sort__trigger {
  background: rgba(0, 0, 0, 0.03);
}

.yojo-sort__trigger:focus-visible {
  outline: 2px solid rgba(0, 0, 0, 0.6);
  outline-offset: -2px;
}

.yojo-sort__trigger-label {
  display: inline-block;
}

.yojo-sort__chevron {
  flex: 0 0 auto;
  transition: transform var(--motion-duration, 180ms) var(--motion-ease, ease-out);
  color: currentColor;
}

.yojo-sort[open] .yojo-sort__chevron {
  transform: rotate(180deg);
}

@media (min-width: 1024px) {
  .yojo-sort__trigger {
    padding: 23px 50px;
  }
}

/* Dropdown panel — positions below the trigger. Fade + slide-down entry. */
.yojo-sort__panel {
  position: absolute;
  top: 100%;
  inset-inline-end: 0;
  min-width: 220px;
  max-width: min(320px, calc(100vw - 32px));
  margin: 0;
  padding: var(--yojo-space-2, 8px) 0;
  background: var(--color-paper, #FCFBF9);
  border: 1px solid var(--color-gray-line, #D1CDC4);
  border-radius: var(--radius-sm, 3px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
  /* High z-index so the panel always stacks above the grid cards, whose
     transform (stagger reveal) creates its own stacking context. */
  z-index: 1000;
  transform-origin: top right;
  animation: yojo-sort-panel-in 180ms cubic-bezier(0.25, 1, 0.5, 1);
}

html[dir="rtl"] .yojo-sort__panel {
  transform-origin: top left;
}

@keyframes yojo-sort-panel-in {
  from { opacity: 0; transform: translateY(-6px); }
  to   { opacity: 1; transform: translateY(0); }
}

.yojo-sort__list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.yojo-sort__item {
  margin: 0;
  padding: 0;
}

.yojo-sort__option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 16px;
  font-size: 14px;
  line-height: 1.3;
  color: var(--color-ink, #212121);
  text-decoration: none;
  text-transform: none;
  letter-spacing: 0;
  /* Wave 3E: explicit font-weight 400 to override theme.css global
     anchor-weight rules that were cascading to 600 on sort options. */
  font-weight: 400;
  transition: background var(--motion-duration, 180ms) var(--motion-ease, ease-out);
}

.yojo-sort__option .yojo-sort__option-label {
  font-weight: 400;
}

.yojo-sort__option:hover,
.yojo-sort__option:focus-visible {
  background: rgba(0, 0, 0, 0.04);
  text-decoration: none;
}

.yojo-sort__option.is-active,
.yojo-sort__option.is-active .yojo-sort__option-label {
  /* Active state is signified by the checkmark icon, not by weight. */
  font-weight: 400;
}

.yojo-sort__check {
  flex: 0 0 auto;
  color: var(--color-ink, #212121);
}

.yojo-sort__option-label {
  flex: 1 1 auto;
}

/* ============================================================================
   WAVE 2.2 — HIDE LEGACY YOJO-NAV + FACETS-TOP-BAR

   yojo-nav sticky category pills row is no longer rendered on collection
   pages (Erewhon has no equivalent). The `.yojo-collection` wrapper-scoped
   hide is reversible in one line.

   The old .yojo-filters wrapper is kept only for the facets drawer content
   (triggered by yojo-toolbar filter button via data-js-sidebar-handle).
   The top-bar visible parts of that wrapper are hidden.
   ============================================================================ */

.yojo-collection .yojo-nav {
  display: none !important;
}

/* ============================================================================
   WAVE 3D — FILTER DRAWER (<dialog id="yojo-filter-dialog">)

   Native <dialog> opened by the toolbar filter button via showModal().
   Slide-in from inline-end (right in LTR, left in RTL). Backdrop fades in.
   Close on: backdrop click, ESC (native), or [data-yojo-filter-close] click.

   ::backdrop + dialog geometry use logical properties so RTL works
   automatically without a separate selector.
   ============================================================================ */

.yojo-filter-dialog {
  /* Override browser defaults so we can position as a side drawer. */
  margin: 0;
  padding: 0;
  width: min(420px, 92vw);
  max-width: 100%;
  height: 100vh;
  max-height: 100vh;
  border: 0;
  background: var(--color-paper, #FCFBF9);
  color: var(--color-ink, #212121);
  overflow: hidden;
  /* Pin to the inline-end edge (right LTR / left RTL). */
  position: fixed;
  inset-block: 0;
  inset-inline-end: 0;
  inset-inline-start: auto;
}

/* Closed state — keep off-screen on inline-end so the open transition
   slides in cleanly. Note: browsers don't animate display:none → block,
   so we use [open] presence to trigger the animation instead of closed
   state styling. */
.yojo-filter-dialog[open] {
  animation: yojo-filter-dialog-in 280ms var(--motion-ease, cubic-bezier(0.25, 1, 0.5, 1));
}

.yojo-filter-dialog::backdrop {
  background: rgba(0, 0, 0, 0.5);
  animation: yojo-filter-backdrop-in 240ms var(--motion-ease, ease-out);
}

@keyframes yojo-filter-dialog-in {
  from { transform: translateX(100%); opacity: 0.85; }
  to   { transform: translateX(0); opacity: 1; }
}
html[dir="rtl"] .yojo-filter-dialog[open] {
  animation-name: yojo-filter-dialog-in-rtl;
}
@keyframes yojo-filter-dialog-in-rtl {
  from { transform: translateX(-100%); opacity: 0.85; }
  to   { transform: translateX(0); opacity: 1; }
}

@keyframes yojo-filter-backdrop-in {
  from { opacity: 0; }
  to   { opacity: 1; }
}

/* Prevent body scroll while dialog is open (native dialog blocks tab
   but not scroll — this class is toggled by the toolbar JS). */
html.yojo-filter-dialog-open,
html.yojo-filter-dialog-open body {
  overflow: hidden;
}

/* Inner panel — 3-row layout: head / body (scrollable) / spacer */
.yojo-filter-dialog__panel {
  display: flex;
  flex-direction: column;
  height: 100%;
  max-height: 100vh;
}

.yojo-filter-dialog__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  border-bottom: 1px solid var(--color-gray-line, #D1CDC4);
  flex: 0 0 auto;
}

.yojo-filter-dialog__title {
  margin: 0;
  font-size: 16px;
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--color-ink, #212121);
}

.yojo-filter-dialog__close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  padding: 0;
  margin: 0;
  background: transparent;
  border: 0;
  border-radius: 0;
  color: var(--color-ink, #212121);
  cursor: pointer;
  transition: background var(--motion-duration, 180ms) var(--motion-ease, ease-out);
}

.yojo-filter-dialog__close:hover,
.yojo-filter-dialog__close:focus-visible {
  background: rgba(0, 0, 0, 0.05);
  outline: none;
}

.yojo-filter-dialog__close:focus-visible {
  outline: 2px solid rgba(0, 0, 0, 0.6);
  outline-offset: -2px;
}

.yojo-filter-dialog__body {
  flex: 1 1 auto;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 20px 24px 40px;
}

/* Restyle the inherited facets markup inside the dialog so it matches
   Erewhon's filter-list look (accordion-ish, checkbox rows). The facets
   snippet emits a lot of legacy Krown chrome — neutralize the visual
   top-bar bits that would show inline, keep the actual form controls. */
.yojo-filter-dialog__body .section-heading--facets,
.yojo-filter-dialog__body #collection-filters-handle,
.yojo-filter-dialog__body .collection-filters__inner,
.yojo-filter-dialog__body .facets__inner {
  display: none !important;
}

.yojo-filter-dialog__body facet-filters-form,
.yojo-filter-dialog__body .facets,
.yojo-filter-dialog__body form.facets__form {
  display: block !important;
  width: 100%;
}

/* Facet group: label above, expand on click. Legacy markup uses <details>
   for expandable groups — works for us as-is. */
.yojo-filter-dialog__body details {
  border-bottom: 1px solid var(--color-gray-line, #D1CDC4);
  padding: 14px 0;
}

.yojo-filter-dialog__body details > summary {
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--color-ink, #212121);
  padding: 6px 0;
  user-select: none;
}

.yojo-filter-dialog__body details > summary::-webkit-details-marker,
.yojo-filter-dialog__body details > summary::marker {
  display: none;
  content: '';
}

.yojo-filter-dialog__body details[open] > summary::after,
.yojo-filter-dialog__body details:not([open]) > summary::after {
  content: '+';
  font-weight: 400;
  font-size: 18px;
  line-height: 1;
  color: var(--color-ink-mute, #636262);
}
.yojo-filter-dialog__body details[open] > summary::after {
  content: '−';
}

.yojo-filter-dialog__body details > *:not(summary) {
  padding-top: 10px;
}

/* Checkbox rows */
.yojo-filter-dialog__body input[type="checkbox"] + label,
.yojo-filter-dialog__body label {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  font-weight: 400;
  line-height: 1.3;
  color: var(--color-ink, #212121);
  padding: 6px 0;
  cursor: pointer;
}

/* Mobile: full-width dialog */
@media (max-width: 767px) {
  .yojo-filter-dialog {
    width: 100vw;
    max-width: 100vw;
  }
  .yojo-filter-dialog__head {
    padding: 16px 20px;
  }
  .yojo-filter-dialog__body {
    padding: 16px 20px 32px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .yojo-filter-dialog[open] { animation: none; }
  .yojo-filter-dialog::backdrop { animation: none; }
}

/* ============================================================================
   WAVE 3F — COLLECTION HEADER + TOOLBAR ENTRY ANIMATION

   Small fade-up on initial page load so the shell feels animated-in,
   matching Erewhon's gentle entry motion. Uses CSS-only animation
   triggered by the element's presence (not a class toggle) — zero JS.

   Respects prefers-reduced-motion.
   ============================================================================ */

@media (prefers-reduced-motion: no-preference) {
  .yojo-collection-header {
    animation: yojo-fade-up 380ms var(--motion-ease, cubic-bezier(0.25, 1, 0.5, 1)) both;
  }

  .yojo-toolbar {
    animation: yojo-fade-up 380ms var(--motion-ease, cubic-bezier(0.25, 1, 0.5, 1)) 80ms both;
  }
}

@keyframes yojo-fade-up {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Load-more button: subtle hover/press states matching Erewhon's
   restrained interactive feedback. */
.yojo-load-more__btn {
  transition:
    background var(--motion-duration, 180ms) var(--motion-ease, ease-out),
    color var(--motion-duration, 180ms) var(--motion-ease, ease-out),
    border-color var(--motion-duration, 180ms) var(--motion-ease, ease-out),
    transform var(--motion-duration, 180ms) var(--motion-ease, ease-out);
}

.yojo-load-more__btn:hover {
  background: var(--color-ink, #212121);
  color: var(--color-paper, #FCFBF9);
  border-color: var(--color-ink, #212121);
}

.yojo-load-more__btn:active {
  transform: scale(0.985);
}

