/*
Theme Name: Fashion Shuffle
Theme URI: https://example.com/fashion-shuffle
Author: Dinesh
Author URI: https://example.com
Description: A lightweight WooCommerce fashion theme. The homepage automatically shuffles section order, products within each section, and promotional banners on every page load. Just add products in WooCommerce — no manual homepage building required.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.7
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: LICENSE
Text Domain: fashion-shuffle
Tags: e-commerce, woocommerce, custom-menu, featured-images, translation-ready

Fashion Shuffle is a standalone theme built for WooCommerce fashion stores.
*/

/* =========================================================
   RESET & BASE
   ========================================================= */
*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
	margin: 0;
	font-family: 'Helvetica Neue', Arial, sans-serif;
	font-size: 16px;
	line-height: 1.6;
	color: #1a1a1a;
	background: #ffffff;
}

img { max-width: 100%; height: auto; display: block; }

a {
	color: #1a1a1a;
	text-decoration: none;
	transition: color 0.2s ease;
}
a:hover { color: #b8894f; }

ul { list-style: none; margin: 0; padding: 0; }

h1, h2, h3, h4 {
	font-family: 'Helvetica Neue', Arial, sans-serif;
	font-weight: 600;
	letter-spacing: 0.02em;
	margin: 0 0 0.6em;
}

.container {
	max-width: 1240px;
	margin: 0 auto;
	padding: 0 24px;
}

.screen-reader-text {
	position: absolute;
	width: 1px; height: 1px;
	overflow: hidden;
	clip: rect(1px, 1px, 1px, 1px);
}

/* =========================================================
   HEADER
   ========================================================= */
.site-header {
	border-bottom: 1px solid #eee;
	position: sticky;
	top: 0;
	background: #fff;
	z-index: 100;
}

.site-header-inner {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 18px 24px;
	gap: 24px;
	flex-wrap: wrap;
}

.site-branding .site-title {
	font-size: 26px;
	margin: 0;
	text-transform: uppercase;
	letter-spacing: 0.12em;
}

.site-branding .site-title a { color: #1a1a1a; }

.site-branding .site-description {
	margin: 2px 0 0;
	font-size: 12px;
	letter-spacing: 0.08em;
	color: #888;
	text-transform: uppercase;
}

.main-navigation ul {
	display: flex;
	gap: 28px;
	flex-wrap: wrap;
}

.main-navigation a {
	font-size: 14px;
	text-transform: uppercase;
	letter-spacing: 0.06em;
}

.header-icons {
	display: flex;
	align-items: center;
	gap: 18px;
}

.header-icons a {
	font-size: 14px;
	text-transform: uppercase;
	letter-spacing: 0.05em;
}

.cart-count {
	display: inline-block;
	background: #1a1a1a;
	color: #fff;
	border-radius: 50%;
	font-size: 11px;
	width: 18px;
	height: 18px;
	line-height: 18px;
	text-align: center;
	margin-left: 4px;
}

.menu-toggle {
	display: none;
	background: none;
	border: 1px solid #1a1a1a;
	padding: 8px 12px;
	cursor: pointer;
	font-size: 14px;
}

@media (max-width: 780px) {
	.main-navigation { width: 100%; order: 3; display: none; }
	.main-navigation.is-open { display: block; }
	.main-navigation ul { flex-direction: column; gap: 12px; padding: 16px 0; }
	.menu-toggle { display: inline-block; }
}

/* =========================================================
   BANNERS / HERO SLIDER (shuffled)
   ========================================================= */
.fs-banner-strip {
	position: relative;
	overflow: hidden;
	background: #f4f1ec;
}

.fs-banner-slide {
	display: none;
	position: relative;
	min-height: 340px;
}

.fs-banner-slide.is-active { display: block; }

.fs-banner-slide img {
	width: 100%;
	height: 420px;
	object-fit: cover;
}

.fs-banner-caption {
	position: absolute;
	left: 6%;
	bottom: 12%;
	background: rgba(255,255,255,0.9);
	padding: 20px 28px;
	max-width: 420px;
}

.fs-banner-caption h2 {
	font-size: 28px;
	margin-bottom: 8px;
}

.fs-banner-caption a.fs-btn {
	display: inline-block;
	margin-top: 10px;
}

.fs-banner-dots {
	position: absolute;
	bottom: 18px;
	right: 24px;
	display: flex;
	gap: 8px;
}

.fs-banner-dots button {
	width: 9px; height: 9px;
	border-radius: 50%;
	border: 1px solid #1a1a1a;
	background: transparent;
	cursor: pointer;
	padding: 0;
}

.fs-banner-dots button.is-active { background: #1a1a1a; }

@media (max-width: 600px) {
	.fs-banner-slide img { height: 260px; }
	.fs-banner-caption { left: 5%; right: 5%; max-width: none; padding: 14px 18px; }
	.fs-banner-caption h2 { font-size: 20px; }
}

/* =========================================================
   BUTTONS
   ========================================================= */
.fs-btn, .woocommerce a.button, .woocommerce button.button, .woocommerce #respond input#submit {
	display: inline-block;
	background: #1a1a1a;
	color: #fff !important;
	border: 1px solid #1a1a1a;
	padding: 12px 26px;
	font-size: 13px;
	text-transform: uppercase;
	letter-spacing: 0.08em;
	cursor: pointer;
	border-radius: 0;
	transition: all 0.2s ease;
}

.fs-btn:hover, .woocommerce a.button:hover, .woocommerce button.button:hover {
	background: #fff;
	color: #1a1a1a !important;
}

.fs-btn-outline {
	background: transparent;
	color: #1a1a1a !important;
}

/* =========================================================
   PRODUCT SECTIONS (shuffled order + shuffled products)
   ========================================================= */
.fs-section {
	padding: 56px 0;
}

.fs-section:nth-child(even) { background: #fafaf8; }

.fs-section-header {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	margin-bottom: 28px;
	flex-wrap: wrap;
	gap: 12px;
}

.fs-section-header h2 {
	font-size: 24px;
	text-transform: uppercase;
	letter-spacing: 0.06em;
}

.fs-section-header .fs-section-link {
	font-size: 13px;
	text-transform: uppercase;
	letter-spacing: 0.05em;
	border-bottom: 1px solid #1a1a1a;
	padding-bottom: 2px;
}

.fs-product-grid {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 28px;
}

@media (max-width: 980px) {
	.fs-product-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 700px) {
	.fs-product-grid { grid-template-columns: repeat(2, 1fr); gap: 16px; }
}

.fs-product-card {
	position: relative;
}

.fs-product-thumb {
	position: relative;
	overflow: hidden;
	background: #f2f2f0;
	aspect-ratio: 3/4;
}

.fs-product-thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 0.4s ease;
}

.fs-product-card:hover .fs-product-thumb img { transform: scale(1.05); }

.fs-badge {
	position: absolute;
	top: 10px;
	left: 10px;
	background: #b8894f;
	color: #fff;
	font-size: 11px;
	text-transform: uppercase;
	letter-spacing: 0.05em;
	padding: 4px 10px;
}

.fs-product-title {
	margin-top: 12px;
	font-size: 14px;
	font-weight: 500;
	text-transform: none;
}

.fs-product-price {
	font-size: 14px;
	color: #555;
	margin-top: 4px;
}

.fs-product-price del { color: #aaa; margin-right: 6px; }
.fs-product-price ins { text-decoration: none; color: #b8894f; }

.fs-empty-section {
	color: #999;
	font-size: 14px;
}

/* =========================================================
   FOOTER
   ========================================================= */
.site-footer {
	background: #1a1a1a;
	color: #ddd;
	padding: 48px 0 24px;
	margin-top: 40px;
}

.footer-columns {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 32px;
}

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

.footer-columns h3 {
	color: #fff;
	font-size: 14px;
	text-transform: uppercase;
	letter-spacing: 0.06em;
	margin-bottom: 16px;
}

.footer-columns li { margin-bottom: 8px; font-size: 13px; }
.footer-columns a { color: #bbb; }
.footer-columns a:hover { color: #fff; }

.footer-bottom {
	border-top: 1px solid #333;
	margin-top: 32px;
	padding-top: 20px;
	text-align: center;
	font-size: 12px;
	color: #888;
}

/* =========================================================
   WOOCOMMERCE GENERIC OVERRIDES
   ========================================================= */
.woocommerce ul.products { display: contents; }
.woocommerce ul.products li.product { margin: 0; }

.woocommerce-message, .woocommerce-info, .woocommerce-error {
	border-top-color: #1a1a1a !important;
}

.woocommerce-message::before, .woocommerce-info::before { color: #1a1a1a !important; }

.page-content-wrap { padding: 48px 0; }

/* =========================================================
   v2.0 — MARKETPLACE COMPONENTS
   ========================================================= */

/* Header search + nav row */
.fs-search {
	flex: 1 1 320px;
	max-width: 520px;
	display: flex;
	border: 1px solid #ddd;
	border-radius: 4px;
	overflow: hidden;
	background: #f7f7f7;
}
.fs-search input[type="search"] {
	flex: 1;
	border: 0;
	background: transparent;
	padding: 11px 14px;
	font-size: 14px;
	outline: none;
}
.fs-search button {
	border: 0;
	background: #1a1a1a;
	color: #fff;
	padding: 0 18px;
	cursor: pointer;
	font-size: 16px;
}

.fs-header-link { position: relative; }

.fs-wish-count, .cart-count {
	display: inline-block;
	background: #b8894f;
	color: #fff;
	border-radius: 50%;
	font-size: 11px;
	min-width: 18px;
	height: 18px;
	line-height: 18px;
	text-align: center;
	margin-left: 2px;
	padding: 0 4px;
}

.main-navigation {
	border-top: 1px solid #f0f0f0;
	background: #fff;
}
.main-navigation .container {
	display: flex;
}
.main-navigation ul {
	display: flex;
	gap: 28px;
	flex-wrap: wrap;
	padding: 12px 0;
}

@media (max-width: 820px) {
	.fs-search { order: 4; flex-basis: 100%; max-width: none; }
	.main-navigation { display: none; }
	.main-navigation.is-open { display: block; }
	.main-navigation ul { flex-direction: column; gap: 10px; }
}

/* Category strip */
.fs-cat-strip {
	background: #fff;
	border-bottom: 1px solid #eee;
	padding: 16px 0;
}
.fs-cat-track {
	display: flex;
	gap: 26px;
	overflow-x: auto;
	scrollbar-width: none;
	-ms-overflow-style: none;
	padding-bottom: 4px;
}
.fs-cat-track::-webkit-scrollbar { display: none; }
.fs-cat-item {
	flex: 0 0 auto;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 8px;
	width: 84px;
	text-align: center;
}
.fs-cat-thumb {
	width: 64px;
	height: 64px;
	border-radius: 50%;
	overflow: hidden;
	background: #f2efe9;
	display: flex;
	align-items: center;
	justify-content: center;
	border: 1px solid #eee;
	transition: transform 0.2s ease;
}
.fs-cat-item:hover .fs-cat-thumb { transform: translateY(-3px); }
.fs-cat-thumb img { width: 100%; height: 100%; object-fit: cover; }
.fs-cat-initial { font-size: 24px; font-weight: 600; color: #b8894f; }
.fs-cat-name {
	font-size: 12px;
	color: #333;
	line-height: 1.2;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
	max-width: 84px;
}

/* Hero */
.fs-hero {
	position: relative;
	overflow: hidden;
	background: #f4f1ec;
}
.fs-hero-slide { display: none; position: relative; }
.fs-hero-slide.is-active { display: block; }
.fs-hero-media img {
	width: 100%;
	height: 440px;
	object-fit: cover;
}
.fs-hero-caption {
	position: absolute;
	left: 6%;
	bottom: 12%;
	background: rgba(255,255,255,0.92);
	padding: 22px 30px;
	max-width: 440px;
}
.fs-hero-caption h2 { font-size: 30px; margin-bottom: 6px; }
.fs-hero-caption p { margin: 0 0 12px; color: #444; }
.fs-hero-dots {
	position: absolute;
	bottom: 18px;
	right: 24px;
	display: flex;
	gap: 8px;
}
.fs-hero-dots button {
	width: 9px; height: 9px;
	border-radius: 50%;
	border: 1px solid #1a1a1a;
	background: transparent;
	cursor: pointer;
	padding: 0;
}
.fs-hero-dots button.is-active { background: #1a1a1a; }

@media (max-width: 600px) {
	.fs-hero-media img { height: 260px; }
	.fs-hero-caption { left: 4%; right: 4%; max-width: none; padding: 14px 18px; }
	.fs-hero-caption h2 { font-size: 20px; }
}

/* Feed section shell */
.fs-feed-section, .fs-feed-deal, .fs-feed-cta, .fs-feed-split {
	padding: 40px 0;
	border-bottom: 1px solid #f0f0f0;
}
.fs-feed-section:nth-of-type(even) { background: #fafaf8; }

.fs-section-head {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	margin-bottom: 22px;
	flex-wrap: wrap;
	gap: 10px;
}
.fs-section-head h2 {
	font-size: 22px;
	text-transform: uppercase;
	letter-spacing: 0.04em;
}
.fs-see-all {
	font-size: 13px;
	text-transform: uppercase;
	letter-spacing: 0.05em;
	border-bottom: 1px solid #1a1a1a;
	padding-bottom: 2px;
}

/* Product card */
.fs-card {
	position: relative;
	background: #fff;
	border: 1px solid #eee;
	border-radius: 6px;
	overflow: hidden;
	transition: box-shadow 0.2s ease, transform 0.2s ease;
	display: flex;
	flex-direction: column;
}
.fs-card:hover {
	box-shadow: 0 8px 24px rgba(0,0,0,0.08);
	transform: translateY(-3px);
}
.fs-card-thumb {
	position: relative;
	aspect-ratio: 3/4;
	background: #f4f4f2;
	overflow: hidden;
}
.fs-card-thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 0.4s ease;
}
.fs-card:hover .fs-card-thumb img { transform: scale(1.06); }

.fs-badge {
	position: absolute;
	top: 10px;
	left: 10px;
	font-size: 11px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.04em;
	padding: 4px 8px;
	border-radius: 3px;
	z-index: 2;
}
.fs-badge--deal { background: #e64a19; color: #fff; }
.fs-badge--new { background: #1a1a1a; color: #fff; }

.fs-wish {
	position: absolute;
	top: 8px;
	right: 8px;
	width: 34px;
	height: 34px;
	border-radius: 50%;
	border: none;
	background: rgba(255,255,255,0.9);
	cursor: pointer;
	z-index: 3;
	display: flex;
	align-items: center;
	justify-content: center;
	box-shadow: 0 1px 4px rgba(0,0,0,0.15);
	transition: transform 0.15s ease;
}
.fs-wish:hover { transform: scale(1.1); }
.fs-heart { color: #ccc; font-size: 18px; line-height: 1; transition: color 0.15s ease; }
.fs-wish.is-active .fs-heart { color: #e0245e; }

.fs-card-body { padding: 12px 12px 14px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.fs-card-title {
	font-size: 13.5px;
	color: #222;
	line-height: 1.35;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
	min-height: 2.7em;
}
.fs-card-price { font-size: 15px; font-weight: 600; color: #1a1a1a; }
.fs-card-price del { color: #aaa; font-weight: 400; font-size: 13px; margin-right: 6px; }
.fs-card-price ins { text-decoration: none; color: #1a1a1a; }

.fs-card-meta {
	display: flex;
	align-items: center;
	gap: 10px;
	font-size: 12px;
	color: #777;
	min-height: 16px;
}
.fs-rating {
	display: inline-flex;
	align-items: center;
	gap: 3px;
	background: #2e7d32;
	color: #fff;
	padding: 1px 6px;
	border-radius: 3px;
	font-size: 11px;
}
.fs-star { font-size: 10px; }
.fs-rating-count { opacity: 0.85; margin-left: 2px; }
.fs-sold { color: #888; }

.fs-add-cart {
	margin-top: 4px;
	text-align: center;
	font-size: 12px !important;
	padding: 9px 14px !important;
	width: 100%;
}
.fs-add-cart.added { opacity: 0.7; }

/* Grids */
.fs-grid {
	display: grid;
	grid-template-columns: repeat(5, 1fr);
	gap: 20px;
}
.fs-grid--spotlight { grid-template-columns: repeat(3, 1fr); }
.fs-grid--2 { grid-template-columns: repeat(2, 1fr); gap: 14px; }

@media (max-width: 1100px) { .fs-grid { grid-template-columns: repeat(4, 1fr); } }
@media (max-width: 900px)  { .fs-grid { grid-template-columns: repeat(3, 1fr); } .fs-grid--spotlight { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 620px)  { .fs-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; } }

/* Carousel */
.fs-carousel { position: relative; }
.fs-carousel-track {
	display: flex;
	gap: 18px;
	overflow-x: auto;
	scroll-snap-type: x mandatory;
	scrollbar-width: none;
	padding-bottom: 6px;
}
.fs-carousel-track::-webkit-scrollbar { display: none; }
.fs-carousel-track > .fs-card {
	flex: 0 0 220px;
	scroll-snap-align: start;
}
.fs-carousel-nav {
	position: absolute;
	top: 40%;
	transform: translateY(-50%);
	width: 40px;
	height: 40px;
	border-radius: 50%;
	border: 1px solid #ddd;
	background: #fff;
	cursor: pointer;
	font-size: 20px;
	z-index: 4;
	box-shadow: 0 2px 8px rgba(0,0,0,0.12);
	display: flex;
	align-items: center;
	justify-content: center;
}
.fs-carousel-nav.fs-prev { left: -8px; }
.fs-carousel-nav.fs-next { right: -8px; }
@media (max-width: 620px) { .fs-carousel-nav { display: none; } .fs-carousel-track > .fs-card { flex-basis: 160px; } }

/* Deal of the day */
.fs-feed-deal { background: linear-gradient(180deg, #fff7f2 0%, #fafaf8 100%); }
.fs-deal-head { align-items: center; }
.fs-countdown {
	font-size: 13px;
	color: #e64a19;
	background: #fff;
	border: 1px solid #ffccbc;
	padding: 6px 12px;
	border-radius: 4px;
}
.fs-countdown b { font-variant-numeric: tabular-nums; letter-spacing: 0.5px; }
.fs-deal-wrap {
	display: grid;
	grid-template-columns: 1.1fr 2fr;
	gap: 24px;
}
.fs-deal-feature .fs-card { height: 100%; }
.fs-deal-feature .fs-card-thumb { aspect-ratio: 1/1; }
.fs-deal-side {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 16px;
}
@media (max-width: 900px) {
	.fs-deal-wrap { grid-template-columns: 1fr; }
	.fs-deal-side { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 620px) { .fs-deal-side { grid-template-columns: repeat(2, 1fr); } }

/* Banner CTA */
.fs-feed-cta { padding: 24px 0; }
.fs-cta-card {
	display: block;
	position: relative;
	min-height: 240px;
	border-radius: 10px;
	overflow: hidden;
	background-size: cover;
	background-position: center;
}
.fs-cta-card::before {
	content: '';
	position: absolute;
	inset: 0;
	background: linear-gradient(90deg, rgba(0,0,0,0.55) 0%, rgba(0,0,0,0.15) 60%, rgba(0,0,0,0) 100%);
}
.fs-cta-inner {
	position: relative;
	z-index: 2;
	color: #fff;
	padding: 40px;
	max-width: 480px;
}
.fs-cta-kicker {
	display: inline-block;
	background: #e64a19;
	padding: 4px 12px;
	border-radius: 3px;
	font-size: 12px;
	text-transform: uppercase;
	letter-spacing: 0.05em;
	margin-bottom: 12px;
}
.fs-cta-inner h3 { color: #fff; font-size: 28px; margin-bottom: 16px; }
.fs-cta-inner .fs-btn { background: #fff; color: #1a1a1a !important; border-color: #fff; }
@media (max-width: 600px) { .fs-cta-inner { padding: 24px; } .fs-cta-inner h3 { font-size: 20px; } }

/* Split */
.fs-split-wrap { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; }
@media (max-width: 820px) { .fs-split-wrap { grid-template-columns: 1fr; gap: 24px; } }

/* Compact */
.fs-compact-track {
	display: flex;
	gap: 16px;
	overflow-x: auto;
	scrollbar-width: none;
	padding-bottom: 6px;
}
.fs-compact-track::-webkit-scrollbar { display: none; }
.fs-card--compact { flex: 0 0 150px; }
.fs-card--compact .fs-card-thumb { aspect-ratio: 1/1; }
.fs-card--compact .fs-card-title { font-size: 12.5px; min-height: 2.5em; }
.fs-card--compact .fs-add-cart { display: none; }

/* Feed status / sentinel */
.fs-feed-sentinel { height: 1px; }
.fs-feed-status {
	text-align: center;
	padding: 28px 0 48px;
	color: #999;
	font-size: 14px;
}

/* Wishlist-only view (toggled from header). Uses :has() where supported;
   degrades gracefully to "no filter" on older browsers — the heart toggle
   itself still works everywhere. */
@supports selector(.a:has(.b)) {
	body.fs-show-wishlist-only .fs-feed-section .fs-card:not(:has(.fs-wish.is-active)),
	body.fs-show-wishlist-only .fs-feed-deal .fs-card:not(:has(.fs-wish.is-active)),
	body.fs-show-wishlist-only .fs-feed-split .fs-card:not(:has(.fs-wish.is-active)) { display: none; }
	body.fs-show-wishlist-only .fs-hero,
	body.fs-show-wishlist-only .fs-cat-strip,
	body.fs-show-wishlist-only .fs-feed-cta { display: none; }
}
