/*
 * WR Gadget Storefront Polish v1.5.0
 * Industrial Electrical Professional presentation layer.
 * Scoped under body.wrg-storefront-polish. No WooCommerce templates are overridden.
 */

body.wrg-storefront-polish {
  --wrg-navy-950: #091522;
  --wrg-navy-900: #0e2235;
  --wrg-navy-800: #15324b;
  --wrg-steel-700: #34475a;
  --wrg-steel-600: #526577;
  --wrg-steel-500: #718292;
  --wrg-line: #d9e0e6;
  --wrg-line-strong: #bdc8d2;
  --wrg-panel: #f4f7f9;
  --wrg-panel-2: #edf2f5;
  --wrg-white: #ffffff;
  --wrg-electric: #f4b400;
  --wrg-electric-dark: #d99b00;
  --wrg-success: #1c7c54;
  --wrg-danger: #b42318;
  --wrg-radius: 8px;
  --wrg-radius-sm: 5px;
  --wrg-control-height: 46px;
  --wrg-shadow: 0 8px 24px rgba(9, 21, 34, .07);
  --wrg-shadow-hover: 0 14px 34px rgba(9, 21, 34, .13);
  color: var(--wrg-navy-950);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body.wrg-storefront-polish .woocommerce,
body.wrg-storefront-polish .wc-block-grid,
body.wrg-storefront-polish .wp-block-woocommerce-product-collection {
  --wrg-control-height: 46px;
}

/* Quiet industrial background treatment inside commerce surfaces. */
body.wrg-storefront-polish.woocommerce-shop main,
body.wrg-storefront-polish.tax-product_cat main,
body.wrg-storefront-polish.tax-product_tag main,
body.wrg-storefront-polish.single-product main,
body.wrg-storefront-polish.woocommerce-cart main,
body.wrg-storefront-polish.woocommerce-checkout main {
  position: relative;
}

/* Header / footer: deliberately conservative selectors to avoid theme restructuring. */
body.wrg-storefront-polish :where(header.site-header, .site-header, header.wp-block-template-part) {
  border-bottom: 1px solid var(--wrg-line);
  box-shadow: 0 2px 12px rgba(9, 21, 34, .035);
}
body.wrg-storefront-polish :where(footer.site-footer, .site-footer, footer.wp-block-template-part) {
  border-top: 1px solid var(--wrg-line);
}

/* Accessibility */
body.wrg-storefront-polish :where(a, button, input, select, textarea):focus-visible {
  outline: 3px solid rgba(244, 180, 0, .35);
  outline-offset: 2px;
}

/* Electrical trust strip injected through a normal WooCommerce hook. */
body.wrg-storefront-polish .wrg-electrical-trust-strip {
  width: 100%;
  clear: both;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0;
  margin: 0 0 22px;
  border: 1px solid var(--wrg-line-strong);
  border-left: 4px solid var(--wrg-electric);
  border-radius: var(--wrg-radius-sm);
  background: linear-gradient(90deg, #fff 0%, #f7f9fb 100%);
  color: var(--wrg-steel-700);
  font-size: 12px;
  font-weight: 650;
  line-height: 1.3;
  overflow: hidden;
}
body.wrg-storefront-polish .wrg-electrical-trust-strip > span {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 14px;
  border-right: 1px solid var(--wrg-line);
  white-space: nowrap;
}
body.wrg-storefront-polish .wrg-electrical-trust-strip > span:not(:first-child)::before {
  content: "✓";
  display: inline-grid;
  place-items: center;
  width: 17px;
  height: 17px;
  margin-right: 7px;
  border: 1px solid #9eb3a8;
  border-radius: 50%;
  color: var(--wrg-success);
  font-size: 10px;
  font-weight: 900;
}
body.wrg-storefront-polish .wrg-electrical-trust-strip__brand {
  background: var(--wrg-navy-950);
  color: #fff;
  letter-spacing: .055em;
  text-transform: uppercase;
}
body.wrg-storefront-polish .wrg-electrical-trust-strip__brand b {
  margin-left: 6px;
  color: var(--wrg-electric);
  font-weight: 800;
}

/* Breadcrumbs */
body.wrg-storefront-polish :where(.woocommerce-breadcrumb, .wc-block-breadcrumbs) {
  color: var(--wrg-steel-500);
  font-size: 12px;
  font-weight: 600;
  line-height: 1.6;
  letter-spacing: .01em;
  margin-bottom: 18px;
}
body.wrg-storefront-polish .woocommerce-breadcrumb a {
  color: var(--wrg-steel-700);
  text-decoration: none;
}
body.wrg-storefront-polish .woocommerce-breadcrumb a:hover { color: var(--wrg-navy-900); }

/* Archive heading = technical catalogue rather than lifestyle marketplace. */
body.wrg-storefront-polish :where(.woocommerce-products-header, .woocommerce-products-header__title, .woocommerce-loop-category__title) {
  color: var(--wrg-navy-950);
}
body.wrg-storefront-polish .woocommerce-products-header {
  position: relative;
  margin-bottom: 20px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--wrg-line);
}
body.wrg-storefront-polish .woocommerce-products-header::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -1px;
  width: 74px;
  height: 3px;
  background: var(--wrg-electric);
}
body.wrg-storefront-polish .woocommerce-products-header__title.page-title,
body.wrg-storefront-polish .woocommerce-products-header h1 {
  font-size: clamp(25px, 3vw, 38px);
  font-weight: 800;
  line-height: 1.17;
  letter-spacing: -.02em;
  margin-bottom: 8px;
}
body.wrg-storefront-polish .term-description {
  color: var(--wrg-steel-600);
  line-height: 1.75;
  max-width: 940px;
  margin-bottom: 24px;
}
body.wrg-storefront-polish .term-description p:last-child { margin-bottom: 0; }

