/*
Theme Name:       Mayfield
Theme URI:        https://www.mayfieldeggs.co.uk/
Description:      Mayfield Farm Shop theme — a Storefront child implementing the new Mayfield design. Owns all presentation (global shell, design tokens, WooCommerce + checkout templates and styling). Theme-independent logic lives in plugins (InstaDeliveryScheduler, mf-custom-checkout service layer).
Author:           Mayfield / InstaDispatch
Template:         storefront
Version:          0.1.0
License:          GNU General Public License v2 or later
License URI:      http://www.gnu.org/licenses/gpl-2.0.html
Text Domain:      mayfield
*/

/* =====================================================================
   MAYFIELD — P0 GLOBAL SHELL STYLESHEET
   Ported from the design system (mayfield-website/styles.css).
   Scope (P0): 1) Tokens  2) Base  3) Layout  4) Header/Nav  5) Footer
               6) Buttons  7) Responsive / mobile shell
   Product, single-product, account and checkout styling land in P1–P4.
   ===================================================================== */

/* ---------- 1) DESIGN TOKENS ---------- */
:root {
  /* Brand colours */
  --dark-green: #00473b;
  --teal: #6e969a;
  --brown: #93705d;
  --terracotta: #cb8967;
  --orange: #e87722;
  --sage: #c0c1b5;
  --pink-bg: #f2e1d9;
  --off-white: #faf7f5;
  --white: #ffffff;
  --black: #000000;

  /* Type */
  --font-head: "Arbutus Slab", Georgia, serif;
  --font-body: "Open Sans", "Segoe UI", sans-serif;
  --font-hand: "Shadows Into Light", cursive;

  /* Spacing scale */
  --sp-1: 6px;
  --sp-2: 12px;
  --sp-3: 18px;
  --sp-4: 24px;
  --sp-5: 30px;
  --sp-6: 44px;
  --sp-7: 64px;

  /* Misc */
  --container: 1200px;
  --radius: 6px;
  --radius-lg: 12px;
  --shadow: 0 6px 22px rgba(40, 30, 20, 0.08);
  --shadow-sm: 0 2px 8px rgba(40, 30, 20, 0.07);
}

/* ---------- 2) BASE ---------- */
.mayfield-shell * { box-sizing: border-box; }

body {
  font-family: var(--font-body);
  font-size: 20px;
  line-height: 1.5;
  color: var(--black);
  background: var(--pink-bg);
  -webkit-font-smoothing: antialiased;
}

.mayfield-shell img { max-width: 100%; display: block; }
.mayfield-shell a {  text-decoration: none; }

.page-title {
  font-family: var(--font-head);
  font-weight: 500;
  font-size: 54px;
  line-height: 1.05;
  color: var(--teal);
  margin: 0;
}

.panel-title {
  font-family: var(--font-head);
  font-weight: 400;
  font-size: 38px;
  line-height: 1.1;
  color: var(--black);
  margin: 0 0 var(--sp-3);
}

.hand { font-family: var(--font-hand); font-weight: 400; }

/* ---------- 2b) NATIVE BASE RESET ----------
   Storefront's design CSS is dequeued (fully native). This lightweight base keeps
   not-yet-styled surfaces (catalog→P1, product→P2, cart/checkout→P3, account→P4)
   legible in the meantime. Full per-surface styling lands in those phases. */
/* Arbutus Slab ships a single weight (400); browsers fake-bold h1–h6 by default
   which makes headings render heavy/dark. Match the design's reset to 400. */
h1, h2, h3, h4, h5, h6 { font-family: var(--font-head); line-height: 1.15; font-weight: 400; }
p { margin: 0 0 var(--sp-3); }
ul, ol { margin: 0 0 var(--sp-3); }
/* a:hover { color: var(--dark-green); }
 */
/* Buttons (WooCommerce + generic) baseline mapped to brand */
button,
input[type="submit"],
.woocommerce a.button,
.woocommerce button.button,
.woocommerce input.button,
.woocommerce #respond input#submit {
  font-family: var(--font-body);
  font-weight: 700;
  letter-spacing: .18em;
  text-transform: uppercase;
  background: var(--teal);
  color: #fff;
  border: 0;
  border-radius: var(--radius);
  padding: 12px 22px;
  cursor: pointer;
  line-height: 1;
}
.woocommerce a.button:hover,
.woocommerce button.button:hover,
.woocommerce input.button:hover { filter: brightness(1.06); }
.woocommerce a.button.alt,
.woocommerce button.button.alt { background: var(--orange); }

/* Form fields baseline */
input[type="text"], input[type="email"], input[type="password"],
input[type="tel"], input[type="number"], input[type="search"],
select, textarea {
  font-family: var(--font-body);
  font-size: 16px;
  border: 1px solid var(--sage);
  border-radius: var(--radius);
/*   padding: 10px 12px; */
  background: #fff;
  color: var(--black);
  max-width: 100%;
}

