.museum-heading {
  border-bottom: 1px solid var(--line);
  background: #eeece1;
}

.museum-heading-inner {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1.5rem 3rem;
  padding-block: clamp(2.75rem, 6vw, 5.75rem);
}

.museum-heading h1 {
  margin: .7rem 0 .85rem;
  font-size: clamp(3rem, 7.1vw, 6.5rem);
  letter-spacing: -.05em;
  line-height: .99;
}

.museum-intro { max-width: 33rem; color: var(--muted); }

.museum-outline {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: .8rem;
  border: 1px solid #ab9c7b;
  padding: .65rem 1rem;
  font-size: .83rem;
  font-weight: 600;
}

.museum-outline span,
.museum-room-arrow { color: var(--bronze); }

.museum-outline:hover,
.museum-room:hover {
  border-color: var(--bronze);
  background: #f3eee2;
}

.museum-section { padding-block: clamp(2rem, 5vw, 4.5rem) clamp(3rem, 7vw, 6rem); }

.museum-rooms {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: .75rem;
  padding: 0;
  margin: 0;
  list-style: none;
}

.museum-room {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: .55rem .75rem;
  height: 100%;
  min-height: 5rem;
  padding: .8rem;
  border: 1px solid var(--line);
  background: #fbf9f2;
}

.museum-room-title { display: grid; gap: .15rem; }

.museum-room-title strong {
  font: clamp(1.21rem, 2vw, 1.65rem)/1.1 var(--display);
  overflow-wrap: anywhere;
}

.museum-room-title > span { color: var(--muted); font-size: .76rem; line-height: 1.45; }
.museum-room-arrow { align-self: start; }
.museum-directory .museum-room {
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-rows: auto auto 1fr auto;
  align-items: start;
  min-height: 10.4rem;
  padding: 0 1.25rem 1.25rem;
}

.museum-room-theme,
.museum-room-status { grid-column: 1 / -1; }
.museum-room-theme { color: var(--muted); font-size: .92rem; }
.museum-room-status { color: var(--bronze); font-size: .75rem; font-weight: 650; }

