@font-face {
  font-family: "Aurea Ultra";
  src: url("assets/fonts/aurea-ultra-roman.otf") format("opentype");
  font-weight: 400 950;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "TAN Songbird";
  src: url("assets/fonts/tan-songbird.otf") format("opentype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  color-scheme: light;
  --ink: #2a1636;
  --muted: #62556f;
  --line: #2a1636;
  --paper: #ffffff;
  --wash: #eee4ff;
  --page-bg: #8f5fc0;
  --accent: #d777ca;
  --accent-dark: #9d4b91;
  --sun: #ffd96a;
  --danger: #e84b61;
  --good: #4fcf91;
  --shadow: 0 12px 0 rgba(42, 22, 54, 0.18);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  height: 100dvh;
  background: var(--page-bg);
  color: var(--ink);
  overflow: hidden;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
}

button,
input,
select,
textarea {
  font: inherit;
}

button,
.import-button,
.map-link {
  min-height: 42px;
  border: 2px solid var(--line);
  border-radius: 6px;
  background: var(--paper);
  color: var(--ink);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 14px;
  text-decoration: none;
  font-weight: 900;
}

button:hover,
.import-button:hover,
.map-link:hover {
  border-color: var(--accent);
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
.import-button:focus-within {
  outline: 3px solid rgba(215, 119, 202, 0.32);
  outline-offset: 2px;
}

.hidden {
  display: none !important;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.app-header {
  min-height: 58px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 10px clamp(16px, 4vw, 36px) 0;
  background: var(--page-bg);
  position: sticky;
  top: 0;
  z-index: 20;
}

.app-header > div:first-child {
  display: flex;
  align-items: center;
}

.brand-title {
  position: relative;
  display: inline-flex;
  align-items: center;
  margin: 0;
  transform: translateY(2px);
}

.brand-title-image {
  display: block;
  width: clamp(132px, 15vw, 220px);
  height: auto;
}

.eyebrow {
  margin: 0;
  color: var(--accent-dark);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 0;
  font-size: clamp(0.82rem, 1.7vw, 1.1rem);
  line-height: 1.1;
  font-weight: 400;
  font-family: "TAN Songbird", "Aurea Ultra", Inter, ui-sans-serif, system-ui, sans-serif;
  color: var(--ink);
  white-space: nowrap;
}

h2 {
  margin-bottom: 0;
  font-size: 1.18rem;
}

.header-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(86px, 1fr));
  border: 2px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: var(--paper);
}

.mode-button {
  border: 0;
  border-radius: 0;
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--ink);
  text-decoration: none;
}

.mode-button.active {
  background: var(--ink);
  color: var(--paper);
}

.header-controls {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  min-width: min(100%, 560px);
}

.day-switcher {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  width: min(100%, 330px);
}

.day-button {
  -webkit-appearance: none;
  appearance: none;
  position: relative;
  min-height: 48px;
  display: grid;
  justify-items: start;
  align-content: center;
  gap: 2px;
  padding: 7px 10px 7px 13px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.72);
  text-align: left;
  box-shadow: 2px 2px 0 rgba(17, 17, 17, 0.12);
  font-family: inherit;
}

.day-button::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 6px;
  background: var(--accent);
}

.day-button span,
.day-button small {
  color: var(--muted);
  font-size: 0.58rem;
  font-weight: 900;
  line-height: 1.18;
  text-transform: uppercase;
}

.day-button strong {
  min-width: 0;
  overflow: hidden;
  font-size: 0.82rem;
  line-height: 1.1;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.day-button.active {
  background: var(--accent);
  border-color: var(--accent-dark);
  box-shadow: 4px 4px 0 rgba(157, 75, 145, 0.24);
}

.day-button.active::before {
  background: var(--accent-dark);
}

.day-button.active span,
.day-button.active strong,
.day-button.active small {
  color: var(--paper);
}

.app-shell {
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  padding: 12px clamp(12px, 3vw, 28px) 18px;
}

.map-stage {
  min-width: 0;
  min-height: 0;
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  position: relative;
}

.toolbar {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) minmax(160px, 220px) auto auto auto auto;
  gap: 8px;
  width: 100%;
  padding: 6px;
  border: 2px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.58);
  box-shadow: 2px 2px 0 rgba(17, 17, 17, 0.1);
  margin-bottom: 6px;
}

.fair-context {
  position: sticky;
  top: 8px;
  left: 8px;
  right: 8px;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin: 0 8px -30px;
  pointer-events: none;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 900;
}

.fair-context span:first-child {
  color: var(--accent-dark);
  padding: 4px 9px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 4px 12px rgba(20, 32, 46, 0.12);
  backdrop-filter: blur(8px);
}

.version-meta {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  min-width: 0;
}

.version-meta > span {
  opacity: 0.82;
  padding: 4px 9px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 4px 12px rgba(20, 32, 46, 0.12);
  backdrop-filter: blur(8px);
}

.version-status {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 8px;
  border: 2px solid var(--accent-dark);
  border-radius: 999px;
  background: var(--accent-dark);
  color: var(--paper);
  font-size: 0.66rem;
  font-weight: 950;
  white-space: nowrap;
  opacity: 1;
  box-shadow: 0 4px 12px rgba(20, 32, 46, 0.18);
}

.version-meta > .version-status {
  background: var(--accent-dark);
  color: var(--paper);
  opacity: 1;
}

.toolbar-action.active,
#unassignedFilter.active {
  background: var(--accent);
  border-color: var(--accent-dark);
  color: var(--paper);
}

#favouritesFilter.active {
  background: var(--paper);
  border-color: var(--accent-dark);
  color: var(--accent-dark);
  box-shadow: inset 0 0 0 3px rgba(215, 119, 202, 0.28);
}

