/* ==========================================================================
   MIDWEST WOODWORKS — all custom CSS for the Client View site (one file).
   Loaded once from functions.php (after Client View's own CSS).

   1. Header + mega menu ........ includes/mww-header.php, js/mww-header.js
   2. Shortcodes ................ [mww_rooms] (+ [mww_subcats] uses Divi's .subcat-grid CSS)
   3. Client View ............... buttons, page container, product cards + product page

   Add new rules to the matching section; don't create new CSS files.
   ========================================================================== */

:root {
  --mww-accent: #e8a658;
  --mww-accent-hover: #dc9442;
  --mww-accent-soft: #f6dcb9;
  --mww-ink: #000;
  --mww-text: #222;
  --mww-muted: #656565;
  --mww-rule: #d6d6d6;
  --mww-serif: "Crimson Text", Georgia, "Times New Roman", serif;
  --mww-sans: "Open Sans", "Helvetica Neue", Arial, sans-serif;
}

/* ==========================================================================
   1. MIDWEST WOODWORKS CUSTOM HEADER
   Markup: includes/mww-header.php  Behaviour: js/mww-header.js
   Scoped to .mww-header; #main-header.mww-header beats Divi's #main-header rules.
   Keep the 1024px breakpoint in sync with matchMedia() in the JS.
   ========================================================================== */

:root {
  --mww-header-width: 1160px;
  --mww-header-gutter: 32px;
  --mww-header-main-height: 172px;
  --mww-header-nav-height: 40px;
  --mww-header-mobile-height: 112px;
  --mww-header-control-height: 36px;
  --mww-header-row-height: 40px;
  --mww-header-admin-offset: 0px;
}

body.admin-bar {
  --mww-header-admin-offset: 32px;
}

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

#main-header.mww-header {
  position: relative;
  top: auto;
  z-index: 99999;
  width: 100%;
  margin: 0;
  padding: 0;
  background: #fff;
  box-shadow: none;
  color: var(--mww-ink);
  font-family: var(--mww-sans);
  font-size: 15px;
  font-weight: 400;
  line-height: 1.35;
  text-align: left;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}

.mww-header [hidden] {
  display: none !important;
}

.mww-header a {
  color: inherit;
  text-decoration: none;
}

.mww-header ul,
.mww-header li {
  margin: 0;
  padding: 0;
  list-style: none;
  line-height: inherit;
}

.mww-header button,
.mww-header input,
.mww-header summary {
  font: inherit;
}

.mww-header button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  color: inherit;
  cursor: pointer;
  line-height: 1;
  text-transform: none;
}

.mww-header :where(a, button, input, summary):focus-visible {
  outline: 2px solid var(--mww-accent);
  outline-offset: 3px;
}

.mww-header :where(a, button, input, summary):focus:not(:focus-visible) {
  outline: none;
}

