/* ============================================================
   ZMS — components
   ============================================================ */

/* ---------- marquee ---------- */

.marquee {
  overflow: hidden;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: var(--paper);
  padding: 13px 0;
}

.marquee__track {
  display: flex;
  width: max-content;
  animation: marquee 56s linear infinite;
}

.marquee:hover .marquee__track {
  animation-play-state: paused;
}

.marquee__group {
  display: flex;
  align-items: center;
  flex: none;
}

.marquee__item {
  display: flex;
  align-items: center;
  gap: 22px;
  padding: 0 22px;
  white-space: nowrap;
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
}

.marquee__item::after {
  content: "";
  width: 4px;
  height: 4px;
  background: var(--ink);
  flex: none;
}

@keyframes marquee {
  to {
    transform: translateX(-50%);
  }
}

/* ---------- product cards ---------- */

.product-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(28px, 4vw, 56px) clamp(20px, 2.6vw, 40px);
}

.product-grid--featured {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(36px, 5vw, 80px) clamp(24px, 5vw, 80px);
}

.product-grid--featured .product-card:nth-child(even) {
  margin-top: clamp(40px, 8vw, 120px);
}

.product-card {
  display: block;
  position: relative;
}

.product-card__inner {
  display: block;
  transform-style: preserve-3d;
}

.product-card__media {
  position: relative;
  aspect-ratio: 4 / 5;
  background: var(--paper-2);
  border: 1px solid var(--line);
  overflow: hidden;
  display: grid;
  place-items: center;
  transition: border-color 0.4s var(--ease), background-color 0.4s var(--ease);
}

.product-card:hover .product-card__media {
  border-color: var(--line-strong);
  background: #e4e1da;
}

.product-card__media img {
  width: 78%;
  height: auto;
  max-height: 82%;
  object-fit: contain;
  transition: transform 0.9s var(--ease-out);
}

.product-card:hover .product-card__media img {
  transform: translateY(-9px) scale(1.012);
}

.product-card__fig,
.product-card__cat {
  position: absolute;
  top: 14px;
  z-index: 2;
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

.product-card__fig {
  left: 16px;
}

.product-card__cat {
  right: 16px;
}

.product-card__cta {
  position: absolute;
  right: 14px;
  bottom: 14px;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  background: var(--ink);
  color: var(--paper);
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 0.35s var(--ease), transform 0.35s var(--ease);
}

.product-card__cta svg {
  width: 14px;
  height: 14px;
}

.product-card:hover .product-card__cta,
.product-card:focus-visible .product-card__cta {
  opacity: 1;
  transform: none;
}

.product-card__meta {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--s4);
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.product-card__name {
  font-size: 16px;
  font-weight: 400;
  letter-spacing: -0.015em;
  line-height: 1.25;
}

.product-card__material {
  margin-top: 3px;
  font-size: 14px;
  line-height: 1.4;
  color: var(--muted);
}

.product-card__price {
  flex: none;
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.04em;
}

/* ---------- FAQ ---------- */

.faq-list {
  border-top: 1px solid var(--line);
}

.faq-item {
  border-bottom: 1px solid var(--line);
}

.faq-item summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s5);
  padding: clamp(18px, 2.2vw, 26px) 0;
  cursor: pointer;
  list-style: none;
  font-size: clamp(1rem, 1.45vw, 1.28rem);
  font-weight: 400;
  letter-spacing: -0.015em;
  line-height: 1.35;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary:hover {
  opacity: 0.62;
}

.faq-icon {
  position: relative;
  width: 13px;
  height: 13px;
  flex: none;
}

.faq-icon::before,
.faq-icon::after {
  content: "";
  position: absolute;
  top: 6px;
  left: 0;
  width: 13px;
  height: 1px;
  background: currentColor;
  transition: transform 0.35s var(--ease);
}

.faq-icon::after {
  transform: rotate(90deg);
}

.faq-item[open] .faq-icon::after {
  transform: rotate(0deg);
}

.faq-answer {
  max-width: 68ch;
  padding: 0 40px var(--s5) 0;
  font-size: 14px;
  line-height: 1.7;
  color: var(--muted);
}

.faq-item[open] .faq-answer {
  animation: faqIn 0.4s var(--ease);
}

@keyframes faqIn {
  from {
    opacity: 0;
    transform: translateY(-4px);
  }
}

.faq-more {
  margin-top: var(--s6);
}

/* ---------- forms ---------- */