.category-picker {
  position: relative;
  min-width: 0;
}

.category-filter-button {
  position: relative;
  width: 100%;
  min-height: 50px;
  justify-content: flex-start;
  padding: 0 30px 0 12px;
  background: var(--paper);
}

.category-filter-button::after {
  content: "";
  position: absolute;
  right: 12px;
  top: 50%;
  width: 8px;
  height: 8px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: translateY(-70%) rotate(45deg);
  opacity: 0.72;
}

.category-filter-icon {
  position: relative;
  flex: 0 0 auto;
  width: 18px;
  height: 18px;
  color: var(--ink);
  background:
    linear-gradient(currentColor, currentColor) 1px 3px / 16px 3px no-repeat,
    linear-gradient(currentColor, currentColor) 4px 8px / 10px 3px no-repeat,
    linear-gradient(currentColor, currentColor) 7px 13px / 4px 3px no-repeat;
}

.category-filter-icon::after {
  content: "";
  position: absolute;
  right: -3px;
  bottom: -3px;
  width: 9px;
  height: 9px;
  border: 1.5px solid var(--line);
  border-radius: 999px;
  background: var(--category-filter-color, var(--paper));
  box-shadow: 0 0 0 2px var(--paper);
}

.category-filter-button:not(.has-selection) .category-filter-icon::after {
  opacity: 0;
}

.category-filter-menu {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  z-index: 45;
  width: min(280px, calc(100vw - 28px));
  max-height: min(390px, 58vh);
  overflow: auto;
  padding: 6px;
  border: 2px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
  box-shadow: 0 14px 30px rgba(42, 22, 54, 0.22);
}

.category-filter-option {
  width: 100%;
  min-height: 38px;
  justify-content: flex-start;
  gap: 10px;
  padding: 0 10px;
  border: 0;
  box-shadow: none;
  background: transparent;
  text-align: left;
}

.category-filter-option:hover,
.category-filter-option.active {
  background: var(--wash);
}

.category-filter-option.active {
  color: var(--accent-dark);
}

.category-option-swatch {
  width: 12px;
  height: 12px;
  border: 1.5px solid var(--line);
  border-radius: 999px;
  background: var(--option-color, transparent);
}

.category-filter-option:first-child .category-option-swatch {
  background:
    linear-gradient(currentColor, currentColor) 1px 2px / 10px 2px no-repeat,
    linear-gradient(currentColor, currentColor) 3px 5px / 6px 2px no-repeat,
    linear-gradient(currentColor, currentColor) 5px 8px / 2px 2px no-repeat;
}

.native-category-filter {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.button-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9em;
  line-height: 1;
}

.search-box {
  position: relative;
}

.search-box::before {
  content: "";
  position: absolute;
  left: 14px;
  bottom: 12px;
  z-index: 1;
  width: 13px;
  height: 13px;
  border: 2px solid var(--muted);
  border-radius: 999px;
  opacity: 0.72;
  pointer-events: none;
}

.search-box::after {
  content: "";
  position: absolute;
  left: 26px;
  bottom: 10px;
  z-index: 1;
  width: 7px;
  height: 2px;
  border-radius: 999px;
  background: var(--muted);
  opacity: 0.72;
  transform: rotate(45deg);
  transform-origin: left center;
  pointer-events: none;
}

.search-box span {
  position: absolute;
  left: 40px;
  top: 8px;
  font-size: 0.68rem;
  color: var(--muted);
  font-weight: 800;
  text-transform: uppercase;
}

.search-box input {
  width: 100%;
  height: 50px;
  padding: 19px 12px 5px 40px;
}

input,
select,
textarea {
  width: 100%;
  border: 2px solid var(--line);
  border-radius: 6px;
  background: var(--paper);
  color: var(--ink);
}

select {
  height: 50px;
  padding: 0 12px;
}

textarea {
  resize: vertical;
}

.map-viewport {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
  border: 3px solid var(--line);
  border-radius: 8px;
  background: var(--page-bg);
  touch-action: none;
  -webkit-user-select: none;
  user-select: none;
  overscroll-behavior: contain;
  cursor: grab;
}

.map-viewport.is-panning {
  cursor: grabbing;
}

.map-viewport.is-panning * {
  cursor: grabbing !important;
  user-select: none;
}

.mazemap-canvas {
  position: relative;
  width: 1600px;
  height: 1177.7296px;
  margin-inline: auto;
  overflow: visible;
  background: var(--page-bg);
  transform-origin: top left;
}

.zoom-surface {
  position: absolute;
  left: 0;
  top: 0;
  width: 1600px;
  height: 1177.7296px;
  transform-origin: top left;
}

.map-image-layer {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: fill;
  pointer-events: none;
  background: var(--page-bg);
  z-index: 0;
  user-select: none;
}

.zoom-surface::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0.1);
  pointer-events: none;
  z-index: 1;
}

.annotation-layer {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
}

.annotation {
  position: absolute;
  min-width: 0;
  min-height: 0;
  border: 0;
  border-radius: 0;
  padding: 0;
  background: transparent;
  color: var(--ink);
  pointer-events: auto;
  touch-action: none;
}

.annotation.selected {
  outline: 3px solid rgba(22, 32, 42, 0.18);
  outline-offset: 2px;
}

.annotation-room {
  border: calc(2px * var(--guide-size, 1)) solid var(--guide);
  border-radius: 5px;
  background: color-mix(in srgb, var(--guide), transparent 78%);
  transform: rotate(var(--rotation, 0deg));
  transform-origin: center;
}

