/* 고객 리포트 페이지(프레임) — 목업 PART 2의 sections.css 클래스를 그대로 쓰고, 목업에서 인라인이던 모양만 여기로 모았다. */
.rp-report .rp-section { margin-bottom: 20px; }
.rp-headline { margin: 10px 0 0; font-size: 17px; line-height: 1.75; color: var(--text-pure); }
.rp-headline-sub, .rp-note { margin: 8px 0 0; font-size: 14px; color: var(--text-muted); }
.rp-card-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; margin-top: 10px; }
.rp-checkpoints { display: grid; grid-template-columns: repeat(var(--rp-cols, 4), minmax(0, 1fr)); gap: 12px; margin-top: 10px; text-align: center; }
.rp-checkpoint { display: flex; flex-direction: column; gap: 4px; padding: 12px; border-radius: var(--radius-sm, 12px); border: 1px solid var(--border-box-purple); background: rgba(255, 255, 255, 0.03); }
.rp-checkpoint strong { font-size: 15px; color: var(--neon-cyan); }
.rp-checkpoint span { font-size: 14.5px; color: var(--text-sub); line-height: 1.6; }
.rp-checkpoint.is-accent { border-color: var(--neon-pink); background: rgba(203, 35, 162, 0.15); }
.rp-checkpoint.is-accent strong { color: var(--text-pure); }
.rp-compare { padding: 14px; border-radius: var(--radius-sm, 12px); border: 1px solid var(--border-box-purple); background: rgba(255, 255, 255, 0.03); margin-top: 10px; }
.rp-compare.is-warm { border-color: var(--neon-pink); background: rgba(203, 35, 162, 0.1); }
.rp-compare-label { font-size: 15px; font-weight: 700; color: var(--neon-cyan); }
.rp-compare.is-warm .rp-compare-label { color: var(--pink-ink); }
.rp-compare p { margin: 6px 0 0; font-size: 15.5px; line-height: 1.7; color: var(--text-pure); }
.dash-card.is-tips { border: 1px solid var(--neon-pink); background: linear-gradient(135deg, rgba(203, 35, 162, 0.1) 0%, rgba(12, 5, 40, 0.9) 100%); }
.rp-tips { list-style: none; padding: 0; margin: 10px 0 0; display: flex; flex-direction: column; gap: 10px; }
.rp-tips li { display: flex; gap: 10px; font-size: 16px; color: var(--text-pure); line-height: 1.6; }
.rp-num-dot { color: var(--pink-ink); font-weight: 800; }
.signal-cue.is-locked { opacity: 0.7; }
/* 모바일: 항목 수만큼만 칸을 쓴다(1개면 한 줄 가득, 3~4개면 두 줄) */
@media (max-width: 640px) { .rp-checkpoints { grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); } }

/* 상품 PR 페이지 PART 2 — 리포트가 어떤 모습인지 보여 주는 포스터(실제 결과는 report.html) */
.pr-poster { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin: 8px 0 18px; }
.pr-poster-tile { display: flex; flex-direction: column; gap: 6px; padding: 20px 18px; border-radius: 18px; border: 1px solid var(--border-box-purple); background: linear-gradient(160deg, rgba(203, 35, 162, 0.16), rgba(12, 5, 40, 0.85)); }
.pr-poster-ico { font-size: 30px; }
.pr-poster-tile strong { font-size: 18px; color: var(--text-pure); }
.pr-poster-tile span:last-child { font-size: 14.5px; color: var(--text-sub); line-height: 1.6; }
.pr-poster-cta { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin: 6px 0 22px; }
.pr-poster-cta a { text-decoration: none; }
@media (max-width: 760px) { .pr-poster { grid-template-columns: minmax(0, 1fr); } }
.pr-poster-cta .btn-submit-glow { width: auto; display: inline-flex; align-items: center; padding: 14px 28px; }
.pr-poster-cta .btn-lock-open { display: inline-flex; align-items: center; }

