/* ==========================================================================
   WooCommerce -> Emilio Degher's design

   This file adds no new design. Every value below is lifted from her existing
   stylesheet so the shop, cart and checkout read as the same site rather than a
   store bolted onto it. Where a number looks arbitrary it is hers:

     - field border  2px solid #d9dde4  and radius 12px are literal values from
       her contact form. 12px is deliberately NOT --radius-sm (10px); using the
       token would be subtly wrong on every input on the site.
     - buttons are pill radius, Fredoka 600, 14px 28px, and every hover lifts
       translateY(-2px) and deepens the shadow. Woo's defaults do none of that.
     - shadows are tinted rgba(19,33,64,...), never neutral grey.
   ========================================================================== */

/* ---------- Buttons: map Woo's markup onto .btn / .btn-primary ---------- */
.woocommerce #respond input#submit,
.woocommerce a.button,
.woocommerce button.button,
.woocommerce input.button,
.woocommerce a.button.alt,
.woocommerce button.button.alt,
.woocommerce input.button.alt,
.wc-block-components-button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 30px;
  border: 1px solid transparent;
  border-radius: 3px;
  font-family: var(--sans);
  font-weight: 600;
  font-size: .8rem;
  letter-spacing: .2em;
  text-transform: uppercase;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  background: var(--gold);
  color: #fff;
  box-shadow: 0 2px 8px rgba(19, 33, 64, 0.10);
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}
.woocommerce #respond input#submit:hover,
.woocommerce a.button:hover,
.woocommerce button.button:hover,
.woocommerce input.button:hover,
.woocommerce a.button.alt:hover,
.woocommerce button.button.alt:hover,
.woocommerce input.button.alt:hover,
.wc-block-components-button:hover {
  background: var(--gold-deep);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(19, 33, 64, 0.14);
}

/* Secondary actions - "Update cart", "Continue shopping" - take the gold
   treatment so the coral stays reserved for the one action that matters. */
.woocommerce .cart .button[name="update_cart"],
.woocommerce a.button.wc-backward {
  background: transparent;
  border-color: var(--gold);
  color: var(--gold-deep);
  box-shadow: none;
}
.woocommerce .cart .button[name="update_cart"]:hover,
.woocommerce a.button.wc-backward:hover {
  background: var(--gold);
  color: #fff;
}

/* A disabled "Update cart" must not look clickable. */
.woocommerce .button:disabled,
.woocommerce .button[disabled] {
  opacity: .45;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

/* ---------- Form fields: her contact-form styling, exactly ---------- */
.woocommerce form .form-row label,
.woocommerce-checkout label {
  font-family: var(--sans);
  font-weight: 500;
  font-size: .74rem;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--text-on-white-dim);
}
.woocommerce table.shop_table th {
  font-family: var(--sans);
  font-weight: 600;
  font-size: .72rem;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--text-on-white);
}
.woocommerce form .form-row input.input-text,
.woocommerce form .form-row textarea,
.woocommerce form .form-row select,
.woocommerce .select2-container .select2-selection--single,
.woocommerce-page form .form-row input.input-text {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid #d9dde4;
  border-radius: 4px;
  font-family: var(--sans);
  font-size: 1rem;
  background: var(--off-white);
  color: var(--text-on-white);
  height: auto;
  transition: border-color .2s ease, background .2s ease;
}
.woocommerce form .form-row input.input-text:focus,
.woocommerce form .form-row textarea:focus,
.woocommerce form .form-row select:focus,
.woocommerce .select2-container--open .select2-selection--single {
  outline: none;
  border-color: var(--gold);
  background: #fff;
}
/* Select2 is injected by Woo and ignores the rules above without this. */
.woocommerce .select2-container .select2-selection--single .select2-selection__rendered {
  line-height: 1.4;
  padding: 0;
  color: var(--text-on-white);
}
.woocommerce .select2-container .select2-selection--single .select2-selection__arrow {
  top: 50%;
  transform: translateY(-50%);
}
.woocommerce form .form-row.woocommerce-invalid input.input-text {
  border-color: #b4453a;
}
.woocommerce form .form-row.woocommerce-validated input.input-text {
  border-color: #3f7d3a;
}