.annotation-room span {
  position: absolute;
  left: 8px;
  top: 0;
  padding: calc(2px * var(--guide-size, 1)) calc(4px * var(--guide-size, 1));
  border: calc(2px * var(--guide-size, 1)) solid var(--guide);
  border-radius: 5px 5px 0 0;
  border-bottom: 0;
  background: rgba(255, 255, 255, 0.92);
  color: var(--ink);
  font-size: calc(0.48rem * var(--guide-size, 1));
  font-weight: 950;
  line-height: 1;
  box-shadow: 0 5px 12px rgba(20, 32, 46, 0.12);
  transform: translateY(calc(-100% - 1px));
}

.annotation-arrow {
  height: calc(22px * var(--guide-size, 1));
  transform: translateY(-50%) rotate(var(--angle));
  transform-origin: left center;
}

.arrow-line {
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  height: calc(4px * var(--guide-size, 1));
  border-radius: 999px;
  background: var(--guide);
  transform: translateY(-50%);
  box-shadow: 0 5px 14px rgba(20, 32, 46, 0.18);
}

.arrow-line::after {
  content: "";
  position: absolute;
  right: calc(-6px * var(--guide-size, 1));
  top: 50%;
  width: 0;
  height: 0;
  border-top: calc(7px * var(--guide-size, 1)) solid transparent;
  border-bottom: calc(7px * var(--guide-size, 1)) solid transparent;
  border-left: calc(11px * var(--guide-size, 1)) solid var(--guide);
  transform: translateY(-50%);
}

.arrow-label {
  position: absolute;
  left: 50%;
  top: calc(-17px * var(--guide-size, 1));
  transform: translateX(-50%) rotate(calc(-1 * var(--angle)));
  padding: calc(2px * var(--guide-size, 1)) calc(5px * var(--guide-size, 1));
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.95);
  color: var(--ink);
  font-size: calc(0.56rem * var(--guide-size, 1));
  font-weight: 900;
  white-space: nowrap;
}

.annotation-label,
.annotation-facility {
  transform: translate(-50%, -50%) rotate(var(--rotation, 0deg));
}

.annotation-label span,
.annotation-facility span {
  display: block;
  padding: calc(4px * var(--guide-size, 1)) calc(6px * var(--guide-size, 1));
  border: calc(2px * var(--guide-size, 1)) solid #fff;
  border-radius: 6px;
  background: var(--guide);
  color: #fff;
  font-size: calc(0.58rem * var(--guide-size, 1));
  font-weight: 950;
  line-height: 1.05;
  white-space: nowrap;
  box-shadow: 0 10px 24px rgba(20, 32, 46, 0.22);
}

.annotation-facility span {
  border-radius: 999px;
}

.annotation-resize-handle {
  position: absolute;
  right: -8px;
  bottom: -8px;
  width: 14px;
  height: 14px;
  border: 2px solid #fff;
  border-radius: 999px;
  background: var(--guide);
  box-shadow: 0 5px 14px rgba(20, 32, 46, 0.24);
  cursor: nwse-resize;
}

.annotation-rotate-handle {
  position: absolute;
  left: 50%;
  top: 4px;
  width: 14px;
  height: 14px;
  border: 2px solid #fff;
  border-radius: 999px;
  background: var(--guide);
  box-shadow: 0 5px 14px rgba(20, 32, 46, 0.24);
  cursor: grab;
  transform: translateX(-50%);
}

.annotation-rotate-handle::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 100%;
  width: 2px;
  height: 10px;
  background: var(--guide);
  transform: translateX(-50%);
}

.annotation-rotate-handle:active {
  cursor: grabbing;
}

.annotation-resize-handle.arrow-handle {
  right: -13px;
  top: 50%;
  bottom: auto;
  transform: translateY(-50%);
  cursor: ew-resize;
}

.table-layer {
  position: absolute;
  inset: 0;
  z-index: 4;
  pointer-events: none;
}

.table-dot {
  position: absolute;
  pointer-events: auto;
  z-index: 2;
  width: 12px;
  min-width: 0;
  height: 12px;
  min-height: 0;
  border: 2px solid #fff;
  border-radius: 999px;
  background: var(--pin);
  color: #fff;
  box-shadow:
    0 0 0 1px rgba(17, 17, 17, 0.58),
    0 3px 8px rgba(20, 32, 46, 0.28);
  transform: translate(-50%, -50%) scale(var(--inverse-zoom, 1));
  transform-origin: center;
  padding: 0;
  display: grid;
  place-items: center;
  touch-action: none;
}

.table-dot:hover,
.table-dot.active {
  width: 16px;
  height: 16px;
  z-index: 12;
}

.table-dot.active {
  width: 20px;
  height: 20px;
  border-width: 3px;
  outline: 4px solid rgba(215, 119, 202, 0.34);
  box-shadow:
    0 0 0 1px rgba(17, 17, 17, 0.58),
    0 0 0 3px #fff,
    0 0 0 7px rgba(215, 119, 202, 0.26),
    0 8px 18px rgba(20, 32, 46, 0.34);
}

.table-dot.active::after {
  content: "";
  position: absolute;
  inset: -10px;
  border: 2px solid rgba(215, 119, 202, 0.48);
  border-radius: 999px;
}

.table-dot.multi-selected {
  width: 22px;
  height: 22px;
  border-color: var(--sun);
  outline: 4px solid rgba(215, 119, 202, 0.36);
  box-shadow:
    0 0 0 1px rgba(17, 17, 17, 0.58),
    0 0 0 3px #fff,
    0 0 0 7px rgba(255, 217, 106, 0.38),
    0 8px 18px rgba(20, 32, 46, 0.34);
}

.table-dot.multi-selected::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: var(--paper);
}

