/* The map and the mark, shared by the drift pages and the studio.
   One authored motion: lines reveal left to right, the way fragments type in. */

/* The mark's letters are the map button; the period after them is the Aleph. */
.mark {
  font: inherit;
  color: inherit;
  text-shadow: inherit;
  text-transform: inherit;
  letter-spacing: inherit;
  background: none;
  border: 0;
  padding: 0;
  margin: 0;
  text-align: inherit;   /* buttons centre by default; the mark sits flush left */
  cursor: pointer;
  transition: color .4s ease;
}
.mark:hover { color: #ef6a42; }
.mark:focus-visible, .map a:focus-visible, .map button:focus-visible {
  outline: 1px solid #ef6a42;
  outline-offset: 6px;
}

/* The veil: the loop keeps moving behind it, dimmed and slightly softened. */
.map {
  position: fixed;
  inset: 0;
  z-index: 20;
  background: rgba(10, 10, 10, .84);
  backdrop-filter: blur(3px) saturate(.6);
  -webkit-backdrop-filter: blur(3px) saturate(.6);
  opacity: 0;
  transition: opacity .26s ease;
}
.map.is-open { opacity: 1; }
.map[hidden] { display: none; }

.map-inner {
  position: absolute;
  left: 8vw;
  right: 8vw;
  bottom: 7vh;
  max-width: 40rem;
  color: #fff;
}
@media (max-width: 640px) {
  .map-inner { left: 6vw; right: 6vw; bottom: 5vh; }
}

.map-here {
  font: italic .95rem "Crete Round", Georgia, serif;
  color: rgba(255, 255, 255, .55);
  margin: 0 0 1.4rem;
}

.map ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: .15em; }
.map li {
  font: italic clamp(1.6rem, 4.2vw, 2.6rem)/1.25 "Crete Round", Georgia, serif;
  clip-path: inset(0 100% 0 0);
  transition: clip-path .7s cubic-bezier(.16, 1, .3, 1);
  transition-delay: calc(var(--i, 0) * 70ms);
}
.map.is-open li { clip-path: inset(0 0 0 0); }
.map a, .map .map-link {
  color: #fff;
  text-decoration: none;
  font: inherit;
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
  transition: color .25s ease;
}
.map a:hover, .map .map-link:hover { color: #ef6a42; }
.map form { margin: 0; }
.map-aside {
  font-size: .5em;
  font-style: normal;
  color: rgba(255, 255, 255, .5);
  margin-left: .5em;
  vertical-align: .35em;
}

/* Close sits under the list, in the same column. */
.map-close {
  display: block;
  margin-top: 1.6rem;
  padding: 0;
  font: italic .95rem "Crete Round", Georgia, serif;
  color: rgba(255, 255, 255, .55);
  background: none;
  border: 0;
  cursor: pointer;
}
.map-close:hover { color: #ef6a42; }

/* Panels: sign in and join, over the drift, in the map's place and type. */
.panel-inner { max-width: 30rem; }
.panel-body { display: flex; flex-direction: column; gap: 1rem; font: 1.05rem/1.5 "Crete Round", Georgia, serif; }
.panel-body[aria-busy="true"] { opacity: .4; transition: opacity .2s; }
.panel-body .lede { font: italic clamp(1.6rem, 4.2vw, 2.4rem)/1.2 "Crete Round", Georgia, serif; }
.panel-body .quiet { color: rgba(255, 255, 255, .6); font-size: .95rem; }
.panel-body .note { color: #ef6a42; }
.panel-body a { color: inherit; text-decoration-color: rgba(255, 255, 255, .3); text-underline-offset: .2em; }
.panel-body a:hover { color: #ef6a42; }
.panel-body form { display: flex; flex-direction: column; gap: 1rem; }
.panel-body label { display: flex; flex-direction: column; gap: .35rem; color: rgba(255, 255, 255, .6); font-size: .95rem; }
.panel-body .field { display: flex; align-items: baseline; color: rgba(255, 255, 255, .6); }
.panel-body input {
  font: inherit; font-size: 1.15rem; color: #fff; background: transparent;
  border: 0; border-bottom: 1px solid rgba(255, 255, 255, .35); border-radius: 0; padding: .35rem 0; width: 100%;
}
.panel-body .field input { width: auto; flex: 1; min-width: 0; }
.panel-body input:focus { outline: none; border-bottom-color: #ef6a42; }
.panel-body button {
  align-self: flex-start; font: italic 1.05rem "Crete Round", Georgia, serif;
  color: #111; background: #fff; border: 0; padding: .55rem 1.1rem; cursor: pointer;
}
.panel-body button:hover { background: #ef6a42; }
.panel-body button:focus-visible, .panel-body a:focus-visible { outline: 1px solid #ef6a42; outline-offset: 4px; }

@media (prefers-reduced-motion: reduce) {
  .map, .map li { transition: none; }
  .map li { clip-path: none; }
}

/* Browser surfaces, in the palette. */
::selection { background: #ef6a42; color: #111; }
