html:has(body.piece-page),
body.piece-page {
  height: auto;
  min-height: 100%;
  overflow-x: hidden;
  background: var(--bg);
}

html:has(body.piece-page) {
  scrollbar-gutter: stable;
}

.piece-fit {
  width: 100%;
  height: calc(1800 / 2880 * 100vw);
  position: relative;
  overflow: hidden;
  background: var(--bg);
}

.piece-board {
  position: absolute;
  top: 0;
  left: 0;
  width: 2880px;
  height: 1800px;
  transform-origin: top left;
  background: var(--bg);
  color: var(--ink);
  font-family: "Outfit", sans-serif;
  font-weight: 500;
  font-kerning: none;
  font-feature-settings: "kern" 0;
}

.tracked {
  position: absolute;
  margin: 0;
  padding: 0;
  font-family: "Outfit", sans-serif;
  font-weight: 500;
  font-kerning: none;
  font-feature-settings: "kern" 0;
  line-height: 1;
  letter-spacing: 0;
  white-space: nowrap;
  color: var(--ink);
}

.tracked span {
  display: inline-block;
}

.nav-link {
  position: absolute;
  top: 41.3124px;
  font-size: 17.4391px;
  color: var(--ink);
  text-decoration: none;
  z-index: 2;
}

.header-logo {
  position: absolute;
  z-index: 2;
  display: block;
  margin: 0;
  color: inherit;
  text-decoration: none;
}

.header-logo img {
  display: block;
  width: 100%;
  height: 100%;
}

.piece-name {
  position: absolute;
  left: 550.1895px;
  top: 218.005px;
  margin: 0;
  font-size: 73.7309px;
  font-weight: 500;
  line-height: 1;
}

.meta-label,
.meta-body,
.buy-price,
.enquire,
.caption,
.blurb,
.copy {
  position: absolute;
  margin: 0;
  line-height: 1;
}

.meta-label {
  left: 552.2578px;
  font-size: 20.5px;
  line-height: 30.57px;
}

.meta-body {
  left: 920.8331px;
  font-size: 20.5px;
  font-weight: 400;
  line-height: 30.57px;
}

.piece-copy .meta-label,
.piece-copy .meta-body {
  font-size: 18.7px;
  line-height: 27.886px;
}

.painting {
  position: absolute;
  left: 1476.4225px;
  top: 226.0862px;
  width: 1133.5775px;
  height: 1253.7173px;
  margin: 0;
  overflow: hidden;
  background: #f2f2f2;
}

.painting img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: #f2f2f2;
  color: transparent;
}

.painting-wide {
  top: 291.1036px;
  height: 780.877px;
}

.buy-rule {
  position: absolute;
  left: 552.6763px;
  right: 1561.9px;
  top: 1105.0624px;
  height: 1px;
  background: var(--ink);
}

.buy-price {
  left: 552.6572px;
  top: 1122.1583px;
  font-size: 19px;
  font-weight: 400;
}

.enquire {
  right: 1561.9px;
  top: 1114.78px;
  display: inline-flex;
  align-items: center;
  gap: 1ch;
  padding: 0.45rem 0.85rem;
  border-radius: 0;
  font-family: Figtree, system-ui, sans-serif;
  font-weight: 600;
  font-size: 1.05rem;
  letter-spacing: 0.01em;
  font-kerning: auto;
  font-feature-settings: normal;
  color: #111;
  background: transparent;
  text-decoration: none;
  transition:
    color 0.4s cubic-bezier(0.33, 0, 0.2, 1),
    background 0.4s cubic-bezier(0.33, 0, 0.2, 1),
    gap 0.4s cubic-bezier(0.33, 0, 0.2, 1);
}

.enquire:hover {
  gap: 4ch;
  color: #111;
}

.enquire-arrow {
  display: block;
  width: 0.62em;
  height: 0.62em;
  object-fit: contain;
  flex-shrink: 0;
  transform: rotate(0deg);
  transition: transform 0.4s cubic-bezier(0.33, 0, 0.2, 1);
}

.enquire:hover .enquire-arrow {
  transform: rotate(90deg);
}

@media (prefers-reduced-motion: reduce) {
  .enquire {
    transition: color 0.2s ease, background 0.2s ease;
  }

  .enquire-arrow {
    transition: none;
  }

  .enquire:hover {
    gap: 1ch;
  }

  .enquire:hover .enquire-arrow {
    transform: none;
  }
}

.caption {
  top: 1529.2917px;
  font-size: 1.05rem;
}

.caption-wide {
  top: 1121.4688px;
}

.caption-date {
  left: 1474.1094px;
}

.caption-medium {
  right: 274.5042px;
}

.blurb {
  left: 156.7041px;
  font-size: 24.9453px;
}

.copy {
  left: 156.7041px;
  top: 1685.0048px;
  font-size: 14.2341px;
}

