/* noripik.com — 먹(ink), 한지(paper) and 금(gold). No client JS; every page shares these tokens. */
@font-face {
  font-family: 'NoriPik Sans';
  src: url('/fonts/noripik-sans.woff2') format('woff2');
  font-weight: 45 930;
  font-style: normal;
  font-display: swap;
}

/* Display serif (Noto Serif KR Bold subset, scripts/fonts/make_fonts.py) for titles only. */
@font-face {
  font-family: 'NoriPik Serif';
  src: url('/fonts/noripik-serif.woff2') format('woff2');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

:root {
  --paper: #f7f3ea;
  --paper-2: #efe8da;
  --card: #fffdf8;
  --ink: #1d2030;
  --ink-2: #2a2e44;
  --muted: #5c5a63;
  --line: #e3dac8;
  --gold: #c9a24a;
  --gold-2: #e2c47a;
  --gold-ink: #6b5214;
  --accent: #34528c;
  --wood: #4f7f5f;
  --fire: #c4573f;
  --earth: #b8913a;
  --metal: #8b8e98;
  --water: #34466e;
  --radius: 20px;
  --shadow: 0 1px 2px rgba(29, 32, 48, 0.05), 0 12px 32px rgba(29, 32, 48, 0.08);
  --serif: 'NoriPik Serif', 'Noto Serif KR', 'Nanum Myeongjo', 'AppleMyungjo', Batang, serif;
  font-family: 'NoriPik Sans', 'NoriPik Serif', 'Pretendard Variable', Pretendard, -apple-system, 'Apple SD Gothic Neo', 'Noto Sans KR', system-ui, sans-serif;
  color: var(--ink);
  background: var(--paper);
  -webkit-text-size-adjust: 100%;
  font-feature-settings: 'tnum' 0;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  line-height: 1.7;
  letter-spacing: -0.01em;
  word-break: keep-all;
  overflow-wrap: anywhere;
}

img {
  max-width: 100%;
}

a {
  color: var(--accent);
  text-underline-offset: 3px;
}

.skip {
  position: absolute;
  left: -999px;
}
.skip:focus {
  left: 8px;
  top: 8px;
  z-index: 10;
  background: #fff;
  padding: 8px;
}

/* ---------- layout ---------- */
.bar,
.wrap {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 20px;
}

main,
.draft {
  max-width: 760px;
  margin: 0 auto;
  padding: 0 20px;
}

main {
  padding-bottom: 56px;
}

main.wide {
  max-width: none;
  padding: 0;
}

/* ---------- header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 5;
  background: rgba(247, 243, 234, 0.92);
  backdrop-filter: saturate(1.4) blur(10px);
  -webkit-backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid rgba(29, 32, 48, 0.06);
}

.site-header .bar {
  display: flex;
  align-items: center;
  gap: 8px 20px;
  min-height: 60px;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 800;
  font-size: 17px;
  letter-spacing: -0.03em;
  color: var(--ink);
  text-decoration: none;
}

.logo img {
  width: 30px;
  height: 30px;
  border-radius: 9px;
}

.site-header nav {
  display: none;
  gap: 4px 22px;
}

.site-header nav a {
  color: var(--ink);
  text-decoration: none;
  font-size: 15px;
  font-weight: 600;
  opacity: 0.78;
}

.site-header nav a:hover {
  opacity: 1;
}

.pill {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  padding: 0 16px;
  border-radius: 999px;
  background: var(--ink);
  color: #f7f3ea;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
}

@media (min-width: 760px) {
  .site-header nav {
    display: flex;
  }
}

.draft {
  margin-top: 12px;
  background: #fff3c4;
  border-radius: 10px;
  padding: 8px 12px;
  font-size: 14px;
}

/* ---------- type ---------- */
h1 {
  font-family: var(--serif);
  font-size: 30px;
  line-height: 1.3;
  letter-spacing: -0.02em;
  font-weight: 700;
  margin: 28px 0 14px;
}

h2 {
  font-family: var(--serif);
  font-size: 23px;
  line-height: 1.35;
  letter-spacing: -0.02em;
  font-weight: 700;
  margin: 40px 0 12px;
}

h3 {
  letter-spacing: -0.02em;
}

/* ---------- buttons ---------- */
.btn,
.cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 52px;
  padding: 0 26px;
  border-radius: 999px;
  font-size: 16px;
  font-weight: 800;
  letter-spacing: -0.02em;
  text-decoration: none;
}

.cta {
  background: var(--ink);
  color: #f7f3ea;
}

.btn.gold {
  background: linear-gradient(180deg, var(--gold-2), var(--gold));
  color: var(--ink);
  box-shadow: 0 8px 24px rgba(201, 162, 74, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.5);
}

