/*
 * ONEEXISTS v1.8.0 — Collections
 * Editorial hub + shared block styles for /collections/ and taxonomy pages.
 * Loads after v170. Mobile-first (60% of traffic).
 */

/* ============================================================================
   HUB HERO — editorial statement, dark, no image
   ============================================================================ */
.oe-collections-hub {
  color: rgb(var(--oe-white));
}

.oe-collections-hero {
  background: #000;
  min-height: 60vh;
  min-height: 60svh;
  display: flex;
  align-items: flex-end;
  padding: calc(var(--oe-header-h) + 4rem) 0 clamp(3rem, 8vh, 6rem);
  position: relative;
}

.oe-collections-hero__inner {
  width: 100%;
}

.oe-collections-hero .oe-eyebrow {
  color: rgb(var(--oe-white) / 0.55);
  font-family: var(--oe-font-mono, "JetBrains Mono", monospace);
  font-size: 0.6875rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  display: block;
  margin: 0 0 clamp(1.5rem, 3vh, 2.5rem);
}

.oe-collections-hero__title {
  font-family: var(--oe-font-head, "Fraunces", serif);
  font-size: clamp(3rem, 8vw, 7rem);
  line-height: 0.98;
  letter-spacing: -0.025em;
  margin: 0 0 clamp(1rem, 2vh, 1.5rem);
  color: rgb(var(--oe-white));
}

.oe-collections-hero__lead {
  font-family: var(--oe-font-head, "Fraunces", serif);
  font-style: italic;
  font-size: clamp(1.0625rem, 1.4vw, 1.375rem);
  line-height: 1.5;
  max-width: 42ch;
  margin: 0;
  color: rgb(var(--oe-white) / 0.75);
}

/* ============================================================================
   FEATURE BLOCK — full-bleed, image bg + scrim + left-aligned text
   ============================================================================ */
.oe-collection-feature {
  position: relative;
  min-height: 92vh;
  min-height: 92svh;
  max-height: 900px;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
  color: rgb(var(--oe-white));
  isolation: isolate;
  background-color: #000;
}

.oe-collection-feature__media {
  position: absolute;
  inset: 0;
  z-index: 0;
  background-size: cover;
  /* Same 62% Y shift as the hero — the shared poster has a mockup nav baked
     into its top edge; shifting the visible slice down clips it away and
     keeps the Roman I fully in frame. */
  background-position: center 62%;
  background-repeat: no-repeat;
  transform: scale(1.02);
  transition: transform 900ms cubic-bezier(0.22, 1, 0.36, 1);
}

.oe-collection-feature__scrim {
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(180deg,
      rgb(0 0 0 / 0.35) 0%,
      transparent 30%,
      rgb(0 0 0 / 0.15) 55%,
      rgb(0 0 0 / 0.55) 85%,
      rgb(0 0 0 / 0.78) 100%);
  pointer-events: none;
}

.oe-collection-feature__inner {
  position: relative;
  z-index: 2;
  padding-block: clamp(3rem, 8vh, 6rem);
  width: 100%;
}

.oe-collection-feature__num {
  display: block;
  font-family: var(--oe-font-mono, "JetBrains Mono", monospace);
  font-size: 0.6875rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: rgb(var(--oe-white) / 0.55);
  margin: 0 0 1.25rem;
}

.oe-collection-feature__title {
  font-family: var(--oe-font-head, "Fraunces", serif);
  font-size: clamp(2.75rem, 6.5vw, 6rem);
  line-height: 1.02;
  letter-spacing: -0.025em;
  margin: 0 0 clamp(1rem, 2vh, 1.5rem);
  color: rgb(var(--oe-white));
  max-width: 20ch;
}

.oe-collection-feature__lead {
  font-family: var(--oe-font-head, "Fraunces", serif);
  font-style: italic;
  font-size: clamp(1.0625rem, 1.4vw, 1.375rem);
  line-height: 1.5;
  max-width: 40ch;
  margin: 0 0 clamp(1.5rem, 3vh, 2.5rem);
  color: rgb(var(--oe-white) / 0.85);
}

