/* =========================================================================
   /big5 와 /big5/r/* 공통. 토큰은 site.css :root 에서만 가져온다.
   ========================================================================= */
.screen { display: none; }
.screen.on { display: block; animation: fadeUp .28s cubic-bezier(.2,.7,.3,1) both; }
.pad { padding: 0 var(--gutter); }

/* ---------- 소개 ---------- */
.intro { padding: 40px var(--gutter) 36px; }
.kicker { font-size: 13px; font-weight: 700; color: var(--accent); margin-bottom: 12px; }
.intro h1 { font-size: 30px; line-height: 1.3; font-weight: 800; letter-spacing: -.8px; }
.intro .lede { margin-top: 14px; font-size: 15px; color: var(--sub); line-height: 1.6; }
.cast { margin: 28px 0 6px; display: flex; justify-content: center; }
.cast img { width: 68px; height: 68px; margin: 0 -5px; display: block; }
.facts { margin: 22px 0 26px; display: grid; gap: 8px; padding: 0; list-style: none; }
.facts li { display: flex; gap: 10px; font-size: 14px; color: var(--sub); }
.facts li::before { content: ""; flex: 0 0 6px; height: 6px; margin-top: 8px; border-radius: 50%; background: var(--accent); }

/* ---------- 문항 ---------- */
.qhead {
  position: sticky; top: 0; z-index: 5; background: var(--bg);
  padding: 14px var(--gutter) 12px; border-bottom: 1px solid var(--hairline);
}
.qhead-top { display: flex; align-items: center; gap: 12px; margin-bottom: 11px; }
.icon-btn {
  appearance: none; background: none; border: 0; cursor: pointer;
  font-family: inherit; font-size: 14px; font-weight: 700; color: var(--sub); padding: 6px 2px; line-height: 1;
}
.qcount { font-size: 12.5px; font-weight: 700; color: var(--sub); margin-left: auto; }
.qcount b { color: var(--ink); }
.progress { height: 4px; background: var(--primary-soft); border-radius: 999px; overflow: hidden; }
.progress > i { display: block; height: 100%; background: var(--primary); border-radius: 999px; transition: width .32s cubic-bezier(.2,.7,.3,1); }
.qbody { padding: 44px var(--gutter) 28px; min-height: 58vh; display: flex; flex-direction: column; justify-content: center; }
.qhint { font-size: 12.5px; color: var(--muted); margin-bottom: 14px; }
.qtext { font-size: 22px; font-weight: 800; line-height: 1.42; letter-spacing: -.5px; min-height: 2.84em; }
.likert { margin-top: 34px; display: grid; grid-template-columns: repeat(5, 1fr); gap: 4px; align-items: start; }
.lk {
  appearance: none; cursor: pointer; background: none; border: 0; padding: 0;
  font-family: inherit; display: flex; flex-direction: column; align-items: center; gap: 9px;
  font-size: 11.5px; font-weight: 600; color: var(--muted); line-height: 1.3;
}
.lk i {
  display: grid; place-items: center; border-radius: 50%;
  border: 1.5px solid var(--line-strong); background: var(--paper);
  transition: border-color .14s ease, background .14s ease, transform .14s ease;
}
.lk:nth-child(1) i, .lk:nth-child(5) i { width: 52px; height: 52px; }
/* 원 크기가 달라도 라벨이 한 줄에 서도록 위아래 여백으로 52px 높이를 맞춘다 */
.lk:nth-child(2) i, .lk:nth-child(4) i { width: 44px; height: 44px; margin: 4px 0; }
.lk:nth-child(3) i { width: 36px; height: 36px; margin: 8px 0; }
.lk:hover i { border-color: var(--sub); }
.lk.sel { color: var(--ink); font-weight: 800; }
.lk.sel i { background: var(--primary); border-color: var(--primary); transform: scale(1.06); }
.lk.sel i::after { content: ""; width: 8px; height: 8px; border-radius: 50%; background: #fff; }
.qfoot { padding: 0 var(--gutter) calc(24px + env(safe-area-inset-bottom)); }

/* ---------- 로딩 ---------- */
.loading { padding: 120px var(--gutter); text-align: center; }
.loading h2 { margin-top: 22px; font-size: 18px; font-weight: 800; }

/* ---------- 결과 카드(= 이미지 저장 단위, card-renderer.js 와 같은 구성) ---------- */
.result { padding: 26px var(--gutter) 0; }
.sharecard {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--card-r);
  padding: 24px 20px 20px; box-shadow: var(--shadow); text-align: center;
}
.sc-label { font-size: 12.5px; font-weight: 700; color: var(--accent); }
/* 흰 배경 위에만 둔다 — 5·6·7 캐릭터는 테두리 광이 구워져 있다 */
.sc-art { display: block; width: 168px; height: 168px; margin: 8px auto 4px; }
.sc-nick { font-size: 26px; font-weight: 800; line-height: 1.3; letter-spacing: -.7px; }
.sc-line { margin-top: 8px; font-size: 14px; color: var(--sub); }
.sharecard .bars { margin-top: 20px; padding-top: 20px; border-top: 1px solid var(--hairline); text-align: left; }
.sc-note { margin-top: 16px; font-size: 11.5px; color: var(--muted); }
.sc-wm { margin-top: 8px; font-size: 11.5px; font-weight: 700; color: var(--sub); }
.nick-note { margin: 12px 4px 0; font-size: 12.5px; color: var(--muted); text-align: center; }

