/**
 * TKBC Shop restyle — scoped to body.tkbc-shop only.
 * Reuses homepage design tokens (purple/teal, League Spartan / Poppins).
 * Do NOT load on the Gutenberg homepage (body.tkbc-home-gutenberg).
 * Version: 1.0.0 (2026-10-22)
 */

@font-face {
	font-family: "TKBC League Spartan";
	src: url("../fonts/homepage/leaguespartan-700.woff2") format("woff2");
	font-weight: 100 900;
	font-style: normal;
	font-display: swap;
}

@font-face {
	font-family: "TKBC Poppins";
	src: url("../fonts/homepage/poppins-400.woff2") format("woff2");
	font-weight: 400;
	font-style: normal;
	font-display: swap;
}

@font-face {
	font-family: "TKBC Poppins";
	src: url("../fonts/homepage/poppins-500.woff2") format("woff2");
	font-weight: 500;
	font-style: normal;
	font-display: swap;
}

@font-face {
	font-family: "TKBC Poppins";
	src: url("../fonts/homepage/poppins-600.woff2") format("woff2");
	font-weight: 600;
	font-style: normal;
	font-display: swap;
}

@font-face {
	font-family: "TKBC Poppins";
	src: url("../fonts/homepage/poppins-700.woff2") format("woff2");
	font-weight: 700;
	font-style: normal;
	font-display: swap;
}

/* —— Tokens —— */
body.tkbc-shop {
	--tkbc-purple: #421f55;
	--tkbc-teal: #4cbeb5;
	--tkbc-teal-hover: #3fa9a1;
	--tkbc-mint: #cdeeec;
	--tkbc-grey: #ebebeb;
	--tkbc-ink: #252525;
	--tkbc-white: #ffffff;
	--tkbc-head: "TKBC League Spartan", "League Spartan", Montserrat, Arial, sans-serif;
	--tkbc-body: "TKBC Poppins", Poppins, Montserrat, Arial, sans-serif;
	--tkbc-shop-max: 1180px;
	--tkbc-shop-gap: 28px;
	color: var(--tkbc-ink);
	background: var(--tkbc-white);
	font-family: var(--tkbc-body);
}

/* Full-width main column — kill Divi sidebar gutter on shop */
body.tkbc-shop.et_right_sidebar #sidebar,
body.tkbc-shop #sidebar,
body.tkbc-shop .et_pb_widget_area_right {
	display: none !important;
	width: 0 !important;
	height: 0 !important;
	overflow: hidden !important;
	margin: 0 !important;
	padding: 0 !important;
}

body.tkbc-shop.et_right_sidebar #left-area,
body.tkbc-shop #left-area {
	width: 100% !important;
	max-width: 100% !important;
	float: none !important;
	padding-right: 0 !important;
	padding-bottom: 48px !important;
	margin: 0 !important;
}

body.tkbc-shop.et_right_sidebar #main-content .container:before {
	display: none !important;
}

body.tkbc-shop #main-content .container {
	max-width: var(--tkbc-shop-max) !important;
	width: 100% !important;
	padding-left: 24px !important;
	padding-right: 24px !important;
	box-sizing: border-box;
}

/* —— Breadcrumbs —— */
body.tkbc-shop .woocommerce-breadcrumb {
	font-family: var(--tkbc-body);
	font-size: 14px;
	font-weight: 500;
	color: #6b6b6b;
	margin: 20px 0 0;
	padding: 0;
	letter-spacing: 0.01em;
}

body.tkbc-shop .woocommerce-breadcrumb a {
	color: var(--tkbc-purple);
	text-decoration: none;
}

body.tkbc-shop .woocommerce-breadcrumb a:hover {
	color: var(--tkbc-teal);
	text-decoration: underline;
}

