/* Ninfea storefront: white gallery ground, warm ink, the logo's blush kept for the top strip, badges and focus.
   A wide video banner opens the home page; below it the pieces carry the page with almost no text. */
:root {
  --paper: #FFFFFF;
  --paper-2: #F8F4F2;
  --ink: #1C1715;
  --ink-2: #6B625D;
  --ink-hover: #3A312D;
  --line: #E8E1DD;
  --blush: #F7DED8;
  --blush-ink: #864A41;
  --foot-ink: #EDE6E2;
  --foot-ink-2: #B9AFA9;
  --f-display: "Frank Ruhl Libre", "David", Georgia, serif;
  --f-body: "Assistant", "Heebo", "Arial Hebrew", Arial, sans-serif;
  --gutter: clamp(16px, 4vw, 56px);
  --head-h: 72px;
  --ease: cubic-bezier(.16, 1, .3, 1);
}
@media (max-width: 860px) { :root { --head-h: 60px; } }

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--head-h) + 16px); scrollbar-color: #CFC4BF transparent; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font: 400 16px/1.6 var(--f-body); -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
  caret-color: var(--ink);
}
::selection { background: var(--blush); color: var(--ink); }
img, video { max-width: 100%; }
a { color: inherit; text-underline-offset: 4px; text-decoration-thickness: 1px; }
button { font: inherit; color: inherit; }
h1, h2, h3 { text-wrap: balance; }
p { text-wrap: pretty; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--blush-ink); outline-offset: 3px; }
.wrap {
  max-width: 1440px; margin-inline: auto;
  padding-left: max(var(--gutter), env(safe-area-inset-left, 0px));
  padding-right: max(var(--gutter), env(safe-area-inset-right, 0px));
}
.skip-link { position: absolute; top: 0; right: 12px; z-index: 100; transform: translateY(-150%); background: var(--ink); color: var(--paper); padding: 12px 16px; }
.skip-link:focus { transform: none; }

/* Top strip + header */
.strip { margin: 0; padding: 8px 16px; background: var(--blush); color: var(--ink); text-align: center; font-size: 13px; letter-spacing: .02em; }
.site-head {
  position: sticky; top: 0; z-index: 40; background: var(--paper); color: var(--ink); border-bottom: 1px solid var(--line);
  transition: background-color .35s var(--ease), color .35s var(--ease), border-color .35s var(--ease);
}
.head-in { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; min-height: var(--head-h); }
.head-in > .main-nav, .head-in > .mobile-nav { grid-column: 1; grid-row: 1; }
.head-in > .logo, .head-in > .custom-logo-link { grid-column: 2; grid-row: 1; }
.head-in > .tools { grid-column: 3; grid-row: 1; justify-self: end; display: flex; gap: 2px; }
.main-nav ul { display: flex; gap: 30px; list-style: none; margin: 0; padding: 0; }
.main-nav a {
  font-size: 15px; text-decoration: none; padding-block: 6px;
  background: linear-gradient(currentColor, currentColor) no-repeat right bottom / 0 1px; transition: background-size .35s var(--ease);
}
.main-nav a:hover, .main-nav .current-menu-item a { background-size: 100% 1px; }
.logo { position: relative; display: block; line-height: 0; }
.brand-logo { display: block; width: 148px; height: auto; object-fit: contain; }
.logo-alt { position: absolute; inset: 0; opacity: 0; }
.icon-btn { width: 42px; height: 42px; display: grid; place-items: center; background: none; border: 0; color: inherit; cursor: pointer; }
.icon-btn[aria-pressed="true"] path { fill: currentColor; }
.custom-logo { width: 148px; height: auto; }

/* Header over the video banner, solid once scrolled */
.has-hero .site-head { margin-bottom: calc(-1 * var(--head-h) - 1px); }
.has-hero:not(.is-scrolled) .site-head { background: transparent; color: var(--paper); border-color: transparent; }
.has-hero:not(.is-scrolled) .site-head .logo-main { opacity: 0; }
.has-hero:not(.is-scrolled) .site-head .logo-alt { opacity: 1; }
.logo-main, .logo-alt { transition: opacity .35s var(--ease); }

