/* Éluwa shop, version 2 (template-shop-v2.php + shop-v2.js).
   Loaded on that page only, after main.css; every class starts with v2. */

.v2 { --v2-max: 1320px; --v2-bar-top: var(--header-h); padding-bottom: 110px; }
.admin-bar .v2 { --v2-bar-top: calc(var(--header-h) + 32px); }

/* ── Hero: a few words on sand beside a photograph ─────────────────────── */
.v2hero { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); background: var(--sand); }
.v2hero__text { display: flex; flex-direction: column; justify-content: center; padding: clamp(48px, 6vw, 96px) clamp(28px, 5vw, 80px) clamp(48px, 6vw, 96px) var(--pad); }
.v2hero__eyebrow { margin: 0 0 18px; font-size: 11px; letter-spacing: .24em; text-transform: uppercase; color: var(--ink-3); }
.v2hero__title { margin: 0; font-family: var(--f-palmer); font-weight: 400; font-size: clamp(40px, 4.6vw, 68px); line-height: 1.04; }
.v2hero__lede { max-width: 400px; margin: 22px 0 0; font-family: var(--f-ui); font-size: 15px; line-height: 1.7; color: var(--ink-3); }
.v2hero__media { position: relative; min-height: clamp(320px, 32vw, 460px); }
.v2hero__media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 64%; }

/* ── The bar under the header: collections, search, filter ─────────────── */
.v2bar { position: sticky; top: var(--v2-bar-top); z-index: 40; background: rgba(255, 255, 255, .96); border-bottom: 1px solid var(--line); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); }
.v2bar__in { display: flex; align-items: center; gap: 24px; width: min(var(--v2-max), 100%); margin: 0 auto; padding: 0 var(--pad); }
.v2pills { display: flex; gap: 20px; flex: 1 1 auto; min-width: 0; overflow-x: auto; scrollbar-width: none; }
/* More collections than fit: the row scrolls, and fades at the edge while there is more (shop-v2.js sets is-more). */
.v2pills.is-more { -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 40px), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 40px), transparent); }
.v2pills::-webkit-scrollbar { display: none; }
.v2pill { flex: none; margin-bottom: -1px; padding: 23px 0 21px; border-bottom: 1px solid transparent; font-size: 12px; line-height: 18px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); transition: color .2s, border-color .2s; }
.v2pill:hover { color: var(--ink); }
.v2pill[aria-current="true"] { color: var(--ink); border-bottom-color: var(--ink); }
.v2pill:focus-visible { outline-offset: -2px; }
.v2bar__tools { display: flex; align-items: center; gap: 14px; flex: none; }

.v2search { position: relative; display: flex; align-items: center; width: clamp(150px, 13vw, 200px); }
.v2search__icon { position: absolute; left: 0; width: 20px; height: 20px; color: var(--ink-3); pointer-events: none; }
.v2 .v2search__input { width: 100%; height: 40px; padding: 0 2px 0 30px; border: 0; border-bottom: 1px solid var(--line); border-radius: 0; background: transparent; font-size: 13px; letter-spacing: .02em; -webkit-appearance: none; appearance: none; transition: border-color .2s, box-shadow .2s; }
.v2 .v2search__input::placeholder { color: var(--muted); font-size: 12px; letter-spacing: .12em; text-transform: uppercase; opacity: 1; }
.v2 .v2search__input:focus { outline: none; border-bottom-color: var(--ink); box-shadow: 0 1px 0 var(--ink); }

