#tour {
  --dock-controls-height: 62px;
  --dock-edge: 22px;
  --dock-floor: max(var(--dock-edge), env(safe-area-inset-bottom));
  --dock-bottom: calc(var(--dock-floor) + var(--dock-controls-height));
  --opening-dock-height: 76px;
  --opening-copy-bottom: calc(var(--dock-floor) + var(--opening-dock-height) + 24px);
}

#project-points {
  left: max(var(--dock-edge), env(safe-area-inset-left));
  right: max(var(--dock-edge), env(safe-area-inset-right));
  bottom: var(--dock-bottom);
  transform: none;
  max-width: 1510px;
  margin-inline: auto;
  display: grid;
  grid-template-columns: repeat(9, minmax(0, 1fr));
  gap: 5px;
  padding: 6px;
  border-color: #ecd0a341;
  background: linear-gradient(110deg, #10222bef, #0c1b24ed);
  box-shadow: 0 12px 36px #08141cc0;
}

#project-points .project-point {
  display: grid;
  grid-template-columns: clamp(33px, 3.1vw, 52px) minmax(0, 1fr) auto;
  align-items: center;
  min-width: 0;
  min-height: 57px;
  gap: 7px;
  padding: 5px 8px 5px 5px;
  text-align: left;
  white-space: normal;
}

#project-points .project-point img {
  display: block;
  width: 100%;
  height: 42px;
  object-fit: cover;
  background: #1b3540;
}

#project-points .project-point strong {
  font-size: clamp(.72rem, .96vw, .9rem);
  line-height: 1.19;
  text-wrap: balance;
}

#project-points .project-point small {
  font-size: .67rem;
  line-height: 1.21;
}

#project-points .point-arrow {
  margin-left: 0;
}

#project-points .project-point:focus-visible {
  outline-offset: -2px;
}

#tour[data-cover="true"] #project-points { bottom: var(--dock-floor); }

#tour .bottom-ui .now {
  display: grid;
  grid-template: "chapter tools" auto "title tools" auto / minmax(0, auto) auto;
  align-items: end;
  column-gap: clamp(8px, 2vw, 25px);
}

#tour .bottom-ui .chapter { grid-area: chapter; }
#tour .bottom-ui h1 {
  grid-area: title;
  margin-bottom: 0;
  font-size: clamp(1.45rem, 2.6vw, 2.375rem);
}
#tour .bottom-ui .scene-tools { grid-area: tools; }
#tour .angle-drawer { bottom: calc(var(--dock-bottom) + var(--opening-dock-height) + 3px); }

@media (max-width: 1320px) {
  #project-points .project-point { grid-template-columns: 31px minmax(0, 1fr); }
  #project-points .point-arrow { display: none; }
  #project-points .project-point small { font-size: .62rem; }
}

@media (max-width: 1100px) {
  #tour { --opening-dock-height: 134px; }
  #project-points { grid-template-columns: repeat(5, minmax(0, 1fr)); }
}

@media (max-width: 870px) {
  #tour { --dock-edge: 15px; --opening-dock-height: 123px; }
  #project-points .project-point { grid-template-columns: 38px minmax(0, 1fr); min-height: 49px; }
  #project-points .project-point img { height: 35px; }
  #project-points .project-point strong { font-size: .75rem; }
  #hint { display: none; }
}

@media (max-width: 700px) {
  #tour { --opening-dock-height: 172px; }
  #project-points { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 560px) {
  #tour { --dock-edge: 12px; --dock-controls-height: 57px; --opening-dock-height: 150px; }
  #project-points .project-point { grid-template-columns: 25px minmax(0, 1fr); min-height: 42px; gap: 5px; padding: 4px; }
  #project-points .project-point img { height: 29px; }
  #project-points .project-point strong { font-size: .705rem; text-wrap: wrap; }
  #project-points .project-point small { display: none; }
  #tour .bottom-ui .chapter { display: none; }
  #tour .bottom-ui h1 { font-size: .875rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  #tour .bottom-ui .now { display: flex; align-items: center; gap: 8px; }
  #tour .bottom-ui .scene-tools { order: -1; }
  #tour .bottom-ui #angles { width: 43px; padding: 0; justify-content: center; font-size: 0; gap: 0; }
}

@media (max-width: 360px) {
  #project-points .project-point:not(.project-point-new) { grid-template-columns: 1fr; text-align: center; }
  #project-points .project-point:not(.project-point-new) img { display: none; }
}

@media (max-height: 510px) {
  #tour { --dock-controls-height: 50px; }
  #project-points .project-point { min-height: 39px; }
  #project-points .project-point img { height: 27px; }
  #project-points .project-point small { display: none; }
  #tour .bottom-ui .chapter { display: none; }
  #tour .bottom-ui h1 { font-size: 1.15rem; }
}

@media (max-width: 1100px) and (min-width: 701px) and (max-height: 510px) {
  #tour { --opening-dock-height: 102px; }
}

@media (max-width: 700px) and (max-height: 510px) {
  #tour { --opening-dock-height: 140px; }
}
