/* HAY LIVIN Mix & Match Set Builder presentation. */

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match {
  margin: 1.5rem 0 1.25rem;
  padding: 1.25rem 0 0;
  border-top: 1px solid var(--hay-border, #ded8d2);
}

/* The set builder belongs to the product summary, not the narrow quantity
 * column created by the summary cart form. */
body.haylivin-site.haylivin-woocommerce-product .summary form.cart > .haylivin-mix-match,
body.haylivin-site.haylivin-woocommerce-product .summary .woocommerce-variation-add-to-cart > .haylivin-mix-match {
  grid-column: 1 / -1;
  width: 100%;
  min-width: 0;
  margin-left: 0;
  margin-right: 0;
}

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__title {
  margin: 0;
  color: var(--hay-black, #111111);
  font-family: var(--hay-heading-font, "Bodoni Moda", serif);
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__intro,
body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__status {
  margin: 0.5rem 0 0;
  color: #77716c;
  font-size: 0.8125rem;
  line-height: 1.5;
}

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__group {
  min-width: 0;
  margin: 1.25rem 0 0;
  padding: 0;
  border: 0;
}

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__group legend {
  width: 100%;
  margin-bottom: 0.65rem;
  color: var(--hay-black, #111111);
  font-size: 0.875rem;
  font-weight: 700;
}

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__group legend small {
  color: #77716c;
  font-size: 0.75rem;
  font-weight: 400;
}

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__choices {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(7.5rem, 1fr));
  gap: 0.75rem;
  min-width: 0;
}

/* Two choices should use the available row rather than leaving an empty
 * third track; the same rule naturally collapses a one-choice group. */
body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__choices:not(:has(> .haylivin-mix-match__choice-row:nth-child(3))) {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__choices:has(> .haylivin-mix-match__choice-row:only-child) {
  grid-template-columns: minmax(0, 1fr);
}

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__choice-row {
  display: flex;
  min-width: 0;
  flex-direction: column;
  align-items: stretch;
  gap: 0.5rem;
}

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__choice {
  display: flex;
  width: 100%;
  min-width: 0;
  min-height: 15rem;
  box-sizing: border-box;
  flex: 1 1 auto;
  flex-direction: column;
  padding: 0;
  border: 1px solid #d6d0ca;
  border-radius: 0;
  background: var(--hay-white, #ffffff);
  color: var(--hay-black, #111111);
  font: inherit;
  text-align: left;
  cursor: pointer;
  transition: border-color 160ms ease, box-shadow 160ms ease, background-color 160ms ease;
}

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__choice:hover,
body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__choice:focus-visible {
  border-color: var(--hay-orange, #ff5c00);
  box-shadow: 0 0 0 2px rgba(255, 92, 0, 0.15);
}

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__choice.is-selected {
  border-color: var(--hay-orange, #ff5c00);
  background: #fffaf7;
  box-shadow: 0 0 0 2px rgba(255, 92, 0, 0.18);
}

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__choice:disabled {
  cursor: not-allowed;
  opacity: 0.58;
}

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__image {
  display: flex;
  width: 100%;
  height: 9.5rem;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: #faf9f7;
}

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__image img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
}

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__card-content {
  display: grid;
  min-width: 0;
  flex: 1 1 auto;
  gap: 0.25rem;
  padding: 0.75rem 0.8rem 0.8rem;
}

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__name,
body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__variation,
body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__price {
  min-width: 0;
  overflow-wrap: anywhere;
}

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__name {
  color: var(--hay-black, #111111);
  font-size: 0.86rem;
  line-height: 1.35;
}

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__variation {
  display: none;
  color: #77716c;
  font-size: 0.73rem;
  line-height: 1.35;
}

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__price {
  color: var(--hay-orange, #ff5c00);
  font-size: 0.82rem;
  font-weight: 600;
}

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__quantity {
  display: inline-flex;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  min-height: 2.65rem;
  align-self: center;
  align-items: center;
  justify-content: space-between;
  border: 1px solid #d6d0ca;
  background: var(--hay-white, #ffffff);
}

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__quantity button {
  flex: 0 0 2.65rem;
  width: 2.65rem;
  height: 2.65rem;
  border: 0;
  background: transparent;
  color: var(--hay-black, #111111);
  font-size: 1.1rem;
  line-height: 1;
  cursor: pointer;
}

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__quantity button:hover,
body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__quantity button:focus-visible {
  background: #f5eee9;
  color: var(--hay-orange, #ff5c00);
}

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__quantity output {
  min-width: 1.5rem;
  color: var(--hay-black, #111111);
  font-size: 0.85rem;
  text-align: center;
}

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__status.is-invalid,
body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__error {
  color: #a33a2b;
}

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__assembly {
  margin: 1.35rem 0 0;
  padding: 0;
  border: 0;
}

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__assembly legend {
  margin-bottom: 0.55rem;
  color: var(--hay-black, #111111);
  font-size: 0.8125rem;
  font-weight: 700;
}

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__assembly-options {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.65rem;
}

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__assembly-options label {
  display: flex;
  min-height: 2.8rem;
  align-items: center;
  gap: 0.55rem;
  padding: 0.65rem 0.8rem;
  border: 1px solid #d6d0ca;
  color: var(--hay-black, #111111);
  font-size: 0.8125rem;
  cursor: pointer;
}

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__assembly-options label:has(input:checked) {
  border-color: var(--hay-orange, #ff5c00);
  background: #fffaf7;
}

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__assembly-options input {
  accent-color: var(--hay-orange, #ff5c00);
}

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__pricing {
  display: grid;
  gap: 0.3rem;
  margin-top: 1.25rem;
  padding-top: 0.9rem;
  border-top: 1px solid #e4ded8;
  color: #77716c;
  font-size: 0.8125rem;
}

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__pricing p {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  margin: 0;
}

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__pricing output {
  color: var(--hay-black, #111111);
  white-space: nowrap;
}

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__pricing .haylivin-mix-match__total {
  margin-top: 0.35rem;
  padding-top: 0.6rem;
  border-top: 1px solid #e4ded8;
  color: var(--hay-black, #111111);
}

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__pricing .haylivin-mix-match__total output {
  color: var(--hay-orange, #ff5c00);
  font-weight: 700;
}

body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__error {
  margin-top: 0.75rem;
}

/* Cart Block set controls. Component rows remain read-only; Edit Set is the
 * only supported way to change a grouped selection. */
.wc-block-cart .haylivin-mix-match-block__controls {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1rem;
  margin-top: 0.65rem;
  font-size: 0.8125rem;
  line-height: 1.4;
}

.wc-block-cart .haylivin-mix-match-block__controls a {
  color: var(--hay-black, #111111);
  text-decoration: underline;
  text-underline-offset: 0.16em;
}

.wc-block-cart .haylivin-mix-match-block__controls a:hover,
.wc-block-cart .haylivin-mix-match-block__controls a:focus-visible {
  color: var(--hay-orange, #ff4202);
}

.wc-block-cart .haylivin-mix-match-block__controls a:focus-visible {
  outline: 2px solid var(--hay-orange, #ff4202);
  outline-offset: 2px;
}

.wc-block-cart .haylivin-mix-match-block__component .wc-block-cart-item__remove-link,
.wc-block-cart .haylivin-mix-match-block__component .wc-block-components-product-details__remove,
.wc-block-cart .haylivin-mix-match-block__component .wc-block-components-quantity-selector,
.wc-block-cart .haylivin-mix-match-block__component .wc-block-cart-item__quantity {
  display: none !important;
}

.wc-block-cart .haylivin-mix-match-block__base .wc-block-cart-item__remove-link {
  display: none !important;
}

@media (max-width: 900px) {
  body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__choices {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 767px) {
  body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match {
    margin-top: 1.25rem;
    padding-top: 1rem;
  }

  body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__choice {
    min-height: 0;
  }

  body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__image {
    height: 7rem;
  }

  body.haylivin-site.haylivin-woocommerce-product .haylivin-mix-match__assembly-options {
    grid-template-columns: 1fr;
  }

  .wc-block-cart .haylivin-mix-match-block__controls {
    gap: 0.55rem 0.85rem;
  }
}