* {
  box-sizing: border-box;
}

html,body {
  margin: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

body {
  font-family: "Pretendard Variable",Pretendard,-apple-system,"Apple SD Gothic Neo",sans-serif;
  -webkit-font-smoothing: antialiased;
  color: #161b27;
}

/* 장면 */

.stage {
  position: relative;
  height: 356px;
  min-width: 0;
  overflow: hidden;
  border-radius: 10px;
  background: radial-gradient(120% 95% at 50% 40%,#ffffff 0%,#f8f8f7 58%,#eeefee 100%);
}

.stage canvas,.stage .poster {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
}

.stage .poster {
  object-fit: contain;
}

.stage [hidden] {
  display: none;
}

.tags {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

/* 이름표: 흰 바탕 · 1px 잉크 테두리 · 반경 6 · 13px 굵게. 정의 물체 하나만 유형색. 가는 지시선 + 4px 끝점 */

.tag {
  position: absolute;
  left: 0;
  top: 0;
  padding: 5px 10px;
  background: #fff;
  border: 1px solid #161b27;
  border-radius: 6px;
  box-shadow: 0 1px 3px rgba(22,27,39,.08);
  font-size: 13px;
  line-height: 17px;
  font-weight: 700;
  letter-spacing: -.02em;
  color: #161b27;
  white-space: nowrap;
  will-change: transform;
}

.tag.key {
  background: var(--tc);
  border-color: var(--tc);
  color: #fff;
}

.leads {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  overflow: visible;
}

.leads line {
  stroke: #161b27;
  stroke-width: 1;
}

.leads circle {
  fill: #161b27;
}

.hl {
  position: absolute;
  left: 0;
  top: 0;
  border-radius: 10px;
  pointer-events: none;
  opacity: 0;
  transition: opacity .2s var(--ease);
  box-shadow: 0 0 0 2px var(--tc),0 0 0 6px color-mix(in srgb,var(--tc) 18%,transparent);
}

.hl.on {
  opacity: 1;
}

.stage {
  height: 100%;
  border-radius: 0;
}

:root[data-compact="true"] .stage {
  /* The scene rig sets an inline background; compact scenes share the white section. */
  background: #fff !important;
}

:root[data-compact="true"] .hl {
  display: none;
}

:root[data-compact="true"] .tag {
  padding: 4px 8px;
  font-size: 12px;
}

@media (prefers-reduced-motion:reduce) {
  .hl,.tag {
    transition: none;
  }
}
