/* ============================================================
   LOT | 23 — Cart + Checkout styles
   Restyles WooCommerce default output to the brand voice.
   Tokens: warm cream #f8f5f2 / alt #f1f1f0 / ink #1d1d1b / body #4a4540
   ============================================================ */

/* ─── Page hero block (above the WC shortcode output) ─────── */
.l23-page-hero {
  background: #f8f5f2;
  padding: 96px 0 56px;
  border-bottom: 1px solid rgba(29, 29, 27, 0.08);
}
.l23-page-hero .container,
.l23-page-hero > div {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 32px;
}
.l23-page-hero .eyebrow {
  display: inline-block;
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: #1d1d1b;
  opacity: 0.55;
  margin-bottom: 18px;
  font-family: 'DM Sans', system-ui, sans-serif;
}
.l23-page-hero .l23-pg-title {
  font-family: 'Avenir', 'DM Sans', system-ui, sans-serif;
  font-weight: 800;
  font-size: clamp(56px, 8vw, 112px);
  line-height: 0.96;
  letter-spacing: -0.02em;
  color: #1d1d1b;
  margin: 0;
}
.l23-page-hero .l23-pg-sub {
  font-family: 'DM Sans', system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.55;
  color: #4a4540;
  margin: 18px 0 0;
  max-width: 540px;
}

/* ─── WC cart / checkout container ────────────────────────── */
.woocommerce {
  background: #f8f5f2;
  padding: 56px 0 96px;
  font-family: 'DM Sans', system-ui, sans-serif;
  color: #1d1d1b;
}
.page-id-8 .woocommerce,
.page-id-9 .woocommerce {
  max-width: 1280px;
  margin: 0 auto;
  padding: 56px 32px 96px;
}

/* ─── Notice / message styling ─────────────────────────────── */
.woocommerce-message,
.woocommerce-info,
.woocommerce-error {
  background: #fff;
  border: 1px solid rgba(29, 29, 27, 0.12);
  border-left: 3px solid #1d1d1b;
  padding: 16px 20px;
  font-size: 14px;
  color: #1d1d1b;
  margin: 0 0 24px;
  border-radius: 0;
  list-style: none;
}
.woocommerce-message a,
.woocommerce-info a {
  color: #1d1d1b;
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* ─── CART: item table ─────────────────────────────────────── */
.woocommerce table.shop_table {
  background: transparent;
  border: 0;
  border-collapse: collapse;
  width: 100%;
  margin: 0 0 32px;
  font-family: 'DM Sans', system-ui, sans-serif;
}
.woocommerce table.shop_table thead th {
  background: transparent;
  border: 0;
  border-bottom: 1px solid #1d1d1b;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-size: 11px;
  font-weight: 500;
  color: #1d1d1b;
  opacity: 0.55;
  padding: 16px 8px;
  text-align: left;
}
.woocommerce table.shop_table tbody td {
  background: transparent;
  border: 0;
  border-bottom: 1px solid rgba(29, 29, 27, 0.08);
  padding: 24px 8px;
  vertical-align: middle;
  color: #1d1d1b;
  font-size: 15px;
}
.woocommerce table.shop_table td.product-thumbnail img {
  width: 84px;
  height: auto;
  border: 0;
}
.woocommerce table.shop_table td.product-name a {
  color: #1d1d1b;
  text-decoration: none;
  font-weight: 500;
  font-size: 16px;
}
.woocommerce table.shop_table td.product-name a:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}
.woocommerce table.shop_table td.product-price,
.woocommerce table.shop_table td.product-subtotal {
  color: #1d1d1b;
  font-feature-settings: 'tnum';
  font-variant-numeric: tabular-nums;
}
.woocommerce table.shop_table td.product-subtotal {
  font-weight: 600;
}

/* Remove (X) button */
.woocommerce table.shop_table td.product-remove a.remove {
  width: 28px;
  height: 28px;
  background: #fff;
  border: 1px solid rgba(29, 29, 27, 0.18);
  color: #1d1d1b !important;
  border-radius: 0;
  font-size: 16px;
  line-height: 26px;
  text-align: center;
  font-weight: 400;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}