.field {
  display: grid;
  gap: 7px;
}

.field label,
.field-label {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}

.field input,
.field select,
.field textarea {
  width: 100%;
  height: 48px;
  padding: 0 13px;
  border: 1px solid var(--line-strong);
  border-radius: 0;
  background: transparent;
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 15px;
  appearance: none;
}

.field textarea {
  height: auto;
  min-height: 104px;
  padding: 12px 13px;
  resize: vertical;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--ink);
  box-shadow: inset 0 0 0 1px var(--ink);
}

.field select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath d='M1 1l4 4 4-4' fill='none' stroke='%230b0b0b' stroke-width='1.2'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 36px;
}

.field input::placeholder,
.field textarea::placeholder {
  color: var(--muted-2);
}

.check {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  font-size: 14px;
  line-height: 1.55;
  color: var(--muted);
  cursor: pointer;
}

.check input {
  appearance: none;
  width: 15px;
  height: 15px;
  margin: 2px 0 0;
  border: 1px solid var(--line-strong);
  background: transparent;
  flex: none;
  display: grid;
  place-items: center;
  cursor: pointer;
}

.check input:checked {
  background: var(--ink);
  border-color: var(--ink);
}

.check input:checked::after {
  content: "";
  width: 7px;
  height: 4px;
  border-left: 1px solid var(--paper);
  border-bottom: 1px solid var(--paper);
  transform: rotate(-45deg) translateY(-1px);
}

.check a {
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* ---------- dialogs ---------- */

dialog {
  border: 0;
  padding: 0;
  margin: 0;
  max-width: none;
  max-height: none;
  background: transparent;
  color: inherit;
}

dialog::backdrop {
  background: rgba(5, 5, 5, 0.62);
}

.dialog-close {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  color: inherit;
  flex: none;
}

.dialog-close svg {
  width: 15px;
  height: 15px;
}

.dialog-close:hover {
  opacity: 0.55;
}

/* cart drawer */

.drawer {
  position: fixed;
  inset: 0 0 0 auto;
  width: min(460px, 100%);
  height: 100%;
  background: var(--paper);
  color: var(--ink);
  border-left: 1px solid var(--line);
}

.drawer[open] {
  animation: drawerIn 0.5s var(--ease-out);
}

@keyframes drawerIn {
  from {
    transform: translateX(100%);
  }
}

.drawer__inner {
  display: flex;
  flex-direction: column;
  height: 100%;
}

.drawer__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s4);
  padding: 0 var(--s5);
  height: var(--header-h);
  border-bottom: 1px solid var(--line);
  flex: none;
}

.drawer__title {
  font-size: 18px;
  font-weight: 400;
  letter-spacing: -0.02em;
}

.drawer__title span {
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.1em;
  color: var(--muted);
  margin-left: 8px;
}

.drawer__body {
  flex: 1;
  overflow-y: auto;
  padding: var(--s5);
  overscroll-behavior: contain;
}

.drawer__foot {
  flex: none;
  padding: var(--s5);
  border-top: 1px solid var(--line);
}

.drawer__empty {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--s4);
  padding: clamp(40px, 12vh, 120px) 0;
}

.drawer__empty p {
  font-size: 14px;
  color: var(--muted);
  max-width: 28ch;
}

.cart-line {
  display: grid;
  grid-template-columns: 74px minmax(0, 1fr) auto;
  gap: var(--s4);
  padding: 18px 0;
  border-bottom: 1px solid var(--line);
}

.cart-line:first-child {
  padding-top: 0;
}

.cart-line__img {
  display: grid;
  place-items: center;
  aspect-ratio: 4 / 5;
  padding: 7px;
  background: var(--paper-2);
  border: 1px solid var(--line);
}

.cart-line__img img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.cart-line__name {
  font-size: 14px;
  font-weight: 400;
  letter-spacing: -0.01em;
  line-height: 1.3;
}

.cart-line__variant {
  margin-top: 2px;
  font-size: 13px;
  color: var(--muted);
}

.cart-line__price {
  font-family: var(--font-mono);
  font-size: 13px;
  text-align: right;
  white-space: nowrap;
}

.qty {
  display: inline-flex;
  align-items: center;
  height: 28px;
  margin-top: 9px;
  border: 1px solid var(--line);
}

.qty button {
  display: grid;
  place-items: center;
  width: 27px;
  height: 26px;
  font-size: 14px;
  line-height: 1;
  color: var(--muted);
}

