/* 퀘스트피아 — 글 상자 · 목록 · 메인 페이지 (추가 CSS 대신 이 파일 하나로 관리) */

/* ── 기본 글자 ── */
body { font-family: "Pretendard", "Apple SD Gothic Neo", "Malgun Gothic", "Noto Sans KR", sans-serif; word-break: keep-all; }
.entry-content { font-size: 16px; line-height: 1.8; }
.entry-content h2 { font-size: 1.3em; margin: 2em 0 .7em; padding-bottom: .35em; border-bottom: 2px solid #1f2a5a; }
.entry-content h3 { font-size: 1.08em; margin: 1.5em 0 .5em; }

/* ── 표 ── */
.entry-content table { width: 100%; border-collapse: collapse; margin: 0 0 1.5em; font-size: .93em; }
.entry-content th, .entry-content td { border: 1px solid #d9dcec; padding: 8px 10px; text-align: left; vertical-align: top; }
.entry-content thead th { background: #eef0fa; font-weight: 700; }
@media (max-width: 600px) {
  .entry-content table { display: block; overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .entry-content th, .entry-content td { min-width: 88px; }
}

/* ── 글 안 상자 ── */
.pc-summary { background: #f3f4fc; border: 1px solid #d6daf2; border-radius: 12px; padding: 14px 18px; margin: 1.2em 0 1.4em; }
.pc-summary-title { font-weight: 700; color: #1f2a5a; margin: 0 0 6px; }
.pc-summary ul { margin: 0 0 0 1.2em; }
.pc-summary li { margin: 3px 0; }
.pc-series { background: #fffaf0; border: 1px solid #f0e2bd; border-left: 4px solid #e0b23c; border-radius: 12px; padding: 12px 16px; margin: 0 0 1.8em; }
.pc-series-title { font-weight: 700; color: #7a5a0a; margin: 0 0 6px; }
.pc-series ol { list-style: none; margin: 0; padding: 0; }
.pc-series li { margin: 3px 0; font-size: .93em; }
.pc-series a { color: #1f2a5a; }
.pc-series-soon { color: #8b8b95; font-size: .9em; }
.pc-official { background: #f7f2fb; border: 1px solid #e3d6f0; border-radius: 12px; padding: 16px 18px; margin: 2em 0; text-align: center; }
.pc-official-lead { margin: 0 0 10px; font-weight: 600; }
.pc-btns { margin: 0; }
.pc-btn { display: inline-block; background: #1f2a5a; color: #fff !important; text-decoration: none !important; font-weight: 700; padding: 10px 18px; border-radius: 999px; margin: 4px; font-size: .95em; }
.pc-btn:hover { background: #33418a; }
.pc-related { border-top: 1px solid #e4e6f0; margin-top: 2em; padding-top: 1em; }
.pc-related-title { font-weight: 700; margin: 0 0 6px; }
.pc-source { background: #f5f6f9; border-radius: 10px; padding: 12px 16px; margin-top: 1.5em; font-size: .86em; color: #555b66; }
.pc-source p { margin: 0 0 4px; }
.pc-source p:last-child { margin: 0; }

/* ── 카테고리·검색 목록 촘촘하게 + 제목 굵게 ── */
.archive .inside-article, .search .inside-article, .blog .inside-article { padding: 16px 20px; }
.archive .site-main article, .search .site-main article, .blog .site-main article { margin-bottom: 10px; }
body.archive .entry-title, body.search .entry-title, body.blog .entry-title { font-size: 19px; line-height: 1.4; margin-bottom: 2px; font-weight: 700; }
.archive .entry-title a, .search .entry-title a, .blog .entry-title a { color: #1c1f2e; }
.archive .entry-title a:hover, .search .entry-title a:hover, .blog .entry-title a:hover { color: #33418a; }
.archive .entry-meta, .search .entry-meta, .blog .entry-meta { font-size: 12px; margin-top: 4px; }
.archive .entry-summary, .search .entry-summary, .blog .entry-summary { font-size: 14px; margin-top: 6px; }
.archive .entry-summary p, .search .entry-summary p, .blog .entry-summary p { margin: 0; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.archive footer.entry-meta, .search footer.entry-meta, .blog footer.entry-meta { margin-top: 6px; }
.archive .page-header, .search .page-header { padding: 16px 20px; margin-bottom: 10px; }
.archive .page-header h1, .search .page-header h1 { font-size: 22px; }
body.single .entry-header .entry-title, body.single h1.entry-title { font-size: 28px; line-height: 1.35; font-weight: 700; }
@media (max-width: 768px) {
  body.archive .entry-title, body.search .entry-title, body.blog .entry-title { font-size: 17px; }
  body.single .entry-header .entry-title, body.single h1.entry-title { font-size: 23px; }
}

/* ── 메인 페이지 ── */
.qph-front .entry-header, .qph-front .page-header, .qph-front .wp-block-post-title { display: none; }
.qph-front .inside-article { padding-top: 20px; }
.qph { --navy: #1f2a5a; --star: #f4c96b; --ink: #1c1f2e; --mute: #6b7080; --line: #e4e6f0; color: var(--ink); font-size: 14px; }
.qph a { text-decoration: none; }
.qph-sec { margin: 30px 0 0; }
.qph-h2 { font-size: 16px; font-weight: 700; margin: 0 0 12px; display: flex; align-items: center; gap: 6px; }
.qph-h2::before { content: "✦"; color: var(--star); font-size: 14px; }

/* 1. 머리말 */
.qph-hero { background: var(--navy); border-radius: 18px; overflow: hidden; color: #fff; }
.qph-hero-text { padding: 22px 24px 10px; }
.qph-hero-kicker { margin: 0 0 6px; font-size: 11px; letter-spacing: .12em; color: var(--star); font-weight: 700; }
.qph-hero-title { font-size: 20px; line-height: 1.45; margin: 0 0 6px; color: #fff; font-weight: 700; }
.qph-hero-sub { margin: 0 0 14px; font-size: 13px; color: #d5d9f0; }
.qph-search label[for] { position: absolute; left: -9999px; }
.qph-search form { display: flex; gap: 6px; max-width: 440px; }
.qph-search input[type="search"], .qph-search input[type="text"] { flex: 1; min-width: 0; padding: 8px 12px; border: 0; border-radius: 999px; background: #fff; font-size: 13px; }
.qph-search button, .qph-search input[type="submit"] { padding: 8px 16px; border: 0; border-radius: 999px; background: var(--star); color: var(--navy); font-weight: 700; font-size: 13px; cursor: pointer; }
.qph-hero-img { display: block; width: 100%; height: auto; }

/* 2. 동그란 바로가기 */
.qph-dots { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 8px; }
.qph-dot { display: flex; flex-direction: column; align-items: center; gap: 6px; color: var(--ink); position: relative; }
.qph-dot-circle { width: 56px; height: 56px; border-radius: 50%; background: var(--tint); display: flex; align-items: center; justify-content: center; transition: transform .15s; }
.qph-dot:hover .qph-dot-circle { transform: translateY(-2px); }
.qph-dot-name { font-size: 12px; font-weight: 600; }
.qph-dot-soon { position: absolute; top: -4px; right: 50%; transform: translateX(38px); background: var(--star); color: var(--navy); font-size: 9px; font-weight: 700; padding: 1px 5px; border-radius: 999px; }

/* 3. 카드 */
.qph-cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.qph-card { display: flex; gap: 10px; align-items: flex-start; padding: 12px; border-radius: 16px; background: var(--tint); color: var(--ink); box-shadow: 0 1px 3px rgba(31,42,90,.06); transition: box-shadow .15s; }
.qph-card:hover { box-shadow: 0 4px 12px rgba(31,42,90,.12); }
.qph-card-body { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.qph-card-cat { font-size: 11px; font-weight: 700; color: var(--navy); opacity: .75; }
.qph-card-title { font-size: 14px; font-weight: 700; line-height: 1.45; }
.qph-card-date { font-size: 11px; color: var(--mute); }

/* 4. 연재 책갈피 */
.qph-marks { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.qph-mark { position: relative; padding: 12px 12px 12px 18px; border-radius: 14px; background: var(--tint); color: var(--ink); }
.qph-mark::before { content: ""; position: absolute; left: 0; top: 10px; bottom: 10px; width: 5px; border-radius: 0 4px 4px 0; background: var(--star); }
.qph-mark-name { display: block; font-size: 14px; font-weight: 700; }
.qph-mark-sub { display: block; font-size: 11px; color: var(--mute); margin-top: 2px; }

/* 5. 오늘의 천문용어 */
.qph-today { background: linear-gradient(135deg, #1f2a5a, #3a3f7a); color: #fff; border-radius: 16px; padding: 16px 18px; }
.qph-today-label { margin: 0 0 4px; font-size: 11px; color: var(--star); font-weight: 700; letter-spacing: .05em; }
.qph-today-title { display: block; color: #fff !important; font-size: 15px; font-weight: 700; line-height: 1.45; }
.qph-today-desc { margin: 6px 0 0; font-size: 12px; color: #d5d9f0; }

/* 6. 분야별 최신 글 */
.qph-boxes { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.qph-box { border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px; background: #fff; }
.qph-box-title { font-size: 14px; margin: 0 0 6px; display: flex; align-items: center; gap: 6px; }
.qph-box ul { list-style: none; margin: 0; padding: 0; }
.qph-box li { padding: 6px 0; border-top: 1px dashed var(--line); font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.qph-box li:first-child { border-top: 0; }
.qph-box li a { color: var(--ink); }
.qph-box li a:hover { color: #33418a; }
.qph-more { margin: 6px 0 0; font-size: 12px; }
.qph-more a { color: var(--navy); font-weight: 700; }

/* 휴대폰 */
@media (max-width: 768px) {
  .qph-hero-text { padding: 18px 16px 8px; }
  .qph-hero-title { font-size: 17px; }
  .qph-dots { grid-template-columns: repeat(4, minmax(0, 1fr)); row-gap: 14px; }
  .qph-cards, .qph-boxes { grid-template-columns: minmax(0, 1fr); }
  .qph-marks { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
