body.em-portfolio-page {
  margin: 0;
  background: #f6f1e9;
  color: #302823;
}

.em-portfolio-page .em-prewed-banner {
  position: relative;
  isolation: isolate;
  display: grid;
  place-items: center;
  min-height: clamp(19rem, 42vw, 34rem);
  padding: 7rem 1rem 3rem;
  text-align: center;
  color: #fffaf1;
  background: radial-gradient(ellipse at 50% 35%, #4b3930, #241d18 72%);
}

.em-portfolio-page .em-prewed-banner__image,
.em-portfolio-page .em-prewed-banner__overlay {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
}

.em-portfolio-page .em-prewed-banner__image { object-fit: cover; }
.em-portfolio-page .em-prewed-banner__overlay {
  background: linear-gradient(180deg, rgb(26 20 16 / 66%), rgb(26 20 16 / 33%) 48%, rgb(26 20 16 / 51%));
}
.em-portfolio-page .em-prewed-banner--type .em-prewed-banner__overlay { display: none; }

.em-portfolio-page .em-portfolio-banner-script {
  margin: 0 0 .45rem;
  color: #f5e2ca;
  font: 400 clamp(1.85rem, 4.1vw, 4.3rem) / 1 Sacramento, cursive;
}

.em-portfolio-page .em-prewed-banner__title {
  max-width: 20ch;
  margin: 0 auto;
  font: 500 clamp(2.2rem, 6vw, 6rem) / 1.04 "Bodoni Moda", Georgia, serif;
  letter-spacing: -.035em;
  text-wrap: balance;
}

.em-portfolio-page[data-portfolio-view="event"] .em-prewed-banner {
  min-height: clamp(16rem, 26vw, 24rem);
  padding-bottom: 2.5rem;
}

.em-portfolio-page .em-prewed-gallery-section { padding: clamp(1.65rem, 4vw, 4rem) 0; }

.em-portfolio-page .em-prewed-gallery {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(1.2rem, 1vw, 0.4rem) clamp(.75rem, 0.6vw, 2.5rem);
  width: min(100% - clamp(2rem, 6vw, 7rem), 111rem);
  margin: 0 auto;
}

.em-portfolio-page .em-collection-link {
  display: grid;
  align-content: start;
  gap: .3rem;
  color: inherit;
  text-align: center;
  text-decoration: none;
}

.em-portfolio-page .em-collection-link:focus-visible {
  outline: 2px solid #8b6244;
  outline-offset: 5px;
}

.em-portfolio-page .em-portfolio-card-media {
  display: block;
  position: relative;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  background: #e2d9d0;
}

.em-portfolio-page .em-portfolio-card-media > img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.em-portfolio-page .em-collection-name {
  padding-top: .4rem;
  font: 500 clamp(1rem, 2vw, 1.45rem) / 1.2 "Bodoni Moda", Georgia, serif;
  text-wrap: balance;
}

.em-portfolio-page .em-collection-type {
  color: #67594e;
  font: 400 .88rem / 1.3 "Bodoni Moda", Georgia, serif;
}

.em-portfolio-page .em-collection-read,
.em-portfolio-page .em-collection-back {
  color: #594739;
  font: 600 .72rem / 1.5 "Bodoni Moda", Georgia, serif;
  text-transform: uppercase;
  letter-spacing: .14em;
}
.em-portfolio-page .em-collection-read { margin-top: .35rem; }
.em-portfolio-page .em-collection-link:is(:hover, :focus-visible) .em-collection-read {
  text-decoration: underline;
  text-underline-offset: .25em;
}

.em-portfolio-page .em-collection-back {
  display: table;
  margin: 0 auto 1.4rem;
  text-underline-offset: .25em;
}

.em-event-story {
  display: grid;
  gap: clamp(.55rem, 1.2vw, 1rem);
  width: min(66.6667%, 76rem);
  margin: 0 auto;
}

.em-event-row { display: grid; gap: inherit; }
.em-event-row--pair {
  grid-template-columns: minmax(0, var(--first-photo)) minmax(0, var(--second-photo));
  align-items: start;
}

.em-event-photo {
  position: relative;
  min-width: 0;
  margin: 0;
}

.em-event-row--single .em-event-photo { width: 100%; }

.em-event-photo > img {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
  object-fit: contain;
}

@media (max-width: 1050px) {
  .em-portfolio-page .em-prewed-gallery { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .em-event-story { width: min(84%, 60rem); }
}

@media (max-width: 720px) {
  .em-portfolio-page .em-prewed-gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .em-event-story { width: calc(100% - 1.5rem); }
}
@media (max-width: 480px) {
  .em-event-row--pair { grid-template-columns: minmax(0, 1fr); }
}

.em-portfolio-page, .em-portfolio-page :is(#site-header, .em-site-footer),
.em-portfolio-page :is(#site-header a, .em-site-footer a) {
  font-family: "Bodoni Moda", Georgia, serif !important;
}
.em-portfolio-page .em-portfolio-banner-script {
  letter-spacing: normal;
  text-transform: capitalize;
}
@media (max-width: 767px) {
  .em-portfolio-page[data-portfolio-view="category"] .em-prewed-gallery {
    grid-template-columns: minmax(0, 1fr);
    width: min(100% - 2rem, 31rem);
  }
  .em-portfolio-page[data-portfolio-view="category"] .em-prewed-banner {
    min-height: clamp(24rem, 69svh, 36rem);
  }
}

.em-event-back-row {
  display: flex;
  justify-content: flex-start;
  width: min(66.6667%, 76rem);
  margin: 0 auto 1rem;
}
.em-portfolio-page .em-event-back-row .em-collection-back {
  display: inline-grid;
  place-items: center;
  min-width: 44px;
  min-height: 44px;
  margin: 0;
  padding: 0;
}
.em-event-back-row svg {
  width: 26px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}
@media (max-width: 1050px) {
  .em-event-back-row { width: min(84%, 60rem); }
}
@media (max-width: 720px) {
  .em-event-back-row { width: calc(100% - 1.5rem); }
}