/* Ghost CTA scoped to collection blocks — same voice as hero */
.oe-collection-feature .oe-btn--ghost,
.oe-collection-half .oe-collection-half__cta {
  display: inline-block;
  background: transparent;
  border: 1px solid rgb(var(--oe-white) / 0.4);
  color: rgb(var(--oe-white));
  padding: 0.9375rem 1.75rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-size: 0.75rem;
  font-weight: 500;
  font-family: var(--oe-font-ui, "Inter", sans-serif);
  text-decoration: none;
  transition: border-color 260ms cubic-bezier(0.22, 1, 0.36, 1),
              background-color 260ms cubic-bezier(0.22, 1, 0.36, 1);
}
.oe-collection-feature .oe-btn--ghost:hover,
.oe-collection-feature .oe-btn--ghost:focus-visible {
  border-color: rgb(var(--oe-white));
  background: rgb(var(--oe-white) / 0.06);
}

/* ============================================================================
   SPLIT BLOCK — two half-height cards side-by-side, image + text
   ============================================================================ */
.oe-collection-split {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2px; /* hairline separator */
  background: rgb(var(--oe-white) / 0.06);
}

.oe-collection-half {
  position: relative;
  min-height: 72vh;
  min-height: 72svh;
  max-height: 780px;
  display: flex;
  align-items: flex-end;
  color: rgb(var(--oe-white));
  text-decoration: none;
  overflow: hidden;
  isolation: isolate;
  background-color: #000;
  transition: transform 400ms cubic-bezier(0.22, 1, 0.36, 1);
}

.oe-collection-half__media {
  position: absolute;
  inset: 0;
  z-index: 0;
  background-size: cover;
  background-position: center 62%; /* clip mockup nav baked into poster top */
  background-repeat: no-repeat;
  transform: scale(1.02);
  transition: transform 900ms cubic-bezier(0.22, 1, 0.36, 1);
}

.oe-collection-half:hover .oe-collection-half__media,
.oe-collection-half:focus-visible .oe-collection-half__media {
  transform: scale(1.04);
}

.oe-collection-half__scrim {
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(180deg,
      rgb(0 0 0 / 0.3) 0%,
      transparent 40%,
      rgb(0 0 0 / 0.35) 70%,
      rgb(0 0 0 / 0.75) 100%);
  pointer-events: none;
}

.oe-collection-half__body {
  position: relative;
  z-index: 2;
  padding: clamp(2rem, 4vh, 3.25rem) clamp(1.5rem, 3vw, 3rem);
  width: 100%;
}

.oe-collection-half__num {
  display: block;
  font-family: var(--oe-font-mono, "JetBrains Mono", monospace);
  font-size: 0.625rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: rgb(var(--oe-white) / 0.55);
  margin: 0 0 1rem;
}

.oe-collection-half__title {
  font-family: var(--oe-font-head, "Fraunces", serif);
  font-size: clamp(2rem, 4vw, 3.5rem);
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin: 0 0 1rem;
  color: rgb(var(--oe-white));
}

.oe-collection-half__lead {
  font-family: var(--oe-font-head, "Fraunces", serif);
  font-style: italic;
  font-size: clamp(0.9375rem, 1.15vw, 1.125rem);
  line-height: 1.5;
  max-width: 34ch;
  margin: 0 0 clamp(1.25rem, 2.5vh, 2rem);
  color: rgb(var(--oe-white) / 0.85);
}

/* --- Desktop breakpoint: side-by-side split --- */
@media (min-width: 64rem) {
  .oe-collection-split:not([data-columns="1"]) {
    grid-template-columns: 1fr 1fr;
  }
  .oe-collection-half--wide { grid-column: 1 / -1; }
}

/* ============================================================================
   SINGLE COLLECTION PAGE — /collections/{slug}/
   ============================================================================ */