/* WooCommerce notices — on-brand (Storefront CSS is dequeued) */
.woocommerce-message,
.woocommerce-info,
.woocommerce-error {
  background: var(--off-white);
  border-left: 4px solid var(--teal);
  border-radius: 6px;
  padding: 14px 18px;
  margin: 0 0 var(--sp-4);
  list-style: none;
  font-size: 14px;
  font-weight: 600;
  color: #000;
}
.woocommerce-message { background: #edf4f1; border-left-color: var(--teal); }
.woocommerce-info { border-left-color: var(--teal); }
.woocommerce-error { background: #fbeceb; border-left-color: #c0392b; color: #7a1f17; }
.woocommerce-message li,
.woocommerce-info li,
.woocommerce-error li { list-style: none; margin: 0 0 4px; }
.woocommerce-message li:last-child,
.woocommerce-info li:last-child,
.woocommerce-error li:last-child { margin-bottom: 0; }
.woocommerce-error .button,
.woocommerce-message .button { float: right; }
/* Contain the floated "View cart" button so it doesn't spill out of the notice. */
.woocommerce-message::after,
.woocommerce-info::after,
.woocommerce-error::after { content: ""; display: table; clear: both; }
/* Storefront prints WooCommerce notices full-width via storefront_content_top
   (storefront_shop_messages → [woocommerce_messages]) as a direct child of
   .col-full. Constrain that wrapper to the content container so notices
   (e.g. "added to cart / View cart") don't span the whole viewport. */
#content .col-full > .woocommerce {
  width: var(--container);
  max-width: 100%;
  margin: var(--sp-4) auto 0;
  box-sizing: border-box;
}
@media (max-width: 1240px) {
  #content .col-full > .woocommerce { padding: 0 20px; }
}

/* ---------- 3) LAYOUT ---------- */
.site .container {
  width: var(--container);
  max-width: 100%;
  margin: 0 auto;
}

/* Storefront's content wrapper is unstyled (its CSS is dequeued); the inner
   .container governs width/centering. Keep .col-full a plain full-width band. */
.mayfield-shell #content .col-full { width: 100%; max-width: 100%; padding: 0; }

main, .mf-main { 
	display: block;
/* 	padding-bottom: var(--sp-7); */
}

.page-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--sp-4);
  margin: var(--sp-5) 0;
}
/* My Subscription page: on mobile the "My Deliveries" button drops below the
   H1 as a FULL-WIDTH button (before the portal content). */
@media (max-width: 768px) {
  .page-head.mf-sub-head { flex-direction: column; align-items: stretch; gap: var(--sp-3); }
  .page-head.mf-sub-head .btn { width: 100%; text-align: center; }
}
.page-head .page-title { flex: 0 1 auto; }
.page-head .btn { flex: none; background: #fff; }

.row { display: flex; gap: var(--sp-4); }
.col { display: flex; flex-direction: column; gap: var(--sp-4); }
.between { display: flex; align-items: center; justify-content: space-between; }
.muted { color: #000; }

/* Paper panel — the design's standard content card */
.paper-panel {
  position: relative;
  background: var(--off-white);
  box-shadow: 0 5px 6px rgba(40, 30, 20, 0.08);
  padding: var(--sp-5);
  margin-bottom: 26px;
  /* border: 0; */
  width: 100%;
}
/* .paper-panel::after {
  content: "";
  position: absolute;
  left: -1px;
  right: -1px;
  bottom: -7px;
  height: 8px;
  background: url("assets/img/bg-shape-zigzag.png") repeat-x bottom center;
  background-size: auto 178px;
  pointer-events: none;
  z-index: 2;
} */
.paper-panel.flat { border-radius: var(--radius-lg); }
.paper-panel.flat::after { display: none; }
.mf-entry-content > :last-child { margin-bottom: 0; }

/* Grids */
.grid { display: grid; gap: var(--sp-5); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

/* Section eyebrow heading */
.section-head { margin-bottom: var(--sp-4); }


.pc-divider { height: 1px; background: var(--sage); border: 0; margin: 4px 0; }

/* ---------- 3b) PRODUCT CARDS / SHOP ---------- */
.shop-page .paper-panel { margin-bottom: 30px; }

.section-head.bestseller-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-3);
}

.product-card {
  position: relative;
  background: var(--white);
/*   border-radius: var(--radius-lg); */
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  margin: 0;
}
.product-card .pc-img,
.product-card .pc-img-link img {
  background: #efe7dd;
  object-fit: cover;
  width: 100%;
  aspect-ratio: 595 / 333;
  height: auto;
  display: block;
}
.product-card .pc-body {
  padding: var(--sp-3);
  display: flex;
  flex-direction: column;
  gap: var(--sp-2);
  flex: 1;
}
.pc-title {
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 21px;
  line-height: 1.2;
  margin: 0;
}
/* .pc-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-2);
  margin-top: auto;
} */
.pc-price { font-weight: 700; font-size: 22px; }
.pc-add {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--teal);
  color: #fff;
  border: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex: none;
}
.pc-add:hover { background: var(--dark-green); }

/* Label chip (e.g. Free Delivery) */
/* .chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--orange);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  padding: 6px 12px;
  border-radius: 20px;
} */
.chip-green { background: var(--dark-green); }

/* Full-width Bestseller card (design) */
.mf-bestseller-card {
  background: transparent;
  box-shadow: none;
  border-radius: 0;
  overflow: visible;
}
.mf-bestseller-card .pc-img-link { display: block; }
.mf-bestseller-card .pc-img,
.mf-bestseller-card .pc-img-link img {
  width: 100%;
  height: 300px;
  object-fit: cover;
/*   border-radius: var(--radius-lg); */
}
.mf-bestseller-card .pc-body { padding: var(--sp-4) var(--sp-1) 0; }
/* .mf-bestseller-card .pc-body > .pc-row { align-items: center; gap: var(--sp-3); } */
.mf-bestseller-card .pc-title { font-size: 22px; }
.mf-bestseller-buy { flex: none; justify-content: flex-end; gap: var(--sp-3); }

/* Bestseller "Free Delivery" — teal text label (not a filled pill) */

.bestseller-head .chip svg { width: 24px; height: 24px; }

/* ---------- 3c) SINGLE PRODUCT ---------- */
main.mf-product.mf-main {
    padding-bottom: 0;
}
.mf-product .product-detail {
  display: grid;
  grid-template-columns: 1fr 420px;
  gap: 44px;
  align-items: start;
  margin-bottom: var(--sp-6);
}
/* Kill WooCommerce's float layout — we use grid; this prevents the container
   collapsing and the footer overlapping the product. */
.mf-product .woocommerce-product-gallery,
.mf-product .summary.entry-summary {
  float: none !important;
  width: auto !important;
  margin: 0 !important;
}
.mf-product .product { display: block; }

/* Gallery: ensure visible without WooCommerce gallery CSS (no flexslider). */
.mf-product .woocommerce-product-gallery {
  opacity: 1 !important;
  width: auto !important;
  float: none !important;
  margin: 0 !important;
}
.mf-product .woocommerce-product-gallery__wrapper { margin: 0; display: block; }
.mf-product .woocommerce-product-gallery .flex-viewport { height: auto !important; }
.mf-product .woocommerce-product-gallery__image { display: block; }
.mf-product .woocommerce-product-gallery__image + .woocommerce-product-gallery__image { margin-top: var(--sp-3); }

/* Product image — fixed 16:9 box matching the registered `mayfield_product`
   image size (1200×675). aspect-ratio defines the height so the image never
   blows up vertically; object-fit:cover keeps the framing consistent even for
   images not yet regenerated to the new size. */
.mf-product .pd-gallery img,
.mf-product .pd-gallery img, .mf-product .woocommerce-product-gallery img {
    width: 100%;
    height: auto;
    /* Fixed landscape frame so every product image is the SAME height/box
       regardless of its source dimensions; object-fit:cover crops to fill so
       nothing is stretched. */
    aspect-ratio: 595 / 333;
    object-fit: cover;
    /* border-radius: var(--radius-lg); */
    background: #efe7dd;
    box-shadow: var(--shadow);
}

/* Summary panel */
/* .mf-product .summary.paper-panel { padding: 22px; background: var(--off-white); } */
.mf-product .summary .product_title {
  font-family: var(--font-head);
  font-weight: 400;
  font-size: 30px;
  line-height: 1.15;
  margin: 0 0 10px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--sage);
}
.mf-product .summary .price {
  font-family: var(--font-body);
  font-size: 18px;
  font-weight: 700;
  color: #000;
  padding-bottom: 14px;
  margin: 0 0 18px;
  border-bottom: 1px solid var(--sage);
}
.mf-product .summary .woocommerce-product-details__short-description {
  margin-bottom: 18px;
  color: #5b5249;
}

/* Add-to-cart form — flex column so we can match the design's visual order
   (quantity → purchase options → frequency → subscription details → button)
   regardless of DOM order. The InstaDeliveryScheduler (IDS) plugin renders its
   purchase-mode + frequency block (.ids-pdp-schedule) on
   woocommerce_before_add_to_cart_button — i.e. *before* the quantity field in
   the DOM — so `order` is what puts quantity back on top. */
.mf-product .summary form.cart:not(.variations_form),
.mf-product .summary .woocommerce-variation-add-to-cart {
  display: flex;
  flex-direction: column;
  margin: 0;
  /* White box is NOT on the whole buy area — only the radio group gets it
     (see .ids-pdp-schedule > div:not([id]) below), so Subscription details /
     Add to cart sit outside the box, matching the design. */
}
/* .mf-product .summary form.cart .quantity,
.mf-product .summary .woocommerce-variation-add-to-cart .quantity { order: 1; }
.mf-product .summary .ids-pdp-schedule { order: 2; }
.mf-product .summary .mf-sub-details { order: 3; }
.mf-product .summary .single_add_to_cart_button { order: 4; } */

/* White card grouping the option controls (size/variation, purchase mode,
   frequency, subscription details). Built by mayfield-shell.js between the
   quantity (above) and the add-to-cart button (below). */
.mf-product .summary form.cart .white-box {
    background: #fff;
    box-shadow: var(--shadow);
    padding: 20px 20px;
    margin: 0 0 18px;
}
.mf-product .summary  .single_variation .price {
    border-bottom: 0;
    display: flex;
    align-items: center;
    padding: 10px 0px;
    margin: 0;
}
.mf-product .summary .woocommerce-product-details__short-description p {
    font-size: 18px;
}
.mf-product .summary form.cart .white-box > .variations { margin-bottom: 6px; }
.mf-product .summary form.cart .white-box .mf-sub-details { margin-top: 4px; }
/* The purchase-mode radio group carries its own card styling; flatten it inside
   the white-box so the two cards don't nest. */
.mf-product .summary .white-box .ids-pdp-schedule { margin: 0 !important; }
.mf-product .summary .white-box .ids-pdp-schedule > div:not([id]) {
  background: transparent;
  box-shadow: none;
  border-radius: 0;
  padding: 0;
}
/* Variation availability / stock message, lifted by mayfield-shell.js to sit
   directly under the size selector. In stock = teal; out of stock / error
   (e.g. "Stock not found", "Out of stock") = dark red. */
.mf-product .summary .white-box .woocommerce-variation-availability.mf-avail-below-size {
  margin: 8px 0 14px;
}
.mf-product .summary .white-box .woocommerce-variation-availability .stock {
  margin: 0;
  font-size: 14px;
  font-weight: 700;
  color: var(--teal);
}
.mf-product .summary .white-box .woocommerce-variation-availability .stock.out-of-stock,
.mf-product .summary .white-box .woocommerce-variation-availability .out-of-stock,
.mf-product .summary .white-box .woocommerce-variation-availability p.unavailable {
  color: #8b0000;
}

/* Quantity stepper: "Quantity − [n] +" (buttons + label injected by
   mayfield-shell.js; .mf-qty is added at the same time). */