/* —— Title band —— */
body.tkbc-shop .woocommerce-products-header {
	background: var(--tkbc-purple) !important;
	background-image: linear-gradient(135deg, #421f55 0%, #5a2d72 55%, #3a1849 100%) !important;
	border-radius: 20px !important;
	padding: 36px 40px 40px !important;
	margin: 20px 0 28px !important;
	position: relative;
	overflow: hidden;
}

body.tkbc-shop .woocommerce-products-header::after {
	content: "";
	position: absolute;
	right: -40px;
	bottom: -60px;
	width: 220px;
	height: 220px;
	border-radius: 50%;
	background: rgba(76, 190, 181, 0.22);
	pointer-events: none;
}

body.tkbc-shop .woocommerce-products-header__title.page-title,
body.tkbc-shop h1.woocommerce-products-header__title {
	font-family: var(--tkbc-head) !important;
	font-weight: 900 !important;
	font-size: clamp(2rem, 4vw, 3.25rem) !important;
	line-height: 1.1 !important;
	letter-spacing: 0.01em !important;
	color: var(--tkbc-white) !important;
	margin: 0 !important;
	padding: 0 !important;
	text-transform: none !important;
	position: relative;
	z-index: 1;
}

body.tkbc-shop .woocommerce-products-header .term-description,
body.tkbc-shop .woocommerce-products-header > p {
	font-family: var(--tkbc-body);
	font-size: 1.05rem;
	line-height: 1.5;
	color: rgba(255, 255, 255, 0.9);
	margin: 12px 0 0;
	max-width: 42rem;
	position: relative;
	z-index: 1;
}

/* —— Toolbar (count + sort) —— */
body.tkbc-shop .woocommerce-result-count,
body.tkbc-shop .woocommerce-ordering {
	font-family: var(--tkbc-body);
	font-size: 15px;
	color: #5a5a5a;
	margin-bottom: 20px;
}

body.tkbc-shop .woocommerce-ordering select.orderby {
	font-family: var(--tkbc-body);
	font-size: 15px;
	font-weight: 500;
	color: var(--tkbc-ink);
	background: var(--tkbc-white);
	border: 1.5px solid var(--tkbc-grey);
	border-radius: 12px;
	padding: 10px 36px 10px 14px;
	min-height: 44px;
	appearance: none;
	-webkit-appearance: none;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%23421f55' d='M1.4.6 6 5.2 10.6.6 12 2 6 8 0 2z'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 14px center;
	cursor: pointer;
}

body.tkbc-shop .woocommerce-ordering select.orderby:focus {
	outline: 3px solid #f4a419;
	outline-offset: 2px;
	border-color: var(--tkbc-teal);
}

/* —— Product grid —— */
body.tkbc-shop ul.products {
	display: grid !important;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: var(--tkbc-shop-gap);
	list-style: none !important;
	margin: 0 0 40px !important;
	padding: 0 !important;
	width: 100% !important;
}

body.tkbc-shop ul.products::before,
body.tkbc-shop ul.products::after {
	display: none !important;
	content: none !important;
}

body.tkbc-shop ul.products li.product {
	width: 100% !important;
	max-width: none !important;
	float: none !important;
	margin: 0 !important;
	padding: 0 !important;
	clear: none !important;
	background: var(--tkbc-white);
	border: 1.5px solid var(--tkbc-grey);
	border-radius: 18px;
	overflow: hidden;
	display: flex;
	flex-direction: column;
	box-shadow: 0 8px 24px rgba(66, 31, 85, 0.06);
	transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
	position: relative;
}

body.tkbc-shop ul.products li.product:hover {
	transform: translateY(-3px);
	box-shadow: 0 14px 32px rgba(66, 31, 85, 0.12);
	border-color: var(--tkbc-mint);
}

body.tkbc-shop ul.products li.product a {
	text-decoration: none;
	color: inherit;
}

body.tkbc-shop ul.products li.product img {
	width: 100% !important;
	height: auto !important;
	aspect-ratio: 1 / 1;
	object-fit: cover;
	display: block;
	margin: 0 !important;
	border-radius: 0 !important;
	background: var(--tkbc-mint);
}

body.tkbc-shop ul.products li.product .woocommerce-loop-product__title,
body.tkbc-shop ul.products li.product h2,
body.tkbc-shop ul.products li.product h3 {
	font-family: var(--tkbc-head) !important;
	font-weight: 700 !important;
	font-size: 1.15rem !important;
	line-height: 1.3 !important;
	letter-spacing: 0.005em;
	color: var(--tkbc-purple) !important;
	margin: 16px 18px 8px !important;
	padding: 0 !important;
	text-align: left !important;
}

body.tkbc-shop ul.products li.product .price {
	font-family: var(--tkbc-body) !important;
	font-weight: 700 !important;
	font-size: 1.05rem !important;
	line-height: 1.35 !important;
	color: var(--tkbc-teal) !important;
	margin: 0 18px 16px !important;
	display: block;
	text-align: left !important;
}

body.tkbc-shop ul.products li.product .price del {
	color: #8a8a8a !important;
	font-weight: 500;
	margin-right: 6px;
}

body.tkbc-shop ul.products li.product .price ins {
	text-decoration: none;
	color: var(--tkbc-teal) !important;
}

/* Sale badge */
body.tkbc-shop ul.products li.product .onsale {
	font-family: var(--tkbc-body);
	font-weight: 700;
	font-size: 12px;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	background: var(--tkbc-purple) !important;
	color: var(--tkbc-white) !important;
	border-radius: 999px !important;
	min-height: 0 !important;
	min-width: 0 !important;
	line-height: 1 !important;
	padding: 8px 12px !important;
	top: 12px !important;
	left: auto !important;
	right: 12px !important;
	margin: 0 !important;
}

/* Buttons — Add to cart / Select options / View product */
body.tkbc-shop ul.products li.product .button,
body.tkbc-shop ul.products li.product a.button,
body.tkbc-shop ul.products li.product .added_to_cart {
	font-family: var(--tkbc-body) !important;
	font-weight: 700 !important;
	font-size: 15px !important;
	line-height: 1.2 !important;
	display: inline-flex !important;
	align-items: center;
	justify-content: center;
	gap: 8px;
	min-height: 44px;
	margin: 0 18px 18px !important;
	padding: 12px 20px !important;
	border-radius: 999px !important;
	background: var(--tkbc-teal) !important;
	color: var(--tkbc-white) !important;
	border: 0 !important;
	box-shadow: none !important;
	text-align: center;
	text-transform: none !important;
	letter-spacing: 0 !important;
	transition: background 0.2s ease;
	width: calc(100% - 36px);
	box-sizing: border-box;
}

body.tkbc-shop ul.products li.product .button:hover,
body.tkbc-shop ul.products li.product a.button:hover,
body.tkbc-shop ul.products li.product .added_to_cart:hover {
	background: var(--tkbc-teal-hover) !important;
	color: var(--tkbc-white) !important;
}

body.tkbc-shop ul.products li.product .button:focus-visible,
body.tkbc-shop ul.products li.product a.button:focus-visible {
	outline: 3px solid #f4a419;
	outline-offset: 3px;
}

body.tkbc-shop ul.products li.product .added_to_cart {
	background: var(--tkbc-purple) !important;
	margin-top: 0 !important;
}

/* Star ratings in loop */
body.tkbc-shop ul.products li.product .star-rating {
	margin: 0 18px 8px;
	color: #f4a419;
}

/* —— Pagination —— */
body.tkbc-shop .woocommerce-pagination ul.page-numbers {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	justify-content: center;
	list-style: none;
	margin: 8px 0 40px;
	padding: 0;
}

body.tkbc-shop .woocommerce-pagination ul.page-numbers li {
	margin: 0;
	padding: 0;
}

body.tkbc-shop .woocommerce-pagination ul.page-numbers a,
body.tkbc-shop .woocommerce-pagination ul.page-numbers span {
	font-family: var(--tkbc-body);
	font-weight: 600;
	font-size: 15px;
	min-width: 44px;
	min-height: 44px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	border-radius: 12px;
	border: 1.5px solid var(--tkbc-grey);
	background: var(--tkbc-white);
	color: var(--tkbc-purple);
	text-decoration: none;
	padding: 0 12px;
	box-sizing: border-box;
}

body.tkbc-shop .woocommerce-pagination ul.page-numbers a:hover {
	border-color: var(--tkbc-teal);
	color: var(--tkbc-teal);
}

body.tkbc-shop .woocommerce-pagination ul.page-numbers span.current {
	background: var(--tkbc-purple);
	border-color: var(--tkbc-purple);
	color: var(--tkbc-white);
}

/* —— Hide leftover “happy customers” / blog dump if still injected —— */
body.tkbc-shop .et_pb_widget,
body.tkbc-shop aside.widget,
body.tkbc-shop .widget_recent_entries,
body.tkbc-shop #sidebar .widget {
	display: none !important;
}