.mww-header svg {
  display: block;
  flex-shrink: 0;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.mww-header-spacer {
  display: none;
}

/* Top row: logo, search, showroom, quote, hamburger. */
.mww-header__main {
  display: grid;
  grid-template-columns: 152px minmax(220px, 432px) 1fr auto 34px;
  align-items: center;
  gap: 24px;
  max-width: var(--mww-header-width);
  min-height: var(--mww-header-main-height);
  margin-inline: auto;
  padding: 24px var(--mww-header-gutter);
}

.mww-header__brand {
  display: block;
}

.mww-header__brand img {
  display: block;
  width: 100%;
  height: auto;
}

.mww-header .mww-header__showroom {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  justify-self: end;
  font-size: 14px;
  line-height: 1.5;
  text-align: right;
  white-space: nowrap;
}

.mww-header .mww-header__showroom:hover .mww-header__showroom-title {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.mww-header__showroom-title {
  font-weight: 600;
}

/* Quote List: orange pill, black outline, light count bubble. */
.mww-header .mww-header__quote {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-height: 42px;
  padding: 6px 14px 6px 18px;
  border: 2px solid var(--mww-ink);
  border-radius: 999px;
  background: var(--mww-accent);
  color: var(--mww-ink);
  font-size: 16px;
  font-weight: 700;
  letter-spacing: .01em;
  text-transform: uppercase;
  white-space: nowrap;
  transition: background-color .2s;
}

.mww-header .mww-header__quote:hover {
  background: var(--mww-accent-hover);
}

.mww-header__count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 20px;
  height: 20px;
  padding-inline: 5px;
  border-radius: 10px;
  background: var(--mww-accent-soft);
  color: var(--mww-ink);
  font-size: 11px;
  font-weight: 600;
  line-height: 1;
}

.mww-header .mww-header__toggle {
  width: 34px;
  height: 44px;
}

.mww-header__toggle svg {
  stroke-width: 2.4;
  stroke-linecap: butt;
}

.mww-header .mww-header__toggle:hover {
  color: var(--mww-accent-hover);
}

.mww-header .mww-header__close {
  display: none;
}

.mww-header.is-menu-open .mww-header__hamburger {
  display: none;
}

.mww-header.is-menu-open .mww-header__close {
  display: block;
}

/* Client View [vuer_search]: outlined box, serif placeholder, icon on the right. */
.mww-header__search {
  min-width: 0;
  height: var(--mww-header-control-height);
}

.mww-header .mww-header__search .vuer-search-shortcode,
.mww-header .mww-header__search .vuer-search,
.mww-header .mww-header__search .vuer-search__form,
.mww-header .mww-header__search .vuer-search__field {
  width: 100%;
  height: 100%;
  margin: 0;
}

.mww-header .mww-header__search .vuer-search__field {
  display: flex;
  align-items: stretch;
  border: 2px solid var(--mww-ink);
  border-radius: 6px;
  background: #fff;
}

.mww-header .mww-header__search .vuer-search__input {
  flex: 1;
  width: 100%;
  min-width: 0;
  height: 100%;
  margin: 0;
  padding: 4px 10px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  box-shadow: none;
  color: var(--mww-ink);
  font-family: var(--mww-serif);
  font-size: 17px;
  line-height: normal;
}

.mww-header .mww-header__search .vuer-search__input::placeholder {
  color: var(--mww-ink);
  opacity: 1;
}

.mww-header .mww-header__search .vuer-search__field:focus-within {
  outline: 2px solid var(--mww-accent);
  outline-offset: 2px;
}

.mww-header .mww-header__search .vuer-search__input:focus {
  outline: 0;
}

.mww-header .mww-header__search .vuer-search__submit {
  position: static;
  width: 36px;
  height: 100%;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--mww-ink);
}

.mww-header .mww-header__search .vuer-search__submit:hover {
  color: var(--mww-accent-hover);
}

.mww-header .mww-header__search .vuer-search__icon {
  width: 15px;
  height: 15px;
}

.mww-header .mww-header__search .vuer-search__suggestions {
  max-height: min(60dvh, 420px);
  overflow-y: auto;
  background: #fff;
  color: var(--mww-text);
}

/* Room bar: full-width black band, serif uppercase rooms spread across the container. */
.mww-header__navigation {
  position: relative;
  background: var(--mww-ink);
  color: #fff;
}

.mww-header__primary {
  max-width: var(--mww-header-width);
  margin-inline: auto;
  padding-inline: var(--mww-header-gutter);
}

.mww-header .mww-header__rooms {
  display: flex;
  align-items: stretch;
  justify-content: space-between;
}

.mww-header__row {
  display: flex;
  align-items: stretch;
}

.mww-header__row > a {
  display: flex;
  align-items: center;
  flex: 1;
  min-width: 0;
  min-height: var(--mww-header-row-height);
  padding: 6px 8px;
}

.mww-header__room > .mww-header__row > a {
  min-height: var(--mww-header-nav-height);
  padding-inline: 0;
  font-family: var(--mww-serif);
  font-size: 19px;
  font-weight: 600;
  letter-spacing: .01em;
  text-transform: uppercase;
}

.mww-header__room > .mww-header__row > a:hover,
.mww-header__room.is-open > .mww-header__row > a {
  color: var(--mww-accent);
}

.mww-header .mww-header__disclosure {
  width: 22px;
  min-height: var(--mww-header-row-height);
}

.mww-header__chevron {
  width: 12px;
  height: 12px;
  transition: transform .15s;
}

.mww-header__disclosure[aria-expanded="true"] .mww-header__chevron,
.mww-header__group[open] > summary .mww-header__chevron {
  transform: rotate(180deg);
}