.mf-product .summary form.cart .quantity.mf-qty {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 18px;
}
.mf-product .summary form.cart .quantity.mf-qty .mf-qty-label {
  font-size: 15px;
  color: #000;
  margin-right: 4px;
}
.mf-product .summary form.cart .quantity.mf-qty button {
  width: 25px;
  height: 25px;
  min-width: 25px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: var(--pink-bg);
  color: #000;
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
	letter-spacing:0;
}
.mf-product .summary form.cart .quantity.mf-qty button:hover { filter: brightness(.97); }
.mf-product .summary form.cart .quantity.mf-qty input.qty {
  width: 42px;
  height: 34px;
  text-align: center;
  border: 1px solid var(--sage);
  border-radius: 8px;
  font-weight: 700;
  background: #fff;
  -moz-appearance: textfield;
}
.mf-product .summary form.cart .quantity.mf-qty input.qty::-webkit-outer-spin-button,
.mf-product .summary form.cart .quantity.mf-qty input.qty::-webkit-inner-spin-button {
  -webkit-appearance: none;
  appearance: none;
  margin: 0;
}

/* Variations (e.g. Size) — render WooCommerce's variations table as a clean
   row that lines up with the Quantity row below it. */
.mf-product .summary .variations { margin: 0 0 16px; }
.mf-product .summary .variations,
.mf-product .summary .variations tbody,
.mf-product .summary .variations tr,
.mf-product .summary .variations th.label,
.mf-product .summary .variations td.value {
  display: block;
  padding: 0;
  border: 0;
}
.mf-product .summary .variations tr {
  display: flex;
  align-items: center;
  gap: 10px;
}
.mf-product .summary .variations th.label label,
.mf-product .summary form.cart .quantity.mf-qty .mf-qty-label {
  min-width: 76px;
  margin: 0;
  font-size: 15px;
  font-weight: 400;
  color: #000;
  text-align: left;
}
.mf-product .summary .variations td.value {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 8px;
}
.mf-product .summary .variations select {
  flex: 1;
  max-width: 240px;
  height: 44px;
  margin: 0;
  padding: 0 38px 0 14px;
  border: 1px solid var(--sage);
  border-radius: 8px;
  background-color: #fff;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='9' viewBox='0 0 14 9'%3E%3Cpath fill='none' stroke='%23000' stroke-width='1.6' d='M1 1l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  font-size: 14px;
  color: #000;
  cursor: pointer;
}
.mf-product .summary .reset_variations {
  font-size: 13px;
  color: var(--teal);
  white-space: nowrap;
}

/* ---- Purchase options (InstaDeliveryScheduler .ids-pdp-schedule) ----
   IDS renders this server-side with INLINE styles (display:flex on the radio
   row, display:block on the heading, min-width on the select), so several
   rules below need !important to win over those inline styles. We restyle the
   plugin markup only — its inputs (ids_purchase_mode / ids_frequency_weeks)
   and toggle script are untouched. */
.mf-product .summary .ids-pdp-schedule { margin: 0 0 18px !important; }

/* Hide the "Purchase option" heading — the design has none. */
.mf-product .summary .ids-pdp-schedule > label:first-child { display: none !important; }

/* The radio row container → white card, stacked. */
/* White card wraps ONLY the two radios (One time purchase / Subscribe);
   Subscription details + Add to cart sit outside it. */
.mf-product .summary .ids-pdp-schedule > div:not([id]) {
  flex-direction: column !important;
  gap: 0 !important;
  background: #fff;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  padding: 8px 22px;
  margin-bottom: 16px;
}
.mf-product .summary .ids-pdp-schedule > div:not([id]) > label {
  gap: 14px !important;
  padding: 12px 0;
  margin: 0;
  cursor: pointer;
  font-size: 16px;
  font-weight: 400;
  color: #000;
	padding-bottom: 5px;
}
.mf-product .summary .ids-pdp-schedule input[type="radio"] {
  width: 24px;
  height: 24px;
  margin: 0;
  accent-color: #000;
  flex: 0 0 auto;
  cursor: pointer;
}

/* Frequency block (shown by IDS JS when "Subscribe" is selected). */
.mf-product .summary #ids-subscription-options {
    margin-top: 16px !important;
    padding-left: 39px;
}
.mf-product .summary #ids-subscription-options > label {
  font-size: 15px;
  font-weight: 400 !important;
  color: #000;
  margin-bottom: 6px !important;
}
.frequency-input-box {
    display: flex;
    align-items: center;
    gap: 10px;
}
.frequency-input-box label {
    font-size: 16px;
    font-weight: 500 !important;
    margin-bottom: 0 !important;
}
.mf-product .summary select#ids_frequency_weeks {
/*   width: 100% !important; */
  min-width: 0 !important;
  height: 30px;
  padding: 0 50px 0 16px;
  border: 1px solid var(--sage);
  border-radius: 8px;
  background-color: #fff;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='9' viewBox='0 0 14 9'%3E%3Cpath fill='none' stroke='%23000' stroke-width='1.6' d='M1 1l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: #000;
  cursor: pointer;
}
.mf-product .summary #ids-subscription-options small {
  font-size: 13px;
  color: #8a8178 !important;
}

/* "Subscription details" collapsible (theme-added, presentation only). */
.mf-product .summary .mf-sub-details { margin: 0 0 18px;    padding-left: 39px; }
.mf-product .summary .mf-sub-details__toggle {
    display: flex;
    align-items: center;
    justify-content: start;
    gap: 30px;
    width: 100%;
    height: 40px;
    text-transform: capitalize;
    letter-spacing: 0;
    margin: 0 auto;
    padding: 0 16px;
    background: #f7f2ef;
    border: 0;
    border-radius: 8px;
    cursor: pointer;
    font-family: var(--font-body);
    font-size: 16px;
    font-weight: 400;
    color: #000;
}
.mf-product .summary .mf-sub-details__icon {
  color: var(--teal);
  font-size: 22px;
  line-height: 1;
}
.mf-product .summary .mf-sub-details__body {
  margin: 12px auto 0;
  max-width: 320px;
  font-size: 14px;
  line-height: 1.6;
  color: #5b5249;
}
.mf-product .summary .mf-sub-details__body > :last-child { margin-bottom: 0; }

