/* Mini Stores 600 — header families, footer families, quality contract */

/* Content is visible without waiting for reveal JS */
body.sg-mini-store .ml-reveal,
body.sg-mini-store .ml-home-hero-copy,
body.sg-mini-store .ml-home-hero-media-frame {
  opacity: 1 !important;
  transform: none !important;
}

body[data-mini-program="1"] .ml-h2,
body[data-mini-program="1"] .ml-best h2,
body[data-mini-program="1"] [data-key="ml_best_h2"] {
  color: var(--text-dark, var(--store-text, inherit)) !important;
  opacity: 1 !important;
}
body[data-mini-program="1"] .ms-hero .ml-home-hero-media-img.is-empty {
  display: none !important;
}
body[data-mini-program="1"] .ms-hero-fallback {
  z-index: 1;
}
body[data-mini-program="1"] .ms-hero .ml-home-hero-media,
body[data-mini-program="1"] .ms-hero .ml-home-hero-media-frame {
  position: relative;
  min-height: min(62vh, 560px);
}
body.sg-mini-store .ml-home-hero .ml-btn--primary,
body.sg-mini-store .ml-home-hero a.ml-btn--primary {
  background: var(--store-primary, var(--text-dark, #111)) !important;
  color: #fff !important;
  border: 0 !important;
  text-decoration: none !important;
}
body.sg-mini-store .ml-home-hero a.aq-text-link,
body.sg-mini-store .ml-home-hero a.aq-text-link:visited {
  color: inherit !important;
  text-decoration: underline;
  text-underline-offset: 0.2em;
}
body.sg-mini-store:not(.store-editor-on) .ml-home-hero-meta-item:has([data-key^="ml_hero_meta"]:empty) {
  display: none;
}

/* Dead buttons / empty optional surfaces */
body.sg-mini-store:not(.store-editor-on) .ml-btn:empty,
body.sg-mini-store:not(.store-editor-on) a.ml-btn:not([href]),
body.sg-mini-store:not(.store-editor-on) a.aq-text-link:empty,
body.sg-mini-store:not(.store-editor-on) .ml-news-form[action="#"],
body.sg-mini-store:not(.store-editor-on) #mlNewsletter:has(form[action="#"]),
body.sg-mini-store:not(.store-editor-on) .ml-promo:has(img.is-empty):has([data-key="ml_promo_h3"]:empty) {
  display: none !important;
}

body.sg-mini-store .ml-btn,
body.sg-mini-store .sg-ms-card__add,
body.sg-mini-store .sg-shell-glass-nav__menu,
body.sg-mini-store .sg-shell-glass-nav__search,
body.sg-mini-store .sg-shell-glass-nav__cart,
body.sg-mini-store .aq-footer-col a,
body.sg-mini-store footer a,
body.sg-mini-store footer a:link,
body.sg-mini-store footer a:visited {
  color: inherit !important;
}
  min-height: 44px;
  min-width: 44px;
  pointer-events: auto !important;
  cursor: pointer;
}
body.sg-mini-store .sg-ms-card {
  aspect-ratio: 3 / 4;
  max-height: 520px;
}
body.sg-mini-store .sg-ms-card__title {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
body.sg-mini-store {
  overflow-x: hidden;
}
@media (prefers-reduced-motion: reduce) {
  body.sg-mini-store *,
  body.sg-mini-store *::before,
  body.sg-mini-store *::after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}

/* Keep menu / search / bag visible in every header family */
body[data-mini-program="1"] .sg-shell-glass-nav__menu,
body[data-mini-program="1"] .sg-shell-glass-nav__search,
body[data-mini-program="1"] .sg-shell-glass-nav__cart {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  opacity: 1 !important;
  visibility: visible !important;
}

/* 1. Light editorial masthead */
body[data-mini-header-family="editorial"] .sg-shell-glass-nav__wrap {
  padding: 18px 8px 10px;
}
body[data-mini-header-family="editorial"] .sg-shell-glass-nav__capsule {
  background: color-mix(in srgb, var(--store-card-bg, #fff) 92%, transparent);
  border: 0;
  border-bottom: 1px solid color-mix(in srgb, var(--store-text, #111) 14%, transparent);
  border-radius: 0;
  box-shadow: none;
  min-height: 72px;
  padding: 0 8px 12px;
}
body[data-mini-header-family="editorial"] .sg-shell-glass-nav__name {
  font-family: var(--store-heading-font), Georgia, serif;
  font-weight: 600;
  letter-spacing: -0.03em;
}

/* 2. Dark cinema bar */
body[data-mini-header-family="cinema"] .sg-shell-glass-nav__wrap {
  padding: 0;
}
body[data-mini-header-family="cinema"] .sg-shell-glass-nav__capsule {
  background: #0b0b0d;
  color: #f4f4f0;
  border-radius: 0;
  min-height: 56px;
  border: 0;
  box-shadow: 0 12px 40px rgba(0,0,0,.35);
}
body[data-mini-header-family="cinema"] .sg-shell-glass-nav__name,
body[data-mini-header-family="cinema"] .sg-shell-glass-nav__menu,
body[data-mini-header-family="cinema"] .sg-shell-glass-nav__search,
body[data-mini-header-family="cinema"] .sg-shell-glass-nav__cart {
  color: #f4f4f0 !important;
}
body.sg-shell-glass-nav-scrolled[data-mini-header-family="cinema"] .sg-shell-glass-nav__capsule {
  background: #050506;
}

/* 3. Paper recipe header */
body[data-mini-header-family="paper"] .sg-shell-glass-nav__capsule {
  background: #f6efe4;
  border: 1px solid #e4d6c4;
  border-radius: 4px;
  box-shadow: 0 10px 0 #eadcc8;
  min-height: 64px;
}
body[data-mini-header-family="paper"] .sg-shell-glass-nav__name {
  font-family: "Fraunces", Georgia, serif;
  font-style: italic;
}

/* 4. Minimal line header */
body[data-mini-header-family="line"] .sg-shell-glass-nav__wrap {
  padding: 8px 4vw 0;
}
body[data-mini-header-family="line"] .sg-shell-glass-nav__capsule {
  background: transparent;
  border: 0;
  border-bottom: 1px solid currentColor;
  border-radius: 0;
  box-shadow: none;
  min-height: 52px;
  padding: 0 0 10px;
}

/* 5. Product-control header */
body[data-mini-header-family="control"] .sg-shell-glass-nav__capsule {
  background: color-mix(in srgb, var(--store-card-bg, #fff) 96%, transparent);
  border: 1px solid color-mix(in srgb, currentColor 16%, transparent);
  border-radius: 10px;
  min-height: 48px;
  gap: 8px;
  font-variant-numeric: tabular-nums;
}
body[data-mini-header-family="control"] .sg-shell-glass-nav__name {
  font-family: "IBM Plex Sans", Inter, sans-serif;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-size: 12px;
}

/* 6. Bold poster header */
body[data-mini-header-family="poster"] .sg-shell-glass-nav__wrap {
  padding: 0;
}
body[data-mini-header-family="poster"] .sg-shell-glass-nav__capsule {
  background: var(--store-primary, #111);
  color: var(--store-bg, #fff);
  border-radius: 0;
  min-height: 84px;
  border: 0;
}
body[data-mini-header-family="poster"] .sg-shell-glass-nav__name {
  font-family: "Oswald", Impact, sans-serif;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-size: clamp(22px, 4vw, 34px);
}
body[data-mini-header-family="poster"] .sg-shell-glass-nav__menu,
body[data-mini-header-family="poster"] .sg-shell-glass-nav__search,
body[data-mini-header-family="poster"] .sg-shell-glass-nav__cart {
  color: inherit !important;
  border-color: currentColor;
}

/* 7. Compact mobile-first bar */
body[data-mini-header-family="compact"] .sg-shell-glass-nav__wrap {
  padding: 6px 10px;
}
body[data-mini-header-family="compact"] .sg-shell-glass-nav__capsule {
  min-height: 48px;
  border-radius: 999px;
  padding: 0 10px;
}
@media (max-width: 720px) {
  body[data-mini-header-family="compact"] .sg-shell-glass-nav__name {
    max-width: 42vw;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
}

/* 8. Gallery navigation */
body[data-mini-header-family="gallery"] .sg-shell-glass-nav__capsule {
  background: transparent;
  border: 0;
  box-shadow: none;
  justify-content: space-between;
  min-height: 68px;
}
body[data-mini-header-family="gallery"] .sg-shell-glass-nav__name {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--store-heading-font), serif;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-size: 12px;
}
@media (max-width: 720px) {
  body[data-mini-header-family="gallery"] .sg-shell-glass-nav__name {
    position: static;
    transform: none;
    letter-spacing: 0.06em;
  }
}

/* 9. Technical utility bar */
body[data-mini-header-family="utility"] .sg-shell-glass-nav__wrap {
  padding: 0;
}
body[data-mini-header-family="utility"] .sg-shell-glass-nav__capsule {
  background: #12151a;
  color: #e8edf5;
  border-radius: 0;
  border-bottom: 2px solid var(--store-accent, #3b82f6);
  min-height: 44px;
}
body[data-mini-header-family="utility"] .sg-shell-glass-nav__name,
body[data-mini-header-family="utility"] .sg-shell-glass-nav__menu,
body[data-mini-header-family="utility"] .sg-shell-glass-nav__search,
body[data-mini-header-family="utility"] .sg-shell-glass-nav__cart {
  color: #e8edf5 !important;
  font-family: "IBM Plex Sans", Inter, sans-serif;
}

/* 10. Playful color header */
body[data-mini-header-family="playful"] .sg-shell-glass-nav__capsule {
  background: var(--store-accent, #e7b6d0);
  border: 3px solid var(--store-primary, #7a5c9e);
  border-radius: 22px;
  min-height: 58px;
  box-shadow: 6px 6px 0 var(--store-primary, #7a5c9e);
}
body[data-mini-header-family="playful"] .sg-shell-glass-nav__name {
  font-family: "Nunito", Inter, sans-serif;
  font-weight: 800;
}

/* Footer families — never default blue links */
body[data-mini-program="1"] .ms-footer {
  margin-top: 2rem;
  padding: 2.2rem 5vw 2.6rem;
  max-width: 100%;
}
body[data-mini-program="1"] .ms-footer .aq-footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 1.5rem 2rem;
  align-items: start;
}
body[data-mini-program="1"] .ms-footer a {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid color-mix(in srgb, currentColor 35%, transparent);
  display: inline-flex;
  align-items: center;
  width: fit-content;
  padding: 6px 0;
}
body[data-mini-program="1"] .ms-footer a:hover,
body[data-mini-program="1"] .ms-footer a:focus-visible {
  border-bottom-color: currentColor;
  outline: none;
}
body[data-mini-program="1"] .ms-footer .aq-footer-col h3 {
  margin: 0 0 0.6rem;
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
body[data-mini-program="1"] .ms-footer .aq-footer-base {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 18px;
  margin-top: 1.6rem;
  padding-top: 1rem;
}
@media (max-width: 720px) {
  body[data-mini-program="1"] .ms-footer .aq-footer-grid {
    grid-template-columns: 1fr;
  }
}

body[data-mini-footer="editorial_light"] .ms-footer {
  background: #f7f4ee;
  color: #2a2723;
  border-top: 1px solid #e4ddd2;
  font-family: Georgia, "Times New Roman", serif;
}
body[data-mini-footer="luxury_deep"] .ms-footer {
  background: #14110f;
  color: #efe7db;
  border-top: 1px solid #3a342c;
}
body[data-mini-footer="graphite"] .ms-footer {
  background: #1c1f24;
  color: #e8edf5;
  border-top: 2px solid #3b82f6;
  font-family: "IBM Plex Sans", Inter, sans-serif;
}
body[data-mini-footer="journal"] .ms-footer {
  background: #f3eadc;
  color: #3a2a1c;
  border-top: 3px double #8b4a2a;
  font-family: "Libre Baskerville", Georgia, serif;
}
body[data-mini-footer="urban"] .ms-footer {
  background: #0b0b0b;
  color: #f4f4f0;
  border-top: 8px solid #c8ff00;
  font-family: "Oswald", Inter, sans-serif;
}
body[data-mini-footer="botanical"] .ms-footer {
  background: #eef4e8;
  color: #243328;
  border-top: 1px solid #2f5d3a;
  font-family: "Fraunces", Georgia, serif;
}
body[data-mini-footer="playful"] .ms-footer {
  background: #f6f0f8;
  color: #2e2438;
  border-top: 4px solid #7a5c9e;
  font-family: "Nunito", Inter, sans-serif;
}
body[data-mini-footer="service"] .ms-footer {
  background: #f3f4f6;
  color: #111827;
  border-top: 1px solid #0891b2;
  padding: 1.4rem 5vw 1.6rem;
  font-family: "IBM Plex Sans", Inter, sans-serif;
}

@media (max-width: 720px) {
  body[data-mini-program="1"] .ms-hero .ml-home-hero-copy {
    padding-right: 0;
  }
  body[data-mini-program="1"] .sg-ms-card {
    aspect-ratio: 4 / 5;
  }
}
