/* 절감 검증 상세페이지 전용 스타일 (c6.css 다음에 읽힘) */

/* 고정 머리말 높이만큼 본문을 내린다 */
main { padding-top: 76px; }

/* 상세페이지 머리말은 항상 흰 배경.
   공용 c6.js가 스크롤 위치 0에서 solid 클래스를 떼어내므로 CSS로 못 박는다. */
.header, .header.solid { background: #fff; color: var(--ink); box-shadow: 0 1px 0 var(--line); }
.header:not(.solid) .nav a:hover { color: var(--teal); text-decoration: none; }
.nav a[aria-current="page"] { color: var(--teal); opacity: 1; }

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

/* 서브 히어로 */
.sub-hero { background: #0b1a2b; color: #fff; padding: 72px 0 80px; }
.crumb { font-size: 14px; color: #93a7b6; }
.crumb a:hover { color: var(--teal); }
.crumb span { margin: 0 6px; }
.sub-hero h1 { margin-top: 18px; font-size: 48px; line-height: 1.25; font-weight: 800; letter-spacing: -.03em; }
.sub-lead { margin-top: 20px; max-width: 660px; font-size: 18px; color: #cddde3; }

/* 본문 공통 조각 */
.text-link { display: inline-block; margin-top: 22px; font-weight: 700; color: var(--teal); border-bottom: 2px solid var(--teal-soft); padding-bottom: 2px; }
.text-link:hover { border-bottom-color: var(--teal); }
.mini-head { margin: 56px 0 20px; font-size: 22px; font-weight: 800; letter-spacing: -.02em; }
.mini-head.big { margin-top: 0; font-size: 28px; }
.table-wrap { overflow-x: auto; }

/* 1. 친화법칙 */
.law { display: grid; grid-template-columns: 1.15fr 1fr; gap: 56px; align-items: center; }
.law-chart svg { width: 100%; height: auto; background: var(--soft); border-radius: var(--radius); padding: 12px 8px; }
.law-chart figcaption { margin-top: 12px; font-size: 13px; color: var(--sub); }
.law-chart .grid line { stroke: #dde4ea; stroke-width: 1; }
.law-chart .curve { fill: none; stroke: var(--teal); stroke-width: 3.5; stroke-linejoin: round; stroke-linecap: round; }
.law-chart .mark-line { stroke: #9fb0ba; stroke-width: 1.5; stroke-dasharray: 5 5; }
.law-chart .mark-dot { fill: #fff; stroke: var(--teal); stroke-width: 4; }
.law-chart .mark-text { font-size: 15px; font-weight: 700; fill: var(--ink); }
.law-chart .axis-y text { font-size: 13px; fill: var(--sub); text-anchor: end; }
.law-chart .axis-x text { font-size: 13px; fill: var(--sub); text-anchor: middle; }
.law-chart .axis-label { font-size: 13px; fill: var(--sub); text-anchor: middle; font-weight: 700; }

.law-point { display: inline-flex; align-items: baseline; gap: 12px; flex-wrap: wrap; padding: 18px 24px; border-radius: 16px; background: var(--teal-soft); margin-bottom: 28px; }
.law-point strong { font-size: 24px; font-weight: 800; color: var(--teal-dark); }
.law-point span { font-size: 18px; font-weight: 700; color: var(--ink); }
.law-text h3 { font-size: 26px; font-weight: 800; letter-spacing: -.02em; }
.law-text p { margin-top: 14px; font-size: 17px; color: var(--ink-2); }
.law-text b { color: var(--ink); }

/* 2. 설치 당일 흐름 */
.day-flow { display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px; }
.day-flow li { position: relative; padding: 26px 22px; border-radius: var(--radius); background: #fff; }
.day-flow li:not(:last-child)::after { content: ""; position: absolute; right: -12px; top: 46px; width: 8px; height: 8px; border-top: 2px solid var(--teal); border-right: 2px solid var(--teal); transform: rotate(45deg); }
.day-flow b { color: var(--teal); font-size: 14px; font-weight: 800; }
.day-flow h3 { margin-top: 8px; font-size: 18px; font-weight: 800; }
.day-flow p { margin-top: 8px; font-size: 14px; color: var(--sub); }

.day-notes { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; margin-top: 40px; }
.day-notes div { padding: 26px 28px; border-radius: 18px; border: 1px solid var(--line); background: #fff; }
.day-notes h4 { font-size: 17px; font-weight: 800; }
.day-notes p { margin-top: 10px; font-size: 15px; color: var(--ink-2); }

/* 3. 측정 기준 표 */
.spec-table { width: 100%; border-collapse: collapse; min-width: 640px; }
.spec-table th, .spec-table td { text-align: left; vertical-align: top; padding: 22px 24px; border-top: 1px solid var(--line); }
.spec-table tr:last-child th, .spec-table tr:last-child td { border-bottom: 1px solid var(--line); }
.spec-table th { width: 200px; font-size: 16px; font-weight: 800; background: var(--soft); }
.spec-table td { font-size: 17px; font-weight: 600; }
.cell-note { margin-top: 8px; font-size: 15px; font-weight: 400; color: var(--sub); }
.inline-list { display: grid; gap: 8px; font-size: 16px; font-weight: 500; color: var(--ink-2); }
.inline-list b { color: var(--teal-dark); font-weight: 800; }

/* 4. 조건 보정 */
.warn-card { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.warn-bad, .warn-good { padding: 30px 32px; border-radius: var(--radius); background: #fff; }
.warn-bad { border-left: 4px solid #d6402f; }
.warn-good { border-left: 4px solid var(--teal); }
.warn-tag { display: inline-block; padding: 6px 14px; border-radius: 999px; background: #ffe8e6; color: #b8351f; font-size: 13px; font-weight: 800; }
.warn-tag.ok { background: var(--teal-soft); color: var(--teal-dark); }
.warn-bad p { margin-top: 16px; font-size: 17px; color: var(--ink-2); }
.unit-list { margin-top: 18px; display: grid; gap: 12px; }
.unit-list li { display: flex; align-items: baseline; gap: 14px; flex-wrap: wrap; padding-bottom: 12px; border-bottom: 1px dashed var(--line); }
.unit-list li:last-child { border-bottom: 0; padding-bottom: 0; }
.unit-list b { font-size: 18px; font-weight: 800; color: var(--teal-dark); }
.unit-list span { font-size: 15px; color: var(--sub); }

.rec-table { width: 100%; border-collapse: collapse; background: #fff; }
.rec-table th, .rec-table td { text-align: left; vertical-align: top; padding: 18px 22px; border: 1px solid var(--line); font-size: 16px; }
.rec-table thead th { background: var(--soft); font-weight: 800; font-size: 15px; }
.rec-table tbody th { width: 220px; font-weight: 800; }
.rec-note { margin-top: 16px; font-size: 15px; color: var(--sub); }
.rec-note b { color: var(--ink); }

/* 5. 비교 그래프 */
.chart-card { padding: 32px 36px 28px; border-radius: 28px; background: #0b1a2b; color: #fff; }
.chart-top { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.chart-switch { display: inline-flex; padding: 4px; border-radius: 999px; background: #12263d; }
.chart-switch button { height: 40px; padding: 0 22px; border: 0; border-radius: 999px; background: transparent; color: #93a7b6; font-size: 15px; font-weight: 700; cursor: pointer; }
.chart-switch button.on { background: var(--teal); color: #fff; }
.demo-badge { padding: 7px 14px; border-radius: 999px; background: #3d2a00; color: #ffc94d; font-size: 13px; font-weight: 700; }
.chart-body { margin-top: 24px; }
.chart-read b { display: block; font-size: 26px; font-weight: 800; letter-spacing: -.02em; }
.chart-read span { display: block; margin-top: 6px; font-size: 15px; color: #93a7b6; }
.chart-body svg { width: 100%; height: auto; margin-top: 18px; }
.chart-body .grid line { stroke: #22364f; stroke-width: 1; }
.chart-body .axis-y text { font-size: 13px; fill: #93a7b6; text-anchor: end; }
.chart-body .axis-x text { font-size: 13px; fill: #93a7b6; text-anchor: middle; }
.chart-body .line { fill: none; stroke-width: 3; stroke-linejoin: round; }
.chart-body .line.base { stroke: #7d8fa0; stroke-dasharray: 7 6; }
.chart-body .line.opt { stroke: var(--teal); }
.legend { display: flex; gap: 22px; margin-top: 10px; font-size: 14px; color: #cddde3; }
.legend i { display: inline-block; width: 20px; height: 3px; margin-right: 8px; vertical-align: middle; background: var(--teal); border-radius: 2px; }
.legend i.base { background: #7d8fa0; }
.chart-note { margin-top: 20px; font-size: 13px; color: #7d8fa0; }

/* 6. 지속 관리 (어두운 띠)
   c6.css에는 .section.dark 배경 규칙이 없으므로 여기서 정의한다. */
.section.dark { background: #0b1a2b; color: #fff; }
.section.dark .sec-head h2 { color: #fff; }
.section.dark .sec-head p { color: #cddde3; }
.keep { display: grid; grid-template-columns: 1.05fr 1fr; gap: 56px; align-items: start; }
.keep-text p { margin-top: 18px; font-size: 17px; color: #cddde3; }
.keep-text p:first-child { margin-top: 0; }
.keep-points { display: grid; gap: 14px; }
.keep-points li { padding: 24px 28px; border-radius: 18px; background: #12263d; }
.keep-no { display: inline-block; padding: 5px 13px; border-radius: 999px; background: rgba(10, 165, 160, .22); color: #7fe0da; font-size: 13px; font-weight: 800; }
.keep-points h3 { margin-top: 12px; font-size: 19px; font-weight: 800; color: #fff; }
.keep-points p { margin-top: 8px; font-size: 15px; color: #93a7b6; }

/* 7. 표현 3단계 */
.stage-list { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.stage-list li { padding: 30px 30px 34px; border-radius: var(--radius); background: #fff; border: 1px solid var(--line); }
.stage-no { display: inline-block; padding: 6px 14px; border-radius: 999px; background: var(--teal-soft); color: var(--teal-dark); font-size: 13px; font-weight: 800; }
.stage-list h3 { margin-top: 16px; font-size: 22px; font-weight: 800; }
.stage-list .when { margin-top: 4px; font-size: 14px; font-weight: 700; color: var(--teal); }
.stage-list p:last-child { margin-top: 12px; font-size: 15px; color: var(--ink-2); }

/* 8. 요금 환산 */
.money { display: grid; grid-template-columns: 1.1fr 1fr; gap: 56px; align-items: start; }
.money-text h2 { font-size: 40px; line-height: 1.3; font-weight: 800; letter-spacing: -.025em; }
.money-text p { margin-top: 16px; font-size: 17px; color: var(--ink-2); }
.money-text b { color: var(--ink); }
.money-box { padding: 32px 34px; border-radius: var(--radius); background: var(--soft); }
.money-box h3 { font-size: 20px; font-weight: 800; }
.report-list { margin: 18px 0 16px; display: grid; gap: 10px; }
.report-list li { position: relative; padding-left: 26px; font-size: 16px; font-weight: 600; color: var(--ink-2); }
.report-list li::before { content: "✓"; position: absolute; left: 0; top: 0; color: var(--teal); font-weight: 800; }

/* 9. 관련 페이지 */
.link-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.link-card { display: block; padding: 26px 28px; border-radius: 18px; background: #fff; border: 1px solid var(--line); transition: border-color .15s; }
.link-card:hover { border-color: var(--teal); }
.link-card b { display: block; font-size: 19px; font-weight: 800; }
.link-card span { display: block; margin-top: 6px; font-size: 15px; color: var(--sub); }
.link-card::after { content: "→"; display: inline-block; margin-top: 14px; color: var(--teal); font-weight: 800; }

/* 태블릿 */
@media (max-width: 1080px) {
  .sub-hero h1 { font-size: 40px; }
  .law, .money, .keep { grid-template-columns: 1fr; gap: 40px; }
  .day-flow { grid-template-columns: repeat(3, 1fr); row-gap: 20px; }
  .day-flow li:nth-child(3)::after { display: none; }
  .day-notes, .stage-list, .link-grid { grid-template-columns: 1fr; }
}

/* 좁은 화면 */
@media (max-width: 900px) {
  .warn-card { grid-template-columns: 1fr; }
}

/* 휴대폰 */
@media (max-width: 600px) {
  main { padding-top: 64px; }
  .sub-hero { padding: 48px 0 56px; }
  .sub-hero h1 { font-size: 30px; }
  .sub-hero h1 br, .law-text h3 br, .money-text h2 br, .mini-head br { display: none; }
  .sub-lead { font-size: 16px; }
  .law-text h3 { font-size: 22px; }
  .law-text p, .money-text p, .warn-bad p { font-size: 16px; }
  .law-point { padding: 14px 18px; margin-bottom: 22px; }
  .law-point strong { font-size: 20px; }
  .law-point span { font-size: 16px; }
  .day-flow { grid-template-columns: 1fr; }
  .day-flow li::after { display: none; }
  .day-notes div, .warn-bad, .warn-good, .money-box, .link-card, .keep-points li { padding: 22px 20px; }
  .keep-text p { font-size: 16px; }
  .keep-points h3 { font-size: 18px; }
  .mini-head { margin: 40px 0 16px; font-size: 19px; }
  .mini-head.big { font-size: 24px; }
  /* 휴대폰에서는 표를 옆으로 밀지 않고 위아래로 쌓는다 */
  .spec-table { min-width: 0; display: block; }
  .spec-table tbody, .spec-table tr { display: block; }
  .spec-table th, .spec-table td { display: block; width: auto; padding: 14px 18px; border-top: 0; }
  .spec-table th { border-top: 1px solid var(--line); font-size: 15px; }
  .spec-table tr:last-child td { border-bottom: 1px solid var(--line); }
  .spec-table td { font-size: 16px; }
  .rec-table th, .rec-table td { padding: 14px 16px; font-size: 15px; }
  .rec-table tbody th { width: 110px; }
  .money-text h2 { font-size: 28px; }
  .chart-card { padding: 22px 18px; border-radius: 22px; }
  .chart-switch button { height: 36px; padding: 0 16px; font-size: 14px; }
  .chart-read b { font-size: 20px; }
  .stage-list li { padding: 24px 22px; }
  .stage-list h3 { font-size: 20px; }
}
