.effects-debug-dock {
  position: fixed;
  right: 12px;
  bottom: 12px;
  z-index: 1200;
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-width: min(320px, calc(100vw - 24px));
  pointer-events: none;
}

.map-panel-link {
  position: fixed;
  right: 12px;
  top: 12px;
  z-index: 1200;
  appearance: none;
  min-height: 38px;
  padding: 8px 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: rgba(228, 232, 238, 0.96);
  color: #101317;
  border-top: 2px solid #ffffff;
  border-left: 2px solid #ffffff;
  border-right: 2px solid #5c6472;
  border-bottom: 2px solid #5c6472;
  box-shadow: 2px 2px 0 rgba(0, 0, 0, 0.18);
  font-family: var(--font-ui);
  font-size: 16px;
  line-height: 1;
  text-decoration: none;
}

.map-panel-link:active {
  transform: translate(1px, 1px);
  box-shadow: none;
}

.effects-debug-actions,
.effects-debug-panel {
  pointer-events: auto;
}

.effects-debug-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.effects-debug-btn {
  appearance: none;
  min-height: 36px;
  padding: 8px 10px;
  background: rgba(228, 232, 238, 0.94);
  color: #101317;
  border-top: 2px solid #ffffff;
  border-left: 2px solid #ffffff;
  border-right: 2px solid #5c6472;
  border-bottom: 2px solid #5c6472;
  box-shadow: 2px 2px 0 rgba(0, 0, 0, 0.18);
  font-family: var(--font-ui);
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
}

.effects-debug-link {
  text-decoration: none;
}

.effects-debug-btn.is-active {
  background: #dfe7ff;
  border-top: 2px solid #5c6472;
  border-left: 2px solid #5c6472;
  border-right: 2px solid #ffffff;
  border-bottom: 2px solid #ffffff;
  box-shadow: none;
}

.effects-debug-panel {
  margin: 0;
  padding: 10px 12px;
  background: rgba(242, 238, 230, 0.96);
  color: #1d1a16;
  border-top: 2px solid #faf7f1;
  border-left: 2px solid #faf7f1;
  border-right: 2px solid #877c6e;
  border-bottom: 2px solid #877c6e;
  box-shadow: 3px 3px 0 rgba(0, 0, 0, 0.2);
  font-family: var(--font-ui);
  font-size: 14px;
  line-height: 1.35;
  white-space: pre-wrap;
}

@media (max-width: 900px) {
  .effects-debug-dock {
    right: 10px;
    bottom: calc(84px + env(safe-area-inset-bottom));
  }

  .map-panel-link {
    right: 10px;
    top: calc(10px + env(safe-area-inset-top));
    min-height: 34px;
    font-size: 15px;
  }

  .effects-debug-btn {
    min-height: 34px;
    font-size: 15px;
  }
}