/* Toolbar */
body.wrg-storefront-polish :where(.woocommerce-result-count, .woocommerce-ordering) { margin-bottom: 20px; }
body.wrg-storefront-polish .woocommerce-result-count {
  color: var(--wrg-steel-600);
  font-size: 13px;
  font-weight: 600;
}
body.wrg-storefront-polish .woocommerce-ordering select,
body.wrg-storefront-polish :where(.woocommerce select, .wc-block-components-select__select) {
  min-height: var(--wrg-control-height);
  border: 1px solid var(--wrg-line-strong);
  border-radius: var(--wrg-radius-sm);
  background: #fff;
  color: var(--wrg-navy-950);
  padding: 0 38px 0 12px;
  font-weight: 600;
}

/* Product catalogue grid */
body.wrg-storefront-polish .woocommerce ul.products,
body.wrg-storefront-polish .woocommerce-page ul.products {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin: 0 0 34px;
}
body.wrg-storefront-polish .woocommerce ul.products::before,
body.wrg-storefront-polish .woocommerce ul.products::after { display: none; }
body.wrg-storefront-polish .woocommerce ul.products li.product,
body.wrg-storefront-polish .woocommerce-page ul.products li.product {
  float: none;
  width: auto;
  margin: 0;
  min-width: 0;
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 10px 10px 13px;
  border: 1px solid var(--wrg-line);
  border-radius: var(--wrg-radius);
  background: #fff;
  box-shadow: 0 2px 7px rgba(9, 21, 34, .035);
  overflow: hidden;
  transition: border-color .16s ease, box-shadow .16s ease, transform .16s ease;
}
body.wrg-storefront-polish .woocommerce ul.products li.product::before,
body.wrg-storefront-polish .woocommerce-page ul.products li.product::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--wrg-electric) 0 42px, var(--wrg-navy-900) 42px 100%);
  opacity: .95;
  z-index: 2;
}
body.wrg-storefront-polish .woocommerce ul.products li.product:hover {
  border-color: #aebcc8;
  box-shadow: var(--wrg-shadow-hover);
  transform: translateY(-2px);
}
body.wrg-storefront-polish .woocommerce ul.products li.product a.woocommerce-LoopProduct-link {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  color: inherit;
  text-decoration: none;
}
body.wrg-storefront-polish .woocommerce ul.products li.product a img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: contain;
  padding: 9px;
  margin: 0 0 9px;
  border: 1px solid #edf1f4;
  border-radius: 5px;
  background: #fff;
}
body.wrg-storefront-polish .woocommerce ul.products li.product .woocommerce-loop-product__title {
  font-size: 14px;
  font-weight: 700;
  line-height: 1.5;
  color: var(--wrg-navy-950);
  padding: 0;
  margin: 2px 0 8px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 4.5em;
}
body.wrg-storefront-polish .woocommerce ul.products li.product .price {
  color: var(--wrg-navy-950);
  font-size: 18px;
  font-weight: 850;
  line-height: 1.3;
  margin: auto 0 10px;
  padding-top: 9px;
  border-top: 1px solid #edf1f4;
}
body.wrg-storefront-polish .woocommerce ul.products li.product .price del {
  color: #8a98a5;
  font-size: .76em;
  font-weight: 550;
  opacity: 1;
}
body.wrg-storefront-polish .woocommerce ul.products li.product .price ins {
  color: var(--wrg-danger);
  text-decoration: none;
  font-weight: 850;
}
body.wrg-storefront-polish .woocommerce ul.products li.product .star-rating {
  color: var(--wrg-electric-dark);
  font-size: 12px;
  margin: 0 0 8px;
}
body.wrg-storefront-polish .woocommerce span.onsale {
  min-width: auto;
  min-height: auto;
  line-height: 1;
  padding: 7px 9px;
  margin: 10px 10px 0 0;
  border-radius: 4px;
  background: var(--wrg-danger);
  color: #fff;
  font-size: 10px;
  font-weight: 850;
  letter-spacing: .04em;
  text-transform: uppercase;
}

/* Category cards */
body.wrg-storefront-polish .woocommerce ul.products li.product-category .woocommerce-loop-category__title {
  font-size: 14px;
  font-weight: 750;
  line-height: 1.45;
  margin: 3px 0 0;
  padding: 0;
}
body.wrg-storefront-polish .woocommerce ul.products li.product-category mark.count {
  display: inline-block;
  margin-left: 3px;
  padding: 2px 6px;
  border-radius: 3px;
  background: var(--wrg-panel-2);
  color: var(--wrg-steel-600);
  font-size: 11px;
  font-weight: 700;
}

