:root {
  --ink: #172033;
  --muted: #627087;
  --line: #dfe5ee;
  --soft: #f5f7fb;
  --paper: #fff;
  --brand: #3457d5;
  --brand-dark: #213caa;
  --accent: #ff7052;
  --warning: #a54900;
  --radius: 18px;
  --shadow: 0 12px 32px rgba(31, 48, 83, .08);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: Pretendard, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Noto Sans KR", sans-serif;
  line-height: 1.65;
  overflow-wrap: anywhere;
}
a { color: inherit; text-underline-offset: .18em; }
img { max-width: 100%; height: auto; }
button, input, select { font: inherit; }
:focus-visible { outline: 3px solid #f7a632; outline-offset: 3px; }
.shell { width: min(1120px, calc(100% - 40px)); margin-inline: auto; }
.narrow { width: min(780px, calc(100% - 40px)); margin-inline: auto; }
.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;
}
.skip-link {
  position: fixed; z-index: 100; top: 12px; left: 12px; padding: 10px 14px;
  border-radius: 10px; background: var(--ink); color: #fff; transform: translateY(-160%);
}
.skip-link:focus { transform: translateY(0); }

.site-header {
  position: sticky; z-index: 20; top: 0; border-bottom: 1px solid rgba(223,229,238,.9);
  background: rgba(255,255,255,.94); backdrop-filter: blur(14px);
}
.header-inner { min-height: 72px; display: flex; align-items: center; justify-content: space-between; gap: 28px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); font-size: 1.25rem; font-weight: 850; text-decoration: none; letter-spacing: -.04em; }
.brand-mark { display: inline-grid; width: 36px; height: 36px; place-items: center; border-radius: 11px; background: linear-gradient(145deg, var(--brand), #6885ee); color: white; box-shadow: 0 8px 18px rgba(52,87,213,.24); }
.primary-nav { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; }
.primary-nav a { padding: 9px 12px; border-radius: 9px; color: #435069; font-size: .94rem; font-weight: 700; text-decoration: none; }
.primary-nav a:hover, .primary-nav a[aria-current="page"] { color: var(--brand-dark); background: #edf1ff; }

.hero { padding: 82px 0 64px; background: radial-gradient(circle at 82% 15%, #dfe7ff 0, transparent 30%), linear-gradient(180deg, #f6f8ff 0%, #fff 100%); }
.eyebrow { margin: 0 0 12px; color: var(--brand); font-size: .84rem; font-weight: 850; letter-spacing: .1em; text-transform: uppercase; }
.hero h1, .page-hero h1 { max-width: 850px; margin: 0; font-size: clamp(2.25rem, 6vw, 4.25rem); line-height: 1.08; letter-spacing: -.065em; }
.hero .lead, .page-hero .lead { max-width: 720px; margin: 22px 0 0; color: #536078; font-size: clamp(1.03rem, 2vw, 1.24rem); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 28px; }
.button { display: inline-flex; min-height: 46px; align-items: center; justify-content: center; padding: 10px 17px; border: 1px solid transparent; border-radius: 12px; background: var(--brand); color: #fff; font-weight: 800; text-decoration: none; }
.button:hover { background: var(--brand-dark); }
.button.hot { background: #d92d20; box-shadow: 0 8px 20px rgba(217, 45, 32, .22); }
.button.hot:hover { background: #b42318; }
.button.secondary { border-color: var(--line); background: #fff; color: var(--ink); }
.button.secondary:hover { border-color: #aeb9cc; background: var(--soft); }
.proof-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-top: 48px; }
.proof-item { padding: 18px; border: 1px solid #e4e9f3; border-radius: 14px; background: rgba(255,255,255,.75); }
.proof-item strong { display: block; margin-bottom: 3px; }
.proof-item span { color: var(--muted); font-size: .91rem; }

.section { padding: 70px 0; }
.section.soft { background: var(--soft); }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 30px; margin-bottom: 28px; }
.section-heading h2 { margin: 0; font-size: clamp(1.65rem, 4vw, 2.45rem); line-height: 1.18; letter-spacing: -.045em; }
.section-heading p { max-width: 560px; margin: 8px 0 0; color: var(--muted); }
.text-link { color: var(--brand-dark); font-weight: 800; text-decoration: none; }
.text-link:hover { text-decoration: underline; }

.category-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.category-card { display: flex; min-width: 0; flex-direction: column; padding: 24px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; box-shadow: var(--shadow); }
.category-card-head { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 14px; align-items: start; }
.category-card-head h2 { margin: 0; font-size: 1.2rem; letter-spacing: -.025em; }
.category-card-head h2 a { text-decoration: none; }
.category-card-head h2 a:hover { color: var(--brand); }
.category-card-head p { margin: 5px 0 0; color: var(--muted); font-size: .9rem; }
.category-initial { display: grid; width: 44px; height: 44px; flex: none; place-items: center; border-radius: 13px; background: #edf1ff; color: var(--brand-dark); font-weight: 900; }
.preview-links { display: grid; gap: 1px; margin: 20px 0; padding: 0; list-style: none; border-block: 1px solid #edf0f5; }
.preview-links li + li { border-top: 1px solid #edf0f5; }
.preview-links a { display: flex; min-height: 48px; align-items: center; justify-content: space-between; gap: 14px; padding: 10px 2px; text-decoration: none; }
.preview-links a:hover span { color: var(--brand); }
.preview-links span { min-width: 0; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.preview-links small { max-width: 42%; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.empty-note { color: var(--muted); }
.category-card > .text-link { margin-top: auto; }

.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; counter-reset: step; }
.step { position: relative; padding: 26px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.step::before { counter-increment: step; content: counter(step); display: grid; width: 34px; height: 34px; place-items: center; margin-bottom: 18px; border-radius: 50%; background: var(--ink); color: #fff; font-weight: 850; }
.step h3 { margin: 0 0 8px; font-size: 1.08rem; }
.step p { margin: 0; color: var(--muted); }

.notice { padding: 22px 24px; border: 1px solid #f1d9b7; border-left: 4px solid #e68a19; border-radius: 14px; background: #fffaf2; }
.notice strong { display: block; margin-bottom: 4px; }
.notice p { margin: 0; color: #71512c; }
.notice + .notice { margin-top: 14px; }
.notice.danger { border-color: #efc8c8; border-left-color: #c83d3d; background: #fff7f7; }
.notice.danger p { color: #733838; }
.notice-gap { margin-top: 24px; }
.section-link { margin: 24px 0 0; }

.page-hero { padding: 54px 0 38px; background: linear-gradient(180deg, #f6f8ff, #fff); }
.page-hero h1 { max-width: 900px; font-size: clamp(2rem, 5vw, 3.35rem); }
.breadcrumbs { margin-bottom: 22px; color: var(--muted); font-size: .9rem; }
.breadcrumbs ol { display: flex; flex-wrap: wrap; gap: 7px; margin: 0; padding: 0; list-style: none; }
.breadcrumbs li:not(:last-child)::after { content: "/"; margin-left: 7px; color: #9da8ba; }
.breadcrumbs a { color: var(--muted); }
.meta-row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 20px; }
.meta-chip { display: inline-flex; align-items: center; min-height: 32px; padding: 4px 10px; border: 1px solid var(--line); border-radius: 999px; background: #fff; color: #526078; font-size: .84rem; font-weight: 700; }

.content-layout { display: grid; grid-template-columns: minmax(0, 1fr) 270px; gap: 38px; align-items: start; }
.prose { font-size: 1.02rem; }
.prose h2 { margin: 2.2em 0 .65em; font-size: clamp(1.4rem, 3vw, 1.8rem); line-height: 1.3; letter-spacing: -.035em; }
.prose h2:first-child { margin-top: 0; }
.prose h3 { margin: 1.7em 0 .5em; font-size: 1.15rem; }
.prose p, .prose li { color: #39465a; }
.prose ul, .prose ol { padding-left: 1.35em; }
.prose li + li { margin-top: .5em; }
.prose .lead-box { padding: 24px; border-radius: var(--radius); background: #f2f5ff; color: #2f3e63; }
.prose table { width: 100%; border-collapse: collapse; font-size: .93rem; }
.prose th, .prose td { padding: 12px; border: 1px solid var(--line); text-align: left; vertical-align: top; }
.prose th { background: var(--soft); }
.side-nav { position: sticky; top: 96px; padding: 20px; border: 1px solid var(--line); border-radius: 15px; }
.side-nav strong { display: block; margin-bottom: 9px; }
.side-nav a { display: block; padding: 7px 0; color: var(--muted); font-size: .92rem; }

.category-list { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.category-tile { display: flex; min-height: 138px; flex-direction: column; padding: 20px; border: 1px solid var(--line); border-radius: 15px; text-decoration: none; }
.category-tile:hover { border-color: #9eb0ec; box-shadow: var(--shadow); }
.category-tile strong { font-size: 1.05rem; }
.category-tile p { margin: 6px 0 12px; color: var(--muted); font-size: .88rem; }
.category-tile small { margin-top: auto; color: var(--brand); font-weight: 750; }
.restricted-grid { margin-top: 22px; }

.search-panel { margin: 0 0 24px; padding: 18px; border: 1px solid var(--line); border-radius: 15px; background: var(--soft); }
.filter-form { display: grid; grid-template-columns: minmax(160px, 1fr) 170px auto; gap: 10px; }
.field label { display: block; margin-bottom: 5px; font-size: .83rem; font-weight: 800; }
.field input, .field select { width: 100%; min-height: 46px; padding: 10px 12px; border: 1px solid #bdc7d7; border-radius: 10px; background: #fff; color: var(--ink); }
.filter-form .button { align-self: end; border: 0; cursor: pointer; }
.result-summary { margin: 0 0 16px; color: var(--muted); font-size: .92rem; }
.link-list { display: grid; gap: 10px; }
.link-card { display: grid; grid-template-columns: 40px minmax(0, 1fr) auto; gap: 15px; align-items: start; padding: 20px; border: 1px solid var(--line); border-radius: 15px; background: #fff; }
.link-card:hover { border-color: #afbbe0; box-shadow: 0 8px 24px rgba(31,48,83,.07); }
.link-position { display: grid; width: 36px; height: 36px; place-items: center; border-radius: 11px; background: var(--soft); color: #66728a; font-weight: 850; }
.link-copy h2 { margin: 0; font-size: 1.08rem; line-height: 1.4; }
.link-copy h2 a { text-decoration: none; }
.link-copy h2 a:hover { color: var(--brand); text-decoration: underline; }
.host { margin: 4px 0 0; color: var(--muted); font-size: .84rem; }
.link-description { margin: 8px 0 0; color: #46536a; font-size: .94rem; }
.sponsor-chip, .warning-chip { display: inline-flex; align-items: center; width: max-content; padding: 3px 8px; border-radius: 999px; font-size: .72rem; font-weight: 850; }
.sponsor-chip { background: #fff0de; color: #92500d; }
.warning-chip { margin-left: 5px; background: #fff0e8; color: var(--warning); }
.empty-state { padding: 44px 20px; border: 1px dashed #bdc7d7; border-radius: 15px; text-align: center; color: var(--muted); }
.category-context { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin: 24px 0; }
.context-box { padding: 18px; border-radius: 14px; background: var(--soft); }
.context-box strong { display: block; margin-bottom: 5px; }
.context-box p { margin: 0; color: var(--muted); font-size: .92rem; }

.cta { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 30px; border-radius: var(--radius); background: var(--ink); color: #fff; }
.cta h2 { margin: 0; font-size: 1.45rem; }
.cta p { margin: 6px 0 0; color: #cbd3e2; }
.cta .button { flex: none; background: #fff; color: var(--ink); }

.site-footer { margin-top: 60px; padding: 50px 0 22px; border-top: 1px solid var(--line); background: #111827; color: #eef2fb; }
.footer-grid { display: grid; grid-template-columns: 1.7fr 1fr 1fr; gap: 42px; }
.footer-brand { color: #fff; }
.footer-grid p { max-width: 460px; color: #adb8ca; font-size: .91rem; }
.footer-grid nav strong { display: block; margin-bottom: 10px; }
.footer-grid nav a { display: block; padding: 5px 0; color: #bac4d5; font-size: .9rem; }
.footer-bottom { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-top: 34px; padding-top: 18px; border-top: 1px solid #2b3547; color: #929eb2; font-size: .83rem; }
.footer-bottom p { margin: 0; }
.footer-analytics { display: flex; min-width: 200px; min-height: 30px; align-items: center; justify-content: flex-end; }
.footer-analytics img, .footer-analytics canvas { display: block; max-width: 100%; }

@media (max-width: 820px) {
  .header-inner { min-height: 64px; align-items: flex-start; flex-direction: column; padding-block: 12px; gap: 8px; }
  .site-header { position: static; }
  .primary-nav { width: 100%; overflow-x: auto; flex-wrap: nowrap; padding-bottom: 3px; }
  .primary-nav a { white-space: nowrap; }
  .hero { padding: 58px 0 45px; }
  .proof-row, .steps, .category-list { grid-template-columns: 1fr 1fr; }
  .content-layout { grid-template-columns: 1fr; }
  .side-nav { position: static; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-grid > div:first-child { grid-column: 1 / -1; }
}

@media (max-width: 600px) {
  .shell, .narrow { width: min(100% - 28px, 1120px); }
  .hero h1, .page-hero h1 { letter-spacing: -.05em; }
  .proof-row, .steps, .category-grid, .category-list, .category-context { grid-template-columns: 1fr; }
  .section { padding: 48px 0; }
  .section-heading { align-items: start; flex-direction: column; gap: 10px; }
  .category-card { padding: 19px; }
  .filter-form { grid-template-columns: 1fr; }
  .link-card { grid-template-columns: 34px minmax(0, 1fr); padding: 16px; }
  .link-position { width: 32px; height: 32px; }
  .sponsor-chip { grid-column: 2; }
  .cta { align-items: stretch; flex-direction: column; }
  .footer-grid { grid-template-columns: 1fr; }
  .footer-grid > div:first-child { grid-column: auto; }
  .footer-bottom { align-items: flex-start; flex-direction: column; }
  .footer-analytics { justify-content: flex-start; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; animation: none !important; }
}

@media print {
  .site-header, .site-footer, .hero-actions, .search-panel, .cta { display: none; }
  body { color: #000; }
  a { text-decoration: none; }
}