.v2filter { display: inline-flex; align-items: center; gap: 8px; height: 40px; padding: 0 16px; border: 1px solid var(--ink); background: #fff; font-size: 12px; letter-spacing: .12em; text-transform: uppercase; transition: background .2s, color .2s; }
.v2filter .icon { width: 18px; height: 18px; }
.v2filter:hover { background: var(--ink); color: #fff; }
.v2filter__n { display: inline-grid; place-items: center; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--ink); color: #fff; font-size: 10px; line-height: 1; letter-spacing: 0; }
.v2filter:hover .v2filter__n { background: #fff; color: var(--ink); }

/* ── Count, active filters, sort ───────────────────────────────────────── */
.v2body { width: min(var(--v2-max), 100%); margin: 0 auto; padding: 0 var(--pad); }
.v2meta { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 18px; min-height: 40px; padding: 26px 0 30px; }
.v2meta__count { margin: 0; font-size: 12px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.v2chips { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.v2chip { display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 9px 0 12px; border: 1px solid var(--line); background: #fff; font-size: 11px; letter-spacing: .1em; text-transform: uppercase; transition: border-color .2s; }
.v2chip:hover { border-color: var(--ink); }
.v2chip .icon { width: 13px; height: 13px; }
.v2chips__clear { padding: 4px 2px; border: 0; background: none; font-size: 11px; letter-spacing: .1em; text-transform: uppercase; text-decoration: underline; text-underline-offset: 3px; color: var(--ink-3); }
.v2sort { display: inline-flex; align-items: center; gap: 8px; margin-left: auto; font-size: 12px; letter-spacing: .12em; text-transform: uppercase; }
.v2sort__label { color: var(--muted); }
.v2 .v2sort__select { height: 32px; padding: 0 20px 0 2px; border: 0; border-radius: 0; background: transparent url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.6'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") no-repeat right center / 13px; font-size: 12px; letter-spacing: .1em; text-transform: uppercase; -webkit-appearance: none; appearance: none; field-sizing: content; cursor: pointer; }

/* ── Grid ──────────────────────────────────────────────────────────────── */
.v2grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 56px clamp(14px, 1.6vw, 24px); margin: 0; padding: 0; list-style: none; }
.v2card__link { display: block; }
.v2card__media { position: relative; display: block; aspect-ratio: 5 / 7; overflow: hidden; background: var(--grey-bg); }
.v2card__media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: opacity .5s var(--ease), transform 1.2s var(--ease); }
.v2card__alt { opacity: 0; }
/* Sold out: a pale veil, so the pieces you can buy lead. */
.v2card.is-out .v2card__media::after { content: ""; position: absolute; inset: 0; background: rgba(255, 255, 255, .28); }
.v2card__name { margin: 16px 0 3px; font-family: var(--f-sans); font-weight: 400; font-size: 12px; line-height: 1.5; letter-spacing: .14em; text-transform: uppercase; }
.v2card__price { display: block; font-family: var(--f-ui); font-size: 13px; line-height: 1.5; color: var(--ink-3); }
.v2card__out { margin-left: 8px; font-family: var(--f-sans); font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
@media (hover: hover) {
	.v2card__link:hover .v2card__media img { transform: scale(1.025); }
	.v2card__link:hover .v2card__media.has-alt img:first-child { opacity: 0; }
	.v2card__link:hover .v2card__alt { opacity: 1; }
	.v2card__link:hover .v2card__name { text-decoration: underline; text-underline-offset: 4px; }
}
@media (hover: none) { .v2card__alt { display: none; } }

.v2empty { padding: 50px 0 10px; text-align: center; }
.v2empty__title { margin: 0 0 8px; font-family: var(--f-palmer); font-size: 30px; line-height: 1.2; }
.v2empty p { color: var(--ink-3); }
.v2empty .btn { margin-top: 12px; }

/* ── Filter panel: a drawer from the right (a sheet from the bottom on phones) ── */
.v2panel { position: fixed; inset: 0 0 0 auto; width: min(400px, 100%); max-width: 100%; height: 100%; max-height: 100%; margin: 0; padding: 0; border: 0; background: #fff; color: var(--ink); box-shadow: -20px 0 60px rgba(0, 0, 0, .12); }
.v2panel::backdrop { background: rgba(0, 0, 0, .3); }
.v2panel[open] { animation: v2-in .35s var(--ease); }
@keyframes v2-in { from { transform: translateX(28px); opacity: 0; } }
html:has(.v2panel[open]) { overflow: hidden; }
.v2panel__form { display: flex; flex-direction: column; height: 100%; }
.v2panel__head { display: flex; align-items: center; justify-content: space-between; padding: 10px 10px 10px 28px; border-bottom: 1px solid var(--line); }
.v2panel__title { margin: 0; font-size: 13px; font-weight: 400; letter-spacing: .16em; text-transform: uppercase; }
.v2panel__body { flex: 1; overflow-y: auto; padding: 4px 28px 24px; }
.v2group { margin: 0; padding: 22px 0; border: 0; border-bottom: 1px solid var(--line); }
.v2group:last-child { border-bottom: 0; }
.v2group__title { float: left; width: 100%; margin: 0 0 14px; padding: 0; font-size: 11px; letter-spacing: .18em; text-transform: uppercase; color: var(--muted); }
.v2opts { clear: both; display: flex; flex-wrap: wrap; gap: 8px; }
.v2opt { position: relative; }
.v2opt input, .v2switch input { position: absolute; width: 1px; height: 1px; margin: 0; opacity: 0; }
.v2opt span { display: inline-flex; align-items: center; height: 40px; padding: 0 16px; border: 1px solid var(--line); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; cursor: pointer; transition: border-color .2s, background .2s, color .2s; }
.v2opt span:hover { border-color: var(--ink); }
.v2opt input:checked + span { border-color: var(--ink); background: var(--ink); color: #fff; }
.v2opt input:focus-visible + span { outline: 2px solid var(--ink); outline-offset: 2px; }
.v2switch { clear: both; position: relative; display: flex; align-items: center; gap: 12px; font-size: 13px; cursor: pointer; }
.v2switch__track { position: relative; flex: none; width: 40px; height: 22px; border: 1px solid var(--ink); border-radius: 11px; transition: background .2s; }
.v2switch__track::after { content: ""; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; border-radius: 50%; background: var(--ink); transition: transform .2s var(--ease), background .2s; }
.v2switch input:checked + .v2switch__track { background: var(--ink); }
.v2switch input:checked + .v2switch__track::after { transform: translateX(18px); background: #fff; }
.v2switch input:focus-visible + .v2switch__track { outline: 2px solid var(--ink); outline-offset: 3px; }
.v2panel__foot { display: grid; grid-template-columns: 1fr 2fr; gap: 10px; padding: 16px 28px calc(16px + env(safe-area-inset-bottom)); border-top: 1px solid var(--line); }
.v2panel__foot .btn { min-height: 48px; }
.v2 .v2panel__clear { border-color: var(--ink); background: #fff; color: var(--ink); font-family: var(--f-sans); letter-spacing: .08em; }
.v2 .v2panel__clear:hover { background: var(--ink); color: #fff; }

/* ── Smaller screens ───────────────────────────────────────────────────── */
@media (max-width: 1100px) {
	.v2grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 1240px) {
	.v2bar__in { flex-wrap: wrap; gap: 0; padding: 0; }
	.v2pills { flex: 1 1 100%; gap: 22px; padding: 0 var(--pad); }
	.v2pill { padding: 15px 0 13px; }
	.v2bar__tools { flex: 1 1 100%; gap: 10px; padding: 8px var(--pad) 10px; border-top: 1px solid var(--line); }
	.v2search { flex: 1; width: auto; }
}
@media (max-width: 782px) {
	.admin-bar .v2 { --v2-bar-top: calc(var(--header-h) + 46px); }
}
@media (max-width: 760px) {
	.v2hero { grid-template-columns: 1fr; }
	.v2hero__media { order: -1; min-height: 0; aspect-ratio: 16 / 10; }
	.v2hero__text { padding: 28px var(--pad) 32px; }
	.v2hero__eyebrow { margin-bottom: 10px; }
	.v2hero__title { font-size: 38px; }
	.v2hero__lede { margin-top: 12px; font-size: 14px; }
}
@media (max-width: 600px) {
	.v2grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 34px 12px; }
	.v2meta { padding: 16px 0 20px; }
	.v2chips { order: 3; flex: 1 1 100%; }
	.v2chips:empty { display: none; }
	.v2card__name { margin-top: 12px; }
	.v2card__out { display: block; margin: 2px 0 0; }
	.v2panel { inset: auto 0 0 0; width: 100%; height: auto; max-height: 86vh; max-height: 86dvh; box-shadow: 0 -20px 60px rgba(0, 0, 0, .14); }
	.v2panel[open] { animation-name: v2-up; }
	.v2panel__head { padding-left: 20px; }
	.v2panel__body { padding: 0 20px 16px; }
	.v2panel__foot { padding-left: 20px; padding-right: 20px; }
}
@keyframes v2-up { from { transform: translateY(28px); opacity: 0; } }
@media (prefers-reduced-motion: reduce) {
	.v2panel[open] { animation: none; }
	.v2card__media img { transition: none; }
}

/* ═══ Product page, version 2 (single-product-v2.php + product-v2.js) ═════ */
.pv2 { --v2-max: 1320px; padding-bottom: 110px; }
.pv2 > .woocommerce-notices-wrapper { width: min(var(--v2-max), 100%); margin: 0 auto; padding: 0 var(--pad); }
.pv2-crumbs { width: min(var(--v2-max), 100%); margin: 0 auto; padding: 24px var(--pad) 26px; }
.pv2-crumbs ol { display: flex; flex-wrap: wrap; gap: 6px 10px; margin: 0; padding: 0; list-style: none; font-size: 11px; line-height: 16px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.pv2-crumbs li + li::before { content: "/"; margin-right: 10px; color: var(--line); }
.pv2-crumbs a:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }
.pv2-crumbs [aria-current] { color: var(--ink); }
.pv2-layout { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(32px, 4.5vw, 80px); align-items: start; width: min(var(--v2-max), 100%); margin: 0 auto; padding: 0 var(--pad); }

/* Photos: the first one wide, the rest two by two. site.js still runs its slideshow on these
   (and hides the slides it isn't showing), so every slide is forced visible here. */
.pv2 .gallery { max-width: none; margin: 0; }
.pv2-gallery__track { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.pv2 .pv2-slide, .pv2 .pv2-slide[hidden] { display: block !important; position: relative; margin: 0; aspect-ratio: 4 / 5; overflow: hidden; background: var(--grey-bg); }
.pv2 .pv2-slide:first-child { grid-column: 1 / -1; }
/* An even count leaves the last photo alone on its row: let it take the whole row. */
.pv2 .pv2-slide:last-child:nth-child(even) { grid-column: 1 / -1; }
.pv2 .pv2-slide img, .pv2 .pv2-slide video { position: absolute; inset: 0; width: 100%; height: 100%; aspect-ratio: auto; object-fit: cover; }
.pv2 .pv2-slide .gallery__zoom { display: block; height: 100%; }
.pv2 .pv2-slide .gallery__zoom img { transition: transform 1.2s var(--ease); }
@media (hover: hover) { .pv2 .pv2-slide .gallery__zoom:hover img { transform: scale(1.02); } }
.pv2-gallery__count { display: none; }

/* The panel beside the photos stays in view while they scroll past. Its column is as tall as the photos
   (align-self: stretch) so it has room to stick; a panel taller than the screen sticks by its bottom
   instead (product-v2.js sets --pv2-top). */
.pv2-info { align-self: stretch; }
.pv2-info__in { position: sticky; top: var(--pv2-top, calc(var(--header-h) + 28px)); }
.admin-bar .pv2-info__in { top: var(--pv2-top, calc(var(--header-h) + 60px)); }
.pv2-title { margin: 0 0 10px; font-family: var(--f-palmer); font-weight: 400; font-size: clamp(34px, 3.2vw, 48px); line-height: 1.08; }
.pv2-price { margin: 0 0 24px; font-family: var(--f-ui); font-size: 17px; }
.pv2-price del { margin-right: 8px; opacity: .55; }
.pv2-price ins { text-decoration: none; }
.pv2 .product-intro { margin: 0; }
.pv2 .product-intro p { margin: 0 0 12px; font-family: var(--f-ui); font-size: 14.5px; line-height: 1.75; color: var(--ink-3); }
.pv2 .product-intro p:last-child { margin-bottom: 0; }
.pv2-buy { margin: 28px 0 0; padding-top: 26px; border-top: 1px solid var(--line); }

/* Options: size and scent as buttons (product-v2.js), colours as the theme's swatches. */
.pv2 .variations { display: grid; gap: 22px; margin-bottom: 26px; }
.pv2 .var-label { margin: 0 0 10px; font-family: var(--f-sans); font-weight: 400; font-size: 11px; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.pv2 .var-label__value { color: var(--ink); letter-spacing: .08em; }
.pv2-opts { display: flex; flex-wrap: wrap; gap: 8px; }
.pv2-opt { min-height: 42px; padding: 9px 16px; border: 1px solid var(--line); background: #fff; font-family: var(--f-ui); font-size: 13px; line-height: 1.35; text-align: left; transition: border-color .2s, background .2s, color .2s; }
.pv2-opt:hover { border-color: var(--ink); }
.pv2-opt[aria-checked="true"] { border-color: var(--ink); background: var(--ink); color: #fff; }
.pv2-opt.is-unavailable { color: var(--muted); text-decoration: line-through; text-decoration-color: rgba(0, 0, 0, .35); }
.pv2-opt.is-unavailable[aria-checked="true"] { color: #fff; text-decoration-color: rgba(255, 255, 255, .6); }
.pv2-one { margin: 0; font-family: var(--f-ui); font-size: 14px; }

/* Quantity and add to cart on one row. */
.pv2 .variations_button, .pv2 .product-buy form.cart:not(.variations_form) { flex-direction: row; align-items: stretch; gap: 10px; }
.pv2 .variations_button .quantity, .pv2 .product-buy form.cart:not(.variations_form) .quantity { align-self: stretch; width: 112px; height: auto; min-height: 52px; border-color: var(--line); }
.pv2 .product-buy .single_add_to_cart_button { flex: 1; width: auto; min-height: 52px; border-color: var(--ink); background: var(--ink); color: #fff; font-size: 12px; letter-spacing: .12em; }
.pv2 .product-buy .single_add_to_cart_button:hover:not(.disabled):not([disabled]) { background: #fff; color: var(--ink); }
.pv2 .product-buy .single_add_to_cart_button.disabled, .pv2 .product-buy .single_add_to_cart_button[disabled] { border-color: var(--sand); background: var(--sand); color: var(--ink); opacity: 1; }
.pv2 .woocommerce-variation-availability p, .pv2 .stock { margin: 0 0 14px; font-family: var(--f-ui); font-size: 13px; color: var(--ink-3); }
.pv2 .out-of-stock { color: var(--ink); }
.pv2 .woocommerce-variation-description p { margin: 0 0 14px; font-family: var(--f-ui); font-size: 13px; color: var(--ink-3); }

/* Details (Specifications, Care…): lighter lines than the current page. */
.pv2 .pv2-details { margin: 34px 0 0; border-top: 1px solid var(--line); }
.pv2 .pv2-details .acc { border-bottom: 1px solid var(--line); }
.pv2 .pv2-details .acc__head { min-height: 56px; font-size: 11px; letter-spacing: .16em; }
.pv2 .pv2-details .acc__body p, .pv2 .pv2-details .acc__body li { font-family: var(--f-ui); font-size: 13.5px; line-height: 1.7; color: var(--ink-3); }

/* You may also like. */
.pv2-related { width: min(var(--v2-max), 100%); margin: clamp(80px, 9vw, 130px) auto 0; padding: 0 var(--pad); }
.pv2-related__title { margin: 0 0 clamp(28px, 3.4vw, 44px); font-family: var(--f-palmer); font-weight: 400; font-size: clamp(28px, 2.6vw, 38px); line-height: 1.2; text-align: center; }

@media (max-width: 1100px) {
	.pv2-layout { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
}
/* Phones and small tablets: one column; the photos become a row to swipe, with a count. */
@media (max-width: 900px) {
	.pv2-crumbs { padding-top: 16px; padding-bottom: 16px; }
	.pv2-layout { grid-template-columns: 1fr; gap: 26px; padding: 0; }
	.pv2-media { position: relative; }
	.pv2-gallery__track { display: flex; gap: 0; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; overscroll-behavior-x: contain; }
	.pv2-gallery__track::-webkit-scrollbar { display: none; }
	.pv2 .pv2-slide, .pv2 .pv2-slide[hidden] { flex: 0 0 100%; scroll-snap-align: start; }
	.pv2-gallery__count { display: block; position: absolute; right: 14px; bottom: 14px; margin: 0; padding: 5px 11px; background: rgba(255, 255, 255, .88); font-family: var(--f-ui); font-size: 12px; letter-spacing: .06em; }
	.pv2-info { padding: 0 var(--pad); }
	.pv2-info__in { position: static; }
	.pv2-title { font-size: 34px; }
}
@media (max-width: 600px) {
	.pv2 .pv2-slide, .pv2 .pv2-slide[hidden] { aspect-ratio: 4 / 5; }
	.pv2-related .v2grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