/* Keep the normal teal Divi/Elementor site footer visible on shop
   (homepage MU-plugin only hides .footer-wrap on body.tkbc-home-gutenberg). */

/* —— Mobile —— */
@media (max-width: 900px) {
	body.tkbc-shop ul.products {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 16px;
	}

	body.tkbc-shop .woocommerce-products-header {
		padding: 28px 22px 32px;
		border-radius: 16px;
		margin-top: 12px;
	}

	body.tkbc-shop #main-content .container {
		padding-left: 16px !important;
		padding-right: 16px !important;
	}

	body.tkbc-shop ul.products li.product .woocommerce-loop-product__title,
	body.tkbc-shop ul.products li.product h2 {
		font-size: 1rem !important;
		margin: 12px 12px 6px !important;
	}

	body.tkbc-shop ul.products li.product .price {
		margin: 0 12px 12px !important;
		font-size: 0.95rem !important;
	}

	body.tkbc-shop ul.products li.product .button,
	body.tkbc-shop ul.products li.product a.button,
	body.tkbc-shop ul.products li.product .added_to_cart {
		width: calc(100% - 24px);
		margin: 0 12px 14px !important;
		min-height: 44px;
	}
}

@media (max-width: 560px) {
	body.tkbc-shop ul.products {
		grid-template-columns: 1fr;
	}

	body.tkbc-shop .woocommerce-result-count,
	body.tkbc-shop .woocommerce-ordering {
		float: none !important;
		width: 100% !important;
		text-align: left;
	}

	body.tkbc-shop .woocommerce-ordering select.orderby {
		width: 100%;
	}
}