@media (max-width: 850px) {
  .museum-directory { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 650px) {
  .museum-heading-inner { display: block; }
  .museum-outline { margin-top: 1.1rem; }
}

@media (max-width: 470px) {
  .museum-directory { grid-template-columns: 1fr; }
  .museum-directory .museum-room { min-height: 8.75rem; }
}

.museum-heading--map .museum-heading-inner,
.museum-heading--directory .museum-heading-inner { padding-block: clamp(2.35rem, 4vw, 4rem); }
.floor-plan-section { padding-top: clamp(1.5rem, 4vw, 3.4rem); }

.floor-plan {
  --paper-line: #d9cdb3;
  --map-lane: #ac9a75;
  --map-fill: #f0ebdc;
  --map-gap: clamp(.7rem, 1.4vw, 1.2rem);
  padding: clamp(.85rem, 2.5vw, 2rem);
  border: 1px solid #c7bb9e;
  background-color: var(--map-fill);
  background-image: linear-gradient(#aa9b7918 1px, transparent 1px), linear-gradient(90deg, #aa9b7918 1px, transparent 1px);
  background-position: center;
  background-size: 24px 24px;
}

.floor-plan-locations {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--map-gap);
  margin: 0;
  padding: 0;
  list-style: none;
}

.map-core, .map-threshold { grid-column: 1 / -1; }
.map-core { display: grid; place-items: center; padding: .8rem .3rem; }

.map-rotunda {
  position: relative;
  isolation: isolate;
  display: grid;
  place-items: end center;
  width: min(100%, 24rem);
  min-height: 11.5rem;
  aspect-ratio: 1.65;
  overflow: hidden;
  border: 1px solid #c1ab7c;
  border-radius: 48% 48% 2.5rem 2.5rem / 76% 76% 2.5rem 2.5rem;
  outline: 1px solid var(--map-lane);
  outline-offset: 5px;
  background: var(--forest);
  color: var(--paper);
  text-align: center;
}

.map-rotunda img, .map-rotunda::after {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.map-rotunda img { z-index: -2; object-fit: cover; }
.map-rotunda::after { content: ""; z-index: -1; background: linear-gradient(0deg, #171f18 5%, #171f18d9 22%, transparent 75%); }
.map-rotunda figcaption { padding: 0 .5rem 1.35rem; }
.map-rotunda figcaption > span { color: #efcf97; font-size: .68rem; font-weight: 650; letter-spacing: .11em; text-transform: uppercase; }
.map-rotunda h2 { margin-top: .2rem; font-size: clamp(1.85rem, 4vw, 3rem); }

.map-door {
  position: relative;
  display: grid;
  gap: .5rem;
  align-content: center;
  min-height: 8rem;
  height: 100%;
  padding: .7rem .75rem .82rem;
  border: 1px solid var(--paper-line);
  background: #fbf8ee;
}

.map-door:hover, .map-door:focus-visible {
  z-index: 2;
  border-color: var(--bronze);
  background: #fffdf6;
}

.map-door:focus-visible, .map-threshold a:focus-visible { outline: 2px solid var(--bronze); outline-offset: 2px; }

.map-door-arch {
  display: grid;
  width: 2.15rem;
  height: 2.45rem;
  place-items: center;
  border: 1px solid #baaa88;
  border-radius: 1rem 1rem .15rem .15rem;
  background: #f1ead9;
  color: #635135;
}

.map-door-icon { width: 1.27rem; height: 1.27rem; }
.map-door-arrow { position: absolute; top: .9rem; right: .75rem; color: var(--bronze); }
.map-door .museum-room-title strong { font-size: clamp(1.15rem, 1.65vw, 1.5rem); }

.map-threshold { text-align: center; }
.map-threshold a {
  position: relative;
  display: inline-flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: baseline;
  gap: .25rem .55rem;
  min-height: 44px;
  padding: .55rem .8rem;
  border: 1px solid #b2a078;
  background: #e8dfca;
  color: var(--ink);
  font-family: var(--display);
}

.map-threshold a:hover { background: #f7f2e4; }
.map-threshold a > span:first-child { color: var(--bronze); }
.map-threshold-caption { flex-basis: 100%; color: #565e50; font: .7rem/1.3 var(--sans); }

@media (min-width: 850px) {
  .floor-plan-locations {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    grid-template-areas:
      ". calliope clio euterpe ."
      "erato core core core melpomene"
      "polyhymnia core core core terpsichore"
      "thalia core core core urania"
      ". . threshold . .";
  }

  .map-core {
    grid-area: core;
    background:
      linear-gradient(var(--map-lane), var(--map-lane)) center / 1px 100% no-repeat,
      linear-gradient(var(--map-lane), var(--map-lane)) center / 100% 1px no-repeat,
      linear-gradient(var(--paper-line), var(--paper-line)) center 16.67% / 100% 1px no-repeat,
      linear-gradient(var(--paper-line), var(--paper-line)) center 83.33% / 100% 1px no-repeat,
      linear-gradient(var(--paper-line), var(--paper-line)) 16.67% center / 1px 50% no-repeat,
      linear-gradient(var(--paper-line), var(--paper-line)) 83.33% center / 1px 50% no-repeat,
      #ede6d6;
    border: 1px solid var(--map-lane);
  }

  .map-rotunda {
    width: min(77%, 20rem);
    aspect-ratio: 1;
    border-radius: 50%;
    box-shadow: 0 0 0 5px var(--map-fill), 0 0 0 10px var(--map-fill), 0 0 0 11px #cabd9e;
  }

  .map-rotunda figcaption { padding-bottom: clamp(2.4rem, 5vw, 4rem); }
  .map-threshold { grid-area: threshold; }
  .map-threshold a { display: flex; }

  .map-doorway, .map-threshold { position: relative; }
  .map-doorway::after, .map-threshold::after { content: ""; position: absolute; background: var(--map-lane); pointer-events: none; }
  :is(.map-doorway--calliope, .map-doorway--clio, .map-doorway--euterpe)::after,
  .map-threshold::after { width: 1px; height: var(--map-gap); left: 50%; top: 100%; }
  .map-threshold::after { top: auto; bottom: 100%; }
  :is(.map-doorway--erato, .map-doorway--polyhymnia, .map-doorway--thalia)::after {
    top: 50%;
    left: 100%;
    width: var(--map-gap);
    height: 1px;
  }
  :is(.map-doorway--melpomene, .map-doorway--terpsichore, .map-doorway--urania)::after {
    top: 50%;
    right: 100%;
    width: var(--map-gap);
    height: 1px;
  }

  .map-doorway--calliope { grid-area: calliope; }
  .map-doorway--clio { grid-area: clio; }
  .map-doorway--euterpe { grid-area: euterpe; }
  .map-doorway--erato { grid-area: erato; }
  .map-doorway--melpomene { grid-area: melpomene; }
  .map-doorway--polyhymnia { grid-area: polyhymnia; }
  .map-doorway--terpsichore { grid-area: terpsichore; }
  .map-doorway--thalia { grid-area: thalia; }
  .map-doorway--urania { grid-area: urania; }
}

@media (max-width: 570px) {
  .floor-plan-locations { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .map-doorway--urania { grid-column: 1 / -1; }
}

.muse-panorama {
  margin: 0 0 clamp(2.4rem, 5vw, 4.75rem);
  padding: clamp(.35rem, 1vw, .65rem);
  border: 1px solid #ae9b6e;
  background: #171e19;
  color: #f0deba;
}

.muse-panorama img {
  width: 100%;
  height: auto;
  aspect-ratio: 1672 / 941;
  object-fit: cover;
}

.muse-panorama figcaption { padding: .65rem .35rem .25rem; font-size: .8rem; }
.muse-directory-title { margin-bottom: 1.15rem; font-size: clamp(2rem, 4vw, 3.25rem); }

.museum-directory .museum-room-title { margin-top: .25rem; }
.museum-directory .museum-room-arrow { margin-top: .35rem; }
.museum-directory .museum-room-arrow,
.museum-directory .museum-room-status { color: var(--muse-accent); }

.museum-room-emblem {
  position: relative;
  isolation: isolate;
  display: grid;
  grid-column: 1 / -1;
  place-items: center;
  overflow: hidden;
  min-height: clamp(6.75rem, 11vw, 8.75rem);
  margin: 0 -1.25rem .2rem;
  border-bottom: 1px solid var(--muse-accent);
  color: var(--muse-light);
  background: radial-gradient(ellipse at 50% 120%, var(--muse-accent), transparent 74%), var(--muse-shadow);
}

.museum-room-emblem::before,
.museum-room-emblem::after {
  position: absolute;
  z-index: -1;
  left: 50%;
  bottom: -.25rem;
  width: 6.6rem;
  height: 5.65rem;
  border: 1px solid currentColor;
  border-radius: 50% 50% 0 0 / 62% 62% 0 0;
  content: "";
  opacity: .32;
  transform: translateX(-50%);
}

.museum-room-emblem::after { width: 7.65rem; height: 6.4rem; opacity: .15; }
.museum-room-emblem .muse-icon { border-color: currentColor; background: var(--muse-shadow); color: inherit; }