/* ---------- Notices ---------- */
.woocommerce-message,
.woocommerce-info,
.woocommerce-error,
.woocommerce-notice {
  border: none;
  border-left: 4px solid #3f7d3a;
  border-radius: 4px;
  background: #fff;
  color: var(--text-on-white);
  font-family: var(--sans);
  padding: 16px 20px;
  margin: 0 0 24px;
  box-shadow: 0 2px 8px rgba(19, 33, 64, 0.10);
  list-style: none;
}
.woocommerce-info { border-left-color: var(--navy-light); }
.woocommerce-error { border-left-color: var(--gold); }
.woocommerce-message::before,
.woocommerce-info::before,
.woocommerce-error::before { display: none; }
.woocommerce-error li { list-style: none; margin: 0; }

/* ---------- Cart ---------- */
.woocommerce table.shop_table {
  border: none;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 2px 8px rgba(19, 33, 64, 0.10);
  border-collapse: separate;
  border-spacing: 0;
  overflow: hidden;
}
.woocommerce table.shop_table th {
  background: var(--off-white);
  padding: 16px;
  border: none;
  text-align: left;
}
.woocommerce table.shop_table td {
  padding: 16px;
  border: none;
  border-top: 1px solid #d9dde4;
  font-family: var(--sans);
  color: var(--text-on-white);
  vertical-align: middle;
}
.woocommerce table.cart img {
  width: 72px;
  border-radius: 4px;
  box-shadow: 0 2px 8px rgba(19, 33, 64, 0.10);
}
.woocommerce table.cart td.product-name a {
  color: var(--text-on-white);
  font-family: var(--display);
  font-weight: 600;
  text-decoration: none;
}
.woocommerce table.cart td.product-name a:hover { color: var(--gold); }

/* The remove "x" is a bare link by default and reads as a typo on her site. */
.woocommerce a.remove {
  width: 26px;
  height: 26px;
  line-height: 24px;
  border-radius: 50%;
  color: var(--gold) !important;
  background: var(--off-white);
  font-weight: 600;
  text-align: center;
}
.woocommerce a.remove:hover {
  background: var(--gold) !important;
  color: #fff !important;
}

/* Quantity box matches the inputs rather than the browser default. */
.woocommerce .quantity .qty {
  width: 72px;
  padding: 10px;
  border: 1px solid #d9dde4;
  border-radius: 4px;
  background: var(--off-white);
  font-family: var(--sans);
  color: var(--text-on-white);
  text-align: center;
}
.woocommerce .quantity .qty:focus {
  outline: none;
  border-color: var(--gold);
  background: #fff;
}

/* ---------- Cart totals / order review ---------- */
.woocommerce .cart-collaterals .cart_totals,
.woocommerce-checkout #order_review {
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 10px 30px rgba(19, 33, 64, 0.14);
  padding: 28px;
}
.woocommerce .cart-collaterals h2,
.woocommerce-checkout h3 {
  font-family: var(--display);
  font-weight: 600;
  color: var(--text-on-white);
  margin: 0 0 18px;
}
.woocommerce .cart_totals table.shop_table,
.woocommerce-checkout #order_review table.shop_table {
  box-shadow: none;
  background: transparent;
}
.woocommerce .cart_totals .order-total .amount,
.woocommerce-checkout .order-total .amount {
  font-family: var(--display);
  font-size: 1.35rem;
  color: var(--gold);
}
.woocommerce .woocommerce-Price-amount {
  font-family: var(--display);
  font-weight: 600;
}

/* Coupon field sits next to its button rather than under it. */
.woocommerce .coupon { display: flex; gap: 10px; flex-wrap: wrap; }
.woocommerce .coupon #coupon_code {
  flex: 1 1 180px;
  padding: 12px 16px;
  border: 1px solid #d9dde4;
  border-radius: 4px;
  background: var(--off-white);
  font-family: var(--sans);
  width: auto;
}

/* ---------- Shop listing ---------- */
.woocommerce ul.products {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 32px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.woocommerce ul.products li.product {
  width: auto !important;
  float: none !important;
  margin: 0 !important;
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(19, 33, 64, 0.10);
  padding: 20px;
  text-align: center;
  transition: transform .2s ease, box-shadow .2s ease;
}
.woocommerce ul.products li.product:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 30px rgba(19, 33, 64, 0.14);
}
.woocommerce ul.products li.product img {
  border-radius: 4px;
  margin-bottom: 16px;
}
.woocommerce ul.products li.product .woocommerce-loop-product__title {
  font-family: var(--display);
  font-weight: 600;
  font-size: 1.1rem;
  color: var(--text-on-white);
  padding: 0;
}
.woocommerce ul.products li.product .price {
  color: var(--gold);
  font-family: var(--display);
  font-size: 1.15rem;
}
/* Woo prints the sale flash as a circle in the corner; keep it, restyle it. */
.woocommerce span.onsale {
  background: var(--gold);
  color: var(--text-on-white);
  font-family: var(--display);
  font-weight: 600;
  border-radius: 3px;
  padding: 6px 16px;
  min-height: 0;
  min-width: 0;
  line-height: 1.4;
}
.woocommerce .woocommerce-result-count,
.woocommerce .woocommerce-ordering { color: var(--text-on-white-dim); }