.table-dot.featured {
  width: 15px;
  height: 15px;
  border-color: var(--paper);
  box-shadow:
    0 0 0 1px rgba(17, 17, 17, 0.58),
    0 0 0 3px rgba(215, 119, 202, 0.62),
    0 0 0 5px rgba(255, 255, 255, 0.78),
    0 5px 14px rgba(20, 32, 46, 0.38);
}

.table-dot.muted {
  opacity: 0.22;
}

.stall-info-card {
  position: absolute;
  z-index: 7;
  width: min(260px, 78vw);
  max-height: min(460px, calc(100dvh - 150px));
  padding: 10px 76px 10px 10px;
  border: 2px solid var(--ink);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.97);
  color: var(--ink);
  box-shadow: 6px 6px 0 rgba(17, 17, 17, 0.18);
  transform: translate(18px, -50%) scale(var(--inverse-zoom, 1));
  transform-origin: left center;
  pointer-events: auto;
  overflow: auto;
  overscroll-behavior: contain;
}

.stall-info-card.preview-only {
  pointer-events: none;
  overflow: hidden;
}

.info-close {
  position: absolute;
  top: 7px;
  right: 7px;
  width: 28px;
  min-height: 28px;
  padding: 0;
  display: grid;
  place-items: center;
  border-width: 2px;
  border-radius: 6px;
  background: var(--paper);
  color: var(--ink);
  font-size: 1rem;
  line-height: 1;
  box-shadow: none;
}

.info-close:hover,
.info-close:focus-visible {
  background: var(--accent);
  color: var(--paper);
}

.stall-info-card.align-left {
  transform: translate(calc(-100% - 18px), -50%) scale(var(--inverse-zoom, 1));
  transform-origin: right center;
}

.stall-info-card.align-top {
  transform: translate(18px, calc(-100% - 18px)) scale(var(--inverse-zoom, 1));
  transform-origin: left bottom;
}

.stall-info-card.align-left.align-top {
  transform: translate(calc(-100% - 18px), calc(-100% - 18px)) scale(var(--inverse-zoom, 1));
  transform-origin: right bottom;
}

.info-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 6px;
}

.info-table,
.info-category {
  font-size: 0.66rem;
  font-weight: 900;
}

.info-table {
  color: var(--accent-dark);
}

.info-category {
  color: var(--muted);
}

.info-featured,
.stall-featured-badge,
.row-badge {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  border-radius: 999px;
  background: var(--accent);
  color: var(--paper);
  font-weight: 950;
  text-transform: uppercase;
}

.info-featured {
  margin-bottom: 6px;
  padding: 3px 7px;
  font-size: 0.58rem;
  letter-spacing: 0.02em;
}

.stall-info-card h3 {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 0 0 6px;
  font-size: 0.88rem;
  line-height: 1.15;
  font-weight: 950;
}

.stall-info-card h3 span:first-child {
  min-width: 0;
}

.instagram-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  width: 100%;
  min-height: 34px;
  margin-top: 2px;
  padding: 0 9px;
  border: 2px solid var(--line);
  border-radius: 6px;
  background: var(--wash);
  color: var(--ink);
  font-size: 0.72rem;
  font-weight: 950;
  text-decoration: none;
}

