:root {
  --ink: #304f46;
  --muted: #738075;
  --paper: #fffcf1;
  --line: #d8decd;
  --sage: #dfe6d8;
  --accent: #d9764e;
  --shadow: 0 8px 28px #2b443318;
  font-family:
    Inter,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  color: var(--ink);
  font-synthesis: none;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: #e7eadd;
  overflow: hidden;
}
button,
input,
select {
  font: inherit;
}
button {
  cursor: pointer;
  color: inherit;
  border: 0;
  background: none;
}
button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible {
  outline: 3px solid #d9764e;
  outline-offset: 3px;
}
button:disabled {
  opacity: 0.5;
  cursor: wait;
}
[hidden] {
  display: none !important;
}
#world {
  position: fixed;
  inset: 0;
}
#world canvas {
  display: block;
  width: 100%;
  height: 100%;
  touch-action: none;
}
.topbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  display: flex;
  align-items: center;
  gap: 26px;
  padding: 20px 30px;
  z-index: 6;
  background: linear-gradient(#f7f7edee, #f7f7edbb, transparent);
  pointer-events: none;
}
.topbar > * {
  pointer-events: auto;
}
.brand {
  display: flex;
  gap: 12px;
  align-items: center;
  font-size: 27px;
  font-weight: 750;
  letter-spacing: -1px;
}
.brand-light {
  font-weight: 350;
}
.brand small {
  display: block;
  font-size: 9px;
  letter-spacing: 2px;
  margin-top: 4px;
  font-weight: 650;
}
.brand-icon {
  background: var(--ink);
  color: var(--paper);
  border-radius: 13px;
  width: 47px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 39px;
  font-weight: 650;
  position: relative;
}
.brand-icon span {
  position: absolute;
  font-size: 21px;
  color: #e9a074;
  right: 4px;
  top: 2px;
}
.top-middle {
  flex: 1;
  text-align: center;
  font-size: 12px;
  color: #576c60;
}
.live-dot {
  display: inline-block;
  background: #698e70;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  margin-right: 7px;
  vertical-align: middle;
  box-shadow: 0 0 0 4px #6d906914;
}
.quiet {
  font-size: 12px;
  font-weight: 600;
  background: #fffcf1cc;
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: 9px;
}
.quiet span {
  margin-left: 12px;
}
.eyebrow {
  font-size: 10px;
  letter-spacing: 2px;
  font-weight: 750;
  color: #758575;
}
.muted {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}
h1,
h2,
p {
  margin-top: 0;
}
h2 {
  font-size: 23px;
  letter-spacing: -0.8px;
  margin-bottom: 8px;
}
.panel {
  background: #fffcf1f2;
  border: 1px solid #d3dbc6;
  border-radius: 15px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(12px);
}
#onboarding {
  position: fixed;
  inset: 90px 0 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px clamp(30px, 7vw, 120px);
  gap: 40px;
  z-index: 5;
  pointer-events: none;
}
.intro-copy {
  pointer-events: auto;
  max-width: 470px;
  align-self: flex-start;
  margin-top: 8vh;
  background: radial-gradient(ellipse, #eef0e4d0, transparent 70%);
  text-shadow: 0 1px 15px #eef0e4;
}
.intro-copy h1 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(42px, 5.1vw, 78px);
  font-weight: 400;
  line-height: 1.05;
  letter-spacing: -3px;
  margin: 22px 0;
}
.intro-copy h1 em {
  color: #9e6649;
  font-weight: 400;
}
.intro-copy p {
  font-size: 15px;
  line-height: 1.8;
  color: #526459;
}
.intro-caption {
  display: flex;
  gap: 12px;
  font-size: 9px;
  letter-spacing: 1.5px;
  margin-top: 42px;
  align-items: center;
}
.intro-caption > span {
  border: 1px solid #bdc9b4;
  border-radius: 50%;
  padding: 10px;
  font-size: 12px;
}
.intro-caption small {
  display: block;
  margin-top: 7px;
  font-size: 11px;
  letter-spacing: 0.3px;
}
.arrival-card {
  pointer-events: auto;
  width: 432px;
  flex-shrink: 0;
  background: var(--paper);
  border: 1px solid #d6ddcb;
  border-radius: 22px;
  padding: 25px;
  box-shadow: 0 24px 80px #304d3426;
  max-height: calc(100dvh - 120px);
  overflow: auto;
}
.card-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 18px;
}
.pill {
  font-size: 8px;
  letter-spacing: 1px;
  border: 1px solid #d5ddc8;
  border-radius: 20px;
  padding: 5px 7px;
  color: #7f8f7e;
}
.arrival-card h2 {
  font-size: 24px;
}
.arrival-card > .muted {
  margin-bottom: 12px;
  font-size: 12px;
}
.avatar-stage {
  position: relative;
  background: radial-gradient(ellipse at 50% 85%, #d8dfca, #edf0e3 60%);
  height: 160px;
  border-radius: 12px;
  overflow: hidden;
  margin-bottom: 17px;
}
.avatar-stage canvas {
  width: 100%;
  height: 100%;
  display: block;
}
.preview-caption {
  position: absolute;
  bottom: 13px;
  left: 15px;
  font-size: 8px;
  letter-spacing: 1.5px;
  color: #87947f;
}
.shuffle {
  position: absolute;
  bottom: 10px;
  right: 13px;
  border-radius: 50%;
  border: 1px solid #c5d0b7;
  width: 44px;
  height: 44px;
  padding: 0;
  display: grid;
  place-items: center;
  line-height: 1;
  background: #fffaf1;
  font-size: 22px;
}
.form-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  margin-bottom: 12px;
}
label {
  font-size: 10px;
  font-weight: 700;
}
input,
select {
  color: var(--ink);
  background: #f5f5e9;
  border: 1px solid #dce1d0;
  border-radius: 7px;
  padding: 10px;
  min-width: 0;
}
label input {
  display: block;
  width: 100%;
  font-size: 11px;
  font-weight: 400;
  margin-top: 6px;
}
.option-row {
  display: flex;
  gap: 10px;
  align-items: center;
  margin: 12px 0;
  min-height: 28px;
}
.option-row > span {
  font-size: 11px;
  width: 52px;
  flex-shrink: 0;
}
.option-row select {
  margin-left: auto;
  font-size: 10px;
  padding: 6px;
  max-width: 92px;
}
.swatches {
  display: flex;
  gap: 6px;
}
.swatch {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 2px solid #ffffff;
  box-shadow: 0 0 0 1px #d6dccb;
}
.swatch[aria-pressed="true"] {
  box-shadow: 0 0 0 2px var(--ink);
  transform: scale(1.08);
}
.segments {
  display: flex;
  gap: 4px;
}
.segments button {
  font-size: 10px;
  border: 1px solid #d9dfce;
  border-radius: 6px;
  padding: 6px 13px;
}
.segments button[aria-pressed="true"] {
  color: white;
  background: var(--ink);
  border-color: var(--ink);
}
.primary {
  color: #fffcf1;
  background: var(--ink);
  border: 1px solid var(--ink);
  border-radius: 8px;
  padding: 12px 15px;
  font-size: 12px;
  font-weight: 650;
}
.primary:hover {
  background: #47695c;
}
.primary span {
  margin-left: 18px;
}
.enter {
  margin-top: 7px;
  display: flex;
  justify-content: space-between;
  width: 100%;
  padding: 14px;
}
.preview-note {
  display: block;
  font-size: 9px;
  line-height: 1.7;
  color: #7e8b7a;
  text-align: center;
  margin-top: 12px;
}
#join-error {
  color: #a14932;
  font-size: 12px;
  margin: 8px 0 0;
}
.directory {
  position: fixed;
  left: 24px;
  top: 112px;
  width: 246px;
  padding: 20px;
  z-index: 4;
}
.directory h2 {
  font-size: 22px;
  margin-top: 8px;
}
.directory > .muted {
  font-size: 11px;
  margin-bottom: 18px;
}
.destination {
  display: flex;
  width: 100%;
  gap: 11px;
  align-items: center;
  padding: 11px 0;
  text-align: left;
  border-top: 1px solid #e7e9db;
}
.destination .destination-icon {
  width: 30px;
  height: 31px;
  border-radius: 9px;
  display: grid;
  place-items: center;
  font-size: 12px;
  background: #e6ebdc;
  flex-shrink: 0;
}
.destination strong {
  display: block;
  font-size: 12px;
  font-weight: 650;
}
.destination small {
  display: block;
  font-size: 9px;
  color: #81907e;
  margin-top: 4px;
}
.destination .arrow {
  margin-left: auto;
  font-size: 16px;
  color: #8c9d89;
}
.destination:hover strong {
  color: #bf704b;
}
.directory-footer {
  border-top: 1px solid var(--line);
  padding-top: 14px;
  margin-top: 10px;
}
.directory-footer > span {
  font-size: 10px;
}
.progress-track {
  height: 4px;
  border-radius: 4px;
  background: #e8eadc;
  margin: 9px 0 13px;
}
.progress-track i {
  display: block;
  height: 4px;
  background: #d48d62;
  border-radius: 4px;
  width: 0%;
  transition: width 0.3s;
}
.directory-footer small {
  font-size: 8px;
  color: #8c9585;
}
.location {
  position: fixed;
  bottom: 38px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 13px 18px;
  z-index: 4;
  min-width: 240px;
}
.location-icon {
  font-size: 28px;
  color: #95a184;
}
.location small {
  font-size: 8px;
  letter-spacing: 1.7px;
  color: #8b9681;
  display: block;
  margin-bottom: 4px;
}
.location strong {
  font-size: 12px;
}
.location .primary {
  padding: 9px 11px;
  margin-left: 10px;
}
.location .primary span {
  margin-left: 8px;
  background: #ffffff20;
  padding: 2px 4px;
}
.chat {
  position: fixed;
  right: 24px;
  bottom: 24px;
  width: 290px;
  z-index: 4;
  overflow: hidden;
}
.chat-heading {
  display: flex;
  justify-content: space-between;
  width: 100%;
  padding: 15px;
  font-size: 11px;
  font-weight: 600;
}
.chat-heading > span:last-child {
  font-weight: 400;
  color: #7d8c75;
  font-size: 10px;
}
#messages {
  height: 128px;
  overflow: auto;
  padding: 0 15px;
  font-size: 11px;
  line-height: 1.5;
  overflow-wrap: anywhere;
}
#messages p {
  margin: 0 0 10px;
}
#messages strong {
  display: block;
  font-size: 9px;
  color: #849176;
}
.chat-system {
  font-size: 10px;
  color: #899280;
  font-style: italic;
}
#chat-form {
  display: flex;
  border-top: 1px solid #e4e7d8;
  padding: 9px;
  gap: 6px;
}
#chat-input {
  width: 100%;
  background: transparent;
  border: 0;
  padding: 5px;
  font-size: 11px;
}
#chat-form button {
  border-radius: 7px;
  width: 31px;
  flex-shrink: 0;
  background: #e6eadb;
  font-size: 18px;
}
.world-controls {
  position: fixed;
  bottom: 34px;
  left: 24px;
  padding: 5px;
  display: flex;
  gap: 2px;
  z-index: 4;
}
.world-controls button {
  width: 36px;
  height: 34px;
  font-size: 22px;
  border-radius: 8px;
}
.world-controls button:hover {
  background: #e8eadc;
}
.movement-hint {
  position: fixed;
  bottom: 12px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 9px;
  color: #6f806c;
  white-space: nowrap;
  pointer-events: none;
}
.movement-hint b {
  margin: 0 6px;
  font-weight: 400;
}
#labels {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 2;
  overflow: hidden;
}
.world-label {
  position: absolute;
  transform: translate(-50%, -100%);
  white-space: nowrap;
  text-align: center;
  background: #fffcf1ee;
  border: 1px solid #cbd7c0;
  border-radius: 6px;
  padding: 5px 9px;
  font-size: 10px;
  box-shadow: 0 2px 4px #304a3212;
}
.world-label.self {
  border-color: #c58052;
  color: #a16747;
}
.world-label.room-label {
  font-size: 10px;
  font-weight: 650;
  padding: 7px 12px;
}
.world-label.room-label small {
  font-size: 8px;
  color: #829277;
  display: block;
  margin-top: 2px;
  font-weight: 450;
}
.world-label.fade {
  opacity: 0.2;
}
#detail {
  position: fixed;
  right: 24px;
  top: 112px;
  width: 320px;
  padding: 25px;
  z-index: 7;
}
.close {
  position: absolute;
  top: 10px;
  right: 12px;
  font-size: 25px;
  color: #839277;
}
#detail h2 {
  margin-top: 12px;
  font-size: 27px;
}
#detail p {
  font-size: 12px;
  line-height: 1.8;
  color: #74846d;
}
#detail-content button:not(.primary) {
  display: block;
  width: 100%;
  text-align: left;
  border: 1px solid #d6decb;
  border-radius: 7px;
  padding: 12px;
  margin: 8px 0;
  font-size: 12px;
}
#detail-content .primary {
  width: 100%;
}
.poll-option {
  position: relative;
  overflow: hidden;
}
.poll-option i {
  position: absolute;
  inset: 0;
  right: auto;
  background: #dce5d0;
  z-index: -1;
}
.poll-option span {
  float: right;
}
.detail-note {
  font-size: 10px;
  color: #829276;
  line-height: 1.6;
  margin: 12px 0;
}
#toast {
  position: fixed;
  top: 86px;
  left: 50%;
  transform: translateX(-50%);
  padding: 12px 20px;
  border-radius: 10px;
  background: #35574e;
  color: var(--paper);
  font-size: 12px;
  box-shadow: var(--shadow);
  z-index: 20;
  max-width: 90vw;
}
dialog {
  border: 1px solid #cdd8c2;
  background: var(--paper);
  border-radius: 18px;
  padding: 34px;
  width: 440px;
  color: var(--ink);
  box-shadow: var(--shadow);
}
dialog::backdrop {
  background: #263b3655;
  backdrop-filter: blur(3px);
}
dialog h2 {
  margin-top: 14px;
  font-size: 30px;
}
dialog p {
  font-size: 13px;
  line-height: 1.8;
}
#mobile-pad {
  display: none;
}
.larger-text .panel {
  font-size: 120%;
}
.larger-text .panel p,
.larger-text .panel strong,
.larger-text #messages,
.larger-text #chat-input {
  font-size: 15px;
}
.reduced-motion * {
  scroll-behavior: auto !important;
  transition: none !important;
}
@media (max-height: 820px) {
  .arrival-card {
    padding: 20px;
    width: 410px;
  }
  .avatar-stage {
    height: 125px;
  }
  .option-row {
    margin: 10px 0;
  }
  .intro-copy {
    margin-top: 5vh;
  }
  .directory {
    top: 100px;
    padding: 16px;
  }
  .destination {
    padding: 9px 0;
  }
  .arrival-card h2 {
    font-size: 22px;
  }
}
@media (max-width: 1050px) {
  #onboarding {
    padding: 20px 30px;
  }
  .intro-copy h1 {
    font-size: 50px;
  }
  .intro-copy {
    max-width: 330px;
  }
  .directory {
    width: 218px;
    left: 16px;
  }
  .chat {
    width: 250px;
    right: 16px;
  }
  .location {
    bottom: 58px;
  }
  .topbar {
    padding: 17px 20px;
    gap: 15px;
  }
  .top-middle {
    font-size: 10px;
  }
  .movement-hint {
    bottom: 24px;
    font-size: 8px;
  }
  #detail {
    right: 16px;
    width: 295px;
  }
}
@media (max-width: 760px) {
  .topbar {
    padding: 12px 15px;
  }
  .brand {
    font-size: 22px;
  }
  .brand-icon {
    width: 37px;
    height: 39px;
    font-size: 31px;
  }
  .brand small {
    font-size: 7px;
  }
  .top-middle {
    display: none;
  }
  .quiet {
    margin-left: auto;
    font-size: 10px;
    padding: 8px;
  }
  .intro-copy {
    display: none;
  }
  #onboarding {
    inset: 70px 0 0;
    padding: 10px;
    justify-content: center;
  }
  .arrival-card {
    width: min(420px, 100%);
    max-height: calc(100dvh - 90px);
    padding: 20px;
  }
  .directory {
    top: 80px;
    left: 10px;
    width: 190px;
    padding: 12px;
    max-height: 37dvh;
    overflow: auto;
  }
  .directory h2 {
    font-size: 17px;
  }
  .directory > .muted,
  .directory-footer {
    display: none;
  }
  .destination {
    padding: 8px 0;
  }
  .destination strong {
    font-size: 11px;
  }
  .directory .eyebrow {
    font-size: 8px;
  }
  .location {
    bottom: 190px;
    padding: 8px 12px;
    min-width: 180px;
  }
  .chat {
    right: 10px;
    bottom: 10px;
    width: calc(100% - 140px);
    max-width: 300px;
  }
  .chat #messages {
    height: 80px;
  }
  .chat-heading {
    padding: 10px;
  }
  .world-controls {
    left: 10px;
    bottom: 140px;
  }
  .world-controls button {
    width: 29px;
  }
  .movement-hint {
    display: none;
  }
  #mobile-pad {
    display: block;
    position: fixed;
    bottom: 15px;
    left: 10px;
    text-align: center;
    z-index: 5;
  }
  #mobile-pad button {
    width: 36px;
    height: 36px;
    background: #fffcf1e8;
    border: 1px solid #d3dbc6;
    border-radius: 8px;
    margin: 2px;
    touch-action: none;
  }
  #detail {
    top: 80px;
    right: 10px;
    max-height: 65dvh;
    overflow: auto;
    width: min(310px, calc(100% - 20px));
  }
  .world-label.room-label {
    font-size: 8px;
    padding: 4px 7px;
  }
  .world-label.room-label small {
    font-size: 7px;
  }
}