/* ---------- Single product ---------- */
.woocommerce div.product .product_title {
  font-family: var(--display);
  font-weight: 700;
  color: var(--text-on-white);
}
.woocommerce div.product p.price,
.woocommerce div.product span.price {
  color: var(--gold);
  font-family: var(--display);
  font-size: 1.6rem;
}
.woocommerce div.product .woocommerce-product-details__short-description {
  color: var(--text-on-white-dim);
  line-height: 1.7;
}
.woocommerce div.product div.images img { border-radius: 8px; }
.woocommerce div.product form.cart { margin-top: 24px; }
.woocommerce div.product .woocommerce-tabs ul.tabs {
  padding: 0;
  margin: 0 0 24px;
}
.woocommerce div.product .woocommerce-tabs ul.tabs::before { border-bottom-color: #d9dde4; }
.woocommerce div.product .woocommerce-tabs ul.tabs li {
  background: var(--off-white);
  border: 2px solid #d9dde4;
  border-radius: 3px;
  margin: 0 8px 0 0;
  padding: 0;
}
.woocommerce div.product .woocommerce-tabs ul.tabs li::before,
.woocommerce div.product .woocommerce-tabs ul.tabs li::after { display: none; }
.woocommerce div.product .woocommerce-tabs ul.tabs li a {
  font-family: var(--display);
  font-weight: 600;
  color: var(--text-on-white);
  padding: 10px 22px;
}
.woocommerce div.product .woocommerce-tabs ul.tabs li.active {
  background: var(--gold);
  border-color: var(--gold);
}
.woocommerce div.product .woocommerce-tabs ul.tabs li.active a { color: #fff; }

/* Variation dropdowns - the binding selector - are the main control on a
   product page here, so they get the full field treatment. */
.woocommerce div.product form.cart .variations td { padding: 8px 0; }
.woocommerce div.product form.cart .variations label {
  font-family: var(--display);
  font-weight: 600;
  color: var(--text-on-white);
}
.woocommerce div.product form.cart .reset_variations {
  color: var(--gold);
  font-size: .9rem;
}

/* ---------- Checkout form rows ---------- */
/* WooCommerce computes .form-row to display:grid with TWO equal columns and
   leans on float:left/right for the two-up fields. Auto-placement then puts the
   label in column 2 and the input in column 1, so every label sits beside the
   wrong field rather than above its own. Measured on this install:
   grid-template-columns resolved to "122.391px 122.391px".

   Rather than patch Woo's grid, each row is forced back to a plain block and the
   two-up arrangement is done one level up, on the field wrapper, where it is
   explicit and cannot be re-ordered by auto-placement. */
.woocommerce form .form-row {
  display: block;
  float: none;
  width: 100%;
  margin: 0 0 18px;
  padding: 0;
}
.woocommerce form .form-row label {
  display: block;
  margin-bottom: 6px;
}
.woocommerce form .form-row .woocommerce-input-wrapper {
  display: block;
  width: 100%;
}
.woocommerce .woocommerce-billing-fields__field-wrapper,
.woocommerce .woocommerce-shipping-fields__field-wrapper,
.woocommerce .woocommerce-additional-fields__field-wrapper {
  display: grid;
  grid-template-columns: 1fr 1fr;
  column-gap: 18px;
}
/* Address, city, email and the order notes need the full width. */
.woocommerce form .form-row-wide,
.woocommerce form .form-row.notes {
  grid-column: 1 / -1;
}

/* ---------- Checkout layout ---------- */
/* form.checkout has exactly three children: #customer_details, the
   #order_review_heading <h3>, and #order_review. Left to auto-placement in a
   two-column grid the heading lands beside the billing card and the order
   review drops underneath it in the LEFT column - the right side then looks
   empty even though the markup is all there. Each child is therefore placed
   explicitly. */
.woocommerce-checkout form.checkout {
  display: grid;
  grid-template-columns: 1.15fr .85fr;
  column-gap: 40px;
  align-items: start;
}
.woocommerce-checkout form.checkout > #customer_details {
  grid-column: 1;
  grid-row: 1 / span 2;
  min-width: 0;
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(19, 33, 64, 0.10);
  padding: 28px;
}
.woocommerce-checkout form.checkout > #order_review_heading { grid-column: 2; grid-row: 1; margin: 0 0 18px; }
.woocommerce-checkout form.checkout > #order_review { grid-column: 2; grid-row: 2; min-width: 0; }
.woocommerce-checkout .col2-set .col-1,
.woocommerce-checkout .col2-set .col-2 { width: 100%; float: none; }
.woocommerce-checkout h3 {
  font-family: var(--display);
  font-weight: 600;
  color: var(--text-on-white);
}

/* ---------- Order review / payment ---------- */
.woocommerce-checkout #order_review {
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 10px 30px rgba(19, 33, 64, 0.14);
  padding: 28px;
}
.woocommerce-checkout #order_review table.shop_table {
  box-shadow: none;
  background: transparent;
}
.woocommerce-checkout .order-total .amount {
  font-family: var(--display);
  font-size: 1.35rem;
  color: var(--gold);
}
.woocommerce-checkout #payment {
  background: var(--off-white);
  border-radius: 8px;
  margin-top: 24px;
}
.woocommerce-checkout #payment ul.payment_methods {
  border-bottom: 1px solid #d9dde4;
  padding: 20px;
  margin: 0;
}
.woocommerce-checkout #payment ul.payment_methods li {
  list-style: none;
  font-family: var(--sans);
  color: var(--text-on-white);
}
.woocommerce-checkout #payment div.payment_box {
  background: #fff;
  border-radius: 4px;
  color: var(--text-on-white-dim);
  font-size: .92rem;
}
.woocommerce-checkout #payment div.payment_box::before { border-bottom-color: #fff; }
.woocommerce-checkout #payment div.form-row.place-order { padding: 20px; margin: 0; }
.woocommerce-checkout #payment #place_order {
  width: 100%;
  justify-content: center;
  font-size: 1.05rem;
  padding: 16px 28px;
}
.woocommerce-checkout .woocommerce-terms-and-conditions-wrapper {
  font-size: .9rem;
  color: var(--text-on-white-dim);
}

