/* =============================================================
   THE NIGHT MERCHANT — Custom Theme Stylesheet
   night-merchant.css
   ============================================================= */

/* =============================================================
   FONT DECLARATIONS
   The font files live at the THEME ROOT (next to template.conf), not in
   a fonts/ folder: the July upload flattened that folder, and the old
   '../fonts/' paths 404'd, so every visitor without the fonts installed
   saw Georgia. Fixed 2026-09-26. There are no .woff fallbacks in the
   theme; every current browser takes woff2.
   ============================================================= */

@font-face {
  font-family: 'TC Antiquated DEMO';
  src: url('../TCAntiquatedDEMO-Regular.woff2') format('woff2');
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'TRIAL Wonderling';
  src: url('../TRIALWonderling-Regular.woff2') format('woff2');
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'TRIAL Wonderling';
  src: url('../TRIALWonderling-ItalicRegular.woff2') format('woff2');
  font-weight: normal;
  font-style: italic;
  font-display: swap;
}

@font-face {
  font-family: 'TC Phantasmagoria';
  src: url('../TCPhantasmagoria-Regular.woff2') format('woff2');
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}

/* =============================================================
   CUSTOM PROPERTIES
   ============================================================= */

:root {
  --nm-aged-paper:    #C8B89A;
  --nm-ink-night:     #1A1209;
  --nm-press-charcoal:#2D2416;
  --nm-crimson-ink:   #8B1F1F;
  --nm-antique-gold:  #9B7D3A;
  --nm-parchment:     #EDE4CC;

  --nm-font-hero:    'TC Antiquated DEMO', Georgia, serif;
  --nm-font-display: 'TRIAL Wonderling', Georgia, serif;
  --nm-font-body:    'TC Phantasmagoria', Georgia, serif;

  --nm-header-height: 80px;
  --nm-max-width:    1200px;
}

/* =============================================================
   RESET / BOX-SIZING
   ============================================================= */

*, *::before, *::after {
  box-sizing: border-box;
}

/* =============================================================
   BODY — AGED PAPER WITH TEXTURE OVERLAY
   ============================================================= */

html {
  font-size: 18px;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--nm-font-body);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--nm-ink-night);
  background-color: var(--nm-aged-paper);
  background-image:
    url('../images/textures/newsprint-text.png'),
    url('../images/textures/paper-grain.png');
  background-repeat: repeat, repeat;
  background-size: auto, auto;
}

/* =============================================================
   ACCESSIBILITY
   ============================================================= */

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}

.main-content-nav-btn {
  position: absolute;
  left: -9999px;
  top: auto;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.main-content-nav-btn:focus {
  position: fixed;
  left: 50%;
  transform: translateX(-50%);
  top: 16px;
  width: auto;
  height: auto;
  padding: 12px 24px;
  z-index: 9999;
  background-color: var(--nm-ink-night);
  color: var(--nm-parchment);
  font-family: var(--nm-font-body);
  font-size: 0.9rem;
  border: 1px solid var(--nm-antique-gold);
  text-decoration: none;
}

/* =============================================================
   TYPOGRAPHY
   ============================================================= */

h1, h2, h3, h4, h5, h6 {
  font-family: var(--nm-font-display);
  font-weight: normal;
  color: var(--nm-ink-night);
  margin: 0;
  line-height: 1.2;
}

p {
  margin: 0 0 1em;
  font-size: 1rem;
  line-height: 1.6;
}

a {
  color: var(--nm-crimson-ink);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

/* =============================================================
   NAVIGATION HEADER
   ============================================================= */

.nm-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background-color: var(--nm-ink-night);
  border-bottom: 1px solid rgba(155, 125, 58, 0.5);
}

.nm-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: var(--nm-max-width);
  margin: 0 auto;
  padding: 0 32px;
  height: var(--nm-header-height);
  gap: 24px;
}

/* Logo */
.nm-logo-link {
  display: flex;
  align-items: center;
  flex-shrink: 0;
  text-decoration: none;
}

.nm-logo-link:hover {
  text-decoration: none;
  opacity: 0.88;
}

.nm-logo {
  height: 56px;
  width: auto;
  display: block;
}

/* Site name — homepage h1 below the hero image */
.nm-site-heading {
  font-family: var(--nm-font-hero);
  font-size: 3.2rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--nm-ink-night);
  text-align: center;
  padding: 60px 32px 0;
  margin: 0;
  line-height: 1;
  font-weight: normal;
}

/* Store attribution — small label above category title on all non-home pages */
.nm-page-attribution {
  font-family: var(--nm-font-hero);
  font-size: 0.75rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--nm-antique-gold);
  text-align: center;
  margin: 0 0 14px;
}

/* Desktop Navigation */
.nm-nav {
  display: flex;
  align-items: center;
  flex: 1;
  justify-content: center;
}

.nm-nav-list {
  display: flex;
  align-items: center;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 0;
}

.nm-nav-item {
  position: relative;
}

.nm-nav-link {
  display: block;
  padding: 8px 13px;
  font-family: var(--nm-font-body);
  font-size: 0.72rem;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--nm-parchment);
  text-decoration: none;
  white-space: nowrap;
  border-bottom: 2px solid transparent;
  transition: color 0.15s, border-color 0.15s;
}

.nm-nav-link:hover,
.nm-nav-link[aria-current="page"] {
  color: var(--nm-parchment);
  border-bottom-color: var(--nm-crimson-ink);
  text-decoration: none;
}

/* Header Actions */
.nm-header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

/* Cart */
.nm-cart-wrap {
  position: relative;
  cursor: pointer;
}

.nm-cart-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--nm-parchment);
  padding: 8px 4px;
  cursor: pointer;
  transition: color 0.15s;
}

.nm-cart-btn:hover {
  color: var(--nm-antique-gold);
}

.nm-cart-icon {
  width: 22px;
  height: 22px;
  display: block;
  flex-shrink: 0;
}

.nm-cart-count {
  font-family: var(--nm-font-body);
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  color: inherit;
  min-width: 14px;
  text-align: center;
}

/* Zoho cart count elements inherit our styles */
.nm-cart-wrap .theme-mini-cart-count,
.nm-cart-wrap [data-zs-view-cart-count] {
  font-family: var(--nm-font-body);
  font-size: 0.72rem;
  color: var(--nm-parchment);
  background: none;
  border: none;
  padding: 0;
  min-width: auto;
}

/* Mobile menu toggle */
.nm-mobile-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px 4px;
  margin: 0;
}

.nm-mobile-toggle span {
  display: block;
  width: 24px;
  height: 1.5px;
  background-color: var(--nm-parchment);
  transition: transform 0.3s ease, opacity 0.3s ease;
  pointer-events: none;
}

.nm-mobile-toggle.is-open span:nth-child(1) {
  transform: translateY(6.5px) rotate(45deg);
}

.nm-mobile-toggle.is-open span:nth-child(2) {
  opacity: 0;
}

.nm-mobile-toggle.is-open span:nth-child(3) {
  transform: translateY(-6.5px) rotate(-45deg);
}

/* Mobile Navigation Panel */
.nm-mobile-nav {
  background-color: var(--nm-press-charcoal);
  border-top: 1px solid rgba(155, 125, 58, 0.3);
  padding: 24px 32px 32px;
}

.nm-mobile-nav[hidden] {
  display: none;
}

.nm-mobile-nav-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.nm-mobile-nav-item {
  border-bottom: 1px solid rgba(155, 125, 58, 0.15);
}

.nm-mobile-nav-link {
  display: block;
  padding: 16px 0;
  font-family: var(--nm-font-body);
  font-size: 1rem;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--nm-parchment);
  text-decoration: none;
  transition: color 0.15s;
}

.nm-mobile-nav-link:hover {
  color: var(--nm-antique-gold);
  text-decoration: none;
}

/* =============================================================
   MAIN CONTENT
   ============================================================= */

#main-content {
  outline: none;
}