/* Buttons: industrial dark primary, electric-yellow action state. */
body.wrg-storefront-polish :where(
  .woocommerce a.button,
  .woocommerce button.button,
  .woocommerce input.button,
  .woocommerce #respond input#submit,
  .wc-block-components-button,
  .woocommerce .wp-element-button,
  .wp-block-woocommerce-product-collection .wp-element-button
) {
  min-height: var(--wrg-control-height);
  border-radius: var(--wrg-radius-sm);
  border: 1px solid var(--wrg-navy-950);
  background: var(--wrg-navy-950);
  color: #fff;
  font-weight: 750;
  line-height: 1.2;
  text-decoration: none;
  box-shadow: none;
  transition: background-color .15s ease, border-color .15s ease, color .15s ease, transform .15s ease, box-shadow .15s ease;
}
body.wrg-storefront-polish :where(
  .woocommerce a.button,
  .woocommerce button.button,
  .woocommerce input.button,
  .woocommerce #respond input#submit,
  .wc-block-components-button,
  .woocommerce .wp-element-button,
  .wp-block-woocommerce-product-collection .wp-element-button
):hover {
  background: var(--wrg-electric);
  border-color: var(--wrg-electric);
  color: var(--wrg-navy-950);
  box-shadow: 0 7px 18px rgba(9, 21, 34, .12);
}
body.wrg-storefront-polish .woocommerce ul.products li.product .button {
  width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: 2px;
  padding: 0 11px;
  font-size: 13px;
}
body.wrg-storefront-polish .woocommerce a.added_to_cart {
  display: block;
  margin-top: 8px;
  color: var(--wrg-navy-800);
  text-align: center;
  font-size: 12px;
  font-weight: 750;
}

/* Notices */
body.wrg-storefront-polish :where(.woocommerce-message, .woocommerce-info, .woocommerce-error) {
  border: 1px solid var(--wrg-line);
  border-top-width: 1px;
  border-radius: var(--wrg-radius-sm);
  background: var(--wrg-panel);
  color: var(--wrg-steel-700);
  box-shadow: none;
  padding-top: 14px;
  padding-bottom: 14px;
}
body.wrg-storefront-polish .woocommerce-message { border-left: 4px solid var(--wrg-success); }
body.wrg-storefront-polish .woocommerce-info { border-left: 4px solid var(--wrg-navy-800); }
body.wrg-storefront-polish .woocommerce-error { border-left: 4px solid var(--wrg-danger); }
body.wrg-storefront-polish :where(.woocommerce-message, .woocommerce-info, .woocommerce-error)::before { display: none; }

/* Single product */
body.wrg-storefront-polish.single-product .product.type-product { margin-top: 8px; }
body.wrg-storefront-polish.single-product div.product div.images,
body.wrg-storefront-polish.single-product div.product div.summary { margin-bottom: 38px; }
body.wrg-storefront-polish.single-product div.product div.images .woocommerce-product-gallery__wrapper {
  position: relative;
  border: 1px solid var(--wrg-line-strong);
  border-radius: var(--wrg-radius);
  background: #fff;
  overflow: hidden;
  box-shadow: 0 5px 18px rgba(9, 21, 34, .05);
}
body.wrg-storefront-polish.single-product div.product div.images .woocommerce-product-gallery__wrapper::before {
  content: "";
  position: absolute;
  z-index: 2;
  left: 0;
  top: 0;
  width: 74px;
  height: 4px;
  background: var(--wrg-electric);
  pointer-events: none;
}
body.wrg-storefront-polish.single-product div.product div.images img { background: #fff; }
body.wrg-storefront-polish.single-product div.product .summary { color: var(--wrg-navy-950); }
body.wrg-storefront-polish .wrg-electrical-product-kicker {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 8px;
  color: var(--wrg-steel-600);
  font-size: 10px;
  font-weight: 850;
  letter-spacing: .11em;
  text-transform: uppercase;
}
body.wrg-storefront-polish .wrg-electrical-product-kicker > span {
  width: 26px;
  height: 3px;
  background: var(--wrg-electric);
}
body.wrg-storefront-polish.single-product div.product .product_title {
  font-size: clamp(24px, 2.7vw, 35px);
  font-weight: 800;
  line-height: 1.25;
  letter-spacing: -.025em;
  margin: 0 0 11px;
}
body.wrg-storefront-polish.single-product div.product p.price,
body.wrg-storefront-polish.single-product div.product span.price {
  color: var(--wrg-navy-950);
  font-size: clamp(25px, 2.5vw, 33px);
  font-weight: 850;
  line-height: 1.25;
  margin-bottom: 15px;
}
body.wrg-storefront-polish.single-product div.product .price del {
  color: #8a98a5;
  font-size: .7em;
  font-weight: 550;
  opacity: 1;
}
body.wrg-storefront-polish.single-product div.product .price ins {
  color: var(--wrg-danger);
  text-decoration: none;
}
body.wrg-storefront-polish.single-product .woocommerce-product-details__short-description {
  color: var(--wrg-steel-600);
  line-height: 1.75;
  margin-bottom: 18px;
}
body.wrg-storefront-polish.single-product .stock.in-stock {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 9px;
  border: 1px solid #bad8c9;
  border-radius: 4px;
  background: #f4fbf7;
  color: var(--wrg-success);
  font-size: 12px;
  font-weight: 750;
}
body.wrg-storefront-polish.single-product .stock.in-stock::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--wrg-success);
}
body.wrg-storefront-polish.single-product form.cart {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  align-items: stretch;
  margin: 18px 0;
  padding: 14px;
  border: 1px solid var(--wrg-line);
  border-radius: var(--wrg-radius);
  background: var(--wrg-panel);
}
body.wrg-storefront-polish .woocommerce .quantity .qty {
  min-height: var(--wrg-control-height);
  width: 74px;
  border: 1px solid var(--wrg-line-strong);
  border-radius: var(--wrg-radius-sm);
  color: var(--wrg-navy-950);
  background: #fff;
  padding: 0 8px;
  font-weight: 700;
}
body.wrg-storefront-polish.single-product .single_add_to_cart_button {
  min-height: 48px;
  padding: 0 22px;
  background: var(--wrg-electric);
  border-color: var(--wrg-electric);
  color: var(--wrg-navy-950);
  font-weight: 850;
}
body.wrg-storefront-polish.single-product .single_add_to_cart_button:hover {
  background: var(--wrg-navy-950);
  border-color: var(--wrg-navy-950);
  color: #fff;
}
body.wrg-storefront-polish.single-product .product_meta {
  margin-top: 17px;
  padding: 13px 14px;
  border: 1px solid var(--wrg-line);
  border-radius: var(--wrg-radius-sm);
  background: #fff;
  color: var(--wrg-steel-600);
  font-size: 12px;
  line-height: 1.85;
}
body.wrg-storefront-polish.single-product .product_meta :where(.sku_wrapper, .posted_in, .tagged_as) {
  display: block;
}
body.wrg-storefront-polish.single-product .product_meta .sku {
  color: var(--wrg-navy-950);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-weight: 800;
  letter-spacing: .02em;
}
body.wrg-storefront-polish.single-product .product_meta a {
  color: var(--wrg-navy-800);
  text-decoration: none;
  font-weight: 650;
}