.btn.gold::after,
.cta::after {
  content: '→';
  font-weight: 700;
}

.btn.ghost {
  color: #f7f3ea;
  border: 1px solid rgba(247, 243, 234, 0.35);
}

/* ---------- home: hero (the drawn scene, characters in front, copy on the paper sky) ---------- */
.home-hero {
  position: relative;
  overflow: hidden;
  background: var(--paper);
}

.hero-bg {
  position: absolute;
  inset: 0;
  background: url('/art/hero/gap-1200.webp') center 70% / cover no-repeat;
}

.hero-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(247, 243, 234, 0.97) 0%,
    rgba(247, 243, 234, 0.9) 34%,
    rgba(247, 243, 234, 0.25) 56%,
    rgba(247, 243, 234, 0) 72%,
    rgba(247, 243, 234, 0.92) 94%,
    var(--paper) 100%
  );
}

.hero-grid {
  position: relative;
  display: grid;
  grid-template-areas: 'copy' 'stage' 'cta';
  padding-top: 28px;
  padding-bottom: 28px;
}

.hero-copy {
  grid-area: copy;
}

.hero-stage {
  grid-area: stage;
  position: relative;
  height: 330px;
  margin: 0;
}

.hero-cta {
  grid-area: cta;
  position: relative;
}

.eyebrow {
  display: inline-flex;
  margin: 0 0 14px;
  padding: 6px 12px;
  border-radius: 999px;
  background: var(--ink);
  color: var(--gold-2);
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0;
}

.home-hero h1 {
  margin: 0 0 12px;
  font-size: 40px;
  line-height: 1.2;
}

.hl {
  background: linear-gradient(180deg, transparent 56%, rgba(201, 162, 74, 0.38) 56%, rgba(201, 162, 74, 0.38) 88%, transparent 88%);
  padding: 0 0.05em;
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
}

.home-hero .lead {
  margin: 0;
  max-width: 26em;
  font-size: 16.5px;
  line-height: 1.7;
  color: #3b3d4c;
}

.hero-stage .spirit {
  position: absolute;
  left: 58%;
  bottom: 0;
  width: min(68%, 320px);
  height: auto;
  transform: translateX(-50%);
  animation: np-float 4.5s ease-in-out infinite;
  filter: drop-shadow(0 14px 18px rgba(29, 32, 48, 0.18));
}

.hero-stage .friend {
  position: absolute;
  left: 4%;
  bottom: 4px;
  width: min(32%, 150px);
  height: auto;
  filter: drop-shadow(0 10px 12px rgba(29, 32, 48, 0.16));
}

.hero-stage .bubble {
  top: 18px;
  left: 2%;
  animation: np-pop 0.6s cubic-bezier(0.2, 0.9, 0.3, 1.25) 0.25s both;
  transform-origin: 18% 100%;
}

.hero-tag {
  position: absolute;
  right: 0;
  bottom: 6px;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(255, 253, 248, 0.92);
  color: var(--muted);
  font-size: 11.5px;
  font-weight: 700;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 6px;
}

.hero-actions .btn {
  flex: 1 1 auto;
}

.fine {
  margin: 14px 0 0;
  font-size: 12.5px;
  color: var(--muted);
}

@keyframes np-float {
  0%,
  100% {
    transform: translate(-50%, 0);
  }
  50% {
    transform: translate(-50%, -8px);
  }
}

@keyframes np-pop {
  from {
    opacity: 0;
    transform: scale(0.86);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-stage .spirit,
  .hero-stage .bubble {
    animation: none;
  }
}

@media (min-width: 880px) {
  .hero-bg {
    background-position: 70% 60%;
  }
  .hero-bg::after {
    background: linear-gradient(90deg, rgba(247, 243, 234, 0.97) 0%, rgba(247, 243, 234, 0.9) 38%, rgba(247, 243, 234, 0.1) 62%, rgba(247, 243, 234, 0) 100%),
      linear-gradient(180deg, transparent 80%, var(--paper) 100%);
  }
  .hero-grid {
    grid-template-columns: 1fr 1fr;
    grid-template-areas: 'copy stage' 'cta stage';
    align-content: center;
    column-gap: 40px;
    min-height: 620px;
    padding-top: 56px;
    padding-bottom: 56px;
  }
  .hero-copy {
    align-self: end;
  }
  .hero-cta {
    align-self: start;
    margin-top: 22px;
  }
  .hero-stage {
    height: 540px;
  }
  .hero-stage .spirit {
    width: min(72%, 390px);
  }
  .hero-stage .friend {
    width: min(34%, 180px);
  }
  .home-hero h1 {
    font-size: 60px;
  }
  .home-hero .lead {
    font-size: 19px;
  }
  .hero-actions .btn {
    flex: 0 0 auto;
  }
  .hero-stage .bubble {
    font-size: 22px;
    top: 40px;
  }
}

/* ---------- webtoon cut (same look as the app) ---------- */
.toon {
  position: relative;
  margin: 0;
  background: var(--card);
  border: 3px solid var(--ink);
  border-radius: 22px;
  overflow: hidden;
  box-shadow: var(--shadow);
}

.home-hero .toon {
  border-color: #0f111b;
  box-shadow: 0 0 0 1px rgba(226, 196, 122, 0.5), 0 30px 60px rgba(0, 0, 0, 0.45);
  max-width: 460px;
  width: 100%;
  justify-self: center;
}

.stage {
  position: relative;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background-size: cover;
  background-position: center;
}

.stage::before {
  /* calmer sky where the bubble sits */
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(255, 252, 244, 0.62) 0%, rgba(255, 252, 244, 0.18) 34%, rgba(255, 252, 244, 0.06) 100%);
}