/* Add to basket — selector carries .button.alt so it beats the global
   `.woocommerce button.button.alt { background: var(--orange) }` rule (which
   was turning this button orange). */
.mf-product .summary .single_add_to_cart_button,
.mf-product .summary .single_add_to_cart_button.button.alt {
  display: block;
  width: 100%;
  background: var(--teal);
  color: #fff;
  border: 0;
  border-radius: 10px;
  padding: 14px 24px;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: .2em;
  text-transform: uppercase;
  cursor: pointer;
}
.mf-product .summary .single_add_to_cart_button:hover { filter: brightness(1.06); }

/* Design omits the star-rating line and the SKU/Category/Tag meta in the
   summary panel — hide to match product.html. */
.mf-product .summary .woocommerce-product-rating,
.mf-product .summary .product_meta {
  display: none;
}

/* Accordion (design component: product info) */
.accordion { border-top: 1px solid var(--sage); }
.acc-item { border-bottom: 1px solid var(--sage); }
.acc-head {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 4px;
  background: none;
  border: 0;
  cursor: pointer;
  font-family: var(--font-head);
  font-size: 20px;
  color: var(--black);
  text-align: left;
}
.acc-head .pm { font-size: 26px; color: var(--teal); line-height: 1; transition: transform .15s; }
.acc-body { display: none; padding: 0 4px 18px; font-size: 16px; color: #5b5249; }
.acc-body > :last-child { margin-bottom: 0; }
.acc-item.open .acc-body { display: block; }
.acc-item.open .pm { transform: rotate(45deg); }

/* Product summary accordion tweaks (matches product.html) */
.mf-product .summary .accordion { margin-top: 24px; }
/* .mf-product .summary .acc-head {
  padding: 10px 0;
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 700;
  color: #000;
} */
.mf-product .summary .acc-head .pm { font-family: var(--font-body); font-size: 18px; color: #000; }

/* Tabs (description / reviews) — stacked, on-brand */
.mf-product .woocommerce-tabs { margin-top: var(--sp-6); }
.mf-product .woocommerce-tabs ul.tabs {
  list-style: none;
  margin: 0 0 var(--sp-3);
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-4);
  border-bottom: 1px solid var(--sage);
}
.mf-product .woocommerce-tabs ul.tabs li a {
  font-family: var(--font-head);
  font-size: 20px;
  color: var(--teal);
  padding: 8px 0;
  display: inline-block;
}
.mf-product .woocommerce-tabs ul.tabs li.active a { color: var(--dark-green); border-bottom: 2px solid var(--dark-green); }

/* Related / up-sells — design product-card grid */
.mf-product-extra .section-head {
    margin-top: 0;
}
.mf-product .related > h2,
.mf-product .up-sells > h2 {
  font-family: var(--font-head);
  font-size: 30px;
  color: var(--dark-green);
  margin: 0 0 var(--sp-4);
}
.mf-product .related ul.products,
.mf-product .up-sells ul.products {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--sp-4);
}

@media (max-width: 768px) {
  .mf-product .product-detail { grid-template-columns: 1fr; gap: var(--sp-4); }
  .mf-product .related ul.products,
  .mf-product .up-sells ul.products { grid-template-columns: 1fr; }
}

/* ---------- 4) HEADER + NAV ---------- */
.mayfield-shell .site-header {
  position: relative;
  height: 210px; /* Andy's design header depth — panel needs the room */
  background: var(--white);
  box-shadow: -5px 20px 20px 20px #34343433;
  border: 0;
}

.header-inner {
  position: relative;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.logo { width: 210px; height: auto; margin-top: 0; }

/* Left delivery panel — vertically centred ("order online" label removed) */
.order-online {
  position: absolute;
  top: 0; /* hangs from the very top of the page, per Andy's design */
  left: 0;
  width: 256px;
  background: var(--pink-bg);
  /* drop-shadow (not box-shadow) so the shadow traces the wavy bottom edge
     instead of drawing a hard rectangle band behind the zigzag teeth */
  box-shadow: none;
  /* drop-shadow on the element traces the clipped ::before below, so the
     shadow follows the zigzag (clip-path on the element itself would clip
     the shadow away) */
  filter: drop-shadow(0 5px 7px rgba(52, 52, 52, 0.22));
  padding: 16px 18px 26px;
  text-align: center;
  border: 0; /* design shows no side borders */
  z-index: 3; /* above .nav-wrap (z-index 2) so the buttons + wavy edge stay visible */
  background: transparent;
}

/* panel surface: pink with the zigzag bottom cut into it (design) */
.order-online::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: var(--pink-bg);
  clip-path: polygon(
    0% 0%, 100% 0%, 100% calc(100% - 7px),
    95% 100%, 90% calc(100% - 7px), 85% 100%, 80% calc(100% - 7px),
    75% 100%, 70% calc(100% - 7px), 65% 100%, 60% calc(100% - 7px),
    55% 100%, 50% calc(100% - 7px), 45% 100%, 40% calc(100% - 7px),
    35% 100%, 30% calc(100% - 7px), 25% 100%, 20% calc(100% - 7px),
    15% 100%, 10% calc(100% - 7px), 5% 100%, 0% calc(100% - 7px)
  );
}

/* the old zigzag strip graphic is replaced by the clip-path above */
.order-online::after { display: none; }

.order-online .hand {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--sp-2);
  position: relative;
}