.woocommerce table.shop_table td.product-remove a.remove:hover {
  background: #1d1d1b;
  color: #fff !important;
  border-color: #1d1d1b;
}

/* Quantity input */
.woocommerce .quantity {
  display: inline-flex;
  align-items: center;
  border: 1px solid rgba(29, 29, 27, 0.18);
  background: #fff;
}
.woocommerce .quantity input.qty {
  width: 56px;
  border: 0;
  background: transparent;
  text-align: center;
  font-family: 'DM Sans', system-ui, sans-serif;
  font-size: 14px;
  padding: 10px 4px;
  color: #1d1d1b;
  -moz-appearance: textfield;
}
.woocommerce .quantity input.qty::-webkit-outer-spin-button,
.woocommerce .quantity input.qty::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

/* Coupon + Update cart row */
.woocommerce .cart .actions {
  padding: 24px 0 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  border-bottom: 0;
}
.woocommerce .cart .actions .coupon {
  display: inline-flex;
  gap: 8px;
}
.woocommerce input[name="coupon_code"] {
  border: 1px solid rgba(29, 29, 27, 0.18);
  background: #fff;
  padding: 10px 14px;
  font-family: 'DM Sans', system-ui, sans-serif;
  font-size: 14px;
  color: #1d1d1b;
  min-width: 200px;
  border-radius: 0;
}

/* ─── Buttons (unified across cart + checkout) ─────────────── */
.woocommerce a.button,
.woocommerce button.button,
.woocommerce input.button,
.woocommerce #respond input#submit,
.woocommerce .button[name="update_cart"],
.woocommerce .button[name="apply_coupon"],
.woocommerce .wc-proceed-to-checkout a.checkout-button,
.woocommerce #place_order {
  background: #1d1d1b;
  color: #fff !important;
  border: 0;
  border-radius: 0;
  padding: 14px 28px;
  font-family: 'DM Sans', system-ui, sans-serif;
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.15s, background 0.15s;
  text-decoration: none;
  display: inline-block;
  text-align: center;
  line-height: 1.4;
}
.woocommerce a.button:hover,
.woocommerce button.button:hover,
.woocommerce input.button:hover,
.woocommerce #place_order:hover,
.woocommerce .wc-proceed-to-checkout a.checkout-button:hover {
  background: #4a4540;
  color: #fff;
  opacity: 1;
}
.woocommerce .button[name="update_cart"],
.woocommerce .button[name="apply_coupon"] {
  background: transparent;
  color: #1d1d1b !important;
  border: 1px solid #1d1d1b;
}
.woocommerce .button[name="update_cart"]:hover,
.woocommerce .button[name="apply_coupon"]:hover {
  background: #1d1d1b;
  color: #fff !important;
}

/* ─── CART totals (right-side collaterals) ─────────────────── */
.woocommerce .cart-collaterals {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
  margin-top: 24px;
}
.woocommerce .cart-collaterals .cart_totals {
  background: #fff;
  padding: 32px;
  border: 1px solid rgba(29, 29, 27, 0.10);
  width: 100%;
  max-width: 460px;
  margin-left: auto;
}
.woocommerce .cart_totals h2 {
  font-family: 'DM Sans', system-ui, sans-serif;
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  font-weight: 600;
  color: #1d1d1b;
  opacity: 0.55;
  margin: 0 0 18px;
}
.woocommerce .cart_totals table.shop_table_responsive tbody td,
.woocommerce .cart_totals table.shop_table_responsive tbody th {
  padding: 14px 0;
  border-bottom: 1px solid rgba(29, 29, 27, 0.08);
  font-size: 14px;
}
.woocommerce .cart_totals table.shop_table_responsive tr.order-total td,
.woocommerce .cart_totals table.shop_table_responsive tr.order-total th {
  border-bottom: 0;
  padding-top: 18px;
  font-size: 20px;
  font-weight: 600;
}
.woocommerce .cart_totals .wc-proceed-to-checkout {
  margin-top: 22px;
  padding: 0;
}
.woocommerce .cart_totals .wc-proceed-to-checkout a.checkout-button {
  display: block;
  width: 100%;
  padding: 16px;
  font-size: 12px;
  letter-spacing: 0.24em;
}

