/* ============================================================
 * Newzon — Single Product Page (PDP) redesign
 * Template: woocommerce/content-single-product.php
 * Layout: [ gallery (vertical thumbs) | summary card ] → Key Features → tabs → related
 * Colours: primary blue #135289, green #009245, ink #111827.
 * ============================================================ */

.woocommerce div.product.newzon-single,
.newzon-single {
	--sp-blue: #135289;
	--sp-blue-d: #0e3f6b;
	--sp-green: #009245;
	--sp-ink: #111827;
	--sp-muted: #6b7280;
	--sp-line: #e5e7eb;
	--sp-bg: #f7f8fa;
}

/* Desktop: widen + centre the PDP with comfortable gutters. On mobile we leave
   #primary alone so the theme's own symmetric .col-full gutters apply (overriding
   them was pushing content to the right). */
@media (min-width: 992px) {
	.single-product #primary.content-area {
		max-width: 1480px;
		margin-left: auto;
		margin-right: auto;
		padding: 8px 24px 48px;
	}
}

/* Own the layout: our template controls the block flow, not the theme floats/flex. */
.woocommerce div.product.newzon-single { display: block !important; }
.newzon-single .woocommerce-product-gallery { float: none !important; width: 100% !important; margin: 0 !important; }
.newzon-single .summary.newzon-sp-summary { float: none !important; width: 100% !important; margin: 0 !important; }
.newzon-single .summary.newzon-sp-summary #shoptimizer-modals-wrapper:empty { display: none; }
.newzon-single .summary.newzon-sp-summary .product-widget:empty { display: none; }
/* Join.chat "Order On WhatsApp" Woo button: redundant on priced products.
   Kept on call-for-price products so they still have a CTA. Keep the sibling
   `.clear` div — it clears the price float. */
.woocommerce div.product.newzon-has-price .joinchat__woo-btn__wrapper { display: none !important; }

/* ---------- Two-column main ---------- */
.newzon-sp-main {
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(360px, 460px);
	gap: 40px;
	align-items: start;
	margin: 6px 0 44px;
}

/* ============================================================
 * Gallery — vertical thumbnail rail on the left of the main image
 * ============================================================ */
.newzon-sp-gallery { position: relative; min-width: 0; }
.newzon-single .woocommerce-product-gallery {
	border: 1px solid var(--sp-line);
	border-radius: 3px;
	padding: 18px;
	background: #fff;
	display: flex;
	flex-direction: row;
	gap: 16px;
	position: relative;
}
/* main image viewport takes the remaining width, thumbs sit to its left */
.newzon-single .woocommerce-product-gallery .flex-viewport,
.newzon-single .woocommerce-product-gallery > .woocommerce-product-gallery__wrapper {
	order: 2;
	flex: 1 1 auto;
	min-width: 0;
	width: auto !important;
	margin: 0 !important;
	border-radius: 3px;
}
.newzon-single .woocommerce-product-gallery__wrapper img,
.newzon-single .flex-viewport img {
	border-radius: 3px;
	max-height: 480px;
	width: auto !important;
	max-width: 100%;
	margin: 0 auto;
	object-fit: contain;
}
/* Vertical thumbnail rail */
.newzon-single .flex-control-thumbs {
	order: 1;
	flex: 0 0 84px;
	width: 84px !important;
	display: flex;
	flex-direction: column;
	gap: 10px;
	margin: 0 !important;
	padding: 0 !important;
	list-style: none;
}
.newzon-single .flex-control-thumbs li { width: 100% !important; margin: 0 !important; float: none !important; }
.newzon-single .flex-control-thumbs img {
	width: 100%;
	height: auto;
	aspect-ratio: 1 / 1;
	object-fit: contain;
	border: 1px solid var(--sp-line);
	border-radius: 3px;
	padding: 5px;
	background: #fff;
	opacity: 1;
	cursor: pointer;
	transition: border-color .15s ease;
}
.newzon-single .flex-control-thumbs img.flex-active,
.newzon-single .flex-control-thumbs img:hover { border-color: var(--sp-blue); }
/* zoom trigger stays pinned top-right over the main image */
.newzon-single .woocommerce-product-gallery__trigger { top: 14px; right: 14px; z-index: 5; }

/* ============================================================
 * Summary / price card
 * ============================================================ */
