/* NVP24 기사 상세 — design/nvp24-view.html <style> 이식 (시안 전환 바 제외 + 실서비스 추가분). portal-news · portal-column 상세에서 BoardController 가 붙인다 */

.layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 312px;
  gap: 40px;
  margin-top: 28px;
  align-items: start;
}
.crumb {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--text-3);
}
.crumb a:hover {
  color: var(--brand);
}
.crumb svg.lucide {
  width: 13px;
  height: 13px;
}

/* ── 기사 머리 ── */
.art-h {
  padding: 16px 0 20px;
  border-bottom: 1px solid var(--line);
}
.art-h .tags {
  display: flex;
  gap: 6px;
  margin-bottom: 12px;
}
.art-h h1 {
  font-size: clamp(24px, 2.8vw, 34px);
  font-weight: 900;
  letter-spacing: -0.045em;
  line-height: 1.32;
}
.art-h .deck {
  margin-top: 12px;
  padding-left: 14px;
  border-left: 3px solid var(--brand);
  color: var(--text-2);
  font-size: 16px;
  line-height: 1.6;
  font-weight: 500;
}
.byline {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 20px;
  flex-wrap: wrap;
}
.byline .pf {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: #fff;
  font-weight: 800;
  background: #1e3a8a;
  flex: none;
}
.byline .who b {
  display: block;
  font-size: 14px;
}
.byline .who .meta {
  margin-top: 2px;
}
.tools {
  margin-left: auto;
  display: flex;
  gap: 4px;
}
.tools button {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  border: 1px solid var(--line);
  display: grid;
  place-items: center;
  color: var(--text-2);
  background: var(--surface);
}
.tools button:hover {
  border-color: var(--brand);
  color: var(--brand);
}
.tools svg.lucide {
  width: 16px;
  height: 16px;
}

/* ── 본문 ── */
.body {
  padding: 28px 0 8px;
  font-size: var(--fs, 17px);
  line-height: 1.85;
  color: var(--text);
  letter-spacing: -0.015em;
}
.body p {
  margin-bottom: 1.25em;
}
.body h3 {
  font-size: 1.15em;
  font-weight: 800;
  margin: 1.8em 0 0.7em;
  letter-spacing: -0.03em;
}
.body figure {
  margin: 0 0 1.6em;
}
.body figure .th {
  aspect-ratio: 16 / 9;
  border-radius: 12px;
}
.body figure .th svg.lucide {
  max-width: 110px;
  max-height: 110px;
}
.body figcaption {
  font-size: 13px;
  color: var(--text-3);
  margin-top: 8px;
  line-height: 1.5;
}
.body blockquote {
  margin: 1.6em 0;
  padding: 18px 22px;
  background: var(--surface-2);
  border-radius: 12px;
  font-weight: 600;
  color: var(--text-2);
  position: relative;
}
.body .fact {
  margin: 1.6em 0;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 18px 20px;
  background: var(--surface);
  font-size: 15px;
  line-height: 1.7;
}
.body .fact b {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--brand-ink);
  margin-bottom: 6px;
}
.body .fact b svg.lucide {
  width: 16px;
  height: 16px;
}
.body .fact ul {
  padding-left: 18px;
  list-style: disc;
}