/* Shipping calculator hidden — we use shipping at checkout */
.woocommerce .cart_totals .shipping-calculator-button {
  font-size: 13px;
  color: #1d1d1b;
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* ─── CHECKOUT: form layout ────────────────────────────────── */
.woocommerce-checkout .woocommerce {
  padding: 56px 32px 96px;
}
.woocommerce form.checkout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 56px;
}
@media (min-width: 980px) {
  .woocommerce form.checkout {
    grid-template-columns: 1.4fr 1fr;
    gap: 80px;
  }
}
.woocommerce form.checkout #customer_details {
  display: contents;
}
.woocommerce form.checkout #customer_details > .col-1,
.woocommerce form.checkout #customer_details > .col-2 {
  grid-column: 1;
}
.woocommerce form.checkout .col-2 {
  display: none; /* hide shipping address by default, customers can show it via the toggle */
}

.woocommerce form.checkout h3 {
  font-family: 'DM Sans', system-ui, sans-serif;
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  font-weight: 600;
  color: #1d1d1b;
  opacity: 0.55;
  margin: 0 0 18px;
  padding-bottom: 12px;
  border-bottom: 1px solid #1d1d1b;
}

/* Form fields */
.woocommerce form .form-row {
  margin: 0 0 18px;
  padding: 0;
}
.woocommerce form .form-row label {
  display: block;
  margin: 0 0 6px;
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #1d1d1b;
  opacity: 0.7;
  font-weight: 500;
}
.woocommerce form .form-row label .required {
  color: #1d1d1b;
  opacity: 0.5;
  text-decoration: none;
}
.woocommerce form .form-row input.input-text,
.woocommerce form .form-row textarea,
.woocommerce form .form-row select {
  width: 100%;
  border: 1px solid rgba(29, 29, 27, 0.18);
  background: #fff;
  padding: 12px 14px;
  font-family: 'DM Sans', system-ui, sans-serif;
  font-size: 15px;
  color: #1d1d1b;
  border-radius: 0;
  min-height: 46px;
  line-height: 1.4;
}
.woocommerce form .form-row input.input-text:focus,
.woocommerce form .form-row textarea:focus,
.woocommerce form .form-row select:focus {
  outline: 0;
  border-color: #1d1d1b;
  box-shadow: 0 0 0 1px #1d1d1b;
}
.woocommerce form .form-row textarea {
  min-height: 96px;
  resize: vertical;
}

/* Select2 dropdowns (country/state) */
.select2-container--default .select2-selection--single {
  border: 1px solid rgba(29, 29, 27, 0.18) !important;
  background: #fff !important;
  border-radius: 0 !important;
  height: 46px !important;
  font-family: 'DM Sans', system-ui, sans-serif;
}
.select2-container--default .select2-selection--single .select2-selection__rendered {
  line-height: 46px !important;
  padding: 0 14px !important;
  color: #1d1d1b !important;
}
.select2-container--default .select2-selection--single .select2-selection__arrow {
  height: 46px !important;
}

/* Order review */
.woocommerce form.checkout #order_review_heading,
.woocommerce form.checkout #order_review {
  grid-column: 2;
}
@media (max-width: 979px) {
  .woocommerce form.checkout #order_review_heading,
  .woocommerce form.checkout #order_review {
    grid-column: 1;
  }
}
.woocommerce #order_review {
  background: #fff;
  padding: 32px;
  border: 1px solid rgba(29, 29, 27, 0.10);
  position: sticky;
  top: 24px;
}
.woocommerce #order_review_heading {
  font-family: 'DM Sans', system-ui, sans-serif;
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  font-weight: 600;
  color: #1d1d1b;
  opacity: 0.55;
  margin: 0 0 18px;
  padding-bottom: 12px;
  border-bottom: 1px solid #1d1d1b;
}
.woocommerce #order_review table.shop_table {
  border: 0;
  margin: 0;
}
.woocommerce #order_review table.shop_table thead {
  display: none;
}
.woocommerce #order_review table.shop_table tbody td,
.woocommerce #order_review table.shop_table tfoot td,
.woocommerce #order_review table.shop_table tfoot th {
  padding: 12px 0;
  border-bottom: 1px solid rgba(29, 29, 27, 0.08);
  font-size: 14px;
}
.woocommerce #order_review table.shop_table tfoot tr.order-total td,
.woocommerce #order_review table.shop_table tfoot tr.order-total th {
  border-bottom: 0;
  padding-top: 18px;
  font-size: 18px;
  font-weight: 600;
}

