/* 태백넷 부동산 검색 공통 스타일 — www.tebek.net / tebeknet.kr 의 어두운 테마와 포인트 색을 따른다. */
:root {
    --bg: #04060e;
    --bg2: #070b17;
    --panel: rgba(120, 170, 255, .045);
    --panel2: rgba(120, 170, 255, .08);
    --line: rgba(130, 175, 255, .14);
    --line2: rgba(130, 175, 255, .28);
    --txt: #e8eefb;
    --sub: #8fa2c0;
    --dim: #5d6f8c;
    --c1: #22d3ee;
    --c2: #8b5cf6;
    --c3: #f472b6;
    --c4: #34d399;
    --grad: linear-gradient(92deg, #22d3ee, #8b5cf6 60%, #f472b6);
    --radius: 12px;
    --maxw: 1100px;
}
* { box-sizing: border-box; }
html { color-scheme: dark; }
body {
    margin: 0;
    background: var(--bg);
    background-image:
        radial-gradient(700px 380px at 15% -5%, rgba(34, 211, 238, .12), transparent 65%),
        radial-gradient(700px 400px at 85% -5%, rgba(139, 92, 246, .13), transparent 65%);
    background-repeat: no-repeat;
    color: var(--txt);
    font-family: 'Noto Sans KR', 'Pretendard', 'Malgun Gothic', -apple-system, sans-serif;
    line-height: 1.7;
    word-break: keep-all;
    overflow-wrap: break-word;
    -webkit-font-smoothing: antialiased;
}
::selection { background: var(--c1); color: #04121f; }
a { color: var(--c1); text-decoration: none; }
a:hover { text-decoration: underline; }
.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }
.wrap.narrow { max-width: 780px; }
main.wrap { padding-top: 28px; padding-bottom: 56px; }

/* 헤더 */
.site-header {
    position: sticky; top: 0; z-index: 100;
    background: rgba(4, 6, 14, .78);
    backdrop-filter: blur(14px) saturate(140%);
    -webkit-backdrop-filter: blur(14px) saturate(140%);
    border-bottom: 1px solid var(--line);
}
.site-header .nav { display: flex; align-items: center; justify-content: space-between; height: 58px; max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }
.brand { display: flex; align-items: center; gap: 11px; color: var(--txt); font-weight: 700; font-size: 21px; letter-spacing: .02em; }
.brand:hover { text-decoration: none; }
.brand img { height: 30px; width: auto; display: block; }
.brand small { font-weight: 400; color: var(--sub); font-size: 12px; margin-left: 2px; }
.site-footer { border-top: 1px solid var(--line); color: var(--dim); font-size: 12.5px; padding: 22px 0 40px; }
.site-footer .wrap { display: flex; flex-wrap: wrap; gap: 6px 18px; justify-content: space-between; }
.site-footer a { color: var(--sub); }

/* 제목·본문 */
h1 { font-size: 1.7rem; line-height: 1.35; margin: .4rem 0 .8rem; font-weight: 800; letter-spacing: -.01em; }
h2 { font-size: 1.3rem; margin: 0 0 .4rem; }
h3 { font-size: 1.02rem; margin: 1.6rem 0 .5rem; color: var(--txt); }
.definition { color: var(--sub); font-size: .88rem; }
.caveat, .trade-note, .map-note { color: var(--dim); font-size: .8rem; margin-top: .8rem; }
.gate-note { color: var(--c3); font-size: .82rem; }
a.back { font-size: .88rem; color: var(--sub); }

/* 칩(필터/정렬) */
.bands { display: flex; gap: .5rem; flex-wrap: wrap; margin: 1rem 0; }
.bands a {
    padding: .32rem .85rem; border: 1px solid var(--line2); border-radius: 999px;
    font-size: .85rem; color: var(--sub); background: var(--panel); transition: color .15s, border-color .15s, background .15s;
}
.bands a:hover { color: var(--txt); border-color: var(--c1); text-decoration: none; }
.bands a.active { background: linear-gradient(92deg, var(--c1), #6ee7f9); color: #04121f; border-color: transparent; font-weight: 700; }

/* 요약 */
.summary {
    background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
    padding: .8rem 1.1rem; margin: 1rem 0; font-size: .92rem; color: var(--txt);
}

/* 표 */
table { width: 100%; border-collapse: collapse; margin-top: 1rem; }
th, td { text-align: left; padding: .6rem .7rem; border-bottom: 1px solid var(--line); font-size: .9rem; }
th { white-space: nowrap; color: var(--sub); font-weight: 500; font-size: .82rem; letter-spacing: .02em; background: var(--panel); }
tbody tr:hover { background: var(--panel); }
td a { font-weight: 500; }
th.chk, td.chk { width: 1.6rem; }
input[type=checkbox] { accent-color: var(--c1); }

/* 비교 바 */
.compare-bar { position: sticky; bottom: 0; background: rgba(4, 6, 14, .88); backdrop-filter: blur(10px); border-top: 1px solid var(--line); padding: .7rem 0; margin-top: 1rem; }
.compare-bar span { font-size: .85rem; color: var(--sub); margin-left: .7rem; }

/* 버튼·입력 */
button {
    font-family: inherit; padding: .55rem 1.2rem; font-size: .92rem; font-weight: 700; cursor: pointer;
    border: 0; border-radius: 8px; color: #04121f; background: linear-gradient(92deg, var(--c1), #6ee7f9);
    transition: filter .15s, transform .15s;
}
button:hover { filter: brightness(1.1); }
button:active { transform: scale(.97); }
button:disabled { background: var(--panel2); color: var(--dim); cursor: not-allowed; filter: none; }
input[type=text], select {
    font-family: inherit; color: var(--txt); background: var(--bg2); border: 1px solid var(--line2);
    border-radius: 8px; padding: .55rem .75rem; font-size: .93rem; outline: none;
}
input[type=text]:focus, select:focus { border-color: var(--c1); box-shadow: 0 0 0 3px rgba(34, 211, 238, .15); }
select option { background: var(--bg2); color: var(--txt); }
input::placeholder { color: var(--dim); }

/* 검색창 */
.search-box { position: relative; margin-bottom: 1.4rem; }
.search-box .row { display: flex; gap: .5rem; flex-wrap: wrap; }
.search-box input[type=text] { flex: 1 1 260px; }
.suggest-list {
    position: absolute; top: calc(100% + 4px); left: 0; right: 0; background: var(--bg2);
    border: 1px solid var(--line2); border-radius: 10px; max-height: 280px; overflow-y: auto; z-index: 20; display: none;
    box-shadow: 0 12px 32px -8px rgba(0, 0, 0, .6);
}
.suggest-list div { padding: .55rem .85rem; font-size: .9rem; cursor: pointer; border-bottom: 1px solid var(--line); }
.suggest-list div:last-child { border-bottom: 0; }
.suggest-list div:hover { background: var(--panel2); }
.suggest-list .type { color: var(--sub); font-size: .78rem; margin-left: .35rem; }

/* 검색 결과 목록 */
ul.results { list-style: none; padding: 0; margin: 0; }
ul.results li { padding: .5rem 0; border-bottom: 1px solid var(--line); font-size: .92rem; }

/* 단지 상세·비교 */
.split { display: flex; gap: 2rem; align-items: flex-start; }
.split > section { flex: 1; min-width: 0; }
table.info { margin: 1rem 0; }
table.info th, table.info td { border-bottom: 1px solid var(--line); background: none; }
table.info th { width: 8rem; vertical-align: top; }
.complex-map { height: 340px; border-radius: var(--radius); margin-top: .6rem; border: 1px solid var(--line); }
table.trades th, table.trades td { padding: .4rem .6rem; }
.leaflet-popup-content { color: #222; }
.station-marker { filter: hue-rotate(150deg) saturate(1.4); }

/* 준비 중 */
.coming { text-align: center; padding: 18vh 0 10vh; }
.coming img { height: 64px; margin: 0 auto 1.2rem; }
.coming h1 { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; display: inline-block; }
.coming p { color: var(--sub); }

@media (max-width: 800px) {
    .split { flex-direction: column; }
    h1 { font-size: 1.4rem; }
    .wrap, .site-header .nav { padding-left: 16px; padding-right: 16px; }
    th, td { padding: .5rem .45rem; }
    main.wrap { overflow-x: auto; }
}
