/* 교과서 소개(about.html)와 이용권(pricing.html). 메인과 같은 토큰, 같은 움직임 원칙(눌림 .97, 강한 ease-out, hover는 마우스 기기만) */
body:is([data-view="about"], [data-view="pricing"]) { background: var(--paper); }
.pg { max-width: 1120px; }
.pg-h { padding: clamp(40px, 7vw, 96px) 0 clamp(24px, 4vw, 48px); }
.pg-h h1 { font-size: clamp(30px, 4vw, 48px); font-weight: 700; line-height: 1.18; letter-spacing: -.04em; text-wrap: balance; }
.pg-h h1 em { font-style: normal; }
.pg-h .lead { margin-top: 18px; max-width: 36em; font-size: clamp(16px, 1.3vw, 18px); line-height: 1.7; color: var(--ink-2); }
.cta { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 28px; }
/* 단추: 주 행동 하나만 먹색으로 채운다(홈의 '이어서 공부하기'와 같다) */
.cta .btn, .plan .btn { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 0 18px; font-size: 15px; font-weight: 600; border-radius: 8px; }
.btn.pri { color: var(--surface); background: var(--ink); border-color: var(--ink); }
@media (hover: hover) and (pointer: fine) { .btn.pri:hover { background: color-mix(in srgb, var(--ink) 84%, var(--surface)); border-color: color-mix(in srgb, var(--ink) 84%, var(--surface)); } }
.sec-h { font-size: clamp(22px, 2.4vw, 30px); font-weight: 700; letter-spacing: -.035em; line-height: 1.25; }
.sec-sub { margin-top: 8px; max-width: 40em; font-size: 15px; color: var(--ink-2); }
.band { margin-top: clamp(56px, 8vw, 104px); }

/* 소개: 첫 화면 + 던지기 그림 */
.hero2 { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: clamp(28px, 5vw, 64px); align-items: center; }
.hero2 .pg-h { padding-bottom: clamp(40px, 7vw, 96px); }
.toss { padding: 18px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); }
.toss svg { display: block; width: 100%; height: auto; border-radius: 6px; background: var(--paper); }
.toss .gnd { stroke: var(--line-strong); stroke-width: 1.5; }
.toss .path { fill: none; stroke: var(--forest); stroke-width: 3; stroke-linecap: round; }
.toss .ghost { fill: none; stroke: var(--ink-3); stroke-width: 1.5; stroke-dasharray: 4 5; opacity: .6; }
.toss .ball { fill: var(--forest); }
.toss .ang { fill: none; stroke: var(--ink-3); stroke-width: 1.2; }
.toss text { font: 500 12px var(--f-kr); fill: var(--ink-2); }
.toss-ctl { display: flex; align-items: center; gap: 12px; margin-top: 14px; font-size: 13.5px; color: var(--ink-2); }
.toss-ctl input { flex: 1; margin: 0; }
.toss-ctl output { min-width: 3.4em; text-align: right; color: var(--ink); font-variant-numeric: tabular-nums; }
.toss-q { margin-top: 10px; font-size: 13.5px; line-height: 1.6; color: var(--ink-2); }
.toss-q b { color: var(--ink); }

.stats2 { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); }
.stats2 div { padding: 20px 22px; }
.stats2 div + div { border-left: 1px solid var(--line); }
.stats2 dt { font-size: 13px; color: var(--ink-3); }
.stats2 dd { margin-top: 4px; font-size: clamp(22px, 2.2vw, 28px); font-weight: 600; letter-spacing: -.03em; font-variant-numeric: tabular-nums; }

.six2 { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 20px; margin-top: 24px; }
.six2 li { padding-top: 14px; border-top: 2px solid var(--ink); }
.six2 li:first-child { border-top-color: var(--forest); }
.six2 b { display: block; font-size: 16px; letter-spacing: -.02em; }
.six2 span { display: block; margin-top: 4px; font-size: 13.5px; line-height: 1.55; color: var(--ink-2); }

.feats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin-top: 24px; }
.feat { padding: 22px 24px; background: var(--surface); border-radius: var(--r); }
.feat svg { display: none; }
.feat h3 { font-size: 17px; letter-spacing: -.02em; }
.feat p { margin-top: 6px; font-size: 14.5px; line-height: 1.65; color: var(--ink-2); }

/* 담긴 과목: 찾기 칸 + 과학(교과별)·수학(분야별) 열 */
.sj-find { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 16px; margin-top: 24px; }
.sj-q { position: relative; flex: 1 1 360px; max-width: 520px; }
.sj-q svg { position: absolute; left: 12px; top: 50%; width: 18px; height: 18px; color: var(--ink-3); translate: 0 -50%; pointer-events: none; }
.sj-q input { width: 100%; height: 44px; padding: 0 14px 0 40px; font: 400 15px var(--f-kr); color: var(--ink); background: var(--surface); border: 1px solid var(--line-strong); border-radius: 8px; transition: border-color 150ms ease; }
.sj-q input::placeholder { color: var(--ink-3); }
.sj-q input:focus { outline: none; border-color: var(--ink-3); box-shadow: 0 0 0 3px color-mix(in srgb, var(--forest) 18%, transparent); }
.sj-n { font-size: 13.5px; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.subj { display: grid; gap: 28px; margin-top: 20px; }
.sj-g { padding: 20px 24px 22px; background: var(--surface); border-radius: var(--r); }
.sj-g h3 { font-size: 16px; font-weight: 700; letter-spacing: -.015em; }
.sj-cols { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 16px 20px; margin-top: 14px; }
.sj-col h4 { padding-bottom: 6px; font-size: 13px; font-weight: 600; color: var(--ink-2); border-bottom: 1px solid var(--line); }
.sj-col ul { margin-top: 4px; }
.sj-col a { display: grid; grid-template-columns: 7px minmax(0, 1fr); column-gap: 8px; align-items: center; padding: 6px 0; color: var(--ink); text-decoration: none; }
.sj-col .sl-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--tc, var(--ink-3)); }
.sj-nm { font-size: 14.5px; font-weight: 500; line-height: 1.35; }
.sj-col small { grid-column: 2; font-size: 12px; color: var(--ink-3); }
.sj-none { padding: 20px 0; font-size: 14.5px; color: var(--ink-2); }
@media (hover: hover) and (pointer: fine) { .sj-col a:hover .sj-nm { text-decoration: underline; text-underline-offset: .2em; } }
@media (max-width: 1000px) { .sj-cols { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 640px) { .sj-cols { grid-template-columns: repeat(2, minmax(0, 1fr)); } .sj-g { padding: 16px; } }

.endcta { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px; padding: clamp(24px, 3.4vw, 36px); background: color-mix(in srgb, var(--forest) 7%, var(--surface)); border-radius: var(--r); }
[data-theme="dark"] .endcta { background: color-mix(in srgb, var(--forest) 14%, var(--surface)); }
.endcta h2 { font-size: clamp(20px, 2vw, 26px); letter-spacing: -.03em; }
.endcta p { margin-top: 6px; color: var(--ink-2); }

/* 이용권 */
.plans { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; align-items: stretch; }
.plan { position: relative; display: flex; flex-direction: column; padding: 24px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); }
.plan.best { border-color: var(--ink); }
.plan .tag { margin-left: 8px; font-size: 13px; font-weight: 600; color: var(--forest); }
.plan h2 { font-size: 17px; letter-spacing: -.02em; }
.plan .d { margin-top: 2px; font-size: 13.5px; color: var(--ink-3); }
.plan .price { margin-top: 18px; display: flex; align-items: baseline; gap: 6px; }
.plan .price b { font-size: 32px; font-weight: 700; letter-spacing: -.04em; font-variant-numeric: tabular-nums; }
.plan .price span { font-size: 14px; color: var(--ink-3); }
.plan ul { display: grid; gap: 9px; margin: 20px 0 24px; font-size: 14.5px; }
.plan li { display: flex; gap: 10px; align-items: baseline; }
.plan li::before { content: ""; flex: none; width: 5px; height: 9px; margin: 0 3px 0 3px; border-right: 2px solid var(--ink-3); border-bottom: 2px solid var(--ink-3); rotate: 40deg; translate: 0 -1px; }
.plan .btn { margin-top: auto; width: 100%; }
.plan .btn[aria-disabled="true"] { color: var(--ink-3); background: var(--paper-2); border-color: var(--line); cursor: not-allowed; }
.plan .btn[aria-disabled="true"]:active { transform: none; }
.pay-note { margin-top: 14px; font-size: 13px; color: var(--ink-3); }