/* Phone menu */
.mobile-nav { display: none; border: 0; }
.mobile-nav > summary { list-style: none; width: 42px; height: 42px; display: grid; place-items: center; cursor: pointer; padding: 0; }
.mobile-nav > summary::-webkit-details-marker { display: none; }
.mobile-nav > summary::after, .mobile-nav[open] > summary::after { content: none; }
.mobile-nav .icon-close, .mobile-nav[open] .icon-open { display: none; }
.mobile-nav[open] .icon-close { display: block; }
.mobile-nav > nav {
  position: absolute; inset-inline: 0; top: 100%; z-index: 30; background: var(--paper); color: var(--ink);
  border-bottom: 1px solid var(--line); box-shadow: 0 18px 30px -18px rgba(28, 23, 21, .25);
  padding-block: 4px 18px; padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px));
}
.mobile-nav ul { list-style: none; margin: 0; padding: 0; }
.mobile-nav a { display: block; padding: 14px 0; border-bottom: 1px solid var(--line); text-decoration: none; font-size: 17px; }
.mobile-nav ul.mobile-collections { margin-top: 12px; }
.mobile-collections a { font-size: 15px; color: var(--ink-2); padding-block: 11px; }
@media (max-width: 860px) {
  .main-nav { display: none; }
  .head-in > .mobile-nav { display: block; justify-self: start; }
  .brand-logo, .custom-logo { width: 116px; }
}

/* Video banner */
.hero { position: relative; height: min(82vh, 860px); min-height: 520px; background: var(--ink); overflow: hidden; }
.hero::before {
  content: ""; position: absolute; inset: 0 0 auto; height: 160px; z-index: 1; pointer-events: none;
  background: linear-gradient(to bottom, rgba(28, 23, 21, .42), rgba(28, 23, 21, 0));
}
.hero-panels { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); grid-template-rows: minmax(0, 1fr); height: 100%; }
/* .hero prefix outranks WooCommerce's `.woocommerce img { height: auto }` on shop-page bodies */
.hero .hero-side, .hero .hero-video { display: block; width: 100%; height: 100%; object-fit: cover; }
.hero-film { position: relative; min-width: 0; height: 100%; overflow: hidden; }
.hero-pause {
  position: absolute; bottom: 20px; inset-inline-end: 20px; z-index: 2; width: 34px; height: 34px; border-radius: 50%;
  display: grid; place-items: center; border: 0; cursor: pointer; background: rgba(255, 255, 255, .78); color: var(--ink);
}
.hero-pause .i-play, .hero-pause[aria-pressed="true"] .i-pause { display: none; }
.hero-pause[aria-pressed="true"] .i-play { display: block; }
.hero-cta { position: absolute; z-index: 2; bottom: 56px; left: 50%; transform: translateX(-50%); }
.btn-primary.hero-cta { background: var(--paper); color: var(--ink); min-width: 200px; }
.btn-primary.hero-cta:hover { background: var(--blush); }
@media (max-width: 760px) {
  .hero { height: min(78svh, 700px); min-height: 460px; }
  .hero-panels { grid-template-columns: minmax(0, 1fr); grid-template-rows: minmax(0, 1fr); }
  .hero .hero-side { display: none; }
  .hero-cta { bottom: 36px; }
}

/* Collection row */
.collections { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; padding-top: clamp(28px, 4vw, 56px); }
.collection { position: relative; display: block; aspect-ratio: 3 / 4; overflow: hidden; background: var(--paper-2); text-decoration: none; }
.collections .collection img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform 1.1s var(--ease); }
.collection:hover img { transform: scale(1.035); }
.collection span {
  position: absolute; inset: auto 0 0; padding: 48px 22px 20px; color: var(--paper);
  font: 300 clamp(20px, 2.4vw, 34px)/1.1 var(--f-display);
  background: linear-gradient(to top, rgba(28, 23, 21, .55), rgba(28, 23, 21, 0));
}
@media (max-width: 700px) { .collections { gap: 8px; } .collection span { padding: 32px 10px 10px; font-size: 18px; } }