/* =============================================================
   HOMEPAGE — HERO
   ============================================================= */

.nm-hero {
  position: relative;
  width: 100%;
  height: 70vh;
  min-height: 480px;
  overflow: hidden;
  background-color: var(--nm-ink-night);
}

.nm-hero-image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

/* =============================================================
   HOMEPAGE — MERCHANT INTRO
   ============================================================= */

.nm-intro {
  text-align: center;
  padding: 72px 32px 64px;
  max-width: 640px;
  margin: 0 auto;
}

.nm-intro-rule {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 36px;
  color: var(--nm-antique-gold);
}

.nm-intro-rule::before,
.nm-intro-rule::after {
  content: '';
  flex: 1;
  height: 1px;
  background-color: var(--nm-antique-gold);
  opacity: 0.45;
}

.nm-intro-ornament {
  font-size: 0.85rem;
  letter-spacing: 0.45em;
  opacity: 0.75;
  padding-right: 0.45em;
}

.nm-intro-text {
  font-family: var(--nm-font-body);
  font-size: 1.05rem;
  line-height: 1.75;
  color: var(--nm-press-charcoal);
  letter-spacing: 0.02em;
  margin-bottom: 0;
}

.nm-intro-text + .nm-intro-text {
  margin-top: 1em;
}

/* =============================================================
   HOMEPAGE — CATEGORY PLATES
   ============================================================= */

.nm-catalog {
  padding-bottom: 80px;
}

.nm-plate {
  display: flex;
  align-items: center;
  gap: 64px;
  max-width: var(--nm-max-width);
  margin: 0 auto;
  padding: 72px 32px;
  border-bottom: 1px solid rgba(155, 125, 58, 0.2);
}

.nm-plate:last-child {
  border-bottom: none;
}

.nm-plate--reverse {
  flex-direction: row-reverse;
}

/* Image side */
.nm-plate-image-wrap {
  flex: 0 0 auto;
  width: 48%;
}

.nm-plate-image-frame {
  border: 1px solid rgba(155, 125, 58, 0.35);
  padding: 7px;
  background-color: var(--nm-ink-night);
  line-height: 0;
  aspect-ratio: 3 / 2;
}

.nm-plate-image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

/* Text side */
.nm-plate-content {
  flex: 1;
  padding: 24px 0;
}

.nm-plate-number {
  display: block;
  font-family: var(--nm-font-body);
  font-size: 0.68rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--nm-antique-gold);
  margin-bottom: 14px;
}

.nm-plate-title {
  font-family: var(--nm-font-display);
  font-size: 2.4rem;
  color: var(--nm-ink-night);
  margin-bottom: 22px;
  line-height: 1.12;
}

.nm-plate-title::first-letter {
  font-family: var(--nm-font-hero);
  font-size: 1.2em;
  color: var(--nm-crimson-ink);
  line-height: 0.85;
  float: left;
  margin-right: 0.04em;
  margin-top: 0.06em;
}

.nm-plate-desc {
  font-family: var(--nm-font-body);
  font-size: 1rem;
  line-height: 1.7;
  color: var(--nm-press-charcoal);
  margin-bottom: 28px;
  max-width: 400px;
  letter-spacing: 0.01em;
}

.nm-plate-cta {
  display: inline-block;
  font-family: var(--nm-font-body);
  font-size: 0.78rem;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--nm-crimson-ink);
  text-decoration: none;
  border-bottom: 1px solid rgba(139, 31, 31, 0.4);
  padding-bottom: 3px;
  transition: color 0.15s, border-color 0.15s;
}

.nm-plate-cta:hover {
  color: var(--nm-press-charcoal);
  border-bottom-color: var(--nm-press-charcoal);
  text-decoration: none;
}

/* =============================================================
   FOOTER
   ============================================================= */

.nm-footer {
  background-color: var(--nm-ink-night);
  color: var(--nm-parchment);
  border-top: 1px solid rgba(155, 125, 58, 0.45);
  padding: 64px 32px 40px;
}

.nm-footer-inner {
  max-width: var(--nm-max-width);
  margin: 0 auto;
}

.nm-footer-logo-link {
  display: inline-block;
  margin-bottom: 20px;
  text-decoration: none;
}

.nm-footer-logo-link:hover {
  opacity: 0.82;
  text-decoration: none;
}

.nm-footer-logo {
  height: 60px;
  width: auto;
  display: block;
}

.nm-footer-grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 56px;
  align-items: start;
}

.nm-footer-col {
  min-width: 0;
}

.nm-footer-col--merchant {
  padding-right: 24px;
}

.nm-footer-tagline {
  font-family: var(--nm-font-body);
  font-size: 0.9rem;
  line-height: 1.7;
  color: rgba(237, 228, 204, 0.6);
  max-width: 260px;
  margin: 0 0 28px;
}

/* Newsletter */
.nm-newsletter {
  margin-top: 28px;
}

.nm-newsletter-prompt {
  font-family: var(--nm-font-body);
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  color: rgba(237, 228, 204, 0.45);
  margin: 0 0 14px;
}

.nm-newsletter-field {
  display: flex;
  gap: 0;
}

.nm-newsletter-input {
  flex: 1;
  font-family: var(--nm-font-body);
  font-size: 0.85rem;
  color: var(--nm-ink-night);
  background-color: rgba(200, 184, 154, 0.9);
  border: 1px solid rgba(155, 125, 58, 0.4);
  border-right: none;
  padding: 10px 14px;
  border-radius: 0;
  min-width: 0;
}

.nm-newsletter-input::placeholder {
  color: rgba(26, 18, 9, 0.45);
}

.nm-newsletter-input:focus {
  outline: none;
  border-color: var(--nm-antique-gold);
}

.nm-newsletter-btn {
  font-family: var(--nm-font-body);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--nm-parchment);
  background-color: var(--nm-crimson-ink);
  border: 1px solid var(--nm-crimson-ink);
  padding: 10px 16px;
  cursor: pointer;
  border-radius: 0;
  white-space: nowrap;
  transition: background-color 0.15s;
}

.nm-newsletter-btn:hover {
  background-color: var(--nm-press-charcoal);
  border-color: var(--nm-press-charcoal);
}

.nm-sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}

.nm-footer-nav-heading {
  font-family: var(--nm-font-body);
  font-size: 0.67rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--nm-antique-gold);
  margin: 0 0 18px;
}

.nm-footer-nav-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.nm-footer-nav-item {
  margin-bottom: 10px;
}

.nm-footer-nav-link {
  font-family: var(--nm-font-body);
  font-size: 0.88rem;
  line-height: 1.5;
  color: rgba(237, 228, 204, 0.65);
  text-decoration: none;
  letter-spacing: 0.02em;
  transition: color 0.15s;
}

.nm-footer-nav-link:hover {
  color: var(--nm-parchment);
  text-decoration: none;
}

.nm-footer-bottom {
  border-top: 1px solid rgba(155, 125, 58, 0.2);
  padding-top: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.nm-footer-copyright {
  font-family: var(--nm-font-body);
  font-size: 0.72rem;
  color: rgba(237, 228, 204, 0.38);
  letter-spacing: 0.05em;
  margin: 0;
}

/* =============================================================
   STORE CATEGORY PAGE
   ============================================================= */

.nm-category-hero {
  width: 100%;
  height: 340px;
  overflow: hidden;
  background-color: var(--nm-ink-night);
  position: relative;
}

.nm-category-hero-img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.nm-category-header {
  text-align: center;
  padding: 56px 32px 32px;
  border-bottom: 1px solid rgba(155, 125, 58, 0.2);
  margin-bottom: 48px;
}

.nm-category-title {
  font-family: var(--nm-font-hero);
  font-size: 2.6rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--nm-ink-night);
}

.nm-category-sort {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  max-width: var(--nm-max-width);
  margin: 0 auto 32px;
  padding: 0 32px;
  gap: 12px;
}

.nm-sort-label {
  font-family: var(--nm-font-body);
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--nm-antique-gold);
}