body:not(.in-venue) #labels {
  display: none;
}

@media (min-width: 761px) {
  #detail {
    max-height: calc(100dvh - 270px);
    overflow: auto;
  }
  body:has(#detail:not([hidden])) #messages {
    height: 48px;
  }
}

/* One tool at a time on smaller screens; the world remains the main interaction. */
#world canvas {
  touch-action: none;
}
[hidden] {
  display: none !important;
}
button,
input,
select {
  min-height: 44px;
}
button:focus-visible,
input:focus-visible,
select:focus-visible {
  outline: 3px solid #be884d;
  outline-offset: 3px;
}
button:disabled {
  opacity: 0.45;
  cursor: default;
}
.directory {
  display: none;
  max-height: calc(100dvh - 225px);
  overflow: auto;
  width: 280px;
}
body[data-panel="map"] .directory {
  display: block;
}
#place-search {
  width: 100%;
  margin: 4px 0 12px;
  font-size: 14px;
}
#event-nav {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  padding: 6px;
  gap: 3px;
  z-index: 9;
}
#event-nav button {
  position: relative;
  min-width: 64px;
  min-height: 52px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  font-size: 21px;
  border-radius: 9px;
}
#event-nav button span {
  font-size: 10px;
}
#event-nav button[aria-pressed="true"] {
  background: #dce5d0;
  color: #294e42;
}
#chat-unread {
  position: absolute;
  right: 14px;
  top: 7px;
  width: 7px;
  height: 7px;
  background: #d18b54;
  border-radius: 50%;
}
#event-panel {
  position: fixed;
  top: 108px;
  left: 24px;
  width: 350px;
  max-height: calc(100dvh - 215px);
  padding: 25px;
  overflow: auto;
  z-index: 8;
}
#event-panel h2 {
  margin: 10px 0 15px;
  font-size: 25px;
}
#event-panel p {
  font-size: 13px;
  line-height: 1.6;
}
#event-panel button {
  border: 1px solid #d2dbc6;
  border-radius: 8px;
  padding: 10px;
  margin: 4px 0;
}
#event-panel .close {
  border: 0;
  margin: 0;
  padding: 0;
}
.event-card {
  border-top: 1px solid #d9dece;
  padding: 16px 0;
}
.event-card h3 {
  font-size: 16px;
  margin: 6px 0;
}
.event-card small {
  font-size: 11px;
  color: #85866d;
}
.inline-actions {
  display: flex;
  gap: 8px;
}
.inline-actions button {
  flex: 1;
}
.presentation {
  background: #e6ebdc;
  border: 1px solid #ccd6c0;
  border-radius: 12px;
  padding: 18px;
  margin-top: 18px;
  min-height: 160px;
}
.presentation small {
  font-size: 9px;
  letter-spacing: 1px;
}
.presentation h3 {
  font-size: 21px;
  line-height: 1.2;
}
.question-card {
  border-bottom: 1px solid #dce2d1;
  padding: 10px 0;
}
.question-card small {
  color: #87947b;
}
.question-form {
  display: flex;
  gap: 6px;
  margin: 12px 0;
}
.question-form input {
  min-width: 0;
  width: 100%;
  font-size: 14px;
}
.question-form button {
  width: auto !important;
}
#detail {
  max-height: calc(100dvh - 220px);
}
#detail-content h3 {
  margin: 18px 0 8px;
  font-size: 18px;
}
.location {
  bottom: 100px;
  padding: 9px 14px;
  max-width: calc(100vw - 700px);
  min-width: 240px;
}
.world-controls button {
  width: 44px;
  height: 44px;
}
.close {
  min-width: 44px;
  min-height: 44px;
}
#mobile-pad {
  display: none !important;
}
.movement-hint {
  bottom: 5px;
}
@media (max-width: 1100px) {
  .top-middle {
    display: none;
  }
  .chat {
    display: none;
  }
  body[data-panel="chat"] .chat {
    display: block;
  }
  .location {
    top: 85px;
    bottom: auto;
    max-width: calc(100vw - 140px);
    min-width: 0;
  }
  #event-panel,
  .directory,
  #detail,
  .chat {
    inset: auto 16px 98px;
    width: 360px;
    max-width: calc(100vw - 32px);
    max-height: 62dvh;
    overflow: auto;
    margin: 0;
  }
  #detail {
    left: auto;
  }
  .chat #messages {
    height: 190px;
  }
  .directory-footer,
  .directory > .muted {
    display: block;
  }
  .directory h2 {
    font-size: 22px;
  }
  .destination {
    padding: 12px 0;
  }
  .destination strong {
    font-size: 13px;
  }
  .directory .eyebrow {
    font-size: 9px;
  }
  .world-controls {
    left: 16px;
    bottom: 24px;
  }
  #event-nav {
    left: auto;
    right: 16px;
    transform: none;
  }
  .movement-hint {
    display: none;
  }
}
@media (max-width: 600px) {
  .topbar {
    padding: 10px 12px;
    gap: 6px;
  }
  .brand {
    font-size: 21px;
  }
  #help-button {
    font-size: 11px;
    padding: 6px;
  }
  .location {
    top: 79px;
    left: 12px;
    right: 66px;
    transform: none;
    max-width: none;
    padding: 8px 10px;
    gap: 8px;
  }
  .location strong {
    font-size: 11px;
  }
  .location small {
    font-size: 7px;
  }
  .location-icon {
    display: none;
  }
  .location .primary {
    margin-left: auto;
    min-width: 75px;
  }
  .location .primary span {
    display: none;
  }
  .world-controls {
    right: 10px;
    left: auto;
    top: 78px;
    bottom: auto;
    flex-direction: column;
    padding: 2px;
  }
  #event-nav {
    left: 10px;
    right: 10px;
    bottom: max(10px, env(safe-area-inset-bottom));
    justify-content: space-around;
  }
  #event-nav button {
    min-width: 54px;
    flex: 1;
  }
  #event-panel,
  .directory,
  #detail,
  .chat {
    left: 10px;
    right: 10px;
    bottom: 84px;
    width: auto;
    max-width: none;
    max-height: calc(100dvh - 230px);
    padding: 18px;
  }
  .chat {
    padding: 0;
  }
  #detail {
    padding-top: 28px;
  }
  .chat #messages {
    height: 160px;
  }
  .directory-footer {
    display: block;
  }
  input,
  select,
  #chat-input,
  .question-form input {
    font-size: 16px;
  }
  #chat-form button {
    width: 44px;
  }
  .form-row {
    gap: 8px;
  }
  .arrival-card {
    padding: 18px;
  }
  .arrival-card .option-row {
    min-height: 44px;
  }
  .segments button {
    min-height: 40px;
  }
  .swatch {
    min-height: 30px;
    min-width: 30px;
  }
  .world-label {
    font-size: 11px;
  }
  .world-label.room-label {
    font-size: 9px;
  }
}
@media (max-height: 500px) and (min-width: 601px) {
  .location {
    top: 10px;
    left: 50%;
  }
  #event-panel,
  .directory,
  #detail,
  .chat {
    max-height: calc(100dvh - 155px);
    bottom: 85px;
  }
}
@media (prefers-reduced-motion: reduce) {
  * {
    scroll-behavior: auto !important;
  }
}
#detail > .close,
#event-panel > .close,
.directory > .close {
  position: sticky;
  top: 0;
  float: right;
  z-index: 2;
  margin: -8px -8px 0 0;
  background: #fffdf1;
  border-radius: 50%;
}
@media (max-width: 600px) {
  .option-row:has(select) {
    display: grid;
    grid-template-columns: 54px minmax(0, 1fr);
    gap: 8px;
  }
  .option-row select {
    grid-column: 2;
    width: 100%;
    max-width: none;
  }
  .option-row .swatches {
    flex-wrap: wrap;
  }
}