/* —— Force-hide Divi sidebar remnants (happy customers + blog dump) —— */
body.tkbc-shop #sidebar,
body.tkbc-shop #sidebar *,
body.tkbc-shop .et_pb_widget_area,
body.tkbc-shop aside.sidebar {
	display: none !important;
	visibility: hidden !important;
	height: 0 !important;
	max-height: 0 !important;
	overflow: hidden !important;
	margin: 0 !important;
	padding: 0 !important;
	position: absolute !important;
	left: -9999px !important;
	width: 0 !important;
}


/* Dual sale price display 2026-10-23 */
body.tkbc-shop ul.products li.product .price del {
	color: #8a8a8a !important;
	font-weight: 500 !important;
	margin-right: 8px !important;
	text-decoration: line-through !important;
	opacity: 0.85;
}

body.tkbc-shop ul.products li.product .price ins {
	text-decoration: none !important;
	color: var(--tkbc-teal) !important;
	font-weight: 700 !important;
}

/* Core book product pages (tkbc-shop-product) */
body.tkbc-shop-product .tkbc-book-price {
	font-family: var(--tkbc-body, "TKBC Poppins", Poppins, Montserrat, Arial, sans-serif) !important;
	font-size: 1.35rem !important;
	line-height: 1.45 !important;
	color: var(--tkbc-teal, #2a9d8f) !important;
	margin: 0.5em 0 1em !important;
}
body.tkbc-shop-product .tkbc-book-price__note {
	display: block;
	font-size: 0.95rem !important;
	font-weight: 600 !important;
	color: var(--tkbc-purple, #5b2c6f) !important;
	margin-bottom: 0.35em;
	line-height: 1.35;
}
body.tkbc-shop-product .tkbc-book-price del {
	color: #8a8a8a !important;
	font-weight: 500 !important;
	text-decoration: line-through !important;
	margin-right: 0.4em;
	opacity: 0.9;
}
body.tkbc-shop-product .tkbc-book-price ins {
	text-decoration: none !important;
	color: var(--tkbc-teal, #2a9d8f) !important;
	font-weight: 700 !important;
}
@media (max-width: 480px) {
	body.tkbc-shop ul.products li.product .price {
		font-size: 1rem !important;
	}
	body.tkbc-shop-product .tkbc-book-price {
		font-size: 1.2rem !important;
	}
}
