/* The frame around every room: view layout and states, the footer, and the phone dock. */

/* ---------- Views ---------- */

.view {
  width: 100%;
  max-width: var(--measure);
  margin: 0 auto;
  padding: 24px var(--gutter) 72px;
  outline: none;
  min-height: 40vh;
}
.view-head {
  display: grid;
  gap: 10px;
  margin: 12px 0 28px;
}
.kicker {
  margin: 0;
  font: 600 12px/1 var(--mono);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--acid);
}
.view-title {
  margin: 0;
  font-size: clamp(44px, 9vw, 104px);
  line-height: 0.9;
  font-weight: 800;
  letter-spacing: -0.035em;
  text-wrap: balance;
  overflow-wrap: anywhere;
}
.view-title em {
  font-family: var(--serif);
  font-weight: 500;
  font-size-adjust: 0.47;
  font-weight: 400;
  font-style: italic;
  letter-spacing: -0.01em;
  color: var(--bone-2);
}
.view-title .acid {
  color: var(--acid);
}
.view-lede {
  font-family: var(--read);
  font-weight: 400;
  font-optical-sizing: auto;
  margin: 0;
  max-width: 60ch;
  color: var(--bone-2);
  font-size: clamp(16px, 2.2vw, 19px);
}

.state {
  display: grid;
  justify-items: center;
  gap: 14px;
  padding: 56px 20px;
  text-align: center;
  border: 1px dashed var(--line-2);
  border-radius: var(--radius);
  color: var(--bone-2);
}
.state-title {
  margin: 0;
  font-size: clamp(24px, 5vw, 34px);
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: -0.02em;
  max-width: 22ch;
  text-wrap: balance;
}
.state p {
  margin: 0;
  max-width: 46ch;
}
/* the medallion: a cut-corner plate, an engraved line glyph, a low acid glow. never a stock emoji. */
.state-mark {
  position: relative;
  width: 76px;
  height: 76px;
  display: grid;
  place-items: center;
  color: var(--acid);
  background:
    linear-gradient(135deg, rgba(210, 255, 31, 0.14), transparent 55%),
    linear-gradient(315deg, rgba(255, 61, 127, 0.08), transparent 60%), var(--ink-3);
  clip-path: polygon(14px 0, 100% 0, 100% calc(100% - 14px), calc(100% - 14px) 100%, 0 100%, 0 14px);
  box-shadow: inset 0 0 0 1px rgba(210, 255, 31, 0.28);
  filter: drop-shadow(0 0 18px rgba(210, 255, 31, 0.18));
}
.state-mark::after {
  content: "";
  position: absolute;
  inset: 6px;
  clip-path: inherit;
  box-shadow: inset 0 0 0 1px var(--line-2);
}
.state-mark .icon {
  width: 34px;
  height: 34px;
  stroke-width: 1.4;
}
.state p {
  font-family: var(--read);
}

/* ---------- Footer ---------- */

.foot {
  max-width: var(--measure);
  margin: 0 auto;
  padding: 48px var(--gutter) 28px;
  border-top: 1px solid var(--line);
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  color: var(--mute);
}
.foot-line {
  margin: 0 0 6px;
  font-size: 17px;
  color: var(--bone-2);
}
.foot-line .mark-fy {
  font-size: 1.05em;
}
.foot-small {
  font-family: var(--read);
  font-weight: 400;
  font-optical-sizing: auto;
  margin: 0 0 14px;
  font-size: 14px;
}
.foot-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 18px;
  font-size: 14px;
}
.foot-nav a {
  color: var(--mute);
  text-decoration: none;
  padding: 6px 0;
}
.foot-nav a:hover {
  color: var(--bone);
}
.build-stamp {
  color: var(--mute);
  font-family: var(--mono);
}

/* ---------- Dock (phones) ---------- */

.dock {
  display: none;
}

.noscript {
  padding: 20px var(--gutter);
  text-align: center;
  color: var(--bone-2);
}

@media (max-width: 760px) {
  :root {
    --top-height: 58px;
    --dock-height: 74px;
  }
  .top {
    gap: 12px;
  }
  .top-nav {
    display: none;
  }
  .mark {
    font-size: 20px;
  }
  .me-chip {
    display: none !important;
  }
  .dock {
    position: fixed;
    left: 10px;
    right: 10px;
    bottom: calc(10px + var(--safe-bottom));
    z-index: 55;
    height: 64px;
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    align-items: center;
    padding: 0 6px;
    border-radius: var(--r-3);
    border: 1px solid var(--line-2);
    background: rgba(14, 12, 19, 0.88);
    backdrop-filter: blur(20px) saturate(1.5);
    -webkit-backdrop-filter: blur(20px) saturate(1.5);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
  }
  .dock a {
    height: 56px;
    display: grid;
    place-items: center;
    align-content: center;
    gap: 3px;
    color: var(--mute);
    text-decoration: none;
    font-size: 11px;
    font-weight: 600;
    border-radius: var(--r-3);
    -webkit-tap-highlight-color: transparent;
    transition: color 0.2s;
  }
  .dock a .icon {
    width: 22px;
    height: 22px;
  }
  .dock a[aria-current="page"] {
    color: var(--bone);
  }
  .dock a[aria-current="page"] .icon {
    color: var(--acid);
    filter: drop-shadow(0 0 8px var(--acid-glow));
  }
  .dock .dock-pour {
    width: 56px;
    height: 56px;
    margin: 0 auto;
    border-radius: 50%;
    background: var(--acid);
    color: var(--acid-ink);
    box-shadow:
      0 0 0 5px rgba(7, 6, 10, 0.9),
      0 0 30px var(--acid-glow);
    transform: translateY(-14px);
  }
  .dock .dock-pour .icon {
    width: 26px;
    height: 26px;
  }
  .dock .sigil {
    width: 26px;
    height: 26px;
    font-size: 12px;
  }
  .foot {
    padding-bottom: 32px;
  }
  dialog.sheet {
    width: 100vw;
    max-width: 100vw;
    margin: auto 0 0;
    border-radius: var(--r-3) var(--r-3) 0 0;
    border-bottom: 0;
    max-height: 92dvh;
    padding-bottom: var(--safe-bottom);
  }
  dialog.sheet[open] {
    animation: sheet-up 0.42s var(--ease-out);
  }
  @keyframes sheet-up {
    from {
      transform: translateY(100%);
    }
    to {
      transform: none;
    }
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  body::after {
    animation: none;
  }
}