/* 수집 기사 전용 */
.src-card {
  margin: 4px 0 24px;
  border: 1px solid var(--line);
  border-radius: 14px;
  overflow: hidden;
  background: var(--surface);
}
.src-card .top {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  background: var(--surface-2);
  font-size: 13px;
  color: var(--text-2);
}
.src-card .top .fav {
  width: 24px;
  height: 24px;
  border-radius: 6px;
  display: grid;
  place-items: center;
  font-weight: 900;
  color: #fff;
  font-size: 11px;
  background: #be123c;
}
.src-card .top b {
  color: var(--text);
}
.src-card .top .auto {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: var(--mint);
  font-weight: 700;
  font-size: 12px;
}
.src-card .top .auto svg.lucide {
  width: 13px;
  height: 13px;
}
.src-card .in {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 18px;
  padding: 16px;
}
.src-card .th {
  aspect-ratio: 16 / 10;
}
.src-card .in h4 {
  font-size: 15px;
  margin-bottom: 6px;
}
.src-card .in p {
  font-size: 14px;
  color: var(--text-2);
  line-height: 1.6;
}
.src-card .in .url {
  font-size: 12px;
  color: var(--text-3);
  margin-top: 8px;
  word-break: break-all;
}
.summary {
  margin-bottom: 20px;
  border-radius: 14px;
  padding: 20px 22px;
  background: var(--brand-soft);
}
.summary h3 {
  margin: 0 0 10px;
  font-size: 15px;
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--brand-ink);
}
.summary h3 svg.lucide {
  width: 17px;
  height: 17px;
}
.summary h3 small {
  margin-left: auto;
  font-size: 11.5px;
  color: var(--text-3);
  font-weight: 600;
}
.summary ol {
  padding-left: 20px;
  font-size: 15.5px;
  line-height: 1.75;
}
.summary ol li {
  margin-bottom: 4px;
}
.go-src {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 18px 20px;
  border-radius: 14px;
  border: 1px solid var(--brand);
  margin-bottom: 18px;
}
.go-src p {
  font-size: 14px;
  color: var(--text-2);
  line-height: 1.55;
}
.go-src .btn {
  margin-left: auto;
  flex: none;
}
.notice {
  font-size: 12.5px;
  color: var(--text-3);
  line-height: 1.6;
  display: flex;
  gap: 6px;
}
.notice svg.lucide {
  width: 14px;
  height: 14px;
  margin-top: 3px;
}
/* 공공저작물 전문 게재 (정부 보도자료) — 본문 아래 출처 상자 */
.body img {
  max-width: 100%;
  height: auto;
}
.body table {
  width: 100%;
  border-collapse: collapse;
  margin: 0 0 1.4em;
  font-size: 0.9em;
}
.body td,
.body th {
  border: 1px solid var(--line);
  padding: 6px 8px;
  vertical-align: top;
}
/* 에디터 표(칸 합치기 확장)는 칸 안 글을 문단으로 저장한다 — 칸 안 문단 여백은 없앤다 */
.body td p,
.body th p {
  margin: 0;
}
.ft-src {
  margin: 8px 0 18px;
  padding: 16px 20px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: var(--surface-2);
  font-size: 14px;
  color: var(--text-2);
  line-height: 1.6;
}
.ft-src b {
  color: var(--text);
}
.ft-src a {
  color: var(--brand);
  font-weight: 700;
  white-space: nowrap;
}
.ft-src .lic {
  display: block;
  margin-top: 4px;
  font-size: 12.5px;
  color: var(--text-3);
}

/* ── 기사 꼬리 ── */
.hash {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  padding: 18px 0;
}
.hash a {
  height: 32px;
  padding: 0 14px;
  display: inline-flex;
  align-items: center;
  border-radius: 99px;
  background: var(--surface-2);
  font-size: 13px;
  font-weight: 600;
  color: var(--text-2);
}
.hash a:hover {
  background: var(--brand-soft);
  color: var(--brand-ink);
}
.react {
  display: flex;
  justify-content: center;
  gap: 10px;
  padding: 22px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.react button {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  min-width: 76px;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid var(--line);
  font-size: 12.5px;
  color: var(--text-2);
  background: var(--surface);
}
.react button:hover,
.react button.on {
  border-color: var(--brand);
  color: var(--brand);
  background: var(--brand-soft);
}
.react button b {
  font-size: 13px;
}
.reporter {
  display: flex;
  gap: 16px;
  align-items: center;
  padding: 20px;
  margin-top: 24px;
}
.reporter .pf {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: #fff;
  font-weight: 800;
  font-size: 20px;
  background: #1e3a8a;
  flex: none;
}
.reporter b {
  font-size: 16px;
}
.reporter p {
  font-size: 13px;
  color: var(--text-2);
  margin-top: 2px;
}
.reporter .btn {
  margin-left: auto;
}
.copy {
  font-size: 12.5px;
  color: var(--text-3);
  margin-top: 14px;
}

.pn {
  margin-top: 28px;
  border-top: 2px solid var(--text);
}
.pn a {
  display: grid;
  grid-template-columns: 74px minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  padding: 14px 6px;
  border-bottom: 1px solid var(--line);
  font-size: 14.5px;
}
.pn a span:first-child {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 13px;
  font-weight: 700;
  color: var(--text-3);
}
.pn a span:first-child svg.lucide {
  width: 15px;
  height: 15px;
}
.pn a:hover b {
  color: var(--brand);
}
.pn a b {
  font-weight: 600;
}
.pn a small {
  font-size: 12px;
  color: var(--text-3);
}

.related {
  margin-top: 40px;
}
.rgrid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}
.rgrid a .th {
  aspect-ratio: 16 / 10;
  margin-bottom: 10px;
}
.rgrid a .th svg.lucide {
  width: 30%;
}
.rgrid a b {
  font-size: 14.5px;
  line-height: 1.45;
  letter-spacing: -0.02em;
}
.rgrid a:hover b {
  color: var(--brand);
}
.rgrid a .meta {
  margin-top: 6px;
}

