/* Marry Me — Brochure Mode / Price on Request presentation.
 *
 * Keyed on <html data-mm-site-mode="brochure|store" data-mm-pricing="show|on-request">
 * (set synchronously by js/site-mode.js). Both rules FAIL CLOSED: commerce UI
 * shows only when the mode is explicitly "store", prices only when pricing is
 * explicitly "show".
 *
 * Presentation only — it is NOT the protection. Routes and APIs are gated
 * server-side (commerce-gate.php, api/site-mode-lib.php), and js/site-mode.js
 * removes the purchase links from the DOM.
 */

/* ---------- Brochure Mode: no purchase UI (also before JS runs) ---------- */
html:not([data-mm-site-mode="store"]) a[href="cart.html"],
html:not([data-mm-site-mode="store"]) a[href="checkout.html"],
html:not([data-mm-site-mode="store"]) .nav-cart,
html:not([data-mm-site-mode="store"]) [data-mm-commerce],
html:not([data-mm-site-mode="store"]) .mm-purchase-row,
html:not([data-mm-site-mode="store"]) .mm-cart-toast,
html:not([data-mm-site-mode="store"]) .mm-mobile-buybar {
  display: none !important;
}
html[data-mm-site-mode="store"] [data-mm-brochure-only] {
  display: none !important;
}
html:not([data-mm-site-mode="store"]) body.mm-has-mobile-buybar {
  padding-bottom: 0 !important;
}

/* ---------- Brochure header ---------- */
/* Home / About / Journal / Contact live in the mobile menu (desktop has the
   logo + footer for those), keeping the desktop row to the catalog. */
@media (min-width: 981px) {
  .main-floating-nav .nav-list > .mm-nav-mobile-only { display: none !important; }
}
a.mm-nav-custom { text-decoration: none; }

/* Catalogue Mode header: Catalogue · Custom Design · Repair · Track Existing
   Order · Contact (the collection links belong to Brochure Mode). */
html:not([data-mm-site-mode="catalogue"]) [data-mm-catalogue-nav] { display: none !important; }
html[data-mm-site-mode="catalogue"] [data-mm-brochure-nav] { display: none !important; }
@media (min-width: 981px) {
  html[data-mm-site-mode="catalogue"] .main-floating-nav .nav-list > .mm-nav-contact,
  html[data-mm-site-mode="catalogue"] .main-floating-nav .nav-list > .mm-nav-journal { display: list-item !important; }
}

/* A product page shown inside the Catalogue's "View Piece" overlay: only the
   piece itself (the catalogue keeps its own header and controls). */
html.mm-embed-catalogue [data-site-nav],
html.mm-embed-catalogue .mm-skip-link,
html.mm-embed-catalogue .back-btn,
html.mm-embed-catalogue footer,
html.mm-embed-catalogue .mm-service-dock,
html.mm-embed-catalogue .mm-social-widget,
html.mm-embed-catalogue .premium-social-widget,
html.mm-embed-catalogue .mm-consent-banner,
html.mm-embed-catalogue [data-mm-consent-banner],
html.mm-embed-catalogue .mm-category-tabs { display: none !important; }
html.mm-embed-catalogue body { padding-top: 0 !important; }

/* Catalogue detail sheet look (Catalogue Mode overlay ONLY — the same rules
   never match a normal Brochure/Store product page). Palette = css/catalogue.css. */
