/*
  Galleries page styles.
*/

@font-face {
  font-family: "Gallery Gotham";
  src:
    url("../fonts/Gotham-Light.woff2") format("woff2"),
    url("../fonts/Gotham-Light.woff") format("woff");
  font-display: swap;
  font-style: normal;
  font-weight: 300;
}

@font-face {
  font-family: "Gallery Gotham";
  src:
    url("../fonts/Gotham-Book.woff2") format("woff2"),
    url("../fonts/Gotham-Book.woff") format("woff");
  font-display: swap;
  font-style: normal;
  font-weight: 400;
}

:root {
  --page-bg: #151515;
  --text-primary: #fff;
  --text-muted: #919191;
  --line-muted: #4d4d4d;
  --gold: #c9a875;

  --font-gallery: "Gallery Gotham", "Helvetica Neue", Arial, sans-serif;

  --page-min: 900px;
  --content-max: 1250px;
  --content-side-gap: 61px;
  --edge-gap: 54px;

  --cell-width: 276px;
  --grid-column-gap: 46px;
  --grid-row-gap: 67px;
}

* {
  box-sizing: border-box;
}

html,
body {
  min-width: var(--page-min);
  min-height: 100%;
  margin: 0;
  background: var(--page-bg);
  overflow-anchor: none;
}

body {
  color: var(--text-primary);
  overflow-x: auto;
}

img,
video {
  display: block;
  max-width: 100%;
}

button {
  font: inherit;
}

.top-graphic {
  position: absolute;
  z-index: 2;
  display: block;
}

.top-graphic--logo {
  top: var(--edge-gap);
  left: var(--edge-gap);
  width: 142px;
  height: 30px;
  cursor: pointer;
}

.top-graphic--menu {
  top: var(--edge-gap);
  right: var(--edge-gap);
}

.top-graphic--logo img,
.fixed-menu__logo img {
  width: 100%;
  height: 100%;
}

.menu-button {
  width: 31px;
  height: 31px;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.menu-icon {
  display: block;
  width: 31px;
  height: 31px;
  overflow: hidden;
}

.menu-icon__line {
  stroke: var(--text-primary);
  stroke-linecap: butt;
  stroke-width: 0.996218px;
}

.top-graphic--logo:focus-visible,
.fixed-menu__logo:focus-visible,
.menu-button:focus-visible {
  outline: 1px solid var(--gold);
  outline-offset: 8px;
}

.fixed-menu {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 10;
  width: 100%;
  min-width: var(--page-min);
  height: 83px;
  background: var(--page-bg);
  pointer-events: none;
  transform: translateY(-83px);
  transition: transform 0.3s cubic-bezier(0.2, 0, 0.2, 1);
}

.fixed-menu.is-visible {
  pointer-events: auto;
  transform: translateY(0);
}

.fixed-menu::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 1px;
  background: var(--line-muted);
}

.fixed-menu__logo {
  position: absolute;
  top: 26px;
  left: var(--edge-gap);
  width: 142px;
  height: 30px;
  cursor: pointer;
}

.fixed-menu__icon {
  position: absolute;
  top: 28px;
  right: var(--edge-gap);
}

.content {
  width: min(var(--content-max), calc(max(100vw, var(--page-min)) - (var(--content-side-gap) * 2)));
  margin: 0 auto;
  padding-bottom: 160px;
}

.hero {
  padding-top: 173px;
}

.title-row {
  display: flex;
  align-items: flex-end;
  width: 100%;
  overflow: hidden;
}

.gallery-title {
  flex: 0 0 auto;
  width: 474px;
  height: 65px;
}

.title-line {
  flex: 1 1 auto;
  height: 1px;
  background: var(--gold);
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.placeholder {
  margin-top: 89px;
}

.placeholder video {
  width: 100%;
  height: auto;
}

.intro {
  width: min(1245px, 100%);
  margin-top: 50px;
  color: var(--text-primary);
  font-family: var(--font-gallery);
  font-size: 14px;
  font-style: normal;
  font-weight: 300;
  line-height: 24px;
  letter-spacing: 0;
  text-align: left;
  text-transform: none;
}

.intro p {
  margin: 0;
}

.gallery-groups {
  margin-top: 90px;
}

.gallery-group {
  position: relative;
}

.gallery-group + .gallery-group {
  margin-top: 120px;
}

.gallery-group__title {
  margin: 0;
  color: var(--text-primary);
  font-family: var(--font-gallery);
  font-size: 20px;
  font-weight: 300;
  line-height: 24px;
  letter-spacing: 0;
  text-align: left;
  text-transform: uppercase;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(2, var(--cell-width));
  column-gap: var(--grid-column-gap);
  row-gap: var(--grid-row-gap);
  justify-content: start;
  margin-top: 38px;
  position: relative;
  contain: layout;
}

.gallery-cell {
  width: var(--cell-width);
  max-width: 100%;
  border-top: 1px solid var(--line-muted);
}

.gallery-cell img {
  width: 100%;
  height: auto;
}

.gallery-cell__text {
  margin-top: 0;
  font-family: var(--font-gallery);
  font-style: normal;
  font-weight: 400;
  letter-spacing: 0;
  text-align: left;
}

.gallery-cell__details {
  margin: 0;
  color: var(--text-muted);
  font-size: 14px;
  line-height: 24px;
}

.gallery-cell__location {
  margin: 25px 0 0;
  color: var(--gold);
  font-size: 11px;
  line-height: 14px;
  letter-spacing: 0.01em;
  text-transform: uppercase;
}

[data-fade] {
  opacity: 0;
  transition: opacity 0.2s ease-out;
  transition-delay: var(--fade-delay, 0ms);
}

[data-fade].is-visible {
  opacity: 1;
}

@media (prefers-reduced-motion: reduce) {
  [data-fade],
  .fixed-menu {
    transition: none;
  }

  [data-fade] {
    opacity: 1;
  }
}

/* 3 columns need 3*276 + 2*46 = 920px content width, plus 122px gutters. */
@media (min-width: 1042px) {
  .gallery-grid {
    grid-template-columns: repeat(3, var(--cell-width));
  }
}

/* 4 columns need 4*276 + 3*46 = 1242px content width, plus 122px gutters. */
@media (min-width: 1364px) {
  .gallery-grid {
    grid-template-columns: repeat(4, var(--cell-width));
  }
}