.instagram-link span {
  min-width: 0;
  overflow: hidden;
  color: var(--accent-dark);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.instagram-preview-icon {
  position: relative;
  flex: 0 0 auto;
  width: 14px;
  height: 14px;
  border: 2px solid var(--accent-dark);
  border-radius: 4px;
  opacity: 0.72;
}

.instagram-preview-icon::before {
  content: "";
  position: absolute;
  inset: 3px;
  border: 1.5px solid var(--accent-dark);
  border-radius: 999px;
}

.instagram-preview-icon::after {
  content: "";
  position: absolute;
  top: 2px;
  right: 2px;
  width: 2px;
  height: 2px;
  border-radius: 999px;
  background: var(--accent-dark);
}

.instagram-link:hover,
.instagram-link:focus-visible {
  border-color: var(--accent-dark);
  background: var(--paper);
}

.builder-popover-tools {
  display: grid;
  gap: 8px;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 2px dashed rgba(17, 17, 17, 0.18);
}

.builder-popover-actions {
  display: grid;
  grid-template-columns: 1fr 34px;
  gap: 6px;
}

.builder-popover-actions.table-actions {
  grid-template-columns: 1fr;
}

.table-actions .mini-action {
  min-height: 34px;
  width: 100%;
}

.table-assignment-tools {
  gap: 7px;
  min-height: 0;
}

.assigned-stall-summary {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  padding: 7px 8px;
  border: 2px solid var(--line);
  border-radius: 6px;
  background: #fff8d8;
}

.assigned-stall-summary strong,
.assigned-stall-summary small {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.assigned-stall-summary small {
  color: var(--muted);
  font-size: 0.64rem;
  font-weight: 900;
}

.mini-action {
  min-height: 32px;
  padding: 0 9px;
  font-size: 0.72rem;
}

.popup-search {
  display: grid;
  gap: 4px;
  color: var(--muted);
  font-size: 0.7rem;
  font-weight: 900;
}

.popup-search input,
.popup-search select {
  height: 36px;
  padding: 7px 9px;
  font-size: 0.78rem;
}

.popup-field-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 7px;
}

.popup-assign-list {
  display: grid;
  gap: 5px;
  max-height: min(138px, 28dvh);
  overflow: auto;
  overscroll-behavior: contain;
}

.popup-stall-option {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 7px;
  min-height: 34px;
  padding: 5px 7px;
  text-align: left;
  font-size: 0.72rem;
}

.popup-stall-option span:not(.swatch) {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.popup-stall-option small {
  color: var(--muted);
  font-size: 0.64rem;
  font-weight: 900;
}

.popup-stall-option.active {
  background: var(--sun);
}

.toggle-field {
  display: flex;
  align-items: center;
  gap: 9px;
  min-height: 42px;
  padding: 9px 10px;
  border: 2px solid var(--line);
  border-radius: 6px;
  background: var(--paper);
  color: var(--ink);
}

.toggle-field input {
  width: 18px;
  height: 18px;
  flex: 0 0 auto;
}

.toggle-field span {
  font-size: 0.78rem;
  font-weight: 900;
}

.stall-info-card p {
  margin: 0 0 8px;
  color: var(--muted);
  font-size: 0.76rem;
  line-height: 1.35;
}

.stall-info-card p:last-child {
  margin-bottom: 0;
}

.zoom-controls {
  position: absolute;
  right: 14px;
  bottom: 14px;
  z-index: 12;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px;
  border: 2px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 12px 28px rgba(20, 32, 46, 0.16);
}

.zoom-controls button {
  width: 38px;
  min-height: 36px;
  padding: 0;
  font-size: 1.2rem;
}

.zoom-controls output {
  min-width: 56px;
  text-align: center;
  font-weight: 800;
}

.multi-select-bar {
  position: absolute;
  left: 14px;
  bottom: 14px;
  z-index: 13;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 5px;
  border: 2px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 12px 28px rgba(20, 32, 46, 0.16);
}

.multi-select-bar button {
  min-height: 32px;
  padding: 0 9px;
  font-size: 0.7rem;
}

.multi-select-bar button.active {
  background: var(--accent);
  border-color: var(--accent-dark);
  color: var(--paper);
}

.multi-select-bar span {
  min-width: 64px;
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 900;
  text-align: center;
  white-space: nowrap;
}

.multi-select-bar .icon-action {
  width: 34px;
  min-width: 34px;
  padding: 0;
  font-size: 0.78rem;
}

.side-panel {
  position: fixed;
  top: 106px;
  right: clamp(12px, 3vw, 28px);
  bottom: 28px;
  z-index: 30;
  width: min(540px, calc(100vw - 24px));
  min-width: 0;
  pointer-events: none;
  transform: translateX(calc(100% + 36px));
  transition: transform 180ms ease;
}

.side-panel.open {
  pointer-events: auto;
  transform: translateX(0);
}

.results-panel,
.builder-panel {
  display: none;
  height: 100%;
  overflow: auto;
  border: 2px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
  padding: 16px;
  box-shadow: var(--shadow);
}

.side-panel.show-directory .results-panel,
.side-panel.show-builder .builder-panel {
  display: block;
}

.side-panel.show-directory .results-panel {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
}

.panel-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.panel-heading-actions {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.panel-close {
  width: 32px;
  min-height: 32px;
  padding: 0;
  font-weight: 900;
}

.count-pill {
  min-width: 34px;
  height: 30px;
  border-radius: 999px;
  background: var(--accent);
  color: var(--paper);
  border: 2px solid var(--ink);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 10px;
  font-weight: 800;
}

.stall-list {
  display: grid;
  align-content: start;
  gap: 6px;
  min-height: 0;
  overflow: auto;
  padding-right: 2px;
  padding-bottom: 8px;
}

.pagination-bar {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 8px;
  margin-top: 12px;
}

.pagination-bar span {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 900;
  white-space: nowrap;
}

.stall-card {
  position: relative;
  width: 100%;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 34px 72px;
  align-items: center;
  gap: 10px;
  min-height: auto;
  padding: 8px;
  border-radius: 6px;
}

.stall-card.featured {
  background: var(--paper);
  box-shadow: none;
}

.stall-featured-badge {
  margin-top: 5px;
  width: 86px;
  min-height: 25px;
  justify-content: center;
  padding: 4px 5px;
  border: 1.5px solid rgba(157, 75, 145, 0.32);
  background: rgba(255, 255, 255, 0.82);
  color: var(--accent-dark);
  font-size: 0.5rem;
  letter-spacing: 0.02em;
  text-align: center;
  box-shadow: 1px 1px 0 rgba(42, 22, 54, 0.08);
}

.favourite-button {
  width: 34px;
  min-height: 34px;
  padding: 0;
  align-self: center;
  border-color: var(--line);
  background: var(--paper);
  color: var(--muted);
  font-size: 1.05rem;
  line-height: 1;
  box-shadow: none;
}

.favourite-button.active {
  background: var(--accent);
  border-color: var(--accent-dark);
  color: var(--paper);
}

.favourite-button:hover,
.favourite-button:focus-visible {
  border-color: var(--accent-dark);
  color: var(--ink);
}

.favourite-button.active:hover,
.favourite-button.active:focus-visible {
  color: var(--paper);
}

.info-favourite {
  position: absolute;
  top: 7px;
  right: 42px;
  width: 28px;
  min-height: 28px;
  font-size: 0.9rem;
}

.stall-card.active {
  border-color: var(--accent);
  background: #f7d8f1;
  box-shadow: inset 0 0 0 2px rgba(215, 119, 202, 0.32);
}

.stall-card-main {
  min-width: 0;
  min-height: 62px;
  display: grid;
  grid-template-columns: 86px minmax(0, 1fr);
  align-items: start;
  gap: 12px;
  padding: 0;
  border: 0;
  background: transparent;
  text-align: left;
}

.stall-code-stack {
  display: grid;
  justify-items: center;
  align-content: start;
  width: 86px;
  min-width: 0;
}

.stall-map-action {
  width: 72px;
  min-height: 42px;
  margin-right: 0;
  padding: 0 8px;
  background: var(--accent);
  border-color: var(--accent-dark);
  color: var(--ink);
  font-size: 0.72rem;
  align-self: center;
}

.stall-title {
  display: block;
  font-weight: 900;
  overflow-wrap: anywhere;
  white-space: normal;
  line-height: 1.05;
}

.stall-meta {
  display: block;
  color: var(--muted);
  font-size: 0.74rem;
  overflow-wrap: anywhere;
  white-space: normal;
  line-height: 1.15;
}

.stall-code {
  min-width: 0;
  width: 86px;
  padding: 4px 5px;
  border-radius: 5px;
  background: #eef2f7;
  color: var(--ink);
  font-size: 0.68rem;
  font-weight: 900;
  text-align: center;
}

.stall-summary {
  min-width: 0;
}

.empty-state {
  display: grid;
  gap: 8px;
  padding: 12px;
  border: 2px dashed rgba(17, 17, 17, 0.22);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.55);
}

.empty-state strong {
  font-size: 0.92rem;
}

.empty-state p {
  margin: 0;
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.35;
}

.empty-state button {
  width: fit-content;
  min-height: 34px;
  padding-inline: 10px;
}

.stall-category {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 8px;
  max-width: 100%;
  color: var(--muted);
  font-size: 0.7rem;
  font-weight: 800;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.swatch {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: var(--pin);
}

.category-list {
  display: grid;
  align-content: start;
  gap: 10px;
  min-height: 0;
  overflow: auto;
  padding-right: 6px;
}

.category-chip {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  justify-content: flex-start;
  gap: 10px;
  min-height: 52px;
  padding: 0 12px;
  overflow: hidden;
  font-size: 0.9rem;
  text-align: left;
}

.category-chip span:last-child {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.category-chip.active {
  background: var(--sun);
  box-shadow: 3px 3px 0 rgba(17, 17, 17, 0.18);
}

.builder-stall-list {
  display: grid;
  gap: 10px;
  max-height: 260px;
  overflow: auto;
  padding-right: 6px;
}

.builder-stall-row {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  justify-content: stretch;
  gap: 10px;
  min-height: 62px;
  padding: 10px 12px;
  font-size: 0.96rem;
  text-align: left;
}

.builder-stall-row small {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.builder-stall-row strong {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  overflow: hidden;
}

.builder-stall-row strong > em {
  flex: 0 0 auto;
}

.builder-stall-row strong > span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.row-badge {
  padding: 2px 5px;
  font-size: 0.48rem;
  font-style: normal;
  letter-spacing: 0.02em;
}

.builder-stall-row small {
  color: var(--muted);
  font-size: 0.74rem;
  font-weight: 900;
  line-height: 1.2;
  margin-top: 3px;
}

.builder-stall-row.active {
  background: var(--sun);
  box-shadow: 3px 3px 0 rgba(17, 17, 17, 0.18);
}

.stall-editor-form {
  align-self: stretch;
  align-content: start;
  gap: 12px;
  min-height: 0;
  padding: 14px;
  border: 2px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}

.stall-editor-form .form-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start;
  align-items: center;
  gap: 6px;
}

.stall-editor-form .form-actions button {
  flex: 0 0 auto;
  min-height: 34px;
  padding: 0 10px;
  font-size: 0.76rem;
}

.editor-kicker {
  padding-bottom: 8px;
  border-bottom: 2px dashed rgba(17, 17, 17, 0.2);
  color: var(--accent-dark);
  font-size: 0.76rem;
  font-weight: 950;
  text-transform: uppercase;
}

.bulk-stall-box {
  border: 2px solid var(--line);
  border-radius: 8px;
  background: #fff2bf;
  overflow: clip;
}

.manager-search-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 42px;
  align-items: end;
  gap: 10px;
}

.manager-search {
  display: grid;
  align-content: end;
  gap: 6px;
  margin: 0;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 900;
}

.manager-search input {
  height: 42px;
}

.icon-action {
  width: 42px;
  height: 42px;
  min-height: 42px;
  padding: 0;
  background: var(--sun);
  font-size: 1.35rem;
  font-weight: 950;
  line-height: 1;
}

.bulk-stall-box summary {
  min-height: 38px;
  display: flex;
  align-items: center;
  padding: 0 10px;
  font-size: 0.78rem;
  font-weight: 950;
  cursor: pointer;
}

.bulk-stall-box .builder-form {
  margin-top: 0;
  padding: 10px;
  border-top: 2px solid var(--line);
}

.builder-form {
  display: grid;
  gap: 12px;
  margin-top: 14px;
}

.bulk-table-form {
  margin-top: 0;
}

.bulk-table-form.armed {
  background: #fff2bf;
  outline: 2px solid var(--accent);
  outline-offset: -2px;
}

.builder-section {
  border: 2px solid var(--line);
  border-radius: 8px;
  margin-top: 10px;
  overflow: clip;
}

.builder-section:first-of-type {
  margin-top: 0;
}

.builder-section summary {
  display: flex;
  align-items: center;
  min-height: 42px;
  padding: 0 12px;
  background: #fff2bf;
  color: var(--ink);
  cursor: pointer;
  font-size: 0.86rem;
  font-weight: 900;
}

.builder-section summary::-webkit-details-marker {
  display: none;
}

.builder-section summary::after {
  content: "+";
  margin-left: auto;
  color: var(--muted);
  font-weight: 900;
}

.builder-section[open] summary::after {
  content: "-";
}

.builder-section .builder-form,
.builder-section .data-panel {
  padding: 12px;
}

.bulk-form,
.annotation-form,
.data-panel {
  margin-top: 0;
  border-top: 2px solid var(--line);
}

.builder-form label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 800;
}

.builder-form input,
.builder-form select,
.builder-form textarea {
  padding: 10px 11px;
  color: var(--ink);
  font-weight: 500;
}

.field-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.hint {
  margin: 0;
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.4;
}

.edit-status {
  margin: 0;
  padding: 9px 10px;
  border: 1px solid #cdd9e4;
  border-radius: 6px;
  background: #f7fafc;
  color: var(--ink);
  font-size: 0.86rem;
  font-weight: 800;
}

.form-actions,
.data-actions {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(118px, 1fr));
  gap: 8px;
}

#saveStall,
#saveTable,
#saveBuilderStall,
#saveCategory,
#saveMazeMap {
  background: var(--good);
  border-color: var(--good);
  color: #fff;
  font-weight: 900;
}

