/* Denimsan catalogue refinements — 20.10.2026 */

/* Softer imagery behind the collection slider keeps fabric cards legible. */
.collection-stage .collection-bg.active {
  opacity: .42 !important;
}

/* Amazon-like family grid: four consistent cards per row on desktop. */
@media (min-width: 1181px) {
  .collection.category-view .collection-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  }

  .collection.category-view .collection-card,
  .collection.category-view .collection-card:nth-child(n) {
    grid-column: auto !important;
    height: clamp(176px, 11.5vw, 224px) !important;
    min-height: 176px !important;
  }
}

.collection.category-view .collection-card b,
.fabric-sample b {
  font-size: clamp(.68rem, .61rem + .12vw, .84rem) !important;
}

.collection.category-view .collection-card small,
.fabric-sample small {
  font-size: clamp(.44rem, .4rem + .08vw, .56rem) !important;
}

.collection.category-view .family-cover-picture {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
}

.collection.category-view .family-cover-picture img {
  object-position: center;
}

@media (max-width: 700px) {
  .collection.category-view .collection-card,
  .collection.category-view .collection-card:nth-child(n),
  .collection.category-view .collection-card:nth-child(13),
  .collection.category-view .collection-card:hover,
  .collection.category-view .collection-card:focus-visible {
    grid-column: auto !important;
    aspect-ratio: 4 / 5 !important;
    height: auto !important;
    min-height: 0 !important;
  }
}

/* Shared product links receive their own clear action. */
.modal-actions {
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
}

.modal-actions .fabric-share {
  color: #f8f7f4;
  background: #765f43;
  border-color: #765f43;
}

/* Desktop product details use one scrollbar and keep every field clear of the actions. */
@media (min-width: 901px) {
  html.product-modal-open,
  body.product-modal-open {
    overflow: hidden !important;
  }

  .product-modal {
    overflow: hidden !important;
  }

  .product-modal .modal-info {
    height: 100dvh;
    box-sizing: border-box;
    overflow-x: hidden !important;
    overflow-y: auto !important;
    overscroll-behavior-y: contain;
    scrollbar-gutter: stable;
    padding-bottom: 28px !important;
  }

  .product-modal .modal-info > .modal-actions {
    position: static !important;
    inset: auto !important;
    flex: 0 0 auto;
    margin: 18px 0 0 !important;
    padding: 0 0 6px !important;
    background: none !important;
  }
}

.shared-product-modal .modal-visual {
  display: block;
  background: #10141d;
}