/* Desktop with a mouse: rooms open on hover, so the chevron is just a small cue. */
@media (min-width: 1024px) and (hover: hover) and (pointer: fine) {
  .mww-header__room > .mww-header__row > .mww-header__disclosure {
    width: 16px;
    margin-left: 2px;
  }

  .mww-header__room > .mww-header__row .mww-header__chevron {
    width: 10px;
    height: 10px;
    stroke-width: 2;
  }
}

/* Mega panel (Menu Dropdown Mockup): white card under the bar, two link columns
   and a room photo. Closed = display:none via [hidden], so no ghost hitbox. */
.mww-header__mega {
  position: absolute;
  top: 100%;
  left: 50%;
  width: min(100%, calc(var(--mww-header-width) + 80px));
  max-height: calc(100dvh - var(--mww-header-nav-height) - var(--mww-header-admin-offset) - 16px);
  overflow-y: auto;
  overscroll-behavior: contain;
  background: #fff;
  box-shadow: 0 14px 30px rgba(0, 0, 0, .18);
  color: var(--mww-text);
  transform: translateX(-50%);
}

.mww-header__mega-inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 580px);
  align-items: start;
  gap: 40px;
  padding: 28px 36px 28px 110px;
}

.mww-header .mww-header__category-links {
  display: grid;
  grid-auto-flow: column;
  grid-template-rows: repeat(var(--mww-link-rows, 5), auto);
  grid-template-columns: repeat(2, minmax(0, 1fr));
  column-gap: 32px;
  padding-top: 40px;
}

.mww-header__category-links a {
  display: block;
  padding-block: 6px;
  font-size: 15px;
  line-height: 1.4;
}

.mww-header__category-links a:hover,
.mww-header__sublinks a:hover {
  color: var(--mww-accent-hover);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.mww-header__feature {
  display: block;
  aspect-ratio: 580 / 412;
  overflow: hidden;
  background: #f2f2f2;
}

.mww-header__feature-image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .4s ease;
}

.mww-header__feature:hover .mww-header__feature-image {
  transform: scale(1.03);
}

/* Hamburger dropdown (desktop): white card under the menu icon. */
.mww-header__utility {
  position: absolute;
  top: var(--mww-header-utility-top, 0px);
  right: max(16px, calc((100% - var(--mww-header-width)) / 2 + 16px));
  z-index: 2;
  width: 300px;
  max-height: calc(100dvh - var(--mww-header-main-height) - var(--mww-header-admin-offset) - 16px);
  padding: 8px 20px 12px;
  overflow-y: auto;
  overscroll-behavior: contain;
  border: 1px solid var(--mww-rule);
  background: #fff;
  box-shadow: 0 12px 30px rgba(0, 0, 0, .18);
  color: var(--mww-ink);
}

.mww-header-js .mww-header:not(.is-menu-open) .mww-header__utility {
  display: none;
}

.mww-header__utility-item + .mww-header__utility-item {
  border-top: 1px solid var(--mww-rule);
}

.mww-header__utility .mww-header__row > a {
  padding-inline: 0;
  font-family: var(--mww-serif);
  font-size: 18px;
  font-weight: 600;
  text-transform: uppercase;
}

.mww-header__utility .mww-header__row > a:hover {
  color: var(--mww-accent-hover);
}

.mww-header .mww-header__utility .mww-header__disclosure {
  width: 40px;
}

.mww-header__subpanel {
  padding: 0 0 10px 12px;
}

.mww-header__sublinks a {
  display: block;
  padding: 6px 0;
  font-size: 15px;
}

.mww-header__group summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-height: 36px;
  padding: 4px 0;
  cursor: pointer;
  list-style: none;
  font-weight: 600;
}

.mww-header__group summary::-webkit-details-marker {
  display: none;
}

.mww-header__group .mww-header__sublinks {
  padding-left: 12px;
}

/* No-JS fallback. .mww-header-js is set on <html> by an inline <head> script before
   first paint, so the closed state never waits on the deferred mww-header.js. */
html:not(.mww-header-js) .mww-header .mww-header__toggle,
html:not(.mww-header-js) .mww-header .mww-header__disclosure,
html:not(.mww-header-js) .mww-header .mww-header__mega {
  display: none;
}

html:not(.mww-header-js) .mww-header .mww-header__room:hover .mww-header__mega,
html:not(.mww-header-js) .mww-header .mww-header__room:focus-within .mww-header__mega {
  display: block !important; /* Beats the [hidden] rule the server renders. */
}

html:not(.mww-header-js) .mww-header .mww-header__utility {
  position: static;
  width: min(100%, var(--mww-header-width));
  max-height: none;
  margin-inline: auto;
  border: 0;
  box-shadow: none;
  background: transparent;
  color: #fff;
}

/* Bigger chevron targets on touch devices, including desktop-width tablets. */
@media (any-pointer: coarse) {
  .mww-header .mww-header__room > .mww-header__row > .mww-header__disclosure {
    width: 44px;
    min-height: 44px;
  }
}

/* Tighten the desktop bar before it collapses. */
@media (min-width: 1024px) and (max-width: 1240px) {
  :root {
    --mww-header-main-height: 150px;
  }

  .mww-header {
    --mww-header-gutter: 24px;
  }

  .mww-header__main {
    grid-template-columns: 132px minmax(200px, 400px) 1fr auto 34px;
    gap: 18px;
  }

  .mww-header__room > .mww-header__row > a {
    font-size: 17px;
  }

  .mww-header__mega-inner {
    padding-left: 48px;
  }
}

/* Mobile/tablet (Mobile Menu Mockups): logo | Quote List | menu, then a full-width
   search. The open menu covers the page below the logo row. */
@media (max-width: 1023px) {
  :root {
    --mww-header-mobile-height: 96px;
  }

  html.mww-header-menu-open {
    overflow: hidden;
  }

  .mww-header {
    --mww-header-gutter: 16px;
  }

  /* --mww-header-open-top (set by the JS on open) is the bottom of whatever sits
     above the header — admin bar, Banner 360 — so the open menu doesn't cover it.
     !important: Divi's mobile CSS sets #main-header { top: auto !important }. */
  #main-header.mww-header.is-menu-open {
    position: fixed;
    top: var(--mww-header-open-top, var(--mww-header-admin-offset)) !important;
    left: 0;
  }

  .mww-header.is-menu-open + .mww-header-spacer {
    display: block;
    height: calc(var(--mww-header-mobile-height) + 76px);
  }

  .mww-header__main {
    grid-template-columns: auto minmax(0, 1fr) auto 40px;
    grid-template-rows: auto auto;
    gap: 22px 14px;
    min-height: 0;
    padding-block: 12px 16px;
  }

  .mww-header__brand {
    grid-column: 1;
    grid-row: 1;
    width: 112px;
  }

  .mww-header .mww-header__showroom {
    display: none;
  }

  .mww-header .mww-header__quote {
    grid-column: 3;
    grid-row: 1;
  }

  .mww-header__toggle {
    grid-column: 4;
    grid-row: 1;
  }

  .mww-header .mww-header__toggle {
    width: 40px;
  }

  .mww-header__search {
    grid-column: 1 / -1;
    grid-row: 2;
    height: 44px;
  }

  .mww-header.is-menu-open .mww-header__search {
    display: none;
  }

  .mww-header.is-menu-open .mww-header__main {
    padding-bottom: 8px;
  }

  .mww-header .mww-header__search .vuer-search__input {
    font-size: 19px;
  }

  .mww-header .mww-header__search .vuer-search__icon {
    width: 20px;
    height: 20px;
  }

  /* Menu overlay: white list, serif uppercase rows, grey rules, chevrons on the right. */
  .mww-header__navigation {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    min-height: calc(100dvh - var(--mww-header-mobile-height) - var(--mww-header-open-top, var(--mww-header-admin-offset)));
    max-height: calc(100dvh - var(--mww-header-mobile-height) - var(--mww-header-open-top, var(--mww-header-admin-offset)));
    padding: 0 0 40px;
    overflow-y: auto;
    overscroll-behavior: contain;
    background: #fff;
    color: var(--mww-ink);
  }

  .mww-header-js .mww-header:not(.is-menu-open) .mww-header__navigation {
    display: none;
  }

  .mww-header__primary {
    max-width: none;
    padding: 0;
  }

  .mww-header .mww-header__rooms {
    display: block;
  }

  .mww-header__room,
  .mww-header .mww-header__utility-item,
  .mww-header .mww-header__utility-item + .mww-header__utility-item {
    border: 0;
    border-bottom: 1px solid #8a8a8a;
  }

  .mww-header .mww-header__room > .mww-header__row > a,
  .mww-header .mww-header__utility .mww-header__row > a {
    min-height: 52px;
    padding: 6px 0 6px 18px;
    font-family: var(--mww-serif);
    font-size: 19px;
    font-weight: 600;
    text-transform: uppercase;
  }

  .mww-header__room > .mww-header__row > a:hover,
  .mww-header__room.is-open > .mww-header__row > a {
    color: var(--mww-ink);
  }

  .mww-header .mww-header__disclosure,
  .mww-header .mww-header__room > .mww-header__row > .mww-header__disclosure,
  .mww-header .mww-header__utility .mww-header__disclosure {
    width: 60px;
    min-height: 52px;
  }

  .mww-header__row .mww-header__chevron,
  .mww-header__room > .mww-header__row .mww-header__chevron {
    width: 22px;
    height: 22px;
    stroke-width: 2.2;
  }

  .mww-header__mega {
    position: static;
    width: auto;
    max-height: none;
    overflow: visible;
    box-shadow: none;
    transform: none;
  }

  .mww-header__mega-inner {
    display: block;
    padding: 0 18px 12px 34px;
  }

  .mww-header .mww-header__category-links {
    display: block;
    padding-top: 0;
  }

  .mww-header__category-links a {
    padding-block: 9px;
    font-size: 16px;
  }

  .mww-header .mww-header__feature {
    display: none;
  }

  .mww-header__utility {
    position: static;
    width: 100%;
    max-height: none;
    padding: 0;
    overflow: visible;
    border: 0;
    box-shadow: none;
  }

  .mww-header__subpanel {
    padding: 0 18px 12px 34px;
  }

  .mww-header__sublinks a {
    padding-block: 9px;
    font-size: 16px;
  }

  html:not(.mww-header-js) .mww-header .mww-header__navigation {
    position: static;
    min-height: 0;
    max-height: none;
  }

  html:not(.mww-header-js) .mww-header .mww-header__mega {
    display: block !important;
  }

  html:not(.mww-header-js) .mww-header .mww-header__utility {
    color: var(--mww-ink);
  }
}

@media (max-width: 782px) {
  body.admin-bar {
    --mww-header-admin-offset: 46px;
  }
}

/* Phones. */
@media (max-width: 480px) {
  .mww-header__main {
    column-gap: 10px;
  }

  .mww-header__brand {
    width: 96px;
  }

  .mww-header .mww-header__quote {
    gap: 8px;
    min-height: 40px;
    padding: 4px 10px 4px 14px;
    font-size: 14px;
  }

  .mww-header .mww-header__toggle {
    width: 34px;
  }
}

@media (max-width: 340px) {
  .mww-header__brand {
    width: 78px;
  }

  .mww-header .mww-header__quote {
    padding-inline: 10px;
    font-size: 12px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .mww-header__feature-image,
  .mww-header__chevron,
  .mww-header .mww-header__quote {
    transition: none;
  }
}

@media print {
  .mww-header .mww-header__navigation,
  .mww-header .mww-header__search,
  .mww-header .mww-header__toggle,
  .mww-header .mww-header__quote {
    display: none;
  }
}

/* END MIDWEST WOODWORKS CUSTOM HEADER
   ========================================================================== */

/* ==========================================================================
   2. MIDWEST WOODWORKS SHORTCODES — [mww_rooms]
   Markup: includes/mww-shortcodes.php. [mww_subcats] reuses the existing
   .subcat-grid rules from Divi's custom CSS.
   ========================================================================== */

.mww-rooms {
  --mww-rooms-accent: var(--mww-ink);
  --mww-rooms-text: #fff;
  --mww-rooms-font: var(--mww-serif);
  display: grid;
  grid-template-columns: repeat(var(--mww-rooms-columns, 5), minmax(0, 1fr));
  gap: 30px 5.5%;
  margin: 0;
  padding: 0;
  list-style: none;
}

.mww-rooms__item {
  margin: 0;
  padding: 0;
  list-style: none;
}

.mww-rooms__link {
  display: flex;
  flex-direction: column;
  height: 100%;
  color: var(--mww-rooms-text);
  text-decoration: none;
}

.mww-rooms__image {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 6 / 5;
  object-fit: cover;
}

.mww-rooms__label {
  display: flex;
  flex: 1;
  align-items: center;
  justify-content: center;
  min-height: 87px;
  padding: 16px 12px;
  background: var(--mww-rooms-accent);
  color: var(--mww-rooms-text);
  font-family: var(--mww-rooms-font);
  font-size: 18px;
  font-weight: 500;
  line-height: 1.2;
  text-align: center;
}

/* Override the site-wide `a:hover { color: #333; text-decoration: underline }`
   (Divi custom CSS): a parent's underline can't be removed from the label, so it
   is cleared on the link and only the label's own white underline shows. */
.mww-rooms__link:hover,
.mww-rooms__link:focus {
  color: var(--mww-rooms-text);
  text-decoration: none;
}

.mww-rooms__link:hover .mww-rooms__label,
.mww-rooms__link:focus-visible .mww-rooms__label {
  text-decoration: underline;
  text-underline-offset: 4px;
}

.mww-rooms__link:focus-visible {
  outline: 2px solid var(--mww-rooms-accent);
  outline-offset: 3px;
}

@media (max-width: 980px) {
  .mww-rooms {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 767px) {
  .mww-rooms {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* [mww_subcats]: the old Divi custom CSS gives the grid `1fr 1fr` + a 4em gap below
   981px and the labels 25-30px !important padding, so on phones the padded labels
   force columns wider than the screen (right column runs off). Let columns shrink,
   tighten gap + labels on small screens. Desktop's 4 columns are unchanged. */
.subcat-grid-container .subcat-grid > .subcat-div {
  min-width: 0;
}

.subcat-grid-container .subcat-div .sub_cat_img_container img {
  display: block;
  width: 100%;
  height: auto;
  /* ProductBarn category images aren't all 6:5 (tall wardrobes, mirrors), so give
     every tile the same box and fit the photo inside; labels then line up. */
  aspect-ratio: 6 / 5;
  object-fit: contain;
}

@media (max-width: 981px) {
  .subcat-grid-container .subcat-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 24px;
  }
}

@media (max-width: 480px) {
  .subcat-grid-container .subcat-grid {
    column-gap: 14px;
  }

  .subcat-grid-container .sub_cat_link {
    margin-bottom: 18px;
    padding: 12px 0;
  }

  .subcat-grid-container .sub_cat_link p {
    padding: 16px 8px !important;
    font-size: 15px;
    line-height: 1.3;
    overflow-wrap: anywhere;
  }
}

.mww-shortcode-error {
  padding: 12px 16px;
  border-left: 4px solid #d63638;
  background: #fcf0f1;
  color: #1d2327;
}


/* ==========================================================================
   3. CLIENT VIEW (VUER) BUTTONS — per the Product Page Mockup
   Primary actions are orange pills with a black outline and black uppercase text.
   Vuer wraps product/toast buttons in :where() (zero specificity), so plain
   class selectors win; the checkout submit is doubled to beat its scoped rule.
   ========================================================================== */

:root {
  --mww-button-bg: var(--mww-accent);
  --mww-button-bg-hover: var(--mww-accent-hover);
  --mww-button-text: var(--mww-ink);
  --mww-button-font: var(--mww-sans);

  /* Vuer's own checkout/order accents (focus rings, highlights). */
  --vuer-checkout-primary: var(--mww-button-bg);
  --vuer-checkout-primary-contrast: #fff;
  --vuer-order-primary: var(--mww-button-bg);
  --vuer-order-primary-contrast: #fff;
}

.product-add-to-cart,
.add-to-quote-toast__button,
.vue-plugin-checkout-submit.vue-plugin-checkout-submit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  min-height: 48px;
  padding: 8px 24px;
  border: 2px solid var(--mww-ink);
  border-radius: 999px;
  background: var(--mww-button-bg);
  color: var(--mww-button-text);
  font-family: var(--mww-button-font);
  font-size: 18px;
  font-weight: 600;
  letter-spacing: .02em;
  line-height: 1.3;
  text-decoration: none;
  text-transform: uppercase;
  opacity: 1;
  cursor: pointer;
  transition: background-color .2s;
}

.add-to-quote-toast__button,
.add-to-quote-toast__button:visited {
  min-height: 44px;
  color: var(--mww-button-text);
}

:is(.product-add-to-cart, .add-to-quote-toast__button, .vue-plugin-checkout-submit.vue-plugin-checkout-submit):is(:hover, :focus-visible):not(:disabled, [aria-disabled="true"]) {
  background: var(--mww-button-bg-hover);
  color: var(--mww-button-text);
  opacity: 1;
}

:is(.product-add-to-cart, .add-to-quote-toast__button, .vue-plugin-checkout-submit.vue-plugin-checkout-submit):focus-visible {
  outline: 2px solid var(--mww-ink);
  outline-offset: 2px;
}

:is(.product-add-to-cart, .add-to-quote-toast__button, .vue-plugin-checkout-submit.vue-plugin-checkout-submit):is(:disabled, [aria-disabled="true"]) {
  opacity: .5;
  cursor: not-allowed;
}

@media (prefers-reduced-motion: reduce) {
  .product-add-to-cart,
  .add-to-quote-toast__button,
  .vue-plugin-checkout-submit.vue-plugin-checkout-submit {
    transition: none;
  }
}

/* ==========================================================================
   CLIENT VIEW PAGE LAYOUT — match the old Divi/WooCommerce archive
   Divi's container is 80% wide, capped at 1600px, with 58px top padding.
   Vuer sets max-width inline from its Content Width setting, hence !important.
   ========================================================================== */

article#vue-plugin-app {
  box-sizing: border-box;
  width: 80%;
  max-width: 1600px !important;
  margin-inline: auto;
  padding-top: 58px;
  padding-bottom: 50px;
}

/* Product cards: image fills the card at 6:5 (ProductBarn images are 1200x1000,
   the old 600x500 thumbnail ratio), centered serif title below. */
#vue-plugin-app .vue-plugin-product-card__link {
  gap: 0;
  padding: 0;
}

#vue-plugin-app .vue-plugin-product-card__image-wrap {
  width: 100%;
  aspect-ratio: 6 / 5;
}

#vue-plugin-app .vue-plugin-product-card__image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

#vue-plugin-app .vue-plugin-product-card__design-center-icon {
  top: 10px;
  left: 10px;
  width: 38px;
  height: 38px;
}

#vue-plugin-app .vue-plugin-product-card__heading {
  margin-top: 9px;
}

#vue-plugin-app .vue-plugin-product-card__title {
  padding: 8px 0;
  font-size: 16px;
  line-height: 1.5;
}

#vue-plugin-app .vue-plugin-product-stack--products {
  gap: 48px 44px;
}

@media (max-width: 980px) {
  article#vue-plugin-app {
    padding-top: 40px;
  }
}

/* ==========================================================================
   CLIENT VIEW PRODUCT PAGE — match the old WooCommerce single product
   Desktop: gallery 668 / summary 438 of the 1152px container (58:38), 46px gap,
   controls full column width, breadcrumbs above both columns so the image and
   title share a top line, 4 thumbnails per row. Mobile keeps Vuer's layout.
   ========================================================================== */

@media (min-width: 981px) {
  article#vue-plugin-app.product-page {
    padding-top: 30px;
  }

  #vue-plugin-app .product-information {
    margin-top: 0;
  }

  #vue-plugin-app .product-desktop-sticky-boundary {
    position: relative;
    grid-template-columns: minmax(0, 668fr) minmax(0, 438fr);
    column-gap: 46px;
    padding-top: 40px;
  }

  #vue-plugin-app .product-desktop-sticky-boundary .product-breadcrumbs {
    position: absolute;
    top: 0;
    left: 0;
    margin: 0;
  }

  #vue-plugin-app .description-dropdown,
  #vue-plugin-app .product-variation-options,
  #vue-plugin-app .vue-plugin-product-notes,
  #vue-plugin-app .product-add-to-cart,
  #vue-plugin-app .add-to-quote-toast {
    max-width: none;
  }

  #vue-plugin-app .product-thumbnails {
    margin-top: 44px;
  }

  #vue-plugin-app .product-thumbnails ul {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 20px 44px;
  }

  #vue-plugin-app .product-thumbnails__button {
    width: 100%;
  }

  #vue-plugin-app .product-thumbnails__button img {
    width: 100%;
    height: auto;
    aspect-ratio: 1;
    object-fit: cover;
  }
}

