/* 니아랩 사이트 공통 스타일: 게임과 같은 글꼴·색·굵은 테두리 */
:root {
  --paper: #F5F9FC; --grid: #DCE7F2; --ink: #1E2A3A; --muted: #56677C; --card: #FFFFFF;
  --fox: #F08A24; --fox-deep: #C8640E; --muzzle: #FFF1E2;
  --yellow: #FFD43B; --green: #2F9E44; --green-soft: #D3F9D8; --blue: #5CB3F8; --sea: #7CC8F0;
  --display: 'Jua', 'Apple SD Gothic Neo', 'Malgun Gothic', sans-serif;
  --body: 'Gowun Dodum', 'Apple SD Gothic Neo', 'Malgun Gothic', sans-serif;
  color-scheme: light;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; color: var(--ink); font-family: var(--body); font-size: 17px; line-height: 1.6;
  word-break: keep-all; overflow-wrap: anywhere; /* 한국어는 띄어쓰기 단위로만 줄바꿈 */
  background-color: var(--paper);
  background-image: linear-gradient(var(--grid) 1px, transparent 1px), linear-gradient(90deg, var(--grid) 1px, transparent 1px);
  background-size: 26px 26px;
}
a { color: inherit; }
img, svg { display: block; }
.wrap { width: 100%; max-width: 1040px; margin: 0 auto; padding: 0 16px; }

/* 머리줄 */
.top { padding: 14px 0; }
.top .wrap { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.brand svg { width: 44px; height: 44px; }
.brand b { font-family: var(--display); font-weight: normal; font-size: 26px; line-height: 1; }
.brand small { display: block; font-size: 13px; color: var(--muted); letter-spacing: .04em; }
.nav { display: flex; gap: 8px; }
.nav a { text-decoration: none; font-family: var(--display); font-size: 18px; padding: 6px 14px; border: 2px solid var(--ink); border-radius: 12px; background: var(--card); }
.nav a[aria-current="page"] { background: var(--yellow); }

/* 카드·버튼 */
.card { background: var(--card); border: 3px solid var(--ink); border-radius: 22px; box-shadow: 6px 6px 0 var(--ink); }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; cursor: pointer; text-decoration: none;
  font-family: var(--display); font-size: 22px; line-height: 1.2; color: var(--ink);
  padding: .5em 1.2em; background: var(--yellow); border: 3px solid var(--ink); border-radius: 16px; box-shadow: 4px 4px 0 var(--ink);
  transition: transform .15s, box-shadow .15s;
}
.btn.sub { background: var(--card); font-size: 19px; }
.btn.done { background: var(--green-soft); }
@media (hover: hover) { .btn:hover { transform: translate(-2px, -3px); box-shadow: 6px 7px 0 var(--ink); } }
.btn:active { transform: translate(3px, 3px); box-shadow: 1px 1px 0 var(--ink); }
.btn:focus-visible, .nav a:focus-visible { outline: 4px solid var(--blue); outline-offset: 3px; }
.chip { display: inline-block; font-family: var(--display); font-size: 17px; padding: 3px 12px; border: 2px solid var(--ink); border-radius: 999px; background: var(--card); white-space: nowrap; }

h1, h2, h3 { font-family: var(--display); font-weight: normal; line-height: 1.25; margin: 0; text-wrap: balance; }
p { margin: 0; }

/* 바닥줄 */
.foot { margin-top: 56px; padding: 22px 0 30px; border-top: 2px dashed var(--grid); color: var(--muted); font-size: 15px; }
.foot .wrap { display: flex; flex-wrap: wrap; gap: 8px 18px; justify-content: space-between; }
.foot a { color: var(--muted); }

@media (max-width: 600px) {
  body { font-size: 16px; }
  .brand b { font-size: 22px; }
  .brand svg { width: 38px; height: 38px; }
  .nav a { font-size: 16px; padding: 5px 10px; }
  .btn { font-size: 20px; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }
