:root {
  --bg: #f7f7f4;
  --paper: #ffffff;
  --ink: #1f2428;
  --muted: #66707a;
  --line: #e3e0d8;
  --accent: #2f6f73;
  --accent-soft: #e7f0ef;
  --tag: #f0eee8;
  --shadow: 0 10px 30px rgba(31, 36, 40, 0.06);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans KR", sans-serif;
  line-height: 1.68;
  letter-spacing: 0;
}

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

a:hover {
  color: var(--accent);
}

.site {
  width: min(1040px, calc(100% - 40px));
  margin: 0 auto;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  border-bottom: 1px solid rgba(227, 224, 216, 0.86);
  background: rgba(247, 247, 244, 0.92);
  backdrop-filter: blur(14px);
}

.topbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  width: min(1040px, calc(100% - 40px));
  margin: 0 auto;
  padding: 14px 0;
}

.brand {
  font-weight: 700;
}

.nav {
  display: flex;
  gap: 16px;
  color: var(--muted);
  font-size: 14px;
}

.hero {
  padding: 72px 0 42px;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--accent);
  font-size: 14px;
  font-weight: 700;
}

h1,
h2,
h3 {
  line-height: 1.25;
  letter-spacing: 0;
}

h1 {
  max-width: 820px;
  margin: 0;
  font-size: clamp(34px, 5vw, 56px);
}

h2 {
  margin: 0 0 20px;
  font-size: 26px;
}

h3 {
  margin: 0 0 10px;
  font-size: 20px;
}

p {
  margin: 0 0 14px;
}

.lead {
  max-width: 780px;
  margin-top: 22px;
  color: #3f474d;
  font-size: 18px;
}

.meta-row,
.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 22px;
}

.pill,
.tag {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--paper);
  padding: 4px 10px;
  color: #444c52;
  font-size: 13px;
  white-space: nowrap;
}

.link-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 14px 0 6px;
}

.link-button {
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  border: 1px solid #b8cecc;
  border-radius: 8px;
  background: var(--accent-soft);
  padding: 7px 12px;
  color: #1f5559;
  font-size: 14px;
  font-weight: 700;
}

.link-button:hover {
  border-color: var(--accent);
  background: #dbeceb;
}

.small-note {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.resource-links {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 16px 0 8px;
}

.resource-card {
  position: relative;
  display: grid;
  grid-template-columns: 42px 1fr;
  gap: 12px;
  align-items: center;
  min-height: 86px;
  border: 1px solid #b8cecc;
  border-radius: 8px;
  background: linear-gradient(180deg, #ffffff 0%, var(--accent-soft) 100%);
  padding: 14px 40px 14px 14px;
  box-shadow: var(--shadow);
}

.resource-card::after {
  content: "↗";
  position: absolute;
  top: 14px;
  right: 14px;
  color: var(--accent);
  font-weight: 800;
}

.resource-card:hover {
  border-color: var(--accent);
  transform: translateY(-1px);
}

.resource-icon {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 8px;
  background: #2f6f73;
  color: #fff;
}

.resource-icon svg {
  width: 22px;
  height: 22px;
  stroke: currentColor;
}

.resource-title {
  display: block;
  color: var(--ink);
  font-weight: 800;
  line-height: 1.3;
}

.resource-desc {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

.section {
  padding: 36px 0;
  border-top: 1px solid var(--line);
}

.grid-2 {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 22px;
}

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

.list {
  display: grid;
  gap: 12px;
}

.row {
  display: grid;
  grid-template-columns: 150px 1fr;
  gap: 20px;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}

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

.row strong {
  display: block;
}

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

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

.project-card {
  display: flex;
  min-height: 210px;
  flex-direction: column;
  justify-content: space-between;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
  padding: 20px;
  box-shadow: var(--shadow);
  transition: transform 160ms ease, border-color 160ms ease;
}

.project-card:hover {
  transform: translateY(-2px);
  border-color: #b9d0ce;
}

.project-card p {
  color: var(--muted);
}

.project-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.status {
  color: var(--accent);
  font-weight: 700;
}

.page {
  padding: 42px 0 80px;
}

.back {
  display: inline-flex;
  margin-bottom: 26px;
  color: var(--muted);
  font-size: 14px;
}

.project-hero {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 28px;
  align-items: start;
}

.project-hero.no-media {
  grid-template-columns: 1fr;
}

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

.cover img {
  display: block;
  width: 100%;
  height: auto;
}

.cover.small img {
  max-height: 520px;
  object-fit: contain;
  background: #fff;
}

.stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin: 28px 0;
}

.stat {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
  padding: 16px;
}

.stat b {
  display: block;
  margin-bottom: 4px;
  color: var(--accent);
  font-size: 22px;
}

.content {
  display: grid;
  gap: 22px;
}

.content-section {
  border-top: 1px solid var(--line);
  padding-top: 26px;
}

.content-section ul {
  margin: 10px 0 0;
  padding-left: 20px;
}

.content-section li {
  margin-bottom: 8px;
}

.note {
  border-left: 3px solid var(--accent);
  background: var(--accent-soft);
  padding: 14px 16px;
}

.compact-list {
  display: grid;
  gap: 10px;
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}

.panel.compact-list {
  margin-top: 0;
  padding-top: 22px;
  border-top: 1px solid var(--line);
}

.compact-item {
  display: grid;
  grid-template-columns: 130px 1fr;
  gap: 14px;
  font-size: 14px;
}

.compact-item p {
  margin: 2px 0 0;
  color: var(--muted);
}

.image-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.inline-figure {
  overflow: hidden;
  margin: 18px 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
}

.inline-figure img {
  display: block;
  width: 100%;
  max-height: 640px;
  object-fit: contain;
  background: #fff;
}

.inline-figure figcaption {
  padding: 9px 12px;
  color: var(--muted);
  font-size: 13px;
  border-top: 1px solid var(--line);
}

.inline-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 18px 0;
}

.inline-grid .inline-figure {
  margin: 0;
}

.thumb {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
}

.thumb img {
  display: block;
  width: 100%;
  max-height: 260px;
  object-fit: contain;
  background: #fff;
}

.thumb figcaption {
  padding: 8px 10px;
  color: var(--muted);
  font-size: 13px;
  border-top: 1px solid var(--line);
}

.footer {
  padding: 34px 0 60px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 14px;
}

@media (max-width: 820px) {
  .topbar-inner {
    align-items: flex-start;
    flex-direction: column;
    gap: 8px;
  }

  .nav {
    width: 100%;
    overflow-x: auto;
    padding-bottom: 4px;
  }

  .grid-2,
  .projects,
  .project-hero,
  .stats,
  .image-grid,
  .inline-grid,
  .resource-links {
    grid-template-columns: 1fr;
  }

  .row,
  .compact-item {
    grid-template-columns: 1fr;
    gap: 6px;
  }

  .hero {
    padding-top: 48px;
  }
}