/* 댓글 */
.cmt {
  margin-top: 40px;
}
.cmt .sec-h h2 b {
  color: var(--brand);
}
.cmt-form {
  padding: 14px;
}
.cmt-form textarea {
  width: 100%;
  min-height: 84px;
  border: 0;
  outline: 0;
  resize: vertical;
  background: none;
  font: inherit;
  font-size: 14px;
  color: var(--text);
}
.cmt-form .row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid var(--line);
  padding-top: 10px;
  font-size: 12.5px;
  color: var(--text-3);
}
.cmt-sort {
  display: flex;
  gap: 12px;
  margin: 18px 0 4px;
  font-size: 13px;
}
.cmt-sort button {
  color: var(--text-3);
  font-weight: 600;
}
.cmt-sort button.on {
  color: var(--text);
  font-weight: 800;
}
.c {
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr);
  gap: 12px;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}
.c .av {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: #fff;
  font-weight: 800;
  font-size: 13px;
}
.c .hd {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
}
.c .hd b {
  font-size: 13.5px;
}
.c .hd .lv {
  font-size: 11px;
  font-weight: 800;
  color: var(--brand-ink);
  background: var(--brand-soft);
  padding: 1px 6px;
  border-radius: 4px;
}
.c .hd time {
  color: var(--text-3);
  font-size: 12px;
}
.c p {
  font-size: 14.5px;
  margin: 6px 0 8px;
  line-height: 1.6;
}
.c .ft {
  display: flex;
  gap: 14px;
  font-size: 12.5px;
  color: var(--text-3);
}
.c .ft button {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: var(--text-3);
  font-size: 12.5px;
}
.c .ft button:hover {
  color: var(--brand);
}
.c .ft svg.lucide {
  width: 14px;
  height: 14px;
}
.c.reply {
  margin-left: 48px;
}
.cmt .more-btn {
  width: 100%;
  height: 46px;
  margin-top: 16px;
  border: 1px solid var(--line);
  border-radius: 10px;
  font-size: 14px;
  font-weight: 700;
  color: var(--text-2);
  background: var(--surface);
}

/* 우측 */
.aside {
  display: flex;
  flex-direction: column;
  gap: 20px;
  position: sticky;
  top: 74px;
}
.aside > .card {
  padding: 18px;
}
.aside .tabs {
  margin: 0 -4px 6px;
}
.mini a {
  display: grid;
  grid-template-columns: 84px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 10px 0;
  border-top: 1px solid var(--line);
}
.mini a:first-child {
  border-top: 0;
  padding-top: 0;
}
.mini .th {
  aspect-ratio: 16 / 11;
  border-radius: 6px;
}
.mini .th svg.lucide {
  width: 22px;
  height: 22px;
}
.mini b {
  font-size: 13.5px;
  font-weight: 600;
  line-height: 1.45;
}
.mini a:hover b {
  color: var(--brand);
}
.ad {
  border-radius: var(--radius);
  border: 1px dashed var(--line-2);
  height: 250px;
  display: grid;
  place-items: center;
  color: var(--text-3);
  font-size: 12px;
  background: var(--surface);
}