/* Chunky grey dots flanking the label, vertically centred (design zoom) */
.order-online .hand::before, .order-online .hand::after {
    content: '';
    border: none;
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    display: block;
    width: 48px;
    height: 6px;
    background-image: radial-gradient(circle, #c6c6c6 2px, transparent 2.2px);
    background-size: 10px 6px;
    background-repeat: repeat-x;
    background-position: center;
}
.order-online .hand::before { left: 0; }
.order-online .hand::after { right: 0; }

.order-online .hand img {
  display: block !important;
  width: 120px !important;
  max-width: 120px !important;
  height: auto !important;
  margin-bottom: 10px;
}

.order-online .stack { display: flex; flex-direction: column; gap: var(--sp-2); }

/* Panel buttons per design zoom: white pills, generous rounding, soft tan
   text, inset from the panel edges. Overrides .btn declared later. */
.order-online .header-choice-btn {
  padding: 13px 10px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .2em;
  background: #fff;
  border: 1px solid #d8b294;
  border-radius: 12px;
  color: #bd9273;
  margin: 0 12px;
}

.order-online .header-choice-btn:hover {
  background: var(--pink-bg);
  color: #93705d;
}

.order-online .btn-block {
  width: 100%;
  background: var(--white);
  border: 1px solid var(--terracotta);
  color: var(--terracotta);
}

/* Right-hand phone + login, vertically centred */
.header-right {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  right: 20px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--sp-2);
}

.phone-btn {
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
  gap: 10px;
  background: transparent;
  color: var(--terracotta);
  font-weight: 700;
  font-size: 18px;
  padding: 10px 18px;
  border-radius: var(--radius);
  border: 1px solid var(--terracotta);
  letter-spacing: 0.25em;
}

.header-links {
  display: flex;
  align-items: center;
  gap: 10px;
}
.header-link-sep { color: var(--terracotta); font-size: 13px; }

.login-link {
  font-size: 15px;
  font-weight: 600;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--terracotta);
}
.login-link:hover { color: var(--dark-green); }

/* Nav bar — teal pill */
.nav-wrap { position: relative; z-index: 2; top: -8px; } /* -20 grazed the order-online wavy edge */

.main-nav {
  height: 40px;
  background: var(--teal);
  border-radius: 30px;
  box-shadow: var(--shadow-sm);
  display: flex;
  align-items: center;
  justify-content: flex-start;
  color: var(--white);
  gap: 15px;
}

.nav-home {
  color: var(--white);
  transition: background .15s;
  width: 60px !important;
  height: 35px !important;
  border-radius: 100px !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 7px 16px;
  box-shadow: inset 0 0 5px #547475;
}
.nav-home:hover, .nav-icon:hover { background: rgba(255, 255, 255, .18); }

.nav-links {
  display: flex;
  gap: var(--sp-6);
  list-style: none;
  margin: 0;
  padding: 0;
}
.nav-links a {
  font-weight: 700;
  font-size: 14px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--white);
  padding: 6px 2px;
  border-bottom: 2px solid transparent;
}
.nav-links a:hover,
.nav-links li.current-menu-item a { border-bottom-color: var(--white); }

.nav-right {
  display: flex;
  align-items: center;
  gap: 15px;
  margin-left: auto;
  color: var(--white);
  border-radius: 100px !important;
  justify-content: center !important;
  padding: 7px 25px;
  box-shadow: inset 0 0 5px #547475;
}
.nav-right .nav-icon { width: 22px !important; height: 22px !important; display: block !important; }
.nav-right .mf-cart-link { position: relative; }