@media (max-width: 760px) {
  html:has(body.piece-page),
  body.piece-page {
    height: auto;
    overflow-x: hidden;
    overflow-y: auto;
  }

  .piece-fit {
    height: auto;
    overflow: visible;
  }

  .piece-board {
    --about-w: 765.8422;
    --type: 0.78;
    position: relative;
    display: flex;
    flex-direction: column;
    width: auto;
    height: auto;
    transform: none;
    padding: 20px 20px 36px;
    container-type: inline-size;
    font-weight: 300;
  }

  .piece-header {
    order: 1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 22px;
  }

  .piece-nav {
    display: flex;
    gap: 16px;
  }

  .piece-header .header-logo,
  .piece-header .nav-link,
  .piece-header .tracked {
    position: static;
    left: auto !important;
    top: auto !important;
  }

  .piece-header .header-logo {
    width: 64px !important;
    height: auto !important;
  }

  .piece-header .header-logo img {
    width: 64px;
    height: auto;
  }

  .piece-header .nav-link {
    font-size: 12px;
    font-weight: 300;
  }

  .piece-name {
    order: 4;
    position: static;
    margin: 44px 0 40px;
    font-weight: 500;
    font-size: min(22px, calc(73.7309 / var(--about-w) * 100cqi * 0.62));
  }

  .painting,
  .painting-wide {
    order: 2;
    position: relative;
    left: auto;
    top: auto;
    width: 100%;
    height: auto;
    aspect-ratio: 1133.5775 / 1253.7173;
  }

  .painting-wide {
    aspect-ratio: 1133.5775 / 780.877;
  }

  .piece-captions {
    order: 3;
    display: flex;
    justify-content: space-between;
    gap: 16px;
    margin-top: 10px;
  }

  .caption,
  .caption-wide {
    position: static;
    top: auto;
    left: auto;
    right: auto;
    font-weight: 300;
    font-size: min(12px, calc(16.8 / var(--about-w) * 100cqi * var(--type)));
  }

  .piece-about {
    order: 5;
    display: grid;
    grid-template-columns: 48.1275% 1fr;
    align-items: baseline;
    width: 100%;
  }

  .piece-about .meta-label,
  .piece-about .meta-body,
  .piece-about .buy-price,
  .piece-about .enquire,
  .piece-about .buy-rule {
    position: static;
    left: auto;
    right: auto;
    top: auto;
  }

  .piece-about .meta-label {
    grid-column: 1;
    margin: 0;
    font-weight: 400;
    font-size: min(12px, calc(20.5 / var(--about-w) * 100cqi * var(--type)));
    line-height: 1.4912;
    white-space: nowrap;
  }

  .piece-about .meta-body,
  .piece-copy .piece-about .meta-body {
    grid-column: 2;
    max-width: none;
    margin: 0;
    font-weight: 300;
    font-size: min(12px, calc(20.5 / var(--about-w) * 100cqi * var(--type)));
    line-height: 1.4912;
  }

  .piece-copy .piece-about .meta-label,
  .piece-copy .piece-about .meta-body {
    font-size: min(12px, calc(18.7 / var(--about-w) * 100cqi * var(--type)));
    line-height: calc(27.886 / 18.7);
  }

  .piece-about .meta-label:not(:first-child),
  .piece-about .meta-body:not(:nth-child(2)) {
    margin-top: calc(45.874 / var(--about-w) * 100cqi);
  }

  .piece-about .buy-rule {
    grid-column: 1 / -1;
    width: 100%;
    height: 1px;
    margin: calc(135.75 / var(--about-w) * 100cqi) 0 0;
  }

  .piece-about .buy-price,
  .piece-about .enquire {
    align-self: center;
    margin-top: calc(17.1 / var(--about-w) * 100cqi);
  }

  .piece-about .buy-price {
    grid-column: 1;
    font-weight: 300;
    font-size: min(12px, calc(19 / var(--about-w) * 100cqi * var(--type)));
  }

  .piece-about .enquire {
    grid-column: 2;
    justify-self: end;
    padding: 0.45em 0.85em;
    font-family: "Outfit", sans-serif;
    font-weight: 300;
    font-size: min(12px, calc(16.8 / var(--about-w) * 100cqi * var(--type)));
  }

  .piece-about .enquire-arrow {
    width: 8px;
    height: 8px;
  }

  .piece-board > .blurb,
  .piece-board > .copy {
    order: 6;
    position: static;
    left: auto;
    top: auto;
    max-width: 16em;
    font-weight: 400;
    font-size: min(13px, calc(24.9453 / var(--about-w) * 100cqi * var(--type)));
    line-height: 1.2;
  }

  .piece-board > .blurb:first-of-type {
    margin-top: 64px;
  }

  .piece-board > .copy {
    order: 7;
    max-width: none;
    margin-top: calc(18 / var(--about-w) * 100cqi);
    font-weight: 400;
    font-size: min(11px, calc(14.2341 / var(--about-w) * 100cqi * var(--type)));
    white-space: nowrap;
  }
}
