.background-explore, .background-explorer__close {
  display: inline-flex; align-items: center; gap: 12px; min-height: 44px; padding: 10px 15px;
  font: 500 13px/1.4 var(--sans); color: var(--ink); border: 1px solid var(--rule);
  border-radius: 999px; background: var(--atmosphere-glass, var(--paper));
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); cursor: pointer;
}
.background-explore { margin-bottom: 18px; }
.background-explore:hover, .background-explorer__close:hover { border-color: var(--accent); }
.background-explore:active { transform: scale(.98); }
.background-explorer {
  position: fixed; inset: 0; width: 100%; height: 100%; max-width: none; max-height: none;
  margin: 0; padding: 0; border: 0; overflow: auto; background: #9fcdf0; color: #152a45;
}
.background-explorer[data-scene='night'] { background: #0c102d; color: #f1efff; }
.background-explorer::backdrop { background: transparent; }
.background-explorer__close { position: fixed; z-index: 2; background: #f5f8f3ed; color: #152a45; border-color: #627b92; }
.background-explorer[data-scene='night'] .background-explorer__close { background: #20294fed; color: #f1efff; border-color: #7d8bb8; }
.background-explorer__close span { font-size: 20px; line-height: 1; }
.background-explorer__art { position: absolute; width: min(100%, 177.68dvh); aspect-ratio: 1672 / 941; top: 50%; left: 50%; transform: translate(-50%, -50%); margin: 0; }
.background-explorer__image { display: block; width: 100%; height: 100%; object-fit: contain; }
 .background-explorer, .background-explorer button { font-family: 'Geist', sans-serif; }
.background-explorer__cities { position: absolute; inset: 0; pointer-events: none; }
.background-explorer__cities[hidden] { display: none; }
.background-explorer__city { position: absolute; width: 227px; box-sizing: border-box; padding: 16px 12px; border-radius: 12px; background: rgb(248 252 255 / 76%); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); text-align: left; color: #152a45; pointer-events: auto; }
.background-explorer__city[data-city='Chennai'] { left: 7%; top: 40%; }
.background-explorer__city[data-city='Boston'] { left: 36%; top: 51%; }
.background-explorer__city[data-city='New Orleans'] { right: 7%; top: 59%; }
.background-explorer__city h2 { margin: 0 0 20px; font: 500 16px/1.4 'Geist', sans-serif; }
.background-explorer__city p { margin: 0; font: 400 15px/1.5 'Geist', sans-serif; }
.background-explorer__sticker { position: absolute; top: -104px; right: -20px; display: block; width: 130px; height: 130px; max-width: none; object-fit: contain; pointer-events: none; }
/* The cap artwork has more transparent padding than the coffee sticker. */
.background-explorer__city[data-city='Boston'] .background-explorer__sticker { top: -78px; }
.background-explorer[data-scene] .background-explorer__close { position: absolute; inset: 0 0 auto; width: 100%; height: 32%; padding: 0 24px; display: flex; justify-content: center; align-items: center; border: 0; border-radius: 0; background: transparent; backdrop-filter: none; -webkit-backdrop-filter: none; text-align: center; font: 400 16px/1.5 'Geist', sans-serif; }
.background-explorer__close:focus-visible { outline: 2px solid currentColor; outline-offset: -6px; }
.background-explorer__caption { position: absolute; bottom: 2%; left: 50%; transform: translateX(-50%); width: max-content; max-width: 94%; padding: 6px 12px; border-radius: 8px; background: #f8fbf5e8; font: 400 18px/1.5 'Geist', sans-serif; color: #173653; text-align: center; }
.background-explorer[data-scene='night'] .background-explorer__caption { background: #20294fe8; color: #f1efff; }
.exploring-background { overflow: hidden; }
/* The native modal makes the mounted portfolio inert; keep it painted beneath
   the opacity transition so there is never a blank frame. */
@media (max-width: 900px), (max-height: 650px) {
  /* Keep the landscape intact. The dialog becomes a single, horizontally
     scrollable canvas instead of turning the city notes into a vertical feed. */
  .background-explorer { overflow-x: auto; overflow-y: hidden; overscroll-behavior-x: contain; }
  .background-explorer__art {
    position: relative; top: auto; left: auto; transform: none;
    width: 177.68svh; min-width: 177.68svh; height: 100svh;
    margin: 0; max-width: none;
  }
  .background-explorer__image { object-fit: cover; }
  .background-explorer__cities { position: absolute; display: block; inset: 0; padding: 0; }
  .background-explorer__city[data-city] { position: absolute; width: 227px; max-width: none; }
  .background-explorer[data-scene] .background-explorer__close {
    position: fixed; inset: 0 0 auto; width: 100vw; height: 22svh;
  }
}
@media (max-width: 979px) {
  /* Keep the first mobile viewport focused on the introduction. */
  .background-explore { display: none; }
}
@media (prefers-reduced-motion: reduce) { .background-explore:active { transform: none; } }
@media (prefers-reduced-transparency: reduce) { .background-explore, .background-explorer__close { backdrop-filter: none; -webkit-backdrop-filter: none; background: var(--paper); color: var(--ink); } }

@media (prefers-reduced-transparency: reduce) { .background-explorer__city { background: #f8fcff; backdrop-filter: none; -webkit-backdrop-filter: none; } }

/* A brief, overlapping reveal keeps the three notes feeling connected. */
.background-explorer[open][data-animate-cities='true'] .background-explorer__city {
  animation: city-note-enter 280ms cubic-bezier(.23,1,.32,1) both;
  animation-delay: 60ms;
}
.background-explorer[open][data-animate-cities='true'] .background-explorer__city:nth-child(2) { animation-delay: 140ms; }
.background-explorer[open][data-animate-cities='true'] .background-explorer__city:nth-child(3) { animation-delay: 220ms; }
@keyframes city-note-enter {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}
@media (prefers-reduced-motion: reduce) {
  .background-explorer[open][data-animate-cities='true'] .background-explorer__city { animation: none; }
}