/* Product Page Mockup details: black-outlined dropdowns, orange "Add Note",
   round zoom badge on the main image, roomier gap above Add to Quote. */
#vue-plugin-app .product-dropdown__toggle {
  min-height: 56px;
  padding: 8px 56px 8px 12px;
  border: 2px solid var(--mww-ink);
  border-radius: 0;
  background-color: #fff;
  color: #111;
  font-family: var(--mww-button-font);
  font-size: 17px;
  font-weight: 400;
  text-transform: uppercase;
}

#vue-plugin-app .product-variation-options {
  margin-top: 28px;
}

/* "Made by {builder}" box under the title (relabelled in includes/mww-client-view.php).
   Hidden until relabelled so Vuer's "Builder:" wording never flashes. */
#vue-plugin-app .vuer-product-builders {
  box-sizing: border-box;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  margin: 24px 0 36px;
  padding: 8px 16px;
  border: 2px solid var(--mww-muted);
  color: var(--mww-muted);
  font-family: var(--mww-sans);
  font-size: 17px;
  font-weight: 600;
  line-height: 1.3;
  text-align: center;
}

#vue-plugin-app .vuer-product-builders:not(.is-made-by) {
  visibility: hidden;
}

#vue-plugin-app .vue-plugin-product-notes {
  margin-top: 14px;
  padding-left: 16px;
}