/* Catalog */
.catalog { padding-block: clamp(40px, 5vw, 72px) clamp(56px, 6vw, 96px); }
.cat-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; margin-bottom: 16px; }
.cat-head h1 { margin: 0; font: 300 clamp(28px, 3vw, 42px)/1.1 var(--f-display); }
.count { margin: 0; color: var(--ink-2); font-size: 14px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.filters {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 4px 24px;
  border-block: 1px solid var(--line); margin-bottom: 32px;
}
.tabs { display: flex; flex-wrap: wrap; gap: 0 28px; }
.tab { padding-block: 13px 12px; margin-bottom: -1px; border-bottom: 1px solid transparent; color: var(--ink-2); font-size: 15px; text-decoration: none; }
.tab:hover { color: var(--ink); }
.tab[aria-current="page"] { color: var(--ink); border-color: var(--ink); }
.sort { display: flex; align-items: center; gap: 8px; color: var(--ink-2); font-size: 14px; }
.sort select {
  appearance: none; -webkit-appearance: none; border: 0; padding: 10px 0 10px 20px; font: inherit; color: var(--ink); cursor: pointer;
  background: transparent url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M1 1l4 4 4-4' fill='none' stroke='%231C1715' stroke-width='1.2'/%3E%3C/svg%3E") no-repeat left 2px center;
}
.sort button { border: 0; background: none; padding: 0; text-decoration: underline; cursor: pointer; }
.js .sort button { display: none; }
.stones { display: flex; flex-wrap: wrap; gap: 8px; margin: -16px 0 28px; }
.chip { padding: 6px 14px; border: 1px solid var(--line); border-radius: 999px; font-size: 14px; text-decoration: none; }
.chip[aria-current="true"] { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.stones-label { color: var(--ink-2); font-size: 14px; align-self: center; }
.saved-empty { color: var(--ink-2); margin: 0 0 24px; }

.grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 44px 20px; }
@media (max-width: 1080px) { .grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 700px) { .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px 10px; } }
.empty { grid-column: 1 / -1; padding: 48px 0; text-align: center; color: var(--ink-2); }
.empty p { margin: 0 0 18px; }

/* Product card */
.card { position: relative; min-width: 0; }
.media-wrap { position: relative; }
.media { position: relative; aspect-ratio: 3 / 4; overflow: hidden; background: var(--paper-2); }
.ninfea-track {
  position: absolute; inset: 0; display: flex; overflow-x: auto; overflow-y: hidden;
  scroll-snap-type: x mandatory; scrollbar-width: none; overscroll-behavior-x: contain; touch-action: pan-x pan-y;
}
.ninfea-track::-webkit-scrollbar { display: none; }
.ninfea-slide { position: relative; flex: 0 0 100%; display: block; height: 100%; min-width: 0; scroll-snap-align: start; scroll-snap-stop: always; }
.media .ninfea-slide img { display: block; width: 100%; height: 100%; object-fit: cover; }
.no-photo { display: grid; place-content: center; color: var(--ink-2); font-size: 14px; }
@media (hover: hover) and (pointer: fine) {
  .card .ninfea-track { display: block; overflow: hidden; }
  .card .ninfea-slide { position: absolute; inset: 0; }
  .card .ninfea-slide:nth-child(2) { opacity: 0; transition: opacity .6s var(--ease); }
  .card .ninfea-slide:nth-child(n+3) { display: none; }
  .card:hover .ninfea-slide:nth-child(2), .card:focus-within .ninfea-slide:nth-child(2) { opacity: 1; }
  .card .gallery-count { display: none; }
}
.gallery-count {
  position: absolute; bottom: 10px; inset-inline-end: 10px; padding: 2px 9px; border-radius: 999px;
  background: rgba(255, 255, 255, .86); color: var(--ink); font-size: 11px; font-variant-numeric: tabular-nums; pointer-events: none;
  direction: ltr; unicode-bidi: isolate; /* keeps "1 / 4" from flipping to "4 / 1" in RTL */
}
.fav {
  position: absolute; top: 10px; inset-inline-end: 10px; z-index: 2; width: 36px; height: 36px; border-radius: 50%;
  display: grid; place-items: center; border: 0; cursor: pointer; background: rgba(255, 255, 255, .86); color: var(--ink);
}
.fav[aria-pressed="true"] path, .product-save[aria-pressed="true"] path { fill: var(--blush-ink); stroke: var(--blush-ink); }
.badge { position: absolute; top: 12px; inset-inline-start: 12px; z-index: 2; padding: 4px 10px; background: var(--paper); color: var(--ink); font-size: 12px; letter-spacing: .02em; }
.badge-sold { background: var(--ink); color: var(--paper); }
.is-sold .product-photo { opacity: .7; }
.info { padding-top: 12px; display: grid; gap: 2px; }
.name { margin: 0; font: 400 15px/1.45 var(--f-body); overflow-wrap: anywhere; }
.name a { text-decoration: none; }
.name a:hover { text-decoration: underline; }
.also-in { margin: 0; color: var(--ink-2); font-size: 13px; }
.details .also-in { margin: 0 0 14px; font-size: 14px; }
.price { margin: 0; font-size: 15px; font-weight: 600; font-variant-numeric: tabular-nums; }
.price small { display: block; color: var(--ink-2); font-weight: 400; font-size: 12px; }