.danger {
  color: var(--danger);
}

.import-button {
  position: relative;
  text-align: center;
  font-weight: 800;
}

.import-button input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

dialog {
  width: min(760px, calc(100vw - 24px));
  border: 2px solid var(--line);
  border-radius: 8px;
  padding: 16px;
  box-shadow: var(--shadow);
}

.manager-dialog {
  width: min(920px, calc(100vw - 24px));
  max-height: min(820px, calc(100vh - 24px));
  overflow: auto;
}

#stallManagerDialog,
#categoryManagerDialog {
  width: min(940px, calc(100vw - 24px));
  height: min(680px, calc(100vh - 24px));
  overflow: hidden;
  padding: 20px;
}

#stallManagerDialog .dialog-shell,
#categoryManagerDialog .dialog-shell {
  height: 100%;
  grid-template-rows: auto minmax(0, 1fr);
  gap: 18px;
}

.dialog-shell {
  display: grid;
  gap: 14px;
}

.manager-grid {
  display: grid;
  grid-template-columns: minmax(330px, 0.95fr) minmax(300px, 0.8fr);
  gap: 24px;
  min-height: 0;
}

.manager-list-pane {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  gap: 16px;
  min-width: 0;
  min-height: 0;
}

.category-list-heading {
  align-items: center;
}

