/* Simple Product Order — frontend styles (Glassmorphism theme) */

/* ---------------------------------------------------------------------- */
/*  "Native app" lock — no pinch-zoom, no page-wide horizontal slip.       */
/*  Shudhu ei plugin-er nijer page-e (shop/single product) effect fele,    */
/*  jekhane style.css enqueue hoy — onno kono theme page-ke touch kore na. */
/*  Pinch-zoom bondho, kintu shwabhabik vertical/horizontal swipe/scroll   */
/*  (jemon "You May Also Like" shelf) age-er moto-i kaj kore — details    */
/*  niche comment-e deya ache. */
/* ---------------------------------------------------------------------- */
/* ":has()" ar plain class selector ke ekই rule-e rakha hoyni — purono
   browser (jara :has() bojhena) plain selector list-e ekta unsupported
   selector thakle গোটা rule-taই drop kore dite pare, tate amader
   ".spo-app-lock" class fallback-o (JS diye boshano) kaje ashto na. Tai
   duita alada rule, jate ekta fail korleo onnota independently kaj kore. */
html:has(.spo-shop-wrap),
html:has(.spo-single-wrap),
body:has(.spo-shop-wrap),
body:has(.spo-single-wrap) {
	max-width: 100%;
	overscroll-behavior-x: none;
	touch-action: pan-x pan-y;
}
html.spo-app-lock,
body.spo-app-lock {
	/* NOTE: overflow-x: hidden ekhane deliberately deya hoyni — html/body-e
	   overflow (x hole-o) set korle kichu browser-e (notably Safari) sticky
	   header (.spo-header, position: sticky) bhenge jete pare, karon eta
	   document-er "scrolling container"-ke viewport theke alada kore dey.
	   Horizontal slip/bounce already ".spo-shop-wrap"/".spo-single-wrap"-er
	   nijer "overflow: hidden" diye clip hoye jay (niche dekho), tai eikhane
	   shudhu overscroll-behavior/touch-action-i যথেষ্ট — sticky-safe. */
	max-width: 100%;
	overscroll-behavior-x: none;
	touch-action: pan-x pan-y;
}
/* "pan-x pan-y" (dutoi direction) dise, ekta na — karon touch-action
   ancestor theke descendant porjonto "intersect" hoy; শুধু pan-y dile
   ".spo-related-track"-er (You May Also Like shelf) nijer horizontal
   swipe kono kono browser-e conflict kore bondho hoye jete parto.
   Zoom-lock er jonno direction restrict korar dorkar nei — pinch-zoom
   emnitei pan-x/pan-y sujog thakle default off thake (pinch-zoom
   explicitly likhle-i shudhu abar chalu hoy), tai dutoi direction khola
   rekhe-o zoom bondho thake, r shelf-o thik moto kaj kore. */
.spo-shop-wrap,
.spo-single-wrap {
	touch-action: pan-x pan-y;
	overscroll-behavior-x: none;
}