/* Variations = spec selector */
body.wrg-storefront-polish .woocommerce div.product form.cart .variations {
  width: 100%;
  margin: 2px 0 12px;
}
body.wrg-storefront-polish .woocommerce div.product form.cart .variations th,
body.wrg-storefront-polish .woocommerce div.product form.cart .variations td {
  padding: 6px 0;
  vertical-align: middle;
}
body.wrg-storefront-polish .woocommerce div.product form.cart .variations label {
  color: var(--wrg-navy-950);
  font-size: 13px;
  font-weight: 800;
}
body.wrg-storefront-polish .woocommerce div.product form.cart .variations select {
  width: 100%;
  min-height: var(--wrg-control-height);
  border: 1px solid var(--wrg-line-strong);
  border-radius: var(--wrg-radius-sm);
  background: #fff;
  padding: 0 12px;
  font-weight: 650;
}

/* Product data tabs */
body.wrg-storefront-polish .woocommerce div.product .woocommerce-tabs { margin-top: 14px; }
body.wrg-storefront-polish .woocommerce div.product .woocommerce-tabs ul.tabs {
  display: flex;
  gap: 4px;
  padding: 5px;
  margin: 0 0 18px;
  border: 1px solid var(--wrg-line);
  border-radius: var(--wrg-radius-sm);
  background: var(--wrg-panel);
}
body.wrg-storefront-polish .woocommerce div.product .woocommerce-tabs ul.tabs::before { display: none; }
body.wrg-storefront-polish .woocommerce div.product .woocommerce-tabs ul.tabs li {
  border: 0;
  border-radius: 4px;
  background: transparent;
  margin: 0;
  padding: 0;
}
body.wrg-storefront-polish .woocommerce div.product .woocommerce-tabs ul.tabs li::before,
body.wrg-storefront-polish .woocommerce div.product .woocommerce-tabs ul.tabs li::after { display: none; }
body.wrg-storefront-polish .woocommerce div.product .woocommerce-tabs ul.tabs li a {
  padding: 10px 13px;
  color: var(--wrg-steel-600);
  font-size: 13px;
  font-weight: 750;
  border: 0;
}
body.wrg-storefront-polish .woocommerce div.product .woocommerce-tabs ul.tabs li.active a {
  border-radius: 3px;
  background: var(--wrg-navy-950);
  color: #fff;
}
body.wrg-storefront-polish .woocommerce div.product .woocommerce-tabs .panel {
  color: var(--wrg-steel-700);
  line-height: 1.75;
}
body.wrg-storefront-polish #reviews #comments ol.commentlist li .comment-text {
  border-color: var(--wrg-line);
  border-radius: var(--wrg-radius-sm);
}

/* Technical spec tables inside descriptions. */
body.wrg-storefront-polish .woocommerce-Tabs-panel table,
body.wrg-storefront-polish .woocommerce-product-details__short-description table {
  width: 100%;
  border-collapse: collapse;
  border: 1px solid var(--wrg-line);
  font-size: 13px;
}
body.wrg-storefront-polish .woocommerce-Tabs-panel table th,
body.wrg-storefront-polish .woocommerce-Tabs-panel table td,
body.wrg-storefront-polish .woocommerce-product-details__short-description table th,
body.wrg-storefront-polish .woocommerce-product-details__short-description table td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--wrg-line);
  text-align: left;
}
body.wrg-storefront-polish .woocommerce-Tabs-panel table th,
body.wrg-storefront-polish .woocommerce-product-details__short-description table th {
  width: 32%;
  background: var(--wrg-panel);
  color: var(--wrg-navy-950);
  font-weight: 800;
}