.bg-gap { background-image: url('/art/backgrounds/gap.webp'); }
.bg-eul { background-image: url('/art/backgrounds/eul.webp'); }
.bg-byeong { background-image: url('/art/backgrounds/byeong.webp'); }
.bg-jeong { background-image: url('/art/backgrounds/jeong.webp'); }
.bg-mu { background-image: url('/art/backgrounds/mu.webp'); }
.bg-gi { background-image: url('/art/backgrounds/gi.webp'); }
.bg-gyeong { background-image: url('/art/backgrounds/gyeong.webp'); }
.bg-sin { background-image: url('/art/backgrounds/sin.webp'); }
.bg-im { background-image: url('/art/backgrounds/im.webp'); }
.bg-gye { background-image: url('/art/backgrounds/gye.webp'); }

.stage .spirit {
  position: absolute;
  left: 54%;
  bottom: -3%;
  width: 74%;
  height: auto;
  transform: translateX(-50%);
}

.stage .friend {
  position: absolute;
  left: 2%;
  bottom: 1%;
  width: 34%;
  height: auto;
  z-index: 1;
}

.bubble {
  position: absolute;
  z-index: 2;
  top: 14px;
  left: 14px;
  max-width: 80%;
  margin: 0;
  padding: 12px 16px 13px;
  background: #fff;
  color: var(--ink);
  border: 3px solid var(--ink);
  border-radius: 20px;
  font-size: 18px;
  font-weight: 800;
  line-height: 1.4;
  letter-spacing: -0.03em;
  box-shadow: 0 6px 16px rgba(29, 32, 48, 0.18);
}

.bubble::after {
  content: '';
  position: absolute;
  left: 30px;
  bottom: -13px;
  width: 18px;
  height: 18px;
  background: #fff;
  border-right: 3px solid var(--ink);
  border-bottom: 3px solid var(--ink);
  transform: rotate(45deg) skew(8deg, 8deg);
}

.toon figcaption {
  padding: 12px 16px 14px;
  border-top: 3px solid var(--ink);
  font-size: 14px;
  font-weight: 700;
  color: var(--ink);
}

.toon-topic {
  position: absolute;
  z-index: 3;
  right: 12px;
  top: 12px;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--ink);
  color: var(--gold-2);
  font-size: 12px;
  font-weight: 800;
}

.toon .toon-topic + .stage .bubble {
  max-width: 66%;
}

@media (min-width: 880px) {
  .home-hero .bubble {
    font-size: 21px;
    top: 18px;
    left: 18px;
  }
}

/* ---------- home: bands ---------- */
.band {
  padding: 56px 0;
}

.band.paper2 {
  background: var(--paper-2);
}