/* Pagination */
.pagination { display: flex; justify-content: center; gap: 8px; padding-top: 56px; }
.page-numbers { min-width: 42px; height: 42px; display: grid; place-items: center; padding-inline: 12px; border: 1px solid var(--line); font-size: 14px; text-decoration: none; }
a.page-numbers:hover { border-color: var(--ink); }
.page-numbers.current { background: var(--ink); border-color: var(--ink); color: var(--paper); }

/* Buttons */
.btn-primary {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px; padding: 15px 36px; border: 0; cursor: pointer;
  background: var(--ink); color: var(--paper); font: 600 15px/1.2 var(--f-body); letter-spacing: .02em; text-decoration: none;
  transition: background-color .25s var(--ease);
}
.btn-primary:hover { background: var(--ink-hover); }
.btn-line {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px; padding: 13px 26px; cursor: pointer;
  border: 1px solid var(--ink); background: transparent; color: var(--ink); font: 400 15px/1.2 var(--f-body); text-decoration: none;
  transition: background-color .25s var(--ease), color .25s var(--ease);
}
.btn-line:hover { background: var(--ink); color: var(--paper); }

/* Product page */
.product-breadcrumb { display: flex; flex-wrap: wrap; gap: 10px; padding-block: 22px; color: var(--ink-2); font-size: 13px; }
.product-breadcrumb a { text-decoration: none; }
.product-breadcrumb a:hover { text-decoration: underline; }
.pdp { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: clamp(28px, 5vw, 80px); align-items: start; padding-bottom: 72px; }
.gallery { position: sticky; top: calc(var(--head-h) + 20px); min-width: 0; }
.product-gallery .ninfea-slide img { object-fit: contain; }
.carousel-controls { position: absolute; inset: auto 14px 14px; display: flex; align-items: center; justify-content: space-between; pointer-events: none; }
.carousel-controls .gallery-count { position: static; }
.carousel-arrow {
  pointer-events: auto; width: 40px; height: 40px; border-radius: 50%; border: 0; cursor: pointer;
  display: grid; place-items: center; background: rgba(255, 255, 255, .9); color: var(--ink);
}
.thumbs { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 12px; }
.thumb { width: 68px; aspect-ratio: 3 / 4; padding: 0; border: 1px solid transparent; background: var(--paper-2); cursor: pointer; opacity: .65; transition: opacity .25s; }
.thumb:hover, .thumb[aria-pressed="true"] { opacity: 1; }
.thumb[aria-pressed="true"] { border-color: var(--ink); }
.thumbs .thumb img { display: block; width: 100%; height: 100%; object-fit: cover; }
.details { min-width: 0; padding-top: 6px; }
.pdp-name { margin: 0 0 10px; font: 300 clamp(28px, 3vw, 40px)/1.15 var(--f-display); }
.pdp-price { margin: 0 0 18px; font-size: 20px; font-variant-numeric: tabular-nums; }
.pdp-price small { color: var(--ink-2); font-size: 13px; }
.pdp-blurb { color: var(--ink-2); max-width: 52ch; }
.product-preview { margin: 18px 0 0; padding: 14px 18px; background: var(--paper-2); color: var(--ink); font-size: 14px; }
.sold-note { display: inline-block; margin: 18px 0 0; padding: 8px 14px; background: var(--ink); color: var(--paper); font-size: 14px; }
.concept-note { color: var(--blush-ink); font-size: 14px; }
.product-save { width: 100%; margin-top: 14px; }
.product-ask { display: block; margin-top: 14px; text-align: center; font-size: 14px; }
.specs { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 10px 28px; margin: 32px 0 0; padding-block: 18px; border-block: 1px solid var(--line); font-size: 14px; }
.specs dt { color: var(--ink-2); }
.specs dd { margin: 0; }
.details details { border-bottom: 1px solid var(--line); }
.details details:first-of-type { border-top: 1px solid var(--line); margin-top: 18px; }
.details summary { list-style: none; display: flex; justify-content: space-between; padding: 16px 0; cursor: pointer; font-size: 15px; }
.details summary::-webkit-details-marker { display: none; }
.details summary::after {
  content: ""; flex: none; align-self: center; width: 11px; height: 11px; color: var(--ink-2);
  background: linear-gradient(currentColor, currentColor) center / 100% 1px no-repeat, linear-gradient(currentColor, currentColor) center / 1px 100% no-repeat;
}
.details details[open] > summary::after { background-size: 100% 1px, 1px 0; }
.details details p { margin: 0 0 16px; color: var(--ink-2); font-size: 14px; max-width: 52ch; }
.woocommerce table.shop_attributes { margin-top: 20px; font-size: 14px; }
.woocommerce div.product form.cart .button, .woocommerce .button { background: var(--ink); color: var(--paper); border-radius: 0; padding: 15px 28px; }
.related { padding-block: 56px 88px; border-top: 1px solid var(--line); }
.related > h2 { margin: 0 0 24px; font: 300 clamp(24px, 2.4vw, 32px)/1.2 var(--f-display); }
.rel-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; }
@media (max-width: 860px) {
  .pdp { grid-template-columns: minmax(0, 1fr); padding-bottom: 48px; }
  .gallery { position: static; }
  .rel-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px 10px; }
}