/* 읽기 진행바 */
.progress {
  position: fixed;
  left: 0;
  top: 0;
  height: 3px;
  background: var(--brand);
  width: 0;
  z-index: 50;
}

@media (max-width: 1080px) {
  .layout {
    grid-template-columns: minmax(0, 1fr);
  }
  .aside {
    position: static;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .aside .ad {
    display: none;
  }
}
@media (max-width: 760px) {
  .rgrid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .aside {
    grid-template-columns: minmax(0, 1fr);
  }
  .src-card .in {
    grid-template-columns: minmax(0, 1fr);
  }
  .go-src {
    flex-direction: column;
    align-items: flex-start;
  }
  .go-src .btn {
    margin-left: 0;
  }
  .tools {
    margin-left: 0;
    width: 100%;
  }
  .reporter {
    flex-wrap: wrap;
  }
  .reporter .btn {
    margin-left: 0;
  }
  .pn a {
    grid-template-columns: 60px minmax(0, 1fr);
  }
  .pn a small {
    display: none;
  }
  .c.reply {
    margin-left: 24px;
  }
}

/* ── 이식 추가 (본문 HTML · 미리보기 · 첨부 · 수정/삭제 · 댓글 파셜 board/_hub/comments.php) ── */
.portal-view {
  padding-bottom: 64px;
}
.th img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.body img {
  max-width: 100%;
  height: auto;
  border-radius: 12px;
}
.body h2 {
  font-size: 1.3em;
  font-weight: 800;
  margin: 1.8em 0 0.7em;
  letter-spacing: -0.03em;
}
.body ul,
.body ol {
  padding-left: 1.3em;
  margin-bottom: 1.25em;
  list-style: revert;
}
.body a {
  color: var(--brand-ink);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.body .btn {
  text-decoration: none;
}
.body .btn-primary {
  color: #fff;
}
.body pre {
  overflow-x: auto;
  padding: 14px 16px;
  border-radius: 10px;
  background: var(--surface-2);
  font-size: 14px;
}
.body table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 1.25em;
  font-size: 15px;
}
.body th,
.body td {
  border: 1px solid var(--line);
  padding: 8px 10px;
}
.summary p {
  font-size: 15.5px;
  line-height: 1.75;
}
.summary .summary-body {
  font-size: 15.5px;
  line-height: 1.75;
}
.summary .summary-body p {
  margin-bottom: 0.6em;
}
.summary .summary-body ol,
.summary .summary-body ul {
  padding-left: 20px;
  list-style: revert;
}
.tools button.on {
  border-color: var(--brand);
  color: var(--brand);
}
.react form {
  margin: 0;
}
.files {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 14px 0;
}
.files a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  color: var(--text-2);
}
.files a:hover {
  color: var(--brand);
}
.files svg.lucide {
  width: 15px;
  height: 15px;
}
.owner {
  display: flex;
  justify-content: flex-end;
  gap: 6px;
  padding-top: 14px;
}
.owner form {
  margin: 0;
}
.owner .del {
  border: 1px solid var(--line);
  color: var(--text-2);
}
.aside-empty {
  font-size: 13px;
  color: var(--text-3);
  padding: 8px 0;
}
.aside .rank .chg {
  color: var(--text-3);
  font-weight: 500;
}
.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;
}