/* ---------- Block notices ---------- */
/* Even with the classic cart and checkout shortcodes, WooCommerce renders its
   "added to your cart" and coupon notices with the block notice banner, which
   ships its own blue border. These are the same notices as .woocommerce-message
   above, so they get the same treatment. */
.wc-block-components-notice-banner {
  border: none !important;
  border-left: 4px solid #3f7d3a !important;
  border-radius: 4px;
  background: #fff;
  color: var(--text-on-white);
  font-family: var(--sans);
  box-shadow: 0 2px 8px rgba(19, 33, 64, 0.10);
}
.wc-block-components-notice-banner.is-error { border-left-color: var(--gold) !important; }
.wc-block-components-notice-banner.is-info { border-left-color: var(--navy-light) !important; }
.wc-block-components-notice-banner > svg { fill: #3f7d3a; }
.wc-block-components-notice-banner.is-error > svg { fill: var(--gold); }

/* The shop sort dropdown sits outside any .form-row, so it misses the field
   rules above and would otherwise render as a raw browser select. */
.woocommerce .woocommerce-ordering select {
  padding: 10px 14px;
  border: 1px solid #d9dde4;
  border-radius: 4px;
  background: var(--off-white);
  font-family: var(--sans);
  color: var(--text-on-white);
}
.woocommerce .woocommerce-ordering select:focus {
  outline: none;
  border-color: var(--gold);
  background: #fff;
}

/* ---------- Order received / account ---------- */
.woocommerce .woocommerce-order,
.woocommerce-account .woocommerce {
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(19, 33, 64, 0.10);
  padding: 32px;
}
.woocommerce ul.order_details {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  padding: 0;
  margin: 0 0 28px;
  list-style: none;
}
.woocommerce ul.order_details li {
  border: none;
  padding: 0;
  margin: 0;
  font-family: var(--sans);
  color: var(--text-on-white-dim);
  font-size: .85rem;
  text-transform: uppercase;
  letter-spacing: .04em;
}
.woocommerce ul.order_details li strong {
  display: block;
  margin-top: 4px;
  font-family: var(--display);
  font-size: 1.05rem;
  color: var(--text-on-white);
  text-transform: none;
  letter-spacing: 0;
}
/* The downloads table is how her eBook buyers get their file - it must not look
   like an afterthought. */
.woocommerce table.order_details_table,
.woocommerce .woocommerce-table--order-downloads { margin-bottom: 28px; }

/* ---------- Breadcrumb ---------- */
.woocommerce .woocommerce-breadcrumb {
  font-family: var(--sans);
  font-size: .9rem;
  color: var(--text-on-white-dim);
  margin-bottom: 24px;
}
.woocommerce .woocommerce-breadcrumb a { color: var(--gold); text-decoration: none; }

/* ---------- Mobile ---------- */
@media (max-width: 860px) {
  /* Collapse to one column and release the explicit placements above, or the
     order review would stay pinned to a column that no longer exists. */
  .woocommerce-checkout form.checkout { grid-template-columns: 1fr; row-gap: 28px; }
  .woocommerce-checkout form.checkout > #customer_details,
  .woocommerce-checkout form.checkout > #order_review_heading,
  .woocommerce-checkout form.checkout > #order_review {
    grid-column: 1;
    grid-row: auto;
  }
  .woocommerce .woocommerce-billing-fields__field-wrapper,
  .woocommerce .woocommerce-shipping-fields__field-wrapper,
  .woocommerce .woocommerce-additional-fields__field-wrapper {
    grid-template-columns: 1fr;
  }
  .woocommerce-checkout form.checkout > #customer_details,
  .woocommerce-checkout #order_review,
  .woocommerce .cart-collaterals .cart_totals,
  .woocommerce .woocommerce-order { padding: 20px; }
  .woocommerce table.shop_table td,
  .woocommerce table.shop_table th { padding: 12px; }
  /* The cart table has six columns and will not fit; let it scroll rather than
     squeeze thumbnails and prices into unreadable slivers. */
  .woocommerce table.cart { display: block; overflow-x: auto; }
  .woocommerce .coupon { width: 100%; }
}