/* Payment methods */
.woocommerce #payment {
  background: transparent;
  border-radius: 0;
  padding: 22px 0 0;
}
.woocommerce #payment ul.payment_methods {
  background: transparent;
  border-bottom: 1px solid rgba(29, 29, 27, 0.08);
  padding: 0 0 18px;
  margin: 0 0 22px;
}
.woocommerce #payment ul.payment_methods li {
  padding: 12px 0;
  background: transparent;
  border: 0;
  list-style: none;
}
.woocommerce #payment ul.payment_methods li input[type="radio"] {
  margin-right: 10px;
}
.woocommerce #payment ul.payment_methods li label {
  font-size: 15px;
  color: #1d1d1b;
  font-weight: 500;
}
.woocommerce #payment div.payment_box {
  background: #f1f1f0 !important;
  padding: 14px 18px;
  margin: 12px 0 0;
  border: 0;
  color: #4a4540;
  font-size: 13px;
  line-height: 1.5;
}
.woocommerce #payment div.payment_box::before {
  display: none !important;
}
.woocommerce #payment #place_order {
  display: block;
  width: 100%;
  padding: 18px;
  font-size: 12px;
  letter-spacing: 0.24em;
}

/* Terms checkbox */
.woocommerce-terms-and-conditions-wrapper {
  margin: 14px 0;
}
.woocommerce-form__label-for-checkbox {
  font-size: 13px;
  color: #4a4540;
  display: flex;
  gap: 8px;
  align-items: flex-start;
  line-height: 1.5;
}

/* Login / coupon collapsibles at top of checkout */
.woocommerce-form-login-toggle .woocommerce-info,
.woocommerce-form-coupon-toggle .woocommerce-info {
  background: #fff;
  border: 1px solid rgba(29, 29, 27, 0.12);
  border-left: 3px solid #1d1d1b;
  font-size: 14px;
  color: #1d1d1b;
}

/* ─── Empty cart ──────────────────────────────────────────── */
.cart-empty.woocommerce-info {
  background: #fff;
  border: 1px solid rgba(29, 29, 27, 0.12);
  border-left: 3px solid #1d1d1b;
  padding: 28px 32px;
  font-size: 18px;
  color: #1d1d1b;
  font-family: 'Avenir', 'DM Sans', system-ui, sans-serif;
  font-weight: 800;
  letter-spacing: -0.01em;
}
.return-to-shop .button {
  margin-top: 16px;
}

/* ─── Spacing utility for responsive ───────────────────────── */
@media (max-width: 768px) {
  .l23-page-hero { padding: 64px 0 40px; }
  .woocommerce { padding: 40px 0 64px; }
  .page-id-8 .woocommerce,
  .page-id-9 .woocommerce { padding: 40px 16px 64px; }
  .woocommerce table.shop_table thead { display: none; }
  .woocommerce table.shop_table tbody tr {
    display: block;
    padding: 16px 0;
    border-bottom: 1px solid rgba(29, 29, 27, 0.08);
  }
  .woocommerce table.shop_table tbody td {
    display: flex;
    justify-content: space-between;
    padding: 6px 0;
    border: 0;
  }
  .woocommerce table.shop_table tbody td::before {
    content: attr(data-title);
    text-transform: uppercase;
    letter-spacing: 0.16em;
    font-size: 11px;
    opacity: 0.55;
  }
}
