/* 청약로그 입주물량 지도·표 모듈 (scoped: .mvm-root)
   기존 style.css와 충돌하지 않도록 모든 셀렉터를 .mvm-root 아래로 한정.
   사이트 변수가 있으면 따라가고, 없으면 기본값 사용. */
.mvm-root {
  --mvm-accent: var(--accent, #2563eb);
  --mvm-fg: var(--fg, #1f2430);
  --mvm-muted: var(--muted, #6b7280);
  --mvm-card-bg: var(--card-bg, #ffffff);
  --mvm-line: var(--line, #e5e7eb);
  color: var(--mvm-fg);
  font-family: inherit;
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 12px;
}
.mvm-root *, .mvm-root *::before, .mvm-root *::after { box-sizing: border-box; }
.mvm-h2 { font-size: 1.25rem; font-weight: 700; margin: 0 0 4px; }
.mvm-meta { font-size: 0.78rem; color: var(--mvm-muted); line-height: 1.5; margin: 0 0 14px; }
.mvm-meta a { color: var(--mvm-accent); }
.mvm-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 0 0 18px; }
.mvm-card { background: var(--mvm-card-bg); border: 1px solid var(--mvm-line); border-radius: 10px; padding: 10px 12px; }
.mvm-card .mvm-num { font-size: 1.15rem; font-weight: 700; font-variant-numeric: tabular-nums; }
.mvm-card .mvm-lab { font-size: 0.72rem; color: var(--mvm-muted); margin-top: 2px; }
.mvm-sec { margin: 22px 0 8px; font-size: 1rem; font-weight: 700; }
.mvm-sec small { font-weight: 400; color: var(--mvm-muted); font-size: 0.75rem; margin-left: 6px; }

/* 시도 타일 지도 (그리드 카토그램) */
.mvm-tilemap { display: grid; grid-template-columns: repeat(5, 1fr); gap: 4px; }
.mvm-tile { border: 1px solid var(--mvm-line); border-radius: 8px; padding: 8px 6px; text-align: center; cursor: pointer; background: var(--mvm-card-bg); color: var(--mvm-fg); font: inherit; }
.mvm-tile .t-name { font-size: 0.8rem; font-weight: 700; }
.mvm-tile .t-val { font-size: 0.72rem; font-variant-numeric: tabular-nums; }
.mvm-tile[aria-pressed="true"] { outline: 2px solid var(--mvm-accent); outline-offset: -2px; }
.mvm-tile-empty { visibility: hidden; }
.mvm-legend { display: flex; align-items: center; gap: 6px; font-size: 0.72rem; color: var(--mvm-muted); margin: 6px 0 0; }
.mvm-legend .sw { width: 14px; height: 10px; border-radius: 2px; display: inline-block; }

/* 시군구 바 차트 */
.mvm-bars { display: flex; flex-direction: column; gap: 6px; }
.mvm-bar-row { display: grid; grid-template-columns: 92px 1fr 64px; align-items: center; gap: 8px; font-size: 0.8rem; }
.mvm-bar-row .b-name { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mvm-bar-track { background: var(--mvm-line); border-radius: 4px; height: 14px; }
.mvm-bar-fill { background: var(--mvm-accent); height: 14px; border-radius: 4px; min-width: 2px; }
.mvm-bar-row .b-val { text-align: right; font-variant-numeric: tabular-nums; }

/* 월별 차트 */
.mvm-months { display: flex; align-items: flex-end; gap: 3px; height: 110px; padding: 6px 0 0; overflow-x: auto; }
.mvm-month { flex: 1 0 auto; min-width: 22px; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; height: 100%; }
.mvm-month .m-bar { width: 100%; background: var(--mvm-accent); border-radius: 3px 3px 0 0; opacity: .85; }
.mvm-month .m-lab { font-size: 0.62rem; color: var(--mvm-muted); writing-mode: vertical-rl; transform: rotate(180deg); margin-top: 4px; max-height: 64px; }
.mvm-month .m-val { font-size: 0.62rem; color: var(--mvm-muted); font-variant-numeric: tabular-nums; }

/* 표 */
.mvm-table-wrap { overflow-x: auto; border: 1px solid var(--mvm-line); border-radius: 10px; }
.mvm-table { border-collapse: collapse; width: 100%; font-size: 0.8rem; min-width: 520px; }
.mvm-table th, .mvm-table td { padding: 8px 10px; text-align: left; border-bottom: 1px solid var(--mvm-line); white-space: nowrap; }
.mvm-table th { background: var(--mvm-card-bg); font-weight: 700; cursor: pointer; user-select: none; position: sticky; top: 0; }
.mvm-table td.num, .mvm-table th.num { text-align: right; font-variant-numeric: tabular-nums; }
.mvm-table tr:last-child td { border-bottom: none; }
.mvm-filter-note { font-size: 0.75rem; color: var(--mvm-muted); margin: 6px 0; }
.mvm-reset { font: inherit; font-size: 0.75rem; border: 1px solid var(--mvm-line); background: var(--mvm-card-bg); color: var(--mvm-accent); border-radius: 6px; padding: 3px 8px; cursor: pointer; }
.mvm-disclaimer { font-size: 0.75rem; color: var(--mvm-muted); border-top: 1px solid var(--mvm-line); margin-top: 18px; padding-top: 10px; line-height: 1.6; }

@media (max-width: 480px) {
  .mvm-cards { grid-template-columns: repeat(3, 1fr); gap: 6px; }
  .mvm-card .mvm-num { font-size: 1rem; }
  .mvm-bar-row { grid-template-columns: 78px 1fr 58px; }
}

/* 모바일 가독성: 월별 막대 라벨 11px */
.mvm-month .m-lab,.mvm-month .m-val{font-size:11px}
.mvm-month .m-lab{white-space:nowrap;max-height:none;margin-top:6px}