/* ==========================================================================
   Delivery-first checkout

   Classes used by woocommerce/checkout/form-checkout.php and form-shipping.php.
   Same structure as the Globalgood build, dressed in Emilio's tokens.
   ========================================================================== */

/* WooCommerce still needs billing email/phone in the DOM - inc/checkout.php
   fills them from the delivery block - so they are hidden, never removed. */
.emiliodegher-hidden-field { display: none !important; }

/* The ship-to-different-address checkbox must EXIST and stay CHECKED or
   WooCommerce never posts the shipping address and the checkout offers no
   shipping methods at all. Hidden with CSS, because a CSS-hidden field still
   submits while a disabled or removed one does not. Never replace it with an
   input type=hidden - checkout.js tests it with :checked. */
.ed-ship-flag {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
  pointer-events: none;
}

.ed-delivery-heading,
.ed-download-heading {
  font-family: var(--display);
  font-weight: 600;
  color: var(--text-on-white);
  margin: 0 0 6px;
}

.ed-section-hint,
.ed-download-hint {
  font-size: .9rem;
  color: var(--text-on-white-dim);
  margin: 0 0 20px;
}

/* "My billing address is different" - her field styling, so it reads as part
   of the form rather than a bolted-on control. */
.billing-toggle {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 22px 0 6px;
  padding: 14px 16px;
  background: var(--off-white);
  border: 1px solid #d9dde4;
  border-radius: 4px;
}
.billing-toggle input {
  margin-top: 4px;
  flex-shrink: 0;
  accent-color: var(--gold);
}
.billing-toggle label {
  font-family: var(--display);
  font-weight: 600;
  font-size: .95rem;
  color: var(--text-on-white);
  cursor: pointer;
  margin: 0;
}
.billing-toggle small {
  display: block;
  font-family: var(--sans);
  font-weight: 400;
  font-size: .85rem;
  color: var(--text-on-white-dim);
  margin-top: 3px;
}
#ed-billing-wrap h3 { margin-top: 26px; }

/* Shipping method rows: name left, price right, on one line. */
.ship-name {
  font-family: var(--sans);
  font-weight: 600;
  color: var(--text-on-white);
}
.ship-price {
  font-family: var(--display);
  font-weight: 600;
  color: var(--gold);
  white-space: nowrap;
  margin-left: 8px;
}

/* An eBook order is delivered to the email address, so a typo there is a paid
   order that never arrives. The note is given weight deliberately. */