.share { margin-top: 18px; display: grid; grid-template-columns: repeat(auto-fit, minmax(0, 1fr)); gap: 8px; }
.share button {
  appearance: none; cursor: pointer; font-family: inherit;
  display: flex; flex-direction: column; align-items: center; gap: 7px;
  background: var(--paper); border: 1px solid var(--line-strong); border-radius: var(--r);
  padding: 13px 4px 11px; font-size: 12px; font-weight: 700; color: var(--ink);
  touch-action: manipulation;
  transition: transform .12s ease, background-color .12s ease, border-color .12s ease, color .12s ease;
}
/* 누름 반응. site.css 가 전역으로 -webkit-tap-highlight-color: transparent 를 걸어 브라우저 기본 반짝임이
   없으므로 여기서 직접 준다(없으면 눌렸는지 알 수 없다 — 2026-09-28 모바일 제보). */
.share button:active { transform: scale(.96); background: var(--soft); border-color: var(--ink); }
@media (hover: hover) { .share button:hover { border-color: var(--ink); } }
.share button:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
/* 동작이 끝났다는 표시(링크 복사 등) — 1.6초 뒤 원래대로 */
.share button.done { border-color: var(--mint); background: var(--mint-soft); color: var(--ink); }
.share button.done svg { stroke: var(--mint); }
.share svg { width: 22px; height: 22px; stroke: var(--ink); fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; transition: stroke .12s ease; }

.block { margin-top: 34px; }
.block h3 { font-size: 18px; font-weight: 800; }
.block .sub { margin-top: 6px; font-size: 13px; color: var(--sub); }
.flist { margin: 14px 0 0; padding: 0; list-style: none; display: grid; gap: 10px; }
.flist li { padding: 14px 16px; border-radius: var(--r); background: var(--soft); }
.fl-head { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; font-size: 14px; }
.fl-level { font-size: 12px; font-weight: 800; color: var(--sub); }
.fl-level.fl-2 { color: var(--accent); }
.flist p { margin-top: 5px; font-size: 13.5px; color: var(--sub); }
.source { margin-top: 12px; font-size: 11.5px; color: var(--muted); line-height: 1.6; }

/* ---------- 앱 소개 ---------- */
.steps { margin: 16px 0 0; padding: 0; list-style: none; display: grid; gap: 14px; counter-reset: s; }
.steps li { display: grid; grid-template-columns: 30px 1fr; gap: 12px; align-items: start; }
.steps li::before {
  counter-increment: s; content: counter(s);
  display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%;
  background: var(--accent-soft); color: var(--accent); font-size: 13px; font-weight: 800;
}
.steps b { display: block; font-size: 15px; }
.steps span { display: block; margin-top: 3px; font-size: 13.5px; color: var(--sub); }
.compare { margin-top: 18px; display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.compare div { border-radius: var(--r); padding: 13px 14px; font-size: 13px; color: var(--sub); }
.compare div:first-child { background: var(--soft); }
.compare div:last-child { background: var(--accent-soft); }
.compare b { display: block; font-size: 12px; color: var(--ink); margin-bottom: 4px; }
.notice { margin-top: 12px; font-size: 12.5px; color: var(--sub); }
.notice b { color: var(--ink); }

.cta-card { margin-top: 30px; }
.cta-card h3 { font-size: 16px; font-weight: 800; }
.cta-card .btn { margin-top: 16px; }
.retry { margin: 18px 0 8px; }

/* ---------- 공유받은 화면 ---------- */
.shared-head { padding: 30px var(--gutter) 0; text-align: center; }
.shared-head .kicker { margin-bottom: 4px; }

/* 이미지 저장 시트 — 인앱 브라우저(카카오톡 등)는 다운로드를 못 하니 이미지를 띄우고 길게 눌러 저장하게 한다. */
.img-sheet {
  position: fixed; inset: 0; z-index: 60;
  display: none; align-items: center; justify-content: center;
  padding: 24px var(--gutter);
  background: rgba(29, 29, 33, 0.84); /* 뒤 페이지 글자가 안내 문구와 겹쳐 읽히지 않게 충분히 어둡게 */
}
.img-sheet.on { display: flex; }
.img-sheet-body {
  width: 100%; max-width: 420px; max-height: 100%;
  display: flex; flex-direction: column; align-items: center; gap: 14px;
}
.img-sheet-hint { margin: 0; color: #fff; font-size: 15px; text-align: center; word-break: keep-all; }
.img-sheet-body img {
  display: block; width: 100%; height: auto; max-height: calc(100vh - 170px); object-fit: contain;
  border-radius: var(--r); background: var(--paper);
  -webkit-touch-callout: default; user-select: auto; /* 길게 누르기 메뉴를 막지 않는다 */
}
.img-sheet-close { min-width: 120px; background: var(--paper); }