.oe-collection-single .oe-collection-hero {
  position: relative;
  background-color: #000;
  background-size: cover;
  background-position: center 62%; /* same nav-clip shift as hero + feature */
  background-repeat: no-repeat;
  min-height: 68vh;
  min-height: 68svh;
  max-height: 780px;
  display: flex;
  align-items: flex-end;
  padding: calc(var(--oe-header-h) + 4rem) 0 clamp(3rem, 8vh, 6rem);
  color: rgb(var(--oe-white));
  overflow: hidden;
  isolation: isolate;
}

.oe-collection-hero__scrim {
  position: absolute;
  inset: 0;
  z-index: 0;
  background:
    linear-gradient(180deg,
      rgb(0 0 0 / 0.35) 0%,
      transparent 30%,
      rgb(0 0 0 / 0.2) 55%,
      rgb(0 0 0 / 0.6) 85%,
      rgb(0 0 0 / 0.85) 100%);
  pointer-events: none;
}

.oe-collection-hero__inner {
  position: relative;
  z-index: 1;
  width: 100%;
}

.oe-crumb {
  display: block;
  font-family: var(--oe-font-mono, "JetBrains Mono", monospace);
  font-size: 0.6875rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgb(var(--oe-white) / 0.55);
  margin: 0 0 clamp(1.25rem, 2.5vh, 2rem);
}
.oe-crumb a { color: rgb(var(--oe-white) / 0.75); text-decoration: none; }
.oe-crumb a:hover { color: rgb(var(--oe-white)); }
.oe-crumb__current { color: rgb(var(--oe-white)); }

.oe-collection-single__title {
  font-family: var(--oe-font-head, "Fraunces", serif);
  font-size: clamp(2.75rem, 7vw, 6rem);
  line-height: 1.02;
  letter-spacing: -0.025em;
  margin: 0 0 clamp(1rem, 2vh, 1.5rem);
  color: rgb(var(--oe-white));
  max-width: 20ch;
}

.oe-collection-single__lead {
  font-family: var(--oe-font-head, "Fraunces", serif);
  font-style: italic;
  font-size: clamp(1.0625rem, 1.4vw, 1.375rem);
  line-height: 1.5;
  max-width: 44ch;
  margin: 0;
  color: rgb(var(--oe-white) / 0.85);
}

/* --- META STRIP --- */
.oe-collection-meta {
  background: rgb(var(--oe-graphite));
  padding-block: clamp(2rem, 5vh, 3.5rem);
  border-block: 1px solid rgb(var(--oe-white) / 0.06);
  color: rgb(var(--oe-white));
}

.oe-collection-meta__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(1.25rem, 2vw, 2rem);
  margin: 0;
  padding: 0;
}

.oe-collection-meta__cell dt {
  font-family: var(--oe-font-mono, "JetBrains Mono", monospace);
  font-size: 0.625rem;
  letter-spacing: 0.22em;
  color: rgb(var(--oe-white) / 0.55);
  margin: 0 0 0.5rem;
}

.oe-collection-meta__cell dd {
  font-family: var(--oe-font-head, "Fraunces", serif);
  font-size: 0.9375rem;
  line-height: 1.4;
  margin: 0;
  color: rgb(var(--oe-white));
}

@media (min-width: 48rem) {
  .oe-collection-meta__grid { grid-template-columns: repeat(4, 1fr); }
}

/* --- OBJECTS SECTION --- */
.oe-collection-objects {
  background: rgb(var(--oe-black));
  padding-block: clamp(4rem, 10vh, 7rem);
  color: rgb(var(--oe-white));
}

.oe-collection-objects__header {
  margin-bottom: clamp(2rem, 5vh, 3.5rem);
}

.oe-collection-objects .oe-h2 {
  font-family: var(--oe-font-head, "Fraunces", serif);
  font-size: clamp(1.75rem, 3.5vw, 2.75rem);
  line-height: 1.1;
  letter-spacing: -0.015em;
  margin: 0;
  color: rgb(var(--oe-white));
}