.nm-sort-select {
  font-family: var(--nm-font-body);
  font-size: 0.82rem;
  color: var(--nm-ink-night);
  background-color: var(--nm-aged-paper);
  border: 1px solid rgba(155, 125, 58, 0.4);
  padding: 6px 10px;
  cursor: pointer;
  letter-spacing: 0.04em;
}

/* =============================================================
   PRODUCT GRID / CATALOG PLATES
   ============================================================= */

.nm-product-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 48px;
  max-width: var(--nm-max-width);
  margin: 0 auto;
  padding: 0 32px 80px;
}

.nm-product-plate {
  display: flex;
  flex-direction: column;
}

.nm-product-item-number {
  font-family: var(--nm-font-body);
  font-size: 0.66rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--nm-antique-gold);
  margin-bottom: 10px;
  display: block;
}

.nm-product-image-frame {
  border: 1px solid rgba(155, 125, 58, 0.28);
  padding: 6px;
  background-color: var(--nm-ink-night);
  margin-bottom: 16px;
  line-height: 0;
}

.nm-product-image {
  display: block;
  width: 100%;
  /* height:auto is required — the img height attribute otherwise wins
     over aspect-ratio and blows the box up to its intrinsic height */
  height: auto;
  aspect-ratio: 1 / 1;
  object-fit: cover;
}

.nm-product-name {
  font-family: var(--nm-font-body);
  font-size: 1rem;
  color: var(--nm-ink-night);
  margin-bottom: 6px;
  line-height: 1.4;
  letter-spacing: 0.01em;
}

.nm-product-price {
  font-family: var(--nm-font-body);
  font-size: 0.9rem;
  color: var(--nm-crimson-ink);
  letter-spacing: 0.05em;
}

/* =============================================================
   ZOHO COMMERCE OVERRIDES
   Minimal overrides — let Zoho handle functional styles,
   we only override visual properties that conflict.
   ============================================================= */

/* Zoho base product card: strip to bare */
.theme-product-box {
  background: transparent !important;
  border: none !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  padding: 0 !important;
}

/* Buttons */
.zpbutton-type-primary {
  font-family: var(--nm-font-body) !important;
  letter-spacing: 0.06em;
  border-radius: 0 !important;
  background-color: var(--nm-crimson-ink) !important;
  border-color: var(--nm-crimson-ink) !important;
  color: var(--nm-parchment) !important;
}

.zpbutton-type-primary:hover {
  background-color: var(--nm-press-charcoal) !important;
  border-color: var(--nm-press-charcoal) !important;
}

/* Cart and system messages: use our font */
.theme-cart-add-success-message,
.theme-cart-add-failure-message,
.theme-cart-update-success-message,
.theme-cart-update-failure-message,
.theme-cart-delete-success-message,
.theme-cart-delete-failure-message {
  font-family: var(--nm-font-body) !important;
}

/* Zoho footer: override to match our color system */
.theme-footer-area {
  background-color: var(--nm-ink-night) !important;
  color: var(--nm-parchment) !important;
}

/* Zoho header area: reset Zoho's header styles */
[data-headercontainer] {
  background-color: var(--nm-ink-night) !important;
  border-bottom: 1px solid rgba(155, 125, 58, 0.5) !important;
}

/* =============================================================
   RESPONSIVE — TABLET (max 960px)
   ============================================================= */

@media (max-width: 960px) {
  .nm-nav {
    display: none;
  }

  .nm-mobile-toggle {
    display: flex;
  }

  .nm-header-inner {
    padding: 0 20px;
  }

  .nm-plate {
    flex-direction: column !important;
    gap: 32px;
    padding: 52px 24px;
  }

  .nm-plate-image-wrap {
    width: 100%;
  }

  .nm-plate-title {
    font-size: 2rem;
  }

  .nm-plate-desc {
    max-width: 100%;
  }

  .nm-site-heading {
    font-size: 2.6rem;
    letter-spacing: 0.14em;
    padding: 48px 24px 0;
  }

  .nm-intro {
    padding: 56px 24px 48px;
  }

  .nm-hero {
    height: 55vh;
    min-height: 320px;
  }

  .nm-product-grid {
    grid-template-columns: 1fr;
    padding: 0 24px 64px;
    gap: 40px;
  }

  .nm-footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 36px;
  }

  .nm-footer-col--merchant {
    grid-column: 1 / -1;
    padding-right: 0;
  }

  .nm-newsletter-field {
    max-width: 400px;
  }
}

/* =============================================================
   RESPONSIVE — MOBILE (max 600px)
   ============================================================= */

@media (max-width: 600px) {
  html {
    font-size: 16px;
  }

  .nm-logo {
    height: 44px;
  }

  .nm-site-heading {
    font-size: 2rem;
    letter-spacing: 0.1em;
    padding: 44px 16px 0;
  }

  .nm-plate {
    padding: 40px 16px;
  }

  .nm-plate-title {
    font-size: 1.8rem;
  }

  .nm-catalog {
    padding-bottom: 48px;
  }

  .nm-intro {
    padding: 48px 16px 40px;
  }

  .nm-footer {
    padding: 48px 16px 32px;
  }

  .nm-footer-grid {
    grid-template-columns: 1fr;
  }

  .nm-footer-col--merchant {
    padding-right: 0;
  }

  .nm-newsletter-field {
    max-width: 100%;
  }

  .nm-footer-bottom {
    flex-direction: column;
    align-items: flex-start;
  }

  .nm-category-hero {
    height: 220px;
  }

  .nm-category-title {
    font-size: 2rem;
  }
}

/* =============================================================
   BREADCRUMB
   ============================================================= */

.nm-breadcrumb {
  max-width: var(--nm-max-width);
  margin: 0 auto;
  padding: 20px 32px 0;
}

.nm-breadcrumb-inner {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
}

.nm-breadcrumb-link {
  font-family: var(--nm-font-body);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--nm-antique-gold);
  text-decoration: none;
  opacity: 0.75;
  transition: opacity 0.15s;
}

.nm-breadcrumb-link:hover {
  opacity: 1;
  text-decoration: none;
}

.nm-breadcrumb-sep {
  font-size: 0.7rem;
  color: var(--nm-antique-gold);
  opacity: 0.4;
}

/* =============================================================
   SORT BAR (category pages)
   ============================================================= */

.nm-sort-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: var(--nm-max-width);
  margin: 0 auto 32px;
  padding: 0 32px;
  gap: 12px;
}

.nm-sort-group {
  display: flex;
  align-items: center;
  gap: 10px;
}

.nm-no-products {
  text-align: center;
  padding: 80px 32px;
  font-family: var(--nm-font-body);
  font-size: 1rem;
  color: var(--nm-press-charcoal);
  opacity: 0.6;
  max-width: var(--nm-max-width);
  margin: 0 auto;
}

/* Product card image links and placeholders */
.nm-product-image-link {
  display: block;
  text-decoration: none;
}

.nm-product-image-link:hover {
  text-decoration: none;
}

.nm-product-image-link:hover .nm-product-image-frame {
  border-color: rgba(155, 125, 58, 0.55);
}

.nm-product-image-placeholder {
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1;
  background-color: var(--nm-press-charcoal);
  opacity: 0.4;
}

/* Hover image swap — second product image fades in over the first.
   Frame padding is 6px, so the overlay is inset to match. */
.nm-product-image-frame {
  position: relative;
}

.nm-product-image-alt {
  position: absolute;
  top: 6px;
  left: 6px;
  width: calc(100% - 12px);
  height: calc(100% - 12px);
  opacity: 0;
  transition: opacity 0.35s ease;
}

.nm-product-plate:hover .nm-product-image-alt,
.nm-product-image-link:focus-visible .nm-product-image-alt {
  opacity: 1;
}

/* =============================================================
   PRODUCT DETAIL PAGE
   ============================================================= */

.nm-product-detail-wrap {
  max-width: var(--nm-max-width);
  margin: 0 auto;
  padding: 0 32px 80px;
}

