.project-showcase {
  --showcase-paper: #f9f7f1;
  --showcase-ink: #172d26;
  --showcase-columns: 5;
  --showcase-rows: 3;
  position: fixed;
  inset: 0;
  isolation: isolate;
  display: none;
  width: 100%;
  max-width: none;
  height: 100%;
  max-height: none;
  margin: 0;
  padding: 0;
  overflow: hidden;
  border: 0;
  background: transparent;
  color: var(--showcase-ink);
}

.project-showcase[open] {
  display: grid;
  grid-template-rows: var(--header-height) minmax(0, 1fr);
}

.project-showcase::backdrop { background: transparent; }

.showcase-fill,
.showcase-flights {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.showcase-fill {
  z-index: 0;
  background: var(--showcase-paper);
}

.showcase-chrome {
  position: relative;
  z-index: 3;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 var(--gutter) 1px;
  overflow: hidden;
  overflow: clip;
}

.showcase-chrome h2 {
  margin: 0;
}

.showcase-chrome h2:focus { outline: none; }

.showcase-close {
  display: grid;
  flex: none;
  place-items: center;
  width: 2.75rem;
  height: 2.75rem;
  padding: 0;
  border: 0;
  border-radius: .25rem;
  background: transparent;
  color: var(--showcase-ink);
  font-size: 1.55rem;
  line-height: 1;
  cursor: pointer;
}

.showcase-close:hover { background: #e9ede4; }

.showcase-board {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(var(--showcase-columns), minmax(0, 1fr));
  grid-template-rows: repeat(var(--showcase-rows), minmax(0, 1fr));
  min-width: 0;
  min-height: 0;
}

.showcase-card {
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
  min-width: 0;
  min-height: 0;
  padding: 0;
  overflow: hidden;
  appearance: none;
  border: 0;
  border-radius: 0;
  background: transparent;
  cursor: pointer;
}

.showcase-card:focus-visible {
  outline: 2px solid white;
  outline-offset: -4px;
  box-shadow: inset 0 0 0 6px var(--showcase-ink);
}

.showcase-photo,
.showcase-photo img {
  width: 100%;
  height: 100%;
}

.showcase-photo { display: block; overflow: hidden; }
.showcase-photo img { object-fit: cover; }

.showcase-name {
  position: absolute;
  inset: auto 0 0;
  padding: .8rem clamp(.4rem, .9vw, .85rem) .38rem;
  background: linear-gradient(to top, #0b1612de, #0b1612bc calc(100% - .8rem), #0b161200);
  color: white;
  font-size: clamp(.8125rem, 1.07vw, .95rem);
  font-weight: 600;
  line-height: 1.14;
  text-align: start;
  overflow-wrap: anywhere;
  pointer-events: none;
}

.showcase-flights {
  z-index: 4;
  overflow: hidden;
  clip-path: inset(var(--header-height) 0 0);
}

.showcase-flight {
  position: absolute;
  top: 0;
  left: 0;
  max-width: none;
  object-fit: cover;
}

@media (orientation: portrait) {
  .project-showcase {
    --showcase-columns: 3;
    --showcase-rows: 5;
  }
}
