@font-face {
  font-family: "GowunDodum";
  src: url("/static/GowunDodum-Regular.ttf") format("truetype");
  font-display: swap;
}

:root {
  --bg: #fbf7f2;
  --paper: #fffaf6;
  --surface: #ffffff;
  --ink: #2f2933;
  --muted: #766d77;
  --subtle: #a0969f;
  --line: #e9ded6;
  --rose: #e87580;
  --rose-strong: #d76470;
  --rose-soft: #ffe9ed;
  --mint: #55c5ad;
  --mint-soft: #e8f8f4;
  --yellow-soft: #fff4cc;
  --shadow: 0 14px 34px rgba(82, 63, 71, 0.08);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "GowunDodum", -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo",
    "Noto Sans KR", sans-serif;
  color: var(--ink);
  background: linear-gradient(180deg, #fffdfb 0%, var(--bg) 58%, #fffaf6 100%);
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
select {
  font: inherit;
}

img {
  display: block;
  max-width: 100%;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  border-bottom: 1px solid rgba(233, 222, 214, 0.92);
  background: rgba(255, 250, 246, 0.94);
  backdrop-filter: blur(14px);
}

.container {
  width: min(1180px, calc(100vw - 32px));
  margin: 0 auto;
}

.top-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: 74px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: max-content;
  font-weight: 900;
}

.brand img {
  width: 44px;
  height: 44px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface);
}

.brand span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.nav-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  min-width: 0;
}

.nav-links a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 0 14px;
  border-radius: 999px;
  color: var(--muted);
  font-size: 15px;
  font-weight: 900;
  white-space: nowrap;
}

.nav-links a[aria-current="page"] {
  background: var(--rose-soft);
  color: var(--rose-strong);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 0 15px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--ink);
  font-weight: 900;
  white-space: nowrap;
}

.btn-primary {
  border-color: var(--rose);
  background: var(--rose);
  color: #fff;
  box-shadow: 0 12px 26px rgba(232, 117, 128, 0.2);
}

.board-hero {
  padding: 34px 0 18px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 14px;
  color: var(--subtle);
  font-size: 13px;
  font-weight: 900;
}

.breadcrumb a {
  color: var(--muted);
}

.hero-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 240px;
  gap: 22px;
  align-items: center;
  padding: 30px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(232, 117, 128, 0.1), rgba(85, 197, 173, 0.1)),
    var(--surface);
  box-shadow: var(--shadow);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 0 12px;
  border-radius: 999px;
  background: var(--mint-soft);
  color: #268d79;
  font-size: 13px;
  font-weight: 900;
}

h1 {
  margin: 16px 0 12px;
  font-size: clamp(32px, 4.2vw, 52px);
  line-height: 1.1;
}

.hero-panel p {
  margin: 0;
  max-width: 720px;
  color: var(--muted);
  font-size: 16px;
  font-weight: 800;
  line-height: 1.75;
}

.hero-art {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.68);
}

.hero-art img {
  border-radius: 8px;
}

.board-shell {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 22px;
  align-items: start;
  padding: 8px 0 36px;
}

.board-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 14px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.86);
}

.board-summary {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
  font-weight: 900;
  line-height: 1.5;
}

.sort-segment {
  display: inline-flex;
  gap: 4px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
}

.sort-button {
  min-height: 34px;
  padding: 0 12px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--muted);
  font-weight: 900;
  cursor: pointer;
}

.sort-button[aria-pressed="true"] {
  background: var(--rose);
  color: #fff;
}

.board-select {
  min-height: 46px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--muted);
  font-weight: 900;
}

.board-state {
  padding: 28px 18px;
  color: var(--muted);
  font-size: 15px;
  font-weight: 900;
  line-height: 1.7;
  text-align: center;
}

.board-state.error {
  color: var(--rose-strong);
}

.board-state[hidden] {
  display: none;
}

.tab-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 14px;
}

.tab {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--muted);
  font-size: 14px;
  font-weight: 900;
}

.tab[aria-current="true"] {
  border-color: var(--rose);
  background: var(--rose-soft);
  color: var(--rose-strong);
}

.board-list {
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.list-head,
.post-row {
  display: grid;
  grid-template-columns: 116px minmax(0, 1fr) 120px 96px;
  gap: 12px;
  align-items: center;
}

.list-head {
  min-height: 46px;
  padding: 0 18px;
  border-bottom: 1px solid var(--line);
  background: var(--paper);
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
}

.post-row {
  padding: 18px;
  border-bottom: 1px solid var(--line);
}

.post-row:last-child {
  border-bottom: 0;
}

.badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  background: var(--mint-soft);
  color: #268d79;
  font-size: 12px;
  font-weight: 900;
}