/* Restyle Zoho's product detail container */
.nm-product-detail-wrap .theme-product-detail-container {
  display: grid !important;
  grid-template-columns: 1fr 1fr !important;
  gap: 64px !important;
  align-items: start !important;
  padding: 56px 0 !important;
  max-width: 100% !important;
  float: none !important;
}

.nm-product-detail-wrap .theme-product-detail-column {
  width: 100% !important;
  float: none !important;
  padding: 0 !important;
}

/* Image frame */
.nm-product-detail-wrap .theme-product-detail-image-container {
  position: relative;
}

/* Stock markup classes are .theme-product-detail-image /
   .theme-product-detail-thumbnail(-container); active thumbnail gets
   .theme-active-thumbnail from store.js showDetailImage() */
.nm-product-detail-wrap .theme-product-detail-image {
  border: 1px solid rgba(155, 125, 58, 0.35) !important;
  padding: 8px !important;
  background-color: var(--nm-ink-night) !important;
  line-height: 0 !important;
  border-radius: 0 !important;
  box-shadow: none !important;
}

.nm-product-detail-wrap .theme-product-detail-image img {
  display: block !important;
  width: 100% !important;
  height: auto !important;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 0 !important;
}

/* Thumbnails — small uniform squares below the hero image */
.nm-product-detail-wrap .theme-product-detail-thumbnail-container {
  display: flex !important;
  flex-wrap: wrap !important;
  gap: 12px !important;
  margin-top: 24px !important;
}

.nm-product-detail-wrap .theme-product-detail-thumbnail {
  flex: 0 0 auto !important;
  width: 84px !important;
  height: 84px !important;
  border: 1px solid rgba(155, 125, 58, 0.25) !important;
  padding: 4px !important;
  background-color: var(--nm-ink-night) !important;
  border-radius: 0 !important;
  cursor: pointer !important;
  line-height: 0 !important;
  opacity: 0.7 !important;
  transition: opacity 0.15s, border-color 0.15s !important;
}

.nm-product-detail-wrap .theme-product-detail-thumbnail img {
  display: block !important;
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
}

.nm-product-detail-wrap .theme-product-detail-thumbnail:hover,
.nm-product-detail-wrap .theme-product-detail-thumbnail.theme-active-thumbnail {
  opacity: 1 !important;
  border-color: var(--nm-antique-gold) !important;
}

/* Product name h1 */
.nm-product-detail-wrap h1[data-zs-product-name],
.nm-product-detail-wrap .theme-product-name-social-share h1 {
  font-family: var(--nm-font-display) !important;
  font-size: 2.2rem !important;
  font-weight: normal !important;
  color: var(--nm-ink-night) !important;
  line-height: 1.15 !important;
  margin: 0 0 16px !important;
  letter-spacing: 0 !important;
}

/* Short description */
.nm-product-detail-wrap .theme-product-short-description {
  font-family: var(--nm-font-body) !important;
  font-size: 1rem !important;
  line-height: 1.7 !important;
  color: var(--nm-press-charcoal) !important;
  margin-bottom: 20px !important;
}

/* Price */
.nm-product-detail-wrap .theme-product-price,
.nm-product-detail-wrap .theme-product-price-new,
.nm-product-detail-wrap .theme-product-rate {
  font-family: var(--nm-font-body) !important;
  font-size: 1.1rem !important;
  color: var(--nm-crimson-ink) !important;
  letter-spacing: 0.06em !important;
  font-weight: normal !important;
}

.nm-product-detail-wrap .theme-product-price-old,
.nm-product-detail-wrap .theme-product-label-rate {
  font-family: var(--nm-font-body) !important;
  font-size: 0.85rem !important;
  color: var(--nm-press-charcoal) !important;
  opacity: 0.5 !important;
  text-decoration: line-through !important;
}

/* Variant selectors */
.nm-product-detail-wrap .theme-product-varients-area select,
.nm-product-detail-wrap .theme-variant-type-select {
  font-family: var(--nm-font-body) !important;
  font-size: 0.9rem !important;
  color: var(--nm-ink-night) !important;
  background-color: var(--nm-aged-paper) !important;
  border: 1px solid rgba(155, 125, 58, 0.4) !important;
  padding: 10px 12px !important;
  border-radius: 0 !important;
  width: 100% !important;
}

.nm-product-detail-wrap .theme-product-varients-row label,
.nm-product-detail-wrap .theme-variant-label {
  font-family: var(--nm-font-body) !important;
  font-size: 0.72rem !important;
  letter-spacing: 0.14em !important;
  text-transform: uppercase !important;
  color: var(--nm-antique-gold) !important;
}

/* Quantity input */
.nm-product-detail-wrap .theme-product-quantity-input,
.nm-product-detail-wrap input[data-zs-quantity] {
  font-family: var(--nm-font-body) !important;
  font-size: 0.9rem !important;
  color: var(--nm-ink-night) !important;
  background-color: var(--nm-aged-paper) !important;
  border: 1px solid rgba(155, 125, 58, 0.4) !important;
  border-radius: 0 !important;
  text-align: center !important;
}

/* Add to cart button */
.nm-product-detail-wrap button[data-zs-add-to-cart],
.nm-product-detail-wrap .theme-addtocart-btn {
  font-family: var(--nm-font-body) !important;
  font-size: 0.85rem !important;
  letter-spacing: 0.12em !important;
  text-transform: uppercase !important;
  background-color: var(--nm-crimson-ink) !important;
  border: 1px solid var(--nm-crimson-ink) !important;
  color: var(--nm-parchment) !important;
  border-radius: 0 !important;
  padding: 14px 24px !important;
  width: 100% !important;
  cursor: pointer !important;
  transition: background-color 0.15s, border-color 0.15s !important;
}

.nm-product-detail-wrap button[data-zs-add-to-cart]:hover,
.nm-product-detail-wrap .theme-addtocart-btn:hover {
  background-color: var(--nm-press-charcoal) !important;
  border-color: var(--nm-press-charcoal) !important;
}

/* Product tabs section */
.nm-product-tabs-wrap {
  max-width: var(--nm-max-width);
  margin: 0 auto;
  padding: 0 32px 72px;
  border-top: 1px solid rgba(155, 125, 58, 0.2);
}

.nm-product-tabs-wrap .nm-product-tabs {
  display: flex;
  gap: 0;
  border-bottom: 1px solid rgba(155, 125, 58, 0.2);
  margin-bottom: 32px;
}

.nm-product-tabs-wrap .nm-product-tab {
  font-family: var(--nm-font-body) !important;
  font-size: 0.72rem !important;
  letter-spacing: 0.14em !important;
  text-transform: uppercase !important;
  color: var(--nm-press-charcoal) !important;
  opacity: 0.55 !important;
  padding: 16px 20px !important;
  cursor: pointer !important;
  border-bottom: 2px solid transparent !important;
  transition: opacity 0.15s, border-color 0.15s !important;
}

.nm-product-tabs-wrap .nm-product-tab.theme-prod-detail-tab-active {
  opacity: 1 !important;
  border-bottom-color: var(--nm-crimson-ink) !important;
  color: var(--nm-ink-night) !important;
}

.nm-product-tabs-wrap .nm-product-tab-content {
  font-family: var(--nm-font-body) !important;
  font-size: 1rem !important;
  line-height: 1.75 !important;
  color: var(--nm-press-charcoal) !important;
}

.nm-product-tabs-wrap .nm-product-desc-body p {
  margin-bottom: 1em;
}

/* Recommended products wrapper */
.nm-recommended-wrap {
  max-width: var(--nm-max-width);
  margin: 0 auto;
  padding: 0 32px 80px;
}

/* =============================================================
   CART PAGE
   ============================================================= */

.nm-cart-page-header {
  text-align: center;
  padding: 56px 32px 40px;
  border-bottom: 1px solid rgba(155, 125, 58, 0.2);
  margin-bottom: 48px;
}

