/* The Gadget Garage - storefront styles v3 (clean rewrite) */
body { font-family: 'Poppins', sans-serif; }

/* ===== HOMEPAGE: every section is a centered 80rem box ===== */
.home .wp-block-post-content > * {
  max-width: 80rem !important;
  margin-left: auto !important;
  margin-right: auto !important;
  box-sizing: border-box;
  padding-left: 1.25rem;
  padding-right: 1.25rem;
}
/* let inner content fill those boxes instead of collapsing to 42rem */
.home .wp-block-post-content .is-layout-constrained > :where(:not(.alignfull):not(.alignwide)) {
  max-width: 100% !important;
  margin-left: auto !important;
  margin-right: auto !important;
}
/* center all text and buttons on the homepage */
.home .wp-block-post-content { text-align: center; }
.home .wp-block-post-content .wp-block-buttons { justify-content: center; }
.home .wp-block-media-text { margin-top: 2rem; margin-bottom: 2rem; }
.home .wp-block-media-text__media img { height: auto; margin: 0 auto; }

/* ===== Labels, titles, price ===== */
.gg2-topbar p { margin: 0; }
.gg2-label { display: inline-block; background: #1D3FD8; color: #fff !important; font-weight: 600; font-size: 1rem; padding: 0.45rem 1.1rem; }
.gg2-section-title { position: relative; padding-bottom: 14px; }
.gg2-section-title::after { content: ''; display: block; width: 230px; max-width: 60%; height: 3px; background: #1D3FD8; margin: 12px auto 0; position: absolute; left: 50%; transform: translateX(-50%); bottom: 0; }
.gg2-price { color: #1D3FD8; font-size: 2rem; font-weight: 500; }

/* ===== Trust row ===== */
.gg2-trust .wp-block-column { text-align: center; padding: 1.5rem 1rem; border-left: 1px solid #ececec; }
.gg2-trust .wp-block-column:first-child { border-left: none; }
.gg2-trust img { width: 56px; height: 56px; margin: 0 auto; }
.gg2-trust h4 { font-size: 1.05rem; margin-top: 0.75rem; }

/* ===== Footer (left-aligned, not affected by homepage centering) ===== */
.gg2-footer { text-align: left; }
.gg2-footer a { color: #cfcfcf !important; text-decoration: none; }
.gg2-footer a:hover { color: #ffffff !important; }
.gg2-footer h4 { color: #ffffff; text-transform: uppercase; letter-spacing: 0.04em; font-size: 1rem; }

/* ===== WooCommerce: grid centered, blue accents ===== */
.woocommerce ul.products { margin-left: auto !important; margin-right: auto !important; }
.woocommerce ul.products li.product { text-align: center; }
.woocommerce ul.products li.product img { margin-left: auto; margin-right: auto; }
.woocommerce ul.products li.product .button { margin-left: auto; margin-right: auto; display: inline-block; }
.woocommerce ul.products li.product .price, .wc-block-grid__product-price, .woocommerce div.product p.price { color: #1D3FD8; font-weight: 600; }
.woocommerce a.button, .woocommerce button.button, .woocommerce button.button.alt, .wc-block-components-button, .wp-block-search__button { background-color: #1D3FD8 !important; color: #fff !important; border-color: #1D3FD8 !important; border-radius: 999px; }
.woocommerce a.button:hover, .woocommerce button.button:hover, .wc-block-components-button:hover { background-color: #152FA8 !important; }
.wp-block-button__link { border-radius: 999px; }

/* ===== Social sidebar ===== */
.gg2-social { position: fixed; right: 0; top: 38%; z-index: 9999; display: flex; flex-direction: column; }
.gg2-social a { width: 44px; height: 44px; display: flex; align-items: center; justify-content: center; color: #fff; }
.gg2-social a .dashicons { font-size: 22px; width: 22px; height: 22px; }
.gg2-social .s-fb { background: #3b5998; } .gg2-social .s-ig { background: #b04a3c; } .gg2-social .s-yt { background: #e02f2f; } .gg2-social .s-pi { background: #d32e2e; } .gg2-social .s-wa { background: #1fc8a0; }

/* ===== Mobile ===== */
@media (max-width: 781px) {
  .gg2-social { display: none; }
  .gg2-trust .wp-block-column { border-left: none; border-top: 1px solid #ececec; padding: 1.25rem 0.5rem; }
  .gg2-trust .wp-block-column:first-child { border-top: none; }
  .gg2-topbar p { font-size: 13px; padding: 0 12px; }
  .gg2-price { font-size: 1.6rem; }
  .gg2-section-title::after { width: 160px; }
  .gg2-label { font-size: 0.9rem; }
  .woocommerce ul.products[class*="columns-"] li.product { width: 48% !important; margin-right: 4% !important; }
  .woocommerce ul.products[class*="columns-"] li.product:nth-child(2n) { margin-right: 0 !important; }
}
@media (max-width: 480px) {
  h1 { font-size: 2.1rem; }
  .gg2-footer .wp-block-columns { gap: 1.25rem; }
}
/* ---- v3.1 vertical rhythm: compact hero + sections ---- */
/* the page's top padding (theme default is oversized) */
.home main.wp-block-group { padding-top: 1rem !important; }

/* hero/banner images: cap height so sections stay compact */
.home .wp-block-media-text__media img { max-height: 500px; width: auto; object-fit: contain; display: block; margin: 0 auto; }

/* tighten spacing between hero text elements (was ~90px gaps) */
.home .wp-block-media-text { margin-top: 0.5rem; margin-bottom: 1.5rem; }
.home .wp-block-media-text__content > * { margin-top: 0 !important; margin-bottom: 0 !important; }
.home .wp-block-media-text__content > * + * { margin-top: 1rem !important; }
.home .wp-block-media-text__content h1 { line-height: 1.15; }

/* consistent breathing room between homepage sections */
.home .wp-block-post-content > * { margin-top: 1.5rem !important; margin-bottom: 1.5rem !important; }
.home .wp-block-post-content > *:first-child { margin-top: 0 !important; }
/* ---- v3.2 style polish: depth, motion, hero accent ---- */
/* product cards: lift on hover */
.woocommerce ul.products li.product { background: #fff; border: 1px solid #ececec; border-radius: 10px; padding: 14px 14px 20px; transition: transform .18s ease, box-shadow .18s ease; }
.woocommerce ul.products li.product:hover { transform: translateY(-5px); box-shadow: 0 12px 28px rgba(29,63,216,.12); border-color: #d9defa; }
.woocommerce ul.products li.product img { border-radius: 6px; transition: transform .25s ease; }
.woocommerce ul.products li.product:hover img { transform: scale(1.04); }

/* buttons: smooth hover + soft shadow */
.wp-block-button__link, .woocommerce a.button, .woocommerce button.button { transition: transform .15s ease, box-shadow .15s ease; }
.wp-block-button__link:hover, .woocommerce a.button:hover { transform: translateY(-2px); box-shadow: 0 8px 18px rgba(29,63,216,.25); }

/* hero: soft blue disc behind the product photo */
.home .wp-block-post-content > .wp-block-media-text:first-child .wp-block-media-text__media { position: relative; }
.home .wp-block-post-content > .wp-block-media-text:first-child .wp-block-media-text__media::before { content: ''; position: absolute; inset: 8% 12%; background: radial-gradient(circle, rgba(29,63,216,.10) 0%, rgba(29,63,216,.04) 55%, transparent 72%); border-radius: 50%; z-index: 0; }
.home .wp-block-media-text__media img { position: relative; z-index: 1; }

/* section labels: slight shadow, feels like a sticker */
.gg2-label { box-shadow: 0 4px 12px rgba(29,63,216,.28); border-radius: 3px; letter-spacing: .01em; }

/* trust icons: hover tint */
.gg2-trust .wp-block-column { transition: background .15s ease; border-radius: 8px; }
.gg2-trust .wp-block-column:hover { background: #F4F6FE; }

/* footer: subtle top accent line in brand blue */
.gg2-footer { border-top: 4px solid #1D3FD8; }

/* topbar: gentle emphasis */
.gg2-topbar { box-shadow: 0 2px 8px rgba(0,0,0,.15); }
/* ---- v3.3 imagery: garden backdrop + logo sizing ---- */
/* 5th homepage section = Tools for Every Gardener; its inner card gets the flat-lay backdrop */
.home .wp-block-post-content > :nth-child(5) > .wp-block-group.has-tertiary-background-color {
  background-image: url('garden-bg.jpg');
  background-size: cover;
  background-position: center;
  position: relative;
}
.home .wp-block-post-content > :nth-child(5) > .wp-block-group.has-tertiary-background-color > * {
  background: rgba(255,255,255,.88);
  max-width: 560px !important;
  margin-left: auto !important;
  margin-right: auto !important;
  padding: 0.5rem 1.5rem;
}
.home .wp-block-post-content > :nth-child(5) > .wp-block-group.has-tertiary-background-color > *:first-child { padding-top: 1.5rem; border-radius: 10px 10px 0 0; }
.home .wp-block-post-content > :nth-child(5) > .wp-block-group.has-tertiary-background-color > *:last-child { padding-bottom: 1.75rem; border-radius: 0 0 10px 10px; }

/* header logo mark: crisp, vertically centered next to the name */
.wp-block-site-logo img { border-radius: 8px; }
header .wp-block-site-title a { text-decoration: none; }
/* ---- v3.4 high-end details ---- */
/* refined typography */
h1, h2, h3 { letter-spacing: -0.015em; }
body { -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }
::selection { background: #1D3FD8; color: #fff; }
html { scroll-behavior: smooth; }

/* single product page: framed gallery, styled meta and tabs */
.woocommerce div.product div.images img { border: 1px solid #ececec; border-radius: 12px; }
.woocommerce div.product .product_title { font-weight: 600; }
.woocommerce div.product .product_meta { border-top: 1px solid #ececec; padding-top: 1rem; margin-top: 1.25rem; font-size: .9rem; color: #4B5563; }
.woocommerce div.product .woocommerce-tabs ul.tabs li.active a { color: #1D3FD8; }
.woocommerce div.product form.cart .quantity .qty { border-radius: 999px; border: 1px solid #d7d7d7; padding: .5rem; }

/* sale badge in brand blue */
.woocommerce span.onsale { background: #1D3FD8; border-radius: 999px; padding: .4em .9em; }

/* cart + checkout: soft cards */
.woocommerce table.shop_table { border: 1px solid #ececec; border-radius: 12px; overflow: hidden; }
.wc-block-components-sidebar .wc-block-components-panel, .cart_totals { background: #F7F8FC; border-radius: 12px; padding: 1rem; }

/* back-to-top button */
#gg-top { position: fixed; right: 18px; bottom: 18px; width: 46px; height: 46px; border-radius: 50%; background: #fff; border: 1px solid #e2e2e2; box-shadow: 0 6px 18px rgba(0,0,0,.12); color: #1D3FD8; font-size: 20px; cursor: pointer; opacity: 0; pointer-events: none; transition: opacity .2s ease, transform .2s ease; z-index: 9998; }
#gg-top.gg-show { opacity: 1; pointer-events: auto; }
#gg-top:hover { transform: translateY(-3px); background: #1D3FD8; color: #fff; }
@media (max-width: 781px) { #gg-top { right: 12px; bottom: 12px; } }
/* ---- v3.5 logo-only header, centered topbar, emoji accents ---- */
/* hide the text next to the logo; scale the mark up to carry the header alone */
header .wp-block-site-title { display: none !important; }
.wp-block-site-logo img { width: 64px !important; height: 64px !important; }

/* shipping bar: force dead-center at every width */
.gg2-topbar { text-align: center; }
.gg2-topbar p { text-align: center !important; margin: 0 auto; }
.gg2-topbar strong::before { content: '\1F69A  '; }

/* light emoji accents on section labels */
.home .wp-block-post-content > :nth-child(2) .gg2-label::before { content: '\2B50 '; }
.home .wp-block-post-content > :nth-child(3) .gg2-label::before { content: '\1F331 '; }
.home .wp-block-post-content > :nth-child(5) .gg2-label::before { content: '\2705 '; }
.home .wp-block-post-content > :nth-child(6) .gg2-label::before { content: '\1F4EC '; }
/* ---- v3.6 FINAL: bulletproof product grid ---- */
.woocommerce ul.products, .woocommerce-page ul.products {
  display: grid !important;
  grid-template-columns: repeat(4, 1fr) !important;
  gap: 22px !important;
  width: 100% !important;
  margin: 0 auto !important;
  float: none !important;
}
.woocommerce ul.products li.product, .woocommerce-page ul.products li.product {
  width: auto !important;
  margin: 0 !important;
  float: none !important;
  display: flex;
  flex-direction: column;
}
/* uniform square image area, whole-card alignment */
.woocommerce ul.products li.product a img {
  aspect-ratio: 1 / 1;
  object-fit: contain;
  width: 100%;
  background: #fff;
}
.woocommerce ul.products li.product .woocommerce-loop-product__title { min-height: 2.6em; font-size: .95rem; }
.woocommerce ul.products li.product .button { margin-top: auto; }

@media (max-width: 1024px) {
  .woocommerce ul.products, .woocommerce-page ul.products { grid-template-columns: repeat(3, 1fr) !important; }
}
@media (max-width: 781px) {
  .woocommerce ul.products, .woocommerce-page ul.products { grid-template-columns: repeat(2, 1fr) !important; gap: 14px !important; }
}
/* ---- v3.7 kill WooCommerce clearfix ghosts inside the grid ---- */
.woocommerce ul.products::before,
.woocommerce ul.products::after,
.woocommerce-page ul.products::before,
.woocommerce-page ul.products::after {
  display: none !important;
  content: none !important;
}
.woocommerce ul.products li.product { box-sizing: border-box !important; }