.kicker {
  margin: 0 0 6px;
  color: var(--gold-ink);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.kicker::before {
  content: '';
  display: inline-block;
  width: 18px;
  height: 2px;
  margin-right: 8px;
  vertical-align: middle;
  background: var(--gold);
}

.band h2 {
  margin: 0 0 10px;
  font-size: 26px;
}

.section-lead {
  margin: 0 0 28px;
  max-width: 40em;
  color: var(--muted);
  font-size: 16px;
}

@media (min-width: 880px) {
  .band {
    padding: 88px 0;
  }
  .band h2 {
    font-size: 34px;
  }
  .section-lead {
    font-size: 17px;
  }
}

/* steps */
.steps {
  list-style: none;
  margin: 24px 0 0;
  padding: 0;
  display: grid;
  gap: 12px;
}

.steps li {
  display: grid;
  grid-template-columns: auto 1fr;
  column-gap: 14px;
  align-items: start;
  padding: 20px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.steps .num {
  grid-row: span 2;
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--ink);
  color: var(--gold-2);
  font-weight: 800;
}

.steps strong {
  font-size: 17px;
  letter-spacing: -0.03em;
}

.steps li > span:last-child {
  color: var(--muted);
  font-size: 15px;
  line-height: 1.6;
}

@media (min-width: 880px) {
  .steps {
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
  }
  .steps li {
    grid-template-columns: 1fr;
    row-gap: 10px;
    padding: 26px;
  }
  .steps .num {
    grid-row: auto;
  }
}

/* sample cuts: swipe on phones, three columns on wide screens */
.cuts {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 82%;
  gap: 14px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding: 4px 20px 18px;
  margin: 0 -20px;
  scrollbar-width: none;
}

.cuts::-webkit-scrollbar {
  display: none;
}

.cuts .toon {
  scroll-snap-align: center;
}

@media (min-width: 880px) {
  .cuts {
    grid-auto-flow: row;
    grid-template-columns: repeat(3, 1fr);
    overflow: visible;
    padding: 4px 0 0;
    margin: 0;
  }
}

/* ten spirits */
.spirit-row {
  list-style: none;
  margin: 0;
  padding: 4px 20px 18px;
  margin: 0 -20px;
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 40%;
  gap: 12px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
}

.spirit-row::-webkit-scrollbar {
  display: none;
}

.spirit-card {
  scroll-snap-align: start;
  display: grid;
  justify-items: center;
  gap: 2px;
  padding: 14px 10px 16px;
  background: var(--card);
  border: 1px solid var(--line);
  border-top: 4px solid var(--el, var(--gold));
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  color: var(--ink);
  text-decoration: none;
  text-align: center;
}

.spirit-card img {
  width: 108px;
  height: 108px;
}

.spirit-card strong {
  font-size: 15px;
  letter-spacing: -0.03em;
}

.spirit-card span {
  font-size: 13px;
  color: var(--muted);
}

.el-wood { --el: var(--wood); }
.el-fire { --el: var(--fire); }
.el-earth { --el: var(--earth); }
.el-metal { --el: var(--metal); }
.el-water { --el: var(--water); }

@media (min-width: 880px) {
  .spirit-row {
    grid-auto-flow: row;
    grid-template-columns: repeat(5, 1fr);
    overflow: visible;
    padding: 4px 0 0;
    margin: 0;
    gap: 16px;
  }
}

/* 60갑자 table */
.gapja {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 6px;
}

.gj {
  display: grid;
  justify-items: center;
  padding: 9px 2px 8px;
  background: var(--card);
  border: 1px solid var(--line);
  border-bottom: 3px solid var(--el, var(--line));
  border-radius: 12px;
  color: var(--ink);
  text-decoration: none;
  line-height: 1.25;
}

a.gj:hover {
  border-color: var(--el);
}

.gj strong {
  font-size: 15px;
  letter-spacing: -0.02em;
}

.gj span {
  font-size: 12px;
  color: var(--muted);
}

@media (min-width: 880px) {
  .gapja {
    grid-template-columns: repeat(10, 1fr);
    gap: 8px;
  }
}

.more-link {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  margin: 22px 0 0;
  font-weight: 700;
}

.more-link a {
  color: var(--ink);
}

/* trust */
.trust {
  list-style: none;
  margin: 24px 0 0;
  padding: 0;
  display: grid;
  gap: 12px;
}

.trust li {
  display: grid;
  gap: 6px;
  padding: 22px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.trust strong {
  font-size: 17px;
  letter-spacing: -0.03em;
}

.trust strong::before {
  content: '';
  display: inline-block;
  width: 8px;
  height: 8px;
  margin-right: 8px;
  border-radius: 50%;
  background: var(--gold);
  vertical-align: middle;
}

.trust span {
  color: var(--muted);
  font-size: 15px;
  line-height: 1.65;
}

@media (min-width: 880px) {
  .trust {
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
  }
}

/* closing call to action */
.cta-band {
  padding: 64px 0 72px;
  text-align: center;
  color: #f7f3ea;
  background:
    radial-gradient(600px 300px at 50% 0%, rgba(201, 162, 74, 0.25), transparent 60%),
    var(--ink);
}

.cta-band h2 {
  margin: 8px 0 8px;
  font-size: 28px;
  color: #fffaf0;
}

.cta-band p {
  margin: 0 0 24px;
  color: rgba(247, 243, 234, 0.72);
}

.cta-art {
  display: flex;
  justify-content: center;
}

.cta-art img {
  width: 76px;
  height: 76px;
  margin: 0 -8px;
}

@media (min-width: 880px) {
  .cta-band h2 {
    font-size: 38px;
  }
  .cta-art img {
    width: 104px;
    height: 104px;
  }
}

/* ---------- footer ---------- */
.site-footer {
  padding: 36px 0 44px;
  background: #161827;
  color: rgba(247, 243, 234, 0.6);
  font-size: 13px;
}

.footer-brand {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 10px;
  margin: 0 0 14px;
}

.footer-brand img {
  width: 26px;
  height: 26px;
  border-radius: 8px;
}

.footer-brand strong {
  color: #f7f3ea;
  font-size: 15px;
}

.site-footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 18px;
}

.site-footer nav a {
  color: rgba(247, 243, 234, 0.85);
  text-decoration: none;
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  font-weight: 600;
}

.dot {
  display: block;
  width: 72px;
  height: 72px;
  border-radius: 50%;
  border: 2px dashed var(--line);
}

/* ---------- encyclopedia ---------- */
.ilju-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(104px, 1fr));
  gap: 10px;
}

.ilju-card {
  display: grid;
  justify-items: center;
  gap: 2px;
  padding: 10px 6px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 14px;
  color: var(--ink);
  text-decoration: none;
  font-size: 14px;
  text-align: center;
}

.ilju-card .card-art {
  position: relative;
  width: 84px;
  height: 76px;
}

.ilju-card .card-art > img {
  width: 72px;
  height: 72px;
}

.ilju-card .card-friend {
  position: absolute;
  right: 0;
  bottom: 0;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: #fff;
  border: 3px solid var(--ring, var(--line));
  overflow: hidden;
}

.ilju-card .card-friend img {
  width: 100%;
  height: 100%;
}

.ilju-card.soon {
  opacity: 0.55;
}

.crumbs {
  font-size: 14px;
  color: var(--muted);
  margin-top: 12px;
}

.ilju-hero {
  display: flex;
  gap: 12px;
  align-items: center;
}

.ilju-hero .pair {
  position: relative;
  flex: none;
  width: 128px;
  height: 120px;
}

.ilju-hero .pair > img {
  width: 110px;
  height: 110px;
}

.ilju-hero .friend {
  position: absolute;
  right: 0;
  bottom: 0;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: #fff;
  border: 5px solid var(--ring, var(--line));
  overflow: hidden;
}

.ilju-hero .friend img {
  width: 100%;
  height: 100%;
}