.nm-cart-title {
  font-family: var(--nm-font-hero);
  font-size: 2.4rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--nm-ink-night);
  margin: 0;
  font-weight: normal;
}

.nm-cart-ornament {
  display: block;
  font-family: var(--nm-font-body);
  font-size: 0.75rem;
  letter-spacing: 0.45em;
  color: var(--nm-antique-gold);
  opacity: 0.65;
  margin-bottom: 20px;
}

/* Zoho cart-view overrides */
.nm-cart-wrap .theme-cart-table,
.nm-cart-wrap table[data-cart-table] {
  width: 100%;
  border-collapse: collapse;
  font-family: var(--nm-font-body) !important;
}

.nm-cart-wrap .theme-cart-heading th,
.nm-cart-wrap thead th {
  font-family: var(--nm-font-body) !important;
  font-size: 0.66rem !important;
  letter-spacing: 0.16em !important;
  text-transform: uppercase !important;
  color: var(--nm-antique-gold) !important;
  border-bottom: 1px solid rgba(155, 125, 58, 0.3) !important;
  padding: 0 12px 14px !important;
  font-weight: normal !important;
  background: transparent !important;
}

.nm-cart-wrap .theme-cart-data td,
.nm-cart-wrap tbody td {
  padding: 20px 12px !important;
  border-bottom: 1px solid rgba(155, 125, 58, 0.12) !important;
  font-family: var(--nm-font-body) !important;
  font-size: 0.9rem !important;
  color: var(--nm-ink-night) !important;
  vertical-align: middle !important;
  background: transparent !important;
}

.nm-cart-wrap .theme-cart-product-name,
.nm-cart-wrap [data-cart-product-name] {
  font-family: var(--nm-font-body) !important;
  font-size: 1rem !important;
  color: var(--nm-ink-night) !important;
}

.nm-cart-wrap .theme-cart-price,
.nm-cart-wrap [data-cart-price] {
  font-family: var(--nm-font-body) !important;
  color: var(--nm-crimson-ink) !important;
}

.nm-cart-wrap .theme-cart-total-price {
  font-family: var(--nm-font-body) !important;
  color: var(--nm-crimson-ink) !important;
}

.nm-cart-wrap .theme-cart-subtotal-container {
  font-family: var(--nm-font-body) !important;
  border-top: 1px solid rgba(155, 125, 58, 0.25) !important;
  padding-top: 16px !important;
}

.nm-cart-wrap .theme-cart-subtotal-label {
  font-family: var(--nm-font-body) !important;
  font-size: 0.72rem !important;
  letter-spacing: 0.1em !important;
  text-transform: uppercase !important;
  color: var(--nm-antique-gold) !important;
}

.nm-cart-wrap .theme-checkout-button,
.nm-cart-wrap button[data-zs-checkout] {
  font-family: var(--nm-font-body) !important;
  font-size: 0.85rem !important;
  letter-spacing: 0.12em !important;
  text-transform: uppercase !important;
  background-color: var(--nm-crimson-ink) !important;
  border: 1px solid var(--nm-crimson-ink) !important;
  color: var(--nm-parchment) !important;
  border-radius: 0 !important;
  padding: 14px 24px !important;
  cursor: pointer !important;
}

.nm-cart-wrap .theme-checkout-button:hover,
.nm-cart-wrap button[data-zs-checkout]:hover {
  background-color: var(--nm-press-charcoal) !important;
  border-color: var(--nm-press-charcoal) !important;
}

/* =============================================================
   CHECKOUT PAGE
   ============================================================= */

.nm-checkout-page-header {
  text-align: center;
  padding: 56px 32px 40px;
  border-bottom: 1px solid rgba(155, 125, 58, 0.2);
  margin-bottom: 48px;
}

.nm-checkout-title {
  font-family: var(--nm-font-hero);
  font-size: 2.4rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--nm-ink-night);
  margin: 0;
  font-weight: normal;
}

/* Zoho checkout form overrides */
.nm-checkout-wrap {
  font-family: var(--nm-font-body) !important;
}

.nm-checkout-wrap input,
.nm-checkout-wrap select,
.nm-checkout-wrap textarea {
  font-family: var(--nm-font-body) !important;
  font-size: 0.9rem !important;
  color: var(--nm-ink-night) !important;
  background-color: rgba(200, 184, 154, 0.3) !important;
  border: 1px solid rgba(155, 125, 58, 0.3) !important;
  border-radius: 0 !important;
  padding: 11px 14px !important;
}

.nm-checkout-wrap input:focus,
.nm-checkout-wrap select:focus,
.nm-checkout-wrap textarea:focus {
  outline: none !important;
  border-color: var(--nm-antique-gold) !important;
}

.nm-checkout-wrap label {
  font-family: var(--nm-font-body) !important;
  font-size: 0.72rem !important;
  letter-spacing: 0.12em !important;
  text-transform: uppercase !important;
  color: var(--nm-press-charcoal) !important;
}

.nm-checkout-wrap button[type="submit"],
.nm-checkout-wrap .zpbutton-type-primary {
  font-family: var(--nm-font-body) !important;
  font-size: 0.85rem !important;
  letter-spacing: 0.12em !important;
  text-transform: uppercase !important;
  background-color: var(--nm-crimson-ink) !important;
  border: 1px solid var(--nm-crimson-ink) !important;
  color: var(--nm-parchment) !important;
  border-radius: 0 !important;
  padding: 14px 24px !important;
  cursor: pointer !important;
}

.nm-checkout-wrap button[type="submit"]:hover {
  background-color: var(--nm-press-charcoal) !important;
  border-color: var(--nm-press-charcoal) !important;
}

.nm-checkout-wrap .theme-section-heading,
.nm-checkout-wrap h2,
.nm-checkout-wrap h3 {
  font-family: var(--nm-font-body) !important;
  font-size: 0.66rem !important;
  letter-spacing: 0.18em !important;
  text-transform: uppercase !important;
  color: var(--nm-antique-gold) !important;
  font-weight: normal !important;
  border-bottom: 1px solid rgba(155, 125, 58, 0.2) !important;
  padding-bottom: 10px !important;
  margin-bottom: 20px !important;
}

/* =============================================================
   RESPONSIVE ADDITIONS — TABLET
   ============================================================= */

@media (max-width: 960px) {
  .nm-product-detail-wrap .theme-product-detail-container {
    grid-template-columns: 1fr !important;
    gap: 40px !important;
    padding: 40px 0 !important;
  }

  .nm-product-tabs-wrap {
    padding: 0 24px 56px;
  }

  .nm-sort-bar {
    padding: 0 24px;
  }

  .nm-breadcrumb {
    padding: 16px 24px 0;
  }
}

/* =============================================================
   RESPONSIVE ADDITIONS — MOBILE
   ============================================================= */

@media (max-width: 600px) {
  .nm-cart-title,
  .nm-checkout-title {
    font-size: 1.8rem;
  }

  .nm-cart-page-header,
  .nm-checkout-page-header {
    padding: 44px 16px 32px;
  }

  .nm-sort-bar {
    padding: 0 16px;
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }

  .nm-breadcrumb {
    padding: 14px 16px 0;
  }

  .nm-product-detail-wrap {
    padding: 0 16px 64px;
  }

  .nm-product-tabs-wrap {
    padding: 0 16px 48px;
  }
}

/* =============================================================
   CONTROLS BAR — Filter + Sort (category pages)
   ============================================================= */

.nm-controls-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: var(--nm-max-width);
  margin: 0 auto 20px;
  padding: 0 32px;
  gap: 12px;
}

.nm-controls-left {
  display: flex;
  align-items: center;
  gap: 20px;
}

.nm-filter-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--nm-font-body);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--nm-press-charcoal);
  background: transparent;
  border: 1px solid rgba(155, 125, 58, 0.35);
  padding: 8px 16px;
  cursor: pointer;
  transition: border-color 0.15s, color 0.15s;
}

