/* ==========================================================================
   WorldExpanders v6.2 — shop, category archives and product cards.
   Uses the homepage's primitives (.gwe6-sec, .gwe6-wrap, .gwe6-card, buttons)
   so the shop reads as part of the same site. Loads after v6.css.
   ========================================================================== */

.gwe6-shop, .gwe6-shop *, .gwe6-shop *::before, .gwe6-shop *::after,
.gwe6-pcards, .gwe6-pcards *, .gwe6-pcards *::before, .gwe6-pcards *::after { box-sizing: border-box; }
.gwe6-shop { overflow-x: clip; font-size: 1.0625rem; line-height: 1.6; }
.gwe6-archive .gwe-site-footer { margin-top: 0; }

/* ---------- Header band ---------- */
.gwe6-shop-head { padding: clamp(32px, 6vw, 76px) 0 clamp(22px, 3.5vw, 36px); border-bottom: 1px solid var(--gwe-line); }
.gwe6-shop-head-grid { display: grid; gap: 2rem; align-items: center; }
.gwe6-shop-head-copy { max-width: 720px; }
.gwe6 .gwe6-shop-title { font-size: clamp(2.1rem, 5vw, 3.3rem); line-height: 1.05; letter-spacing: -.02em; margin: 0 0 .75rem; color: var(--gwe-ink); }
.gwe6-shop-head .gwe6-sub { margin: 0; }
.gwe6-shop-head .gwe6-micro { margin-top: 1.15rem; }
.gwe6-shop-head .gwe6-kicker a { color: inherit; text-decoration: none; }
.gwe6-shop-head .gwe6-kicker a:hover { text-decoration: underline; text-underline-offset: .2em; }
.gwe6-shop-head .gwe6-kicker span { opacity: .6; margin-left: .15em; }
.gwe6-shop-photo { display: none; margin: 0; }
.gwe6-shop-photo img { aspect-ratio: 1; object-fit: cover; transform: rotate(1.6deg); }
@media (min-width: 760px) {
	.gwe6-shop-head.has-photo .gwe6-shop-head-grid { grid-template-columns: 1fr 230px; gap: clamp(2rem, 6vw, 5rem); }
	.gwe6-shop-photo { display: block; }
}
@media (min-width: 1100px) { .gwe6-shop-head.has-photo .gwe6-shop-head-grid { grid-template-columns: 1fr 260px; } }