/* Traditional stem colours: 甲乙 푸른, 丙丁 붉은, 戊己 노란, 庚辛 하얀, 壬癸 검은 */
.ring-blue { --ring: #3e7cc2; }
.ring-red { --ring: #e0574b; }
.ring-yellow { --ring: #e8b43a; }
.ring-white { --ring: #c9ced8; }
.ring-black { --ring: #2b2b3a; }

.ilju-hero h1 {
  margin: 0;
  font-size: 26px;
  word-break: keep-all;
}

@media (min-width: 600px) {
  .ilju-hero .pair {
    width: 176px;
    height: 160px;
  }
  .ilju-hero .pair > img {
    width: 150px;
    height: 150px;
  }
  .ilju-hero .friend {
    width: 76px;
    height: 76px;
  }
  .ilju-hero h1 {
    font-size: 32px;
  }
}

.facts {
  width: 100%;
  margin: 20px 0 8px;
  border-collapse: collapse;
  font-size: 15px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
}

.facts caption {
  text-align: left;
  font-weight: 700;
  padding: 0 0 8px;
}

.facts th,
.facts td {
  border-bottom: 1px solid var(--line);
  padding: 8px 10px;
  text-align: left;
  vertical-align: top;
}

.facts .nb {
  white-space: nowrap;
}

.facts th {
  width: 7.5em;
  color: var(--muted);
  font-weight: 600;
}

.prose {
  font-size: 17px;
}

.prose table {
  width: 100%;
  border-collapse: collapse;
  font-size: 15px;
}

.prose th,
.prose td {
  border-bottom: 1px solid var(--line);
  padding: 6px 4px;
  text-align: left;
}

.cta-box {
  margin: 28px 0;
  padding: 18px;
  background: #fff;
  border: 2px solid var(--ink);
  border-radius: 16px;
}

.cta-box {
  margin: 36px 0;
  padding: 22px;
  background: var(--ink);
  color: #f7f3ea;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.cta-box p {
  margin: 0 0 14px;
}

.cta-box .cta {
  background: linear-gradient(180deg, var(--gold-2), var(--gold));
  color: var(--ink);
}

/* Contact and report form (no client JS). */
.report-form {
  display: grid;
  gap: 12px;
  margin: 24px 0 32px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
}
.report-form fieldset {
  display: grid;
  gap: 6px;
  margin: 0;
  padding: 0;
  border: 0;
}
.report-form legend,
.report-form .field {
  font-weight: 700;
  margin-bottom: 4px;
}
.report-form .choice {
  display: flex;
  gap: 8px;
  align-items: center;
}
.report-form textarea {
  width: 100%;
  padding: 12px;
  font: inherit;
  color: inherit;
  border: 1px solid var(--line);
  border-radius: 12px;
  resize: vertical;
}
.report-form .hint {
  margin: 0;
  font-size: 0.9rem;
  color: var(--muted);
}
.report-form .hp {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}
.report-form button {
  justify-self: start;
  padding: 10px 24px;
  font: inherit;
  font-weight: 700;
  color: #fff;
  background: var(--accent);
  border: 0;
  border-radius: 999px;
  cursor: pointer;
}

/* ---------- encyclopedia article head: the spirit and friend on their drawn scene ---------- */
.ilju-head {
  margin: 8px 0 24px;
  background: var(--card);
  border: 3px solid var(--ink);
  border-radius: 24px;
  overflow: hidden;
  box-shadow: var(--shadow);
}

.ilju-head .scene {
  aspect-ratio: 16 / 10;
  background-position: center 62%;
}

.ilju-head .scene .spirit {
  width: 50%;
  left: 56%;
  bottom: -4%;
}

.ilju-head .scene .friend {
  width: 24%;
  left: 12%;
  bottom: 2%;
}

.ilju-title {
  padding: 16px 20px 18px;
  border-top: 3px solid var(--ink);
}

.ilju-title .kicker {
  margin-bottom: 4px;
}

.ilju-title h1 {
  margin: 0 0 2px;
  font-size: 28px;
}

.ilju-title p:last-child {
  margin: 0;
  color: var(--muted);
  font-weight: 600;
}

@media (min-width: 760px) {
  .ilju-title h1 {
    font-size: 36px;
  }
}

/* ---------- refinements: ghost-line button, steps, basics, 60갑자 header ---------- */
.btn.line {
  color: var(--ink);
  border: 1.5px solid var(--ink);
  background: rgba(255, 253, 248, 0.7);
}

.steps .num {
  display: block;
  background: none;
  width: auto;
  height: auto;
  white-space: nowrap;
  color: var(--gold);
  font-family: var(--serif);
  font-size: 30px;
  line-height: 1;
}

.steps .num::before {
  content: '0';
}

.band.ink {
  color: #f7f3ea;
  background:
    radial-gradient(640px 320px at 100% 0%, rgba(201, 162, 74, 0.2), transparent 60%),
    var(--ink);
}

.band.ink .kicker {
  color: var(--gold-2);
}

.band.ink h2 {
  color: #fffaf0;
}

.band.ink .more-link a {
  color: var(--gold-2);
}

.basics {
  margin: 24px 0 0;
  display: grid;
  gap: 1px;
  background: rgba(247, 243, 234, 0.14);
  border: 1px solid rgba(247, 243, 234, 0.14);
  border-radius: 20px;
  overflow: hidden;
}

.basics > div {
  padding: 20px;
  background: var(--ink);
}

.basics dt {
  margin-bottom: 6px;
  font-family: var(--serif);
  font-size: 19px;
  font-weight: 700;
  color: var(--gold-2);
}

.basics dd {
  margin: 0;
  color: rgba(247, 243, 234, 0.8);
  font-size: 15px;
  line-height: 1.7;
}

@media (min-width: 880px) {
  .basics {
    grid-template-columns: repeat(2, 1fr);
  }
  .basics > div {
    padding: 28px;
  }
}

.gapja-head {
  display: none;
}

@media (min-width: 880px) {
  .gapja-head {
    display: grid;
    grid-template-columns: repeat(10, 1fr);
    gap: 8px;
    margin-bottom: 8px;
    text-align: center;
  }
  .gapja-head span {
    padding: 6px 0;
    border-radius: 10px;
    font-family: var(--serif);
    font-size: 20px;
    font-weight: 700;
    color: #fff;
    background: var(--el);
  }
  .gapja-head small {
    margin-left: 4px;
    font-family: 'NoriPik Sans', sans-serif;
    font-size: 12px;
    font-weight: 700;
    opacity: 0.85;
  }
}

.gj span,
.spirit-card span,
.ilju-title h1,
.facts td {
  font-feature-settings: normal;
}

.gj span {
  font-family: var(--serif);
  font-size: 12.5px;
}

.spirit-card strong,
.trust strong,
.steps strong {
  font-family: var(--serif);
  font-weight: 700;
  letter-spacing: -0.01em;
}

/* ---------- brand seal (낙관): vermilion stamp beside the wordmark ---------- */
.seal {
  display: inline-grid;
  place-items: center;
  flex: none;
  width: 30px;
  height: 30px;
  border-radius: 8px;
  background: #b5402f;
  color: #fff8ec;
  font-family: var(--serif);
  font-size: 16px;
  font-weight: 700;
  line-height: 1;
  box-shadow: inset 0 0 0 2px #b5402f, inset 0 0 0 3.5px rgba(255, 248, 236, 0.55);
  transform: rotate(-5deg);
}

.footer-brand .seal {
  width: 34px;
  height: 34px;
  font-size: 18px;
}

/* ---------- 궁합 pairs and FAQ on encyclopedia articles ---------- */
.pairs,
.faq {
  margin: 40px 0;
}

.pairs > p {
  color: var(--muted);
}

.pair-cards {
  display: grid;
  gap: 12px;
  margin-top: 16px;
}

.pair-card {
  display: grid;
  gap: 6px;
  padding: 18px 20px;
  background: var(--card);
  border: 1px solid var(--line);
  border-left: 5px solid var(--wood);
  border-radius: 16px;
  color: var(--ink);
  text-decoration: none;
  box-shadow: var(--shadow);
  transition: transform 0.15s ease;
}

.pair-card + .pair-card {
  border-left-color: var(--fire);
}

.pair-card:hover {
  transform: translateY(-2px);
}

.pair-card strong {
  font-family: var(--serif);
  font-size: 20px;
}

.pair-card > span:last-child {
  color: var(--muted);
  font-size: 15px;
  line-height: 1.65;
}

.pair-tag {
  justify-self: start;
  padding: 2px 10px;
  border-radius: 999px;
  background: rgba(79, 127, 95, 0.12);
  color: #2f5a3d;
  font-size: 13px;
  font-weight: 800;
}

.pair-card + .pair-card .pair-tag {
  background: rgba(196, 87, 63, 0.12);
  color: #9a3a26;
}

@media (min-width: 600px) {
  .pair-cards {
    grid-template-columns: 1fr 1fr;
  }
}

.faq details {
  margin: 0 0 10px;
  padding: 0 18px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 14px;
}

.faq summary {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 0;
  font-weight: 700;
  cursor: pointer;
  list-style: none;
}

.faq summary::-webkit-details-marker {
  display: none;
}

.faq summary::before {
  content: 'Q';
  flex: none;
  display: inline-grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--ink);
  color: var(--gold-2);
  font-family: var(--serif);
  font-size: 14px;
}

.faq summary::after {
  content: '';
  flex: none;
  margin-left: auto;
  width: 8px;
  height: 8px;
  border-right: 2px solid var(--muted);
  border-bottom: 2px solid var(--muted);
  transform: rotate(45deg);
}

.faq details[open] summary::after {
  transform: rotate(-135deg);
}

.faq details[open] summary {
  border-bottom: 1px dashed var(--line);
}

.faq details p {
  margin: 12px 0 16px;
  padding-left: 36px;
  color: #3d3b45;
}

/* ---------- Coupang Partners banners ---------- */
/* Each spot is an empty box of the banner's size (no layout shift); /assets/slots.*.js adds the
   iframe only to spots shown on this screen. */
.only-wide {
  display: none;
}

.spot {
  margin: 40px auto;
  max-width: 340px;
}

.disclose {
  margin: 0 0 8px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
  text-align: left;
}

.disclose b {
  display: inline-block;
  margin-right: 6px;
  padding: 0 6px;
  border: 1px solid currentColor;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 800;
}

.spot-box {
  margin: 0 auto;
  max-width: 100%;
  overflow: hidden;
  border-radius: 12px;
  background: var(--card);
  box-shadow: inset 0 0 0 1px var(--line);
}

.spot-box iframe {
  display: block;
  border: 0;
}

.spot-336x280 { width: 336px; height: 280px; }
.spot-340x140 { width: 340px; height: 140px; }
.spot-300x600 { width: 300px; height: 600px; }

/* Small phones: the banner may use the page gutter. */
@media (max-width: 380px) {
  .spot.only-narrow {
    margin-left: -12px;
    margin-right: -12px;
  }
}

.spot-rail {
  margin: 0;
  max-width: 300px;
}

.side-rail {
  display: none;
}

/* Wide screens: the article keeps its reading width and the tall banner sits in its own column
   (it stays in view while scrolling but never covers the text). */
@media (min-width: 1120px) {
  .only-wide {
    display: block;
  }
  .only-narrow {
    display: none;
  }
  main.with-side {
    max-width: 1100px;
  }
  .article-grid {
    display: grid;
    grid-template-columns: minmax(0, 720px) 300px;
    gap: 40px;
    justify-content: center;
    align-items: start;
  }
  .side-rail {
    display: block;
    position: sticky;
    top: 84px;
  }
}

/* The browser blocks the banner host (an ad blocker): fold the spots away instead of empty boxes. */
.spots-off .spot,
.spots-off .side-rail {
  display: none !important;
}

.spots-off main.with-side {
  max-width: 760px;
}

@media (min-width: 1120px) {
  .spots-off .article-grid {
    display: block;
  }
}

/* ---------- 어울리는 소품 (Coupang partner links) ---------- */
.picks {
  margin: 40px 0;
  padding: 22px 20px 20px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 20px;
  box-shadow: var(--shadow);
}

.picks h2 {
  margin-top: 0;
}

.picks > p:not(.disclose) {
  margin: 0 0 14px;
  color: #3d3b45;
}

.pick-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}

.pick-list a {
  display: grid;
  gap: 2px;
  height: 100%;
  padding: 14px 16px;
  background: #fff;
  border: 1px solid var(--line);
  border-top: 4px solid var(--el);
  border-radius: 14px;
  color: var(--ink);
  text-decoration: none;
  transition: transform 0.15s ease;
}

.pick-list a:hover {
  transform: translateY(-2px);
}

.pick-list strong {
  font-size: 17px;
}

.pick-list span {
  color: var(--muted);
  font-size: 14px;
}

.pick-list em {
  margin-top: 6px;
  color: var(--gold-ink);
  font-size: 13px;
  font-style: normal;
  font-weight: 800;
}

.pick-list em::after {
  content: ' →';
}

/* Phones: one compact row per pick, the link label on the right. */
@media (max-width: 599px) {
  .pick-list a {
    grid-template-columns: 1fr auto;
    grid-template-areas: 'name go' 'note go';
    align-items: center;
    column-gap: 12px;
    padding: 12px 14px;
    border-top-width: 1px;
    border-left: 4px solid var(--el);
  }
  .pick-list strong { grid-area: name; }
  .pick-list span { grid-area: note; }
  .pick-list em { grid-area: go; margin: 0; }
}

@media (min-width: 600px) {
  .pick-list {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* Lighter body text on the ink band and a darker one on paper (WCAG AA). */
.band.ink .section-lead {
  color: rgba(247, 243, 234, 0.82);
}

/* ---------- blog section ---------- */
.blog-head {
  margin: 12px 0 28px;
}
.blog-head h1 {
  margin: 6px 0 10px;
}
.blog-grid {
  display: grid;
  gap: 16px;
  margin: 24px 0 36px;
}
.blog-card {
  display: block;
  padding: 22px 24px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--ink);
  text-decoration: none;
  box-shadow: var(--shadow);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.blog-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(29, 32, 48, 0.1);
}
.blog-card h2 {
  margin: 0 0 8px;
  font-size: 21px;
  color: var(--ink);
}
.blog-card .post-meta {
  margin: 0 0 10px;
  font-size: 13.5px;
  color: var(--muted);
}
.blog-card .post-desc {
  margin: 0 0 14px;
  color: #3d3b45;
  font-size: 15px;
  line-height: 1.65;
}
.blog-card .post-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
}
.blog-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.blog-tag {
  padding: 2px 9px;
  border-radius: 999px;
  background: rgba(201, 162, 74, 0.14);
  color: var(--gold-ink);
  font-size: 12px;
  font-weight: 700;
}
.blog-more {
  font-size: 14px;
  font-weight: 800;
  color: var(--accent);
}

/* post page */
.post-head {
  margin: 8px 0 24px;
  padding-bottom: 18px;
  border-bottom: 1px dashed var(--line);
}
.post-head .kicker {
  margin-bottom: 4px;
}
.post-head h1 {
  margin: 0 0 12px;
  font-size: 30px;
}
.post-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 14px;
  color: var(--muted);
  font-size: 13.5px;
}

/* related tools */
.tools-box {
  margin: 40px 0 28px;
  padding: 22px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.tools-box h2 {
  margin: 0 0 14px;
  font-size: 21px;
}
.tool-cards {
  display: grid;
  gap: 12px;
}
.tool-card {
  display: block;
  padding: 16px 18px;
  background: #fff;
  border: 1px solid var(--line);
  border-left: 4px solid var(--gold);
  border-radius: 14px;
  color: var(--ink);
  text-decoration: none;
  box-shadow: var(--shadow);
  transition: transform 0.15s ease;
}
.tool-card:hover {
  transform: translateY(-2px);
}
.tool-card strong {
  display: block;
  font-size: 16.5px;
  margin-bottom: 4px;
}
.tool-card span {
  display: block;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.5;
}

/* related posts */
.related-posts {
  margin: 36px 0;
}
.related-posts h2 {
  margin: 0 0 14px;
  font-size: 21px;
}
.related-grid {
  display: grid;
  gap: 12px;
}