.shared-product-modal .modal-texture {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.shared-product-modal .modal-texture img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.shared-image-nav {
  z-index: 8;
  position: absolute;
  left: 50%;
  bottom: max(16px, env(safe-area-inset-bottom));
  display: flex;
  gap: 7px;
  max-width: calc(100% - 28px);
  padding: 6px;
  overflow-x: auto;
  border: 1px solid rgba(255, 255, 255, .22);
  border-radius: 4px;
  background: rgba(7, 10, 14, .78);
  backdrop-filter: blur(12px);
  transform: translateX(-50%);
  scrollbar-width: none;
}

.shared-image-nav::-webkit-scrollbar {
  display: none;
}

.shared-image-nav button {
  flex: 0 0 64px;
  width: 64px;
  height: 72px;
  padding: 0;
  overflow: hidden;
  cursor: pointer;
  border: 2px solid transparent;
  background: #11161d;
  opacity: .7;
  transition: border-color .2s, opacity .2s, transform .2s;
}

.shared-image-nav button.active {
  border-color: #c5a880;
  opacity: 1;
  transform: translateY(-2px);
}

.shared-image-nav img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.shared-garment-grid {
  z-index: 3;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
  padding: 6px;
  background: #10141d;
}

.shared-garment-grid img {
  width: 100%;
  height: 112px;
  object-fit: cover;
}

/* Natural photo gestures: pinch to zoom, drag while zoomed, double-click on desktop. */
.modal-texture,
.gallery-stage {
  overflow: hidden;
}

.shared-garment-item {
  display: block;
  min-width: 0;
  overflow: hidden;
}

.shared-product-modal .is-linked-image { outline: 0; }

.modal-texture img,
.gallery-stage > img,
.shared-garment-grid img {
  --zoom-scale: 1;
  --zoom-x: 0px;
  --zoom-y: 0px;
  cursor: zoom-in;
  user-select: none;
  -webkit-user-select: none;
  -webkit-user-drag: none;
  transform-origin: center center;
  transform: translate3d(var(--zoom-x), var(--zoom-y), 0) scale(var(--zoom-scale));
  transition: transform .22s cubic-bezier(.16, 1, .3, 1);
  will-change: transform;
}

.modal-texture img.is-zoomed,
.gallery-stage > img.is-zoomed,
.shared-garment-grid img.is-zoomed {
  cursor: grab;
}

.modal-texture img.is-gesturing,
.gallery-stage > img.is-gesturing,
.shared-garment-grid img.is-gesturing,
.modal-texture img.is-panning,
.gallery-stage > img.is-panning,
.shared-garment-grid img.is-panning {
  cursor: grabbing;
  transition: none;
}

/* Editorial fair index and story pages. */
.fairs-page:has(.fair-landing),
.fairs-page:has(.fair-story) {
  background: #f2f0eb;
  color: #13171a;
  min-height: 100vh;
  padding: 0;
}

.fair-landing {
  width: min(1500px, calc(100% - 72px));
  margin: 0 auto;
  padding: clamp(128px, 13vw, 210px) 0 clamp(80px, 10vw, 150px);
}

.fair-intro {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(260px, .55fr);
  column-gap: clamp(40px, 9vw, 150px);
  align-items: end;
  margin-bottom: clamp(55px, 8vw, 120px);
}

.fair-kicker,
.fair-story-title > span {
  color: #a97d42;
  font: 700 .64rem/1.2 Arial, sans-serif;
  letter-spacing: .26em;
  text-transform: uppercase;
}

.fair-intro h1 {
  grid-row: 2;
  max-width: 980px;
  margin: 25px 0 0;
  font: 400 clamp(3.2rem, 7.2vw, 8rem)/.88 Georgia, serif;
  letter-spacing: -.065em;
}

.fair-intro p {
  grid-column: 2;
  grid-row: 1 / span 2;
  margin: 0 0 8px;
  color: #555b5e;
  font: 400 clamp(.9rem, 1.1vw, 1.08rem)/1.75 Arial, sans-serif;
}

.fair-feature-list {
  display: grid;
  gap: clamp(28px, 4vw, 64px);
}

.fair-feature-card {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(400px, .75fr);
  min-height: min(72vw, 820px);
  background: #11181e;
  color: #f5f3ee;
}

.fair-feature-image {
  display: block;
  min-height: 560px;
  position: relative;
  overflow: hidden;
}

.fair-feature-image picture,
.fair-feature-image img {
  display: block;
  width: 100%;
  height: 100%;
}

.fair-feature-image img {
  object-fit: cover;
  transition: transform .8s cubic-bezier(.2, .8, .2, 1);
}

@media (min-width: 901px) {
  .fair-feature-card-texhibition-istanbul-2026 .fair-feature-image img {
    object-position: 65% center;
  }
}

.fair-feature-image:hover img {
  transform: scale(1.025);
}

.fair-feature-copy {
  display: flex;
  flex-direction: column;
  padding: clamp(34px, 5vw, 76px);
}

.fair-card-meta,
.fair-story-meta {
  display: flex;
  justify-content: space-between;
  gap: 22px;
  color: #c9a96f;
  font: 700 .58rem/1.45 Arial, sans-serif;
  letter-spacing: .16em;
  text-transform: uppercase;
}

.fair-feature-copy h2 {
  margin: auto 0 25px;
  max-width: 100%;
  font: 400 clamp(2.25rem, 2.8vw, 3.6rem)/.94 Georgia, serif;
  letter-spacing: -.055em;
}

.fair-feature-copy p {
  max-width: 470px;
  margin: 0 0 40px;
  color: #aeb5b9;
  font: 400 .92rem/1.75 Arial, sans-serif;
}

.fair-detail-link {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 0 14px;
  border-bottom: 1px solid rgba(255, 255, 255, .32);
  color: #fff;
  font: 700 .64rem/1 Arial, sans-serif;
  letter-spacing: .17em;
  text-decoration: none;
}

.fair-detail-link span {
  color: #d8b57a;
  font-size: 1.05rem;
}

.fair-archive-film {
  display: grid;
  grid-template-columns: minmax(340px, .72fr) minmax(0, 1.28fr);
  gap: clamp(36px, 6vw, 96px);
  align-items: center;
  margin: 0 0 clamp(65px, 9vw, 135px);
  padding: clamp(32px, 5vw, 78px);
  background: #d9d5cd;
}

.fair-archive-film-copy > span {
  color: #9a713d;
  font: 700 .6rem/1.2 Arial, sans-serif;
  letter-spacing: .22em;
}

.fair-archive-film-copy h2 {
  margin: 24px 0 28px;
  font: 400 clamp(2.5rem, 4.2vw, 5.2rem)/.92 Georgia, serif;
  letter-spacing: -.055em;
}

.fair-archive-film-copy p {
  margin: 0 0 24px;
  color: #4e5559;
  font: 400 .94rem/1.75 Arial, sans-serif;
}

.fair-archive-film-copy small {
  color: #74797b;
  font: 700 .58rem/1.4 Arial, sans-serif;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.fair-archive-film-media {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #0d1216;
  box-shadow: 0 28px 80px rgba(20, 25, 29, .22);
  overflow: hidden;
}

.fair-archive-film-media video {
  display: block;
  width: auto;
  max-width: 100%;
  height: min(78vh, 820px);
  max-height: 100%;
  aspect-ratio: 9 / 16;
  object-fit: contain;
  background: #000;
}

.fair-archive-film-media video:fullscreen,
.fair-archive-film-media video:-webkit-full-screen {
  width: 100vw;
  max-width: 100vw;
  height: 100vh;
  max-height: 100vh;
  aspect-ratio: auto;
  object-fit: contain;
  background: #000;
}

.fair-story {
  padding: clamp(104px, 10vw, 160px) 0 0;
}

.fair-back {
  display: block;
  width: min(1500px, calc(100% - 72px));
  margin: 0 auto 30px;
  color: #596064;
  font: 700 .62rem/1 Arial, sans-serif;
  letter-spacing: .16em;
  text-decoration: none;
}

.fair-story-hero {
  position: relative;
  min-height: min(78vh, 920px);
  overflow: hidden;
  background: #11181e;
  color: #fff;
}

.fair-story-hero picture,
.fair-story-hero img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.fair-story-hero img {
  object-fit: cover;
}

.fair-story-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(7, 10, 12, .06) 25%, rgba(7, 10, 12, .86) 100%);
}

