/*
 * Mercer Lab Supply: what the reference stylesheet does not cover (messages,
 * page text, the request forms, checkout and the account pages).  Built from
 * the reference stylesheet's colors, sizes and borders and nothing new.
 * Where the reference styles a thing (forms, the cart, quick order, totals,
 * the pricing panel), the reference stands; the generic rules here are
 * wrapped in :where() so they never outweigh it.
 */

/* ---------- messages ---------- */

.notices { margin-bottom: 16px; }
.notices ul { margin: 0; padding: 0; list-style: none; }
.woocommerce-error, .woocommerce-message, .woocommerce-info, .mercer-notice {
  margin: 0 0 8px; padding: 10px 12px; border: 1px solid var(--rule); background: var(--tint);
  font-size: 13px; line-height: 18px; list-style: none;
}
.woocommerce-error, .mercer-notice-error { border-color: var(--warn); color: var(--warn); }
.woocommerce-error li + li { margin-top: 4px; }
.woocommerce-error a, .woocommerce-message a, .woocommerce-info a { text-decoration: underline; }
.woocommerce-message .button, .woocommerce-info .button { float: none; margin-left: 8px; }
.warn { color: var(--warn); }
.after-lede { margin-top: 16px; max-width: 520px; }
.after-lede .rail ul, .body.rail ul { margin: 0; }
.data td.empty { color: var(--ink-2); }
.pages a, .pages span { margin-right: 8px; }
.form > .error, main > .frame > .error { margin-top: 12px; font-size: 13px; }

/* ---------- page text ---------- */

.prose { margin-top: 12px; max-width: 760px; }
.prose h2 { margin: 20px 0 6px; }
.prose h3 { margin: 16px 0 6px; font-size: 14px; line-height: 20px; }
.prose p, .prose ul, .prose ol { margin: 0 0 10px; }
.prose ul { list-style: disc; padding-left: 20px; }
.prose ol { padding-left: 20px; list-style: decimal; }
.prose table { margin: 0 0 12px; }

/* ---------- the sign-in password, beside the reference's fields ---------- */

.field input[type=password] {
  display: block; width: 100%; height: 32px; margin-top: 3px; padding: 0 8px;
  border: 1px solid var(--rule-2); border-radius: 2px; background: #fff;
  font: 14px var(--font-sans); color: var(--ink);
}

/* ---------- request forms, checkout and account forms ---------- */

