:root {
  --primary: #1e40af;
  --primary-dark: #172f7d;
  --secondary: #f8fafc;
  --ink: #111827;
  --muted: #64748b;
  --line: #dbe3ef;
  --surface: #ffffff;
  --soft-blue: #eef4ff;
  --accent: #0f766e;
  --warn: #9a3412;
  --shadow: 0 18px 45px rgba(15, 23, 42, 0.08);
  --radius: 8px;
  --content: 1120px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  font-family: "Pretendard", "Apple SD Gothic Neo", "Noto Sans KR", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  line-height: 1.7;
  background: var(--surface);
}

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

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

img,
svg {
  max-width: 100%;
}

.container {
  width: min(var(--content), calc(100% - 40px));
  margin-inline: auto;
}

.skip-link {
  position: absolute;
  left: 16px;
  top: -50px;
  z-index: 100;
  padding: 10px 14px;
  color: #fff;
  background: var(--primary);
}

.skip-link:focus {
  top: 12px;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  border-bottom: 1px solid rgba(219, 227, 239, 0.8);
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(14px);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 74px;
  gap: 24px;
}

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-weight: 800;
}

.brand small {
  display: block;
  margin-top: -2px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 500;
}

.brand-mark,
.avatar {
  display: inline-grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border-radius: 8px;
  color: #fff;
  background: var(--primary);
  font-weight: 800;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 4px;
}

.site-nav a,
.nav-toggle {
  min-height: 40px;
  padding: 8px 12px;
  border-radius: 7px;
  color: #334155;
  font-size: 15px;
  font-weight: 700;
}

.site-nav a[aria-current="page"],
.site-nav a:hover {
  color: var(--primary);
  background: var(--soft-blue);
}

.admin-link {
  border: 1px solid var(--line);
}

.nav-toggle {
  display: none;
  border: 1px solid var(--line);
  background: #fff;
}

.hero {
  background:
    linear-gradient(135deg, rgba(30, 64, 175, 0.08), transparent 42%),
    var(--secondary);
  border-bottom: 1px solid var(--line);
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(300px, 0.85fr);
  gap: 42px;
  align-items: center;
  min-height: 560px;
  padding-block: 72px;
}

.hero h1,
.page-hero h1 {
  margin: 0;
  font-size: clamp(42px, 6vw, 72px);
  line-height: 1.08;
  letter-spacing: 0;
}

.hero-lead,
.article-subtitle,
.page-hero p {
  color: #334155;
  font-size: 20px;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--primary);
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.hero-copy p {
  max-width: 720px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 28px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 10px 16px;
  border-radius: 7px;
  border: 1px solid var(--line);
  font-weight: 800;
  cursor: pointer;
}

.button.primary {
  border-color: var(--primary);
  color: #fff;
  background: var(--primary);
}

.button.secondary {
  color: var(--primary);
  background: #fff;
}

.visual-card {
  position: relative;
  padding: 34px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background:
    linear-gradient(180deg, #fff, #f8fbff),
    repeating-linear-gradient(90deg, transparent 0 28px, rgba(30, 64, 175, 0.08) 28px 29px);
  box-shadow: var(--shadow);
}

.visual-card::before {
  content: "";
  display: block;
  height: 170px;
  margin-bottom: 24px;
  border-radius: 6px;
  background:
    linear-gradient(90deg, var(--primary) 0 22%, #22c55e 22% 40%, #0f766e 40% 58%, #94a3b8 58% 76%, #cbd5e1 76% 100%);
  clip-path: polygon(0 78%, 22% 56%, 40% 64%, 58% 34%, 76% 44%, 100% 22%, 100% 100%, 0 100%);
}

.visual-kicker {
  display: inline-block;
  margin-bottom: 10px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.visual-card strong {
  display: block;
  font-size: 24px;
  line-height: 1.35;
}

.section {
  padding-block: 70px;
}

.section.soft {
  background: var(--secondary);
  border-block: 1px solid var(--line);
}

.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 28px;
  margin-bottom: 24px;
}

.section-head.compact {
  display: block;
}

.section-head h2,
.side-panel h2,
.split-band h2,
.prose-page h2,
.article h2 {
  margin: 0 0 10px;
  font-size: 28px;
  line-height: 1.25;
}

.section-head p {
  max-width: 620px;
  margin: 0;
  color: var(--muted);
}

.category-grid,
.card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.card-grid.three {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.category-card,
.content-card,
.side-panel,
.editor-box,
.category-row,
.summary-box,
.toc,
.notice {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
}

.category-card,
.content-card {
  min-height: 190px;
  padding: 22px;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.category-card:hover,
.content-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

.category-card span,
.content-card h3 {
  display: block;
  margin: 0 0 10px;
  color: #0f172a;
  font-size: 21px;
  line-height: 1.35;
  font-weight: 900;
}

.category-card p,
.content-card p {
  margin: 0;
  color: var(--muted);
}

.pill {
  display: inline-flex;
  width: fit-content;
  margin-bottom: 12px;
  padding: 4px 9px;
  border-radius: 999px;
  color: var(--primary);
  background: var(--soft-blue);
  font-size: 12px;
  font-weight: 900;
}

.pill.accent {
  color: var(--accent);
  background: #ecfdf5;
}

.card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  margin-top: 18px;
  color: var(--muted);
  font-size: 13px;
}

.two-col {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 28px;
}

.side-panel {
  align-self: start;
  padding: 24px;
}

.check-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.check-list li {
  position: relative;
  margin: 10px 0;
  padding-left: 24px;
}

.check-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.72em;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
}

.check-list.warn li::before {
  background: var(--warn);
}

.split-band {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 0.8fr);
  gap: 28px;
  align-items: center;
}

.editor-box {
  display: flex;
  gap: 16px;
  padding: 22px;
}

.editor-box h3,
.editor-box h2 {
  margin: 0 0 6px;
  font-size: 20px;
}

.text-link {
  display: inline-block;
  margin-top: 8px;
  color: var(--primary);
  font-weight: 800;
}

.cta-band {
  text-align: center;
}

.cta-band .container {
  padding: 42px;
  border-radius: var(--radius);
  color: #fff;
  background: var(--primary);
}

.cta-band p {
  max-width: 680px;
  margin-inline: auto;
  color: rgba(255, 255, 255, 0.88);
}

.cta-band .button.primary {
  border-color: #fff;
  color: var(--primary);
  background: #fff;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding-top: 28px;
  color: var(--muted);
  font-size: 14px;
}

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

.page-hero {
  padding-block: 58px 30px;
}

.page-hero h1 {
  max-width: 860px;
  font-size: clamp(36px, 5vw, 56px);
}

.category-list {
  display: grid;
  gap: 14px;
}

.category-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 22px;
}

.category-row h2 {
  margin: 0 0 8px;
}

.category-row p {
  margin: 0;
  color: var(--muted);
}

.category-row span {
  flex: 0 0 auto;
  color: var(--primary);
  font-weight: 900;
}

.article {
  max-width: 860px;
  padding-block: 38px 76px;
}

.article-header {
  margin-bottom: 28px;
}

.article-header h1 {
  margin: 0;
  font-size: clamp(34px, 5vw, 54px);
  line-height: 1.18;
  letter-spacing: 0;
}

.article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
  color: var(--muted);
  font-size: 14px;
}

.summary-box,
.toc {
  margin: 24px 0;
  padding: 22px;
}

.summary-box {
  border-left: 5px solid var(--primary);
  background: #f8fbff;
}

.summary-box strong {
  display: block;
  margin-bottom: 8px;
  color: var(--primary);
  font-size: 18px;
}

.toc ol {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px 24px;
  margin: 0;
  padding-left: 20px;
}

.article section {
  margin-top: 34px;
}

.article p,
.prose-page p {
  color: #27364a;
}

.faq-block details {
  border-top: 1px solid var(--line);
  padding: 14px 0;
}

.faq-block summary {
  cursor: pointer;
  font-weight: 900;
}

.related-block {
  margin-top: 48px;
  padding-top: 28px;
  border-top: 1px solid var(--line);
}

.article-editor {
  margin-top: 42px;
}

.column-article .summary-box {
  border-left-color: var(--accent);
  background: #f0fdfa;
}

.author-hero {
  border-bottom: 1px solid var(--line);
}

.admin-cta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-top: 18px;
}

.notice {
  display: inline-flex;
  padding: 10px 12px;
  color: #475569;
  background: #fff;
}

.notice.success {
  color: #065f46;
  background: #ecfdf5;
  border-color: #a7f3d0;
}

.prose-page {
  max-width: 820px;
}

.prose-page ul {
  padding-left: 22px;
}

.contact-form {
  display: grid;
  gap: 14px;
  margin: 20px 0;
}

.contact-form label {
  display: grid;
  gap: 8px;
  font-weight: 800;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 7px;
  padding: 12px 13px;
  font: inherit;
}

.not-found {
  min-height: 420px;
}

.site-footer {
  padding-block: 44px 24px;
  color: #cbd5e1;
  background: #0f172a;
}

.site-footer a:hover {
  color: #fff;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 0.7fr 0.7fr;
  gap: 32px;
}

.footer-grid h2 {
  margin: 0 0 12px;
  color: #fff;
  font-size: 16px;
}

.footer-grid ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.footer-grid li {
  margin: 8px 0;
}

.footer-brand {
  color: #fff;
  font-size: 20px;
}

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

.footer-bottom {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  margin-top: 34px;
  padding-top: 20px;
  border-top: 1px solid rgba(203, 213, 225, 0.2);
  font-size: 14px;
}

@media (max-width: 920px) {
  .header-inner {
    align-items: flex-start;
    padding-block: 14px;
  }

  .nav-toggle {
    display: inline-flex;
  }

  .site-nav {
    position: absolute;
    inset: 74px 20px auto 20px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #fff;
    box-shadow: var(--shadow);
  }

  .site-nav.is-open {
    display: flex;
  }

  .hero-grid,
  .two-col,
  .split-band,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .hero-grid {
    min-height: auto;
    padding-block: 52px;
  }

  .category-grid,
  .card-grid,
  .card-grid.three {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .container {
    width: min(100% - 28px, var(--content));
  }

  .brand small {
    display: none;
  }

  .hero h1,
  .page-hero h1,
  .article-header h1 {
    font-size: 36px;
  }

  .hero-lead,
  .article-subtitle,
  .page-hero p {
    font-size: 17px;
  }

  .section {
    padding-block: 48px;
  }

  .section-head,
  .category-row,
  .footer-bottom {
    display: block;
  }

  .category-grid,
  .card-grid,
  .card-grid.three,
  .toc ol {
    grid-template-columns: 1fr;
  }

  .content-card,
  .category-card,
  .side-panel,
  .editor-box {
    padding: 18px;
  }

  .editor-box {
    display: block;
  }

  .editor-box .avatar {
    margin-bottom: 12px;
  }
}
