/* 붕붕이: 따뜻한 회색 바탕 + 먹색 결과판 + 주황 강조 (다른 사이트와 색을 섞지 않음) */
:root {
  --ink: #1D1B18; --ink-2: #4B4740; --muted: #6E685F; --line: #E4E0D8; --line-2: #EFECE6;
  --bg: #F6F4EF; --card: #FFFFFF; --accent: #C2410C; --accent-d: #B23A0B; --accent-bg: #FFF1E8;
  --panel: #232220; --panel-2: #2F2D2A; --panel-t: #F3EFE7; --panel-m: #B7AFA3; --hi: #FFB570;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 64px; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: "Pretendard", -apple-system, BlinkMacSystemFont, "Malgun Gothic", sans-serif; font-size: 16px; line-height: 1.72; letter-spacing: -0.2px; word-break: keep-all; overflow-wrap: break-word; }
a { color: var(--accent-d); text-underline-offset: 3px; }
p, li, td, .f-h, .r-sub { text-wrap: pretty; }
h1, h2, h3, th, .f-l { text-wrap: balance; }
.w { max-width: 1080px; margin: 0 auto; padding: 0 20px; }
.w-t { max-width: 760px; }

/* 앱 틀: 폰·태블릿은 상단바 + 하단 탭 바, PC(960px 이상)는 왼쪽 메뉴 */
.top { position: sticky; top: 0; z-index: 20; background: rgba(246, 244, 239, .96); border-bottom: 1px solid var(--line); backdrop-filter: saturate(1.2) blur(6px); }
.top .w { position: relative; display: flex; align-items: center; justify-content: center; height: 52px; }
.top .brand { position: absolute; left: 20px; }
.top .t { margin: 0; font-size: 17px; font-weight: 800; color: var(--ink); letter-spacing: -0.4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: calc(100% - 110px); }
.back { position: absolute; left: 8px; top: 4px; display: grid; place-items: center; width: 44px; height: 44px; border-radius: 12px; color: var(--ink); }
.back svg { width: 26px; height: 26px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.back:active { background: #ECE8E0; }
.brand { display: inline-flex; align-items: center; gap: 8px; color: var(--ink); text-decoration: none; font-weight: 800; font-size: 17px; letter-spacing: -0.5px; white-space: nowrap; }
.brand small { margin-left: 2px; font-size: 12.5px; font-weight: 600; color: var(--muted); letter-spacing: -0.2px; }
.brand img { flex: none; display: block; width: 30px; height: 28px; }
.brand i { display: inline-grid; place-items: center; width: 28px; height: 28px; border-radius: 7px; background: var(--ink); color: var(--hi); font-style: normal; font-size: 14px; font-weight: 900; }
.tabs { position: fixed; left: 0; right: 0; bottom: 0; z-index: 25; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); padding: 0 4px env(safe-area-inset-bottom); background: rgba(255, 255, 255, .97); border-top: 1px solid var(--line); backdrop-filter: blur(8px); transition: transform .2s; }
.tabs a { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; height: 60px; color: var(--muted); font-size: 11.5px; font-weight: 700; text-decoration: none; white-space: nowrap; }
.tabs svg, .side-nav svg { width: 23px; height: 23px; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.tabs a[aria-current] { color: var(--accent); }
body.typing .tabs { transform: translateY(110%); }
body { padding-bottom: calc(60px + env(safe-area-inset-bottom)); }
.side { display: none; }
.crumb { display: none; }
@media (min-width: 960px) {
  html { scroll-padding-top: 20px; }
  body { padding: 0 0 0 236px; }
  .top, .tabs { display: none; }
  .crumb { display: block; }
  .side { position: fixed; left: 0; top: 0; bottom: 0; z-index: 20; display: flex; flex-direction: column; width: 236px; padding: 22px 14px; background: var(--panel); color: var(--panel-t); overflow-y: auto; }
  .side .brand { margin: 0 8px 24px; color: #fff; }
  .side .brand i { background: var(--hi); color: var(--panel); }
  .side .brand small { color: var(--panel-m); }
  .side-nav { display: grid; gap: 2px; }
  .side-nav a { display: flex; align-items: center; gap: 12px; padding: 11px 12px; border-radius: 11px; color: var(--panel-m); font-size: 15.5px; font-weight: 700; text-decoration: none; }
  .side-nav a:hover { background: var(--panel-2); color: #fff; }
  .side-nav a[aria-current] { background: var(--panel-2); color: var(--hi); }
  .side-sub { margin: auto 8px 0; padding-top: 18px; font-size: 13px; line-height: 2; }
  .side-sub a { display: block; color: var(--panel-m); text-decoration: none; }
  .side-sub a:hover { color: #fff; }
  main { padding-top: 26px; }
}

main { padding: 18px 0 56px; }
.crumb { margin: 0; font-size: 13px; color: var(--muted); }
.crumb a { color: var(--muted); text-decoration: none; }
h1 { margin: 6px 0 8px; font-size: 30px; line-height: 1.3; letter-spacing: -1px; }
.lead { margin: 0 0 22px; max-width: 680px; color: var(--ink-2); font-size: 16.5px; }
h2 { margin: 44px 0 12px; font-size: 22px; line-height: 1.4; letter-spacing: -0.6px; }
h3 { margin: 22px 0 6px; font-size: 17.5px; line-height: 1.45; letter-spacing: -0.3px; }
p { margin: 0 0 12px; color: var(--ink-2); }
b { color: var(--ink); }
ul.l, ol.l { margin: 0 0 14px; padding-left: 21px; color: var(--ink-2); }
ul.l li, ol.l li { margin: 5px 0; }

/* 계산기: PC는 입력 | 결과 두 칸, 폰은 한 줄 */
.calc { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 20px; align-items: start; }
.c-form { padding: 22px 22px 8px; border: 1px solid var(--line); border-radius: 16px; background: var(--card); }
.c-res { position: sticky; top: 72px; min-height: 220px; padding: 22px; border-radius: 16px; background: var(--panel); color: var(--panel-t); }
.f { display: block; margin: 0 0 18px; }
fieldset.f { min-width: 0; padding: 0; border: 0; }
fieldset.f legend { padding: 0; }
.f[hidden] { display: none; }
.f-l { display: block; margin: 0 0 7px; font-size: 14.5px; font-weight: 700; color: var(--ink); }
.f-l small { margin-left: 4px; font-weight: 500; color: var(--muted); }
.f-in { position: relative; display: flex; align-items: center; height: 50px; border: 1.5px solid #D6D1C7; border-radius: 11px; background: #fff; transition: border-color .15s; }
.f-in:focus-within { border-color: var(--ink); box-shadow: 0 0 0 3px rgba(29, 27, 24, .08); }
.f-in input, .f-in select { flex: 1; width: 100%; min-width: 0; height: 100%; padding: 0 14px; border: 0; border-radius: 11px; background: transparent; font: inherit; font-size: 18px; font-weight: 600; color: var(--ink); outline: none; font-variant-numeric: tabular-nums; }
.f-in select { appearance: none; -webkit-appearance: none; padding-right: 36px; font-size: 16.5px; cursor: pointer; }
.f-in.sel::after { content: ""; position: absolute; right: 16px; top: 50%; width: 8px; height: 8px; margin-top: -6px; border-right: 2px solid var(--ink-2); border-bottom: 2px solid var(--ink-2); transform: rotate(45deg); pointer-events: none; }
.f-in em { flex: none; padding: 0 14px 0 2px; font-style: normal; font-size: 15px; color: var(--muted); }
.f-h { display: block; margin-top: 6px; font-size: 13px; line-height: 1.55; color: var(--muted); }
.f-2 { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 0 12px; }
.seg { display: flex; flex-wrap: wrap; gap: 6px; margin: 0; padding: 0; border: 0; }
.seg label { position: relative; flex: 1 1 auto; }
.seg.col { flex-direction: column; }
.seg.col span { justify-content: flex-start; padding-left: 16px; }
.seg input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.seg span { display: flex; align-items: center; justify-content: center; min-height: 44px; padding: 8px 12px; border: 1.5px solid #D6D1C7; border-radius: 11px; background: #fff; font-size: 15px; font-weight: 600; line-height: 1.35; text-align: center; color: var(--ink-2); cursor: pointer; transition: .12s; }
.seg input:checked + span { border-color: var(--ink); background: var(--ink); color: #fff; }
.seg input:focus-visible + span { outline: 3px solid rgba(217, 72, 15, .35); outline-offset: 1px; }
.chk { display: flex; align-items: flex-start; gap: 10px; margin: -6px 0 18px; font-size: 15px; color: var(--ink-2); cursor: pointer; }
.chk[hidden] { display: none; }
.chk input { flex: none; width: 20px; height: 20px; margin: 2px 0 0; accent-color: var(--ink); }
.c-go { display: none; }

/* 결과판 */
.r-k { margin: 0 0 2px; font-size: 14px; font-weight: 700; color: var(--panel-m); }
.r-v { margin: 0; font-size: 36px; font-weight: 800; line-height: 1.25; letter-spacing: -1px; color: var(--hi); font-variant-numeric: tabular-nums; }
.r-sub { margin: 4px 0 0; font-size: 14px; color: var(--panel-m); }
.r-empty { margin: 0; padding: 40px 0; color: var(--panel-m); text-align: center; }
.r-tbl { width: 100%; margin: 18px 0 0; border-collapse: collapse; font-size: 15px; font-variant-numeric: tabular-nums; }
.r-tbl th, .r-tbl td { padding: 9px 0; border-top: 1px solid #3B3935; vertical-align: top; }
.r-tbl th { padding-right: 12px; font-weight: 500; text-align: left; color: var(--panel-m); }
.r-tbl td { text-align: right; color: var(--panel-t); }
.r-tbl small { display: block; font-size: 12.5px; color: var(--panel-m); }
.r-tbl tr.tot th, .r-tbl tr.tot td { border-top-color: #6B655C; color: #fff; font-weight: 700; }
.r-tbl tr.tot b { color: #fff; }
.r-note { margin: 16px 0 0; padding: 0 0 0 18px; font-size: 13.5px; line-height: 1.6; color: var(--panel-m); }
.r-note li { margin: 4px 0; }
.r-sched { margin: 14px 0 0; }
.r-sched summary { cursor: pointer; font-size: 14.5px; font-weight: 700; color: var(--hi); }
.r-sched .tbl { max-height: 340px; margin-top: 10px; overflow: auto; }
.r-sched table { font-size: 13px; }
.r-sched th, .r-sched td { padding: 6px 8px; border-bottom: 1px solid #3B3935; background: transparent; color: var(--panel-t); text-align: right; white-space: nowrap; }
.r-sched th { position: sticky; top: 0; background: var(--panel-2); color: var(--panel-m); }
.r-sched td:first-child, .r-sched th:first-child { text-align: center; }
.r-unit { margin: 6px 0 0; font-size: 12.5px; color: var(--panel-m); text-align: right; }
.r-list { margin-top: 14px; font-size: 15px; }
.r-list th, .r-list td { padding: 8px 6px; border-bottom: 1px solid #3B3935; background: transparent; color: var(--panel-t); text-align: right; }
.r-list th { color: var(--panel-m); font-weight: 600; }
.r-list td:first-child, .r-list th:first-child { text-align: left; }
.c-res .tbl { margin: 0; }

/* 폰 하단 바 */
.c-bar { display: none; }

/* 글 */
.art { max-width: 760px; }
.sum { margin: 0 0 6px; padding: 16px 18px; border-left: 4px solid var(--accent); border-radius: 0 12px 12px 0; background: var(--accent-bg); }
.sum p { margin: 0; color: var(--ink); }
.tbl { overflow-x: auto; margin: 10px 0 16px; -webkit-overflow-scrolling: touch; }
table { width: 100%; border-collapse: collapse; font-size: 15px; font-variant-numeric: tabular-nums; }
.art table, .home table { background: var(--card); border: 1px solid var(--line); border-radius: 12px; border-collapse: separate; border-spacing: 0; overflow: hidden; }
.art th, .art td, .home th, .home td { padding: 10px 14px; border-bottom: 1px solid var(--line-2); text-align: left; vertical-align: top; color: var(--ink-2); }
.art thead th, .home thead th { background: #EFEBE3; color: var(--ink); font-size: 14px; font-weight: 700; white-space: nowrap; }
.art tbody tr:last-child td, .home tbody tr:last-child td { border-bottom: 0; }
.art td.n, .art th.n { text-align: right; white-space: nowrap; }
.art td:first-child { color: var(--ink); font-weight: 600; }
.tip { padding: 12px 16px; border: 1px solid var(--line); border-radius: 12px; background: var(--card); font-size: 15px; }
.formula { padding: 12px 16px; border-radius: 12px; background: #EFEBE3; font-size: 15px; color: var(--ink); }
.law { margin: 6px 0 18px; font-size: 13.5px; color: var(--muted); }
.law a { color: var(--muted); }
.faq details { border-bottom: 1px solid var(--line); }
.faq details:first-of-type { border-top: 1px solid var(--line); }
.faq summary { position: relative; padding: 15px 34px 15px 0; font-weight: 700; color: var(--ink); cursor: pointer; list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ""; position: absolute; right: 6px; top: 22px; width: 8px; height: 8px; border-right: 2px solid var(--ink-2); border-bottom: 2px solid var(--ink-2); transform: rotate(45deg); transition: transform .15s; }
.faq details[open] summary::after { transform: rotate(-135deg); top: 26px; }
.faq details p { margin: -4px 0 16px; }
.more { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-top: 10px; }
.more a, .cards a { display: block; padding: 15px 16px; border: 1px solid var(--line); border-radius: 13px; background: var(--card); color: var(--ink); text-decoration: none; transition: border-color .15s; }
.more a:hover, .cards a:hover { border-color: var(--ink); }
.more b, .cards b { display: block; font-size: 16px; }
.more span, .cards span { display: block; margin-top: 2px; font-size: 14px; line-height: 1.55; color: var(--muted); }
.fine { margin-top: 26px; font-size: 13.5px; color: var(--muted); }
.ad-slot:empty { display: none; }
.ad-slot { margin: 28px 0; }

/* 홈 */
.cards { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 12px; margin: 6px 0 8px; }
.cards a { grid-column: span 2; }
.cards a:nth-child(n+4) { grid-column: span 3; }
.cards a { position: relative; padding: 18px 18px 18px; }
.cards .no { display: block; margin: 0 0 10px; font-size: 12.5px; font-weight: 800; letter-spacing: .5px; color: var(--accent); }
.cards b { font-size: 18px; }
.home .art { margin-top: 8px; }

/* 문의 */
.mail { display: inline-block; padding: 12px 16px; border-radius: 11px; background: var(--card); border: 1px solid var(--line); font-weight: 700; color: var(--ink); }

/* 바닥 */
.foot { padding: 28px 0 40px; border-top: 1px solid var(--line); background: #EFEBE3; font-size: 13.5px; color: var(--muted); }
.foot p { margin: 0 0 8px; color: var(--muted); }
.foot a { color: var(--ink-2); }
.foot .nav { line-height: 2; }
.foot .nav a, .nw { white-space: nowrap; }
/* 회사 정보: 폰·좁은 화면은 '항목 | 내용' 두 칸, PC(1240px 이상)는 한 줄 */
.co { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 3px 14px; margin: 4px 0 14px; padding: 14px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); font-size: 13px; line-height: 1.6; }
.co div { display: contents; }
.co dt { color: var(--ink-2); font-weight: 700; }
.co dd { margin: 0; color: var(--muted); }
.co a { color: var(--muted); }
@media (min-width: 1240px) {
  .co { display: flex; flex-wrap: nowrap; gap: 0; font-size: 12.5px; }
  .co div { display: flex; gap: 5px; white-space: nowrap; }
  .co div + div { margin-left: 10px; padding-left: 10px; border-left: 1px solid var(--line); }
}
/* 문의 폼 */
.ask { margin: 8px 0 24px; padding: 22px 22px 18px; border: 1px solid var(--line); border-radius: 16px; background: var(--card); }
.f-in.area { height: auto; align-items: stretch; }
.f-in textarea { flex: 1; min-width: 0; min-height: 150px; padding: 12px 14px; border: 0; border-radius: 11px; background: transparent; font: inherit; font-size: 16px; line-height: 1.6; color: var(--ink); outline: none; resize: vertical; }
.f-in input::placeholder, .f-in textarea::placeholder { color: #9A938A; font-weight: 400; }
.ask .f-in input[type=email] { font-size: 17px; font-weight: 500; }
.honey { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.ask .chk { margin: 0 0 18px; }
.ask .chk small { color: var(--muted); font-size: 13px; }
.send { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; }
.btn { height: 50px; padding: 0 30px; border: 0; border-radius: 12px; background: var(--accent); color: #fff; font: inherit; font-size: 16.5px; font-weight: 800; cursor: pointer; }
.btn:disabled { opacity: .6; cursor: default; }
.ask-msg { margin: 0; font-size: 14.5px; font-weight: 700; color: var(--accent-d); }
@media (max-width: 640px) { .ask { margin: 8px -16px 24px; padding: 18px 16px 16px; border-radius: 0; border-left: 0; border-right: 0; } .btn { width: 100%; } }

@media (max-width: 900px) {
  .calc { grid-template-columns: minmax(0, 1fr); }
  .c-res { position: static; min-height: 0; }
  .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cards a, .cards a:nth-child(n+4) { grid-column: auto; }
  .cards a:last-child { grid-column: span 2; }
}
@media (max-width: 640px) {
  html { scroll-padding-top: 64px; }
  .w { padding: 0 16px; }
  main { padding-top: 12px; }
  h1 { font-size: 25px; }
  .lead { font-size: 15.5px; margin-bottom: 16px; }
  h2 { margin-top: 38px; font-size: 20px; }
  .calc { gap: 14px; }
  .c-form { margin: 0 -16px; padding: 18px 16px 4px; border-radius: 0; border-left: 0; border-right: 0; }
  .c-res { margin: 0 -16px; padding: 20px 16px; border-radius: 0; }
  .r-v { font-size: 32px; }
  .c-go { display: block; width: 100%; height: 50px; margin: 2px 0 18px; border: 0; border-radius: 12px; background: var(--accent); color: #fff; font: inherit; font-size: 16.5px; font-weight: 800; cursor: pointer; }
  .c-bar { position: fixed; left: 0; right: 0; bottom: calc(60px + env(safe-area-inset-bottom)); z-index: 24; display: flex; align-items: center; gap: 10px; padding: 10px 16px; background: var(--panel); color: var(--panel-t); box-shadow: 0 -6px 20px rgba(0,0,0,.18); transition: transform .2s; }
  .c-bar[hidden], body.typing .c-bar, body.res-seen .c-bar { transform: translateY(calc(100% + 60px + env(safe-area-inset-bottom))); }
  .c-bar[hidden] { display: flex; visibility: hidden; }
  .c-bar p { flex: 1; min-width: 0; margin: 0; line-height: 1.3; }
  .c-bar span { display: block; font-size: 12.5px; color: var(--panel-m); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .c-bar b { display: block; font-size: 19px; color: var(--hi); font-variant-numeric: tabular-nums; white-space: nowrap; }
  .c-bar a { flex: none; padding: 9px 14px; border-radius: 10px; background: var(--accent); color: #fff; font-size: 14.5px; font-weight: 800; text-decoration: none; }
  body.has-bar .foot { padding-bottom: 92px; }
  .more { grid-template-columns: minmax(0, 1fr); }
  .cards { grid-template-columns: minmax(0, 1fr); gap: 10px; }
  .cards a:last-child { grid-column: auto; }
  .cards a { display: grid; grid-template-columns: 30px minmax(0, 1fr); column-gap: 8px; padding: 14px 16px; }
  .cards .no { grid-row: span 2; margin: 3px 0 0; }
  .cards b { font-size: 17px; }
  .art th, .art td { padding: 9px 10px; }
  .art thead th { white-space: normal; }
  /* 3칸 이상 표: 폰에서는 줄마다 카드 */
  .tbl.stack { overflow: visible; }
  .art .tbl.stack table { border: 0; background: none; }
  .tbl.stack thead { display: none; }
  .tbl.stack tr { display: block; margin: 0 0 10px; padding: 10px 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--card); }
  .art .tbl.stack td { display: flex; justify-content: space-between; gap: 12px; padding: 4px 0; border: 0; text-align: right; }
  .tbl.stack td::before { content: attr(data-l); flex: 0 1 auto; max-width: 48%; color: var(--muted); font-weight: 500; text-align: left; }
  .art .tbl.stack td.n { white-space: normal; }
  .art .tbl.stack td:first-child { display: block; padding: 0 0 6px; margin-bottom: 4px; border-bottom: 1px solid var(--line-2); font-size: 15.5px; font-weight: 800; text-align: left; }
  .tbl.stack td:first-child::before { content: none; }
  table { font-size: 14.5px; }
}
@media (max-width: 400px) {
  .r-sched .pr { display: none; }
  .r-sched th, .r-sched td { padding: 6px 5px; }
}
@media (max-width: 360px) {
  .art .tbl:not(.stack) th, .art .tbl:not(.stack) td { padding: 8px 6px; font-size: 13.5px; }
  .f-2 { grid-template-columns: minmax(0, 1fr); }
  .seg span { padding: 8px 8px; font-size: 14.5px; }
  .r-v { font-size: 29px; }
}
