/* Scoped to the optional category landing; the existing page background stays intact. */
.shop-category-logo {
  display: block;
  width: min(420px, calc(100% - 48px));
  height: auto;
  margin: 26px auto 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  object-fit: contain;
}
.shop-category-landing {
  --category-gap: 22px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--category-gap);
  width: min(900px, calc(100% - 36px));
  margin: 28px auto 48px;
}
.shop-category-logo[hidden],
.shop-category-landing[hidden],
#products[hidden],
#recently-viewed[hidden],
#products [data-category-landing-hidden] { display: none !important; }
.shop-category-card {
  display: flex;
  flex-direction: column;
  min-width: 0;
  padding: 12px;
  border: 1px solid #edcecd;
  border-radius: 22px;
  background: #fff9f5;
  box-shadow: 0 7px 22px rgb(174 108 119 / 8%);
  color: #ad5058;
  text-decoration: none;
  transition: box-shadow .18s ease, border-color .18s ease;
}
.shop-category-card:last-child {
  grid-column: 1 / -1;
  justify-self: center;
  width: calc((100% - var(--category-gap)) / 2);
}
.shop-category-card:hover { border-color: #cc99ad; box-shadow: 0 9px 26px rgb(174 108 119 / 15%); }
.shop-category-card:focus-visible { outline: 3px solid #a371ae; outline-offset: 5px; }
.shop-category-heading {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 78px;
  margin: 0;
  padding: 5px 10px 12px;
  font-family: Georgia, 'Times New Roman', serif;
  font-size: clamp(19px, 2.25vw, 26px);
  font-weight: 700;
  line-height: 1.2;
  text-align: center;
  text-transform: uppercase;
  overflow-wrap: anywhere;
}
.shop-category-photo {
  display: block;
  width: 100%;
  aspect-ratio: 1.6;
  overflow: hidden;
  border-radius: 15px;
  background: #f4ede7;
}
.shop-category-photo img { display: block; width: 100%; height: 100%; object-fit: contain; }
@media (max-width: 580px) {
  .shop-category-landing { grid-template-columns: minmax(0, 1fr); gap: 16px; width: calc(100% - 28px); margin-top: 22px; }
  .shop-category-card:last-child { grid-column: auto; width: 100%; }
  .shop-category-heading { min-height: 70px; font-size: 22px; }
}
@media (prefers-reduced-motion: reduce) { .shop-category-card { transition: none; } }

/* Soft pink title boxes, using the existing category links and photos. */
.shop-category-heading { box-sizing: border-box; min-height: 76px; margin: 0 0 12px; padding: 12px 16px; border: 1px solid #e5c5d5; border-radius: 14px; background: linear-gradient(135deg,#fff9fc,#faedf4); color: #78445f; font-weight: 500; line-height: 1.3; letter-spacing: .01em; text-transform: none; overflow-wrap: break-word; text-wrap: balance; }
.shop-category-card:focus-visible { outline-color: #9b567e; }
@media(max-width:580px){.shop-category-heading{min-height:66px;padding:12px 14px;font-size:21px;}}

/* Compact headings only; category photographs keep their existing size. */
.shop-category-heading { width: fit-content; min-width: 60%; max-width: 100%; min-height: 46px; margin: 0 auto 7px; padding: 7px 10px; border-radius: 9px; font-size: clamp(13px,1.35vw,16px); }
@media(max-width:580px){.shop-category-heading{min-height:40px;padding:7px 9px;font-size:13px;}}

/* Approved desktop-only category heading size, plus ten percent. */
@media(min-width:1024px){.shop-category-heading{min-width:66%;min-height:50.6px;padding:7.7px 11px;border-radius:9.9px;font-size:clamp(14.3px,1.485vw,17.6px);}}

/* New Arrivals card shares the same confirmed presence state as Offer. */
.shop-category-card[aria-disabled="true"] { cursor: not-allowed; opacity: .48; box-shadow: none; }
.shop-category-card[data-offer-availability="pending"] { cursor: progress; opacity: 1; }

/* Original homepage sections: one full-width section per row. */
.shop-category-landing{grid-template-columns:minmax(0,1fr);width:min(1100px,calc(100% - 36px));gap:48px}
.shop-category-landing>[data-shop-feature]{width:100%;margin:0 auto;min-width:0}
/* Keep the existing New Arrivals card at its previous responsive width. */
.shop-category-landing>.shop-category-card:last-child{width:calc((min(900px,100vw - 36px) - 22px)/2)}
@media(max-width:580px){.shop-category-landing{width:calc(100% - 28px);gap:32px}.shop-category-landing>.shop-category-card:last-child{width:100%}}

/* Owner-requested uniform 20% reduction of all five Shop landing cards. */
#shop-categories>[data-shop-feature]{width:min(1100px,calc(100vw - 36px));zoom:.8}
#shop-categories>.shop-category-card:last-child{zoom:.8}
@media(max-width:580px){#shop-categories>[data-shop-feature],#shop-categories>.shop-category-card:last-child{width:calc(100vw - 28px)}}

/* Static first paint: category content stays hidden on direct live-product routes. */
html:not([data-shop-entry-home]) #shop-categories,html:not([data-shop-entry-home]) .shop-category-logo{display:none!important}