.ed-email-field .description {
  display: block;
  margin-top: 8px;
  padding: 10px 12px;
  border-left: 3px solid var(--gold);
  background: rgba(201, 168, 76, .10);
  border-radius: 4px;
  font-size: .86rem;
  line-height: 1.5;
  color: var(--text-on-white-dim);
}
.ed-email-field input[type="email"] { font-weight: 600; }

/* Field hints under phone/email in the delivery block. */
.woocommerce form .form-row .description {
  display: block;
  margin-top: 6px;
  font-size: .84rem;
  color: var(--text-on-white-dim);
}

/* Field hints must be readable, not a tooltip.
   WooCommerce styles .description inside .woocommerce-input-wrapper as an
   absolutely-positioned popup that is display:none until the field is focused,
   with a selector that outranks a plain .form-row .description rule. These
   hints carry real instructions - "Required by our printer for delivery" - so
   they are pinned open underneath the field instead. */
.woocommerce form .form-row .woocommerce-input-wrapper .description {
  display: block;
  position: static;
  margin: 6px 0 0;
  padding: 0;
  background: none;
  border: none;
  box-shadow: none;
  color: var(--text-on-white-dim);
  font-size: .84rem;
  line-height: 1.45;
}
.woocommerce form .form-row .woocommerce-input-wrapper .description::before { display: none; }

/* The Lulu phone rule sets form-row-wide and wins over the form-row-first set
   later, so the phone takes a full line. The email matches it rather than
   being left stranded at half width beside empty space - both are long values
   that read better on their own line anyway. */
#shipping_email_field,
#billing_email_field { grid-column: 1 / -1; }

/* ---------- What the customer typed ----------
   Their own answers should read weighted and dark; an empty field stays quiet.
   :placeholder-shown separates the two with no JavaScript. Carried over from
   the Globalgood checkout, where it was introduced for the same reason.

   Selects are weighted unconditionally because they always show a value, and a
   field with no placeholder attribute never matches :placeholder-shown - which
   is harmless, since an empty field has no letters to weight. */
.woocommerce form .form-row input.input-text:not(:placeholder-shown),
.woocommerce form .form-row textarea:not(:placeholder-shown),
.woocommerce form .form-row select,
.woocommerce .select2-container .select2-selection--single .select2-selection__rendered,
.woocommerce .quantity .qty,
.woocommerce .coupon #coupon_code:not(:placeholder-shown) {
  font-weight: 600;
  letter-spacing: .1px;
  color: var(--text-on-white);
}

/* ---------- Variation selector (Format: Paperback / Hardcover / eBook) ----------
   This select lives in a <table class="variations"> inside form.cart, NOT in a
   .form-row, so the field rules further up never reach it and it renders as a
   bare browser dropdown. It is the single most important control on a product
   page here - it chooses the binding - so it gets the full field treatment. */
.woocommerce div.product form.cart .variations select {
  padding: 12px 16px;
  border: 1px solid #d9dde4;
  border-radius: 4px;
  background: var(--off-white);
  font-family: var(--sans);
  font-weight: 600;
  font-size: 1rem;
  color: var(--text-on-white);
  min-width: 230px;
  max-width: 100%;
}
.woocommerce div.product form.cart .variations select:focus {
  outline: none;
  border-color: var(--gold);
  background: #fff;
}
.woocommerce div.product form.cart .variations th.label label {
  font-family: var(--display);
  font-weight: 600;
  color: var(--text-on-white);
}
/* The price that appears once a format is chosen. */
.woocommerce div.product .woocommerce-variation-price .price {
  font-family: var(--display);
  color: var(--gold);
}
/* Add to cart is disabled until a format is picked - make that read as waiting,
   not broken. */
