/**
 * FlexiDesignX — Parent Theme (Funori) Overrides
 *
 * Neutralizes Funori's default styles so our Shopee design takes over.
 *
 * @package FlexiDesignX
 * @since   1.0.0
 */

/* ==========================================================================
   Hide Funori's default header/footer/page-title elements
   We render our own via child theme header.php / footer.php
   ========================================================================== */

body.fdx-site #bwp-header,
body.fdx-site .bwp-header,
body.fdx-site #bwp-footer,
body.fdx-site .bwp-footer,
body.fdx-site .page-title,
body.fdx-site .bwp-page-title,
body.fdx-site .bwp-breadcrumb,
body.fdx-site .breadcrumb-wrapper,
body.fdx-site .woocommerce-breadcrumb,
body.fdx-site .search-overlay,
body.fdx-site .back-top,
body.fdx-site .popup-newsletter,
body.fdx-site .content-cart-popup,
body.fdx-site .bwp-quick-view,
body.fdx-site #loader-wrapper,
body.fdx-site .bwp-canvas-vertical,
body.fdx-site .remove-verticalmenu {
	display: none !important;
}

/* Reset Funori's page wrapper */
body.fdx-site .page-wrapper,
body.fdx-site #page {
	background: var(--fdx-grey-50);
	padding: 0;
}

/* Container width override — Funori uses Bootstrap .container */
body.fdx-site .container,
body.fdx-site .container-fluid {
	max-width: var(--fdx-max-width);
	margin-left: auto;
	margin-right: auto;
	padding-left: 1rem;
	padding-right: 1rem;
}

/* ==========================================================================
   WooCommerce Global Overrides
   ========================================================================== */

/* Notices */
.woocommerce-info,
.woocommerce-message {
	border-top-color: var(--fdx-accent);
	background: var(--fdx-accent-light);
}

.woocommerce-info::before,
.woocommerce-message::before {
	color: var(--fdx-accent);
}

/* Buttons — global WooCommerce */
.woocommerce a.button,
.woocommerce button.button,
.woocommerce input.button,
.woocommerce #respond input#submit {
	background-color: var(--fdx-accent);
	color: var(--fdx-white);
	border: none;
	border-radius: var(--fdx-radius-sm);
	font-weight: 600;
	padding: 0.5rem 1rem;
	font-size: var(--fdx-font-size-sm);
	transition: background-color 0.15s;
}

.woocommerce a.button:hover,
.woocommerce button.button:hover,
.woocommerce input.button:hover,
.woocommerce #respond input#submit:hover {
	background-color: var(--fdx-accent-hover);
	color: var(--fdx-white);
}

.woocommerce a.button.alt,
.woocommerce button.button.alt,
.woocommerce input.button.alt {
	background-color: var(--fdx-accent);
}

.woocommerce a.button.alt:hover,
.woocommerce button.button.alt:hover,
.woocommerce input.button.alt:hover {
	background-color: var(--fdx-accent-hover);
}

/* Single Product — hide default stuff we've replaced */
.single-product div.product .woocommerce-product-gallery,
.single-product div.product .summary,
.single-product div.product .woocommerce-tabs,
.single-product .related.products,
.single-product .up-sells {
	display: none;
}

/* Onsale badge — we have our own */
.woocommerce span.onsale {
	display: none;
}

/* Hide Funori's product label overlays (coloured category/sale/hot bars) */
.product-lable,
.product-lable *,
.vgwc-label {
	display: none !important;
}

/* Star rating colour */
.woocommerce .star-rating span::before {
	color: #FBBF24;
}

/* Remove default product loop buttons (card grid doesn't need them) */
.woocommerce ul.products li.product .button,
.woocommerce ul.products li.product .added_to_cart {
	display: none;
}

/* Content area — remove Storefront's sidebar gap */
.site-main {
	width: 100%;
	max-width: 100%;
}

#secondary {
	display: none;
}

.col-full {
	max-width: var(--fdx-max-width);
	padding: 0 1rem;
}

/* ==========================================================================
   Cart Page — Override Storefront defaults
   ========================================================================== */

/* Page title */
.woocommerce-cart .entry-header,
.woocommerce-checkout .entry-header {
	max-width: var(--fdx-max-width);
	margin: 0 auto;
	padding: 1.5rem 1rem 0.5rem;
}

.woocommerce-cart .entry-header .entry-title,
.woocommerce-checkout .entry-header .entry-title {
	font-size: var(--fdx-font-size-2xl);
	font-weight: 700;
	color: var(--fdx-grey-900);
}

/* Empty cart — Shopee style */
.woocommerce-cart .cart-empty.woocommerce-info {
	text-align: center;
	background: var(--fdx-white);
	border: none;
	border-top: none;
	padding: 3rem 1rem;
	font-size: var(--fdx-font-size-lg);
	color: var(--fdx-grey-500);
	border-radius: var(--fdx-radius-md);
	box-shadow: var(--fdx-shadow-sm);
}

.woocommerce-cart .cart-empty.woocommerce-info::before {
	content: '🛒';
	display: block;
	font-size: 4rem;
	margin-bottom: 1rem;
	color: var(--fdx-grey-300);
}

.woocommerce-cart .return-to-shop {
	text-align: center;
	padding: 1rem;
}

.woocommerce-cart .return-to-shop a.button {
	background: var(--fdx-accent);
	color: var(--fdx-white);
	border-radius: var(--fdx-radius-full);
	padding: 0.75rem 2rem;
	font-size: var(--fdx-font-size-base);
	font-weight: 600;
}

.woocommerce-cart .return-to-shop a.button:hover {
	background: var(--fdx-accent-hover);
	color: var(--fdx-white);
}

/* "New in store" cross-sells — style like Shopee cards */
.woocommerce-cart .cross-sells,
.woocommerce-cart section.products {
	max-width: var(--fdx-max-width);
	margin: 2rem auto;
	padding: 0 1rem;
}

.woocommerce-cart section.products h2,
.woocommerce-cart .cross-sells h2 {
	font-size: var(--fdx-font-size-xl);
	font-weight: 700;
	color: var(--fdx-grey-900);
	margin-bottom: 1rem;
}

/* Override Storefront's product loop in cart page */
.woocommerce-cart ul.products {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 0.5rem;
}

.woocommerce-cart ul.products li.product {
	background: var(--fdx-white);
	border-radius: var(--fdx-radius-md);
	box-shadow: var(--fdx-shadow-sm);
	overflow: hidden;
	margin: 0;
	padding: 0;
}

.woocommerce-cart ul.products li.product a img {
	border-radius: var(--fdx-radius-md) var(--fdx-radius-md) 0 0;
}

.woocommerce-cart ul.products li.product .woocommerce-loop-product__title {
	font-size: var(--fdx-font-size-sm);
	padding: 0.5rem 0.75rem 0;
}

.woocommerce-cart ul.products li.product .price {
	color: var(--fdx-accent);
	font-weight: 600;
	padding: 0.25rem 0.75rem 0.75rem;
}

.woocommerce-cart ul.products li.product .button,
.woocommerce-cart ul.products li.product .added_to_cart {
	display: none;
}

.woocommerce-cart ul.products li.product span.onsale {
	background: var(--fdx-error);
	border-radius: var(--fdx-radius-sm);
}

@media (min-width: 768px) {
	.woocommerce-cart ul.products {
		grid-template-columns: repeat(4, 1fr);
	}
}

@media (min-width: 1025px) {
	.woocommerce-cart ul.products {
		grid-template-columns: repeat(5, 1fr);
	}
}
