/* Dynamic shop / category page tweaks */
.kids-shop-products-page .category-row-link {
	display: flex;
	align-items: center;
	justify-content: space-between;
	width: 100%;
	text-decoration: none;
	color: inherit;
	padding: 10px 16px;
	box-sizing: border-box;
}

.kids-shop-products-page .category-row-link:hover {
	background: var(--shop-color-primary-light-3, rgba(39, 167, 184, 0.08));
}

.kids-shop-products-page .category-item.selected > .category-row-link,
.kids-shop-products-page .category-child.selected {
	background: var(--shop-color-primary-light-3, rgba(39, 167, 184, 0.12));
	border-left: 3px solid var(--shop-color-primary, #27a7b8);
}

.kids-shop-products-page .clear-filters .clear-btn {
	display: block;
	width: 100%;
	text-align: center;
	padding: 12px;
	text-decoration: none;
	color: inherit;
	background: #fff;
	border: 1px solid #e6e6e6;
	border-radius: 4px;
	cursor: pointer;
	box-sizing: border-box;
}

.kids-shop-products-page .kids-shop-category-title {
	margin: 0;
	font-size: 1.25rem;
	font-weight: 600;
}

.kids-shop-products-page .kids-shop-no-products {
	grid-column: 1 / -1;
	text-align: center;
	padding: 48px 16px;
}

.kids-shop-products-page .woocommerce-pagination {
	grid-column: 1 / -1;
	margin-top: 24px;
}

/* Hide default WooCommerce product list wrappers */
.kids-shop-archive .woocommerce ul.products {
	display: contents;
}

.kids-shop-archive .woocommerce .products::before,
.kids-shop-archive .woocommerce .products::after {
	display: none;
}

/* Mobile sidebar overlay */
@media (max-width: 991px) {
	.kids-shop-products-page .left-area .sidebar {
		position: fixed;
		top: 0;
		left: 0;
		z-index: 10001;
		height: 100%;
		width: min(320px, 88vw);
		background: #fff;
		transform: translateX(-110%);
		transition: transform 0.25s ease;
		overflow-y: auto;
		box-shadow: 2px 0 12px rgba(0, 0, 0, 0.12);
	}

	.kids-shop-products-page .left-area .sidebar.is-open {
		transform: translateX(0);
	}

	body.kids-shop-sidebar-open::before {
		content: "";
		position: fixed;
		inset: 0;
		background: rgba(0, 0, 0, 0.45);
		z-index: 10000;
	}

	.kids-shop-products-page .slide-top.kids-shop-sidebar-close {
		display: flex;
		justify-content: flex-end;
		padding: 12px 16px;
		cursor: pointer;
		font-weight: 700;
	}
}

@media (min-width: 992px) {
	.kids-shop-products-page .slide-top.kids-shop-sidebar-close {
		display: none;
	}
}

/* ── Add-to-cart spinner ─────────────────────────────────────────── */
@keyframes ks-rotate {
	to { transform: rotate(360deg); }
}

.ks-spin {
	display: block;
	animation: ks-rotate 0.75s linear infinite;
}

/* ── Toast notification ──────────────────────────────────────────── */
.ks-toast {
	position: fixed;
	bottom: 28px;
	left: 50%;
	transform: translateX(-50%) translateY(20px);
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 12px 18px;
	border-radius: 50px;
	font-size: 14px;
	font-weight: 500;
	color: #fff;
	box-shadow: 0 6px 24px rgba(0, 0, 0, 0.18);
	opacity: 0;
	transition: opacity 0.3s ease, transform 0.3s ease;
	z-index: 99999;
	white-space: nowrap;
	pointer-events: none;
}

.ks-toast.ks-toast--in {
	opacity: 1;
	transform: translateX(-50%) translateY(0);
	pointer-events: auto;
}

.ks-toast--success { background: linear-gradient(135deg, #1db954 0%, #17a345 100%); }
.ks-toast--error   { background: linear-gradient(135deg, #e53935 0%, #c62828 100%); }

.ks-toast__icon { display: flex; align-items: center; flex-shrink: 0; }
.ks-toast__msg  { flex: 1; }

.ks-toast__view {
	color: #fff;
	text-decoration: none;
	font-weight: 600;
	border: 1.5px solid rgba(255, 255, 255, 0.7);
	border-radius: 50px;
	padding: 4px 12px;
	font-size: 13px;
	transition: background 0.2s;
}

.ks-toast__view:hover { background: rgba(255, 255, 255, 0.2); }

.ks-toast__close {
	background: rgba(255, 255, 255, 0.2);
	border: none;
	color: #fff;
	font-size: 13px;
	font-weight: 500;
	border-radius: 50px;
	padding: 4px 12px;
	cursor: pointer;
	transition: background 0.2s;
}

.ks-toast__close:hover { background: rgba(255, 255, 255, 0.35); }

@media (max-width: 480px) {
	.ks-toast {
		bottom: 80px;
		left: 16px;
		right: 16px;
		transform: translateY(20px);
		white-space: normal;
		border-radius: 14px;
	}
	.ks-toast.ks-toast--in { transform: translateY(0); }
}

/* ── Single product (reference layout) ───────────────────────────── */
.kids-shop-single-product-page-wrap {
	padding: 18px 0 40px;
	background: #f6f8f9;
}

.kids-shop-single-product-card {
	border: 1px solid #e2e8ea;
	border-radius: 14px;
	padding: 20px 20px 24px;
	background: #fff;
	box-shadow: 0 1px 0 rgba(0, 0, 0, 0.02);
}

.kids-shop-sp-main {
	display: grid;
	grid-template-columns: minmax(260px, 1fr) minmax(300px, 1.15fr) minmax(220px, 0.85fr);
	gap: 20px 24px;
	align-items: start;
}

/* Gallery */
.kids-shop-sp-left {
	position: relative;
	border: 1px solid #e8edf0;
	border-radius: 12px;
	background: linear-gradient(180deg, #fdfcfa 0%, #f5f2ee 100%);
	min-height: 340px;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 16px;
}

.kids-shop-sp-image {
	max-width: 100%;
	max-height: 320px;
	width: auto;
	height: auto;
	object-fit: contain;
}

.kids-shop-sp-discount {
	position: absolute;
	top: 14px;
	left: 14px;
	z-index: 2;
	font-size: 12px;
	font-weight: 800;
	letter-spacing: 0.02em;
	color: #0d7a4d;
	background: #dff7ea;
	border-radius: 6px;
	padding: 6px 10px;
	line-height: 1;
	box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

.kids-shop-sp-wishlist {
	position: absolute;
	top: 12px;
	right: 12px;
	z-index: 2;
	width: 42px;
	height: 42px;
	border: none;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.95);
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.kids-shop-sp-wishlist:hover {
	transform: scale(1.05);
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* Middle column */
.kids-shop-sp-title {
	margin: 0 0 10px;
	font-size: clamp(1.5rem, 2.4vw, 2rem);
	font-weight: 800;
	color: #2b3135;
	letter-spacing: -0.02em;
	line-height: 1.2;
}

.kids-shop-sp-rating {
	display: flex;
	align-items: center;
	gap: 10px;
	margin-bottom: 14px;
	font-size: 14px;
	color: #8a9399;
}

.kids-shop-sp-stars {
	display: inline-flex;
	gap: 2px;
	line-height: 1;
	font-size: 18px;
	letter-spacing: 0;
}

.kids-shop-sp-star--full {
	color: #ffc107;
	text-shadow: 0 0 0 #ffc107;
}

.kids-shop-sp-star--empty {
	color: #d5dde1;
}

.kids-shop-sp-price-block {
	margin-bottom: 18px;
}

.kids-shop-sp-save {
	font-size: 15px;
	font-weight: 700;
	color: #ff6b35;
	margin-bottom: 6px;
}

.kids-shop-sp-price-row {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: 10px 14px;
}

.kids-shop-sp-current {
	font-size: clamp(2rem, 3.2vw, 2.65rem);
	font-weight: 800;
	color: var(--shop-color-primary, #27a7b8);
	line-height: 1;
}

.kids-shop-sp-regular {
	font-size: 1.35rem;
	font-weight: 600;
	color: #9aa3a8;
	text-decoration: line-through;
}

/* Quantity + buttons */
.kids-shop-sp-cart {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 10px;
	margin-bottom: 20px;
}

.kids-shop-sp-qty-box {
	display: inline-flex;
	align-items: stretch;
	border: 1.5px solid var(--shop-color-primary, #27a7b8);
	border-radius: 6px;
	overflow: hidden;
	background: #fff;
}

.kids-shop-sp-qty-box .kids-shop-sp-qty-minus,
.kids-shop-sp-qty-box .kids-shop-sp-qty-plus {
	width: 44px;
	border: none;
	background: #fff;
	font-size: 22px;
	line-height: 1;
	color: #2b3135;
	cursor: pointer;
	transition: background 0.15s ease;
}

.kids-shop-sp-qty-box .kids-shop-sp-qty-minus:hover,
.kids-shop-sp-qty-box .kids-shop-sp-qty-plus:hover {
	background: #f0fafb;
}

.kids-shop-sp-qty-box .qty,
.kids-shop-sp-qty-box .kids-shop-sp-qty {
	width: 56px;
	height: 44px;
	border: none;
	border-left: 1px solid #d9ecef;
	border-right: 1px solid #d9ecef;
	text-align: center;
	font-size: 16px;
	font-weight: 700;
	color: #2b3135;
	-moz-appearance: textfield;
}

.kids-shop-sp-qty-box input::-webkit-outer-spin-button,
.kids-shop-sp-qty-box input::-webkit-inner-spin-button {
	-webkit-appearance: none;
	margin: 0;
}

.kids-shop-sp-add,
.kids-shop-sp-buy-now {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	min-height: 46px;
	padding: 0 20px;
	border-radius: 6px;
	font-size: 15px;
	font-weight: 800;
	text-decoration: none;
	border: none;
	cursor: pointer;
	transition: filter 0.15s ease, transform 0.1s ease;
}

.kids-shop-sp-add .kids-shop-sp-btn-icon,
.kids-shop-sp-buy-now .kids-shop-sp-btn-icon {
	flex-shrink: 0;
}

.kids-shop-sp-add {
	background: var(--shop-color-primary, #27a7b8) !important;
	color: #fff !important;
}

.kids-shop-sp-add:hover {
	filter: brightness(0.96);
}

.kids-shop-sp-add:disabled {
	opacity: 0.85;
	cursor: wait;
}

.kids-shop-sp-buy-now {
	background: var(--shop-color-secondary, #d12c60);
	color: #fff;
}

.kids-shop-sp-buy-now:hover {
	filter: brightness(1.05);
	color: #fff;
}

.kids-shop-sp-cart--fallback {
	align-items: flex-start;
}

.kids-shop-sp-buy-now--solo {
	margin-top: 8px;
}

.kids-shop-sp-meta {
	display: grid;
	gap: 8px;
	font-size: 15px;
	line-height: 1.5;
	color: #7a838a;
}

.kids-shop-sp-meta-line {
	margin: 0;
}

.kids-shop-sp-meta-label {
	font-weight: 700;
	color: #5c656c;
	margin-right: 4px;
}

.kids-shop-sp-meta a {
	color: var(--shop-color-primary, #27a7b8);
	font-weight: 600;
	text-decoration: none;
}

.kids-shop-sp-meta a:hover {
	text-decoration: underline;
}

/* Right: category panel */
.kids-shop-sp-right {
	border: 1px solid #e8edf0;
	border-radius: 12px;
	padding: 14px 12px 16px;
	background: #fff;
	align-self: stretch;
}

.kids-shop-sp-right .nested-category-sidebar {
	padding: 0;
}

.kids-shop-category-sidebar--single .sidebar-header h3 {
	font-size: 1.35rem;
	font-weight: 800;
	color: #2b3135;
	margin: 0 0 10px;
	padding-bottom: 8px;
	border-bottom: 3px solid var(--shop-color-primary, #27a7b8);
	display: inline-block;
	min-width: 120px;
}

.kids-shop-category-sidebar--single .category-tree {
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.kids-shop-category-sidebar--single .category-item {
	border: 1px solid #e4eaed;
	border-radius: 10px;
	overflow: hidden;
	background: #fafcfd;
}

.kids-shop-category-sidebar--single .category-row-link {
	padding: 10px 12px;
	border-radius: 10px;
}

.kids-shop-category-sidebar--single .expand-icon,
.kids-shop-category-sidebar--single .category-children {
	display: none !important;
}

.kids-shop-category-sidebar--single .category-content {
	gap: 10px;
}

.kids-shop-category-sidebar--single .category-image {
	border-radius: 8px;
	border: 1px solid #d9ecef;
}

.kids-shop-category-sidebar--single .category-name {
	font-weight: 700;
	font-size: 14px;
	color: #3a4248;
}

/* Tabs */
.kids-shop-sp-tabs {
	margin-top: 22px;
	border: 1px solid #e8edf0;
	border-radius: 12px;
	padding: 16px 18px 20px;
	background: #fff;
}

.kids-shop-sp-tab-head {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin-bottom: 16px;
}

.kids-shop-sp-tab {
	height: 44px;
	padding: 0 22px;
	border-radius: 22px;
	border: 1.5px solid #d5dee2;
	background: #fff;
	color: #7a8790;
	font-size: 15px;
	font-weight: 700;
	cursor: pointer;
	transition: border-color 0.15s ease, color 0.15s ease, background 0.15s ease;
}

.kids-shop-sp-tab.is-active {
	color: var(--shop-color-primary, #27a7b8);
	border-color: var(--shop-color-primary, #27a7b8);
	background: #f4fbfc;
}

.kids-shop-sp-tab-panels {
	border: 1px solid #eef3f5;
	border-radius: 10px;
	padding: 16px 18px;
	background: #fbfcfd;
	min-height: 120px;
}

.kids-shop-sp-panel {
	color: #7d868c;
	font-size: 15px;
	line-height: 1.65;
}

.kids-shop-sp-desc-short {
	white-space: pre-wrap;
	word-break: break-word;
}

.kids-shop-sp-see-more {
	margin-top: 10px;
	padding: 0;
	border: none;
	background: none;
	color: var(--shop-color-primary, #27a7b8);
	font-weight: 700;
	font-size: 15px;
	cursor: pointer;
	text-decoration: none;
}

.kids-shop-sp-see-more:hover {
	text-decoration: underline;
}

.kids-shop-sp-desc-long {
	margin-top: 12px;
	padding-top: 12px;
	border-top: 1px dashed #e0e8eb;
}

.kids-shop-sp-reviews-closed {
	margin: 0;
	color: #8a9399;
}

/* Shared product row — cart "You May Like" + single "Related Products" */
.kids-shop-product-row {
	width: 100%;
	margin-top: 28px;
	box-sizing: border-box;
}

.kids-shop-product-row .suggestion-section {
	width: 100%;
}

.kids-shop-product-row__title,
.kids-shop-product-row .title {
	margin: 0;
	font-size: 20px;
	font-weight: 700;
	color: #2b3135;
	line-height: 1.25;
}

.kids-shop-product-row .suggestion-border-element {
	width: 100%;
	margin: 15px 0 20px;
	border-bottom: 1px solid #e2e8ea;
}

.kids-shop-product-row .products-cards {
	display: grid !important;
	grid-template-columns: repeat(5, minmax(0, 1fr)) !important;
	gap: 15px !important;
	margin: 0 0 30px !important;
	padding: 0 !important;
	list-style: none !important;
}

/* White panel (matches single product card block) */
.kids-shop-product-row-panel {
	background: #fff;
	border: 1px solid #e2e8ea;
	border-radius: 14px;
	padding: 20px 20px 8px;
	box-shadow: 0 1px 0 rgba(0, 0, 0, 0.02);
	box-sizing: border-box;
}

.kids-shop-cart-page .kids-shop-product-row.kids-shop-cart-suggestions {
	display: block !important;
	width: 100% !important;
	max-width: 100% !important;
	margin: 32px 0 0 !important;
	padding: 0 !important;
	flex: none !important;
}

.kids-shop-cart-page app-cart .kids-shop-product-row.kids-shop-cart-suggestions.container {
	display: block !important;
	flex-direction: column !important;
	justify-content: flex-start !important;
}

.kids-shop-single-product-page-wrap .kids-shop-related-products {
	margin-top: 28px;
}

@media (max-width: 1080px) {
	.kids-shop-product-row .products-cards {
		grid-template-columns: repeat(4, minmax(0, 1fr));
	}
}

@media (max-width: 850px) {
	.kids-shop-product-row .products-cards {
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}
}

@media (max-width: 650px) {
	.kids-shop-product-row .products-cards {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 7px;
		margin-bottom: 20px;
	}

	.kids-shop-product-row .title {
		font-size: 16px;
	}
}

@media (max-width: 1199px) {
	.kids-shop-sp-main {
		grid-template-columns: 1fr 1fr;
	}

	.kids-shop-sp-right {
		grid-column: 1 / -1;
	}
}

@media (max-width: 767px) {
	.kids-shop-single-product-card {
		padding: 14px;
	}

	.kids-shop-sp-main {
		grid-template-columns: 1fr;
	}

	.kids-shop-sp-left {
		min-height: 260px;
	}

	.kids-shop-sp-current {
		font-size: 1.85rem;
	}
}