.woocommerce div.product form.cart .button.disabled,
.woocommerce div.product form.cart .button:disabled {
  opacity: .45;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

/* ---------- Covers read as BOOKS, not flat pictures ----------
   Same treatment as .live-book-inner img on the home page: a stack of 1px
   shadows down the right edge that reads as page thickness, a soft spine line
   on the left, and a floating drop shadow. Done in CSS rather than baked into
   the artwork so one flat cover file serves the shop, the product page and the
   cart without three separate exports.

   The gallery needs right-hand padding or the page edges are clipped by the
   wrapper's overflow. */
.woocommerce div.product div.images { padding-right: 16px; }
.woocommerce div.product div.images .woocommerce-product-gallery__image img,
.woocommerce div.product div.images img.wp-post-image {
  border-radius: 3px 10px 10px 3px;
  box-shadow:
    1px 0 0 #c3cad5, 2px 0 0 #f7f8fa, 3px 0 0 #c3cad5,
    4px 0 0 #f7f8fa, 5px 0 0 #c3cad5, 6px 0 0 #f7f8fa,
    7px 0 0 #c3cad5, 8px 0 0 #f7f8fa, 9px 0 0 #c3cad5,
    10px 0 0 #f7f8fa, 11px 0 0 #aab3c1,
    inset 6px 0 8px -4px rgba(0,0,0,0.18),
    24px 38px 45px rgba(19,33,64,0.32);
}

/* Shop grid thumbnails get the same idea at a smaller scale - a full 11px
   stack on a 260px thumbnail would read as a border, not pages. */
.woocommerce ul.products li.product img {
  border-radius: 3px 8px 8px 3px;
  box-shadow:
    1px 0 0 #c3cad5, 2px 0 0 #f7f8fa, 3px 0 0 #c3cad5,
    4px 0 0 #f7f8fa, 5px 0 0 #c3cad5, 6px 0 0 #aab3c1,
    inset 4px 0 6px -3px rgba(0,0,0,0.18),
    10px 16px 22px rgba(19,33,64,0.26);
}

/* Cart and checkout line-item thumbnails: a hint of the same, scaled right down. */
.woocommerce table.cart img,
.woocommerce-checkout #order_review img {
  border-radius: 2px 5px 5px 2px;
  box-shadow:
    1px 0 0 #c3cad5, 2px 0 0 #f7f8fa, 3px 0 0 #aab3c1,
    4px 6px 10px rgba(19,33,64,0.22);
}

/* WooCommerce clears its float layout with ul.products::before/::after set to
   display:table. The shop grid above is CSS grid, and in a grid container those
   pseudo-elements become REAL GRID ITEMS - the ::before silently occupied cell
   one, pushing the first book into column two and wrapping the third onto a
   second row with an empty space where it should have been. */
.woocommerce ul.products::before,
.woocommerce ul.products::after { content: none; display: none; }

/* "Your order" must sit directly under its heading.
   #customer_details spans both rows, so with implicit row sizing the browser
   splits ITS height across them: a 25px heading was getting a 249px row and the
   order table started a quarter of the way down the page. Sizing row 1 to its
   content and giving row 2 the remainder fixes it without touching the span. */
.woocommerce-checkout form.checkout { grid-template-rows: auto 1fr; }

/* Product, shop and cart images are now the book MOCKUPS from the home page
   shelf - they already carry their own page edges, spine and shadow in the
   artwork. The CSS page-edge stack earlier in this file would draw a second set
   on top, so it is switched off wherever the mockup is shown. Keep the CSS
   version in mind if a flat cover is ever used in these slots again. */
.woocommerce div.product div.images .woocommerce-product-gallery__image img,
.woocommerce div.product div.images img.wp-post-image,
.woocommerce ul.products li.product img,
.woocommerce table.cart img,
.woocommerce-checkout #order_review img {
  border-radius: 4px;
  box-shadow: none;
}
.woocommerce div.product div.images { padding-right: 0; }

/* Book cover beside each line in the checkout order review. WooCommerce has no
   image column there, so the cover is prepended to the name - these rules put
   the two back into a row. */
.ed-review-item { display: flex; align-items: center; gap: 12px; }
.ed-review-thumb { flex: 0 0 auto; line-height: 0; }
.ed-review-thumb .ed-review-thumb-img,
.ed-review-thumb img {
  width: 52px;
  height: auto;
  border-radius: 4px;
  box-shadow: 0 4px 10px rgba(19, 33, 64, .22);
  display: block;
}
.ed-review-name { flex: 1 1 auto; min-width: 0; }
.woocommerce-checkout #order_review td.product-name { vertical-align: middle; }

/* ==========================================================================
   Emilio-specific collisions and shop furniture

   Everything above is the structural WooCommerce mapping. The rules below exist
   only because of things already in his site.css, or because the shop needs a
   hero of its own to read as part of the site.
   ========================================================================== */

/* HIS .form-row is a two-column grid for the home-page contact form, declared
   globally. WooCommerce gives every checkout field a <p class="form-row">, so
   without this every single field became a two-column grid and the labels and
   inputs sat side by side. This has to come after site.css, which is why
   woocommerce.css is enqueued with site.css as a dependency. */
