*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  /* ── 색상: 부석사·단청에서 가져온 따뜻한 팔레트 ── */
  --paper: #f6efe1;
  --paper-deep: #efe2c6;
  --ink: #332a22;
  --ink-soft: #6b5c4c;
  --temple-red: #a5382f;
  --temple-blue: #2c5568;
  --temple-gold: #c69a45;
  --temple-gold-soft: #e2c98a;

  --image-aspect: 1448 / 1086;
  --hotspot-glow-color: rgba(255, 180, 60, 0.6);
  --hotspot-glow-color-mid: rgba(255, 180, 60, 0.25);
  --hotspot-glow-color-fade: rgba(255, 180, 60, 0);
  --bar-icon-width: 6.4%;
  --bar-icon-height: 11.2%;
}

html, body {
  height: 100%;
}

body {
  font-family: 'Gowun Dodum', 'Malgun Gothic', 'Noto Sans KR', sans-serif;
  background: var(--paper);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
}

/* ── 배경: 은은한 한지 결 + 상단 미색 그러데이션 ── */
.home-view {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 40px 24px;
  gap: 28px;
  position: relative;
  background:
    radial-gradient(circle at 1px 1px, rgba(51, 42, 34, 0.05) 1px, transparent 1px),
    radial-gradient(ellipse at center, transparent 45%, rgba(51, 42, 34, 0.07) 100%),
    linear-gradient(175deg, #fbf7ec 0%, var(--paper) 55%, var(--paper-deep) 100%);
  background-size: 22px 22px, 100% 100%, 100% 100%;
}

.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;
}

/* ── 지도 프레임: 병풍/족자를 연상시키는 액자 ── */
.home-frame {
  position: relative;
  width: min(100%, 1200px);
  padding: 18px;
  background: #fffdf8;
  border-radius: 20px;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.6) inset,
    0 18px 44px rgba(51, 42, 34, 0.16);
  animation: rise 0.7s 0.1s ease both;
}

.home-frame::before {
  content: "";
  position: absolute;
  inset: 8px;
  border: 1px solid var(--temple-gold-soft);
  border-radius: 14px;
  pointer-events: none;
}

.home-frame::after {
  content: "";
  position: absolute;
  inset: 12px;
  border: 1px solid rgba(198, 154, 69, 0.35);
  border-radius: 11px;
  pointer-events: none;
}

.home-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: var(--image-aspect);
  border-radius: 12px;
  overflow: visible;
  background: var(--paper-deep);
}

.home-wrap img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  user-select: none;
  pointer-events: none;
  border-radius: 12px;
}

.hotspot-layer {
  position: absolute;
  inset: 0;
  overflow: visible;
}

.hotspot {
  position: absolute;
  border: none;
  background: transparent;
  cursor: pointer;
  padding: 0;
  border-radius: 8px;
  overflow: visible;
}

.hotspot--map {
  transform: translate(-50%, -50%);
  transform-origin: center center;
}

.hotspot--bar {
  transform: translate(-50%, -50%);
  transform-origin: center center;
  z-index: 1;
}

.hotspot:focus {
  outline: none;
}

.hotspot:focus-visible {
  outline: 2px solid var(--temple-blue);
  outline-offset: 3px;
  border-radius: 50%;
}

/* 지도 글로우 — 원형 (부모 핫스팟 기준 %) */
.hotspot-glow--map {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 0;
  width: 200%;
  height: 200%;
  border-radius: 50%;
  transform: translate(-50%, -50%);
  background: radial-gradient(
    circle,
    var(--hotspot-glow-color) 0%,
    var(--hotspot-glow-color-mid) 40%,
    var(--hotspot-glow-color-fade) 75%
  );
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

.hotspot--map:hover .hotspot-glow--map,
.hotspot--map:focus-visible .hotspot-glow--map {
  opacity: 1;
}

@keyframes rise {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

/* 지도 프레임에 살짝 손을 얹는 듯한 반응 */
.home-frame {
  transition: transform 0.35s ease, box-shadow 0.35s ease;
}

.home-frame:hover,
.home-frame:focus-within {
  transform: translateY(-3px);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.6) inset,
    0 22px 52px rgba(51, 42, 34, 0.2);
}



@media (prefers-reduced-motion: reduce) {
  .home-frame {
    animation: none;
  }

  .home-frame:hover, .home-frame:focus-within {
    transform: none;
  }
}

@media (max-width: 640px) {
  .home-view {
    padding: 24px 14px;
    gap: 20px;
  }

  .home-frame {
    padding: 10px;
    border-radius: 16px;
  }
}