.badge.hot {
  background: var(--rose-soft);
  color: var(--rose-strong);
}

.badge.wait {
  background: var(--yellow-soft);
  color: #9a7518;
}

.post-title {
  min-width: 0;
}

.post-title h2 {
  margin: 0 0 7px;
  font-size: 19px;
  line-height: 1.35;
}

.post-title p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  font-weight: 800;
  line-height: 1.55;
}

.post-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 12px;
  margin-top: 10px;
  color: var(--subtle);
  font-size: 12px;
  font-weight: 900;
}

.count-cell,
.date-cell {
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
  line-height: 1.55;
  text-align: right;
}

.pagination {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin: 20px 0 0;
}

.page-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 38px;
  height: 38px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--muted);
  font-weight: 900;
}

.page-link[aria-current="page"] {
  border-color: var(--rose);
  background: var(--rose);
  color: #fff;
}

.page-gap {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 38px;
  color: var(--subtle);
  font-weight: 900;
}

.side-stack {
  display: grid;
  gap: 14px;
}

.side-panel {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.side-panel h2 {
  margin: 0 0 12px;
  font-size: 21px;
}

.side-panel p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  font-weight: 800;
  line-height: 1.65;
}

.rank-list {
  display: grid;
  gap: 10px;
}

.rank-item {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
}

.rank-item:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.rank-num {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: var(--rose-soft);
  color: var(--rose-strong);
  font-weight: 900;
}

.rank-item strong {
  display: block;
  margin-bottom: 4px;
  line-height: 1.35;
}

.rank-item span {
  color: var(--subtle);
  font-size: 12px;
  font-weight: 900;
}

.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tag {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
}

.app-panel {
  display: grid;
  grid-template-columns: 68px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  background: linear-gradient(135deg, var(--rose-soft), var(--mint-soft));
}

.app-panel img {
  width: 68px;
  height: 68px;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.app-panel .btn {
  margin-top: 12px;
}

.seo-copy {
  margin-top: 24px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.72);
}

.seo-copy h2 {
  margin: 0 0 10px;
  font-size: 22px;
}

.seo-copy p {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
  font-weight: 800;
  line-height: 1.75;
}

.detail-hero {
  padding-bottom: 12px;
}

.detail-title-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 180px;
  gap: 22px;
  align-items: center;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(232, 117, 128, 0.1), rgba(85, 197, 173, 0.1)),
    var(--surface);
  box-shadow: var(--shadow);
}

.detail-title-panel h1 {
  max-width: 860px;
  overflow-wrap: anywhere;
}

.detail-title-panel p {
  margin: 0;
  max-width: 760px;
  color: var(--muted);
  font-size: 16px;
  font-weight: 800;
  line-height: 1.75;
}

.detail-title-panel .hero-art {
  margin: 0;
}

.detail-meta {
  margin-top: 14px;
}

.detail-shell {
  grid-template-columns: minmax(0, 1fr) 310px;
}

.detail-content {
  display: grid;
  gap: 14px;
  min-width: 0;
}

.detail-card {
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.detail-card h2 {
  margin: 0 0 12px;
  font-size: 22px;
  line-height: 1.3;
}

.detail-card h3 {
  margin: 18px 0 8px;
  font-size: 17px;
  line-height: 1.35;
}

.detail-card h3:first-child {
  margin-top: 0;
}

.detail-card p {
  margin: 0;
  color: var(--muted);
  font-size: 16px;
  font-weight: 800;
  line-height: 1.82;
  overflow-wrap: anywhere;
}

.lead-card {
  border-color: rgba(232, 117, 128, 0.34);
}

.lead-card .tag-cloud {
  margin-bottom: 14px;
}

.statement-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.verdict-card {
  background: linear-gradient(180deg, #fff, #fffaf6);
}

.mission-list {
  display: grid;
  gap: 10px;
  margin: 0;
  padding-left: 20px;
  color: var(--muted);
  font-size: 16px;
  font-weight: 800;
  line-height: 1.75;
}

.stat-list {
  display: grid;
  gap: 10px;
}

.stat-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font-size: 14px;
  font-weight: 900;
}

.stat-row:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.stat-row strong {
  color: var(--ink);
}

.vote-bars {
  display: grid;
  gap: 8px;
  padding-top: 4px;
}

.vote-bars div {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  min-height: 34px;
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
}

.vote-bars strong {
  color: var(--rose-strong);
}

.reaction-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.reaction-row span {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 9px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
}

.comment-list {
  display: grid;
  gap: 10px;
}

.comment-form {
  display: grid;
  gap: 12px;
  margin-bottom: 16px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
}

.comment-form label {
  display: grid;
  gap: 8px;
}

.comment-form label span {
  color: var(--ink);
  font-size: 14px;
  font-weight: 900;
}

.comment-form textarea {
  width: 100%;
  resize: vertical;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fffdfb;
  color: var(--ink);
  font-size: 14px;
  font-weight: 800;
  line-height: 1.65;
}

.comment-item {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fffdfb;
}

.comment-item.reply {
  margin-left: 24px;
  background: var(--paper);
}

.comment-head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 8px;
}