.fair-story-title {
  position: absolute;
  z-index: 1;
  left: max(36px, calc((100% - 1500px) / 2));
  right: max(36px, calc((100% - 1500px) / 2));
  bottom: clamp(36px, 7vw, 92px);
}

.fair-story-title h1 {
  max-width: 1150px;
  margin: 20px 0 32px;
  font: 400 clamp(3.8rem, 8.5vw, 9.7rem)/.82 Georgia, serif;
  letter-spacing: -.07em;
}

.fair-story-meta {
  justify-content: flex-start;
  gap: clamp(35px, 8vw, 130px);
  color: #e6c995;
}

.fair-film {
  width: min(1240px, calc(100% - 72px));
  margin: clamp(54px, 8vw, 112px) auto 0;
  display: grid;
  grid-template-columns: minmax(280px, .72fr) minmax(0, 1.28fr);
  align-items: center;
  gap: clamp(48px, 9vw, 130px);
  padding: clamp(24px, 4vw, 54px);
  background: #11181e;
  color: #f5f3ee;
}

.fair-film-media {
  width: min(100%, 470px);
  justify-self: center;
  background: #07090b;
}

.fair-film video {
  display: block;
  width: 100%;
  aspect-ratio: 9 / 16;
  object-fit: cover;
  background: #07090b;
}

.fair-film-copy > span {
  color: #c9a96f;
  font: 700 .62rem/1 Arial, sans-serif;
  letter-spacing: .2em;
}

.fair-film-copy h2 {
  max-width: 620px;
  margin: 28px 0 30px;
  font: 400 clamp(2.25rem, 4vw, 4.8rem)/.98 Georgia, serif;
  letter-spacing: -.05em;
}

.fair-film-copy p {
  max-width: 560px;
  margin: 0;
  color: #b6bdc0;
  font: 400 .98rem/1.8 Arial, sans-serif;
}

.fair-film-copy small {
  display: block;
  margin-top: 32px;
  color: #7f898e;
  font: 600 .62rem/1.5 Arial, sans-serif;
  letter-spacing: .08em;
}