/* ── 칸 나눔(관리자 🧩 페이지 배치의 행 템플릿) — 넓은 화면은 격자, 좁은 화면은 한 줄로 쌓는다 ── */
.rp-row { display: grid; gap: 14px; margin-bottom: 14px; grid-template-columns: var(--rp-row-cols); grid-template-areas: var(--rp-row-areas); align-items: stretch; }
.rp-cell { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.rp-cell > .rp-section { margin: 0; flex: 1; }
/* 같은 행의 카드 높이를 맞출 때 짧은 카드가 비어 보이지 않게: 차트는 남는 높이를 채우고, 결론 카드의 출처 줄은 바닥에 붙인다. */
.rp-cell > .rp-section > .viz-box { flex: 1 1 auto; }
.rp-cell > .rp-section > .rp-headline-sub { margin-top: auto; }
@media (max-width: 720px) {
  .rp-row { grid-template-columns: 1fr; grid-template-areas: none; }
  .rp-cell { grid-area: auto !important; }
}

/* ── 그래프 라이브러리(graph.heal7.com 카탈로그를 우리 데이터로) ── */
.rp-section.is-graph .viz-box { min-height: 240px; }
.rp-section.is-graph .viz-box.is-tall { min-height: 300px; }
.rg-liquids { display: flex; flex-wrap: wrap; justify-content: center; gap: 18px; }
.rg-liquid { display: flex; flex-direction: column; align-items: center; gap: 6px; width: 140px; }
.rg-liquid svg { width: 120px; height: 120px; }
.rg-liquid text { fill: #fff; font-size: 22px; font-weight: 800; }
.rg-liquid span { font-size: 13px; color: var(--text-sub, #d6cbe9); text-align: center; }
.rg-wave { animation: rg-wave 4s linear infinite; }
@keyframes rg-wave { from { transform: translateX(0); } to { transform: translateX(-100px); } }
@media (prefers-reduced-motion: reduce) { .rg-wave { animation: none; } }
.rg-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 10px; }
.rg-tile { display: flex; flex-direction: column; gap: 4px; padding: 14px; border-radius: 14px; border: 1px solid color-mix(in srgb, var(--rg-c) 55%, transparent); background: color-mix(in srgb, var(--rg-c) 12%, transparent); }
.rg-tile b { font-size: 30px; font-weight: 900; color: var(--rg-c); line-height: 1; }
.rg-tile span { font-size: 13px; color: var(--text-sub, #d6cbe9); }
.rg-tile.is-grade b { font-size: 22px; font-weight: 800; }

/* 도식 — graph.heal7 도식 SKU의 배치를 한글 문장이 들어가는 격자로 */
.rg-sch { display: grid; gap: 10px; align-items: stretch; }
.rg-cell { display: flex; flex-direction: column; gap: 6px; padding: 12px 14px; border-radius: 12px; border: 1.5px solid #6b8cff; background: rgba(107, 140, 255, 0.08); min-width: 0; }
.rg-cell strong { font-size: 14px; font-weight: 800; color: var(--text-pure, #fff); line-height: 1.4; }
.rg-cell strong em { font-style: normal; font-size: 12px; padding: 1px 8px; margin-left: 4px; border-radius: 999px; border: 1px solid #e8c069; color: #e8c069; white-space: nowrap; }
.rg-cell p { margin: 0; font-size: 13.5px; line-height: 1.65; color: var(--text-sub, #d6cbe9); overflow-wrap: anywhere; }
.rg-cell.is-locked { border-style: dashed; opacity: 0.8; }
.rg-sch > .rg-cell:nth-of-type(3n+2), .rg-quad > .rg-cell:nth-child(2), .rg-six > .rg-cell:nth-child(2) { border-color: #e8c069; background: rgba(232, 192, 105, 0.08); }
.rg-sch > .rg-cell:nth-of-type(3n), .rg-quad > .rg-cell:nth-child(3) { border-color: #e07a9f; background: rgba(224, 122, 159, 0.08); }
.rg-quad > .rg-cell:nth-child(4), .rg-six > .rg-cell:nth-child(5) { border-color: #6dd2c4; background: rgba(109, 210, 196, 0.08); }
.rg-arrow, .rg-vs { align-self: center; justify-self: center; font-size: 18px; color: #e8c069; font-style: normal; }
.rg-vs { font-size: 13px; font-weight: 900; letter-spacing: 1px; }
.rg-split { grid-template-columns: 1fr auto 1fr; }
.rg-split .is-cool { border-color: #6b8cff; }
.rg-split .is-warm { border-color: #e07a9f; background: rgba(224, 122, 159, 0.08); }
.rg-flow { grid-auto-flow: column; grid-template-columns: 1fr auto 1fr auto 1fr; }
.rg-flow.is-five { grid-template-columns: 1fr auto 1fr auto 1fr auto 1fr auto 1fr; }
.rg-layers { grid-template-columns: 1fr; }
.rg-pyramid { grid-template-columns: 1fr; justify-items: center; }
.rg-pyramid .is-tier0 { width: 56%; border-color: #e8c069; }
.rg-pyramid .is-tier1 { width: 78%; border-color: #6b8cff; }
.rg-pyramid .is-tier2 { width: 100%; border-color: #e07a9f; }
.rg-quad { grid-template-columns: 1fr 1fr; }
.rg-six { grid-template-columns: repeat(3, 1fr); }
.rg-cycle { grid-template-columns: 1fr 1fr; position: relative; }
.rg-cycle-mark { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); width: 40px; height: 40px; display: grid; place-items: center; border-radius: 50%; background: var(--bg-card-inner, #1c1234); border: 1.5px solid #e8c069; color: #e8c069; font-size: 20px; }
.rg-hub { grid-template-columns: 1fr; }
.rg-hub .is-hub { border-color: #e8c069; background: rgba(232, 192, 105, 0.12); text-align: center; }
.rg-hub-spokes { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 10px; }
/* 낮 모드 — 흰 바탕에서 금색·흰 글자가 흐려지지 않게(그래프 원본 색은 밤 바탕 기준) */
html[data-theme="light"] .rg-cell strong em { color: #8a5a00; border-color: #c9962b; }
html[data-theme="light"] .rg-arrow, html[data-theme="light"] .rg-vs { color: #a8741a; }
html[data-theme="light"] .rg-cycle-mark { color: #a8741a; border-color: #c9962b; }
html[data-theme="light"] .rg-tile b { color: color-mix(in srgb, var(--rg-c) 55%, #2d1a3e); }
html[data-theme="light"] .rg-liquid text { fill: #2d1a3e; }
@media (max-width: 720px) {
  .rg-split, .rg-flow, .rg-flow.is-five, .rg-quad, .rg-six, .rg-cycle { grid-template-columns: 1fr; grid-auto-flow: row; }
  .rg-arrow { transform: rotate(90deg); }
  .rg-cycle-mark { position: static; transform: none; justify-self: center; }
  .rg-pyramid .rg-cell { width: 100%; }
}

/* 장 탭 — 모바일에서 5장 이상이면 한 줄 가로 스크롤(글자가 세로로 꺾이지 않게). 4장 이하는 격자 그대로. */
@media (max-width: 640px) {
  .rp-report .chapter-tabs-nav:has(> :nth-child(5)) {
    display: flex; overflow-x: auto; scroll-snap-type: x proximity; scrollbar-width: none; overscroll-behavior-x: contain;
    -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 28px), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 28px), transparent);
  }
  .rp-report .chapter-tabs-nav:has(> :nth-child(5))::-webkit-scrollbar { display: none; }
  .rp-report .chapter-tabs-nav:has(> :nth-child(5))[data-at-end] { -webkit-mask-image: none; mask-image: none; }
  /* 넓은 히트맵 — 옆으로 더 있다는 표시(끝에 닿으면 걷힘) */
  .rp-report .deck-viz-scroll.is-wide:not([data-at-end]) {
    -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 36px), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 36px), transparent);
  }
  .rp-report .chapter-tabs-nav:has(> :nth-child(5)) .chapter-tab-btn {
    flex: 0 0 auto; width: 124px; scroll-snap-align: start; padding: 10px 8px; font-size: 14px;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  }
}
/* 공개 전체 샘플: 사례 선택과 개인 리포트 진입. */
.rpage-sample {
  margin: 0 auto 24px;
  padding: 18px;
  max-width: 1080px;
  border: 1px solid var(--border-box-purple);
  border-radius: 16px;
  background: var(--bg-card);
  color: var(--text-pure);
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}
.rpage-sample[hidden] { display: none; }
.rpage-sample p { flex-basis: 100%; margin: 0; line-height: 1.7; }
.rpage-sample select { max-width: 100%; min-width: 0; padding: 8px; color: var(--text-pure); background: var(--bg-card); border: 1px solid var(--border-box-purple); border-radius: 8px; }
.rpage-sample a { color: var(--neon-cyan); }

/* 계산 원본 콘텐츠: 명식과 월 달력. 좁은 칸에서는 표 내부만 스크롤한다. */
.rp-section.is-native { min-width: 0; }
.rp-native-scroll { width: 100%; max-width: 100%; overflow-x: auto; overscroll-behavior-x: contain; }
.rp-natal-profile + .rp-natal-profile { margin-top: 24px; }
.rp-natal-profile h4, .rp-calendar-month h4 { margin: 14px 0 10px; color: var(--text-pure); font-size: 16px; }
.rp-personality-profile + .rp-personality-profile { margin-top: 24px; }
.rp-personality-profile h4 { margin: 14px 0 10px; color: var(--text-pure); font-size: 16px; }
.rp-personality-readings { display: grid; grid-template-columns: minmax(0, 1fr); gap: 12px; min-width: 0; }
.rp-personality-reading { min-width: 0; padding: 12px 14px; border: 1px solid var(--border-box-purple); border-radius: 12px; background: color-mix(in srgb, var(--text-pure) 3%, transparent); }
.rp-personality-reading h5 { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 8px; margin: 0 0 8px; color: var(--text-pure); font-size: 15px; }
.rp-personality-reading h5 small { color: var(--text-muted); font-size: 12px; font-weight: 500; }
.rp-personality-body { color: var(--text-sub); font-size: 14px; line-height: 1.85; overflow-wrap: anywhere; }
.rp-personality-body p { margin: 0 0 12px; white-space: pre-line; }
.rp-personality-body p:last-child { margin-bottom: 0; }
.rp-personality-status { padding: 3px 7px; border: 1px dashed var(--border-box-purple); border-radius: 999px; color: var(--text-muted); font-size: 11px; font-weight: 600; }
.rp-position-profile { min-width: 0; }
.rp-position-profile + .rp-position-profile { margin-top: 24px; }
.rp-position-profile h4 { margin: 14px 0 10px; color: var(--text-pure); font-size: 16px; }
.rp-position-readings { display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px; min-width: 0; }
.rp-position-reading { min-width: 0; border: 1px solid var(--border-box-purple); border-radius: 12px; background: color-mix(in srgb, var(--text-pure) 3%, transparent); }
.rp-position-reading > summary { display: list-item; min-width: 0; padding: 12px 14px; color: var(--text-pure); font-size: 15px; font-weight: 700; line-height: 1.5; cursor: pointer; overflow-wrap: anywhere; }
.rp-position-reading > summary:focus-visible { outline: 2px solid var(--pink-ink); outline-offset: -3px; border-radius: 12px; }
.rp-position-body { padding: 0 14px 12px; color: var(--text-sub); font-size: 14px; line-height: 1.85; overflow-wrap: anywhere; }
.rp-position-body p { margin: 0 0 12px; white-space: pre-line; }
.rp-position-body p:last-child { margin-bottom: 0; }
.rp-position-more { min-width: 0; margin-top: 12px; border-top: 1px solid color-mix(in srgb, var(--border-box-purple) 65%, transparent); }
.rp-position-more > summary { display: list-item; min-width: 0; padding: 10px 0 6px; color: var(--text-pure); font-size: 13px; font-weight: 700; line-height: 1.5; cursor: pointer; overflow-wrap: anywhere; }
.rp-position-more > summary:focus-visible { outline: 2px solid var(--pink-ink); outline-offset: 2px; border-radius: 4px; }
.rp-position-more-list, .rp-position-extra { min-width: 0; max-width: 100%; }
.rp-position-extra { padding: 4px 0 10px; overflow-wrap: anywhere; }
.rp-position-extra h5 { margin: 4px 0 5px; color: var(--text-pure); font-size: 13px; font-weight: 700; line-height: 1.5; overflow-wrap: anywhere; }
.rp-position-extra-body { min-width: 0; color: var(--text-sub); font-size: 13px; line-height: 1.75; overflow-wrap: anywhere; }
.rp-position-extra-body p { margin: 0 0 9px; white-space: pre-line; }
.rp-position-extra-body p:last-child { margin-bottom: 0; }
.rp-position-reading.is-locked { padding: 8px; }
.rp-position-lock { margin: 0; min-width: 0; flex-wrap: wrap; }
.rp-position-lock .lock-copy { overflow-wrap: anywhere; }
.rp-position-lock .lock-copy strong { font-size: 15px; }
.rp-position-lock .lock-copy span { font-size: 13px; }
.rp-native-notice { padding: 10px 12px; border: 1px dashed var(--border-box-purple); border-radius: 10px; }
.rp-natal-table { width: 100%; min-width: 420px; border-collapse: separate; border-spacing: 4px; table-layout: fixed; color: var(--text-pure); font-size: 13px; text-align: center; }
.rp-natal-table th, .rp-natal-table td { padding: 8px 4px; border-radius: 8px; background: color-mix(in srgb, var(--text-pure) 4%, transparent); overflow-wrap: anywhere; }
.rp-natal-table th { color: var(--text-muted); font-weight: 600; }
.rp-natal-table th:first-child { width: 76px; }
.rp-natal-table td small { display: block; font-size: 12px; }
.rp-natal-glyph { display: block; font-size: 32px; line-height: 1.4; }
.rp-natal-glyph.is-wood { color: #45c99d; }
.rp-natal-glyph.is-fire { color: #f27d92; }
.rp-natal-glyph.is-earth { color: #deb45f; }
.rp-natal-glyph.is-metal { color: #b5bfdd; }
.rp-natal-glyph.is-water { color: #77b8f8; }
.rp-natal-facts { display: flex; flex-wrap: wrap; gap: 8px; padding: 0; margin: 12px 0 0; list-style: none; }
.rp-natal-facts li { padding: 6px 10px; border: 1px solid var(--border-box-purple); border-radius: 12px; color: var(--text-sub); font-size: 12px; line-height: 1.6; }
.rp-calendar-legend { display: flex; flex-wrap: wrap; gap: 8px 16px; margin-top: 12px; color: var(--text-sub); font-size: 12px; }
.rp-calendar-month h4 small { display: block; margin-top: 4px; color: var(--text-muted); font-size: 12px; font-weight: 400; }
.rp-calendar-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 5px; min-width: 560px; }
.rp-calendar-weekday { padding: 8px; color: var(--text-muted); text-align: center; font-size: 13px; }
.rp-calendar-day { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; min-height: 114px; padding: 8px; border: 1px solid var(--border-box-purple); border-radius: 10px; background: color-mix(in srgb, var(--text-pure) 3%, transparent); color: var(--text-sub); cursor: pointer; font: inherit; text-align: left; overflow-wrap: anywhere; }
.rp-calendar-day b { color: var(--text-pure); font-size: 17px; }
.rp-calendar-day span { font-size: 14px; }
.rp-calendar-day small { font-size: 11px; line-height: 1.4; }
.rp-calendar-day .rp-calendar-state { margin-top: auto; color: var(--text-muted); }
.rp-calendar-day.is-pick { border: 2px solid var(--neon-cyan); background: color-mix(in srgb, var(--neon-cyan) 10%, transparent); }
.rp-calendar-day.is-low { border-style: dashed; }
.rp-calendar-day.is-holiday b { color: var(--pink-ink); }
.rp-calendar-day[aria-pressed="true"], .rp-calendar-day:focus-visible { outline: 2px solid var(--pink-ink); outline-offset: -4px; }
.rp-calendar-detail { min-height: 3em; margin: 12px 0 0; font-size: 13px; line-height: 1.8; color: var(--text-sub); }
html[data-theme="light"] .rp-natal-glyph.is-wood { color: #197b52; }
html[data-theme="light"] .rp-natal-glyph.is-fire { color: #b1344c; }
html[data-theme="light"] .rp-natal-glyph.is-earth { color: #85601a; }
html[data-theme="light"] .rp-natal-glyph.is-metal { color: #56607e; }
html[data-theme="light"] .rp-natal-glyph.is-water { color: #23659b; }
/* 좁은 리포트 칸에서도 네 기둥과 한 주의 일곱 칸을 한눈에 본다. 상세는 날짜 선택으로 표시한다. */
.rp-native-scroll { container-type: inline-size; }
@container (max-width: 600px) {
  .rp-natal-table { min-width: 260px; border-spacing: 2px; font-size: 11px; }
  .rp-natal-table th:first-child { width: 48px; }
  .rp-natal-table td, .rp-natal-table th { padding: 6px 2px; }
  .rp-natal-table td small { font-size: 10px; }
  .rp-natal-glyph { font-size: 27px; }
  .rp-calendar-grid { min-width: 260px; gap: 3px; }
  .rp-calendar-day { min-height: 86px; padding: 5px 3px; border-radius: 7px; gap: 3px; }
  .rp-calendar-day b { font-size: 14px; }
  .rp-calendar-day span { font-size: 11px; }
  .rp-calendar-day small { font-size: 10px; }
  .rp-calendar-day .rp-calendar-lunar, .rp-calendar-day .rp-calendar-event { display: none; }
  .rp-calendar-weekday { padding: 6px 2px; font-size: 11px; }
}
/* 택일은 확정된 손없는날 기준의 월 전체 후보. 연락 흐름과 서로 다른 표시를 쓴다. */
.rp-election { margin-top: 14px; padding: 12px; border: 1px solid var(--pink-ink); border-radius: 12px; }
.rp-election h4 { margin: 0; color: var(--text-pure); font-size: 15px; }
.rp-election-dates { display: flex; flex-wrap: wrap; gap: 8px; padding: 0; list-style: none; }
.rp-election-date { display: flex; flex-direction: column; gap: 4px; padding: 8px 10px; border: 1px solid var(--border-box-purple); border-radius: 10px; background: transparent; color: var(--text-pure); font: inherit; font-size: 13px; text-align: left; cursor: pointer; }
.rp-election-date small { color: var(--text-sub); font-size: 11px; }
.rp-election-date:focus-visible { outline: 2px solid var(--pink-ink); }
.rp-election-rules { color: var(--text-sub); font-size: 12px; line-height: 1.8; }
.rp-election-rules summary { cursor: pointer; }
.rp-calendar-day.is-election { box-shadow: inset 0 0 0 1px var(--pink-ink); background: color-mix(in srgb, var(--pink-ink) 8%, transparent); }
.rp-calendar-day .rp-calendar-candidate { color: var(--pink-ink); font-weight: 700; }