.mercer-form, .mercer-form-wrap { max-width: 520px; margin-top: 12px; }
:where(.mercer-form .field, .mercer-field, .form-row) { margin: 0 0 12px; }
:where(.mercer-form label, .mercer-field label, .form-row label, .co label) {
  display: block; margin-bottom: 4px; font-size: 13px; line-height: 18px; font-weight: 700; color: var(--ink);
}
.mercer-required, .form-row .required, .form-row .optional { font-weight: 400; color: var(--ink-2); font-size: 12px; }
.form-row abbr.required { text-decoration: none; border: 0; }
.mercer-hp { position: absolute; left: -9999px; }
:where(.mercer-form, .co, .woocommerce-MyAccount-content, .woocommerce-ResetPassword, .woocommerce-form)
  :where(input[type="text"], input[type="email"], input[type="tel"], input[type="password"], input[type="url"], input[type="date"], select, textarea, .input-text) {
  width: 100%; height: 32px; padding: 0 8px;
  border: 1px solid var(--rule-2); border-radius: 2px; background: #fff;
  font: 14px var(--font-sans); color: var(--ink);
}
:where(.mercer-form, .co, .woocommerce-MyAccount-content) :where(textarea) { height: auto; min-height: 96px; padding: 6px 8px; line-height: 20px; }
:where(input[type="file"]) { font: 13px var(--font-sans); }
:where(select, textarea):focus { outline: 2px solid var(--link); outline-offset: 1px; }
.woocommerce-invalid input, .woocommerce-invalid select { border-color: var(--warn); }
.field .msg { display: block; margin-top: 4px; font-size: 12px; line-height: 18px; color: var(--warn); }
.mercer-form button, .mercer-form-wrap button, .wp-element-button, .woocommerce-Button, .woocommerce-button, .button, button.alt {
  display: inline-block; height: 32px; padding: 0 14px;
  border: 1px solid var(--navy); border-radius: 2px; background: var(--navy); color: #fff;
  font: 700 13px/30px var(--font-sans); cursor: pointer; white-space: nowrap;
}
.mercer-form button:hover, .wp-element-button:hover, .button:hover, button.alt:hover { background: var(--navy-2); border-color: var(--navy-2); color: #fff; text-decoration: none; }

/* ---------- cart ---------- */

.cart-form .enter { position: absolute; left: -9999px; }

/* ---------- checkout ---------- */

.co { max-width: 900px; margin-top: 12px; }
.co-sec { margin-top: 24px; }
.co-sec > h2 { padding-bottom: 6px; margin-bottom: 12px; border-bottom: 1px solid var(--rule); }
.co-fields { display: grid; grid-template-columns: 1fr 1fr; column-gap: 16px; }
.co-fields .form-row-wide, .co-fields #billing_email_field, .co-fields #billing_address_1_field, .co-fields #shipping_address_1_field,
.co-fields #billing_address_2_field, .co-fields #shipping_address_2_field, .co-fields #billing_company_field, .co-fields #shipping_company_field { grid-column: 1 / -1; }
.co-same-input { margin: 0 6px 12px 0; vertical-align: middle; }
.co-same { display: inline !important; font-weight: 400 !important; }
.co-same-input:checked ~ .co-billing { display: none; }
.co .ship { display: block; font-size: 12px; line-height: 18px; color: var(--ink-2); }
.wc_payment_methods { list-style: none; border: 1px solid var(--rule); }
.wc_payment_methods > li { padding: 10px 12px; border-bottom: 1px solid var(--rule); }
.wc_payment_methods > li:last-child { border-bottom: 0; }
.wc_payment_methods > li > label { display: inline; font-weight: 700; }
.wc_payment_methods input[type="radio"] { margin: 0 6px 0 0; vertical-align: middle; }
.payment_box { margin-top: 8px; font-size: 13px; line-height: 18px; }
.payment_box p { margin-bottom: 8px; }
.review .totals th { text-align: left; }
.co-place { margin-top: 24px; padding-top: 16px; border-top: 1px solid var(--rule); }
.co-ruo input { margin: 0 6px 0 0; vertical-align: middle; }
.co-ruo label { display: inline; font-weight: 400; }
.co-button { margin-top: 16px; display: flex; align-items: center; gap: 16px; }
.place-total { font-size: 14px; line-height: 20px; font-weight: 700; }
.blockUI.blockOverlay { background: #fff !important; opacity: 0.6 !important; }
.select2-container .select2-selection--single { height: 32px; border: 1px solid var(--rule-2); border-radius: 2px; }
.select2-container .select2-selection--single .select2-selection__rendered { line-height: 30px; padding-left: 8px; color: var(--ink); }
.select2-container .select2-selection--single .select2-selection__arrow { height: 30px; }
.screen-reader-text { position: absolute; left: -9999px; }

/* ---------- account ---------- */

.woocommerce-MyAccount-navigation ul { display: flex; flex-wrap: wrap; gap: 4px 20px; margin: 12px 0 16px; padding-bottom: 8px; border-bottom: 1px solid var(--rule); }
.woocommerce-MyAccount-navigation .is-active a { color: var(--ink); font-weight: 700; }
:where(.woocommerce-MyAccount-content) table:not(.spec) { border: 1px solid var(--rule); font-size: 13px; line-height: 18px; margin-bottom: 12px; }
:where(.woocommerce-MyAccount-content) table:not(.spec) :where(th, td) { padding: 7px 12px; border-bottom: 1px solid var(--rule); text-align: left; }
:where(.woocommerce-MyAccount-content) table:not(.spec) thead th { background: var(--tint); font-size: 12px; }
.woocommerce-MyAccount-content address { font-style: normal; }
.account-standing { max-width: 560px; margin: 4px 0 16px; }

@media (max-width: 860px) {
  .co-fields { grid-template-columns: minmax(0, 1fr); }
}

@media print {
  .notices, .actions, .co-button, .mercer-form { display: none; }
}