.code { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(20px, 4vw, 48px); padding: clamp(24px, 3.4vw, 36px); background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); scroll-margin-top: 80px; }
.code form { display: flex; gap: 8px; margin-top: 4px; }
.code input { flex: 1; min-width: 0; height: 48px; padding: 0 14px; font: 500 16px var(--f-mono); letter-spacing: .04em; text-transform: uppercase; color: var(--ink); background: var(--paper); border: 1px solid var(--line-strong); border-radius: 8px; transition: border-color 150ms ease, box-shadow 200ms var(--ease-out); }
.code input:focus { outline: none; border-color: var(--forest); box-shadow: 0 0 0 4px color-mix(in srgb, var(--forest) 16%, transparent); }
.code button.btn { height: 48px; padding: 0 20px; border-radius: 8px; font-weight: 600; }
.code label { font-size: 14px; font-weight: 600; }
.code .msg { min-height: 1.6em; margin-top: 10px; font-size: 14px; }
.code .msg.ok { color: var(--forest); font-weight: 600; }
.code .msg.bad { color: var(--warn); }
.status { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 20px; padding: 16px 20px; background: color-mix(in srgb, var(--forest) 7%, var(--surface)); border-radius: var(--r); }
.status b { color: var(--ink); }
.status button { font-size: 13px; color: var(--ink-3); background: none; border: 0; text-decoration: underline; cursor: pointer; }
.faq { margin-top: 20px; border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 56px; font-size: 16px; font-weight: 600; cursor: pointer; list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ""; flex: none; width: 8px; height: 8px; margin-top: -4px; border-right: 2px solid var(--ink-3); border-bottom: 2px solid var(--ink-3); rotate: 45deg; transition: rotate 200ms var(--ease-out); }
.faq details[open] summary::after { rotate: -135deg; margin-top: 4px; }
.faq details p { padding: 0 0 18px; max-width: 46em; font-size: 15px; line-height: 1.7; color: var(--ink-2); }

.btn:active { transform: scale(.97); }
@media (max-width: 1000px) {
  .hero2 { grid-template-columns: minmax(0, 1fr); }
  .hero2 .pg-h { padding-bottom: 0; }
  .six2 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .stats2 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .stats2 div:nth-child(4) { border-left: 0; }
  .stats2 div:nth-child(n+4) { border-top: 1px solid var(--line); }
  .plans { grid-template-columns: minmax(0, 1fr); max-width: 480px; }
  .plan.best { order: -1; }
  .code { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 640px) {
  .six2, .feats { grid-template-columns: minmax(0, 1fr); }
  .six2 { gap: 16px; }
  .stats2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stats2 div { border-left: 0 !important; border-top: 1px solid var(--line); }
  .stats2 div:nth-child(-n+2) { border-top: 0; }
  .stats2 div:nth-child(even) { border-left: 1px solid var(--line) !important; }
  .cta .btn { flex: 1; }
  .code form { flex-direction: column; }
}
@media (prefers-reduced-motion: reduce) {
  .btn:active { transform: none; }
}