.comment-head strong {
  font-size: 14px;
}

.comment-head span,
.comment-foot {
  color: var(--subtle);
  font-size: 12px;
  font-weight: 900;
}

.comment-item p {
  font-size: 14px;
  line-height: 1.7;
}

.comment-foot {
  margin-top: 10px;
}

.empty-text {
  color: var(--subtle) !important;
}

.form-hero {
  grid-template-columns: 1fr;
}

.form-shell {
  padding: 8px 0 36px;
}

.write-form {
  display: grid;
  gap: 16px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.embedded-form {
  padding: 0;
  border: 0;
  box-shadow: none;
}

.write-form label {
  display: grid;
  gap: 8px;
  min-width: 0;
}

.write-form label > span,
.write-form legend {
  color: var(--ink);
  font-size: 14px;
  font-weight: 900;
}

.write-form input[type="text"],
.write-form textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fffdfb;
  color: var(--ink);
  font-size: 15px;
  font-weight: 800;
  line-height: 1.6;
}

.write-form input[type="text"] {
  min-height: 46px;
  padding: 0 12px;
}

.write-form textarea {
  resize: vertical;
  padding: 12px;
}

.write-form fieldset {
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}

.choice-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.choice-grid.compact {
  margin-top: 8px;
}

.choice-pill {
  display: inline-flex !important;
  grid-template-columns: none;
  align-items: center;
  min-height: 36px;
  cursor: pointer;
}

.choice-pill input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.choice-pill span {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--muted);
  font-size: 14px;
  font-weight: 900;
}

.choice-pill input:checked + span {
  border-color: var(--rose);
  background: var(--rose-soft);
  color: var(--rose-strong);
}

.field-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.form-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}

.form-state {
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
  color: var(--muted);
  font-size: 14px;
  font-weight: 900;
  line-height: 1.55;
}

.form-state:empty {
  display: none;
}

.form-state.error {
  border-color: rgba(232, 117, 128, 0.44);
  background: var(--rose-soft);
  color: var(--rose-strong);
}

.case-list-head,
.case-list-head + .post-row {
  grid-template-columns: 116px minmax(0, 1fr) 96px 96px;
}

.full-button {
  width: 100%;
  margin-top: 12px;
}

.footer {
  padding: 20px 0 32px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  gap: 16px;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.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;
}

@media (max-width: 1020px) {
  .top-nav {
    flex-wrap: wrap;
    padding: 12px 0;
  }

  .nav-links {
    order: 3;
    justify-content: flex-start;
    width: 100%;
    overflow-x: auto;
    padding-bottom: 2px;
  }

  .hero-panel,
  .board-shell,
  .detail-shell {
    grid-template-columns: 1fr;
  }

  .hero-art {
    max-width: 180px;
  }
}

@media (max-width: 760px) {
  .container {
    width: min(100vw - 22px, 1180px);
  }

  .nav-links {
    flex-wrap: wrap;
    overflow-x: visible;
  }

  .nav-links a {
    min-height: 34px;
    padding: 0 10px;
    font-size: 14px;
  }

  .nav-actions .btn:first-child {
    display: none;
  }

  .hero-panel,
  .detail-title-panel,
  .field-grid,
  .board-controls,
  .app-panel {
    grid-template-columns: 1fr;
  }

  .hero-panel,
  .detail-title-panel,
  .detail-card,
  .side-panel,
  .seo-copy {
    padding: 15px;
  }

  .list-head {
    display: none;
  }

  .post-row {
    grid-template-columns: 1fr;
    gap: 10px;
    padding: 16px;
  }

  .count-cell,
  .date-cell {
    text-align: left;
  }

  .statement-grid {
    grid-template-columns: 1fr;
  }

  .comment-item.reply {
    margin-left: 12px;
  }

  .footer-inner {
    flex-direction: column;
  }
}
