*, *::before, *::after {
  box-sizing: border-box;
}
html, body {
  height: 100%;
  margin: 0;
  font-family: system-ui, sans-serif;
  background: #0f1419;
  color: #e6edf3;
}
.layout {
  min-height: 100%;
  display: flex;
  flex-direction: column;
  align-items: stretch;
}
.top {
  flex-shrink: 0;
  padding: 1.25rem 1rem;
  display: flex;
  justify-content: center;
  align-items: center;
}
.top-inner {
  text-align: center;
}
.hint {
  margin-top: 0.4rem;
  font-size: 0.8rem;
  color: #8b9cb3;
}
.btn {
  appearance: none;
  border: 1px solid #3b82f6;
  background: linear-gradient(180deg, #1e3a5f 0%, #152238 100%);
  color: #93c5fd;
  font-size: 1rem;
  font-weight: 600;
  padding: 0.65rem 1.4rem;
  border-radius: 999px;
  cursor: pointer;
  letter-spacing: 0.02em;
}
.btn:hover {
  border-color: #60a5fa;
  color: #bfdbfe;
}
.btn:active {
  transform: scale(0.98);
}
.stage-wrap {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 241px;
  min-height: 0;
}
.circles-stage {
  position: relative;
  width: 100%;
  max-width: calc(100vw - 482px);
  display: flex;
  justify-content: center;
  align-items: flex-start;
}
.link-layer {
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
  overflow: visible;
}
.link-layer * {
  pointer-events: none;
}
.circles-root {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-content: flex-start;
  max-width: 100%;
}
.cell {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
}
.ring {
  border-radius: 50%;
  border-style: solid;
  border-color: #2563eb;
  background: transparent;
  box-sizing: border-box;
  flex-shrink: 0;
  cursor: grab;
  touch-action: none;
  transition: box-shadow 0.12s ease;
}
.ring--dragging {
  box-shadow: 0 0 0 2px #93c5fd, 0 0 14px rgba(59, 130, 246, 0.5);
  cursor: grabbing;
}
.ring--drop-target {
  box-shadow: 0 0 0 3px #4ade80, 0 0 18px rgba(74, 222, 128, 0.4);
  border-color: #4ade80;
}
body.is-link-drag {
  user-select: none;
  -webkit-user-select: none;
}