.qty button:hover {
  background: var(--paper-2);
  color: var(--ink);
}

.qty span {
  min-width: 24px;
  text-align: center;
  font-family: var(--font-mono);
  font-size: 13px;
}

.cart-line__remove {
  display: inline-block;
  margin-top: 9px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  border-bottom: 1px solid currentColor;
}

.cart-line__remove:hover {
  color: var(--ink);
}

.ship-progress {
  margin-bottom: var(--s5);
}

.ship-progress__text {
  display: flex;
  justify-content: space-between;
  gap: var(--s4);
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}

.ship-progress__bar {
  height: 2px;
  margin-top: 9px;
  background: var(--line);
  overflow: hidden;
}

.ship-progress__fill {
  height: 100%;
  width: 0;
  background: var(--ink);
  transition: width 0.45s var(--ease);
}

.cart-totals {
  display: grid;
  gap: 6px;
  margin-bottom: var(--s5);
}

.cart-totals__row {
  display: flex;
  justify-content: space-between;
  gap: var(--s4);
  font-size: 14px;
  color: var(--muted);
}

.cart-totals__row--total {
  margin-top: 6px;
  padding-top: 10px;
  border-top: 1px solid var(--line);
  font-size: 15px;
  color: var(--ink);
}

.cart-totals__row--total span:last-child {
  font-family: var(--font-mono);
  font-size: 14px;
}

.cart-note {
  margin-top: 12px;
  font-size: 13px;
  line-height: 1.5;
  color: var(--muted);
  text-align: center;
}

/* search */

.search {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  background: var(--paper);
  color: var(--ink);
}

.search[open] {
  animation: searchIn 0.45s var(--ease-out);
}

@keyframes searchIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
}

.search__inner {
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: 0 var(--gutter);
}

.search__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--header-h);
  border-bottom: 1px solid var(--line);
  flex: none;
}

.search__field {
  display: flex;
  align-items: center;
  gap: var(--s4);
  padding: clamp(26px, 5vw, 54px) 0;
  border-bottom: 1px solid var(--line);
  flex: none;
}

.search__field svg {
  width: clamp(20px, 2.4vw, 30px);
  height: auto;
  flex: none;
  color: var(--muted);
}

.search__field input {
  flex: 1;
  min-width: 0;
  border: 0;
  background: transparent;
  font-family: var(--font-sans);
  font-size: clamp(1.8rem, 5vw, 4.4rem);
  font-weight: 400;
  letter-spacing: -0.045em;
  line-height: 1;
  outline: none;
}

.search__field input::placeholder {
  color: var(--paper-3);
}

.search__results {
  flex: 1;
  overflow-y: auto;
  padding: var(--s5) 0 var(--s7);
  overscroll-behavior: contain;
}

.search-result {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr) auto;
  align-items: center;
  gap: var(--s4);
  width: 100%;
  padding: 12px 10px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  color: var(--ink);
}

.search-result:hover,
.search-result.is-active {
  background: var(--paper-2);
}

.search-result__img {
  display: grid;
  place-items: center;
  width: 52px;
  height: 64px;
  background: var(--paper-2);
  border: 1px solid var(--line);
  padding: 4px;
}

.search-result__img img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.search-result__name {
  font-size: 17px;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.search-result__meta {
  margin-top: 2px;
  font-size: 13px;
  color: var(--muted);
}

.search-result__price {
  font-family: var(--font-mono);
  font-size: 13px;
}

.search__empty {
  padding: var(--s7) 0;
  font-size: 14px;
  color: var(--muted);
}

.search__hint {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 28px;
  padding: 16px 0;
  border-top: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  flex: none;
}

/* mobile menu */

.menu {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  background: var(--ink);
  color: var(--paper);
}

.menu[open] {
  animation: searchIn 0.35s var(--ease-out);
}

.menu__inner {
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: 0 var(--gutter);
}

.menu__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--header-h);
  border-bottom: 1px solid var(--line-light);
  flex: none;
}

.menu__nav {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0;
  overflow-y: auto;
}

.menu__nav a {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--s5);
  padding: 10px 0;
  border-bottom: 1px solid var(--line-light);
  font-size: clamp(2.4rem, 8.5vw, 4.6rem);
  letter-spacing: -0.055em;
  line-height: 1.05;
}

.menu__nav a span {
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.12em;
  color: var(--muted-dark);
}

.menu__nav a:hover {
  color: var(--muted-dark);
}