.nm-filter-toggle:hover {
  border-color: var(--nm-antique-gold);
  color: var(--nm-ink-night);
}

.nm-filter-toggle[aria-expanded="true"] {
  border-color: var(--nm-crimson-ink);
  color: var(--nm-crimson-ink);
}

.nm-filter-active-count {
  color: var(--nm-crimson-ink);
  font-size: 0.68rem;
}

/* =============================================================
   FILTER PANEL
   ============================================================= */

.nm-filter-panel {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 340px;
  max-width: 90vw;
  height: 100vh;
  background-color: var(--nm-aged-paper);
  background-image: url('../images/textures/paper-grain.png');
  border-right: 1px solid rgba(155, 125, 58, 0.3);
  z-index: 900;
  overflow-y: auto;
  flex-direction: column;
}

.nm-filter-panel--open {
  display: flex;
}

.nm-filter-panel-inner {
  flex: 1;
  padding: 32px 28px 24px;
  overflow-y: auto;
}

.nm-filter-panel-footer {
  padding: 20px 28px;
  border-top: 1px solid rgba(155, 125, 58, 0.2);
  display: flex;
  justify-content: flex-end;
}

.nm-filter-done {
  font-family: var(--nm-font-body);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--nm-parchment);
  background-color: var(--nm-crimson-ink);
  border: 1px solid var(--nm-crimson-ink);
  padding: 10px 24px;
  cursor: pointer;
  border-radius: 0;
  transition: background-color 0.15s;
}

.nm-filter-done:hover {
  background-color: var(--nm-press-charcoal);
  border-color: var(--nm-press-charcoal);
}

.nm-filter-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(26, 18, 9, 0.45);
  z-index: 899;
}

.nm-filter-overlay--visible {
  display: block;
}

.nm-filter-body-lock {
  overflow: hidden;
}

/* Night Merchant overrides for Zoho filter UI within the panel */
.nm-filter-panel-inner .theme-product-filter-box {
  border: none !important;
  padding: 0 0 24px !important;
  margin: 0 0 20px !important;
  border-bottom: 1px solid rgba(155, 125, 58, 0.15) !important;
}

.nm-filter-panel-inner .theme-product-filter-box:last-child {
  border-bottom: none !important;
}

.nm-filter-panel-inner .theme-product-filter-type {
  font-family: var(--nm-font-body) !important;
  font-size: 0.66rem !important;
  letter-spacing: 0.18em !important;
  text-transform: uppercase !important;
  color: var(--nm-antique-gold) !important;
  margin: 0 0 14px !important;
  padding: 0 !important;
  cursor: pointer !important;
}

.nm-filter-panel-inner .theme-product-filter-text {
  font-family: var(--nm-font-body) !important;
  font-size: 0.9rem !important;
  color: var(--nm-ink-night) !important;
  letter-spacing: 0.02em !important;
}

.nm-filter-panel-inner .theme-product-filter-option-container {
  display: flex !important;
  align-items: center !important;
  gap: 10px !important;
  margin-bottom: 10px !important;
  background: transparent !important;
}

.nm-filter-panel-inner .theme-product-filter-select-option {
  flex-shrink: 0 !important;
}

.nm-filter-panel-inner .theme-product-filter-custom-check {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 16px !important;
  height: 16px !important;
  border: 1px solid rgba(155, 125, 58, 0.5) !important;
  background-color: transparent !important;
  cursor: pointer !important;
  transition: background-color 0.12s, border-color 0.12s !important;
  border-radius: 0 !important;
}

.nm-filter-panel-inner input.theme-product-filter-check:checked + .theme-product-filter-custom-check {
  background-color: var(--nm-crimson-ink) !important;
  border-color: var(--nm-crimson-ink) !important;
}

.nm-filter-panel-inner .theme-product-filter-show-more {
  font-family: var(--nm-font-body) !important;
  font-size: 0.72rem !important;
  letter-spacing: 0.1em !important;
  text-transform: uppercase !important;
  color: var(--nm-antique-gold) !important;
  opacity: 0.7 !important;
  text-decoration: none !important;
}

.nm-filter-panel-inner .theme-product-clear-filter {
  font-family: var(--nm-font-body) !important;
  font-size: 0.7rem !important;
  color: var(--nm-crimson-ink) !important;
  text-decoration: none !important;
}

/* =============================================================
   APPLIED FILTER CHIPS
   ============================================================= */

.nm-filter-chips-wrap {
  max-width: var(--nm-max-width);
  margin: 0 auto 24px;
  padding: 0 32px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.nm-filter-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.nm-filter-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--nm-font-body);
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  color: var(--nm-ink-night);
  background-color: rgba(155, 125, 58, 0.12);
  border: 1px solid rgba(155, 125, 58, 0.35);
  padding: 5px 12px;
  cursor: pointer;
  border-radius: 0;
  transition: background-color 0.12s;
}

.nm-filter-chip:hover {
  background-color: rgba(139, 31, 31, 0.08);
  border-color: var(--nm-crimson-ink);
}

.nm-filter-clear-all {
  font-family: var(--nm-font-body);
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--nm-crimson-ink);
  background: transparent;
  border: none;
  padding: 5px 0;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* =============================================================
   ERROR PAGE (404)
   ============================================================= */

.nm-error-page {
  min-height: 60vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 80px 32px;
}

.nm-error-inner {
  text-align: center;
  max-width: 560px;
  margin: 0 auto;
}

.nm-error-ornament {
  font-family: var(--nm-font-body);
  font-size: 0.72rem;
  letter-spacing: 0.5em;
  color: var(--nm-antique-gold);
  opacity: 0.65;
  margin-bottom: 32px;
}

.nm-error-code {
  font-family: var(--nm-font-hero);
  font-size: clamp(4rem, 12vw, 8rem);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--nm-ink-night);
  line-height: 1;
  margin: 0 0 8px;
  font-weight: normal;
}

.nm-error-heading {
  font-family: var(--nm-font-display);
  font-size: 1.6rem;
  color: var(--nm-press-charcoal);
  font-weight: normal;
  margin: 0 0 24px;
  letter-spacing: 0.01em;
}

.nm-error-body {
  font-family: var(--nm-font-body);
  font-size: 1rem;
  line-height: 1.75;
  color: var(--nm-press-charcoal);
  opacity: 0.75;
  margin: 0 0 40px;
}

.nm-error-btn {
  display: inline-block;
  font-family: var(--nm-font-body);
  font-size: 0.8rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--nm-parchment);
  background-color: var(--nm-crimson-ink);
  border: 1px solid var(--nm-crimson-ink);
  padding: 14px 32px;
  text-decoration: none;
  transition: background-color 0.15s, border-color 0.15s;
}

.nm-error-btn:hover {
  background-color: var(--nm-press-charcoal);
  border-color: var(--nm-press-charcoal);
  color: var(--nm-parchment);
  text-decoration: none;
}

@media (max-width: 600px) {
  .nm-controls-bar {
    padding: 0 16px;
    flex-wrap: wrap;
    gap: 12px;
  }

  .nm-filter-chips-wrap {
    padding: 0 16px;
  }

  .nm-error-page {
    padding: 56px 16px;
  }
}

/* =============================================================
   CMS CONTENT PAGES (Shipping & Returns, Privacy Policy, etc.)
   ============================================================= */

.nm-page-content-wrap {
  max-width: 720px;
  margin: 0 auto;
  padding: 64px 32px 96px;
}

.nm-page-content-header {
  border-bottom: 1px solid rgba(155, 125, 58, 0.2);
  padding-bottom: 32px;
  margin-bottom: 48px;
}

.nm-page-content-title {
  font-family: var(--nm-font-display);
  font-size: 2.4rem;
  color: var(--nm-ink-night);
  font-weight: normal;
  margin: 8px 0 0;
  letter-spacing: 0;
}

.nm-page-content-body {
  font-family: var(--nm-font-body);
  font-size: 1rem;
  line-height: 1.8;
  color: var(--nm-press-charcoal);
}

