/* MessageCard Boutique v4.5.5 - product option layout refinement
 * Adds styling only. No changes to dropdown values, attribute IDs,
 * prices, validation, cart or checkout behavior.
 * Loaded after v4.5.0 mobile CSS by its filename.
 */
body.tpl_messagecard #productGeneral #productAttributes {
  display: flex !important;
  flex-direction: column !important;
  gap: 0 !important;
  min-width: 0 !important;
  min-height: 0 !important;
  height: auto !important;
  margin: 0 0 13px !important;
  padding: 18px 20px 6px !important;
  overflow: visible !important;
  border: 1px solid #e6dbd2 !important;
  border-radius: 12px !important;
  background: #fcf9f6 !important;
  box-shadow: 0 4px 20px rgba(84, 57, 43, .035);
}

/* Section heading: retain the store's actual Zen Cart text. */
body.tpl_messagecard #productGeneral #attribsOptionsText {
  display: block !important;
  width: 100% !important;
  margin: 0 !important;
  padding: 0 0 12px !important;
  border-bottom: 1px solid #eadfd7 !important;
  color: #644b40 !important;
  font-size: 14px !important;
  font-weight: 700 !important;
  line-height: 1.6 !important;
  letter-spacing: .03em;
}

/* Reset old float / spacer rules that made the two options very tall. */
body.tpl_messagecard #productGeneral #productAttributes .attribBlock {
  display: block !important;
  flex: 0 0 auto !important;
  min-width: 0 !important;
  min-height: 0 !important;
  height: auto !important;
  margin: 0 !important;
  padding: 13px 0 14px !important;
  border: 0 !important;
  background: transparent !important;
  float: none !important;
  clear: both !important;
}
body.tpl_messagecard #productGeneral #productAttributes .attribBlock + .attribBlock {
  border-top: 1px solid #ece2db !important;
}
body.tpl_messagecard #productGeneral #productAttributes .wrapperAttribsOptions {
  display: flex !important;
  flex-direction: column !important;
  gap: 7px !important;
  min-width: 0 !important;
  min-height: 0 !important;
  height: auto !important;
  width: 100% !important;
  float: none !important;
  clear: both !important;
  margin: 0 !important;
  padding: 0 !important;
}
body.tpl_messagecard #productGeneral #productAttributes .wrapperAttribsOptions > .back {
  display: block !important;
  width: 100% !important;
  min-width: 0 !important;
  height: auto !important;
  float: none !important;
  clear: both !important;
  margin: 0 !important;
  padding: 0 !important;
}
body.tpl_messagecard #productGeneral #productAttributes h4.optionName {
  display: block !important;
  float: none !important;
  clear: both !important;
  width: 100% !important;
  min-height: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  color: #5d493e !important;
  font-size: 13px !important;
  font-weight: 700 !important;
  line-height: 1.6 !important;
  letter-spacing: .025em;
}
/* The Zen Cart template includes float-clearing BR tags after each input. */
body.tpl_messagecard #productGeneral #productAttributes br.clearBoth {
  display: none !important;
}

/* Natural-size form controls with a consistent arrow and focus state. */
body.tpl_messagecard #productGeneral #productAttributes .wrapperAttribsOptions select {
  -webkit-appearance: none !important;
  appearance: none !important;
  display: block !important;
  box-sizing: border-box !important;
  width: 100% !important;
  min-width: 0 !important;
  min-height: 48px !important;
  height: 48px !important;
  max-width: 100% !important;
  margin: 0 !important;
  padding: 10px 43px 10px 14px !important;
  border: 1px solid #d8c7bc !important;
  border-radius: 8px !important;
  background-color: #ffffff !important;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 24 24' fill='none' stroke='%23876556' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") !important;
  background-repeat: no-repeat !important;
  background-position: right 14px center !important;
  background-size: 17px 17px !important;
  color: #493a33 !important;
  font-size: 14px !important;
  font-weight: 500 !important;
  line-height: 1.5 !important;
  text-overflow: ellipsis;
  box-shadow: 0 1px 2px rgba(70, 44, 30, .025);
  cursor: pointer;
  transition: border-color .18s ease, box-shadow .18s ease;
}
body.tpl_messagecard #productGeneral #productAttributes .wrapperAttribsOptions select:hover {
  border-color: #ad8776 !important;
}
body.tpl_messagecard #productGeneral #productAttributes .wrapperAttribsOptions select:focus,
body.tpl_messagecard #productGeneral #productAttributes .wrapperAttribsOptions select:focus-visible {
  outline: 2px solid #a87966 !important;
  outline-offset: 2px !important;
  border-color: #946c5b !important;
  box-shadow: 0 0 0 3px rgba(159, 112, 91, .12) !important;
}
body.tpl_messagecard #productGeneral #productAttributes .wrapperAttribsOptions :is(input[type='radio'],input[type='checkbox']) {
  accent-color: #946254;
}

/* Keep optional attribute descriptions compact and readable. */
body.tpl_messagecard #productGeneral #productAttributes :is(.attributesComments, .ProductInfoComments) {
  margin: 4px 0 8px !important;
  padding: 0 !important;
  color: #827066 !important;
  font-size: 12px !important;
  line-height: 1.7 !important;
}

/* Form controls remain touch-friendly on narrow displays. */
@media screen and (max-width: 700px) {
  body.tpl_messagecard #productGeneral #productAttributes {
    padding: 16px 15px 5px !important;
    margin-bottom: 12px !important;
  }
  body.tpl_messagecard #productGeneral #attribsOptionsText {
    font-size: 14px !important;
    padding-bottom: 11px !important;
  }
  body.tpl_messagecard #productGeneral #productAttributes .attribBlock {
    padding: 13px 0 !important;
  }
  body.tpl_messagecard #productGeneral #productAttributes h4.optionName {
    font-size: 14px !important;
  }
  body.tpl_messagecard #productGeneral #productAttributes .wrapperAttribsOptions select {
    min-height: 50px !important;
    height: 50px !important;
    font-size: 16px !important; /* Prevent automatic iOS input zoom. */
    padding-right: 44px !important;
  }
}
@media (prefers-reduced-motion: reduce) {
  body.tpl_messagecard #productGeneral #productAttributes select { transition: none !important; }
}
