/* WooCommerce's own cart, checkout, account and notices, styled to match the design.
   Selectors start from body so they outrank WooCommerce's stylesheets, which may load later. */

/* Page frame */
body.woocommerce-cart main,
body.woocommerce-checkout main,
body.woocommerce-account main { padding-bottom: 64px; }

/* Shared block parts */
body .wc-block-components-title,
body .wc-block-cart__totals-title {
  font-family: var(--font);
  font-size: 18px;
  font-weight: 800;
  text-transform: uppercase;
  color: var(--red-ink);
}
body .wc-block-components-product-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--ink);
  text-decoration: none;
}
body .wc-block-components-product-name:hover { color: var(--red-ink); }
body .wc-block-components-product-metadata,
body .wc-block-components-product-details { font-size: 13px; color: var(--muted); }
body .wc-block-components-totals-item { font-size: 14px; }
body .wc-block-components-totals-footer-item {
  font-size: 17px;
  font-weight: 800;
  color: var(--red-ink);
}
body .wc-block-components-totals-wrapper { border-color: var(--line); }

/* Main buttons */
body .wc-block-components-button:not(.is-link),
body .wc-block-cart__submit-button,
body .wc-block-components-checkout-place-order-button {
  min-height: 52px;
  padding: 12px 24px;
  border: 2px solid var(--red);
  border-radius: 999px;
  background: var(--red);
  color: #fff;
  font-family: var(--font);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  transition: background-color 0.2s, border-color 0.2s;
}
body .wc-block-components-button:not(.is-link):hover,
body .wc-block-cart__submit-button:hover,
body .wc-block-components-checkout-place-order-button:hover {
  background: var(--red-dark);
  border-color: var(--red-dark);
  color: #fff;
}

/* Cart */
body .wc-block-cart { padding-top: 12px; }
body .wc-block-cart-items {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  border-collapse: separate;
  background: #fff;
}
body .wc-block-cart-items__header { font-size: 12px; color: var(--muted); }
body .wc-block-cart table.wc-block-cart-items .wc-block-cart-items__header th { padding: 12px 16px; border-bottom: 1px solid var(--line); }
body .wc-block-cart table.wc-block-cart-items .wc-block-cart-items__row td { border-top: 1px solid var(--line); padding: 16px; }
body .wc-block-cart table.wc-block-cart-items .wc-block-cart-items__row:first-child td { border-top: 0; }
body .wc-block-cart .wc-block-cart__totals-title { color: var(--red-ink); font-size: 16px; font-weight: 800; }
@media (max-width: 700px) {
  body .wc-block-cart table.wc-block-cart-items,
  body .wc-block-cart table.wc-block-cart-items tbody { display: block; width: 100%; }
  body .wc-block-cart table.wc-block-cart-items .wc-block-cart-items__row {
    grid-template-columns: 64px minmax(0, 1fr) auto;
    column-gap: 12px;
    padding: 16px;
    border-top: 1px solid var(--line);
  }
  body .wc-block-cart table.wc-block-cart-items .wc-block-cart-items__row:first-child { border-top: 0; }
  body .wc-block-cart table.wc-block-cart-items .wc-block-cart-items__row td { padding: 0; border-top: 0; }
}
body .wc-block-cart-item__total { font-weight: 800; color: var(--red-ink); }
body .wc-block-cart-item__remove-link { color: var(--red); font-size: 13px; font-weight: 600; }
body .wc-block-components-quantity-selector {
  width: 120px;
  border: 1px solid var(--line);
  border-radius: 999px;
}
body .wc-block-components-quantity-selector::after { display: none; }
body .wc-block-components-quantity-selector__button { color: var(--red-ink); }
body .wc-block-components-quantity-selector__input { font-weight: 700; }
body .wc-block-cart .wc-block-cart__main { min-width: 0; max-width: 100%; }
body .wc-block-cart table.wc-block-cart-items { width: 100%; max-width: 100%; }
body .wc-block-cart .wc-block-cart__sidebar {
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
}
.free-note {
  margin: 12px 0 16px;
  padding: 12px 16px;
  border-radius: var(--radius);
  background: var(--red-soft);
  color: var(--red-ink);
  font-size: 14px;
  font-weight: 600;
}

/* Empty cart */
body .wp-block-woocommerce-empty-cart-block { padding: 40px 0 0; }
body .wp-block-woocommerce-empty-cart-block .wc-block-cart__empty-cart__title { color: var(--muted); font-size: 18px; font-weight: 600; }
body .wp-block-woocommerce-empty-cart-block > h2 { font-size: 22px; text-transform: uppercase; color: var(--red-ink); }
body .wp-block-woocommerce-empty-cart-block .wc-block-grid__product-title { font-size: 14px; font-weight: 600; color: var(--red-ink); }
body .wp-block-woocommerce-empty-cart-block .wc-block-grid__product-link { text-decoration: none; }
body .wp-block-woocommerce-empty-cart-block .wp-block-button__link {
  border-radius: 999px;
  background: var(--red);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  text-decoration: none;
}
body .wp-block-woocommerce-empty-cart-block .wp-block-separator { border-color: var(--line); }