.nm-page-content-body h2 {
  font-family: var(--nm-font-display);
  font-size: 1.4rem;
  color: var(--nm-ink-night);
  font-weight: normal;
  margin: 40px 0 16px;
}

.nm-page-content-body h3 {
  font-family: var(--nm-font-body);
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--nm-antique-gold);
  margin: 28px 0 12px;
}

.nm-page-content-body p {
  margin: 0 0 1.4em;
}

.nm-page-content-body a {
  color: var(--nm-crimson-ink);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.nm-page-content-body a:hover {
  color: var(--nm-press-charcoal);
}

.nm-page-content-body ul,
.nm-page-content-body ol {
  padding-left: 1.5em;
  margin: 0 0 1.4em;
}

.nm-page-content-body li {
  margin-bottom: 0.5em;
}

@media (max-width: 600px) {
  .nm-page-content-wrap {
    padding: 48px 16px 72px;
  }

  .nm-page-content-title {
    font-size: 1.8rem;
  }
}


/* =============================================================
   INTERACTION & ATMOSPHERE (added 2026-07-05)
   Subtle motion only — opacity and transform. No parallax.
   ============================================================= */

/* Product plates — lift, and the frame takes the ink */
.nm-product-plate {
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.nm-product-plate:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 24px rgba(26, 18, 9, 0.18);
}
.nm-product-image-frame {
  overflow: hidden;
  transition: border-color 0.25s ease;
}
.nm-product-plate:hover .nm-product-image-frame {
  border-color: var(--nm-crimson-ink);
}
.nm-product-image {
  transition: transform 0.6s ease;
}
.nm-product-plate:hover .nm-product-image {
  transform: scale(1.03);
}
.nm-product-plate:hover .nm-product-item-number {
  color: var(--nm-crimson-ink);
}
.nm-product-name {
  transition: color 0.2s ease;
}
.nm-product-plate:hover .nm-product-name {
  color: var(--nm-crimson-ink);
}

/* Homepage category plates — the engraving stirs */
.nm-plate-image-frame { overflow: hidden; }
.nm-plate-image { transition: transform 0.7s ease; }
.nm-plate:hover .nm-plate-image { transform: scale(1.025); }
.nm-plate-cta::after {
  content: '\2192';
  display: inline-block;
  margin-left: 0.4em;
  transition: transform 0.25s ease;
}
.nm-plate-cta:hover::after { transform: translateX(4px); }

/* Nav links — the underline draws itself */
.nm-nav-link { position: relative; }
.nm-nav-link::after {
  content: '';
  position: absolute;
  left: 0;
  right: 100%;
  bottom: -2px;
  height: 1px;
  background: var(--nm-crimson-ink);
  transition: right 0.25s ease;
}
.nm-nav-link:hover::after { right: 0; }

/* Header — gains weight once the page moves */
.nm-header { transition: box-shadow 0.3s ease; }
.nm-header--scrolled { box-shadow: 0 4px 18px rgba(26, 18, 9, 0.35); }

/* Scroll reveal — plates settle onto the page */
.nm-reveal {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.nm-reveal.nm-in {
  opacity: 1;
  transform: none;
}

/* Respect reduced motion */
@media (prefers-reduced-motion: reduce) {
  .nm-product-plate,
  .nm-product-image,
  .nm-plate-image,
  .nm-plate-cta::after,
  .nm-reveal {
    transition: none !important;
    transform: none !important;
  }
  .nm-reveal { opacity: 1; }
}


/* Hide the category/collection hero band until an image is uploaded */
.nm-category-hero:not(:has(.nm-category-hero-img)) {
  display: none;
}


/* =============================================================
   HOMEPAGE ATMOSPHERE (added 2026-07-10)
   Ambient motion in the gaslight register — slow drift, lamplight,
   ink settling. Still no parallax, no sliding panels, nothing fast.
   ============================================================= */

/* Hero — the image breathes, very slowly */
.nm-hero {
  overflow: hidden;
  position: relative;
}

.nm-hero-image {
  transform-origin: 50% 40%;
  animation: nm-hero-drift 48s ease-in-out infinite alternate;
}

@keyframes nm-hero-drift {
  from { transform: scale(1); }
  to   { transform: scale(1.06); }
}

/* Hero — warm lamplight vignette, wavering like a gas flame */
.nm-hero-lamplight {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(
    ellipse 72% 58% at 50% 42%,
    rgba(155, 125, 58, 0.08),
    rgba(26, 18, 9, 0.30) 80%
  );
  animation: nm-lamplight 9s ease-in-out infinite;
}

@keyframes nm-lamplight {
  0%, 100% { opacity: 0.85; }
  9%   { opacity: 0.95; }
  14%  { opacity: 0.80; }
  24%  { opacity: 0.92; }
  42%  { opacity: 0.78; }
  56%  { opacity: 0.95; }
  74%  { opacity: 0.83; }
  87%  { opacity: 0.96; }
}

/* Heading and intro — the ink settles once, on arrival */
.nm-site-heading {
  animation: nm-ink-settle 1.2s ease-out both;
}

.nm-intro-rule {
  animation: nm-ink-settle 1.2s ease-out 0.25s both;
}

@keyframes nm-ink-settle {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: none; }
}

/* Intro ornament — a slow gold glimmer */
.nm-intro-ornament {
  display: inline-block;
  animation: nm-glimmer 8s ease-in-out infinite;
}

@keyframes nm-glimmer {
  0%, 100% { opacity: 0.55; text-shadow: none; }
  50%      { opacity: 1; text-shadow: 0 0 12px rgba(155, 125, 58, 0.55); }
}

/* Category plates — image arrives from its own side, text settles after.
   These rules only bite when the reveal JS has added .nm-reveal, so a
   no-JS visitor sees everything immediately. */
.nm-plate.nm-reveal .nm-plate-image-wrap {
  opacity: 0;
  transform: translateX(-26px);
  transition: opacity 0.7s ease 0.05s, transform 0.7s ease 0.05s;
}

.nm-plate--reverse.nm-reveal .nm-plate-image-wrap {
  transform: translateX(26px);
}

.nm-plate.nm-reveal .nm-plate-content {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.7s ease 0.3s, transform 0.7s ease 0.3s;
}

.nm-plate.nm-reveal.nm-in .nm-plate-image-wrap,
.nm-plate.nm-reveal.nm-in .nm-plate-content {
  opacity: 1;
  transform: none;
}

/* Plate frames warm toward the lamp on hover */
.nm-plate-image-frame {
  transition: border-color 0.4s ease;
}

.nm-plate:hover .nm-plate-image-frame {
  border-color: rgba(139, 31, 31, 0.55);
}

.nm-plate-number {
  transition: color 0.3s ease;
}

.nm-plate:hover .nm-plate-number {
  color: var(--nm-crimson-ink);
}

/* Reduced motion — the room goes still */
@media (prefers-reduced-motion: reduce) {
  .nm-hero-image,
  .nm-hero-lamplight,
  .nm-site-heading,
  .nm-intro-rule,
  .nm-intro-ornament {
    animation: none !important;
  }
  .nm-plate.nm-reveal .nm-plate-image-wrap,
  .nm-plate.nm-reveal .nm-plate-content {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
}

/* Filter drawer sits above the sticky header so no group hides behind it */
.nm-filter-panel { z-index: 1200; }
.nm-filter-overlay { z-index: 1199; }

/* =============================================================
   DESKTOP FILTER SIDEBAR (revised 2026-07-05, Richard)
   The Type/Theme/Price checkboxes are always visible in a left
   sidebar on desktop. The slide-out drawer is mobile-only.
   ============================================================= */

.nm-category-body {
  max-width: var(--nm-max-width);
  margin: 0 auto;
  padding: 0 32px 80px;
}

/* Grid and chips now live inside the wrapper — it owns the page padding */
.nm-category-body .nm-product-grid {
  max-width: none;
  padding: 0;
}

.nm-category-body .nm-filter-chips-wrap {
  max-width: none;
  padding: 0;
  margin: 0 0 24px;
}

@media (max-width: 960px) {
  .nm-category-body {
    padding: 0 24px 64px;
  }
}

@media (max-width: 600px) {
  .nm-category-body {
    padding: 0 16px 64px;
  }
}

.nm-filter-panel-title {
  font-family: var(--nm-font-body);
  font-size: 0.9rem;
  font-weight: normal;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--nm-ink-night);
  margin: 0;
  padding: 32px 28px 14px;
  border-bottom: 1px solid rgba(155, 125, 58, 0.35);
}

@media (min-width: 961px) {
  .nm-category-body {
    display: flex;
    align-items: flex-start;
    gap: 48px;
  }

  .nm-filter-sidebar {
    width: 280px;
    flex-shrink: 0;
  }

  .nm-category-main {
    flex: 1;
    min-width: 0;
  }

  /* Grid drops to 3 columns beside the sidebar for breathing room */
  .nm-category-main .nm-product-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  /* The drawer becomes a normal-flow sticky panel */
  .nm-filter-sidebar .nm-filter-panel {
    display: block;
    position: sticky;
    top: calc(var(--nm-header-height) + 24px);
    width: auto;
    max-width: none;
    height: auto;
    max-height: calc(100vh - var(--nm-header-height) - 48px);
    background-color: transparent;
    background-image: none;
    border-right: none;
    z-index: 1;
    overflow-y: auto;
  }

  .nm-filter-sidebar .nm-filter-panel-title {
    padding: 0 0 12px;
    margin-bottom: 24px;
  }

  .nm-filter-sidebar .nm-filter-panel-inner {
    padding: 0;
    overflow-y: visible;
    flex: none;
  }

  .nm-filter-sidebar .nm-filter-panel-footer {
    display: none;
  }

  .nm-filter-toggle,
  .nm-filter-overlay {
    display: none !important;
  }
}

/* =============================================================
   FILTER FUNCTIONALITY REWIRE (2026-07-05)
   Zoho's filter JS is back in charge: native applied-filter chips,
   AJAX fragment elements inside the plate grid, quieter counts,
   thin sidebar scrollbar.
   ============================================================= */

/* Fragment children that land inside the plate grid span the full row */
.nm-product-grid .theme-lazy-loading-container,
.nm-product-grid .theme-no-products-error {
  grid-column: 1 / -1;
  font-family: var(--nm-font-body);
  color: var(--nm-press-charcoal);
  text-align: center;
  padding: 24px 0;
}

/* Applied-filter chips (Zoho native, restyled to the nm chip design) */
.theme-product-filter-selected-container {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 0 0 24px;
}

.theme-product-filter-selected-label {
  font-family: var(--nm-font-body);
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--nm-press-charcoal);
}