/* ---------- Shared glass tokens ---------- */
:root {
	--spo-primary: #16a34a;
	--spo-primary-dark: #15803d;
	--spo-neon: #12e8c6;
	--spo-neon-glow: rgba(18, 232, 198, .5);
	--spo-accent-a: #7c5cff;
	--spo-accent-b: #ff5cb8;
	--spo-text: #10172a;
	--spo-muted: #55607a;
	--spo-border: #e5e7eb;
	--spo-bg: #ffffff;
	--spo-radius: 14px;
	--spo-glass-bg: rgba(255, 255, 255, .52);
	--spo-glass-bg-strong: rgba(255, 255, 255, .68);
	--spo-glass-border: rgba(255, 255, 255, .55);
	--spo-glass-shadow: 0 8px 32px rgba(31, 38, 135, .16), inset 0 1px 0 rgba(255, 255, 255, .5);
	--spo-title-gradient: linear-gradient(135deg, #0f172a 0%, #364360 55%, #0f172a 100%);

	/* Product/related card blur strength — pulled into a variable so it can
	   be turned down for low-end mobile devices (see media queries below)
	   without touching every ".spo-card"/".spo-related-card" rule. These two
	   selectors can repeat 10-100+ times on a single page (shop grid +
	   New Arrivals + Related shelf), so they're the ones that actually
	   matter for scroll performance — other glass elements (toolbar, modal,
	   cart drawer) only ever appear once or twice per page and aren't worth
	   the same treatment. */
	--spo-blur-card: blur(18px) saturate(160%);
	--spo-blur-related: blur(16px) saturate(160%);
}

/* Low-end mobile fallback — a shop grid full of ".spo-card" (New Arrivals,
   full catalog) or a horizontal ".spo-related-card" shelf can put dozens
   of backdrop-filter: blur() layers on screen at once. Compositing that
   many blurred layers is expensive, and on low-end Android phones (common
   among BD users) it shows up as visible scroll lag/jank. Rather than
   dropping the glass look on mobile entirely, just turn the blur radius
   down — still reads as "frosted glass" but costs a lot less to paint. */
@media (max-width: 768px) {
	:root {
		--spo-blur-card: blur(6px) saturate(140%);
		--spo-blur-related: blur(6px) saturate(140%);
	}
}

/* Respect the OS-level "reduce motion" preference: on top of dropping
   hover/transition animations, also drop the blur entirely here. Some
   devices set this preference specifically because compositor-heavy
   effects (like backdrop-filter) cause stutter for that user, so this is
   as much a performance affordance as an accessibility one. */
@media (prefers-reduced-motion: reduce) {
	:root {
		--spo-blur-card: none;
		--spo-blur-related: none;
	}
	.spo-shop-wrap *,
	.spo-single-wrap * {
		animation-duration: .001ms !important;
		animation-iteration-count: 1 !important;
		transition-duration: .001ms !important;
		scroll-behavior: auto !important;
	}
}

.spo-shop-wrap {
	--spo-primary: #16a34a;
	--spo-primary-dark: #15803d;
	--spo-neon: #12e8c6;
	--spo-neon-glow: rgba(18, 232, 198, .5);
	--spo-accent-a: #7c5cff;
	--spo-accent-b: #ff5cb8;
	--spo-text: #10172a;
	--spo-muted: #55607a;
	--spo-border: #e5e7eb;
	--spo-bg: #ffffff;
	--spo-radius: 14px;
	--spo-glass-bg: rgba(255, 255, 255, .52);
	--spo-glass-bg-strong: rgba(255, 255, 255, .68);
	--spo-glass-border: rgba(255, 255, 255, .55);
	--spo-glass-shadow: 0 8px 32px rgba(31, 38, 135, .16), inset 0 1px 0 rgba(255, 255, 255, .5);
	--spo-title-gradient: linear-gradient(135deg, #0f172a 0%, #364360 55%, #0f172a 100%);
	position: relative;
	isolation: isolate;
	width: 100%;
	max-width: 100%;
	margin: 0;
	padding: 0;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
	color: var(--spo-text);
	overflow: hidden;
}

/* Soft, blurred colour "orbs" sitting behind the content — this is what
   the frosted-glass cards/panels actually pick up via backdrop-filter,
   so the glass effect reads instead of just looking like plain white
   translucent boxes on the theme's own background. */
.spo-shop-wrap::before,
.spo-shop-wrap::after,
.spo-single-wrap::before,
.spo-single-wrap::after {
	content: "";
	position: absolute;
	z-index: -1;
	border-radius: 50%;
	filter: blur(90px);
	opacity: .55;
	pointer-events: none;
}
.spo-shop-wrap::before,
.spo-single-wrap::before {
	width: 480px;
	height: 480px;
	top: -160px;
	left: -120px;
	background: radial-gradient(circle, var(--spo-accent-a), transparent 70%);
}
.spo-shop-wrap::after,
.spo-single-wrap::after {
	width: 420px;
	height: 420px;
	top: 200px;
	right: -140px;
	background: radial-gradient(circle, var(--spo-accent-b), transparent 70%);
}

.spo-grid {
	display: grid;
	gap: 22px;
	grid-template-columns: repeat(3, 1fr);
}
.spo-cols-1 { grid-template-columns: repeat(1, 1fr); }
.spo-cols-2 { grid-template-columns: repeat(2, 1fr); }
.spo-cols-3 { grid-template-columns: repeat(3, 1fr); }
.spo-cols-4 { grid-template-columns: repeat(4, 1fr); }

@media (max-width: 900px) {
	.spo-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 560px) {
	.spo-grid { grid-template-columns: 1fr; }
}

.spo-card {
	background: var(--spo-glass-bg);
	backdrop-filter: var(--spo-blur-card);
	-webkit-backdrop-filter: var(--spo-blur-card);
	border: 1px solid var(--spo-glass-border);
	border-radius: var(--spo-radius);
	overflow: hidden;
	display: flex;
	flex-direction: column;
	box-shadow: var(--spo-glass-shadow);
	transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.spo-card:hover {
	transform: translateY(-4px);
	border-color: var(--spo-neon-glow);
	box-shadow: 0 16px 34px rgba(31,38,135,.18), 0 0 0 1px var(--spo-neon-glow), inset 0 1px 0 rgba(255,255,255,.6);
}
.spo-card-link { display: block; color: inherit; text-decoration: none; }
.spo-card-link:hover .spo-title { color: var(--spo-primary-dark); }

.spo-card-img {
	position: relative;
	aspect-ratio: 1 / 1;
	background: #f3f4f6;
	overflow: hidden;
}
.spo-card-img img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.spo-badge {
	position: absolute;
	top: 10px;
	left: 10px;
	font-size: 12px;
	font-weight: 600;
	padding: 4px 10px;
	border-radius: 999px;
	color: #fff;
	backdrop-filter: blur(6px);
	-webkit-backdrop-filter: blur(6px);
}
.spo-badge-sale { background: rgba(22,163,74,.88); box-shadow: 0 0 14px rgba(22,163,74,.55); }
.spo-badge-out { background: rgba(239,68,68,.88); box-shadow: 0 0 14px rgba(239,68,68,.5); }
.spo-badge-new { background: rgba(37,99,235,.88); box-shadow: 0 0 14px rgba(37,99,235,.5); }

.spo-card-body {
	padding: 16px 18px 18px;
	display: flex;
	flex-direction: column;
	gap: 8px;
	flex: 1;
}

.spo-title {
	margin: 0;
	font-size: 17px;
	font-weight: 800;
	line-height: 1.3;
	background: var(--spo-title-gradient);
	-webkit-background-clip: text;
	background-clip: text;
	-webkit-text-fill-color: transparent;
	color: var(--spo-text);
}

.spo-desc {
	margin: 0;
	font-size: 13.5px;
	color: var(--spo-muted);
	line-height: 1.5;
	flex: 1;
}

.spo-price-row { display: flex; align-items: baseline; gap: 8px; }
.spo-price {
	font-size: 19px;
	font-weight: 800;
	color: var(--spo-neon);
	text-shadow: 0 0 14px var(--spo-neon-glow);
	letter-spacing: .2px;
}
.spo-price-old { font-size: 13px; color: var(--spo-muted); text-decoration: line-through; }

.spo-btn {
	appearance: none;
	border: none;
	background: linear-gradient(135deg, var(--spo-primary), var(--spo-neon));
	color: #fff;
	font-size: 14.5px;
	font-weight: 700;
	padding: 11px 18px;
	border-radius: 10px;
	cursor: pointer;
	box-shadow: 0 6px 18px rgba(18,232,198,.28);
	transition: box-shadow .15s ease, transform .1s ease, filter .15s ease;
	margin-top: 4px;
}
.spo-btn:hover { filter: brightness(1.06); box-shadow: 0 8px 24px rgba(18,232,198,.42); }
.spo-btn:active { transform: scale(.98); }
.spo-btn:disabled {
	background: #d1d5db;
	color: #6b7280;
	cursor: not-allowed;
	box-shadow: none;
}
.spo-btn-block { width: 100%; }
.spo-card-actions {
	display: flex;
	gap: 8px;
	margin-top: 4px;
}
.spo-card-actions .spo-btn { flex: 1; margin-top: 0; }
.spo-btn-outline {
	background: var(--spo-glass-bg-strong);
	backdrop-filter: blur(10px);
	-webkit-backdrop-filter: blur(10px);
	color: var(--spo-primary-dark);
	border: 1.5px solid var(--spo-glass-border);
	box-shadow: none;
}
.spo-btn-outline:hover { border-color: var(--spo-neon); box-shadow: 0 0 0 3px var(--spo-neon-glow); filter: none; }
.spo-btn-outline svg { vertical-align: -3px; margin-right: 4px; }

.spo-empty { text-align: center; color: var(--spo-muted); padding: 40px 0; }

/* ---------------------------------------------------------------------- */
/*  Search bar + live suggestions                                         */
/* ---------------------------------------------------------------------- */
/* ---------------------------------------------------------------------- */
/*  Site header (Category dropdown + Search + Account + Cart)             */
/* ---------------------------------------------------------------------- */
.spo-header {
	position: sticky;
	top: 0;
	z-index: 30;
	display: flex;
	align-items: center;
	gap: 8px;
	margin: 0 0 24px;
	padding: 10px 16px 16px;
	background: var(--spo-glass-bg-strong);
	backdrop-filter: blur(16px) saturate(160%);
	-webkit-backdrop-filter: blur(16px) saturate(160%);
	border-bottom: 1px solid var(--spo-glass-border);
	box-shadow: 0 2px 16px rgba(16, 23, 42, .08);
	transition: transform .25s ease, background .15s ease;
}
/* Scroll-down hides the bar, scroll-up brings it back — see script.js/
   site-header.js (spoInitHeaderAutoHide). */
.spo-header.spo-header--hidden { transform: translateY(-100%); }
.spo-header-left {
	flex: 0 0 auto;
	position: relative;
}
.spo-header-search {
	flex: 1 1 auto;
	min-width: 0;
}
.spo-header-actions {
	flex: 0 0 auto;
	display: flex;
	align-items: center;
	gap: 4px;
}

/* Category toggle gets the same flat grey fill as the search box, so the
   two read as one matched "icon + search" set. Admin/cart stay plain
   icon buttons on the right — only a hover tint, no chrome at rest. */
.spo-category-toggle {
	appearance: none;
	cursor: pointer;
	flex: 0 0 auto;
	width: 40px;
	height: 40px;
	border-radius: 8px;
	border: 1.5px solid #c7cbd4;
	background: #f5f6f8;
	color: #10172a;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: background .15s ease, color .15s ease, border-color .15s ease;
}
.spo-category-toggle svg { display: block; }
.spo-category-toggle:hover,
.spo-category-toggle:focus-visible,
.spo-category-toggle.is-active {
	background: #eef0f3;
	border-color: var(--spo-primary);
	color: var(--spo-primary-dark);
}
.spo-toolbar-icon,
.spo-cart-toggle {
	appearance: none;
	cursor: pointer;
	flex: 0 0 auto;
	width: 40px;
	height: 40px;
	border-radius: 10px;
	border: 0;
	background: transparent;
	color: var(--spo-text);
	display: flex;
	align-items: center;
	justify-content: center;
	text-decoration: none;
	transition: background .15s ease, color .15s ease;
}
.spo-toolbar-icon:hover,
.spo-toolbar-icon:focus-visible {
	background: #f0f1f3;
	color: var(--spo-primary-dark);
}

/* Category dropdown panel — anchored under the hamburger button. */
.spo-category-dropdown {
	position: absolute;
	z-index: 40;
	top: calc(100% + 10px);
	left: 0;
	width: max-content;
	max-width: min(420px, 86vw);
	background: #fff;
	border: 1px solid var(--spo-border);
	border-radius: 14px;
	box-shadow: 0 16px 40px rgba(16, 23, 42, .16);
	padding: 16px 18px;
	animation: spo-dropdown-in .15s ease;
}
@keyframes spo-dropdown-in {
	from { opacity: 0; transform: translateY(-6px); }
	to   { opacity: 1; transform: translateY(0); }
}
.spo-category-dropdown .spo-categories-title { margin: 0 0 12px; font-size: 15px; }
.spo-category-dropdown .spo-chip-row { max-width: 100%; }
@media (max-width: 480px) {
	.spo-category-dropdown { left: -10px; max-width: 88vw; }
}

/* ---------------------------------------------------------------------- */
/*  Top banner (image or video — admin sets whichever from Settings)      */
/* ---------------------------------------------------------------------- */
.spo-banner {
	position: relative;
	z-index: 5;
	margin-bottom: 30px;
	border-radius: 22px;
	overflow: hidden;
	border: 1px solid var(--spo-glass-border);
	box-shadow: var(--spo-glass-shadow);
	background: var(--spo-glass-bg);
	line-height: 0;
}
.spo-banner-image,
.spo-banner-video {
	display: block;
	width: 100%;
	max-height: 420px;
	object-fit: cover;
}
@media (max-width: 600px) {
	.spo-banner-image,
	.spo-banner-video { max-height: 260px; }
}

/* Banner-e ekaadhik image upload kora hoyle auto-slide (fade crossfade). */
.spo-banner-slider {
	position: relative;
	width: 100%;
	height: 420px;
}
@media (max-width: 600px) {
	.spo-banner-slider { height: 260px; }
}
.spo-banner-slide {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	object-fit: cover;
	opacity: 0;
	transition: opacity .8s ease;
}
.spo-banner-slide.is-active {
	opacity: 1;
}
.spo-banner-slider-dots {
	position: absolute;
	left: 0;
	right: 0;
	bottom: 14px;
	z-index: 2;
	display: flex;
	justify-content: center;
	gap: 7px;
}
.spo-banner-slider-dot {
	width: 7px;
	height: 7px;
	border-radius: 50%;
	background: rgba(255, 255, 255, .55);
	transition: background .2s ease, transform .2s ease;
}
.spo-banner-slider-dot.is-active {
	background: #fff;
	transform: scale(1.3);
}

/* ---------------------------------------------------------------------- */
/*  Category chips                                                        */
/* ---------------------------------------------------------------------- */
.spo-categories-title,
.spo-newarrivals-title,
.spo-related-title {
	font-size: 18px;
	font-weight: 800;
	margin: 0 0 14px;
	background: var(--spo-title-gradient);
	-webkit-background-clip: text;
	background-clip: text;
	-webkit-text-fill-color: transparent;
	color: var(--spo-text);
}
.spo-chip-row {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
}
.spo-chip {
	appearance: none;
	cursor: pointer;
	font-family: inherit;
	font-size: 13.5px;
	font-weight: 600;
	color: var(--spo-text);
	padding: 9px 18px;
	border-radius: 999px;
	background: var(--spo-glass-bg);
	backdrop-filter: blur(14px) saturate(160%);
	-webkit-backdrop-filter: blur(14px) saturate(160%);
	border: 1.5px solid var(--spo-glass-border);
	box-shadow: var(--spo-glass-shadow);
	transition: border-color .15s ease, box-shadow .15s ease, transform .1s ease;
}
.spo-chip:hover,
.spo-chip.is-active {
	border-color: var(--spo-neon);
	box-shadow: 0 0 0 3px var(--spo-neon-glow);
	transform: translateY(-1px);
}

/* ---------------------------------------------------------------------- */
/*  New Arrivals shelf (reuses .spo-related-shelf/track/card markup)      */
/* ---------------------------------------------------------------------- */
.spo-newarrivals { position: relative; z-index: 5; margin-bottom: 34px; }

.spo-search-wrap {
	position: relative;
	flex: 1 1 320px;
	min-width: 0;
}
.spo-search-box {
	position: relative;
	display: flex;
	align-items: center;
	background: #f5f6f8;
	border: 1.5px solid transparent;
	border-radius: 8px;
	padding: 0 14px;
	transition: background .15s ease, border-color .15s ease, box-shadow .15s ease;
}
.spo-search-box:hover {
	background: #eef0f3;
}
.spo-search-box:focus-within {
	background: #fff;
	border-color: var(--spo-primary);
	box-shadow: 0 0 0 4px rgba(22, 163, 74, .12);
}
.spo-search-icon {
	flex: 0 0 auto;
	color: var(--spo-muted);
}
.spo-search-input {
	flex: 1 1 auto;
	border: 0;
	outline: 0;
	background: transparent;
	font-size: 15px;
	padding: 13px 10px;
	color: var(--spo-text);
	width: 100%;
}
.spo-search-input::placeholder { color: #8b93a7; }
/* Single-product page: search box is a plain link (no live product grid to
   search there), so the "input" is just a static label styled to match. */
.spo-search-box-link { text-decoration: none; cursor: pointer; }
.spo-search-input-static { color: #8b93a7; display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.spo-search-clear {
	flex: 0 0 auto;
	border: 0;
	background: #e5e7eb;
	color: var(--spo-muted);
	width: 22px;
	height: 22px;
	border-radius: 50%;
	font-size: 15px;
	line-height: 1;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
}
.spo-search-clear:hover { background: #d1d5db; color: var(--spo-text); }

.spo-search-suggestions {
	position: absolute;
	top: calc(100% + 8px);
	left: 0;
	right: 0;
	background: #fff;
	border: 1px solid var(--spo-border);
	border-radius: 12px;
	box-shadow: 0 16px 40px rgba(16, 23, 42, .16);
	overflow: hidden;
	z-index: 40;
	max-height: 360px;
	overflow-y: auto;
}
.spo-suggestion-item {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 9px 14px;
	cursor: pointer;
	text-decoration: none;
	color: inherit;
	border-bottom: 1px solid #f3f4f6;
}
.spo-suggestion-item:last-child { border-bottom: 0; }
.spo-suggestion-item:hover,
.spo-suggestion-item.is-active {
	background: #f0fdf4;
}
.spo-suggestion-thumb {
	flex: 0 0 auto;
	width: 38px;
	height: 38px;
	border-radius: 8px;
	overflow: hidden;
	background: #f3f4f6;
}
.spo-suggestion-thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}
.spo-suggestion-info {
	flex: 1 1 auto;
	min-width: 0;
}
.spo-suggestion-name {
	display: block;
	font-size: 14px;
	font-weight: 600;
	color: var(--spo-text);
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}
.spo-suggestion-name mark {
	background: rgba(22,163,74,.18);
	color: var(--spo-primary-dark);
	border-radius: 3px;
	padding: 0 1px;
}
.spo-suggestion-price {
	flex: 0 0 auto;
	font-size: 13px;
	font-weight: 700;
	color: var(--spo-primary-dark);
}
.spo-suggestion-empty {
	padding: 16px 14px;
	font-size: 14px;
	color: var(--spo-muted);
	text-align: center;
}
.spo-search-empty {
	text-align: center;
	color: var(--spo-muted);
	padding: 30px 0;
	font-size: 15px;
}
.spo-card.spo-is-hidden { display: none !important; }

/* ---------- Modal ---------- */
.spo-modal-overlay {
	position: fixed;
	inset: 0;
	background: rgba(17, 24, 39, .55);
	display: flex;
	align-items: center;
	justify-content: center;
	z-index: 99999;
	padding: 16px;
	animation: spo-fade .15s ease;
}
.spo-modal-overlay[hidden] { display: none; }

@keyframes spo-fade { from { opacity: 0; } to { opacity: 1; } }

.spo-modal {
	background: var(--spo-glass-bg-strong, rgba(255,255,255,.82));
	backdrop-filter: blur(26px) saturate(160%);
	-webkit-backdrop-filter: blur(26px) saturate(160%);
	width: 100%;
	max-width: 420px;
	border-radius: 16px;
	padding: 24px;
	position: relative;
	max-height: 90vh;
	overflow-y: auto;
	border: 1px solid var(--spo-glass-border, rgba(255,255,255,.55));
	box-shadow: 0 20px 50px rgba(0,0,0,.25), inset 0 1px 0 rgba(255,255,255,.5);
	animation: spo-pop .18s ease;
}
@keyframes spo-pop {
	from { transform: translateY(10px) scale(.97); opacity: 0; }
	to { transform: translateY(0) scale(1); opacity: 1; }
}

.spo-modal-close {
	position: absolute;
	top: 12px;
	right: 14px;
	background: none;
	border: none;
	font-size: 24px;
	line-height: 1;
	cursor: pointer;
	color: var(--spo-muted);
}
.spo-modal-close:hover { color: var(--spo-text); }

.spo-modal-product {
	display: flex;
	align-items: center;
	gap: 12px;
	margin-bottom: 18px;
	padding-bottom: 16px;
	border-bottom: 1px solid var(--spo-border);
}
.spo-modal-product img {
	width: 64px;
	height: 64px;
	border-radius: 10px;
	object-fit: cover;
	flex-shrink: 0;
}
.spo-modal-product h4 { margin: 0 0 4px; font-size: 15px; }

.spo-field { margin-bottom: 14px; }
.spo-field label {
	display: block;
	font-size: 13px;
	font-weight: 600;
	margin-bottom: 6px;
	color: var(--spo-text);
}
.spo-field input,
.spo-field textarea {
	width: 100%;
	box-sizing: border-box;
	background: rgba(255,255,255,.55);
	border: 1px solid var(--spo-glass-border, var(--spo-border));
	border-radius: 9px;
	padding: 10px 12px;
	font-size: 14.5px;
	font-family: inherit;
	color: var(--spo-text);
}
.spo-field input:focus,
.spo-field textarea:focus {
	outline: none;
	border-color: var(--spo-neon, var(--spo-primary));
	box-shadow: 0 0 0 3px var(--spo-neon-glow, rgba(22,163,74,.15));
}

.spo-form-msg {
	font-size: 13.5px;
	margin-bottom: 12px;
	min-height: 0;
}
.spo-form-msg.spo-msg-error { color: #dc2626; }
.spo-form-msg.spo-msg-success { color: var(--spo-primary-dark); font-weight: 600; }

/* ---------------------------------------------------------------------- */
/*  Cart: floating toggle, slide-in drawer, items, checkout, toast         */
/* ---------------------------------------------------------------------- */
/* Kept in the DOM (the app-style bottom bar's Cart tap just clicks this
   button under the hood — see bottom-nav.js), but visually hidden here so
   there's only ONE cart entry point on screen: the bottom bar's Cart tab.
   Do not delete this element from the markup, only its visibility. */
.spo-cart-toggle {
	position: relative;
	flex: 0 0 auto;
	width: 46px;
	height: 46px;
	border-radius: 50%;
	border: 1.5px solid var(--spo-glass-border);
	background: var(--spo-glass-bg-strong);
	backdrop-filter: blur(16px) saturate(160%);
	-webkit-backdrop-filter: blur(16px) saturate(160%);
	color: var(--spo-text);
	display: none;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	box-shadow: var(--spo-glass-shadow);
	transition: transform .15s ease, border-color .15s ease, box-shadow .15s ease;
}
.spo-cart-toggle:hover { border-color: var(--spo-neon); box-shadow: 0 0 0 3px var(--spo-neon-glow); transform: translateY(-2px); }
.spo-cart-count {
	position: absolute;
	top: -4px;
	right: -4px;
	background: #ef4444;
	color: #fff;
	font-size: 11px;
	font-weight: 800;
	min-width: 20px;
	height: 20px;
	border-radius: 999px;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 0 4px;
	border: 2px solid #fff;
	box-shadow: 0 0 10px rgba(239,68,68,.55);
}

.spo-cart-overlay {
	position: fixed;
	inset: 0;
	background: rgba(17, 24, 39, .5);
	z-index: 99999;
	opacity: 0;
	transition: opacity .2s ease;
}
.spo-cart-overlay.is-visible { opacity: 1; }
.spo-cart-overlay[hidden] { display: none; }

.spo-cart-drawer {
	position: fixed;
	top: 0;
	right: 0;
	bottom: 0;
	width: 400px;
	max-width: 92vw;
	background: var(--spo-glass-bg-strong, rgba(255,255,255,.82));
	backdrop-filter: blur(26px) saturate(160%);
	-webkit-backdrop-filter: blur(26px) saturate(160%);
	border-left: 1px solid var(--spo-glass-border, rgba(255,255,255,.55));
	z-index: 100000;
	display: flex;
	flex-direction: column;
	box-shadow: -14px 0 40px rgba(0,0,0,.2);
	transform: translateX(100%);
	transition: transform .25s ease;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
	color: var(--spo-text, #10172a);
}
.spo-cart-drawer.is-open { transform: translateX(0); }
.spo-cart-drawer[hidden] { display: none; }

.spo-cart-drawer-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 18px 20px;
	border-bottom: 1px solid var(--spo-border, #e5e7eb);
	flex: 0 0 auto;
}
.spo-cart-drawer-header h3 { margin: 0; font-size: 17px; }
.spo-cart-drawer-header .spo-modal-close { position: static; }

.spo-cart-body {
	flex: 1 1 auto;
	overflow-y: auto;
	padding: 16px 20px;
}

.spo-cart-empty {
	text-align: center;
	color: var(--spo-muted, #6b7280);
	padding: 60px 10px;
}
.spo-cart-empty svg { margin-bottom: 10px; opacity: .5; }
.spo-cart-empty p { margin: 0; font-size: 14.5px; }

.spo-cart-items { display: flex; flex-direction: column; gap: 14px; }
.spo-cart-item {
	display: flex;
	align-items: center;
	gap: 12px;
	padding-bottom: 14px;
	border-bottom: 1px solid #f3f4f6;
}
.spo-cart-item:last-child { border-bottom: 0; padding-bottom: 0; }
.spo-cart-item-img {
	width: 52px;
	height: 52px;
	border-radius: 8px;
	object-fit: cover;
	flex: 0 0 auto;
	background: #f3f4f6;
}
.spo-cart-item-info { flex: 1 1 auto; min-width: 0; }
.spo-cart-item-name {
	font-size: 14px;
	font-weight: 600;
	margin-bottom: 3px;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}
.spo-cart-item-price {
	font-size: 13px;
	color: var(--spo-primary-dark, #15803d);
	font-weight: 700;
	margin-bottom: 6px;
}
.spo-cart-qty {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	background: #f9fafb;
	border: 1px solid var(--spo-border, #e5e7eb);
	border-radius: 8px;
	padding: 3px 4px;
}
.spo-cart-qty-btn {
	appearance: none;
	border: none;
	background: #fff;
	width: 22px;
	height: 22px;
	border-radius: 6px;
	font-size: 15px;
	line-height: 1;
	cursor: pointer;
	box-shadow: 0 0 0 1px var(--spo-border, #e5e7eb);
	color: var(--spo-text, #1f2937);
}
.spo-cart-qty-btn:hover { background: #f0fdf4; }
.spo-cart-qty-val { font-size: 13.5px; font-weight: 700; min-width: 14px; text-align: center; }
.spo-cart-remove {
	flex: 0 0 auto;
	appearance: none;
	border: none;
	background: none;
	color: var(--spo-muted, #6b7280);
	font-size: 20px;
	line-height: 1;
	cursor: pointer;
	align-self: flex-start;
	padding: 2px 4px;
}
.spo-cart-remove:hover { color: #dc2626; }

.spo-cart-back {
	appearance: none;
	border: none;
	background: none;
	color: var(--spo-primary-dark, #15803d);
	font-weight: 700;
	font-size: 13.5px;
	cursor: pointer;
	padding: 0;
	margin-bottom: 14px;
}
.spo-cart-summary {
	background: #f9fafb;
	border: 1px solid var(--spo-border, #e5e7eb);
	border-radius: 10px;
	padding: 12px 14px;
	margin-bottom: 16px;
}
.spo-cart-summary-row {
	display: flex;
	justify-content: space-between;
	font-size: 13.5px;
	padding: 4px 0;
	color: var(--spo-muted, #6b7280);
}
.spo-cart-summary-row.spo-cart-summary-total {
	border-top: 1px solid var(--spo-border, #e5e7eb);
	margin-top: 6px;
	padding-top: 8px;
	font-weight: 800;
	color: var(--spo-text, #1f2937);
	font-size: 14.5px;
}

.spo-cart-footer {
	flex: 0 0 auto;
	padding: 16px 20px 20px;
	border-top: 1px solid var(--spo-border, #e5e7eb);
}
.spo-cart-footer[hidden] { display: none; }
.spo-cart-total-row {
	display: flex;
	justify-content: space-between;
	align-items: baseline;
	font-size: 15px;
	font-weight: 700;
	margin-bottom: 12px;
}
#spo-cart-total { font-size: 19px; color: var(--spo-primary-dark, #15803d); }

.spo-cart-toast {
	position: fixed;
	left: 50%;
	bottom: 30px;
	transform: translate(-50%, 12px);
	background: #1f2937;
	color: #fff;
	font-size: 13.5px;
	font-weight: 600;
	padding: 10px 18px;
	border-radius: 999px;
	box-shadow: 0 10px 26px rgba(0,0,0,.25);
	opacity: 0;
	pointer-events: none;
	transition: opacity .2s ease, transform .2s ease;
	z-index: 100001;
	max-width: 88vw;
	text-align: center;
}
.spo-cart-toast.is-visible {
	opacity: 1;
	transform: translate(-50%, 0);
}

/* ---------- Single product page ---------- */
.spo-single-wrap {
	--spo-primary: #16a34a;
	--spo-primary-dark: #15803d;
	--spo-neon: #12e8c6;
	--spo-neon-glow: rgba(18, 232, 198, .5);
	--spo-accent-a: #7c5cff;
	--spo-accent-b: #ff5cb8;
	--spo-text: #10172a;
	--spo-muted: #55607a;
	--spo-border: #e5e7eb;
	--spo-bg: #ffffff;
	--spo-radius: 14px;
	--spo-glass-bg: rgba(255, 255, 255, .52);
	--spo-glass-bg-strong: rgba(255, 255, 255, .68);
	--spo-glass-border: rgba(255, 255, 255, .55);
	--spo-glass-shadow: 0 8px 32px rgba(31, 38, 135, .16), inset 0 1px 0 rgba(255, 255, 255, .5);
	--spo-title-gradient: linear-gradient(135deg, #0f172a 0%, #364360 55%, #0f172a 100%);
	position: relative;
	isolation: isolate;
	overflow: hidden;
	width: 100%;
	max-width: 100%;
	margin: 0;
	padding: 0;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
	color: var(--spo-text);
}
.spo-hp-field {
	position: absolute;
	left: -9999px;
	top: -9999px;
	height: 0;
	width: 0;
	overflow: hidden;
}
.spo-breadcrumb {
	display: flex;
	align-items: center;
	gap: 6px;
	margin-bottom: 8px;
	font-size: 12.5px;
	color: var(--spo-muted);
}
.spo-breadcrumb a {
	color: var(--spo-muted);
	text-decoration: none;
}
.spo-breadcrumb a:hover { color: var(--spo-primary-dark); }
.spo-breadcrumb span[aria-current] {
	color: var(--spo-text);
	font-weight: 600;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
	max-width: 60vw;
}
.spo-single-back {
	display: inline-block;
	margin-bottom: 18px;
	color: var(--spo-muted);
	text-decoration: none;
	font-size: 14px;
	font-weight: 600;
}
.spo-single-back:hover { color: var(--spo-primary-dark); }

.spo-single-top {
	display: grid;
	grid-template-columns: minmax(0, 420px) 1fr;
	gap: 36px;
}
@media (max-width: 700px) {
	.spo-single-top { grid-template-columns: 1fr; gap: 20px; }
}

.spo-single-gallery {
	position: relative;
	aspect-ratio: 1 / 1;
	border-radius: var(--spo-radius);
	overflow: hidden;
	background: #f3f4f6;
	border: 1px solid var(--spo-glass-border);
	box-shadow: var(--spo-glass-shadow);
}
.spo-single-gallery img { width: 100%; height: 100%; object-fit: cover; display: block; }

.spo-single-info { display: flex; flex-direction: column; }
.spo-single-title {
	font-size: 26px;
	font-weight: 800;
	margin: 0 0 10px;
	line-height: 1.25;
	background: var(--spo-title-gradient);
	-webkit-background-clip: text;
	background-clip: text;
	-webkit-text-fill-color: transparent;
	color: var(--spo-text);
}

.spo-single-rating-link {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	color: var(--spo-muted);
	text-decoration: none;
	font-size: 13.5px;
	margin-bottom: 14px;
	width: fit-content;
}
.spo-single-rating-link:hover { color: var(--spo-text); }

.spo-single-price { margin-bottom: 16px; }
.spo-single-price .spo-price { font-size: 26px; }
.spo-single-price .spo-price-old { font-size: 15px; }

.spo-single-desc {
	color: var(--spo-muted);
	font-size: 14.5px;
	line-height: 1.7;
	margin-bottom: 22px;
}
.spo-single-desc p:first-child { margin-top: 0; }

/* ---------- Star rating (display) ---------- */
.spo-stars { display: inline-flex; gap: 1px; }
.spo-star { color: #d1d5db; font-size: 15px; line-height: 1; }
.spo-star-filled { color: #f59e0b; }

/* ---------- Related products ("You may also like") ---------- */
.spo-related {
	position: relative;
	z-index: 5;
	margin-top: 48px;
	padding-top: 32px;
	border-top: 1px solid var(--spo-glass-border, var(--spo-border));
}
.spo-related-title { font-size: 20px; }

/* Horizontal, snap-scrolling "shelf" — lets us surface a lot of related
   products (not just 4) without the page growing tall, same pattern used
   on major shopping sites so it browses like a native carousel on touch
   devices and a mouse-drag/scroll row on desktop. Also reused for the
   "New Arrivals" section on the shop wall. */
.spo-related-shelf {
	position: relative;
	margin: 0 -16px;
	padding: 0 16px;
}
.spo-related-track {
	display: flex;
	gap: 16px;
	overflow-x: auto;
	scroll-snap-type: x proximity;
	scroll-padding-left: 16px;
	padding-bottom: 6px;
	-webkit-overflow-scrolling: touch;
	scrollbar-width: thin;
}
.spo-related-track::-webkit-scrollbar { height: 6px; }
.spo-related-track::-webkit-scrollbar-thumb { background: var(--spo-glass-border, var(--spo-border)); border-radius: 999px; }
.spo-related-track::-webkit-scrollbar-track { background: transparent; }

.spo-related-card {
	flex: 0 0 auto;
	width: 200px;
	scroll-snap-align: start;
	display: flex;
	flex-direction: column;
	background: var(--spo-glass-bg);
	backdrop-filter: var(--spo-blur-related);
	-webkit-backdrop-filter: var(--spo-blur-related);
	border: 1px solid var(--spo-glass-border);
	border-radius: 12px;
	overflow: hidden;
	color: inherit;
	box-shadow: var(--spo-glass-shadow);
	transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.spo-related-card:hover {
	transform: translateY(-3px);
	border-color: var(--spo-neon-glow);
	box-shadow: 0 14px 28px rgba(31,38,135,.16), 0 0 0 1px var(--spo-neon-glow);
}
@media (max-width: 480px) {
	.spo-related-shelf { margin: 0 -16px; padding: 0 16px; }
	.spo-related-card { width: 160px; }
	.spo-related-track { gap: 12px; }
	.spo-related-actions { gap: 5px; }
	.spo-related-order-btn { font-size: 12px; padding: 8px 6px; }
	.spo-related-cart-btn { width: 30px; height: 30px; border-radius: 8px; }
	.spo-related-cart-btn svg { width: 13px; height: 13px; }
}

.spo-related-imglink { display: block; color: inherit; text-decoration: none; }
.spo-related-img { position: relative; aspect-ratio: 1 / 1; background: #f3f4f6; }
.spo-related-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.spo-related-body {
	padding: 10px 12px 12px;
	display: flex;
	flex-direction: column;
	gap: 5px;
	flex: 1;
}
.spo-related-name {
	font-size: 13.5px;
	font-weight: 700;
	margin: 0;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
	min-height: 2.6em;
}
.spo-related-imglink:hover .spo-related-name { color: var(--spo-primary-dark); }
.spo-related-rating {
	display: flex;
	align-items: center;
	gap: 5px;
	font-size: 11.5px;
	color: var(--spo-muted);
}
.spo-related-rating .spo-stars { gap: 0; }
.spo-related-rating .spo-star { font-size: 12px; }
.spo-related-price-row { display: flex; align-items: baseline; gap: 6px; flex-wrap: wrap; }
.spo-related-price {
	font-size: 15px;
	font-weight: 800;
	color: var(--spo-neon, var(--spo-primary-dark, #15803d));
	text-shadow: 0 0 10px var(--spo-neon-glow, transparent);
}
.spo-related-price-row .spo-price-old { font-size: 12px; }
.spo-related-order-btn {
	font-size: 13px;
	padding: 8px 12px;
	margin-top: 6px;
}
.spo-related-actions {
	display: flex;
	align-items: stretch;
	gap: 6px;
	margin-top: 6px;
}
.spo-related-actions .spo-related-order-btn { flex: 1; margin-top: 0; }
.spo-related-cart-btn {
	flex: 0 0 auto;
	width: 34px;
	height: 34px;
	padding: 0;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	border-radius: 10px;
	margin-top: 0;
}
.spo-related-cart-btn svg { margin: 0; vertical-align: middle; }

/* ---------- Reviews section ---------- */
.spo-reviews {
	position: relative;
	z-index: 5;
	margin-top: 48px;
	padding-top: 32px;
	border-top: 1px solid var(--spo-glass-border, var(--spo-border));
}
.spo-reviews-title {
	font-size: 20px;
	font-weight: 800;
	margin: 0 0 14px;
	background: var(--spo-title-gradient);
	-webkit-background-clip: text;
	background-clip: text;
	-webkit-text-fill-color: transparent;
	color: var(--spo-text);
}

.spo-reviews-summary {
	display: flex;
	align-items: center;
	gap: 10px;
	margin-bottom: 22px;
	flex-wrap: wrap;
}
.spo-reviews-avg { font-size: 22px; font-weight: 800; color: var(--spo-neon); text-shadow: 0 0 12px var(--spo-neon-glow); }
.spo-reviews-count { color: var(--spo-muted); font-size: 13.5px; }
.spo-reviews-empty { color: var(--spo-muted); font-size: 14px; }

.spo-reviews-list { display: flex; flex-direction: column; gap: 18px; margin-bottom: 32px; }
.spo-review-item {
	background: var(--spo-glass-bg);
	backdrop-filter: blur(14px) saturate(160%);
	-webkit-backdrop-filter: blur(14px) saturate(160%);
	border: 1px solid var(--spo-glass-border);
	border-radius: 12px;
	padding: 14px 16px;
	box-shadow: var(--spo-glass-shadow);
}
.spo-review-head { display: flex; align-items: center; gap: 10px; margin-bottom: 6px; flex-wrap: wrap; }
.spo-review-author { font-size: 14px; }
.spo-review-text { margin: 0 0 6px; font-size: 14px; line-height: 1.6; color: var(--spo-text); }
.spo-review-date { font-size: 12px; color: var(--spo-muted); }

.spo-review-form-wrap {
	background: var(--spo-glass-bg);
	backdrop-filter: blur(14px) saturate(160%);
	-webkit-backdrop-filter: blur(14px) saturate(160%);
	border: 1px solid var(--spo-glass-border);
	border-radius: var(--spo-radius);
	padding: 20px;
	max-width: 480px;
	box-shadow: var(--spo-glass-shadow);
}
.spo-review-form-wrap h3 { margin: 0 0 16px; font-size: 16px; }

.spo-star-input { display: flex; gap: 4px; margin-bottom: 4px; }
.spo-star-btn {
	appearance: none;
	background: none;
	border: none;
	font-size: 26px;
	line-height: 1;
	color: #d1d5db;
	cursor: pointer;
	padding: 2px;
}
.spo-star-btn-active { color: #f59e0b; }