/* Forms */
body.wrg-storefront-polish .woocommerce :where(input.input-text, textarea, select),
body.wrg-storefront-polish :where(.wc-block-components-text-input input, .wc-block-components-address-form input) {
  border: 1px solid var(--wrg-line-strong);
  border-radius: var(--wrg-radius-sm);
  background: #fff;
  color: var(--wrg-navy-950);
  box-shadow: none;
}
body.wrg-storefront-polish .woocommerce input.input-text,
body.wrg-storefront-polish .woocommerce select {
  min-height: var(--wrg-control-height);
  padding: 9px 12px;
}
body.wrg-storefront-polish .woocommerce textarea {
  min-height: 110px;
  padding: 10px 12px;
}
body.wrg-storefront-polish .woocommerce form .form-row label {
  color: var(--wrg-steel-700);
  font-weight: 750;
  font-size: 13px;
}
body.wrg-storefront-polish .select2-container--default .select2-selection--single {
  min-height: var(--wrg-control-height);
  border: 1px solid var(--wrg-line-strong);
  border-radius: var(--wrg-radius-sm);
}
body.wrg-storefront-polish .select2-container--default .select2-selection--single .select2-selection__rendered {
  line-height: calc(var(--wrg-control-height) - 2px);
  padding-left: 12px;
}
body.wrg-storefront-polish .select2-container--default .select2-selection--single .select2-selection__arrow {
  height: calc(var(--wrg-control-height) - 2px);
}

/* Cart / Checkout: clean B2B order-document styling. */
body.wrg-storefront-polish.woocommerce-cart .woocommerce-cart-form,
body.wrg-storefront-polish.woocommerce-cart .cart-collaterals .cart_totals,
body.wrg-storefront-polish.woocommerce-checkout #order_review,
body.wrg-storefront-polish.woocommerce-checkout .woocommerce-checkout-review-order {
  border: 1px solid var(--wrg-line-strong);
  border-radius: var(--wrg-radius);
  background: #fff;
  box-shadow: var(--wrg-shadow);
}
body.wrg-storefront-polish.woocommerce-cart .woocommerce-cart-form { padding: 8px 16px 16px; }
body.wrg-storefront-polish.woocommerce-cart table.shop_table,
body.wrg-storefront-polish.woocommerce-checkout table.shop_table {
  border: 0;
  border-collapse: collapse;
  border-radius: 0;
}
body.wrg-storefront-polish .woocommerce table.shop_table th {
  color: var(--wrg-navy-950);
  background: var(--wrg-panel);
  font-size: 12px;
  font-weight: 850;
  letter-spacing: .025em;
}
body.wrg-storefront-polish .woocommerce table.shop_table td,
body.wrg-storefront-polish .woocommerce table.shop_table th {
  border-color: var(--wrg-line);
  padding: 13px 10px;
}
body.wrg-storefront-polish.woocommerce-cart .cart-collaterals .cart_totals { padding: 17px; }
body.wrg-storefront-polish.woocommerce-cart .cart-collaterals .cart_totals h2,
body.wrg-storefront-polish.woocommerce-checkout #order_review_heading {
  color: var(--wrg-navy-950);
  font-size: 20px;
  font-weight: 800;
  padding-bottom: 9px;
  margin-bottom: 13px;
  border-bottom: 3px solid var(--wrg-electric);
}
body.wrg-storefront-polish .woocommerce-cart-form .coupon {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
body.wrg-storefront-polish .woocommerce-cart-form .coupon .input-text { min-width: 180px; }
body.wrg-storefront-polish .wc-proceed-to-checkout a.checkout-button,
body.wrg-storefront-polish.woocommerce-checkout #place_order {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 52px;
  border-color: var(--wrg-electric);
  background: var(--wrg-electric);
  color: var(--wrg-navy-950);
  font-size: 16px;
  font-weight: 850;
}
body.wrg-storefront-polish .wc-proceed-to-checkout a.checkout-button:hover,
body.wrg-storefront-polish.woocommerce-checkout #place_order:hover {
  border-color: var(--wrg-navy-950);
  background: var(--wrg-navy-950);
  color: #fff;
}

body.wrg-storefront-polish.woocommerce-checkout .woocommerce-billing-fields,
body.wrg-storefront-polish.woocommerce-checkout .woocommerce-shipping-fields,
body.wrg-storefront-polish.woocommerce-checkout .woocommerce-additional-fields { margin-bottom: 20px; }
body.wrg-storefront-polish.woocommerce-checkout :where(.woocommerce-billing-fields > h3, .woocommerce-shipping-fields h3, #order_review_heading) {
  color: var(--wrg-navy-950);
  font-size: 20px;
  font-weight: 800;
  line-height: 1.35;
}
body.wrg-storefront-polish.woocommerce-checkout #order_review,
body.wrg-storefront-polish.woocommerce-checkout .woocommerce-checkout-review-order { padding: 16px; }
body.wrg-storefront-polish.woocommerce-checkout #payment {
  background: var(--wrg-panel);
  border: 1px solid var(--wrg-line);
  border-radius: var(--wrg-radius-sm);
}
body.wrg-storefront-polish.woocommerce-checkout #payment ul.payment_methods { border-bottom-color: var(--wrg-line); }
body.wrg-storefront-polish.woocommerce-checkout #payment div.payment_box {
  background: #fff;
  border: 1px solid var(--wrg-line);
  border-radius: var(--wrg-radius-sm);
  color: var(--wrg-steel-600);
}
body.wrg-storefront-polish.woocommerce-checkout #payment div.payment_box::before { display: none; }

