/**
 * Great Africa — premium storefront UI (green + gold).
 * Implements the approved design. Mobile-first, friendly, fully responsive.
 */

:root {
	--ga-green: #1A4731;
	--ga-green-l: #2D6E4E;
	--ga-green-d: #0F2B1E;
	--ga-gold: #C8922A;
	--ga-gold-l: #E5A93A;
	--ga-gold-d: #9A6E1A;
	--ga-ink: #1F2937;
	--ga-muted: #6B7280;
	--ga-line: #E5E7EB;
	--ga-cream: #FAF8F3;
	--ga-off: #F7F5F0;
	--ga-radius: 14px;
	--ga-radius-sm: 10px;
	--ga-shadow: 0 4px 18px rgba(15,43,30,.08);
	--ga-shadow-lg: 0 16px 40px rgba(15,43,30,.16);
}

body { -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; color: var(--ga-ink); }
img { max-width: 100%; height: auto; }
.wp-block-heading { letter-spacing: -.01em; }

/* ===================== Top promo bar ===================== */
.ga-topbar { padding-block: 8px !important; }
.ga-topbar p { margin: 0; color: var(--ga-gold-l) !important; font-size: 13px; font-weight: 500; letter-spacing: .2px; }

/* ===================== Header ===================== */
.ga-header {
	position: sticky; top: 0; z-index: 300; padding-block: 14px;
	background: rgba(255,255,255,.98); backdrop-filter: saturate(1.2) blur(8px);
	border-bottom: 1px solid transparent; transition: box-shadow .2s ease, padding .2s ease;
}
.ga-header.is-stuck { box-shadow: 0 6px 22px rgba(0,0,0,.07); border-bottom-color: var(--ga-line); padding-block: 9px; }

/* Logo */
.ga-logo { display: inline-flex; align-items: center; gap: 12px; text-decoration: none; }
.ga-logo-mark {
	width: 46px; height: 46px; flex: 0 0 auto; border-radius: 12px;
	background: linear-gradient(135deg, var(--ga-green), var(--ga-green-l));
	color: var(--ga-gold); font-family: "Playfair Display", serif; font-weight: 900; font-size: 26px;
	display: inline-flex; align-items: center; justify-content: center;
	box-shadow: 0 6px 16px rgba(26,71,49,.28);
}
.ga-logo-text { display: flex; flex-direction: column; line-height: 1; }
.ga-logo-name { font-family: "Playfair Display", serif; font-weight: 800; font-size: 1.45rem; color: var(--ga-green); letter-spacing: -.01em; }
.ga-logo-tag { font-size: 10px; font-weight: 700; letter-spacing: 1.8px; text-transform: uppercase; color: var(--ga-gold); margin-top: 3px; }
.ga-header.is-stuck .ga-logo-mark { width: 40px; height: 40px; font-size: 22px; }

/* Nav (custom) */
.ga-nav-custom { display: flex; gap: 30px; align-items: center; font-weight: 600; font-family: var(--wp--preset--font-family--body); font-size: .98rem; }
.ga-nav-custom a { color: var(--ga-ink); text-decoration: none; position: relative; padding-block: 4px; white-space: nowrap; }
.ga-nav-custom a::after { content: ""; position: absolute; left: 0; right: 100%; bottom: -3px; height: 2px; background: var(--ga-gold); transition: right .2s ease; border-radius: 2px; }
.ga-nav-custom a:hover { color: var(--ga-green); }
.ga-nav-custom a:hover::after { right: 0; }
.ga-nav-toggle { display: none !important; }   /* desktop: nav links are visible, no hamburger */

/* Header actions */
.ga-header-actions { gap: 12px; }
.ga-search .wp-block-search__inside-wrapper { border: 1px solid var(--ga-line); border-radius: 999px; background: var(--ga-off); overflow: hidden; }
.ga-search .wp-block-search__input { border: 0; background: transparent; padding: 9px 14px; min-width: 170px; }
.ga-search .wp-block-search__button { background: var(--ga-green); color: #fff; border: 0; margin: 3px; border-radius: 999px; padding: 7px 11px; }
.ga-search .wp-block-search__button:hover { background: var(--ga-green-l); }
.ga-icon-link { display: inline-flex; align-items: center; justify-content: center; width: 42px; height: 42px; border-radius: 50%; color: var(--ga-ink); background: var(--ga-off); transition: background .15s, color .15s, transform .12s; }
.ga-icon-link:hover { background: var(--ga-green); color: #fff; transform: translateY(-1px); }
.wc-block-mini-cart__button { background: var(--ga-off) !important; border-radius: 999px !important; padding: 9px 14px !important; color: var(--ga-ink) !important; font-weight: 700; transition: background .15s, color .15s; }
.wc-block-mini-cart__button:hover { background: var(--ga-green) !important; color: #fff !important; }
.wc-block-mini-cart__badge { background: var(--ga-gold) !important; color: #fff !important; font-weight: 700; }
.ga-btn-login, .ga-btn-supplier { display: inline-flex; align-items: center; text-decoration: none; font-weight: 600; font-size: .9rem; padding: 9px 18px; border-radius: 8px; transition: filter .15s, transform .12s, background .15s; }
.ga-btn-login { background: var(--ga-green); color: #fff; }
.ga-btn-login:hover { background: var(--ga-green-l); color: #fff; transform: translateY(-1px); }
.ga-btn-supplier { background: var(--ga-gold); color: #fff; }
.ga-btn-supplier:hover { background: var(--ga-gold-l); color: #fff; transform: translateY(-1px); }

/* Toggleable header search bar */
.ga-search-bar { display: none; padding-top: 14px; }
.ga-search-bar.is-open { display: block; }
.ga-search-bar .wp-block-search__inside-wrapper { border: 1px solid var(--ga-line); border-radius: 999px; overflow: hidden; max-width: 600px; margin: 0 auto; background: var(--ga-off); }
.ga-search-bar .wp-block-search__input { border: 0; background: transparent; padding: 13px 18px; }
.ga-search-bar .wp-block-search__button { background: var(--ga-green); color: #fff; border: 0; margin: 4px; border-radius: 999px; padding: 9px 14px; }
.ga-search-toggle { cursor: pointer; border: 0; }

/* Mini-cart drawer */
.wc-block-components-drawer__screen-overlay { background: rgba(10,30,20,.5) !important; }
.wc-block-mini-cart__title { font-family: "Playfair Display", serif; }
.wc-block-mini-cart__footer .wc-block-components-button, .wc-block-cart__submit-button { border-radius: 999px !important; }

/* ===================== Supplier-confined header =====================
 * A logged-in supplier (sales-agent) lives only in the dashboard, so strip the
 * storefront chrome from the header and leave a single Contact icon on the right.
 */
.ga-contact-icon { display: none; }
.ga-supplier .ga-nav-custom,
.ga-supplier .ga-nav-toggle,
.ga-supplier .ga-search-toggle,
.ga-supplier .ga-search-bar,
.ga-supplier .ga-icon-link[aria-label="Saved items"],
.ga-supplier .ga-login-icon,
.ga-supplier .ga-minicart,
.ga-supplier .wc-block-mini-cart { display: none !important; }
.ga-supplier .ga-contact-icon { display: inline-flex !important; }

/* Supplier dashboard page: clean branded canvas, no redundant page title. */
body.ga-supplier-dash { background: #eef3ee; }
.ga-supplier-dash .wp-block-post-title { display: none !important; }
/* Dashboards: green canvas, clip horizontal overflow (clip keeps the sticky header
   working), and paint <html> so a dark-mode browser canvas never shows as strips. */
body.ga-supplier-dash, body.woocommerce-account { overflow-x: clip; }
html:has(body.ga-supplier-dash) { background: #eef3ee; }
html:has(body.woocommerce-account) { background: #f4f7f2; }
.ga-supplier-canvas { background: #eef3ee; }
.ga-supplier-canvas, .ga-supplier-canvas > .wp-block-post-content { width: 100% !important; max-width: 100% !important; padding-left: 0 !important; padding-right: 0 !important; margin-left: 0 !important; margin-right: 0 !important; }
@media (max-width: 860px) { body.ga-supplier-dash, body.woocommerce-account { overflow-x: hidden; } }

/* ===================== Buttons ===================== */
.wp-element-button, .wp-block-button__link,
.woocommerce a.button, .woocommerce button.button, .woocommerce input.button, .woocommerce #respond input#submit, .woocommerce .button {
	border-radius: 8px !important; font-weight: 600 !important;
	transition: transform .12s ease, box-shadow .15s ease, background-color .15s ease, filter .15s ease;
}
.wp-block-button__link:hover { transform: translateY(-2px); box-shadow: var(--ga-shadow-lg); }
.woocommerce a.button:hover, .woocommerce button.button:hover, .woocommerce .button:hover, .woocommerce #respond input#submit:hover { filter: brightness(1.06); transform: translateY(-1px); }
.woocommerce .button.alt, .woocommerce #respond input#submit.alt { background: var(--ga-green) !important; color: #fff !important; }
.is-style-outline .wp-block-button__link { box-shadow: none !important; }

/* ===================== Hero ===================== */
.ga-hero { overflow: hidden; background: linear-gradient(135deg, #0F2B1E 0%, #1A4731 55%, #2D6E4E 100%); }
/* Cover overlay defaults to 50% opacity (washed-out sage) — force full strength */
.ga-hero .wp-block-cover__background { opacity: 1 !important; }
.ga-hero .wp-block-cover__background::after {
	content: ""; position: absolute; inset: 0; pointer-events: none;
	background-image: repeating-linear-gradient(105deg, transparent 0, transparent 58px, rgba(229,169,58,.07) 58px, rgba(229,169,58,.07) 60px);
}
.ga-pill {
	display: inline-flex; align-items: center; gap: 8px; margin: 0 0 18px;
	background: rgba(200,146,42,.18); border: 1px solid rgba(200,146,42,.4); color: var(--ga-gold-l);
	border-radius: 999px; padding: 7px 16px; font-size: 13px; font-weight: 600;
}
.ga-hero-title { font-size: clamp(2.2rem, 5.5vw, 3.6rem); line-height: 1.08; margin: 0 0 18px; text-wrap: balance; }
.ga-gold { color: var(--ga-gold); }
.ga-hero-stats { display: flex; flex-wrap: wrap; gap: 36px; margin-top: 42px; }
.ga-stat { display: flex; flex-direction: column; }
.ga-stat-num { font-family: "Playfair Display", serif; font-size: 1.9rem; font-weight: 800; color: var(--ga-gold); line-height: 1; }
.ga-stat-label { font-size: 13px; color: #cdd9d1; margin-top: 4px; }

/* Hero glass cards */
.ga-hero-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.ga-hero-card {
	display: flex; flex-direction: column; align-items: flex-start;
	background: rgba(255,255,255,.08); backdrop-filter: blur(10px);
	border: 1px solid rgba(255,255,255,.14); border-radius: 16px; padding: 22px;
	text-decoration: none; color: inherit; cursor: pointer;
	transition: background .18s ease, border-color .18s ease, box-shadow .18s ease;
}
.ga-hero-card:hover { background: rgba(255,255,255,.14); border-color: rgba(229,169,58,.55); box-shadow: 0 16px 38px rgba(0,0,0,.22); }
.ga-hero-card.ga-hc-offset { transform: translateY(22px); }
.ga-hc-emoji { font-size: 34px; margin-bottom: 10px; }
.ga-hc-img { margin-bottom: 10px; }
.ga-hc-img img { width: 58px; height: 58px; border-radius: 12px; object-fit: cover; display: block; background: rgba(255,255,255,.1); }
.ga-hc-tag { display: inline-block; background: var(--ga-gold); color: #fff; font-size: 10px; font-weight: 700; letter-spacing: .5px; text-transform: uppercase; border-radius: 999px; padding: 2px 9px; }
.ga-hc-title { color: #fff; font-weight: 700; margin-top: 8px; font-size: 15px; }
.ga-hc-price { color: var(--ga-gold-l); font-weight: 800; font-size: 18px; margin-top: 2px; }

/* ===================== Why-choose-us features ===================== */
.ga-feat { text-align: center; }
.ga-feat-ic {
	width: 64px; height: 64px; margin: 0 auto 16px; border-radius: 16px;
	background: rgba(200,146,42,.18); display: flex; align-items: center; justify-content: center; font-size: 30px;
}
.ga-feat-h { color: #fff; font-family: var(--wp--preset--font-family--body); font-weight: 700; font-size: 1.05rem; margin: 0 0 8px; }
.ga-feat-p { color: #b9cabf; font-size: .9rem; line-height: 1.6; margin: 0; }

/* ===================== Section headings ===================== */
main h2.wp-block-heading { font-family: "Playfair Display", serif; }

/* ===================== Category grid (custom cards) ===================== */
.ga-cat-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 18px; }
.ga-cat-card {
	display: flex; flex-direction: column; align-items: center; text-align: center; text-decoration: none;
	background: #fff; border: 1px solid var(--ga-line); border-radius: var(--ga-radius); padding: 26px 14px;
	box-shadow: var(--ga-shadow); transition: transform .16s ease, box-shadow .16s ease, border-color .16s ease;
}
.ga-cat-card:hover { transform: translateY(-5px); box-shadow: var(--ga-shadow-lg); border-color: var(--ga-gold); }
.ga-cat-ic {
	width: 64px; height: 64px; display: flex; align-items: center; justify-content: center; font-size: 32px;
	background: linear-gradient(135deg, rgba(26,71,49,.08), rgba(200,146,42,.12)); border-radius: 18px; margin-bottom: 14px;
}
.ga-cat-name { font-family: var(--wp--preset--font-family--body); font-weight: 700; color: var(--ga-green); font-size: .98rem; line-height: 1.25; }
.ga-cat-sub { color: var(--ga-gold-d); font-size: .78rem; font-weight: 600; margin-top: 6px; }

/* Hide the legacy WooCommerce category block if used elsewhere */
.wc-block-product-categories-list-item { list-style: none; }

/* ===================== Product cards ===================== */
.wc-block-grid__products, ul.products {
	display: grid !important; gap: 22px;
	grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)) !important;
	margin: 0 !important; padding: 0 !important; list-style: none !important; width: 100% !important;
	justify-content: start;
}
ul.products::before, ul.products::after { display: none !important; content: none !important; }
/* Honour the configured column count for WooCommerce product blocks (homepage
   Best Sellers / New Arrivals) so the row fills evenly — no empty trailing slot.
   Desktop-only so the mobile 2-column rule below still wins. */
@media (min-width: 782px) {
	.wc-block-grid.has-2-columns .wc-block-grid__products { grid-template-columns: repeat(2, 1fr) !important; }
	.wc-block-grid.has-3-columns .wc-block-grid__products { grid-template-columns: repeat(3, 1fr) !important; }
	.wc-block-grid.has-4-columns .wc-block-grid__products { grid-template-columns: repeat(4, 1fr) !important; }
	.wc-block-grid.has-5-columns .wc-block-grid__products { grid-template-columns: repeat(5, 1fr) !important; }
	.wc-block-grid.has-6-columns .wc-block-grid__products { grid-template-columns: repeat(6, 1fr) !important; }
}
/* The critical fix: WooCommerce caps each card at max-width:25% — remove that. */
.wc-block-grid__product, ul.products li.product {
	background: #fff; border: 1px solid var(--ga-line); border-radius: var(--ga-radius); padding: 16px !important;
	box-shadow: var(--ga-shadow); text-align: center; transition: transform .16s ease, box-shadow .16s ease;
	margin: 0 !important; width: 100% !important; max-width: none !important; min-width: 0 !important;
	float: none !important; display: flex !important; flex-direction: column; box-sizing: border-box;
}
.wc-block-grid__product:hover, ul.products li.product:hover { transform: translateY(-5px); box-shadow: var(--ga-shadow-lg); }
.wc-block-grid__product-link, .wc-block-grid__product > a { display: block; text-decoration: none; }
.wc-block-grid__product-image, .wc-block-grid__product-image img,
ul.products li.product a img { display: block; width: 100% !important; border-radius: 12px; aspect-ratio: 1/1; object-fit: cover; margin: 0 auto 12px; }
.wc-block-grid__product-title, ul.products li.product .woocommerce-loop-product__title {
	font-weight: 600; font-size: 1rem; color: var(--ga-ink) !important; margin: 0 0 6px; line-height: 1.35; display: block;
}
.wc-block-grid__product-price, ul.products li.product .price { color: var(--ga-green) !important; font-weight: 700; font-size: 1.05rem; display: block; margin-bottom: 10px; }
ul.products li.product .price del, .wc-block-grid__product-price del { color: var(--ga-muted); font-weight: 400; }
ul.products li.product .price ins, .wc-block-grid__product-price ins { text-decoration: none; }
.wc-block-grid__product-add-to-cart { margin-top: auto; }
.wc-block-grid__product .wp-block-button__link, .wc-block-grid__product .button,
ul.products li.product .button, ul.products li.product .added_to_cart {
	margin-top: auto; background: var(--ga-green) !important; color: #fff !important; padding: 10px 16px !important;
	display: inline-block; width: 100%; box-sizing: border-box; white-space: normal; border-radius: 8px !important; font-size: .92rem;
}
.wc-block-grid__product .wp-block-button__link:hover, ul.products li.product .button:hover { background: var(--ga-green-l) !important; }
/* Hide the redundant post-add "View cart" link — the mini-cart drawer opens instead. */
.added_to_cart { display: none !important; }
.onsale {
	background: var(--ga-gold) !important; color: #fff !important; border: 0 !important; border-radius: 999px !important;
	min-height: auto !important; min-width: auto !important; padding: 3px 12px !important; line-height: 1.4 !important;
	font-weight: 700; box-shadow: 0 4px 10px rgba(200,146,42,.3); top: 12px !important; right: 12px !important; left: auto !important;
}

/* ===================== Shop / single ===================== */
.woocommerce .woocommerce-result-count, .woocommerce .woocommerce-ordering { margin-bottom: 1.4rem; color: var(--ga-muted); }
.woocommerce-ordering select, .woocommerce select, .woocommerce form .form-row input.input-text, .woocommerce form .form-row textarea,
.woocommerce-cart .quantity input, .select2-container--default .select2-selection--single {
	border: 1px solid var(--ga-line) !important; border-radius: var(--ga-radius-sm) !important; padding: 10px 12px !important;
}
.woocommerce form .form-row input.input-text:focus, .woocommerce select:focus { outline: none; border-color: var(--ga-green) !important; box-shadow: 0 0 0 3px rgba(26,71,49,.15); }
.single-product div.product .product_title { font-family: "Playfair Display", serif; }
.single-product div.product p.price, .single-product div.product span.price { color: var(--ga-green); font-weight: 700; }
.single-product div.product .woocommerce-product-gallery img { border-radius: var(--ga-radius); }
.single-product .single_add_to_cart_button { padding: 13px 28px !important; }
.woocommerce div.product .woocommerce-tabs ul.tabs li.active { border-bottom-color: var(--ga-green); }

/* ===================== Shop archive (custom template) ===================== */
.ga-shop .woocommerce-products-header,
.ga-shop .woocommerce > h1.page-title { display: none; }   /* green banner replaces the title */
.ga-shop .woocommerce-breadcrumb { color: var(--ga-muted); font-size: .85rem; margin-bottom: 1rem; }
.ga-shop-sidebar { flex-basis: 260px !important; }
.ga-side-card { background: #fff; border: 1px solid var(--ga-line); border-radius: var(--ga-radius); padding: 18px 20px; box-shadow: var(--ga-shadow); margin-bottom: 18px; }
.ga-side-h { font-family: var(--wp--preset--font-family--body); font-size: .95rem; font-weight: 700; color: var(--ga-ink); margin: 0 0 4px; }
.ga-side-card.ga-side-help { background: var(--ga-off); }
.ga-side-card.ga-side-help p { color: var(--ga-muted); font-size: .85rem; margin: 6px 0 10px; }
.ga-side-link { color: var(--ga-green); font-weight: 600; text-decoration: none; font-size: .88rem; }
.ga-side-cats { list-style: none; margin: 6px 0 0; padding: 0; }
.ga-side-cats li { margin: 0; }
.ga-side-cats a { display: block; padding: 9px 10px; border-radius: 8px; color: var(--ga-ink); text-decoration: none; font-size: .92rem; font-weight: 500; transition: background .15s, color .15s; }
.ga-side-cats a:hover { background: var(--ga-off); color: var(--ga-green); }
.ga-side-search { margin: -8px 0 18px; }
.ga-side-search .wp-block-search__inside-wrapper { border: 1px solid var(--ga-line); border-radius: 999px; overflow: hidden; background: #fff; }
.ga-side-search .wp-block-search__input { border: 0; padding: 10px 14px; }
.ga-side-search .wp-block-search__button { background: var(--ga-green); color: #fff; border: 0; margin: 3px; border-radius: 999px; padding: 8px 12px; }
.ga-shop-main .woocommerce-result-count { float: none; margin-bottom: 1rem; }
.ga-shop-main .woocommerce-ordering { margin-bottom: 1.5rem; }
.ga-shop-main nav.woocommerce-pagination { margin-top: 2rem; }
.ga-shop-main nav.woocommerce-pagination ul li a, .ga-shop-main nav.woocommerce-pagination ul li span {
	border-radius: 8px; border: 1px solid var(--ga-line); padding: .4em .9em; color: var(--ga-ink);
}
.ga-shop-main nav.woocommerce-pagination ul li span.current { background: var(--ga-green); color: #fff; border-color: var(--ga-green); }

/* ===================== Cart / checkout ===================== */
.woocommerce-cart table.cart, .woocommerce table.shop_table { border: 1px solid var(--ga-line) !important; border-radius: var(--ga-radius) !important; overflow: hidden; border-collapse: separate !important; border-spacing: 0; }
.woocommerce table.shop_table th { background: var(--ga-off); }
.woocommerce-cart table.cart img { border-radius: var(--ga-radius-sm); width: 64px; }
.cart_totals h2, .woocommerce-checkout h3 { font-family: "Playfair Display", serif; }
.woocommerce .cart-collaterals .cart_totals, .woocommerce-checkout #order_review { background: #fff; border: 1px solid var(--ga-line); border-radius: var(--ga-radius); padding: 18px 20px; box-shadow: var(--ga-shadow); }
.woocommerce .wc-proceed-to-checkout a.checkout-button { font-size: 1.05rem; padding: 14px 24px !important; }

/* ===================== Order confirmation (thank-you) ===================== */
.ga-confirmation [class*="order-confirmation-status"] { font-size: 1.05rem; color: var(--ga-muted); margin: 0 0 1.4rem; }
/* Order summary: flatten the nested boxes into ONE clean grid card */
.ga-confirmation [class*="order-confirmation-summary"] {
	background: #fff !important; border: 1px solid var(--ga-line) !important; border-radius: var(--ga-radius) !important;
	padding: 24px 28px !important; box-shadow: var(--ga-shadow) !important; margin: 0 0 1.4rem !important;
	display: grid !important; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)) !important; gap: 18px 30px !important;
}
/* strip every nested box/shadow/border inside the summary */
.ga-confirmation [class*="order-confirmation-summary"] * {
	background: none !important; box-shadow: none !important; border: 0 !important; padding: 0 !important; margin: 0 !important;
}
/* let the inner list/wrappers collapse so the items become the grid cells */
.ga-confirmation [class*="order-confirmation-summary"] > ul,
.ga-confirmation [class*="order-confirmation-summary"] > div,
.ga-confirmation [class*="order-confirmation-summary-list"] { display: contents !important; }
.ga-confirmation [class*="summary-list-item"] { display: block !important; }
/* label (key) */
.ga-confirmation [class*="summary-list-item"] > :first-child,
.ga-confirmation [class*="summary-list-item__key"] {
	display: block !important; font-size: 11px !important; text-transform: uppercase; letter-spacing: .6px;
	font-weight: 700 !important; color: var(--ga-gold, #C8922A) !important; margin-bottom: 5px !important;
}
/* value */
.ga-confirmation [class*="summary-list-item"] > :last-child,
.ga-confirmation [class*="summary-list-item__value"] {
	display: block !important; font-size: 1.05rem !important; color: var(--ga-ink) !important; font-weight: 600 !important; line-height: 1.35;
}
.ga-confirmation h2 { color: var(--ga-green); }
.ga-confirmation table {
	width: 100%; border: 1px solid var(--ga-line); border-radius: var(--ga-radius);
	border-collapse: separate; border-spacing: 0; overflow: hidden; margin: 0;
}
.ga-confirmation table th, .ga-confirmation table td { padding: 12px 16px; border-bottom: 1px solid var(--ga-line); text-align: left; }
.ga-confirmation table thead th { background: var(--ga-off); }
.ga-confirmation table tfoot th, .ga-confirmation table tfoot td { color: var(--ga-green); font-weight: 700; }
.ga-confirmation [class*="order-confirmation-address"], .ga-confirmation address {
	display: block; background: #fff; border: 1px solid var(--ga-line); border-radius: var(--ga-radius);
	padding: 16px 18px; box-shadow: var(--ga-shadow); font-style: normal;
}
.ga-confirmation [class*="order-confirmation-address"] h2, .ga-confirmation [class*="order-confirmation-address"] h3 { margin-top: 0; font-size: 1rem; color: var(--ga-ink); }

/* Block checkout: hide the order-note + the "checking out as a guest" notice */
.wp-block-woocommerce-checkout-order-note-block { display: none !important; }
.wc-block-checkout__guest-checkout-notice,
.wc-block-checkout__login-prompt,
.wp-block-woocommerce-checkout-contact-information-block .wc-block-components-checkout-step__description { display: none !important; }

/* Thank-you: align the amounts and polish the layout */
.ga-confirmation { padding-top: 2.4rem; }
/* The status + summary blocks render as alignwide (wider than the rest) — pull them
   into the same centred 800px column as the "Order details" section below. */
.ga-confirmation .alignwide { max-width: 800px !important; margin-left: auto !important; margin-right: auto !important; }
.ga-confirmation .wc-block-order-confirmation-totals__table { width: 100%; }
.ga-confirmation .wc-block-order-confirmation-totals__table th:last-child,
.ga-confirmation .wc-block-order-confirmation-totals__table td:last-child { text-align: right; white-space: nowrap; }
.ga-confirmation .wc-block-order-confirmation-totals__product { width: 100%; }
.ga-confirmation .product-quantity { color: var(--ga-muted); font-size: .9em; }
.ga-confirmation .wp-block-columns { gap: 22px !important; align-items: stretch; margin-top: 1.2rem; }
.ga-confirmation .wp-block-column { margin: 0 !important; }
.ga-confirmation [class*="order-confirmation-address"] { height: 100%; line-height: 1.6; }
.ga-confirmation .wc-block-order-confirmation-order-note { background: #fff8ec; border-left: 4px solid var(--ga-gold, #C8922A); border-radius: var(--ga-radius-sm); padding: 14px 16px; margin-top: 1rem; }

/* ===================== My Account ===================== */
.woocommerce-account .woocommerce { display: flex; gap: 28px; flex-wrap: wrap; align-items: flex-start; max-width: 1100px; margin-inline: auto; }
/* Ensure padding stays INSIDE the width so cards never overflow the screen. */
.woocommerce-account .woocommerce, .woocommerce-account .woocommerce * { box-sizing: border-box; }
.woocommerce-account .woocommerce-MyAccount-navigation { flex: 0 0 230px; background: #fff; border: 1px solid var(--ga-line); border-radius: var(--ga-radius); padding: 12px; box-shadow: var(--ga-shadow); }
.woocommerce-account .woocommerce-MyAccount-navigation ul { list-style: none; margin: 0; padding: 0; }
.woocommerce-account .woocommerce-MyAccount-navigation li a { display: block; padding: 11px 14px; border-radius: var(--ga-radius-sm); color: var(--ga-ink); text-decoration: none; font-weight: 600; }
.woocommerce-account .woocommerce-MyAccount-navigation li a:hover { background: var(--ga-off); color: var(--ga-green); }
.woocommerce-account .woocommerce-MyAccount-navigation li.is-active a { background: var(--ga-green); color: #fff; }
.woocommerce-account .woocommerce-MyAccount-content { flex: 1 1 420px; min-width: 0; background: #fff; border: 1px solid var(--ga-line); border-radius: var(--ga-radius); padding: 26px; box-shadow: var(--ga-shadow); }
.woocommerce-account:not(.logged-in) .woocommerce { display: block; max-width: 460px; }
.woocommerce form.login, .woocommerce form.register { border-radius: var(--ga-radius) !important; border-color: var(--ga-line) !important; padding: 24px !important; }

/* Content section headings (keep brand serif but a sensible size, no awkward wrap) */
.woocommerce-MyAccount-content > h2,
.woocommerce-MyAccount-content > h3 { font-size: 1.25rem; margin-top: 0; }
.woocommerce-MyAccount-content > p:first-child { margin-top: 0; color: var(--ga-ink); }

/* Addresses: two-up branded cards showing the current shipping + billing address */
.woocommerce-Addresses.col2-set { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; width: 100%; margin: 18px 0 0; }
/* WooCommerce's clearfix pseudo-elements would otherwise become grid items and
   shove the two cards into a diagonal stagger — remove them in the grid. */
.woocommerce-Addresses.col2-set::before, .woocommerce-Addresses.col2-set::after { content: none !important; display: none !important; }
.woocommerce-Addresses .woocommerce-Address { width: 100% !important; float: none !important; margin: 0 !important; background: #fff; border: 1px solid var(--ga-line); border-top: 3px solid var(--ga-gold, #C8922A); border-radius: var(--ga-radius); padding: 20px 22px; box-shadow: var(--ga-shadow); }
.woocommerce-Address-title.title { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 0 0 14px; padding-bottom: 12px; border-bottom: 1px solid var(--ga-line); }
.woocommerce-Address-title.title h2, .woocommerce-Address-title.title h3 { font-family: "Playfair Display", serif; font-size: 1.15rem !important; margin: 0 !important; line-height: 1.2; color: var(--ga-green); white-space: nowrap; }
.woocommerce-Address-title.title .edit { font-size: .76rem; font-weight: 700; color: var(--ga-green); text-decoration: none; white-space: nowrap; border: 1px solid var(--ga-line); border-radius: 999px; padding: 5px 14px; transition: background .15s, border-color .15s; }
.woocommerce-Address-title.title .edit:hover { background: var(--ga-off); border-color: var(--ga-green); text-decoration: none; }
.woocommerce-Address address { font-style: normal; line-height: 1.7; color: var(--ga-ink); font-size: .98rem; }
/* On phones, stack the address heading + edit button so the long button can't
   push past the card edge (the cause of the residual sideways scroll). */
@media (max-width: 600px) {
	.woocommerce-Address-title.title { flex-direction: column; align-items: flex-start; gap: 9px; }
	.woocommerce-Address-title.title h2, .woocommerce-Address-title.title h3 { white-space: normal !important; }
	.woocommerce-Address-title.title .edit { white-space: normal; }
}

/* Orders table: compact, aligned action buttons instead of huge stacked blocks */
.woocommerce-orders-table { width: 100%; border-collapse: collapse; }
.woocommerce-orders-table th { background: var(--ga-off); text-align: left; padding: 12px 14px; font-size: .78rem; text-transform: uppercase; letter-spacing: .5px; color: var(--ga-green); }
.woocommerce-orders-table td { padding: 13px 14px; border-bottom: 1px solid var(--ga-line); vertical-align: middle; }
.woocommerce-orders-table__cell-order-actions { text-align: right; white-space: nowrap; }
.woocommerce-orders-table__cell-order-actions .button { display: inline-block; width: auto !important; min-width: 0 !important; margin: 3px 0 3px 6px !important; padding: 7px 15px !important; font-size: .82rem !important; line-height: 1.3 !important; }
.woocommerce-orders-table__cell-order-actions .button.view,
.woocommerce-orders-table__cell-order-actions .button.cancel { background: #fff !important; color: var(--ga-green) !important; border: 1px solid var(--ga-line) !important; }
.woocommerce-orders-table__cell-order-actions .button.cancel { color: #b32d2e !important; }
.woocommerce-orders-table__cell-order-actions .button.view:hover { background: var(--ga-off) !important; }

/* Mobile: stack the My Account tables into cards (no horizontal page scroll) */
@media (max-width: 781px) {
	.woocommerce-account .woocommerce { max-width: 100%; margin-inline: auto; }
	.woocommerce-account .woocommerce-MyAccount-content { padding: 18px 16px; max-width: 100%; min-width: 0; }
	.woocommerce-account .woocommerce-MyAccount-content table:not(.shop_table_responsive) { display: block; max-width: 100%; overflow-x: auto; }
	.woocommerce-account .woocommerce-MyAccount-content td, .woocommerce-account .woocommerce-MyAccount-content th { word-break: break-word; }
	.woocommerce-account .shop_table_responsive { border: 0; }
	.woocommerce-account .shop_table_responsive thead { display: none; }
	.woocommerce-account .shop_table_responsive tbody,
	.woocommerce-account .shop_table_responsive tr,
	.woocommerce-account .shop_table_responsive td { display: block; width: auto !important; }
	.woocommerce-account .shop_table_responsive tr { background: #fff; border: 1px solid var(--ga-line); border-radius: var(--ga-radius-sm); margin-bottom: 14px; padding: 4px 2px; box-shadow: var(--ga-shadow); }
	.woocommerce-account .shop_table_responsive td { display: flex !important; justify-content: space-between; align-items: center; gap: 14px; text-align: right; border: 0 !important; border-bottom: 1px solid #eef3ef !important; padding: 11px 14px !important; word-break: break-word; }
	.woocommerce-account .shop_table_responsive tr td:last-child { border-bottom: 0 !important; }
	.woocommerce-account .shop_table_responsive td::before { content: attr(data-title); font-weight: 700; color: var(--ga-green); text-align: left; white-space: nowrap; }
	.woocommerce-account .woocommerce-orders-table__cell-order-actions { display: block !important; text-align: center; }
	.woocommerce-account .woocommerce-orders-table__cell-order-actions::before { display: none; }
	.woocommerce-account .woocommerce-orders-table__cell-order-actions .button { display: block; width: 100%; margin: 5px 0 !important; }
	.woocommerce-account table:not(.shop_table_responsive) { display: block; max-width: 100%; overflow-x: auto; }
}

/* ===================== Notices ===================== */
.woocommerce-message, .woocommerce-info, .woocommerce-error { border-top: 0 !important; border-radius: var(--ga-radius-sm); box-shadow: var(--ga-shadow); }
.woocommerce-message::before { color: var(--ga-green); }

/* ===================== Footer ===================== */
.ga-footer h3, .ga-footer h4 { color: #fff; font-family: "Playfair Display", serif; }
.ga-footer a { color: #b9cabf; text-decoration: none; transition: color .15s; }
.ga-footer a:hover { color: var(--ga-gold-l); text-decoration: underline; }
.ga-footer .wp-block-list { list-style: none; margin: 0; padding: 0; }
.ga-footer .wp-block-list li { margin: 0 0 8px; }

/* ===================== RESPONSIVE =====================
 * Breakpoints: 1100 (laptop) · 960 (tablet → hamburger) · 781 (tablet
 * portrait, where WP core stacks columns) · 600 (large phone) · 460 (phone).
 * Goal: zero horizontal scroll and comfortable tap targets on every device.
 * --------------------------------------------------------------------- */

/* ---- Laptop / small desktop ---- */
@media (max-width: 1100px) {
	.ga-nav-custom { gap: 22px; }
	.ga-search .wp-block-search__input { min-width: 120px; }
	.ga-hero-title { font-size: clamp(2rem, 5vw, 3rem); }
}

/* ---- Tablet & below: collapse the primary nav to a hamburger ---- */
@media (max-width: 960px) {
	.ga-nav-toggle { display: inline-flex !important; }
	.ga-nav-custom {
		display: none; position: absolute; top: 100%; left: 0; right: 0; z-index: 250;
		background: #fff; flex-direction: column; gap: 0; padding: 6px 20px 16px;
		box-shadow: 0 12px 26px rgba(0,0,0,.12); border-top: 1px solid var(--ga-line);
	}
	.ga-nav-custom.is-open { display: flex; }
	.ga-nav-custom a { padding: 14px 2px; border-bottom: 1px solid var(--ga-off); width: 100%; }
	.ga-nav-custom a::after { display: none; }
	.ga-header-actions { gap: 8px; }
}

/* ---- Footer: 2-up on tablet / large phone ---- */
@media (max-width: 900px) {
	.ga-footer .wp-block-columns { display: grid !important; grid-template-columns: 1fr 1fr; gap: 2rem 1.5rem; }
	.ga-footer .wp-block-column { flex-basis: auto !important; width: auto !important; }
}

/* ---- Tablet portrait (WP core stacks .wp-block-columns here) ---- */
@media (max-width: 781px) {
	.ga-logo-tag { display: none; }
	.ga-logo-mark { width: 40px; height: 40px; font-size: 22px; }
	.ga-logo-name { font-size: 1.2rem; }

	/* Hero: tighten and stack (columns stacked by core) */
	.ga-hero { min-height: auto !important; }
	.ga-hero-stats { gap: 22px; margin-top: 26px; }
	.ga-hero-cards { margin-top: 24px; }
	.ga-hero-card.ga-hc-offset { transform: none; }
	.ga-hero-card { align-items: center; text-align: center; }
	.ga-hc-img img { margin-left: auto; margin-right: auto; }
	/* Full-width hero CTAs for easy tapping */
	.ga-hero .wp-block-buttons { width: 100%; }
	.ga-hero .wp-block-buttons .wp-block-button { flex: 1 1 100%; }
	.ga-hero .wp-block-buttons .wp-block-button__link { display: block; text-align: center; }

	/* Product + category grids */
	.wc-block-grid__products, ul.products { grid-template-columns: repeat(2, 1fr) !important; gap: 14px; }
	.ga-cat-grid { grid-template-columns: repeat(3, 1fr); gap: 14px; }

	/* "Why Great Africa" features → 2×2 */
	.ga-value .wp-block-columns { display: grid !important; grid-template-columns: 1fr 1fr; gap: 1.8rem 1.4rem; }
	.ga-value .wp-block-column { flex-basis: auto !important; width: auto !important; padding: 0 !important; margin: 0 !important; }

	/* Trim the tall cover/section padding */
	.wp-block-cover { padding-top: 3rem !important; padding-bottom: 3rem !important; }

	/* Shop / search: compact sidebar (search + category pills) ABOVE products */
	.ga-shop .wp-block-columns { display: flex; flex-direction: column; }
	.ga-shop-sidebar { flex-basis: auto !important; width: 100% !important; }
	.ga-shop-sidebar .ga-side-card { padding: 14px 16px; margin-bottom: 12px; }
	.ga-shop-sidebar .ga-side-cats { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 4px; }
	.ga-shop-sidebar .ga-side-cats li { margin: 0; }
	.ga-shop-sidebar .ga-side-cats a { white-space: nowrap; border: 1px solid var(--ga-line); border-radius: 999px; padding: 7px 14px; background: #fff; font-size: .88rem; }
	.ga-shop-sidebar .ga-side-cats a:hover { background: var(--ga-off); color: var(--ga-green); }
	.ga-shop-sidebar .ga-side-help { display: none; }

	/* My account stacks */
	.woocommerce-account .woocommerce { flex-direction: column; align-items: stretch; }
	.woocommerce-account .woocommerce-MyAccount-navigation { flex-basis: auto; width: 100%; }
	.woocommerce-account .woocommerce-MyAccount-content { flex-basis: auto; width: 100%; }
	.woocommerce-Addresses.col2-set { grid-template-columns: 1fr; gap: 16px; }
	/* Orders: let action buttons sit left and wrap comfortably for tapping */
	.woocommerce-orders-table__cell-order-actions { text-align: left; white-space: normal; }
	.woocommerce-orders-table__cell-order-actions .button { margin: 3px 6px 3px 0 !important; }
}

/* ---- WooCommerce safety: stack classic two-column layouts ---- */
@media (max-width: 768px) {
	.woocommerce .col2-set .col-1, .woocommerce .col2-set .col-2,
	.woocommerce-page .col2-set .col-1, .woocommerce-page .col2-set .col-2 { float: none; width: 100%; }
	.woocommerce div.product .woocommerce-product-gallery,
	.woocommerce div.product .summary { float: none !important; width: 100% !important; margin-bottom: 1.6rem; }
	.woocommerce .cart-collaterals .cart_totals { float: none; width: 100% !important; }
	.woocommerce-cart table.cart img { width: 52px; }
}

/* ---- Large phone ---- */
@media (max-width: 600px) {
	.ga-topbar p { font-size: 12px; }
	.ga-stat-num { font-size: 1.55rem; }
	.ga-hero-stats { gap: 16px; }
	.ga-stat { flex: 1 1 40%; }
	.ga-cat-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
	.wc-block-grid__product-title, ul.products li.product .woocommerce-loop-product__title { font-size: .92rem; }

	/* Compact the mini-cart button (icon + badge only) */
	.wc-block-mini-cart__button { padding: 8px 10px !important; }
	.wc-block-mini-cart__amount { display: none; }

	/* Footer bottom bar: centre & stack */
	.ga-footer > .wp-block-group { justify-content: center; text-align: center; gap: 4px; }

	/* Compact order tables */
	.ga-confirmation table th, .ga-confirmation table td { padding: 9px 10px; font-size: .9rem; }

	/* Full-width add to cart on single product */
	.single-product form.cart .single_add_to_cart_button { width: 100%; }
}

/* ---- Phone ---- */
@media (max-width: 460px) {
	.ga-header-actions { gap: 6px; }
	.ga-icon-link { width: 38px; height: 38px; }
	.ga-logo-name { font-size: 1.05rem; }
	/* Heart + login both point to My Account — drop the redundant heart to save room */
	a.ga-icon-link[aria-label="Saved items"] { display: none; }

	.ga-hero-cards { grid-template-columns: 1fr; }
	.ga-hero-card.ga-hc-offset { transform: none; }
	.ga-value .wp-block-columns { grid-template-columns: 1fr; }
	.ga-footer .wp-block-columns { grid-template-columns: 1fr; }
}

/* ---- Very small phone ---- */
@media (max-width: 360px) {
	.ga-cat-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
	.wc-block-grid__products, ul.products { gap: 10px; }
	.wc-block-grid__product, ul.products li.product { padding: 12px !important; }
}