/* Checkout */
body .wc-block-components-checkout-step__title { font-size: 18px; text-transform: uppercase; color: var(--red-ink); }
body .wc-block-components-checkout-step__description { color: var(--muted); }
body .wc-block-components-text-input input,
body .wc-block-components-combobox .components-combobox-control input,
body .wc-block-components-country-input select,
body .wc-block-components-state-input select,
body .wc-blocks-components-select__select,
body .wc-block-components-textarea {
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--ink);
  font-family: var(--font);
}
/* The design's inherited line height pushes WooCommerce's floating label into the typed value. */
body .wc-block-components-text-input input { line-height: 1.2; }
body .wc-block-components-text-input label { line-height: 1.2; }
body .wc-block-components-text-input.is-active label { font-size: 11px; }
body .wc-block-components-text-input.is-active input { padding-top: 22px; padding-bottom: 6px; }
body .wc-block-components-text-input input:focus,
body .wc-block-components-combobox .components-combobox-control input:focus,
body .wc-blocks-components-select__select:focus { border-color: var(--red); box-shadow: 0 0 0 1px var(--red); }
body .wc-block-components-radio-control__option { color: var(--text); }
body .wc-block-components-radio-control__input:checked { border-color: var(--red); }
body .wc-block-components-radio-control__input:checked::before { background: var(--red); }
body .wc-block-components-checkbox__input:checked { background: var(--red); border-color: var(--red); }
body .wc-block-components-checkbox__mark { fill: #fff; }
body .wc-block-components-checkout-return-to-cart-button { color: var(--red); font-weight: 600; }

/* Notices, on block and classic pages */
body .woocommerce-message,
body .woocommerce-info,
body .woocommerce-error {
  margin: 16px 0;
  border-top-color: var(--red);
  border-radius: 6px;
  background: var(--red-soft);
  color: var(--text);
  list-style: none;
}
body .woocommerce-message::before,
body .woocommerce-info::before,
body .woocommerce-error::before { color: var(--red); }

/* Classic buttons, on the account and order pages */
body.woocommerce-page .woocommerce button.button,
body.woocommerce-page .woocommerce a.button,
body.woocommerce-page .woocommerce input.button {
  min-height: 44px;
  padding: 12px 24px;
  border: 2px solid var(--red);
  border-radius: 999px;
  background: var(--red);
  color: #fff;
  font-family: var(--font);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  line-height: 1.4;
  text-transform: uppercase;
}
body.woocommerce-page .woocommerce button.button:hover,
body.woocommerce-page .woocommerce a.button:hover,
body.woocommerce-page .woocommerce input.button:hover {
  background: var(--red-dark);
  border-color: var(--red-dark);
  color: #fff;
}

/* Account: login, register and the signed-in area */
body.woocommerce-account .woocommerce h2,
body.woocommerce-account .woocommerce h3 {
  font-size: 20px;
  text-transform: uppercase;
  color: var(--red-ink);
}
body.woocommerce-page .woocommerce form.login,
body.woocommerce-page .woocommerce form.register {
  margin: 12px 0;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
body.woocommerce-page .woocommerce form .form-row label { font-size: 13px; font-weight: 600; color: var(--ink); }
body.woocommerce-page .woocommerce form .form-row input.input-text,
body.woocommerce-page .woocommerce form .form-row textarea,
body.woocommerce-page .woocommerce form .form-row select {
  min-height: 44px;
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--ink);
}
body.woocommerce-page .woocommerce form .form-row input.input-text:focus { border-color: var(--red); outline: 0; box-shadow: 0 0 0 1px var(--red); }
body.woocommerce-account .woocommerce-LostPassword a,
body.woocommerce-account .woocommerce-MyAccount-content a:not(.button) { color: var(--red); font-weight: 600; }
body.woocommerce-account .woocommerce-MyAccount-navigation ul {
  margin: 0;
  padding: 8px;
  list-style: none;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
body.woocommerce-account .woocommerce-MyAccount-navigation a {
  display: block;
  padding: 10px 12px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
}
body.woocommerce-account .woocommerce-MyAccount-navigation a:hover,
body.woocommerce-account .woocommerce-MyAccount-navigation .is-active a { background: var(--red-soft); color: var(--red-ink); }

/* Order tables, on the thank-you and order pages */
body.woocommerce-page .woocommerce table.shop_table { border-color: var(--line); border-radius: var(--radius); }
body.woocommerce-page .woocommerce table.shop_table th,
body.woocommerce-page .woocommerce table.shop_table td { border-color: var(--line); }
body .woocommerce-order-overview,
body.woocommerce-page .woocommerce ul.order_details { padding: 16px; border: 1px solid var(--line); border-radius: var(--radius); list-style: none; }