.category-list-heading .hint {
  margin-top: 3px;
}

.manager-dialog .builder-stall-list {
  align-content: start;
  max-height: none;
  min-height: 0;
}

#stallManagerDialog .builder-form input,
#stallManagerDialog .builder-form select,
#stallManagerDialog .builder-form textarea,
#categoryManagerDialog .builder-form input,
#categoryManagerDialog .builder-form select,
#categoryManagerDialog .builder-form textarea {
  min-height: 40px;
  padding: 8px 10px;
  font-size: 0.9rem;
  line-height: 1.2;
}

.dialog-actions {
  display: flex;
  justify-content: flex-end;
  margin: 10px 0;
}

dialog::backdrop {
  background: rgba(20, 32, 46, 0.36);
}

#exportText {
  width: 100%;
  padding: 12px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.82rem;
}

@media (max-width: 720px) {
  .app-header {
    min-height: auto;
    align-items: flex-start;
    flex-direction: column;
    gap: 8px;
    padding: 10px 12px 1px;
    position: relative;
  }

  body[data-initial-mode="visitor"] .app-header {
    display: grid;
    grid-template-columns: minmax(132px, 0.82fr) minmax(0, 1.18fr);
    align-items: center;
    gap: 8px;
    padding: 9px 10px 0;
  }

  .app-header > div:first-child {
    min-width: 0;
  }

  .brand-title {
    transform: translateY(1px);
  }

  .brand-title-image {
    width: clamp(86px, 24vw, 112px);
  }

  .header-controls {
    width: 100%;
    min-width: 0;
    align-items: stretch;
    flex-direction: column;
    gap: 6px;
  }

  .day-switcher {
    width: 100%;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 6px;
  }

  body[data-initial-mode="visitor"] .day-switcher {
    gap: 5px;
  }

  .day-button {
    min-height: 42px;
    padding: 6px 8px 6px 12px;
    align-content: center;
    justify-items: start;
    gap: 1px;
  }

  body[data-initial-mode="visitor"] .day-button {
    min-height: 36px;
    padding: 5px 6px 5px 10px;
    border-radius: 7px;
    box-shadow: 2px 2px 0 rgba(17, 17, 17, 0.12);
  }

  body[data-initial-mode="visitor"] .day-button::before {
    width: 4px;
  }

  .day-button span,
  .day-button small {
    font-size: 0.52rem;
    line-height: 1;
  }

  .day-button strong {
    font-size: 0.72rem;
    line-height: 1.05;
  }

  body[data-initial-mode="visitor"] .day-button span {
    font-size: 0.46rem;
  }

  body[data-initial-mode="visitor"] .day-button strong {
    font-size: 0.62rem;
    line-height: 1.08;
  }

  body[data-initial-mode="visitor"] .day-button.active {
    box-shadow: 2px 2px 0 rgba(157, 75, 145, 0.2);
  }

  .day-button small {
    display: none;
  }

  .header-actions,
  .field-row,
  .form-actions,
  .data-actions {
    grid-template-columns: 1fr;
  }

  .app-shell {
    padding: 6px 12px 0;
  }

  .toolbar {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 6px;
    padding: 5px;
    width: calc(100% + 24px);
    margin: 0 -12px 5px;
    border-right: 0;
    border-left: 0;
    border-radius: 0;
    overflow: visible;
  }

  body[data-initial-mode="builder"] .toolbar {
    grid-template-columns: repeat(6, minmax(0, 1fr));
  }

  .toolbar .search-box,
  body[data-initial-mode="builder"] .toolbar .search-box {
    grid-column: 1 / -1;
  }

  .fair-context {
    top: 6px;
    margin: 0 6px -26px;
    padding: 0;
    font-size: 0.6rem;
    line-height: 1.1;
  }

  .fair-context span:first-child {
    padding: 3px 7px;
  }

  .version-meta #lastUpdated {
    display: none;
  }

  .version-meta {
    flex-shrink: 0;
  }

  .version-status {
    min-height: 22px;
    padding-inline: 7px;
    font-size: 0.58rem;
  }

  .toolbar .search-box {
    min-width: 0;
  }

  .category-picker {
    min-width: 0;
    height: 40px;
  }

  .category-filter-button {
    min-height: 40px;
    height: 40px;
    justify-content: center;
    padding: 0;
  }

  .category-filter-button::after,
  .category-filter-button #categoryFilterLabel,
  .category-filter-button span:not(.category-filter-icon) {
    display: none;
  }

  .category-filter-icon {
    width: 19px;
    height: 19px;
  }

  .category-filter-menu {
    left: 0;
    width: min(280px, calc(100vw - 18px));
  }

  .toolbar button {
    min-height: 40px;
    padding-inline: 8px;
    white-space: nowrap;
  }

  #clearSearch,
  #openDirectory,
  #favouritesFilter,
  #unassignedFilter {
    width: 100%;
    padding: 0;
  }

  #clearSearch .button-label,
  #openDirectory .button-label,
  #unassignedFilter .button-label,
  #favouritesFilter .button-label,
  #openBuilderTools .button-label {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
  }

  #clearSearch .button-icon {
    font-size: 1.25rem;
  }

  #openDirectory .button-icon {
    font-size: 1rem;
  }

  #openBuilderTools {
    width: 100%;
    min-width: 0;
    padding: 0;
  }

  .search-box::before {
    left: 10px;
    bottom: 9px;
    width: 11px;
    height: 11px;
  }

  .search-box::after {
    left: 20px;
    bottom: 8px;
    width: 6px;
  }

  .search-box span {
    left: 32px;
    top: 5px;
    font-size: 0.56rem;
  }

  .search-box input,
  select {
    height: 40px;
  }

  .search-box input {
    padding: 15px 8px 4px 32px;
  }

  .map-viewport {
    border-radius: 0;
    margin-inline: -12px;
    border-left: 0;
    border-right: 0;
  }

  .mazemap-canvas {
    min-width: 1040px;
  }

  .zoom-controls {
    position: absolute;
    right: 8px;
    bottom: 8px;
    width: fit-content;
    margin: 0;
    padding: 4px;
    gap: 4px;
  }

  .multi-select-bar {
    left: 8px;
    right: 8px;
    bottom: 52px;
    gap: 4px;
    padding: 4px;
  }

  .multi-select-bar button {
    min-height: 32px;
    padding: 0 6px;
    font-size: 0.64rem;
  }

  .multi-select-bar span {
    min-width: 54px;
    font-size: 0.66rem;
  }

  .multi-select-bar .icon-action {
    width: 32px;
    min-width: 32px;
    font-size: 0.68rem;
  }

  .zoom-controls button {
    width: 32px;
    min-height: 32px;
  }

  .zoom-controls output {
    min-width: 46px;
    font-size: 0.78rem;
  }

  .stall-info-card {
    width: min(300px, calc(100vw - 28px));
    max-height: min(430px, calc(100dvh - 132px));
    padding-right: 46px;
    transform: translate(24px, 24px) scale(var(--inverse-zoom, 1));
    transform-origin: left top;
  }

  .stall-info-card.align-left {
    transform: translate(calc(-100% - 24px), 24px) scale(var(--inverse-zoom, 1));
    transform-origin: right top;
  }

  .stall-info-card.align-top {
    transform: translate(24px, calc(-100% - 24px)) scale(var(--inverse-zoom, 1));
    transform-origin: left bottom;
  }

  .stall-info-card.align-left.align-top {
    transform: translate(calc(-100% - 24px), calc(-100% - 24px)) scale(var(--inverse-zoom, 1));
    transform-origin: right bottom;
  }

  .info-close {
    width: 34px;
    min-height: 34px;
    font-size: 1.1rem;
  }

  .results-panel,
  .builder-panel {
    padding: 14px;
  }

  .side-panel {
    top: auto;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100vw;
    max-height: 58vh;
    transform: translateY(calc(100% + 24px));
  }

  .side-panel.open {
    transform: translateY(0);
  }

  .results-panel,
  .builder-panel {
    height: 58vh;
    border-radius: 12px 12px 0 0;
    border-left: 0;
    border-right: 0;
    border-bottom: 0;
  }

  .manager-grid {
    grid-template-columns: 1fr;
    grid-template-rows: minmax(220px, 0.9fr) auto;
    overflow: auto;
  }

  .manager-dialog .builder-stall-list {
    max-height: none;
  }

  .stall-card {
    grid-template-columns: minmax(0, 1fr) 32px 58px;
    gap: 8px;
    padding: 7px;
  }

  .stall-card-main {
    grid-template-columns: 72px minmax(0, 1fr);
    min-height: 58px;
    gap: 9px;
  }

  .stall-map-action {
    width: 58px;
    padding-inline: 8px;
  }

  .favourite-button {
    width: 32px;
    min-height: 32px;
    font-size: 0.98rem;
  }

  .stall-code {
    width: 72px;
    font-size: 0.64rem;
  }

  .stall-code-stack {
    width: 72px;
  }

  .stall-featured-badge {
    width: 72px;
    min-height: 24px;
    font-size: 0.46rem;
  }

  .stall-category {
    max-width: 100%;
  }
}