a[data-zs-filter-refineby-clear-btn] {
  font-family: var(--nm-font-body);
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--nm-crimson-ink) !important;
  text-decoration: underline;
  text-underline-offset: 3px;
  margin-left: 8px;
  opacity: 1 !important;
}

.theme-product-filter-selected-value {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--nm-font-body);
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  color: var(--nm-ink-night);
  background-color: rgba(155, 125, 58, 0.12);
  border: 1px solid rgba(155, 125, 58, 0.35);
  padding: 5px 10px;
}

.theme-product-filter-selected-value svg {
  width: 11px;
  height: 11px;
  cursor: pointer;
  flex-shrink: 0;
}

.theme-product-filter-selected-value svg path {
  fill: var(--nm-crimson-ink);
}

/* Product counts beside filter options — quiet text, not boxes */
.nm-filter-panel-inner .theme-product-filter-count {
  font-family: var(--nm-font-body) !important;
  font-size: 0.7rem !important;
  color: var(--nm-antique-gold) !important;
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  padding: 0 !important;
}

/* =============================================================
   HEADER SEARCH (added 2026-07-07)
   Icon in the header actions toggles a full-width search bar
   below the header. Plain GET form to the store search page —
   no dependence on Zoho's toggle JS.
   ============================================================= */

.nm-search-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: transparent;
  border: none;
  color: var(--nm-parchment);
  cursor: pointer;
  padding: 0;
  transition: color 0.15s;
}

.nm-search-toggle:hover,
.nm-search-toggle[aria-expanded="true"] {
  color: var(--nm-antique-gold);
}

.nm-search-bar {
  background-color: var(--nm-ink-night);
  border-top: 1px solid rgba(155, 125, 58, 0.35);
  border-bottom: 1px solid rgba(155, 125, 58, 0.5);
  padding: 14px 32px;
}

.nm-search-form {
  display: flex;
  gap: 12px;
  max-width: 640px;
  margin: 0 auto;
}

.nm-search-input {
  flex: 1;
  min-width: 0;
  font-family: var(--nm-font-body);
  font-size: 1rem;
  color: var(--nm-parchment);
  background: transparent;
  border: none;
  border-bottom: 1px solid rgba(155, 125, 58, 0.5);
  padding: 8px 2px;
  letter-spacing: 0.04em;
}

.nm-search-input::placeholder {
  color: rgba(237, 228, 204, 0.45);
}

.nm-search-input:focus {
  outline: none;
  border-bottom-color: var(--nm-antique-gold);
}

.nm-search-submit {
  font-family: var(--nm-font-body);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--nm-parchment);
  background-color: var(--nm-crimson-ink);
  border: 1px solid var(--nm-crimson-ink);
  padding: 8px 20px;
  cursor: pointer;
  border-radius: 0;
  transition: background-color 0.15s;
}

.nm-search-submit:hover {
  background-color: var(--nm-press-charcoal);
  border-color: var(--nm-press-charcoal);
}

@media (max-width: 600px) {
  .nm-search-bar {
    padding: 12px 16px;
  }
}

/* Sidebar scrollbar — thin and quiet */
.nm-filter-sidebar .nm-filter-panel {
  scrollbar-width: thin;
  scrollbar-color: rgba(155, 125, 58, 0.45) transparent;
}

.nm-filter-sidebar .nm-filter-panel::-webkit-scrollbar {
  width: 6px;
}

.nm-filter-sidebar .nm-filter-panel::-webkit-scrollbar-thumb {
  background: rgba(155, 125, 58, 0.4);
}

.nm-filter-sidebar .nm-filter-panel::-webkit-scrollbar-track {
  background: transparent;
}

/* CMS page header — centered, matching the category page headers (2026-07-07) */
.nm-page-content-header {
  text-align: center;
}

/* CMS page body — Zoho's Page Builder renders a fixed-width .zpcontainer grid
   that overflowed the old 720px clamp and pushed content right. Release the
   clamp and let the builder grid center itself (2026-07-07). */
.nm-page-content-wrap {
  max-width: none;
  padding-left: 0;
  padding-right: 0;
}

.nm-page-content-header {
  padding-left: 32px;
  padding-right: 32px;
}

.nm-page-content-body .zpcontainer {
  margin-left: auto;
  margin-right: auto;
  max-width: 100%;
}

/* ============================================================
   CROSS-GROUP FILTER FIX (2026-07-10)
   Zoho ORs every tag-based filter into one tag_ids list, so
   Type + Theme (both tag filters) cannot AND server-side. The
   companion script in _theme.face intersects the groups
   client-side and hides plates that fail any selected group.
   ============================================================ */

.nm-xfilter-hide {
  display: none !important;
}

.nm-xfilter-empty {
  grid-column: 1 / -1;
}

/* Launch usability repairs — 2026-09-05 */
.nm-header-inner { max-width: 1440px; }
@media (min-width: 961px) and (max-width: 1399px) {
  .nm-nav { display: none; }
  .nm-mobile-toggle { display: flex; }
}
.nm-sort-count { display: none; }
.nm-product-item-number:empty { display: none; }
.nm-product-image-placeholder { background-color: rgba(26,18,9,.06); }
