/* 도면 노트 웹(커뮤니티 공유 페이지). 흰 바탕·얇은 선 위에 브랜드 차콜과 라임. 글 읽기에 맞춘 폭(본문 680 + 옆 300). */
:root {
  --ink: #111518; --ink-2: #3a4247; --muted: #6b7378; --faint: #9aa1a6;
  --line: #e8eaec; --line-2: #dcdfe2; --soft: #f6f7f8; --field: #f1f3f4;
  --charcoal: #202629; --charcoal-2: #2c3438; --lime: #c8f000; --like: #e0245e;
  --font: 'Pretendard Variable', Pretendard, -apple-system, BlinkMacSystemFont, 'Apple SD Gothic Neo', 'Malgun Gothic', system-ui, sans-serif;
  --radius: 14px;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: #fff; color: var(--ink); font-family: var(--font); font-size: 16px; line-height: 1.6; letter-spacing: -0.01em; -webkit-font-smoothing: antialiased; word-break: keep-all; overflow-wrap: anywhere; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; cursor: pointer; }
img { display: block; max-width: 100%; }
svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; flex: none; }
:focus-visible { outline: 2px solid #2563a8; outline-offset: 2px; border-radius: 4px; }

/* ── 버튼 ── */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 40px; padding: 0 16px; border: 0; border-radius: 20px; font-size: 14.5px; font-weight: 700; white-space: nowrap; transition: filter .15s, background .15s; }
.btn.lime { background: var(--lime); color: var(--ink); }
.btn.lime:hover { filter: brightness(1.05); }
.btn.dark { background: var(--charcoal); color: #fff; }
.btn.dark:hover { background: var(--charcoal-2); }
.btn.ghost { background: #fff; color: var(--ink-2); box-shadow: inset 0 0 0 1px var(--line-2); }
.btn.ghost:hover { background: var(--soft); }
.btn.small { height: 36px; padding: 0 14px; font-size: 13.5px; }
.btn.big { height: 50px; padding: 0 24px; border-radius: 25px; font-size: 16px; }

/* ── 머리말 ── */
.top { position: sticky; top: 0; z-index: 20; background: rgba(255, 255, 255, .94); backdrop-filter: saturate(180%) blur(12px); -webkit-backdrop-filter: saturate(180%) blur(12px); border-bottom: 1px solid var(--line); }
.top-in { max-width: 1080px; margin: 0 auto; height: 64px; padding: 0 20px; display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.brand { display: flex; align-items: center; gap: 10px; }
.brand img { border-radius: 9px; }
.brand span { display: flex; flex-direction: column; line-height: 1.15; }
.brand b { font-size: 17px; font-weight: 800; letter-spacing: -0.03em; }
.brand small { font-size: 11.5px; font-weight: 600; color: var(--muted); }
.top-actions { display: flex; align-items: center; gap: 6px; }
.top-link { padding: 8px 12px; border-radius: 8px; font-size: 14.5px; font-weight: 600; color: var(--ink-2); }
.top-link:hover { background: var(--soft); }
.sites { border-top: 1px solid var(--line); }
.sites-in { max-width: 1080px; margin: 0 auto; padding: 0 20px; height: 50px; display: flex; align-items: center; gap: 4px; overflow-x: auto; scrollbar-width: none; }
.sites-in::-webkit-scrollbar { display: none; }
.sites a { flex: none; height: 32px; padding: 0 12px; border-radius: 16px; display: inline-flex; align-items: center; font-size: 14px; font-weight: 600; color: var(--ink-2); }
.sites a:hover { background: var(--soft); }
.sites a[aria-current='page'] { background: var(--charcoal); color: #fff; }
/* 웹에 올리지 않는 게시판(현장 이야기·구인구직): 자물쇠와 함께 옅게, 누르면 앱을 연다 */
.sites a.locked { gap: 4px; color: var(--faint); }
.sites a.locked svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.sites-group { flex: none; margin: 0 2px 0 12px; padding-left: 12px; border-left: 1px solid var(--line-2); font-size: 12px; font-weight: 700; color: var(--faint); }

/* ── 본문 두 단 ── */
.wrap { max-width: 1080px; margin: 0 auto; padding: 28px 20px 64px; }
.cols { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 40px; align-items: start; }
.side { position: sticky; top: 140px; display: flex; flex-direction: column; gap: 16px; }
@media (max-width: 960px) { .cols { grid-template-columns: minmax(0, 1fr); gap: 28px; } .side { position: static; } }

.intro { padding: 4px 0 8px; }
.intro h1 { margin: 0 0 8px; font-size: 28px; line-height: 1.3; font-weight: 800; letter-spacing: -0.03em; }
.intro p { margin: 0; color: var(--muted); font-size: 15.5px; }
.block { margin-top: 32px; }
.block-title { margin: 0 0 12px; font-size: 19px; font-weight: 800; letter-spacing: -0.02em; display: flex; align-items: baseline; gap: 8px; }
.block-title small { font-size: 13px; font-weight: 600; color: var(--faint); }
.eyebrow { margin: 0 0 4px; font-size: 13px; font-weight: 700; color: var(--muted); }

/* ── 글 목록 ── */
.list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--ink); }
.list li { border-bottom: 1px solid var(--line); }
.item { display: flex; gap: 18px; align-items: center; padding: 18px 2px; }
.item:hover .item-title { text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.item-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.item-title { font-size: 17px; font-weight: 700; line-height: 1.45; letter-spacing: -0.02em; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; }
.item-excerpt { font-size: 14.5px; color: var(--muted); display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 1; overflow: hidden; }
.item-meta { margin-top: 4px; display: flex; flex-wrap: wrap; align-items: center; gap: 4px 12px; font-size: 13px; color: var(--faint); }
.react { display: inline-flex; align-items: center; gap: 4px; }
.react svg { width: 15px; height: 15px; }
.item-thumb { position: relative; flex: none; width: 92px; height: 92px; border-radius: 12px; overflow: hidden; background: var(--soft); box-shadow: inset 0 0 0 1px rgba(17, 21, 24, .06); }
.item-thumb img { width: 100%; height: 100%; object-fit: cover; }
.item-thumb em { position: absolute; right: 5px; bottom: 5px; padding: 1px 6px; border-radius: 6px; background: rgba(17, 21, 24, .65); color: #fff; font-size: 11px; font-style: normal; font-weight: 700; }
.list-empty { margin: 0; padding: 28px 0; border-top: 1px solid var(--line); color: var(--muted); font-size: 14.5px; }
.more-link { display: flex; align-items: center; justify-content: center; margin-top: 16px; height: 46px; border-radius: 12px; background: var(--soft); font-size: 14.5px; font-weight: 700; color: var(--ink-2); }
.more-link:hover { background: var(--field); }

/* ── 옆 칸 ── */
.side-card { padding: 18px 18px 14px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.side-card h2 { margin: 0 0 8px; font-size: 15.5px; font-weight: 800; }
.side-group { margin: 12px 0 4px; font-size: 12px; font-weight: 700; color: var(--faint); }
.boards { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 2px 8px; }
.boards a { display: flex; flex-direction: column; padding: 6px 8px; margin: 0 -8px; border-radius: 8px; font-size: 14.5px; font-weight: 700; line-height: 1.35; }
.boards a span { font-size: 11.5px; font-weight: 500; color: var(--faint); }
.boards a:hover, .boards a[aria-current='page'] { background: var(--soft); }
.titles { list-style: none; margin: 0; padding: 0; }
.titles li { display: flex; align-items: flex-start; gap: 8px; padding: 7px 0; border-top: 1px solid var(--line); font-size: 14px; }
.titles li:first-child { border-top: 0; }
.titles a { flex: 1; min-width: 0; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; line-height: 1.45; }
.titles a:hover { text-decoration: underline; text-underline-offset: 3px; }
.titles span { flex: none; display: inline-flex; align-items: center; gap: 3px; margin-top: 2px; font-size: 12px; color: var(--faint); }
.titles span svg { width: 13px; height: 13px; }

.app-card { padding: 22px 20px 18px; border-radius: var(--radius); background: var(--charcoal); color: #c9cfd2; display: flex; flex-direction: column; align-items: flex-start; gap: 8px; }
.app-card img { border-radius: 12px; box-shadow: 0 0 0 1px #363e43; }
.app-card strong { margin-top: 4px; color: #fff; font-size: 17px; font-weight: 800; }
.app-card p { margin: 0 0 6px; font-size: 13.5px; line-height: 1.6; }
.app-card .btn { width: 100%; height: 44px; border-radius: 12px; }
.app-card-more { align-self: center; margin-top: 2px; font-size: 13px; color: #9aa3a8; }
.app-card-more:hover { color: #fff; }

/* ── 현장 게시판 머리 ── */
.board-head h1 { margin: 0; font-size: 30px; font-weight: 800; letter-spacing: -0.03em; line-height: 1.25; }
.seg { display: inline-flex; margin-top: 16px; padding: 3px; border-radius: 12px; background: var(--field); }
.seg a { height: 34px; padding: 0 16px; border-radius: 9px; display: inline-flex; align-items: center; font-size: 14px; font-weight: 700; color: var(--muted); }
.seg a[aria-current='page'] { background: #fff; color: var(--ink); box-shadow: 0 1px 3px rgba(17, 21, 24, .12); }

/* ── 글 보기 ── */
.crumbs { display: flex; align-items: center; gap: 2px; flex-wrap: wrap; font-size: 13.5px; font-weight: 600; color: var(--muted); }
.crumbs a:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }
.crumbs svg { width: 14px; height: 14px; color: var(--faint); }
.crumbs span { color: var(--ink-2); }
.post { margin-top: 18px; padding-bottom: 20px; border-bottom: 1px solid var(--line); }
.author { display: flex; align-items: center; gap: 12px; }
.author div { display: flex; flex-direction: column; line-height: 1.35; }
.author b { font-size: 15.5px; font-weight: 700; }
.author span { font-size: 13px; color: var(--muted); }
.avatar { flex: none; width: var(--size); height: var(--size); border-radius: 50%; display: grid; place-items: center; background: hsl(var(--hue) 55% 91%); color: hsl(var(--hue) 40% 32%); font-size: calc(var(--size) * .42); font-weight: 800; }
.post-title { margin: 20px 0 14px; font-size: 26px; line-height: 1.4; font-weight: 800; letter-spacing: -0.03em; }
.post-body { white-space: pre-wrap; font-size: 17px; line-height: 1.75; color: #1f2529; }
.photos { margin-top: 20px; display: grid; gap: 6px; border-radius: var(--radius); overflow: hidden; }
.photos.n1 { grid-template-columns: 1fr; }
.photos.n2, .photos.n4 { grid-template-columns: 1fr 1fr; }
.photos.n3 { grid-template-columns: 2fr 1fr; grid-template-rows: 1fr 1fr; }
.photos.n3 .photo:first-child { grid-row: span 2; }
.photo { display: block; background: var(--soft); min-height: 120px; }
.photo img { width: 100%; height: 100%; object-fit: cover; }
.photos.n1 .photo img { max-height: 560px; object-fit: contain; background: var(--soft); }
.photos.n2 .photo, .photos.n4 .photo { aspect-ratio: 1; }
.post-actions { margin-top: 22px; display: flex; align-items: center; gap: 16px; flex-wrap: wrap; font-size: 14px; font-weight: 600; color: var(--ink-2); }
.post-actions .react svg { width: 18px; height: 18px; }
.post-actions .react:first-child svg { color: var(--like); }
.post-actions-right { margin-left: auto; display: flex; gap: 8px; }
.post-actions-right svg { width: 16px; height: 16px; }

.comments-block .block-title { margin-bottom: 14px; }
.comment-box { display: flex; align-items: center; gap: 10px; padding: 14px 16px; border: 1px solid var(--line-2); border-radius: 12px; color: var(--faint); font-size: 14.5px; }
.comment-box span { flex: 1; }
.comment-box b { font-size: 13.5px; color: var(--ink); }
.comment-box:hover { border-color: var(--ink-2); }
.comments, .replies { list-style: none; margin: 0; padding: 0; }
.comments { margin-top: 8px; }
.comment { display: flex; gap: 12px; padding: 16px 0; border-bottom: 1px solid var(--line); }
.comments > .comment:last-child { border-bottom: 0; }
.comment-main { flex: 1; min-width: 0; }
.comment-head { display: flex; align-items: baseline; gap: 8px; }
.comment-head b { font-size: 14.5px; font-weight: 700; }
.comment-head time { font-size: 12.5px; color: var(--faint); }
.comment-body { margin: 4px 0 0; white-space: pre-wrap; font-size: 15.5px; line-height: 1.65; }
.comment-like { margin-top: 6px; display: inline-flex; align-items: center; gap: 4px; font-size: 12.5px; color: var(--faint); }
.comment-like svg { width: 14px; height: 14px; color: var(--like); }
.replies { margin-top: 6px; }
.comment.reply { padding: 12px 0 4px; border-bottom: 0; }
.comment.deleted { display: block; color: var(--faint); font-size: 14px; }
.comment.deleted > p { margin: 0; }

/* ── 앱 안내 띠 ── */
.app-banner { margin-top: 40px; padding: 32px; border-radius: 20px; background: var(--charcoal); color: #c9cfd2; display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap; position: relative; overflow: hidden; }
.app-banner::before { content: ''; position: absolute; inset: 0; background-image: linear-gradient(rgba(200, 240, 0, .06) 1px, transparent 1px), linear-gradient(90deg, rgba(200, 240, 0, .06) 1px, transparent 1px); background-size: 32px 32px; pointer-events: none; }
.app-banner > * { position: relative; }
.app-banner .eyebrow { color: var(--lime); }
.app-banner h2 { margin: 0 0 6px; color: #fff; font-size: 22px; font-weight: 800; letter-spacing: -0.03em; }
.app-banner p { margin: 0; max-width: 420px; font-size: 14.5px; }
.app-banner-actions { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; }
.stores { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; color: #9aa3a8; }
.stores span { padding: 3px 9px; border-radius: 6px; box-shadow: inset 0 0 0 1px #3d464b; }
.stores em { font-style: normal; font-weight: 700; color: var(--lime); }

/* ── 앱 소개 ── */
.hero { padding: 40px 0 8px; display: flex; flex-direction: column; align-items: center; text-align: center; gap: 14px; }
.hero img { border-radius: 20px; box-shadow: 0 12px 32px rgba(17, 21, 24, .18); }
.hero h1 { margin: 10px 0 0; font-size: 38px; line-height: 1.3; font-weight: 800; letter-spacing: -0.04em; }
.hero p { margin: 0; color: var(--muted); font-size: 17px; }
.hero-actions { margin-top: 10px; display: flex; flex-direction: column; align-items: center; gap: 12px; }
.hero-actions .stores { color: var(--muted); }
.hero-actions .stores span { box-shadow: inset 0 0 0 1px var(--line-2); }
.hero-actions .stores em { color: var(--ink); background: var(--lime); padding: 3px 8px; border-radius: 6px; }
.features { margin: 44px 0 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 14px; }
.features article { padding: 22px; border: 1px solid var(--line); border-radius: var(--radius); }
.feature-no { font-size: 13px; font-weight: 800; color: var(--faint); }
.features h2 { margin: 6px 0 6px; font-size: 18px; font-weight: 800; }
.features p { margin: 0; font-size: 14.5px; color: var(--muted); line-height: 1.65; }
.hero-foot { margin-top: 32px; display: flex; justify-content: center; }

/* ── 없는 글·오류 ── */
.gone { padding: 80px 0; display: flex; flex-direction: column; align-items: center; text-align: center; gap: 10px; }
.gone h1 { margin: 0; font-size: 24px; font-weight: 800; }
.gone p { margin: 0 0 12px; color: var(--muted); }

/* ── 바닥글 ── */
.foot { border-top: 1px solid var(--line); background: var(--soft); }
.foot-in { max-width: 1080px; margin: 0 auto; padding: 28px 20px 40px; display: flex; flex-direction: column; gap: 10px; font-size: 13px; color: var(--muted); }
.foot-brand { display: flex; align-items: center; gap: 10px; }
.foot-brand img { border-radius: 7px; }
.foot-brand b { color: var(--ink); margin-right: 6px; }
.foot nav { display: flex; gap: 16px; font-weight: 600; color: var(--ink-2); }
.foot p { margin: 0; }

/* ── 폰: 아래에 붙는 앱 띠 ── */
.sticky-app { display: none; }
@media (max-width: 760px) {
  .top-in { height: 58px; }
  .top-link { display: none; }
  .wrap { padding: 20px 16px 120px; }
  .intro h1 { font-size: 23px; }
  .post-title { font-size: 22px; }
  .post-body { font-size: 16.5px; }
  .item { gap: 14px; padding: 16px 0; }
  .item-thumb { width: 76px; height: 76px; }
  .app-banner { padding: 24px 20px; }
  .post-actions-right { margin-left: 0; width: 100%; }
  .post-actions-right .btn { flex: 1; }
  .board-head h1 { font-size: 24px; }
  .hero h1 { font-size: 28px; }
  .sticky-app { position: fixed; z-index: 30; left: 12px; right: 12px; bottom: calc(12px + env(safe-area-inset-bottom, 0px)); display: flex; align-items: center; gap: 10px; padding: 10px 10px 10px 12px; border-radius: 16px; background: var(--charcoal); color: #c9cfd2; font-size: 13.5px; box-shadow: 0 10px 30px rgba(0, 0, 0, .25); }
  .sticky-app img { border-radius: 9px; }
  .sticky-app span { flex: 1; min-width: 0; line-height: 1.35; }
  .sticky-app b { color: #fff; }
  .sticky-app .btn { height: 38px; padding: 0 14px; }
  .sticky-close { width: 28px; height: 28px; border: 0; background: none; color: #8f979b; font-size: 20px; line-height: 1; }
  .sticky-app.gone { display: none; }
}

/* ── 앱 안내 창·알림 ── */
.sheet-wrap { position: fixed; inset: 0; z-index: 50; display: grid; place-items: center; padding: 20px; background: rgba(17, 21, 24, .45); }
.sheet-wrap[hidden] { display: none; }
.sheet { width: min(400px, 100%); padding: 28px 24px 20px; border-radius: 20px; background: #fff; display: flex; flex-direction: column; align-items: center; text-align: center; gap: 8px; box-shadow: 0 24px 60px rgba(0, 0, 0, .3); }
.sheet img { border-radius: 14px; }
.sheet h2 { margin: 8px 0 0; font-size: 20px; font-weight: 800; }
.sheet-text { margin: 0; font-size: 14.5px; color: var(--muted); }
.sheet-actions { margin-top: 12px; width: 100%; display: flex; flex-direction: column; gap: 8px; }
.sheet-actions .btn { width: 100%; }
.toast { position: fixed; z-index: 60; left: 50%; bottom: 96px; transform: translateX(-50%); padding: 12px 18px; border-radius: 12px; background: var(--ink); color: #fff; font-size: 14px; box-shadow: 0 10px 30px rgba(0, 0, 0, .2); }
.toast[hidden] { display: none; }
.lightbox { position: fixed; inset: 0; z-index: 70; display: grid; place-items: center; padding: 20px; background: rgba(0, 0, 0, .9); cursor: zoom-out; }
.lightbox img { max-width: 100%; max-height: 100%; object-fit: contain; border-radius: 6px; }
@media (prefers-reduced-motion: no-preference) { .toast, .sheet { animation: rise .18s ease-out; } }
@keyframes rise { from { opacity: 0; transform: translate(-50%, 8px); } }
.sheet { animation-name: pop; }
@keyframes pop { from { opacity: 0; transform: scale(.97); } }