/* Empty state — the dominant state at launch */
.oe-collection-empty {
  border: 1px solid rgb(var(--oe-white) / 0.12);
  padding: clamp(3rem, 8vw, 5rem) clamp(1.5rem, 4vw, 3rem);
  text-align: center;
  max-width: 46rem;
  margin: 0 auto;
}
.oe-collection-empty__eyebrow {
  color: rgb(var(--oe-white) / 0.55);
  display: block;
  margin: 0 0 1.5rem;
}
.oe-collection-empty__msg {
  font-family: var(--oe-font-head, "Fraunces", serif);
  font-style: italic;
  font-size: clamp(1.0625rem, 1.4vw, 1.25rem);
  line-height: 1.55;
  max-width: 40ch;
  margin: 0 auto clamp(1.5rem, 3vh, 2.5rem);
  color: rgb(var(--oe-white) / 0.85);
}

/* Object grid (when products exist) */
.oe-object-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: 1fr;
  gap: clamp(1.5rem, 3vw, 2.5rem);
}
.oe-object-card__link { color: inherit; text-decoration: none; display: block; }
.oe-object-card__media { aspect-ratio: 5/6; background: rgb(var(--oe-graphite)); overflow: hidden; margin-bottom: 1rem; }
.oe-object-card__media img { width: 100%; height: 100%; object-fit: cover; }
.oe-object-card__num { font-family: var(--oe-font-mono, monospace); font-size: 0.625rem; letter-spacing: 0.2em; color: rgb(var(--oe-white) / 0.55); display: block; margin-bottom: 0.375rem; }
.oe-object-card__title { font-family: var(--oe-font-head, serif); font-size: 1.125rem; margin: 0 0 0.375rem; }
.oe-object-card__price { font-family: var(--oe-font-ui, sans-serif); font-size: 0.875rem; color: rgb(var(--oe-white) / 0.7); margin: 0; }

@media (min-width: 48rem) { .oe-object-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 64rem) { .oe-object-grid { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 80rem) { .oe-object-grid { grid-template-columns: repeat(4, 1fr); } }

/* --- RELATED COLLECTIONS --- */
.oe-collection-related {
  background: rgb(var(--oe-graphite));
  padding-block: clamp(3rem, 6vh, 5rem);
  color: rgb(var(--oe-white));
  border-top: 1px solid rgb(var(--oe-white) / 0.06);
}
.oe-collection-related__header { margin-bottom: clamp(1.5rem, 3vh, 2.5rem); }

.oe-collection-related__grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: 1fr;
  gap: 2px;
}
.oe-collection-related__card {
  position: relative;
  display: flex;
  align-items: flex-end;
  min-height: 240px;
  background-color: #000;
  background-size: cover;
  background-position: center;
  padding: 1.5rem;
  color: rgb(var(--oe-white));
  text-decoration: none;
  overflow: hidden;
  isolation: isolate;
}
.oe-collection-related__scrim {
  position: absolute; inset: 0; z-index: 0;
  background: linear-gradient(180deg, rgb(0 0 0 / 0.2) 0%, transparent 45%, rgb(0 0 0 / 0.7) 100%);
}
.oe-collection-related__label {
  position: relative; z-index: 1;
  font-family: var(--oe-font-head, serif);
  font-size: clamp(1.25rem, 2.5vw, 1.75rem);
  line-height: 1.1;
  letter-spacing: -0.015em;
}

@media (min-width: 48rem) { .oe-collection-related__grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 64rem) { .oe-collection-related__grid { grid-template-columns: repeat(4, 1fr); } }

/* ============================================================================
   MOTION — respect prefers-reduced-motion
   ============================================================================ */
@media (prefers-reduced-motion: reduce) {
  .oe-collection-feature__media,
  .oe-collection-half__media {
    transform: none !important;
    transition: none !important;
  }
  .oe-collection-half:hover .oe-collection-half__media,
  .oe-collection-half:focus-visible .oe-collection-half__media {
    transform: none !important;
  }
}
