:root {
  --deep-teal: #101e22;
  --gold: #f0bd70;
  --paper: #faf9f5;
  --line: #cdd1c7;
}

.topbar { background: #101b1e; border-color: #354041; }
.desktop-nav { gap: clamp(1rem, 2.15vw, 2.3rem); }

.showcase {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  background: var(--deep-teal);
  color: white;
}
.showcase-art { position: absolute; z-index: -1; inset: 0; }
.showcase-art img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 22%; }
.showcase-art::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgb(9 22 26 / .83), rgb(9 22 26 / .64) 26%, rgb(9 22 26 / .25) 48%, transparent 67%);
}
.showcase-content { display: flex; align-items: center; min-height: clamp(31rem, 44vw, 50rem); }
.showcase-copy { max-width: 49%; padding-block: clamp(4rem, 7vw, 7.5rem); }
.showcase h1 {
  font-size: clamp(2.8rem, 4.65vw, 5.2rem);
  line-height: 1.21;
  letter-spacing: -.067em;
  font-weight: 740;
}
.showcase h1 span { color: var(--gold); }
.showcase-copy p {
  color: #f3f2ea;
  font-size: clamp(1rem, 1.2vw, 1.15rem);
  max-width: 23em;
  line-height: 1.91;
  margin: 1.25rem 0 1.8rem;
}
.showcase .primary-button { min-height: 3rem; color: #1c2522; background: #fff9e8; }
.showcase .primary-button:hover { background: white; }
.showcase-credit {
  position: absolute;
  right: max(var(--edge), calc((100% - 82rem) / 2));
  bottom: 1.2rem;
  display: inline-flex;
  gap: .65rem;
  align-items: center;
  min-height: 44px;
  padding: .45rem .9rem;
  color: white;
  background: rgb(13 25 28 / .79);
  border: 1px solid #ffffff80;
  border-radius: .2rem;
  font-size: .875rem;
  text-decoration: none;
}
.showcase-credit:hover { background: var(--deep-teal); }

.directions { display: grid; grid-template-columns: minmax(0, 1.9fr) minmax(0, 1fr); align-items: stretch; gap: clamp(1.5rem, 3.6vw, 4rem); }
.card-study {
  display: grid;
  grid-template-columns: minmax(0, .88fr) minmax(0, 1fr);
  min-height: clamp(17rem, 24vw, 23rem);
  background: #eaece3;
}
.portrait-frame { position: relative; display: block; min-height: 100%; background: #233437; color: #fff7db; text-decoration: none; }
.portrait-frame img { position: absolute; inset: 0 0 auto; width: 100%; height: calc(100% - 2.3rem); padding: .55rem .55rem 0; object-fit: contain; }
.portrait-caption { position: absolute; inset: auto 0 0; display: flex; align-items: center; justify-content: center; gap: .4rem; min-height: 2.3rem; font-size: .875rem; }
.portrait-caption .expand-mark { width: .7rem; height: .7rem; }
.portrait-frame:hover .portrait-caption { color: #f5ca7d; }
.study-copy { align-self: center; padding: clamp(1.1rem, 2.5vw, 2.6rem); }
.study-copy h3 { font-size: clamp(1.6rem, 2.4vw, 2.5rem); line-height: 1.23; letter-spacing: -.052em; }
.study-copy p { color: #47524c; font-size: 1rem; margin-top: .75rem; line-height: 1.85; }
.board-link {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: .55rem;
  padding-block: .45rem;
  margin-top: 1.1rem;
  min-height: 44px;
  font-size: .9rem;
  font-weight: 650;
  text-decoration: none;
}
.board-link img { width: 2.9rem; height: 2.15rem; object-fit: cover; border: 1px solid #8d9185; }
.board-link:hover span:first-of-type { text-decoration: underline; text-underline-offset: .25em; }
.board-link .expand-mark { width: .72rem; height: .72rem; }
.directions .genre-list article { align-content: center; }

.art-library { background: #142426; color: #f5f5eb; }
.library-lead { display: flex; align-items: baseline; justify-content: space-between; gap: 1.4rem; margin-bottom: clamp(1.7rem, 3.5vw, 3.1rem); }
.library-lead p { color: #c2cfca; font-size: 1rem; }
.gallery-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(1.55rem, 3vw, 3rem) clamp(1.15rem, 2.6vw, 2.5rem); }
.gallery-piece { display: block; text-decoration: none; }
.piece-image { position: relative; overflow: hidden; aspect-ratio: 2.04; background: #263739; }
.piece-image img { width: 100%; height: 100%; object-fit: cover; }
.ensemble-piece .piece-image img { object-position: 50% 16%; }
.piece-caption { display: flex; align-items: center; justify-content: space-between; gap: .6rem; padding: .9rem .1rem .8rem; border-bottom: 1px solid #506363; }
.piece-caption h3 { font-size: clamp(1.15rem, 1.6vw, 1.5rem); letter-spacing: -.025em; line-height: 1.4; }
.piece-caption .expand-mark { flex: none; width: .85rem; height: .85rem; color: #dbcba8; }
.gallery-piece:hover .piece-caption { border-color: #eccb91; }
.gallery-piece:hover h3 { color: #ffdb97; }

.image-viewer {
  position: fixed;
  padding: 0;
  width: min(92vw, 87rem);
  max-width: 100%;
  max-height: 93dvh;
  color: #f4f1e7;
  background: #101b1e;
  border: 1px solid #506063;
  border-radius: .2rem;
}
.image-viewer::backdrop { background: rgb(7 15 17 / .91); }
.image-viewer img { width: 100%; max-height: 78dvh; height: auto; object-fit: contain; }
.image-error { padding: 1.4rem; }
html:has(.image-viewer[open]) { overflow: hidden; }

@media (min-width: 45.01rem) and (max-width: 61rem) {
  .directions { grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr); gap: 1.45rem; }
  .card-study { grid-template-columns: minmax(0, .68fr) minmax(0, 1fr); }
  .study-copy { padding: 1rem; }
  .board-link img { display: none; }
}

@media (max-width: 45rem) {
  .showcase { --mobile-art-height: clamp(15rem, 67vw, 24rem); display: flex; flex-direction: column; }
  .showcase-art { position: relative; z-index: 0; inset: auto; width: 100%; height: var(--mobile-art-height); }
  .showcase-art img { object-position: 50% 22%; }
  .showcase-art::after { background: linear-gradient(0deg, var(--deep-teal), transparent 28%); }
  .showcase-content { min-height: auto; }
  .showcase-copy { max-width: 100%; padding-block: .4rem 2.65rem; }
  .showcase h1 { font-size: clamp(2.45rem, 8.8vw, 3.6rem); }
  .showcase-copy p { max-width: 31rem; margin: .9rem 0 1.35rem; }
  .showcase-credit { inset: calc(var(--mobile-art-height) - .75rem) .8rem auto auto; transform: translateY(-100%); }
  .directions { grid-template-columns: 1fr; gap: 1.55rem; }
  .card-study { grid-template-columns: minmax(0, .78fr) minmax(0, 1.12fr); min-height: clamp(14rem, 47vw, 18rem); }
  .study-copy { padding: 1rem clamp(.85rem, 4vw, 1.5rem); }
  .study-copy p { margin-top: .5rem; }
  .board-link { gap: .35rem; }
  .directions .genre-list article { border-top: 1px solid var(--line); padding-block: 1.15rem; }
  .library-lead { display: block; }
  .library-lead p { margin-top: .6rem; }
}

@media (max-width: 35rem) {
  .gallery-grid { grid-template-columns: 1fr; }
  .piece-image { aspect-ratio: 1.83; }
  .piece-caption { padding-block: .65rem .7rem; }
  .board-link img { display: none; }
}

@media (prefers-reduced-motion: no-preference) and (hover: hover) {
  .piece-image img { transition: transform .35s ease; }
  .gallery-piece:hover .piece-image img { transform: scale(1.02); }
}
