/* 런BTI 유형 설명 페이지 공통 스타일 (tools/make-types.py 가 만든 페이지용)
   2026-11-13 피그마 '05 유형 설명 페이지' 최종본 기준 (모바일 390px) */
@font-face { font-family: 'Pretendard Variable'; src: url('/assets/fonts/PretendardVariable.woff2') format('woff2-variations'); font-weight: 45 920; font-display: swap; }
:root { --ink: #091e42; --ink2: #243757; --sub: #505f79; --line: #ebecf0; --g: #ff6259; --gbg: #fff1f0; --red: #ff3b30; }
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: #f4f5f7; color: var(--ink); font: 14px/22px 'Pretendard Variable', Pretendard, -apple-system, 'Apple SD Gothic Neo', 'Noto Sans KR', sans-serif; word-break: keep-all; -webkit-font-smoothing: antialiased; }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
h1, h2, h3, p, ul, ol, dl, figure { margin: 0; padding: 0; }
ul, ol { list-style: none; }

/* 상단 바 */
.tp-top { position: sticky; top: 0; z-index: 10; max-width: 720px; margin: 0 auto; display: flex; align-items: center; justify-content: space-between; height: 60px; padding: 0 16px; background: #170202; }
.tp-logo img { width: 74px; }
.tp-nav { display: flex; align-items: center; gap: 16px; font-size: 14px; line-height: 24px; font-weight: 600; }
.tp-nav a { color: #fff4e6; text-decoration: none; }
.tp-nav a[aria-current="page"] { color: #fff; font-size: 16px; font-weight: 700; }
.tp-nav .tp-cta-sm { padding: 8px 12px; border-radius: 8px; background: var(--red); color: #fff; }

/* 본문 */
.tp { max-width: 720px; margin: 0 auto; padding: 16px 16px 0; background: #fff; }
.crumb { color: var(--sub); font-size: 14px; line-height: 22px; }
.crumb a { text-decoration: none; }

/* 히어로 */
.tp-hero { margin: 25px -16px 0; padding: 24px 18px; background: linear-gradient(180deg, #fff 0, var(--gbg) 100%); text-align: center; }
.tag { display: inline-block; padding: 4px 10px; border-radius: 20px; background: var(--g); color: #fff; font-size: 14px; line-height: 22px; font-weight: 700; }
.tp-hero h1 { margin-top: 12px; font-size: 30px; line-height: 38px; font-weight: 800; letter-spacing: -.02em; }
.tp-hero h1 .code { color: var(--g); }
.hook { max-width: 520px; margin: 10px auto 0; font-size: 20px; line-height: 28px; font-weight: 700; }
.tags { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; margin-top: 12px; }
.tags li { padding: 4px 10px; border-radius: 20px; background: #fff; color: var(--g); font-size: 14px; line-height: 22px; font-weight: 700; box-shadow: 0 1px 3px rgba(9, 30, 66, .08); }
.cards { display: flex; justify-content: center; gap: 12px; margin-top: 24px; }
.cards figure { width: min(calc(50% - 6px), 240px); }
.cards img { width: 100%; filter: drop-shadow(0 8px 18px rgba(9, 30, 66, .12)); }
.cards figcaption { margin-top: 6px; color: var(--sub); font-size: 12px; line-height: 20px; }
.lead { max-width: 520px; margin: 20px auto 0; color: var(--sub); font-size: 14px; line-height: 22px; }

/* 섹션 공통 */
.block { margin-top: 25px; padding: 24px 4px 0; }
.block h2 { font-size: 22px; line-height: 28px; font-weight: 800; }
.sub { margin-top: 6px; color: var(--ink2); font-size: 14px; line-height: 24px; }
.block h2 + ul, .block h2 + ol, .block h2 + div, .block h2 + a, .sub + ul, .sub + div { margin-top: 12px; }

/* 공감 체크리스트 */
.checks { display: grid; gap: 8px; }
.checks label { display: flex; align-items: flex-start; gap: 10px; padding: 12px 16px; border: 1px solid var(--line); border-radius: 12px; cursor: pointer; transition: border-color .15s, background .15s; }
.checks input { appearance: none; -webkit-appearance: none; flex: none; width: 22px; height: 22px; margin: 0; border: 2px solid #c1c7d0; border-radius: 6px; display: grid; place-items: center; transition: background .15s, border-color .15s; }
.checks input:checked { background: var(--g); border-color: var(--g); }
.checks input:checked::after { content: ''; width: 6px; height: 11px; margin-top: -2px; border: solid #fff; border-width: 0 2.5px 2.5px 0; transform: rotate(45deg); }
.checks label:has(input:checked) { border-color: var(--g); background: var(--gbg); }
.checks input:focus-visible { outline: 2px solid var(--g); outline-offset: 2px; }
.check-result { margin-top: 12px; padding: 12px; border-radius: 12px; background: #f7f8fa; color: var(--ink2); text-align: center; font-size: 16px; line-height: 28px; font-weight: 700; }
.check-result.is-full { background: var(--g); color: #fff; }

/* 러닝 밖에서도 */
.daily { display: grid; gap: 8px; }
.daily li { position: relative; padding: 12px 16px 12px 32px; border-radius: 12px; background: #f7f8fa; }
.daily li::before { content: '✓'; position: absolute; left: 14px; top: 12px; color: var(--g); font-weight: 800; }

/* 4글자로 읽는 */
.axes { display: grid; gap: 12px; }
.axis { display: flex; gap: 16px; padding: 16px; border-radius: 14px; background: #f7f8fa; }
.axis__letter { flex: none; width: 34px; height: 34px; display: grid; place-items: center; border-radius: 10px; background: var(--g); color: #fff; font-size: 22px; line-height: 1; font-weight: 800; }
.axis__name { font-size: 16px; line-height: 28px; font-weight: 700; }
.axis__name span { color: var(--sub); font-size: 13px; font-weight: 500; }
.axis__text { color: var(--ink2); }

/* 러닝 과학 */
.scis { display: grid; gap: 12px; }
.sci { padding: 16px; border-radius: 16px; background: #f7f8fa; }
.sci__k { color: var(--ink2); font-size: 14px; line-height: 22px; font-weight: 800; }
.sci h3 { margin-top: 4px; font-size: 16px; line-height: 24px; font-weight: 700; }
.sci p:not(.sci__k) { margin-top: 6px; color: var(--ink2); }
.note { margin-top: 10px; color: var(--ink2); font-size: 12px; line-height: 20px; }

/* 무기와 약점: 두 칸 나란히 */
.pw { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; align-items: stretch; }
.pw__box { padding: 16px; border-radius: 16px; background: #f7f8fa; }
.pw__box--good { background: var(--gbg); }
.pw__t { font-size: 16px; line-height: 28px; font-weight: 800; }
.pw__box ul { margin-top: 6px; }
.pw__box li { position: relative; padding-left: 16px; }
.pw__box li + li { margin-top: 6px; }
.pw__box li::before { content: ''; position: absolute; left: 0; top: 9px; width: 5px; height: 5px; border-radius: 50%; background: var(--g); }

/* 맞춤 러닝 처방 */
.rx { display: grid; gap: 12px; }
.rx li { display: flex; gap: 12px; padding: 16px; border: 1px solid var(--line); border-radius: 14px; }
.rx__n { flex: none; color: var(--g); font-size: 20px; line-height: 28px; font-weight: 800; }
.rx b { display: block; font-size: 16px; line-height: 28px; }
.rx p { color: var(--ink2); }
.extra { display: grid; gap: 8px; margin-top: 12px; }
.extra div { display: flex; gap: 12px; padding: 12px 16px; border-radius: 12px; background: #f7f8fa; }
.extra dt { flex: none; width: 92px; color: var(--sub); font-weight: 700; }
.extra dd { margin: 0; }

/* 찰떡 러닝 메이트 */
.mate { text-align: left; }
.mate__card { display: flex; align-items: center; gap: 16px; padding: 12px; border: 1px solid var(--line); border-radius: 16px; text-decoration: none; }
.mate__card img { flex: none; width: 72px; border-radius: 12px; }
.mate__card b { display: block; color: var(--ink); font-size: 16px; line-height: 24px; }
.mate__card span { color: var(--sub); line-height: 24px; }
.mate__more { display: inline-flex; align-items: center; margin-top: 12px; padding: 8px 16px; border: 1px solid #dfe2e6; border-radius: 999px; color: var(--sub); font-size: 12px; line-height: 16px; font-weight: 700; text-decoration: none; }

/* 공유 박스 */
.share { margin-top: 57px; padding: 24px 20px; border-radius: 18px; background: var(--g); color: #fff; text-align: center; }
.share__q { font-size: 16px; line-height: 24px; font-weight: 600; }
.share__outro { margin-top: 4px; font-size: 20px; line-height: 28px; font-weight: 700; }
.share .btn--light { display: inline-flex; align-items: center; justify-content: center; gap: 6px; width: 100%; max-width: 302px; min-height: 52px; margin-top: 17px; border: 0; border-radius: 12px; background: #fff; color: var(--ink); font: inherit; font-size: 16px; font-weight: 700; cursor: pointer; }
.share__ico { flex: none; }
.share__toast { font-size: 13px; }
.share__toast:not(:empty) { margin-top: 8px; }

/* 같은 그룹 러너 */
.minis { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.mini { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 10px 8px; border-radius: 14px; background: #fff; text-decoration: none; text-align: center; }
.mini img { width: 64px; border-radius: 10px; }
.mini b { display: block; color: var(--g); font-size: 14px; }
.mini span { font-size: 13px; font-weight: 600; }

/* 하단 테스트 CTA + 캐릭터 (피그마 Test_Btn + character_img) */
.tp-cta { margin-top: 47px; padding: 19px 16px 0; text-align: center; }
.tp-cta p { font-size: 20px; line-height: 28px; font-weight: 700; color: var(--ink); }
.btn { display: inline-block; padding: 14px 24px; border-radius: 12px; background: var(--red); color: #fff; font-weight: 700; text-decoration: none; }
.tp-cta .btn { display: flex; align-items: center; justify-content: center; width: 100%; min-height: 60px; margin-top: 13px; padding: 6px 16px; border: 1.4px solid #ff9494; font-size: 20px; line-height: 24px; box-shadow: 0 2px 10px rgba(255, 59, 48, .18); }
.tp-cta__chars { display: block; width: 100%; max-width: 338px; height: auto; margin: 47px auto 0; }

/* 푸터 */
.tp-foot { max-width: 720px; margin: 0 auto; padding: 20px 16px 40px; color: #8c96a5; font-size: 12px; line-height: 20.4px; text-align: center; }
.tp-foot p + p { margin-top: 6px; }

/* ===== 유형 도감 (/types/) ===== */
.is-index .tp-hero { background: linear-gradient(180deg, #fff 0, #ffd8d6 100%); }
.is-index .tag { background: var(--red); }
.is-index .tp-hero h1 { font-weight: 700; letter-spacing: 0; }
.is-index .lead { margin-top: 12px; color: #354764; font-size: 16px; line-height: 24px; }
.is-index .block { margin-top: 0; }
.is-index .block:first-of-type { margin-top: 17px; }
.is-index .block h2 { font-size: 20px; font-weight: 700; }
.axes2 { display: grid; gap: 12px; }
.axis2 { padding: 16px; border-radius: 14px; background: #f7f8fa; font-size: 15px; line-height: 25.5px; }
.axis2__t { color: var(--g); font-size: 14px; line-height: 22px; font-weight: 700; }
.axis2 b { font-size: 14px; }
.grp h2 { display: flex; align-items: center; gap: 8px; }
.grp .dot { flex: none; width: 10px; height: 10px; border-radius: 50%; background: var(--g); }
.grp__desc { margin-top: 12px; color: var(--ink2); }
.grp .grp__desc + .tgrid { margin-top: 12px; }
.tgrid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.tcard { display: flex; flex-direction: column; gap: 2px; height: 100%; padding: 8px 8px 12px; border-radius: 14px; background: var(--gbg); text-decoration: none; }
.tcard img { width: 100%; height: auto; aspect-ratio: 66 / 63; object-fit: cover; border-radius: 10px; margin-bottom: 6px; }
.tcard b { color: var(--g); font-size: 14px; line-height: 22px; }
.tcard span { font-size: 14px; line-height: 24px; font-weight: 700; }
.is-index .tp-cta { margin-top: 22px; }
.is-index .tp-cta__chars { margin-top: 22px; }

/* ===== 결과 화면 아래 붙여 보기 (?embed=1) ===== */
.is-embed .tp-top, .is-embed .crumb { display: none; }
.is-embed .tp-hero { margin-top: 0; }
.is-embed body { overflow: hidden; }