/* My account */
body.wrg-storefront-polish.woocommerce-account .woocommerce-MyAccount-navigation ul {
  list-style: none;
  margin: 0;
  padding: 7px;
  border: 1px solid var(--wrg-line);
  border-radius: var(--wrg-radius);
  background: #fff;
}
body.wrg-storefront-polish.woocommerce-account .woocommerce-MyAccount-navigation li a {
  display: block;
  padding: 10px 12px;
  border-left: 3px solid transparent;
  border-radius: 3px;
  color: var(--wrg-steel-700);
  text-decoration: none;
  font-weight: 650;
}
body.wrg-storefront-polish.woocommerce-account .woocommerce-MyAccount-navigation li.is-active a,
body.wrg-storefront-polish.woocommerce-account .woocommerce-MyAccount-navigation li a:hover {
  border-left-color: var(--wrg-electric);
  background: var(--wrg-panel);
  color: var(--wrg-navy-950);
}

/* WooCommerce blocks / homepage collections */
body.wrg-storefront-polish :where(.wc-block-grid__product, .wc-block-product) {
  position: relative;
  border: 1px solid var(--wrg-line);
  border-radius: var(--wrg-radius);
  background: #fff;
  padding: 11px;
}
body.wrg-storefront-polish :where(.wc-block-grid__product, .wc-block-product)::before {
  content: "";
  position: absolute;
  z-index: 2;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--wrg-electric) 0 42px, var(--wrg-navy-900) 42px 100%);
}
body.wrg-storefront-polish .wc-block-grid__product-image img,
body.wrg-storefront-polish .wc-block-components-product-image img {
  aspect-ratio: 1 / 1;
  object-fit: contain;
  border: 1px solid #edf1f4;
  border-radius: 5px;
  background: #fff;
}
body.wrg-storefront-polish :where(.wc-block-grid__product-title, .wc-block-components-product-name) {
  color: var(--wrg-navy-950);
  font-weight: 700;
  line-height: 1.48;
}
body.wrg-storefront-polish :where(.wc-block-grid__product-price, .wc-block-components-product-price) {
  color: var(--wrg-navy-950);
  font-weight: 850;
}
body.wrg-storefront-polish .wc-block-components-product-sale-badge {
  border: 0;
  border-radius: 4px;
  background: var(--wrg-danger);
  color: #fff;
  font-size: 10px;
  font-weight: 850;
}

/* Search / mini cart */
body.wrg-storefront-polish :where(form.woocommerce-product-search, .wc-block-product-search__fields) {
  display: flex;
  gap: 7px;
  align-items: stretch;
}
body.wrg-storefront-polish :where(form.woocommerce-product-search input[type="search"], .wc-block-product-search__field) {
  min-height: 46px;
  flex: 1 1 auto;
  min-width: 0;
  border: 1px solid var(--wrg-line-strong);
  border-radius: var(--wrg-radius-sm);
  background: #fff;
  color: var(--wrg-navy-950);
  padding: 0 13px;
}
body.wrg-storefront-polish form.woocommerce-product-search button,
body.wrg-storefront-polish .wc-block-product-search__button {
  min-height: 46px;
  border: 1px solid var(--wrg-navy-950);
  border-radius: var(--wrg-radius-sm);
  background: var(--wrg-navy-950);
  color: #fff;
  padding: 0 16px;
  font-weight: 750;
}
body.wrg-storefront-polish :where(.widget_shopping_cart, .woocommerce-mini-cart) { color: var(--wrg-navy-950); }
body.wrg-storefront-polish .woocommerce-mini-cart__total {
  border-top: 2px solid var(--wrg-navy-950);
  padding-top: 11px;
}
body.wrg-storefront-polish .woocommerce-mini-cart__buttons {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 7px;
}
body.wrg-storefront-polish .woocommerce-mini-cart__buttons .button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin: 0;
}
body.wrg-storefront-polish .cart-empty.woocommerce-info,
body.wrg-storefront-polish .woocommerce-mini-cart__empty-message { color: var(--wrg-steel-600); }

/* Pagination */
body.wrg-storefront-polish .woocommerce nav.woocommerce-pagination ul {
  border: 0;
  display: inline-flex;
  gap: 5px;
}
body.wrg-storefront-polish .woocommerce nav.woocommerce-pagination ul li { border: 0; }
body.wrg-storefront-polish .woocommerce nav.woocommerce-pagination ul li a,
body.wrg-storefront-polish .woocommerce nav.woocommerce-pagination ul li span {
  min-width: 38px;
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--wrg-line-strong);
  border-radius: 4px;
  background: #fff;
  color: var(--wrg-steel-700);
  font-weight: 700;
}
body.wrg-storefront-polish .woocommerce nav.woocommerce-pagination ul li span.current {
  background: var(--wrg-navy-950);
  border-color: var(--wrg-navy-950);
  color: #fff;
}

@media (prefers-reduced-motion: reduce) {
  body.wrg-storefront-polish *,
  body.wrg-storefront-polish *::before,
  body.wrg-storefront-polish *::after {
    scroll-behavior: auto !important;
    transition-duration: .01ms !important;
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
  }
}

@media (max-width: 1024px) {
  body.wrg-storefront-polish .woocommerce ul.products,
  body.wrg-storefront-polish .woocommerce-page ul.products {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
  }
  body.wrg-storefront-polish .wrg-electrical-trust-strip > span { padding: 0 10px; }
}