.newzon-single .summary.newzon-sp-summary {
	border: 1px solid var(--sp-line);
	border-radius: 3px;
	padding: 26px 28px 28px;
	background: #fff;
	box-shadow: 0 1px 2px rgba(17, 24, 39, .04);
}

/* Sale flash / discount bubble sit at the top-left of the summary and overlap the
   brand — hide them; the strikethrough price already signals the discount.
   (Scoped to the summary so related-product card badges are unaffected.) */
.newzon-single .summary.newzon-sp-summary > .onsale,
.newzon-single .summary.newzon-sp-summary span.onsale,
.newzon-single .summary.newzon-sp-summary .product-label,
.newzon-single .summary.newzon-sp-summary .sale-item { display: none !important; }

/* Brand row */
.newzon-sp-brandrow { margin: 0 0 12px; }
.newzon-sp-brand {
	display: inline-flex; align-items: center;
	font-weight: 800; font-size: 13px; letter-spacing: .3px; text-transform: uppercase;
	color: #fff; background: var(--sp-blue);
	padding: 5px 12px; border-radius: 3px; text-decoration: none;
}
.newzon-sp-brand:hover { background: var(--sp-blue-d); color: #fff; }
/* Logo variant: plain brand logo, no box/border/background */
.newzon-sp-brand--logo {
	background: none;
	border: 0;
	padding: 0;
	border-radius: 0;
}
.newzon-sp-brand--logo:hover { background: none; }
.newzon-sp-brand--logo img {
	display: block;
	height: 54px;
	width: auto;
	max-width: 200px;
	object-fit: contain;
}

/* Rating + Ask a question */
.newzon-sp-ratingrow { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; margin: 0 0 10px; }
.newzon-single .newzon-sp-ratingrow .star-rating { margin: 0; float: none; font-size: 15px; }
.newzon-single .newzon-sp-ratingrow .woocommerce-review-link { color: var(--sp-muted); font-size: 13.5px; }
.newzon-sp-ask { display: inline-flex; align-items: center; gap: 6px; color: var(--sp-blue); font-size: 13.5px; font-weight: 600; text-decoration: none; }
.newzon-sp-ask svg { width: 16px; height: 16px; }
.newzon-sp-ask:hover { color: var(--sp-blue-d); text-decoration: underline; }

/* Title (now inside the summary) */
.newzon-single .summary.newzon-sp-summary h1.product_title.entry-title {
	font-size: clamp(20px, 1.1rem + 0.7vw, 26px) !important;
	font-weight: 800 !important;
	color: var(--sp-ink) !important;
	line-height: 1.28 !important;
	margin: 0 0 14px !important;
	padding: 0 !important;
}

/* Price */
.newzon-single .summary.newzon-sp-summary .price {
	margin: 0 0 14px !important;
	color: var(--sp-blue) !important;
	font-size: 30px !important;
	font-weight: 800 !important;
	line-height: 1.1 !important;
	float: none !important; clear: both !important; display: block !important; width: 100% !important;
}
.newzon-single .summary.newzon-sp-summary .price del { font-size: 17px; font-weight: 600; color: var(--sp-muted); opacity: .8; }
.newzon-single .summary.newzon-sp-summary .price ins { text-decoration: none; }
.newzon-single .summary.newzon-sp-summary .price .woocommerce-price-suffix { font-size: 12.5px; font-weight: 600; color: var(--sp-muted); }

/* Stock */
.newzon-sp-stock { display: flex; align-items: center; gap: 10px; margin: 0 0 8px; }
.newzon-sp-stock svg { width: 26px; height: 26px; flex: 0 0 26px; }
.newzon-sp-stock strong { display: block; font-size: 15px; color: var(--sp-ink); line-height: 1.1; }
.newzon-sp-stock.is-in strong { color: var(--sp-green); }
.newzon-sp-stock span { display: block; font-size: 12.5px; color: var(--sp-muted); }

/* Delivery ETA line */
.newzon-sp-delivery { display: flex; align-items: center; gap: 8px; margin: 0 0 18px; color: #1f4e79; font-size: 13.5px; font-weight: 600; }
.newzon-sp-delivery svg { width: 18px; height: 18px; flex: 0 0 18px; color: var(--sp-blue); }

/* Trust points */
.newzon-sp-trust { list-style: none; clear: both; margin: 0 0 20px; padding: 18px 0; border-top: 1px solid var(--sp-line); border-bottom: 1px solid var(--sp-line); display: grid; gap: 14px; }
.newzon-sp-trust li { display: flex; align-items: center; gap: 12px; margin: 0; }
.newzon-sp-trust-icon { display: inline-flex; width: 36px; height: 36px; flex: 0 0 36px; align-items: center; justify-content: center; border-radius: 3px; background: var(--sp-bg); color: var(--sp-blue); }
.newzon-sp-trust-icon svg { width: 20px; height: 20px; }
.newzon-sp-trust-txt strong { display: block; font-size: 14px; color: var(--sp-ink); line-height: 1.15; }
.newzon-sp-trust-txt span { display: block; font-size: 12.5px; color: var(--sp-muted); }

/* Add to cart */
.newzon-single .summary.newzon-sp-summary form.cart { margin: 0 0 16px !important; display: flex; flex-wrap: wrap; align-items: stretch; gap: 10px; }
.newzon-single .summary.newzon-sp-summary form.cart .quantity { margin: 0 !important; }
.newzon-single .summary.newzon-sp-summary form.cart .quantity input.qty {
	height: 54px; width: 78px; border: 1px solid var(--sp-line); border-radius: 3px;
	font-size: 16px; text-align: center;
}
.newzon-single .summary.newzon-sp-summary form.cart button.single_add_to_cart_button {
	flex: 1 1 auto; min-width: 190px;
	height: 54px; border-radius: 3px !important;
	background: var(--sp-blue) !important; color: #fff !important;
	font-size: 16px !important; font-weight: 700 !important;
	display: inline-flex; align-items: center; justify-content: center; gap: 8px;
	border: none !important; box-shadow: none !important; transition: background .15s ease;
}
.newzon-single .summary.newzon-sp-summary form.cart button.single_add_to_cart_button:hover { background: var(--sp-blue-d) !important; }
.newzon-single .summary.newzon-sp-summary form.cart .variations { margin-bottom: 12px; }
.newzon-single .summary.newzon-sp-summary form.cart.variations_form { display: block; }

/* Compare / Wishlist / Share row.
   The PILL surface is the innermost link (or the share <button> itself). The
   outer .newzon-sp-act span and any YITH/compare wrappers are made borderless
   flex pass-throughs so we never get a double border. */
.newzon-sp-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 4px; }
.newzon-sp-act { flex: 1 1 0; min-width: 100px; display: flex; }
/* borderless pass-through wrappers */
.newzon-sp-act > *,
.newzon-sp-act .compare-button,
.newzon-sp-act .woocommerce.product.compare-button,
.newzon-sp-act .yith-wcwl-add-to-wishlist,
.newzon-sp-act .yith-add-to-wishlist-button-block,
.newzon-sp-act .yith-add-to-wishlist-button-block--single {
	display: flex !important;
	flex: 1 1 auto;
	width: 100%;
	min-width: 0;
	margin: 0 !important;
	padding: 0 !important;
	border: 0 !important;
	background: none !important;
}
/* the actual pill */
.newzon-sp-actions .newzon-sp-act a,
.newzon-sp-actions button.newzon-sp-share {
	display: inline-flex !important; align-items: center; justify-content: center; gap: 7px;
	width: 100%; box-sizing: border-box;
	height: 44px; min-height: 44px; padding: 0 10px !important;
	border: 1px solid var(--sp-line) !important; border-radius: 3px !important;
	background: #fff !important; color: #374151 !important;
	font-size: 13.5px !important; font-weight: 600 !important; line-height: 1 !important;
	text-decoration: none !important; cursor: pointer;
	box-shadow: none !important;
	transition: border-color .15s ease, color .15s ease;
}
.newzon-sp-actions .newzon-sp-act a:hover,
.newzon-sp-actions button.newzon-sp-share:hover { border-color: var(--sp-blue) !important; color: var(--sp-blue) !important; }
.newzon-sp-act svg { width: 17px; height: 17px; flex: 0 0 auto; }
.newzon-sp-act .compare.button .label,
.newzon-sp-act .yith-wcwl-add-to-wishlist a span,
.newzon-sp-share span { line-height: 1; }

/* ============================================================
 * Key Features grid
 * ============================================================ */
.newzon-sp-features { margin: 10px 0 40px; }
.newzon-sp-features-title,
.newzon-single .newzon-sp-features h2 { font-size: 20px; font-weight: 800; color: var(--sp-ink); margin: 0 0 16px; }
.newzon-sp-fgrid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.newzon-sp-fcard {
	display: flex; align-items: center; gap: 12px;
	border: 1px solid var(--sp-line); border-radius: 3px; padding: 15px 17px; background: #fff;
}
.newzon-sp-ficon { display: inline-flex; width: 40px; height: 40px; flex: 0 0 40px; align-items: center; justify-content: center; border-radius: 3px; background: var(--sp-bg); color: var(--sp-blue); }
.newzon-sp-ficon svg { width: 22px; height: 22px; }
.newzon-sp-fbody { min-width: 0; }
.newzon-sp-flabel { display: block; font-size: 12px; text-transform: uppercase; letter-spacing: .3px; color: var(--sp-muted); font-weight: 600; }
.newzon-sp-fvalue { display: block; font-size: 14.5px; font-weight: 700; color: var(--sp-ink); line-height: 1.25; }

/* ============================================================
 * Tabs
 * ============================================================ */
.newzon-single .woocommerce-tabs { margin-top: 16px; }
.newzon-single .woocommerce-tabs ul.tabs { padding: 0 !important; margin: 0 0 22px !important; border-bottom: 1px solid var(--sp-line); display: flex; flex-wrap: wrap; gap: 4px; background: none; }
.newzon-single .woocommerce-tabs ul.tabs::before, .newzon-single .woocommerce-tabs ul.tabs::after { display: none !important; }
.newzon-single .woocommerce-tabs ul.tabs li { background: none !important; border: none !important; border-radius: 0 !important; margin: 0 !important; padding: 0 !important; }
.newzon-single .woocommerce-tabs ul.tabs li::before, .newzon-single .woocommerce-tabs ul.tabs li::after { display: none !important; }
.newzon-single .woocommerce-tabs ul.tabs li a {
	display: block; padding: 11px 18px !important; font-weight: 700; font-size: 15px;
	color: var(--sp-muted) !important; border-bottom: 3px solid transparent; margin-bottom: -1px;
}
.newzon-single .woocommerce-tabs ul.tabs li.active a { color: var(--sp-blue) !important; border-bottom-color: var(--sp-blue); }
.newzon-single .woocommerce-tabs .panel { color: #374151; font-size: 15px; line-height: 1.75; }
.newzon-single .woocommerce-tabs .panel h2:first-child { margin-top: 0; }

/* ============================================================
 * Related / upsells
 * ============================================================ */
.newzon-single .related.products,
.newzon-single .upsells.products,
.newzon-single .related-wrapper { clear: both; margin-top: 44px; }
.newzon-single .related.products > h2,
.newzon-single .upsells.products > h2 { font-size: 21px; font-weight: 800; color: var(--sp-ink); margin: 0 0 18px; }

/* ============================================================
 * Sticky summary (desktop) + responsive
 * ============================================================ */
@media (min-width: 992px) {
	.newzon-single .summary.newzon-sp-summary { position: sticky; top: 90px; }
}

@media (max-width: 991px) {
	.single-product #primary.content-area { padding: 4px 15px 32px; }
	.newzon-sp-main { grid-template-columns: 1fr; gap: 22px; }
	.newzon-sp-fgrid { grid-template-columns: repeat(2, 1fr); }
	/* gallery: thumbnails back to a horizontal rail below on small screens */
	.newzon-single .woocommerce-product-gallery { flex-direction: column; }
	.newzon-single .flex-control-thumbs { order: 2; flex: none; width: 100% !important; flex-direction: row; flex-wrap: wrap; }
	.newzon-single .flex-control-thumbs li { width: 64px !important; }
	.newzon-single .woocommerce-product-gallery .flex-viewport,
	.newzon-single .woocommerce-product-gallery > .woocommerce-product-gallery__wrapper { order: 1; }
}

@media (max-width: 560px) {
	.newzon-sp-fgrid { grid-template-columns: 1fr; }
	.newzon-single .summary.newzon-sp-summary { padding: 18px; }
	.newzon-single .summary.newzon-sp-summary form.cart button.single_add_to_cart_button { min-width: 150px; }
	.newzon-sp-act { min-width: 0; }
}