#vue-plugin-app .vue-plugin-add-note-link {
  color: var(--mww-button-bg);
  font-family: var(--mww-button-font);
  font-size: 14px;
  font-weight: 400;
  text-decoration: underline;
  text-underline-offset: 3px;
}

#vue-plugin-app .vue-plugin-add-note-link:hover {
  color: var(--mww-button-bg-hover);
}

#vue-plugin-app .product-cta {
  margin-top: 40px;
}

/* Buttons per the mockup: outlined "Explore Color Options" (Client View's second CTA)
   above the orange quote button, with the custom-piece line on top. The line is
   added by includes/mww-client-view.php. */
#vue-plugin-app .priced-cta {
  gap: 22px;
}

#vue-plugin-app .product-second-cta {
  order: -1;
}

#vue-plugin-app .product-second-cta,
#vue-plugin-app .product-second-cta:visited {
  background: #fff;
  color: var(--mww-ink);
}

#vue-plugin-app .product-second-cta:is(:hover, :focus-visible) {
  background: var(--mww-accent-soft);
  color: var(--mww-ink);
}

#vue-plugin-app .mww-custom-piece {
  margin: 0 0 22px;
  padding: 0;
  color: var(--mww-ink);
  font-family: var(--mww-sans);
  font-size: 17px;
  line-height: 1.5;
}

#vue-plugin-app .mww-custom-piece a {
  color: var(--mww-accent-hover);
  text-decoration: none;
}

#vue-plugin-app .mww-custom-piece a:hover,
#vue-plugin-app .mww-custom-piece a:focus-visible {
  text-decoration: underline;
  text-underline-offset: 3px;
}

#vue-plugin-app .vuer-product-image-trigger {
  position: relative;
}

#vue-plugin-app .vuer-product-image-trigger::after {
  content: "";
  position: absolute;
  right: 24px;
  bottom: 24px;
  width: 48px;
  height: 48px;
  border: 1px solid rgba(0, 0, 0, .25);
  border-radius: 50%;
  background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='13.5' cy='10.5' r='6'/%3E%3Cpath d='m9.2 14.8-5.2 5.2'/%3E%3C/svg%3E") center / 22px no-repeat;
  box-shadow: 0 3px 8px rgba(0, 0, 0, .25);
  pointer-events: none;
}

/* "Added to your quote" bar under Add to Quote: space it off the button and give it
   back the padded box Vuer intends (its :where() styles lose to the site's globals). */
#vue-plugin-app .add-to-quote-toast {
  align-items: center;
  gap: 16px;
  margin-top: 16px;
  padding: 12px 12px 12px 18px;
  border: 1px solid rgba(0, 0, 0, .08);
  border-radius: 3px;
  background: #f5f5f5;
}