/* Plain pages, cart, 404 */
.page-content { padding-block: clamp(48px, 7vw, 96px); min-height: 50vh; }
.page-content > h1, .page-content article > h1 { margin: 0 0 20px; font: 300 clamp(32px, 4vw, 52px)/1.1 var(--f-display); }
.page-content p { max-width: 60ch; color: var(--ink-2); }
.page-content .btn-primary { margin-top: 12px; }
.not-found .related { margin-top: 64px; padding-bottom: 0; }

/* Footer */
.site-foot { background: var(--ink); color: var(--foot-ink); }
.foot-in { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.4fr; gap: 40px; padding-block: 64px 48px; }
.foot-brand .logo { width: fit-content; }
.foot-brand .brand-logo { width: 168px; }
.foot-brand p, .site-foot .foot-in > div > p:not(.foot-title) { margin: 18px 0 0; color: var(--foot-ink-2); font-size: 14px; max-width: 32ch; }
.foot-title { margin: 0 0 14px; color: var(--foot-ink-2); font-size: 13px; letter-spacing: .02em; }
.site-foot ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.site-foot a { color: var(--foot-ink); font-size: 14px; text-decoration: none; }
.site-foot a:hover { text-decoration: underline; }
.foot-base { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; padding-block: 18px 24px; border-top: 1px solid rgba(237, 230, 226, .16); color: var(--foot-ink-2); font-size: 12px; }
@media (max-width: 900px) { .foot-in { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 520px) { .foot-in { grid-template-columns: minmax(0, 1fr); } }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
}