/* ---------- Subject filter ---------- */
.gwe6-pills {
	display: flex; gap: .55rem;
	margin: clamp(1.4rem, 3vw, 2rem) calc(-1 * var(--gwe6-gutter)) 0;
	padding: .2rem var(--gwe6-gutter) .4rem;
	overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch;
	scroll-snap-type: x proximity;
}
.gwe6-pills::-webkit-scrollbar { display: none; }
.gwe6-pill {
	flex: 0 0 auto; scroll-snap-align: start;
	display: inline-flex; align-items: center; gap: .4em;
	min-height: 44px; padding: .5em 1.1em;
	background: var(--gwe-white); color: var(--gwe-ink) !important;
	border: 1.5px solid rgba(46, 42, 36, .28); border-radius: 999px;
	font-family: var(--gwe-font-body); font-size: .9375rem; font-weight: 800; line-height: 1.2;
	text-decoration: none !important; white-space: nowrap;
	transition: background-color .15s ease, border-color .15s ease, color .15s ease;
}
.gwe6-pill:hover { border-color: var(--gwe-green); color: var(--gwe-green) !important; }
.gwe6-pill.is-active { background: var(--gwe-green); border-color: var(--gwe-green); color: #fff !important; }
.gwe6-pill .gwe-icon { width: 1.05em; height: 1.05em; }
.gwe6-pill--wing { background: transparent; border-style: dashed; border-color: var(--gwe-ochre); color: var(--gwe-ochre) !important; }
.gwe6-pill--wing:hover { color: var(--gwe-ochre) !important; background: rgba(181, 118, 46, .08); border-color: var(--gwe-ochre); }
.gwe6-pill--wing.is-active { background: var(--gwe-ochre); border-style: solid; color: #fff !important; }
@media (min-width: 860px) {
	.gwe6-pills { flex-wrap: wrap; overflow: visible; margin-left: 0; margin-right: 0; padding-left: 0; padding-right: 0; }
	.gwe6-pill--wing { margin-left: auto; }
}

/* ---------- Grid section ---------- */
.gwe6-shop-body { padding: clamp(28px, 5vw, 60px) 0 var(--gwe6-space); }
.gwe6-shop-notices:empty { display: none; }
.gwe6-shop-notices { margin-bottom: 1.4rem; }

/* ---------- Product cards (every loop) ---------- */
ul.gwe6-pcards {
	list-style: none; margin: 0; padding: 0;
	display: grid; gap: 14px; grid-template-columns: repeat(2, minmax(0, 1fr));
}
/* WooCommerce's clearfix (.products ul::before/::after) would occupy grid cells */
ul.gwe6-pcards::before, ul.gwe6-pcards::after { content: none !important; display: none !important; }
.related.products ul.gwe6-pcards, .up-sells ul.gwe6-pcards { display: grid; overflow: visible; padding: 0; margin: 0; }
@media (min-width: 620px) { ul.gwe6-pcards { gap: var(--gwe6-gap); } }
@media (min-width: 900px) { ul.gwe6-pcards { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 1180px) {
	ul.gwe6-pcards--shop, ul.gwe6-pcards--related { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (min-width: 900px) and (max-width: 1179px) { ul.gwe6-pcards--related { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; } }

.gwe6-pcard { margin: 0; padding: 0; width: auto; float: none; }
.gwe6-pcard::before { content: none; }
.gwe6-pcard .gwe6-card-img { aspect-ratio: 1 / 1; }
.gwe6-pcard .gwe6-card-img img { height: 100%; margin: 0; border: 0; border-radius: 0; box-shadow: none; transition: transform .35s ease; }
.gwe6-pcard a:hover .gwe6-card-img img { transform: scale(1.035); }
.gwe6-pcard .gwe6-card-body { gap: .3rem; padding: .8rem .85rem .85rem; }
.gwe6-pcard-cat {
	font-size: .6875rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; line-height: 1.3;
	color: var(--gwe-ochre);
	overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.gwe6 .gwe6-pcard .gwe6-card-title { font-size: 1.0625rem; line-height: 1.22; letter-spacing: -.005em; color: var(--gwe-ink); }
.gwe6-pcard .gwe6-card-foot { padding-top: .6rem; min-height: 0; border-top: 1px dashed var(--gwe-line); }
.gwe6-pcard .gwe6-card-price { font-size: 1.125rem; line-height: 1; color: var(--gwe-ink); }
.gwe6-pcard .gwe6-card-price del { font-size: .72em; font-weight: 700; opacity: .5; margin-right: .2em; }
.gwe6-pcard .gwe6-card-price ins { text-decoration: none; }
.gwe6-pcard.is-wing .gwe6-card-price { color: var(--gwe-ochre); }
.gwe6-pcard-go {
	flex: 0 0 auto; display: inline-flex; align-items: center; justify-content: center;
	width: 30px; height: 30px; border-radius: 50%;
	border: 1.5px solid var(--gwe-green); color: var(--gwe-green);
	font-weight: 800; font-size: .95rem; line-height: 1;
	transition: background-color .15s ease, color .15s ease;
}
.gwe6-pcard a:hover .gwe6-pcard-go { background: var(--gwe-green); color: #fff; }
.gwe6-pcard.is-wing .gwe6-pcard-go { border-color: var(--gwe-ochre); color: var(--gwe-ochre); }
.gwe6-pcard.is-wing a:hover .gwe6-pcard-go { background: var(--gwe-ochre); color: #fff; }
@media (min-width: 620px) {
	.gwe6-pcard .gwe6-card-body { padding: 1rem 1.1rem 1.05rem; gap: .4rem; }
	.gwe6-pcard-cat { font-size: .75rem; }
	.gwe6 .gwe6-pcard .gwe6-card-title { font-size: 1.2rem; }
	.gwe6-pcard .gwe6-card-price { font-size: 1.3rem; }
	.gwe6-pcard-go { width: 34px; height: 34px; }
}

/* Drawn cover — shown until a product has its own photo */
.gwe6-cover {
	position: relative; display: flex; width: 100%; height: 100%; padding: 9%;
	background-color: var(--gwe-green); background-image: var(--gwe-noise);
	box-shadow: inset 12px 0 0 rgba(0, 0, 0, .16), inset 14px 0 0 rgba(255, 255, 255, .06);
	transition: transform .35s ease;
}
.gwe6-pcard a:hover .gwe6-cover { transform: scale(1.035); }
.gwe6-cover-inner {
	flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .7rem;
	padding: 8% 6%;
	border: 1.5px solid rgba(231, 201, 139, .55); outline: 1px solid rgba(231, 201, 139, .25); outline-offset: 4px;
	text-align: center; color: var(--gwe6-gold);
}
.gwe6-cover .gwe-icon { width: 30%; max-width: 54px; height: auto; aspect-ratio: 1; opacity: .9; }
.gwe6-cover-title {
	font-family: var(--gwe-font-hand); font-weight: 700;
	font-size: clamp(1.15rem, 3.6vw, 1.7rem); line-height: 1.05;
	color: #f3e5c2; text-wrap: balance;
	display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
@media (min-width: 900px) { .gwe6-cover-title { font-size: clamp(1.25rem, 1.9vw, 1.75rem); } }
.gwe6-cover--wing { background-color: var(--gwe-kraft); box-shadow: none; }
.gwe6-cover--wing .gwe6-cover-inner { border: 2px dashed var(--gwe-ochre); outline: 0; color: var(--gwe-ochre); }
.gwe6-cover--wing .gwe6-cover-title { color: var(--gwe-ink); }

/* ---------- Free-Wing band ---------- */
.gwe6-shop-wing {
	display: grid; grid-template-columns: 56px 1fr; gap: .9rem 1rem; align-items: center;
	margin: clamp(2.4rem, 5vw, 3.6rem) 0 0; padding: 1.2rem 1.25rem;
	background-color: var(--gwe-kraft); background-image: var(--gwe-noise);
	border: 2px dashed var(--gwe-ochre);
}
.gwe6-shop-body .gwe6-shop-wing:first-child, .gwe6-shop-notices + .gwe6-shop-wing { margin: 0 0 clamp(1.6rem, 4vw, 2.4rem); }
.gwe6-shop-wing-mark {
	display: flex; align-items: center; justify-content: center;
	width: 56px; height: 56px; border-radius: 50%; overflow: hidden;
	background: var(--gwe-white); color: var(--gwe-ochre); box-shadow: 0 0 0 3px rgba(181, 118, 46, .25);
}
.gwe6-shop-wing-mark .gwe-icon { width: 26px; height: 26px; }
.gwe6-shop-wing-mark img { width: 100%; height: 100%; object-fit: cover; }
.gwe6-shop-wing-copy strong { display: block; font-family: var(--gwe-font-display); font-weight: 800; font-size: 1.2rem; line-height: 1.25; color: var(--gwe-ink); }
.gwe6-shop-wing-copy span { display: block; margin-top: .15rem; font-size: 1rem; line-height: 1.45; color: var(--gwe-ink-soft); }
.gwe6-shop-wing .gwe6-btn { grid-column: 1 / -1; width: 100%; }
@media (min-width: 760px) {
	.gwe6-shop-wing { grid-template-columns: 64px 1fr auto; gap: 1.4rem; padding: 1.4rem 1.8rem; }
	.gwe6-shop-wing-mark { width: 64px; height: 64px; }
	.gwe6-shop-wing .gwe6-btn { grid-column: auto; width: auto; white-space: nowrap; }
}

/* ---------- Closing line, pager, empty ---------- */
.gwe6-shop-closing {
	display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: .2rem .9rem;
	margin: clamp(2rem, 4vw, 3rem) 0 0; text-align: center; color: var(--gwe-ink-soft); font-size: 1.0625rem;
}
.gwe6-pager { margin: clamp(2rem, 4vw, 3rem) 0 0; }
.gwe6-pager ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; justify-content: center; gap: .45rem; }
.gwe6-pager a, .gwe6-pager span {
	display: inline-flex; align-items: center; justify-content: center;
	min-width: 44px; min-height: 44px; padding: 0 .9rem;
	border: 1.5px solid rgba(46, 42, 36, .28); border-radius: 999px; background: var(--gwe-white);
	font-weight: 800; font-size: .9375rem; color: var(--gwe-ink); text-decoration: none;
}
.gwe6-pager a:hover { border-color: var(--gwe-green); color: var(--gwe-green); }
.gwe6-pager .current { background: var(--gwe-green); border-color: var(--gwe-green); color: #fff; }
.gwe6-pager .dots { border: 0; background: none; min-width: 0; padding: 0 .2rem; }
.gwe6-shop-empty { max-width: 520px; margin: 0 auto; padding: 2.4rem 1.4rem; text-align: center; border: 2px dashed var(--gwe-line); }
.gwe6-shop-empty .gwe-icon { width: 48px; height: 48px; color: var(--gwe-green); }
.gwe6-shop-empty p { margin: .6rem 0 1.2rem; color: var(--gwe-ink-soft); }

/* ---------- "You may also like" on product pages ---------- */
.related.products > h2, .up-sells.upsells > h2 {
	font-family: var(--gwe-font-display); font-weight: 800;
	font-size: clamp(1.6rem, 3.2vw, 2.2rem); letter-spacing: -.015em; line-height: 1.1;
	margin: 0 0 1.4rem; text-align: left;
}
.related.products > h2 .gwe-icon, .up-sells.upsells > h2 .gwe-icon { display: none; }

/* Replaces WooCommerce's grey "Awaiting product image" everywhere (cart, mini-cart, small thumbs).
   The compass is a CSS background so it survives HTML sanitising (wp_kses). */
.gwe6-noimg {
	display: flex; width: 100%; max-width: 100%;
	background-color: var(--gwe-kraft);
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23b5762e' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='9'/%3E%3Cpath d='m15.5 8.5-2 5-5 2 2-5 5-2Z'/%3E%3C/svg%3E"), var(--gwe-noise);
	background-repeat: no-repeat, repeat; background-position: center, 0 0; background-size: 40% auto, auto;
}