.fair-story-copy {
  width: min(1240px, calc(100% - 72px));
  margin: 0 auto;
  padding: clamp(75px, 10vw, 150px) 0;
}

.fair-story-lead {
  max-width: 1100px;
  margin: 0;
  font: 400 clamp(1.75rem, 3.3vw, 3.8rem)/1.22 Georgia, serif;
  letter-spacing: -.035em;
}

.fair-story-columns {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(300px, .7fr);
  gap: clamp(55px, 11vw, 170px);
  align-items: start;
  margin: clamp(60px, 9vw, 120px) 0 0 clamp(0px, 12vw, 180px);
}

.fair-story-columns p {
  margin: 0;
  color: #4b5255;
  font: 400 1rem/1.9 Arial, sans-serif;
}

.fair-story-columns blockquote {
  margin: 0;
  padding: 0 0 0 28px;
  border-left: 2px solid #b5884b;
  font: italic 400 clamp(1.35rem, 2vw, 2.05rem)/1.35 Georgia, serif;
}

.fair-gallery {
  width: min(1500px, calc(100% - 72px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(18px, 2.4vw, 38px);
  align-items: start;
}

.fair-gallery-item {
  margin: 0;
}

.fair-gallery-item picture,
.fair-gallery-item img {
  display: block;
  width: 100%;
}

.fair-gallery-item img {
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.fair-gallery-item.is-portrait img {
  aspect-ratio: 3 / 4;
}

.fair-gallery-item.is-wide {
  grid-column: 1 / -1;
}

.fair-gallery-item.is-wide img {
  aspect-ratio: 16 / 9;
  object-position: center 44%;
}

.fair-story-footer {
  width: min(1500px, calc(100% - 72px));
  margin: clamp(46px, 6vw, 86px) auto 0;
  padding: 26px 0 clamp(42px, 5vw, 72px);
  border-top: 1px solid #c8c4ba;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 30px;
  background: transparent;
  color: #15191c;
  font: 700 .6rem/1.4 Arial, sans-serif;
  letter-spacing: .16em;
}

.fair-story-footer a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 18px;
  background: #15191c;
  color: #fff;
  text-decoration: none;
}

/* Mobile product detail: one swipe moves from the visual to a complete passport. */
@media (max-width: 900px) {
  .shared-image-nav {
    bottom: max(12px, env(safe-area-inset-bottom));
    gap: 5px;
    padding: 5px;
  }

  .shared-image-nav button {
    flex-basis: 54px;
    width: 54px;
    height: 60px;
  }

  .product-modal {
    display: block !important;
    height: 100dvh;
    overflow-x: hidden !important;
    overflow-y: auto !important;
    scroll-snap-type: y mandatory;
    overscroll-behavior-y: contain;
    -webkit-overflow-scrolling: touch;
  }

  .product-modal .modal-visual {
    height: 100dvh !important;
    min-height: 0;
    scroll-snap-align: start;
    scroll-snap-stop: always;
  }

  .product-modal .modal-info {
    box-sizing: border-box;
    height: 100dvh;
    min-height: 0;
    overflow: hidden !important;
    padding: max(18px, env(safe-area-inset-top)) 16px max(16px, env(safe-area-inset-bottom)) !important;
    scroll-snap-align: start;
    scroll-snap-stop: always;
    display: flex;
    flex-direction: column;
  }

  .product-modal .passport {
    flex: 0 0 auto;
    font-size: .54rem;
  }

  .product-modal .modal-info h2 {
    flex: 0 0 auto;
    margin: 7px 0 3px;
    font-size: clamp(2rem, 10vw, 3.5rem);
    line-height: .92;
  }

  .product-modal .edition {
    flex: 0 0 auto;
    margin: 0;
    padding-bottom: 7px;
    font-size: .7rem;
  }

  .product-modal .modal-info dl {
    flex: 1 1 auto;
    order: 0 !important;
    min-height: 0;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    grid-template-rows: repeat(3, minmax(0, 1fr));
    gap: 5px;
    margin: 8px 0;
  }

  .product-modal .modal-info dl > div {
    min-height: 0;
    overflow: hidden;
    padding: 8px 7px 7px 27px;
  }

  .product-modal .modal-info dl > div > span {
    top: 9px;
    left: 8px;
    font-size: .49rem;
  }

  .product-modal .modal-info dt,
  .product-modal .modal-info dd {
    font-size: .72rem;
    line-height: 1.15;
  }

  .product-modal .modal-info dt small {
    display: none;
  }

  .product-modal .modal-info dd {
    margin-top: 5px;
  }

  .product-modal .product-copy {
    flex: 0 0 auto;
    padding: 8px;
    font-size: .68rem;
  }

  .product-modal .modal-actions {
    flex: 0 0 auto;
    order: 0 !important;
    position: static !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 5px !important;
    margin-top: 5px !important;
    padding: 0 !important;
  }

  .modal-actions button,
  .modal-actions a {
    min-height: 34px;
    padding: 7px 5px !important;
    font-size: .54rem !important;
  }

  .fair-landing,
  .fair-back,
  .fair-film,
  .fair-story-copy,
  .fair-gallery,
  .fair-story-footer {
    width: calc(100% - 36px);
  }

  .fair-landing {
    padding-top: 110px;
  }

  .fair-intro,
  .fair-feature-card,
  .fair-archive-film,
  .fair-film,
  .fair-story-columns,
  .fair-gallery {
    grid-template-columns: 1fr;
  }

  .fair-intro p {
    grid-column: 1;
    grid-row: 3;
    margin-top: 28px;
  }

  .fair-feature-card {
    min-height: 0;
  }

  .fair-feature-image {
    min-height: auto;
    aspect-ratio: 4 / 3;
  }

  .fair-feature-copy {
    min-height: 440px;
  }

  .fair-archive-film {
    padding: 36px;
  }

  .fair-story-title {
    left: 18px;
    right: 18px;
  }

  .fair-story-title h1 {
    font-size: clamp(3rem, 15vw, 5.4rem);
  }

  .fair-story-hero {
    min-height: min(78svh, 760px);
  }

  .fair-film {
    gap: 44px;
  }

  .fair-film-copy {
    padding: 0 8px 14px;
  }

  .fair-story-columns {
    margin-left: 0;
  }

  .fair-gallery-item.is-wide {
    grid-column: auto;
  }
}

@media (max-width: 560px) {
  .fair-landing {
    width: calc(100% - 24px);
    padding-top: 92px;
  }

  .fair-intro {
    margin-bottom: 42px;
  }

  .fair-intro h1 {
    font-size: clamp(2.75rem, 14.5vw, 4.3rem);
  }

  .fair-feature-copy {
    min-height: 400px;
    padding: 28px 24px;
  }

  .fair-archive-film {
    gap: 32px;
    margin: 0 0 46px;
    padding: 28px 20px 20px;
  }

  .fair-archive-film-copy h2 {
    margin: 18px 0 22px;
    font-size: clamp(2.3rem, 12vw, 3.7rem);
  }

  .fair-archive-film-media video {
    width: 100%;
    height: auto;
    aspect-ratio: 9 / 16;
  }

  .fair-card-meta,
  .fair-story-meta {
    flex-direction: column;
    gap: 8px;
  }

  .fair-story {
    padding-top: 86px;
  }

  .fair-story-hero {
    min-height: 72svh;
  }

  .fair-story-hero img {
    object-position: 38% center;
  }

  .fair-story-title h1 {
    margin-bottom: 24px;
  }

  .fair-story-copy {
    width: calc(100% - 30px);
    padding: 65px 0;
  }

  .fair-film {
    width: calc(100% - 24px);
    margin-top: 42px;
    padding: 12px 12px 30px;
  }

  .fair-film-media {
    width: 100%;
  }

  .fair-film-copy {
    padding: 0 10px;
  }

  .fair-film-copy h2 {
    margin: 22px 0 24px;
    font-size: clamp(2rem, 10vw, 3.1rem);
  }

  .fair-story-lead {
    font-size: 1.65rem;
  }

  .fair-story-columns {
    gap: 42px;
    margin-top: 48px;
  }

  .fair-gallery {
    width: 100%;
    gap: 32px;
  }

  .fair-gallery-item img,
  .fair-gallery-item.is-portrait img,
  .fair-gallery-item.is-wide img {
    height: auto;
    aspect-ratio: auto;
    object-fit: contain;
  }

  .fair-story-footer {
    width: calc(100% - 30px);
    flex-direction: column;
    align-items: flex-start;
  }
}