.swatch {
  width: 30px;
  height: 30px;
  min-width: 30px;
  min-height: 30px;
  max-width: 30px;
  max-height: 30px;
  flex: 0 0 30px;
  aspect-ratio: 1;
  padding: 0;
  border-radius: 50%;
}
.swatches {
  flex-wrap: wrap;
  align-items: center;
  flex-shrink: 0;
}
@media (min-width: 601px) {
  .option-row:has(select) {
    display: grid;
    grid-template-columns: 52px minmax(0, 1fr);
    gap: 10px;
  }
  .option-row select {
    grid-column: 2;
    width: 100%;
    max-width: none;
    margin: 0;
  }
  .option-row .swatches {
    gap: 6px;
  }
}

/* Compact doorway signs; schedules stay in the details panel. */
body.in-venue .schedule-label { pointer-events: auto; cursor: pointer; min-height: 44px; color: #35594e; }
.schedule-label:focus-visible { outline: 3px solid #a16747; outline-offset: 3px; }
#schedule-room { width: 100%; min-height: 44px; margin: 8px 0 12px; white-space: normal; }
.schedule-status { display: block; width: fit-content; padding: 4px 8px; margin-bottom: 8px; border-radius: 5px; background: #e5ebdc; color: #35594e; font-size: 11px; }

.booth-content-image { width: 100%; height: auto; border-radius: 10px; display: block; margin: 12px 0; }

/* Conference content uses the existing warm palette and compact panels. */
.profile-fields { margin:16px 0; text-align:left; }
.profile-fields summary { cursor:pointer; font-weight:650; margin-bottom:12px; }
.profile-grid { display:grid; grid-template-columns:1fr 1fr; gap:10px; }
.profile-fields label { font-size:12px; display:flex; flex-direction:column; gap:5px; }
.profile-fields fieldset { border:1px solid var(--line,#d4dcc9); border-radius:10px; padding:10px; margin:12px 0; }
.profile-fields fieldset label,.profile-fields .check-line { flex-direction:row; align-items:flex-start; margin:7px 0; }
.profile-fields input[type=checkbox] { width:16px; height:16px; flex:0 0 16px; margin:1px 5px 0 0; }
.profile-fields > button { width:100%; margin-bottom:12px; }
.experience-dialog { width:min(660px,calc(100vw - 32px)); max-height:88dvh; overflow:auto; color:#304f46; border:1px solid #d4dcc9; background:#fffcf2; border-radius:22px; padding:28px; }
.experience-dialog::backdrop { background:#182b4055; backdrop-filter:blur(3px); }
.experience-dialog h2 { padding-right:30px; }
.experience-dialog p { line-height:1.55; }
.experience-dialog button:not(.close) { margin:5px 6px 5px 0; min-height:42px; }
.experience-dialog iframe { width:100%; height:min(60dvh,480px); border:1px solid #c9d3c5; border-radius:12px; }
.experience-form { display:grid; gap:12px; }
.experience-form label { display:grid; gap:5px; font-size:13px; }
.experience-form textarea { min-height:85px; resize:vertical; font:inherit; border:1px solid #ccd6c6; border-radius:8px; padding:10px; color:inherit; background:#f4f5e9; }
.sample-banner { background:#edf0d9; border:1px solid #cbd7ad; border-radius:10px; padding:10px 12px; font-size:13px; }
.resource-link { display:block; margin:12px 0; color:#315d50; text-decoration:underline; }
.private-log { min-height:150px; max-height:36dvh; overflow:auto; background:#eef1e6; padding:12px; border-radius:12px; overflow-wrap:anywhere; }
.video-placeholder { padding:28px 18px; background:#183047; color:#f9f9e9; border-radius:12px; text-align:center; margin:16px 0; }
.world-label.schedule-label { max-width:280px; white-space:normal; text-align:left; }
.world-label:not(.room-label) { border:1px solid #d4dcca; font:inherit; font-size:11px; cursor:pointer; }
@media(max-width:600px) { .profile-grid {grid-template-columns:1fr;} .experience-dialog {padding:20px;} .world-label.schedule-label {max-width:190px;font-size:10px;} }
.sample-entry { width:100%; min-height:42px; margin:8px 0 12px; border:1px solid #ccd7b9; border-radius:10px; background:#eef2de; color:#31564a; }

/* Personal progress stays on the sign, leaving the venue materials unchanged. */
.visit-badge { display:inline-flex;align-items:center;gap:4px;margin:6px 0 0;padding:3px 8px;border-radius:12px;background:#eeeee5;color:#788078;font-size:10px;font-weight:600;letter-spacing:.02em;line-height:1.4; }
.session-visited .visit-badge,.visit-badge.visited { color:#34584a;background:#e0ead9; }
.world-label.session-visited { border-color:#afc6a4;box-shadow:0 2px 8px #34584a18; }
.visited-session {color:#41604e;}
.event-card > .visit-badge { display:table; margin:0 0 8px; }

@media (min-width: 761px) {
  #detail.room-detail { left: 24px; right: auto; }
}

/* Floor controls remain separate from zoom and never move the visitor. */
#floor-picker { position:fixed; left:16px; top:50%; transform:translateY(-50%); width:48px; padding:5px; z-index:6; text-align:center; }
.floor-caption { display:block; font-size:8px; letter-spacing:1px; padding:5px 0 7px; color:#74846d; }
#floor-buttons { display:grid; gap:4px; }
#floor-buttons button { width:38px; min-height:48px; border-radius:9px; display:flex; flex-direction:column; align-items:center; justify-content:center; gap:2px; }
#floor-buttons strong { font-size:15px; }
#floor-buttons small { font-size:9px; }
#floor-buttons button[aria-pressed="true"] { background:#31564b; color:#fffdf4; }
#floor-buttons button:disabled { color:#889184; cursor:not-allowed; background:#eeefe5; }
.programme-location { background:#edf2e6; border:1px solid #d3deca; border-radius:10px; padding:12px; margin:14px 0 12px; }
.programme-location small { display:block; font-size:9px; letter-spacing:1.5px; color:#657a5e; margin-bottom:5px; }
.programme-location strong { display:block; color:#31564b; font-size:13px; line-height:1.5; }
.destination.current-place { background:#e8efdf; border-radius:8px; }
.destination.current-place .arrow { font-size:9px; color:#31564b; white-space:nowrap; }
@media (min-width:761px) {
  #detail.room-detail, #event-panel, .directory { left:80px; }
}
@media (max-width:760px) {
  #floor-picker { left:10px; }
  body:has(#detail:not([hidden])) #floor-picker,
  body:has(#event-panel:not([hidden])) #floor-picker,
  body[data-panel="map"] #floor-picker,
  body[data-panel="chat"] #floor-picker { visibility:hidden; }
}



body.in-venue .world-label.room-label {
  display: inline-flex; align-items: center; gap: 5px;
  min-height: 30px; max-width: 190px; padding: 5px 8px;
  border-radius: 4px; box-shadow: none; font-size: 10px;
  background: #fffcf1e8; white-space: nowrap;
}
.world-label.room-label[hidden] { display: none !important; }
.world-label.room-label .place-label-name { overflow: hidden; text-overflow: ellipsis; }
body.in-venue .world-label.room-label small { display: none; }
.world-label.room-label .visit-badge { margin: 0; padding: 0; background: none; flex: none; }
@media (pointer: coarse) {
  body.in-venue .world-label.schedule-label { min-height: 44px; }
}

/* The character portrait is the camera control; the pencil edits appearance. */
#character-controls { display: flex; align-items: center; gap: 4px; flex-shrink: 0; }
.character-portrait {
  position: relative; display: grid; place-items: center; padding: 0;
  width: 60px; height: 60px; flex-shrink: 0; overflow: hidden;
  border: 2px solid #d5decd; border-radius: 15px; background: #e9ecde;
}
.character-portrait img { display: block; width: 52px; height: 52px; pointer-events: none; }
.character-portrait[aria-pressed="true"] { border-color: #31564b; box-shadow: 0 0 0 3px #31564b20; }
.follow-indicator { position: absolute; bottom: 2px; right: 5px; color: #31564b; font-size: 12px; opacity: 0; pointer-events: none; }
.character-portrait[aria-pressed="true"] .follow-indicator { opacity: 1; }
#edit-avatar { display: grid; place-items: center; width: 44px; height: 44px; padding: 0; border: 1px solid var(--line); border-radius: 12px; background: #fffcf1dd; }
#edit-avatar svg { pointer-events: none; }
#help-button .help-text { margin-left: 0; }
@media (max-width: 760px) {
  .topbar { gap: 8px; padding: 10px 12px; }
  .topbar .brand { flex: 1; gap: 8px; font-size: 20px; }
  .character-portrait { width: 52px; height: 52px; border-radius: 13px; }
  .character-portrait img { width: 46px; height: 46px; }
  #help-button { width: 40px; height: 44px; margin: 0; padding: 0; flex-shrink: 0; }
  #help-button .help-text { display: none; }
  #help-button .help-icon { margin: 0; font-size: 16px; }
}
@media (max-width: 380px) {
  .topbar .brand { font-size: 17px; gap: 5px; }
  .brand-icon { width: 30px; height: 34px; font-size: 27px; }
  .brand small { font-size: 6px; letter-spacing: 1px; }
}

.name-tag { max-width: 200px; overflow: hidden; text-overflow: ellipsis; min-height: 28px; }
.name-tag:not(.self) { pointer-events: auto; }
.name-tag.self { pointer-events: none; z-index: 3; padding-right: 24px; max-width: min(340px, calc(100vw - 24px)); }
.name-tag.focused-name { border-color: #31564b; background: #fffdf4; z-index: 2; }
.name-tag.edge-name::after { content: "➜"; position: absolute; right: 6px; top: 50%; transform: translateY(-50%) rotate(var(--edge-angle)); }
@media (pointer: coarse) { .name-tag:not(.self) { min-height: 44px; } }

#room-hover{position:fixed;z-index:25;pointer-events:none;max-width:min(300px,calc(100vw - 16px));padding:12px 15px;border:1px solid #bccbb9;border-radius:12px;background:#fffdf3f5;color:#31564b;box-shadow:0 6px 20px #233b2520;font-size:12px;line-height:1.5}
#room-hover strong,#room-hover span{display:block}#room-hover strong{font-size:14px}#room-hover span+span{margin-top:5px}

#character-editor{padding:0;border:0;border-radius:24px;background:#fffdf3;color:var(--ink);width:min(480px,calc(100vw - 24px));max-height:calc(100dvh - 24px);overflow:hidden}
#character-editor::backdrop{background:#20372c60}
#character-editor[open]{display:flex;flex-direction:column}
#character-editor .arrival-card{width:100%;max-width:none;max-height:none;min-height:0;flex:1 1 auto;margin:0;box-shadow:none;overflow:auto}
#character-editor .card-heading,#character-editor .sample-entry,#character-editor .preview-note{display:none}
.character-edit-actions{display:flex;gap:10px;flex-shrink:0;padding:14px 20px;border-top:1px solid #d4dcc9;background:#fffdf3}
.character-edit-actions #join-button{margin:0;flex:1}
#cancel-character-edit{min-height:44px;padding:10px 18px}

.input-preference { padding: 16px; border: 1px solid var(--line); border-radius: 14px; background: #edf0e5; }
.input-preference label { display: block; margin-bottom: 8px; font-weight: 600; }
.input-preference select { width: 100%; min-height: 44px; }
#input-mode-note { margin: 10px 0 0; font-size: 13px; line-height: 1.5; }