span.separator, .nav-sep { color: #dedfd8; line-height: 14px; font-size: 14px; }

.nav-icon .badge {
  position: absolute;
  transform: translate(12px, -12px);
  background: var(--orange);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  min-width: 18px;
  height: 18px;
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
}

.mobile-menu-toggle { display: none; }

/* ---------- 5) FOOTER ---------- */
.mayfield-shell .site-footer {
  position: relative;
  overflow: hidden;
  margin-top: var(--sp-7);
  color: var(--white);
  padding: 90px 0 40px;
  background: transparent;
  border: 0;
}

.footer-wave {
  position: absolute;
  top: -1px;
  left: 0;
  width: 100%;
  height: 100%;
  display: block;
}

.site-footer::after {
  content: "";
  position: absolute;
  right: 0;
  top: 100px;
  width: 570px;
  height: 300px;
  pointer-events: none;
  background: url(assets/img/flourish.svg) no-repeat;
  filter: brightness(0) invert(1);
  opacity: 0.28;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr;
  gap: var(--sp-6);
  position: relative;
  z-index: 2;
}
.footer-grid .hand { font-size: 38px; display: block; margin-bottom: var(--sp-2); }

.footer-col h4 { font-family: var(--font-head); font-size: 22px; margin-bottom: var(--sp-3); }
.footer-col p, .footer-col a { font-size: 17px; line-height: 1.7; color: #d9e3df; }
.footer-col a:hover { color: #fff; }

.footer-links { list-style: none; margin: 0; padding: 0; }

.footer-bottom {
  position: relative;
  z-index: 2;
  margin-top: var(--sp-6);
  padding-top: var(--sp-4);
  border-top: 1px solid rgba(255, 255, 255, .18);
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-4);
  font-size: 14px;
  color: #b9c7c1;
  letter-spacing: .04em;
}
.footer-bottom a:hover { color: #fff; }

/* ---------- 6) BUTTONS ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 15px;
  letter-spacing: .22em;
  text-transform: uppercase;
  padding: 13px 24px;
  border-radius: var(--radius);
  border: 2px solid transparent;
  cursor: pointer;
  transition: filter .15s, background .15s, color .15s;
  white-space: nowrap;
  line-height: 1;
}
.btn:hover { filter: brightness(1.06); }
.btn-teal { background: var(--teal); color: #fff; }
.btn-brown { background: var(--brown); color: #fff; }
.btn-orange { background: var(--orange); color: #fff; }
.btn-green { background: var(--dark-green); color: #fff; }
.btn-outline { background: transparent; border-color: var(--terracotta); color: var(--terracotta); }
.btn-outline:hover { background: var(--terracotta); color: #fff; filter: none; }
.btn-block { width: 100%; }
.btn-lg { font-size: 16px; padding: 17px 30px; }
.btn-sm { font-size: 12px; padding: 9px 15px; letter-spacing: .18em; }

/* ---------- 7) RESPONSIVE / MOBILE SHELL ---------- */
@media (max-width: 1240px) {
  .site .container { width: 100%; padding: 0 20px; }
}
.mf-checkout-page main .container {
    padding: 0;
}
@media (max-width: 768px) {
  body { font-size: 18px; }
  .page-title { font-size: 36px; }
  .panel-title { font-size: 28px; }

  .mayfield-shell .site-header {
    height: 55px !important;
    min-height: 55px !important;
    padding: 0 !important;
    background: #fff !important;
    box-shadow: none !important;
    border-top: 4px solid var(--dark-green) !important;
    border-bottom: 1px solid var(--teal) !important;
    position: relative !important;
    z-index: 1000 !important;
  }
  .header-inner {
    height: 51px !important;
    min-height: 51px !important;
    padding: 0 12px !important;
  }
  .order-online, .header-right, .header-order-cta, .header-shop-choice { display: none !important; }
  .logo { width: 92px !important; max-width: 92px !important; margin: 0 auto !important; }

  .nav-wrap {
    position: absolute !important;
    top: 5px !important;
    right: 10px !important;
    left: auto !important;
    width: auto !important;
    z-index: 1200 !important;
  }
  .nav-wrap .container { width: auto !important; padding: 0 !important; }
  .main-nav {
    width: auto !important;
    height: 51px !important;
    background: transparent !important;
    box-shadow: none !important;
    border-radius: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
    justify-content: flex-end !important;
  }
  .nav-home, .nav-links, .nav-right { display: none !important; }

  .mobile-menu-toggle {
    display: inline-flex !important;
    width: 36px !important;
    height: 36px !important;
    align-items: center !important;
    justify-content: center !important;
    border: 0 !important;
    background: transparent !important;
    color: var(--teal) !important;
    font-size: 26px !important;
    line-height: 1 !important;
    cursor: pointer !important;
    padding: 0 !important;
  }
  .mobile-menu-toggle i { pointer-events: none; }

  .mobile-menu-panel {
    display: none;
    position: fixed;
    top: 55px;
    left: 0;
    right: 0;
    width: 100%;
    background: #fff;
    border-bottom: 1px solid var(--teal);
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.12);
    z-index: 999;
    padding: 14px;
  }
  .mobile-menu-panel.is-open { display: block; }
  .mobile-menu-panel a,
  .mobile-menu-panel li > a {
    display: block;
    padding: 13px 6px;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--teal);
    border-bottom: 1px solid #eee;
  }
  .mobile-menu-panel ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex !important;
    flex-direction: column;
    gap: 0;
}
  .mobile-menu-panel a:last-child, .mobile-menu-panel li:last-child > a { border-bottom: 0; }
  body.mobile-menu-open { overflow: hidden; }

  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .page-head {
    flex-direction: column;
    align-items: flex-start;
    margin: 20px 0px;
    gap: 15px;
}
  .footer-grid { grid-template-columns: 1fr; }
  .footer-wave { display: none !important; }
  .mayfield-shell .site-footer {
    margin-top: 0;
    background: var(--dark-green);
    padding: 50px 0px 30px;
  }
  .site-footer::after { top: 50px; width: 120px; height: 200px; }
  .footer-col-mobile { display: none; }
  .footer-bottom { margin-top: 0; }

  html, body { width: 100%; max-width: 100%; overflow-x: hidden; }
}

/* Desktop-only: hide the mobile slide-down panel */
@media (min-width: 769px) {
  .mobile-menu-panel { display: none !important; }

}
@media (min-width: 1600px) {
 .section-head h2 {
    font-family: var(--font-head);
    font-weight: 600;
    font-size: 38px;
    color: var(--black);
    white-space: nowrap;
}
.mf-product .summary .product_title {
    font-family: var(--font-head);
    font-weight: 400;
    font-size: 38px;
    line-height: 1.15;
    margin: 0 0 10px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--sage);
}
.ids-portal .delivery-head h3 {
    font-family: var(--font-head);
    font-size: 38px;
    font-weight: 400;
    margin: 0;
    color: #000;
}
.delivery-head .price {
    font-family: var(--font-head);
    font-size: 34px;
    line-height: 1;
    color: var(--teal);
}
.mf-edit-account .edit-account-panel .panel-title {
    font-size: 38px;
    line-height: 1.15;
    margin: 0 0 18px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--sage);
    color: #000;
}
}

/* =====================================================================
   ORDER RECEIVED / THANK-YOU  (woocommerce/checkout/thankyou.php)
   WC logic/hooks intact; wrapped in Mayfield design. Loaded globally via
   style.css, scoped under .mf-order-received.
   ===================================================================== */
.mf-order-received { max-width: 880px; margin: 0 auto var(--sp-6); }
.mf-order-received .page-head { margin: var(--sp-5) 0 var(--sp-3); }