html.mm-embed-catalogue {
  --catalogue-paper: #F7F1E7; --catalogue-paper-alt: #FBF7F0; --catalogue-champagne: #E8DCCB;
  --catalogue-taupe: #B7A795; --catalogue-teal: #073F3A; --catalogue-teal-hover: #0C5750; --catalogue-on-teal: #FFF9F0;
  --catalogue-gold: #B78A45; --catalogue-ink: #231F1B; --catalogue-text: #6F665D; --catalogue-muted: #918579;
  --catalogue-border: rgba(183, 167, 149, .55);
  --catalogue-photo-bg: radial-gradient(ellipse at 50% 42%, #FFFCF6 0%, #F6EEE2 62%, #EEE3D3 100%);
}
html.mm-embed-catalogue, html.mm-embed-catalogue body,
html.mm-embed-catalogue .presentation-wrapper,
html.mm-embed-catalogue .product-detail-page,
html.mm-embed-catalogue main { background: var(--catalogue-paper) !important; color: var(--catalogue-ink); }
html.mm-embed-catalogue .presentation-wrapper { padding-top: 34px !important; }
html.mm-embed-catalogue .mm-product-stage,
html.mm-embed-catalogue .mm-product-gallery .mm-product-stage,
html.mm-embed-catalogue .editorial-img,
html.mm-embed-catalogue .mm-product-thumb { background: var(--catalogue-photo-bg) !important; border-color: transparent !important; box-shadow: none !important; }
html.mm-embed-catalogue .mm-product-thumb.is-active,
html.mm-embed-catalogue .mm-product-thumb[aria-current="true"] { outline: 1px solid var(--catalogue-gold) !important; outline-offset: 2px; }
/* the sheet's thumbnail rail: square thumbs (never stretched tall to the photo's height), top-aligned;
   each photo is framed on the piece itself by js/product-fit.js (object-view-box), so a necklace
   fills its thumb instead of floating in empty space */
html.mm-embed-catalogue .product-detail-page .mm-product-thumbs { justify-content: flex-start !important; height: auto !important; }
html.mm-embed-catalogue .product-detail-page .mm-product-thumb { flex: 0 0 auto !important; aspect-ratio: 1 / 1 !important; height: auto !important; min-height: 0 !important; }
html.mm-embed-catalogue .product-detail-page .mm-product-thumb img { object-fit: contain !important; object-position: 50% 50% !important; }
/* a plain-white studio photo WITHOUT a transparent copy (separation refused or failed) sits in the paper */
html.mm-embed-catalogue body.product-detail-page img.mm-fit-onwhite:not([data-cut]) { mix-blend-mode: multiply !important; }
html.mm-embed-catalogue .presentation-title,
html.mm-embed-catalogue #page-title { color: var(--catalogue-ink) !important; font-weight: 300 !important; }
html.mm-embed-catalogue .mm-price-on-request { color: var(--catalogue-gold); font-style: italic; }
html.mm-embed-catalogue .mm-purchase-panel.mm-inquiry-panel { border-top-color: var(--catalogue-border) !important; }
html.mm-embed-catalogue .mm-inquiry-row .mm-primary-btn {
  background: var(--catalogue-teal) !important; border-color: var(--catalogue-teal) !important; color: var(--catalogue-on-teal) !important;
  box-shadow: 0 10px 20px -12px rgba(7, 63, 58, .7) !important; border-radius: 2px !important;
}
html.mm-embed-catalogue .mm-inquiry-row .mm-primary-btn:hover { background: var(--catalogue-teal-hover) !important; transform: translateY(-1px); }
html.mm-embed-catalogue .mm-inquiry-row .mm-primary-btn:active,
html.mm-embed-catalogue .mm-inquiry-row .mm-secondary-btn:active { transform: scale(.985); }
html.mm-embed-catalogue .mm-inquiry-row .mm-secondary-btn,
html.mm-embed-catalogue .mm-detail-actions .mm-enh-btn-secondary {
  background: var(--catalogue-paper-alt) !important; border: 1px solid var(--catalogue-gold) !important; color: var(--catalogue-ink) !important; border-radius: 2px !important; box-shadow: none !important;
}
html.mm-embed-catalogue .mm-detail-actions .mm-enh-btn-secondary { border-color: var(--catalogue-border) !important; color: var(--catalogue-text) !important; }
html.mm-embed-catalogue .mm-inquiry-row .mm-secondary-btn:hover { background: var(--catalogue-champagne) !important; color: var(--catalogue-teal) !important; }
html.mm-embed-catalogue .mm-accordion,
html.mm-embed-catalogue .mm-product-accordions details { border-color: var(--catalogue-border) !important; background: transparent !important; }
html.mm-embed-catalogue .mm-accordion summary { color: var(--catalogue-ink) !important; }
html.mm-embed-catalogue .stock-status { color: var(--catalogue-teal) !important; }
/* metal swatches: real metal textures instead of flat colour dots */
html.mm-embed-catalogue .swatch { background-size: cover !important; background-position: center !important; border-color: var(--catalogue-border) !important; }
html.mm-embed-catalogue .swatch[data-metal*="Yellow" i]:not([data-metal*="&"]):not([data-metal*="/"]) { background-image: url("../images/custom-design/metal-swatches/yellow-gold.jpg") !important; }
html.mm-embed-catalogue .swatch[data-metal*="White" i]:not([data-metal*="&"]):not([data-metal*="/"]) { background-image: url("../images/custom-design/metal-swatches/white-gold.jpg") !important; }
html.mm-embed-catalogue .swatch[data-metal*="Rose" i]:not([data-metal*="&"]):not([data-metal*="/"]) { background-image: url("../images/custom-design/metal-swatches/rose-gold.jpg") !important; }
html.mm-embed-catalogue .swatch[data-metal*="Platinum" i] { background-image: radial-gradient(circle at 35% 30%, #F4F5F6, #C9CCCF 60%, #A9ADB1) !important; }
html.mm-embed-catalogue .swatch.active { outline-color: var(--catalogue-gold) !important; }
/* variant change: a quick, clean resolve instead of a hard blink */
html.mm-embed-catalogue .mm-variant-swap { animation: mmEmbedSwap 260ms cubic-bezier(.22, .8, .24, 1) both; }
@keyframes mmEmbedSwap { from { opacity: .45; transform: scale(.988); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { html.mm-embed-catalogue .mm-variant-swap { animation: none; } }
/* Small desktops / landscape tablets: the full catalog row is wider than the
   space between logo and icons, so tighten it and let two-word labels wrap. */
@media (min-width: 981px) and (max-width: 1399px) {
  .main-floating-nav .nav-list { gap: 16px !important; }
  .main-floating-nav .nav-list > .nav-item > a,
  .main-floating-nav .nav-list .nav-link-row > a,
  .main-floating-nav .nav-list .mm-nav-custom {
    font-size: .6rem !important;
    letter-spacing: .1em !important;
    line-height: 1.3 !important;
    white-space: normal !important;
    max-width: 9em;
    text-align: center;
  }
  .main-floating-nav .nav-dropdown-toggle { margin-left: 2px !important; }
}

/* ---------- Price on Request ---------- */
html:not([data-mm-pricing="show"]) .ring-price .price-header,
html:not([data-mm-pricing="show"]) .ring-price .price-row,
html:not([data-mm-pricing="show"]) .price-disclaimer,
html:not([data-mm-pricing="show"]) .individual-price,
html:not([data-mm-pricing="show"]) .pair-price-summary,
html:not([data-mm-pricing="show"]) .pair-card-pricing,
html:not([data-mm-pricing="show"]) .mm-card-parts,
html:not([data-mm-pricing="show"]) .mm-parts .mm-part-row,
html:not([data-mm-pricing="show"]) .mm-parts .mm-parts-note,
html:not([data-mm-pricing="show"]) .modal-price-box,
html:not([data-mm-pricing="show"]) .modal-pair-summary,
html:not([data-mm-pricing="show"]) .mm-budget-control,
html:not([data-mm-pricing="show"]) .mm-budget-over-badge {
  display: none !important;
}

.mm-price-on-request {
  margin: 0 0 6px;
  font-family: var(--mm-display, "Fraunces", serif);
  font-size: 1.35rem;
  font-weight: 400;
  letter-spacing: .02em;
  color: var(--mm-ink, #2f2924);
}
.mm-price-on-request[hidden] { display: none !important; }

/* Card / search / related price slots that read "Price on Request". */
.mm-card-price.is-price-on-request,
.mm-search-product-price.is-price-on-request {
  font-style: normal;
  letter-spacing: .04em;
  color: var(--mm-muted, #736759);
}

/* ---------- Product page: inquiry panel ---------- */
.mm-purchase-panel.mm-inquiry-panel {
  box-shadow: none;
  background: transparent;
  padding: 22px 0 0;
  border: 0;
  border-top: 1px solid var(--mm-line, #d4c8bc);
  border-radius: 0;
}
.mm-inquiry-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: stretch;
}
.mm-inquiry-row .mm-primary-btn {
  flex: 1 1 240px;
}
.mm-inquiry-row .mm-secondary-btn {
  flex: 0 1 180px;
}
@media (max-width: 520px) {
  .mm-inquiry-row .mm-primary-btn,
  .mm-inquiry-row .mm-secondary-btn { flex: 1 1 100%; }
}

/* ---------- Inquiry modal ---------- */
.mm-inquiry-modal { max-width: 620px; }
.mm-inquiry-product {
  display: flex;
  gap: 14px;
  align-items: center;
  margin: 0 0 18px;
  padding: 12px;
  border: 1px solid var(--mm-line, #d4c8bc);
  border-radius: 12px;
  background: var(--mm-page-bg, #fbfaf7);
}
.mm-inquiry-product img {
  width: 72px;
  height: 72px;
  object-fit: contain;
  flex: 0 0 auto;
  background: #fff;
  border-radius: 8px;
}
.mm-inquiry-product-copy { display: grid; gap: 2px; min-width: 0; }
.mm-inquiry-product-copy strong {
  font-family: var(--mm-display, "Fraunces", serif);
  font-weight: 500;
  font-size: 1.1rem;
  color: var(--mm-ink, #2f2924);
}
.mm-inquiry-product-copy span {
  font-size: .68rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--mm-gold, #b8905a);
}
.mm-inquiry-product-copy small {
  font-size: .82rem;
  color: var(--mm-muted, #736759);
  overflow-wrap: anywhere;
}
.mm-inquiry-form [aria-invalid="true"] { border-color: #b3261e !important; }
.mm-inquiry-note {
  margin: 12px 0 0;
  font-size: .8rem;
  line-height: 1.5;
  color: var(--mm-muted, #736759);
  text-align: right;
}
.mm-inquiry-done { padding: 6px 0 4px; }
.mm-inquiry-done h3 {
  margin: 0 0 8px;
  font-family: var(--mm-display, "Fraunces", serif);
  font-weight: 500;
  font-size: 1.35rem;
  color: var(--mm-ink, #2f2924);
}
.mm-inquiry-done p { margin: 0 0 12px; line-height: 1.6; color: var(--mm-muted, #736759); }
.mm-inquiry-ref { font-weight: 600; color: var(--mm-ink, #2f2924) !important; }
@media (max-width: 520px) {
  .mm-inquiry-note { text-align: left; }
}

/* ---------- Brochure homepage (index.html) ---------- */
/* Same language as the existing .mm-editorial section (css/figma-refresh.css). */
.mm-bh-story {
  max-width: var(--mm-max, 1280px);
  margin: 0 auto;
  padding: clamp(56px, 7vw, 104px) clamp(22px, 4vw, 52px);
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  gap: clamp(32px, 6vw, 88px);
  align-items: center;
}
.mm-bh-story + .mm-bh-story { padding-top: 0; }
.mm-bh-story--reverse { grid-template-columns: .9fr 1.1fr; }
.mm-bh-story--reverse .mm-bh-story-media { order: 2; }
.mm-bh-story-media { background: var(--mm-card, #eee8df); }
.mm-bh-story-media img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}
.mm-bh-story-media--portrait { max-width: 440px; justify-self: center; width: 100%; }
.mm-bh-story-media--portrait img { aspect-ratio: 4 / 5; }
.mm-bh-story-media--sketch { background: #fff; border: 1px solid var(--mm-line, #d4c8bc); max-width: 420px; width: 100%; justify-self: center; }
.mm-bh-story-media--sketch img { aspect-ratio: 1; object-fit: contain; padding: 10%; box-sizing: border-box; }
.mm-bh-story-copy .mm-kicker { margin-bottom: 16px; }
.mm-bh-title {
  margin: 0 0 20px;
  color: var(--mm-ink, #2f2924);
  font-family: var(--mm-display, "Fraunces", serif);
  font-weight: 300;
  font-size: clamp(2.2rem, 3.8vw, 3.9rem);
  line-height: 1.04;
  letter-spacing: -.02em;
}
.mm-bh-title em { font-family: inherit; }
.mm-bh-story-copy p:not(.mm-kicker) {
  max-width: 480px;
  margin: 0 0 14px;
  color: var(--mm-muted, #736759);
  font-size: .9rem;
  line-height: 1.8;
}
.mm-bh-story-copy .mm-bh-choose {
  margin: 22px 0 8px;
  color: var(--mm-ink, #2f2924);
  font-size: .64rem;
  font-weight: 500;
  letter-spacing: .15em;
  text-transform: uppercase;
}
.mm-bh-links { list-style: none; margin: 0 0 6px; padding: 0; display: flex; flex-wrap: wrap; gap: 8px 22px; }
.mm-bh-links a,
.mm-bh-index a {
  color: var(--mm-ink, #2f2924);
  text-decoration: none;
  font-size: .92rem;
  border-bottom: 1px solid transparent;
}
.mm-bh-links a:hover,
.mm-bh-index a:hover { border-bottom-color: currentColor; }
.mm-bh-cta {
  display: inline-block;
  margin-top: 18px;
  padding-bottom: 3px;
  border-bottom: 1px solid var(--mm-ink, #2f2924);
  color: var(--mm-ink, #2f2924);
  text-decoration: none;
  font-size: .66rem;
  font-weight: 500;
  letter-spacing: .15em;
  text-transform: uppercase;
}
.mm-bh-cta:hover { color: var(--mm-teal, #0b6b63); border-bottom-color: var(--mm-teal, #0b6b63); }

.mm-bh-index {
  border-top: 1px solid var(--mm-line, #d4c8bc);
  border-bottom: 1px solid var(--mm-line, #d4c8bc);
  background: var(--mm-card, #eee8df);
  padding: clamp(52px, 6vw, 84px) clamp(22px, 4vw, 52px);
}
.mm-bh-index-head,
.mm-bh-index-cols { max-width: var(--mm-max, 1280px); margin: 0 auto; }
.mm-bh-index-head { margin-bottom: 28px; }
.mm-bh-index-head .mm-kicker { margin-bottom: 12px; }
.mm-bh-index-cols { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px; }
.mm-bh-index h3 {
  margin: 0 0 12px;
  font-family: var(--mm-display, "Fraunces", serif);
  font-weight: 400;
  font-size: 1.25rem;
  color: var(--mm-ink, #2f2924);
}
.mm-bh-index ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }

@media (max-width: 860px) {
  .mm-bh-story,
  .mm-bh-story--reverse { grid-template-columns: 1fr; gap: 26px; }
  .mm-bh-story--reverse .mm-bh-story-media { order: 0; }
  .mm-bh-index-cols { grid-template-columns: 1fr; gap: 22px; }
}

/* ---------- online-ordering.html notice ---------- */
.mm-brochure-notice .mm-brochure-kicker {
  margin: 0 0 6px;
  font-size: .7rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--mm-gold, #b8905a);
}
.mm-brochure-notice-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 18px;
}
.mm-brochure-notice-actions a {
  display: inline-grid;
  place-items: center;
  text-decoration: none;
}