.menu__foot {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: var(--s3) var(--s5);
  padding: var(--s5) 0;
  border-top: 1px solid var(--line-light);
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted-dark);
  flex: none;
}

.menu__foot a {
  color: var(--paper);
}

/* ---------- scene ---------- */

.scene {
  position: absolute;
  inset: 0;
  overflow: hidden;
}

.scene canvas {
  display: block;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 1.4s var(--ease);
}

.scene.is-ready canvas {
  opacity: 1;
}

.scene__fallback {
  display: none;
  position: absolute;
  top: 50%;
  left: 62%;
  width: clamp(120px, 15vw, 230px);
  aspect-ratio: 0.58;
  transform: translate(-50%, -52%) rotateY(-18deg) rotateX(8deg);
  background: linear-gradient(145deg, #2b2b2a 0%, #101010 45%, #050505 100%);
  border: 1px solid #3a3a38;
  box-shadow: 0 60px 120px rgba(0, 0, 0, 0.6);
}

.scene--fallback .scene__fallback {
  display: block;
}

.scene--fallback canvas {
  display: none;
}

.scene__hint {
  position: absolute;
  z-index: 3;
  display: flex;
  align-items: center;
  gap: 9px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(242, 240, 236, 0.55);
  pointer-events: none;
}

.scene__hint svg {
  width: 14px;
  height: 14px;
}

/* ---------- cursor ---------- */

.cursor {
  position: fixed;
  inset: 0 auto auto 0;
  width: 0;
  height: 0;
  margin: 0;
  padding: 0;
  border: 0;
  background: none;
  overflow: visible;
  z-index: 2147483647;
  pointer-events: none;
  color: #fff;
  mix-blend-mode: difference;
  opacity: 0;
  transition: opacity 0.2s linear;
}

.cursor.is-visible {
  opacity: 1;
}

.cursor__dot,
.cursor__ring {
  position: absolute;
  top: 0;
  left: 0;
  border-radius: 50%;
  transform: translate(-50%, -50%);
}

.cursor__dot {
  width: 4px;
  height: 4px;
  background: currentColor;
}

.cursor__ring {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border: 1px solid currentColor;
  transition: width 0.25s var(--ease), height 0.25s var(--ease),
    opacity 0.2s linear;
}

.cursor__label {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  opacity: 0;
  transition: opacity 0.18s linear;
  white-space: nowrap;
}

.cursor.is-link .cursor__ring {
  width: 44px;
  height: 44px;
}

.cursor.is-label .cursor__ring {
  width: 66px;
  height: 66px;
}

.cursor.is-label .cursor__label {
  opacity: 1;
}

.cursor.is-down .cursor__ring {
  width: 22px;
  height: 22px;
}

/* The native pointer is hidden everywhere (including elements that set
   their own cursor, dialogs and their backdrops, the lightbox, the 3D stage).
   Text fields keep the I-beam so the caret position stays readable. */
html.has-cursor,
html.has-cursor *,
html.has-cursor *::before,
html.has-cursor *::after,
html.has-cursor ::backdrop {
  cursor: none !important;
}

html.has-cursor input:not([type="checkbox"]):not([type="radio"]):not([type="button"]):not([type="submit"]),
html.has-cursor textarea,
html.has-cursor select {
  cursor: auto !important;
}

/* ---------- reveal & tilt ---------- */

.js [data-reveal] {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 0.9s var(--ease), transform 0.9s var(--ease);
  transition-delay: calc(var(--reveal-i, 0) * 70ms);
}

.js [data-reveal].is-in {
  opacity: 1;
  transform: none;
}

[data-tilt] {
  transform: perspective(1100px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg));
  transition: transform 0.7s var(--ease);
}

[data-tilt].is-tilting {
  transition: transform 0.1s linear;
  will-change: transform;
}

/* ---------- utility ---------- */

.rule {
  height: 1px;
  background: var(--line);
  border: 0;
  margin: 0;
}

.section--dark .rule {
  background: var(--line-light);
}

@media (max-width: 1080px) {
  .product-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .product-grid--featured {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  .product-grid,
  .product-grid--featured {
    grid-template-columns: 1fr;
  }

  .product-grid--featured .product-card:nth-child(even) {
    margin-top: 0;
  }

  .cursor {
    display: none;
  }

  .search__hint {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .marquee__track {
    animation: none;
  }

  .js [data-reveal] {
    opacity: 1;
    transform: none;
    transition: none;
  }

  [data-tilt] {
    transform: none !important;
  }
}