/* 댓글 — board/_hub/comments.php 마크업을 시안 .cmt 모양으로 */
.cmt {
  margin-top: 40px;
}
.hx-comments h3 {
  font-size: 19px;
  font-weight: 800;
  letter-spacing: -0.03em;
  margin-bottom: 14px;
}
.hx-comments h3 b {
  color: var(--brand);
}
.hx-cbox {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 8px;
  padding: 14px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--surface);
  margin-bottom: 16px;
}
.hx-cbox:focus-within {
  border-color: var(--brand);
}
.hx-cbox textarea {
  width: 100%;
  min-height: 84px;
  border: 0;
  outline: 0;
  resize: vertical;
  background: none;
  font: inherit;
  font-size: 14px;
  color: var(--text);
}
.hx-cbox__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border-top: 1px solid var(--line);
  padding-top: 10px;
  font-size: 12.5px;
  color: var(--text-3);
}
.hx-cbox .btn {
  height: 34px;
  padding: 0 14px;
  font-size: 13px;
  border-radius: 8px;
  background: var(--brand-2);
  color: #fff;
}
.hx-cbox--login {
  flex-direction: row;
  align-items: center;
  gap: 10px;
  color: var(--text-2);
  font-size: 14px;
}
.hx-cbox--login svg {
  width: 18px;
  height: 18px;
  color: var(--brand);
}
.hx-cbox--login span {
  margin-left: auto;
}
.hx-cbox--reply {
  flex-direction: row;
  align-items: flex-end;
  margin: 10px 0 0;
  padding: 8px 8px 8px 14px;
  background: var(--bg);
}
.hx-cbox--reply textarea {
  min-height: 28px;
}
.hx-cm-empty {
  padding: 28px 0;
  text-align: center;
  color: var(--text-3);
  font-size: 14px;
}
.hx-cm-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.hx-cm {
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr);
  gap: 12px;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}
.hx-cm.is-reply {
  margin-left: 48px;
}
.hx-cm .pav,
.hx-cm .cm-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: #fff;
  font-weight: 800;
  font-size: 13px;
  background: #1e3a8a;
  overflow: hidden;
}
.hx-cm .pav img,
.hx-cm .cm-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.hx-cm__m {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
}
.hx-cm__m b {
  font-size: 13.5px;
}
.hx-cm__m time {
  color: var(--text-3);
  font-size: 12px;
}
.hx-cm__badge {
  font-size: 11px;
  font-weight: 800;
  color: var(--brand-ink);
  background: var(--brand-soft);
  padding: 1px 6px;
  border-radius: 4px;
}
.hx-cm__text {
  font-size: 14.5px;
  margin: 6px 0 8px;
  line-height: 1.6;
  word-break: break-word;
}
.hx-cm__gone {
  grid-column: 1 / -1;
  color: var(--text-3);
  font-size: 13.5px;
}
.hx-cm__tools {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 14px;
  font-size: 12.5px;
  color: var(--text-3);
}
.hx-cm__tools form {
  margin: 0;
}
.hx-cm__tools button,
.hx-cm__tools summary,
.hx-cm__tools a {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: var(--text-3);
  font-size: 12.5px;
  cursor: pointer;
  list-style: none;
}
.hx-cm__tools button:hover,
.hx-cm__tools summary:hover {
  color: var(--brand);
}
.hx-cm__tools summary::-webkit-details-marker {
  display: none;
}
.hx-cm__tools svg {
  width: 14px;
  height: 14px;
}
.hx-cm__reply[open] {
  flex-basis: 100%;
  order: 10;
}
.hx-cm__reply .c,
.hx-cm__reply[open] .o {
  display: none;
}
.hx-cm__reply[open] .c {
  display: inline;
}
@media (max-width: 760px) {
  .hx-cm.is-reply {
    margin-left: 24px;
  }
}
@media print {
  .topbar,
  .header,
  .gnb,
  .footer,
  .aside,
  .tools,
  .react,
  .owner,
  .cmt,
  .related,
  .pn,
  .progress {
    display: none !important;
  }
  .layout {
    display: block;
  }
}

/* 수집 기사 매체 아이콘 (techfeed 소스 아이콘이 있을 때 — TechUi::fav has-img) */
.byline .pf.has-img,
.src-card .top .fav.has-img {
  background: #fff;
  border: 1px solid var(--line);
  overflow: hidden;
  padding: 0;
}
.byline .pf.has-img img,
.src-card .top .fav.has-img img {
  width: 70%;
  height: 70%;
  object-fit: contain;
  display: block;
}