/* Confirmation card (.paper-panel already supplies the card + zigzag) */
.mf-order-received .mf-or-confirm { text-align: center; padding: var(--sp-6) var(--sp-5) var(--sp-5); }
.mf-order-received .mf-or-check {
  width: 66px; height: 66px; margin: 0 auto var(--sp-3);
  border-radius: 50%; background: var(--teal); color: #fff; font-size: 34px;
  display: flex; align-items: center; justify-content: center;
}
.mf-order-received .woocommerce-thankyou-order-received {
  font-family: var(--font-head); font-size: 30px; line-height: 1.15;
  color: var(--dark-green); margin: 0 0 var(--sp-2);
}
.mf-order-received .mf-or-failed .woocommerce-notice--error { color: #7a1f17; font-size: 18px; }
.mf-order-received .woocommerce-thankyou-order-failed-actions { display: flex; gap: var(--sp-3); justify-content: center; margin-top: var(--sp-3); }

/* Order overview → tidy meta grid */
.mf-order-received .woocommerce-order-overview {
  list-style: none; margin: var(--sp-4) 0 0; padding: var(--sp-4) 0 0;
  border-top: 1px solid var(--sage);
  display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: var(--sp-3); text-align: left;
}
.mf-order-received .woocommerce-order-overview li {
  margin: 0; display: flex; flex-direction: column; gap: 4px;
  font-size: 12px; text-transform: uppercase; letter-spacing: .08em;
  color: var(--teal); font-weight: 700; border: 0;
}
.mf-order-received .woocommerce-order-overview li strong {
  font-size: 16px; text-transform: none; letter-spacing: 0; color: #000; font-weight: 700;
}

/* Order details table + customer details → paper cards with zigzag */
.mf-order-received .woocommerce-order-details,
.mf-order-received .woocommerce-customer-details {
  position: relative; background: var(--off-white);
  box-shadow: 0 5px 6px rgba(40, 30, 20, 0.08);
  border: 2px solid #bcb0a9; border-top: 0; border-bottom: 0;
  padding: var(--sp-5); margin: 0 0 30px;
}
.mf-order-received .woocommerce-order-details::after,
.mf-order-received .woocommerce-customer-details::after {
  content: ""; position: absolute; left: -1px; right: -1px; bottom: -7px; height: 8px;
  background: url("assets/img/bg-shape-zigzag.png") repeat-x bottom center;
  background-size: auto 178px; pointer-events: none;
}
.mf-order-received .woocommerce-order-details > h2,
.mf-order-received .woocommerce-customer-details > h2 {
  font-family: var(--font-head); font-size: 28px; margin: 0 0 var(--sp-3);
  padding-bottom: var(--sp-2); border-bottom: 1px solid var(--sage); color: #000;
}

/* Items table — table-layout:fixed + wrapping so long product names / shipping
   labels ("£2.00 via Shipping Method") never push the table past its card. */
.mf-order-received .woocommerce-table--order-details {
  width: 100%; max-width: 100%; table-layout: fixed; border-collapse: collapse;
}
.mf-order-received .woocommerce-table--order-details th,
.mf-order-received .woocommerce-table--order-details td {
  padding: 11px 6px; text-align: left; border-bottom: 1px solid var(--sage);
  font-size: 15px; color: #000; overflow-wrap: break-word; word-break: break-word;
}
.mf-order-received .woocommerce-table--order-details thead th {
  font-weight: 700; color: var(--teal); text-transform: uppercase;
  font-size: 12px; letter-spacing: .08em;
}
/* Total column ~30% so the product column has room and nothing overflows. */
.mf-order-received .woocommerce-table--order-details td.product-total,
.mf-order-received .woocommerce-table--order-details th.product-total,
.mf-order-received .woocommerce-table--order-details tfoot td {
  text-align: right; width: 32%;
}
.mf-order-received .woocommerce-table--order-details tfoot th { font-weight: 700; text-align: left; }
.mf-order-received .woocommerce-table--order-details tfoot tr:last-child th,
.mf-order-received .woocommerce-table--order-details tfoot tr:last-child td {
  font-size: 19px; color: var(--dark-green); border-bottom: 0;
}
.mf-order-received .woocommerce-table--order-details a { color: var(--teal); font-weight: 700; }
.mf-order-received .woocommerce-table--order-details .wc-item-meta { margin: 4px 0 0; padding: 0; list-style: none; font-size: 13px; color: #5b5249; }

/* Customer / addresses */
.mf-order-received .woocommerce-customer-details .woocommerce-columns--addresses {
  display: grid; grid-template-columns: 1fr 1fr; gap: var(--sp-4); margin: 0;
}
.mf-order-received .woocommerce-customer-details .woocommerce-column { margin: 0; }
.mf-order-received .woocommerce-customer-details h3 { font-size: 15px; font-weight: 700; margin: 0 0 6px; color: #000; }
.mf-order-received .woocommerce-customer-details address { font-style: normal; line-height: 1.55; font-size: 15px; border: 0; padding: 0; color: #000; }
.mf-order-received .woocommerce-customer-details .woocommerce-customer-details--phone,
.mf-order-received .woocommerce-customer-details .woocommerce-customer-details--email { margin-top: 8px; }

@media (max-width: 600px) {
  .mf-order-received .woocommerce-customer-details .woocommerce-columns--addresses { grid-template-columns: 1fr; }
}

/* Mobile Login / My Account icon in the compact header bar (call 2026-08-26:
   login must be prominent on mobile). Desktop keeps the header-right links. */
.mf-mobile-account { display: none; }
@media (max-width: 768px) {
  .mf-mobile-account {
    display: inline-flex !important;
    align-items: center;
    gap: 5px;
    position: absolute;
    right: 56px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--dark-green);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    min-height: 44px;
    z-index: 5;
  }
}

/* Mobile audit 2026-09-02: 44px hamburger (this sheet's earlier 36px
   !important rule loads later than global.css, so the fix lives here). */
@media (max-width: 768px) {
  .mobile-menu-toggle {
    width: 44px !important;
    height: 44px !important;
  }
}