.woocommerce .form-row,
.woocommerce-page .form-row,
.woocommerce form .form-row {
  display: block;
  grid-template-columns: none;
  gap: 0;
  margin: 0 0 18px;
}
.woocommerce form .form-row label { display: block; margin-bottom: 7px; }

/* His form fields are styled for the navy contact panel - white text on a
   translucent white fill. On the shop, which is white, that is invisible text
   on an invisible box. Scope his version back to the contact form. */
.woocommerce .form-group input,
.woocommerce .form-group textarea,
.woocommerce-page .form-group input,
.woocommerce-page .form-group textarea {
  background: #fff;
  border: 1px solid #d9dde4;
  color: var(--text-on-white);
}

/* ---------- Shop / cart / checkout page hero ----------
   The static site opens every interior page with a navy band. Without one the
   shop started with a bare H1 on white and read as a different website. */
.ed-shop-hero {
  padding: 150px 0 60px;
  text-align: center;
  background:
    radial-gradient(ellipse 60% 50% at 50% 40%, rgba(201, 168, 76, 0.06), transparent 70%),
    var(--navy);
}
.ed-shop-hero .eyebrow {
  font-family: var(--sans);
  font-size: 0.76rem;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 16px;
}
.ed-shop-hero h1 {
  font-family: var(--display);
  font-size: clamp(2.1rem, 4.4vw, 3.2rem);
  color: var(--text-on-navy);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 14px;
}
.ed-shop-hero p {
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.1rem;
  color: var(--text-on-navy-dim);
  max-width: 640px;
  margin: 0 auto;
}
.ed-shop-hero .ornament {
  display: flex; justify-content: center; align-items: center; gap: 18px;
  margin-top: 26px;
}
.ed-shop-hero .ornament span { width: 50px; height: 1px; background: var(--gold); }
.ed-shop-hero .ornament .dot { color: var(--gold); }

/* The body of every shop page sits on the manuscript texture, same as the
   Book Shelf, so the two pages share a floor. */
.ed-shop-main {
  padding: 70px 0 110px;
  background: var(--white) url('manuscript-texture.png') repeat;
  background-size: 400px;
  min-height: 40vh;
}
.ed-shop-main .container { max-width: 1240px; }

/* WooCommerce prints its own page title inside the content; the hero already
   carries it. */
.ed-shop-main > .container > h1.entry-title,
.woocommerce-products-header { display: none; }

/* Product cards pick up the Book Shelf card treatment. */
.woocommerce ul.products li.product {
  background: rgba(255,255,255,0.75);
  border-radius: 12px;
  padding: 20px 20px 28px;
  text-align: center;
  box-shadow: 0 2px 12px rgba(0,0,0,0.04);
  transition: box-shadow .5s cubic-bezier(.25,.8,.25,1), transform .5s cubic-bezier(.25,.8,.25,1);
}
.woocommerce ul.products li.product:hover {
  box-shadow: 0 16px 48px rgba(201,168,76,0.18), 0 4px 16px rgba(0,0,0,0.06);
  transform: translateY(-6px);
}
.woocommerce ul.products li.product .woocommerce-loop-product__title {
  font-family: var(--display);
  font-weight: 500;
  font-size: 1.12rem;
  color: var(--text-on-white);
}
.woocommerce ul.products li.product .price {
  font-family: var(--sans);
  font-weight: 600;
  color: var(--gold-deep);
}

/* Single product: his display face on the title, serif on the description. */
.woocommerce div.product .product_title {
  font-family: var(--display);
  font-weight: 500;
  letter-spacing: 0.01em;
}
.woocommerce div.product p.price,
.woocommerce div.product span.price {
  font-family: var(--sans);
  font-weight: 600;
  color: var(--gold-deep);
}
.woocommerce div.product .woocommerce-product-details__short-description,
.woocommerce div.product #tab-description {
  font-family: var(--serif);
  font-size: 1.1rem;
  line-height: 1.85;
}

/* A line under the add-to-cart telling the reader what happens next. */
.ed-buy-note {
  margin-top: 16px;
  font-family: var(--sans);
  font-size: .86rem;
  line-height: 1.7;
  color: var(--text-on-white-dim);
  border-left: 2px solid var(--gold);
  padding-left: 14px;
}
.ed-buy-note a { color: var(--gold-deep); text-decoration: underline; }

@media (max-width: 760px) {
  .ed-shop-hero { padding: 120px 0 46px; }
  .ed-shop-main { padding: 46px 0 70px; }
}
