/* 아라엑스짐 운동(가칭) — '연구 근거로 짠 운동법' 화면 (#science)
   index.html :root 토큰만 써요 → 밝은·어두운 모드는 저절로 맞아요. 전역 .x · .btn · .k3d · .tap · .sronly · .pad 를 같이 써요.
   움직임 '적게': 접기 화살표 회전 없이 바로, 참고문헌 강조는 색만 바뀌어요. */
.sci { display: grid; gap: 18px; padding-bottom: 8px; }
.sci svg { flex: none; }
.sci p { overflow-wrap: anywhere; }

/* ---------- 머리 ---------- */
.sci-top { display: flex; align-items: center; gap: 10px; padding: 12px 14px 0; }
.sci-eb { font-weight: 800; color: var(--o-ink); font-size: 13px; letter-spacing: .04em; }
.sci-hd { padding: 0 14px; display: grid; gap: 6px; margin-top: -6px; }
.sci-hd h2 { margin: 0; font-size: 26px; font-weight: 900; line-height: 1.25; letter-spacing: -.01em; }
/* 부제 '점진적 과부하 연구를 바탕으로 짰어요': 한눈에 보이게 위 화살표와 함께 */
.sci-sub { margin: 2px 0 0; display: flex; align-items: center; gap: 8px; font-size: 16.5px; font-weight: 900; color: var(--o-ink); line-height: 1.4; }
.sci-subi { width: 28px; height: 28px; flex: none; border-radius: 50%; display: grid; place-items: center; background: var(--o); color: var(--on-o, #fff); }
.sci-subi svg { width: 17px; height: 17px; }
.sci-intro { margin: 4px 0 0; font-size: 14.5px; line-height: 1.7; color: var(--muted); }

/* ---------- 점진적 과부하 한눈에 (메뉴마다 무엇을 조금 더) ---------- */
.sci-po { margin: 0 14px; padding: 14px; border-radius: 20px; background: var(--o-tint); border: 2px solid color-mix(in srgb, var(--o) 40%, transparent); display: grid; gap: 10px; min-width: 0; }
.sci-po h3 { margin: 0; font-size: 17px; font-weight: 900; line-height: 1.4; color: var(--o-ink); }
.sci-pol { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.sci-pol li { display: grid; grid-template-columns: 36px minmax(0, 1fr); column-gap: 12px; row-gap: 6px; align-items: center; padding: 10px 12px; border-radius: 14px; background: var(--bg); }
.sci-pol .sci-ri { grid-row: 1 / span 2; align-self: start; }
.sci-pot { display: grid; gap: 1px; min-width: 0; }
.sci-pot b { font-size: 15px; font-weight: 900; line-height: 1.35; }
.sci-pot > span { font-size: 13.5px; line-height: 1.5; color: var(--muted); font-weight: 700; }
.sci-ex { justify-self: start; padding: 3px 10px; border-radius: 999px; background: var(--o-tint); color: var(--o-ink); font-size: 12.5px; font-weight: 800; line-height: 1.4; }
.sci-pof { margin: 0; font-size: 13px; line-height: 1.6; color: var(--ink); }

/* ---------- 마디 공통 ---------- */
.sci-sec { padding: 0 14px; display: grid; gap: 10px; min-width: 0; }
.sci-sec h3 { margin: 0; font-size: 18px; font-weight: 900; display: flex; align-items: center; gap: 8px; }
.sci-sec h3 svg { width: 20px; height: 20px; color: var(--o); }
.sci-lead { margin: 0; font-size: 13.5px; line-height: 1.6; color: var(--muted); }
.sci-sh { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.sci-sh .btn { width: auto; flex: none; }

/* 본문 속 [n] 단추: 글줄 높이는 그대로, 누르는 자리만 넓게 */
.sci-cite { position: relative; display: inline; margin: 0 1px; padding: 2px 4px; border: 0; border-radius: 6px; background: color-mix(in srgb, var(--o) 14%, transparent); color: var(--o-ink); font: 800 .8em/1 var(--f-num); vertical-align: 1px; cursor: pointer; white-space: nowrap; }
.sci-cite::after { content: ""; position: absolute; inset: -7px -1px; }
.sci-cite:hover { text-decoration: underline; text-underline-offset: 2px; }

/* 원칙 번호로 가는 작은 단추 */
.sci-pl { margin: 0 0 0 4px; padding: 4px 9px; border: 1px solid var(--line); border-radius: 999px; background: var(--bg); color: var(--o-ink); font-size: 12px; font-weight: 800; cursor: pointer; min-height: 28px; }
.sci-used { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 4px 0; font-size: 12px; color: var(--muted); font-weight: 700; }

/* ---------- 요약 카드 3개 ---------- */
.sci-cards { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.sci-card { display: grid; grid-template-columns: 40px minmax(0, 1fr); column-gap: 12px; row-gap: 4px; padding: 14px; border-radius: 20px; background: var(--paper); border: 2px solid var(--line); }
.sci-cn { grid-row: 1 / span 3; width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: var(--o-tint); color: var(--o-ink); box-shadow: inset 0 0 0 3px var(--o); font-weight: 900; font-size: 18px; }
.sci-card b { font-size: 16px; font-weight: 900; line-height: 1.35; padding-top: 2px; }
.sci-card p { margin: 0; font-size: 14px; line-height: 1.7; }
.sci-more { justify-self: start; display: inline-flex; align-items: center; gap: 2px; margin-top: 2px; padding: 6px 2px; border: 0; background: none; color: var(--o-ink); font-size: 13.5px; font-weight: 800; cursor: pointer; min-height: 32px; }
.sci-more svg { width: 15px; height: 15px; }

/* ---------- 우리 앱에는 ---------- */
.sci-rules { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.sci-rules li { display: grid; grid-template-columns: 36px minmax(0, 1fr); gap: 12px; padding: 12px; border-radius: 16px; background: var(--paper); border: 1px solid var(--line); }
.sci-ri { width: 36px; height: 36px; border-radius: 12px; display: grid; place-items: center; background: var(--o-tint); color: var(--o-ink); }
.sci-ri svg { width: 20px; height: 20px; }
.sci-rules b { font-size: 15px; font-weight: 900; line-height: 1.4; margin-right: 6px; }
.sci-rules p { margin: 4px 0 6px; font-size: 14px; line-height: 1.65; }
.sci-op { display: inline-block; vertical-align: 2px; padding: 2px 8px; border-radius: 999px; border: 1px dashed var(--line); color: var(--muted); font-size: 11px; font-weight: 800; white-space: nowrap; }

/* ---------- 원칙 펼치기 ---------- */
.sci-list { display: grid; gap: 8px; }
.sci-p { border-radius: 18px; background: var(--paper); border: 2px solid var(--line); scroll-margin-top: 76px; transition: border-color 200ms var(--e-std); }
.sci-p[open] { border-color: color-mix(in srgb, var(--o) 45%, var(--line)); }
.sci-p > summary, .sci-xr > summary { list-style: none; cursor: pointer; display: flex; align-items: center; gap: 12px; padding: 12px 14px; min-height: 56px; border-radius: 16px; font-weight: 900; font-size: 15.5px; line-height: 1.4; }
.sci-p > summary::-webkit-details-marker, .sci-xr > summary::-webkit-details-marker { display: none; }
.sci-p > summary::marker, .sci-xr > summary::marker { content: ""; }
.sci-pn { width: 32px; height: 32px; flex: none; border-radius: 50%; display: grid; place-items: center; background: var(--bg); color: var(--o-ink); box-shadow: inset 0 0 0 2px var(--o); font-size: 14px; font-weight: 900; }
.sci-pt { flex: 1; min-width: 0; }
.sci-chev { flex: none; margin-left: auto; width: 22px; height: 22px; display: grid; place-items: center; color: var(--muted); transition: transform 200ms var(--e-std); }
.sci-chev svg { width: 20px; height: 20px; }
.sci-p[open] > summary .sci-chev, .sci-xr[open] > summary .sci-chev { transform: rotate(180deg); }
.sci-pb { padding: 2px 16px 16px; border-top: 1px solid var(--line); margin: 0 2px; }
.sci-pb p { margin: 12px 0 0; font-size: 14.5px; line-height: 1.75; }

/* ---------- 측정 안내로 ---------- */
.sci-measure { margin: 0 14px; display: flex; align-items: center; gap: 12px; padding: 14px; border-radius: 18px; background: var(--o-tint); color: var(--o-ink); border: 2px solid color-mix(in srgb, var(--o) 40%, transparent); text-decoration: none; font-weight: 800; font-size: 14.5px; line-height: 1.55; }
.sci-measure > span:nth-child(2) { flex: 1; min-width: 0; }
.sci-measure > svg { width: 18px; height: 18px; }
.sci-mi { width: 38px; height: 38px; flex: none; border-radius: 50%; display: grid; place-items: center; background: var(--bg); }
.sci-mi svg { width: 22px; height: 22px; }

/* ---------- 참고문헌 ---------- */
.sci-cnt { margin: 0; font-size: 13px; font-weight: 800; }
.sci-cnt b { color: var(--o-ink); }
.sci-rl { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.sci-ref { display: grid; grid-template-columns: 40px minmax(0, 1fr); gap: 8px; padding: 12px 12px 10px; border-radius: 16px; background: var(--paper); border: 1px solid var(--line); scroll-margin: 90px 0; transition: background-color 300ms var(--e-std), box-shadow 300ms var(--e-std); }
.sci-ref.hit { background: var(--o-tint); box-shadow: inset 0 0 0 2px var(--o); }
.sci-rn { font-weight: 900; font-size: 14px; color: var(--o-ink); padding-top: 1px; }
.sci-rb { min-width: 0; }
.sci-r1 { margin: 0; font-size: 14px; line-height: 1.6; font-weight: 700; }
.sci-rc { margin: 6px 0 0; font-size: 12px; line-height: 1.5; color: var(--muted); word-break: normal; overflow-wrap: anywhere; }
.sci-ra { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; margin-top: 8px; }
.sci-ra a { display: inline-flex; align-items: center; gap: 4px; min-height: 30px; color: var(--o-ink); font-size: 13px; font-weight: 800; text-decoration: underline; text-underline-offset: 3px; }
.sci-ra a svg { width: 15px; height: 15px; }
.sci-fix { padding: 2px 8px; border-radius: 999px; background: var(--bg); border: 1px solid var(--line); color: var(--muted); font-size: 11.5px; font-weight: 800; white-space: nowrap; }
.sci-backto.btn { width: auto; padding: 6px 12px; font-size: 13px; border-radius: 12px; }
.sci-backto svg { width: 16px; height: 16px; }
.sci-xr { border-radius: 16px; border: 1px dashed var(--line); }
.sci-xr > summary { font-size: 14.5px; font-weight: 800; min-height: 52px; }
.sci-xr > summary b { color: var(--o-ink); margin: 0 2px; }
.sci-xr[open] { padding-bottom: 10px; }
.sci-xr > .sci-lead, .sci-xr > .sci-rl { margin: 0 10px; }
.sci-xr > .sci-lead { margin-bottom: 10px; }

/* ---------- 맨 아래 안내 ---------- */
.sci-note { margin: 0 14px; padding: 12px 14px; border-radius: 14px; background: var(--paper); border: 1px dashed var(--line); font-size: 12.5px; line-height: 1.65; color: var(--muted); }
.sci > .pad { padding-top: 0; }

/* ---------- 화면 움직임 '적게' ---------- */
html[data-motion="less"] .sci-chev, html[data-motion="less"] .sci-p { transition: none; }
@media (prefers-reduced-motion: reduce) {
  html:not([data-motion]) .sci-chev, html:not([data-motion]) .sci-p { transition: none; }
}