@media (max-width: 767px) {
  body.wrg-storefront-polish .wrg-electrical-trust-strip {
    display: grid;
    grid-template-columns: 1fr 1fr;
    border-left-width: 3px;
  }
  body.wrg-storefront-polish .wrg-electrical-trust-strip__brand {
    grid-column: 1 / -1;
  }
  body.wrg-storefront-polish .wrg-electrical-trust-strip > span {
    min-height: 36px;
    padding: 0 9px;
    border-right: 0;
    border-bottom: 1px solid var(--wrg-line);
    font-size: 10px;
    white-space: normal;
  }
  body.wrg-storefront-polish .wrg-electrical-trust-strip > span:nth-child(even) { border-right: 1px solid var(--wrg-line); }

  body.wrg-storefront-polish .woocommerce ul.products,
  body.wrg-storefront-polish .woocommerce-page ul.products {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 9px;
  }
  body.wrg-storefront-polish .woocommerce ul.products li.product,
  body.wrg-storefront-polish .woocommerce-page ul.products li.product {
    padding: 7px 7px 9px;
    border-radius: 6px;
  }
  body.wrg-storefront-polish .woocommerce ul.products li.product:hover {
    transform: none;
    box-shadow: 0 6px 18px rgba(9, 21, 34, .08);
  }
  body.wrg-storefront-polish .woocommerce ul.products li.product .woocommerce-loop-product__title {
    font-size: 12.5px;
    min-height: 4.5em;
  }
  body.wrg-storefront-polish .woocommerce ul.products li.product .price { font-size: 15px; }
  body.wrg-storefront-polish .woocommerce ul.products li.product .button {
    min-height: 42px;
    font-size: 12px;
  }
  body.wrg-storefront-polish.single-product div.product .product_title { font-size: 23px; }
  body.wrg-storefront-polish.single-product div.product p.price,
  body.wrg-storefront-polish.single-product div.product span.price { font-size: 25px; }
  body.wrg-storefront-polish.single-product form.cart {
    display: grid;
    grid-template-columns: 72px minmax(0, 1fr);
    padding: 11px;
  }
  body.wrg-storefront-polish.single-product form.cart .variations,
  body.wrg-storefront-polish.single-product form.cart .single_variation_wrap { grid-column: 1 / -1; }
  body.wrg-storefront-polish.single-product .single_add_to_cart_button { width: 100%; }
  body.wrg-storefront-polish .woocommerce div.product .woocommerce-tabs ul.tabs {
    overflow-x: auto;
    flex-wrap: nowrap;
  }
  body.wrg-storefront-polish .woocommerce div.product .woocommerce-tabs ul.tabs li { flex: 0 0 auto; }
  body.wrg-storefront-polish .woocommerce-cart-form .coupon {
    display: grid;
    grid-template-columns: 1fr;
  }
  body.wrg-storefront-polish .woocommerce-cart-form .coupon .input-text,
  body.wrg-storefront-polish .woocommerce-cart-form .coupon .button { width: 100%; }
  body.wrg-storefront-polish.woocommerce-cart .woocommerce-cart-form,
  body.wrg-storefront-polish.woocommerce-cart .cart-collaterals .cart_totals,
  body.wrg-storefront-polish.woocommerce-checkout #order_review,
  body.wrg-storefront-polish.woocommerce-checkout .woocommerce-checkout-review-order { box-shadow: none; }
}

/* ==========================================================
 * v1.5.0 — WR Electrical Supply technical background
 * Local SVG only. No external image URL, no hotlink, no JS.
 * ========================================================== */

body.wrg-storefront-polish {
  --wrg-workbench: #f3f6f8;
  --wrg-workbench-deep: #e9eff3;
  --wrg-pattern-url: url("../img/electrical-supply-pattern.svg");
}

/*
 * Keep the product canvas bright while giving commerce pages a recognizable
 * electrical-supply environment around the catalogue. Layering is intentionally
 * low-contrast so product photography, prices and checkout fields remain primary.
 */
body.wrg-storefront-polish.woocommerce-shop :where(main, #primary, .site-main, .content-area),
body.wrg-storefront-polish.tax-product_cat :where(main, #primary, .site-main, .content-area),
body.wrg-storefront-polish.tax-product_tag :where(main, #primary, .site-main, .content-area),
body.wrg-storefront-polish.single-product :where(main, #primary, .site-main, .content-area),
body.wrg-storefront-polish.woocommerce-cart :where(main, #primary, .site-main, .content-area),
body.wrg-storefront-polish.woocommerce-checkout :where(main, #primary, .site-main, .content-area) {
  background-color: var(--wrg-workbench);
  background-image:
    linear-gradient(180deg, rgba(255,255,255,.88) 0%, rgba(243,246,248,.92) 230px, rgba(243,246,248,.96) 100%),
    var(--wrg-pattern-url);
  background-repeat: no-repeat, repeat;
  background-position: center top, center top;
  background-size: 100% 100%, 760px 520px;
}

/* Theme wrappers that otherwise paint an opaque generic background. */
body.wrg-storefront-polish.woocommerce-shop :where(.site-content, .content-area),
body.wrg-storefront-polish.tax-product_cat :where(.site-content, .content-area),
body.wrg-storefront-polish.tax-product_tag :where(.site-content, .content-area),
body.wrg-storefront-polish.single-product :where(.site-content, .content-area),
body.wrg-storefront-polish.woocommerce-cart :where(.site-content, .content-area),
body.wrg-storefront-polish.woocommerce-checkout :where(.site-content, .content-area) {
  background-color: transparent;
}

/* Electrical catalogue header: white technical panel over the tool/equipment field. */
body.wrg-storefront-polish :where(.woocommerce-products-header) {
  padding: 22px 24px 19px;
  border: 1px solid var(--wrg-line-strong);
  border-left: 5px solid var(--wrg-electric);
  border-radius: var(--wrg-radius);
  background-color: rgba(255,255,255,.96);
  background-image:
    linear-gradient(90deg, rgba(255,255,255,.98) 0%, rgba(255,255,255,.88) 58%, rgba(244,247,249,.78) 100%),
    var(--wrg-pattern-url);
  background-position: center, right 12% top 36%;
  background-size: auto, 560px 383px;
  box-shadow: 0 10px 28px rgba(9,21,34,.07);
  overflow: hidden;
}
body.wrg-storefront-polish .woocommerce-products-header::before {
  content: "ELECTRICAL • LIGHTING • WIRING ACCESSORIES";
  display: block;
  margin-bottom: 7px;
  color: var(--wrg-steel-600);
  font-size: 10px;
  font-weight: 850;
  letter-spacing: .13em;
}
body.wrg-storefront-polish .woocommerce-products-header::after {
  left: 24px;
  width: 82px;
}

/* Trust strip gets the visual weight of a professional service/spec bar. */
body.wrg-storefront-polish .wrg-electrical-trust-strip {
  border-color: #b7c3cd;
  border-left-width: 0;
  background:
    linear-gradient(90deg, rgba(255,255,255,.98), rgba(246,249,251,.98)),
    var(--wrg-pattern-url);
  box-shadow: 0 7px 22px rgba(9,21,34,.055);
}
body.wrg-storefront-polish .wrg-electrical-trust-strip__brand {
  position: relative;
  border-left: 4px solid var(--wrg-electric);
}
body.wrg-storefront-polish .wrg-electrical-trust-strip__brand::after {
  content: "⚡";
  margin-left: 9px;
  color: var(--wrg-electric);
  font-size: 13px;
  line-height: 1;
}

/* Product catalogue becomes a clean white shelf floating over the technical field. */
body.wrg-storefront-polish .woocommerce ul.products li.product,
body.wrg-storefront-polish .woocommerce-page ul.products li.product {
  border-color: #cfd8df;
  box-shadow: 0 5px 18px rgba(9,21,34,.055);
}
body.wrg-storefront-polish .woocommerce ul.products li.product:hover {
  border-color: #93a6b6;
  box-shadow: 0 16px 34px rgba(9,21,34,.14);
}

/* Single-product content is separated from the equipment background like a spec sheet. */
body.wrg-storefront-polish.single-product div.product .summary {
  padding: 20px;
  border: 1px solid var(--wrg-line-strong);
  border-radius: var(--wrg-radius);
  background: rgba(255,255,255,.97);
  box-shadow: 0 10px 30px rgba(9,21,34,.07);
}
body.wrg-storefront-polish.single-product div.product div.images .woocommerce-product-gallery__wrapper {
  background-color: rgba(255,255,255,.98);
}
body.wrg-storefront-polish.single-product .woocommerce-tabs,
body.wrg-storefront-polish.single-product .related.products,
body.wrg-storefront-polish.single-product .upsells.products {
  padding: 18px;
  border: 1px solid var(--wrg-line);
  border-radius: var(--wrg-radius);
  background: rgba(255,255,255,.96);
  box-shadow: 0 7px 24px rgba(9,21,34,.045);
}

/* Cart and checkout use a quieter version of the same workshop/technical environment. */
body.wrg-storefront-polish.woocommerce-cart :where(main, #primary, .site-main, .content-area),
body.wrg-storefront-polish.woocommerce-checkout :where(main, #primary, .site-main, .content-area) {
  background-image:
    linear-gradient(180deg, rgba(255,255,255,.94), rgba(243,246,248,.97)),
    var(--wrg-pattern-url);
}

@media (max-width: 767px) {
  body.wrg-storefront-polish.woocommerce-shop :where(main, #primary, .site-main, .content-area),
  body.wrg-storefront-polish.tax-product_cat :where(main, #primary, .site-main, .content-area),
  body.wrg-storefront-polish.tax-product_tag :where(main, #primary, .site-main, .content-area),
  body.wrg-storefront-polish.single-product :where(main, #primary, .site-main, .content-area),
  body.wrg-storefront-polish.woocommerce-cart :where(main, #primary, .site-main, .content-area),
  body.wrg-storefront-polish.woocommerce-checkout :where(main, #primary, .site-main, .content-area) {
    background-size: 100% 100%, 520px 356px;
  }
  body.wrg-storefront-polish :where(.woocommerce-products-header) {
    padding: 17px 16px 15px;
    background-size: auto, 430px 294px;
  }
  body.wrg-storefront-polish .woocommerce-products-header::after { left: 16px; }
  body.wrg-storefront-polish .woocommerce-products-header::before {
    font-size: 9px;
    letter-spacing: .09em;
  }
  body.wrg-storefront-polish.single-product div.product .summary { padding: 15px; }
}

@media (prefers-reduced-motion: reduce) {
  body.wrg-storefront-polish * { scroll-behavior: auto; }
}
