/* 구동사 묶음 학습 (10/23) — 구성만 잡은 화면. 색은 tokens.css / student.css 변수만 씀 → 사이트 색을 정하면 그대로 따라감 */
.ph { gap: 18px; }
.ph .btn[disabled] { cursor: not-allowed; }
.ph-hint { margin: 0; font-size: 14px; color: var(--ink-sub); }
.ph-bar { height: 10px; border-radius: 999px; background: var(--line); overflow: hidden; }
.ph-bar i { display: block; height: 100%; background: var(--st-strong); border-radius: inherit; transition: width .3s; }
.ph-bar.thin { height: 6px; flex: 1; }
.ph-bar.test { height: 6px; }

/* 오늘 */
.ph-today { background: var(--st-accent); color: var(--st-accent-ink); border-radius: var(--radius); padding: 24px 26px; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 20px; align-items: center; }
.ph-today-main { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.ph-today .label-mono { color: var(--mint-ink); }
.ph-today h2 { font-family: var(--font-ko-title); font-weight: 700; font-size: 24px; margin: 0; }
.ph-today p { margin: 0; color: var(--mint-ink); }
.ph-today .ph-bar { background: rgba(255,255,255,.6); }
.ph-today-btns { display: flex; flex-wrap: wrap; gap: 10px; }
.ph-today-btns .btn { min-height: 50px; }
.ph-today-btns .btn-ghost { background: var(--card); }
.ph-today .ph-hint { color: var(--mint-ink); }
.ph-allclear { font-weight: 600; align-self: center; }
.ph-stats { margin: 0; display: grid; gap: 10px; }
.ph-stats div { background: var(--card); border-radius: 8px; padding: 10px 16px; min-width: 130px; }
.ph-stats dt { font-size: 13px; color: var(--ink-sub); }
.ph-stats dd { margin: 0; font-family: var(--font-en-title); font-size: 28px; font-weight: 600; color: var(--ink); font-variant-numeric: tabular-nums; }
.ph-stats small { font-size: 15px; color: var(--ink-sub); font-family: var(--font-body); font-weight: 500; }
@media (max-width: 620px) { .ph-today { grid-template-columns: 1fr; } .ph-stats { grid-template-columns: 1fr 1fr; } }

/* 상황별 / 동사별 탭 */
.ph-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 5px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 5px; }
.ph-tabs button { border: 0; background: transparent; border-radius: 6px; padding: 12px 10px; font: inherit; color: var(--ink-sub); cursor: pointer; display: flex; flex-direction: column; align-items: center; gap: 2px; }
.ph-tabs b { font-size: 18px; font-weight: 600; }
.ph-tabs span { font-size: 13px; }
.ph-tabs button[aria-selected="true"] { background: var(--st-strong); color: var(--st-strong-ink); }

/* 묶음 카드 */
.ph-sets { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 240px), 1fr)); gap: 12px; }
.ph-set { display: flex; flex-direction: column; gap: 10px; padding: 14px 18px 16px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); text-decoration: none; color: var(--ink); transition: border-color .15s, transform .15s; min-width: 0; }
.ph-set:hover { border-color: var(--brand); transform: translateY(-2px); }
.ph-set:focus-visible { outline: 3px solid var(--brand-deep); outline-offset: 2px; }
.ph-set-top { display: flex; justify-content: flex-end; align-items: flex-start; min-height: 24px; }
.ph-set-name { font-family: var(--font-en-title); font-size: 24px; font-weight: 600; text-align: center;  /* 11/11 Tori: 덜 굵게 · 가운데 */ line-height: 1.2; overflow-wrap: anywhere; }
.ph-set-foot { display: flex; align-items: center; gap: 10px; margin-top: auto; padding-top: 6px; }
.ph-set .num { font-family: var(--font-mono); font-size: 13px; color: var(--ink-sub); font-variant-numeric: tabular-nums; }
.ph-set .chip { font-size: 11px; font-weight: 600; padding: 3px 8px; border-radius: 999px; background: var(--bg); color: var(--ink-sub); white-space: nowrap; border: 1px solid var(--line); }
.ph-set.ready { border-color: var(--brand); }
.ph-set.ready .chip { background: var(--brand); color: var(--brand-ink); border-color: var(--brand); }
.ph-set.doing .chip { background: var(--st-accent); color: var(--st-accent-ink); border-color: transparent; }
.ph-set.done { background: var(--brand-soft); }

/* 도장 */
.ph-stamp { color: var(--seal); display: inline-block; width: 80px; height: 93px; transform: rotate(-6deg); }
.ph-stamp.sm { width: 34px; height: 40px; flex: none; margin: -6px -4px -6px 0; }
.ph-stamp svg { width: 100%; height: 100%; display: block; }

/* 묶음 상세 */
.ph-sethead { display: flex; justify-content: space-between; align-items: center; gap: 16px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 22px; }
.ph-sethead > div { flex: 1; display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.ph-sethead .label-mono { color: var(--brand-deep); }
.ph-sethead-sub { margin: 0; font-size: 16px; }
.ph-sethead-num { margin: 0; font-size: 14px; color: var(--ink-sub); }
.ph-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.ph-actions .btn { flex: 1 1 200px; min-height: 54px; font-size: 17px; }
.ph-glance { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 20px; overflow-x: auto; }
.ph-glance h3 { font-family: var(--font-ko-title); font-weight: 700; font-size: 18px; margin: 0 0 8px; }
.ph-glance h3 small { font-family: var(--font-mono); font-weight: 500; font-size: 13px; color: var(--ink-sub); margin-left: 6px; }
.ph-glance table { width: 100%; border-collapse: collapse; }
.ph-glance th, .ph-glance td { text-align: left; padding: 9px 6px; border-top: 1px solid var(--line); vertical-align: top; }
.ph-glance th { font-family: var(--font-en-title); font-weight: 500; font-size: 17px; white-space: nowrap; width: 40%; }
.ph-glance th b { color: var(--brand); font-weight: 600; }
.ph-glance td { font-size: 16px; }
.ph-glance td.ok { width: 2em; color: var(--brand); font-weight: 700; text-align: center; }

/* 단계 표시 */
.ph-steps { list-style: none; margin: 0; padding: 0; display: flex; gap: 6px; }
.ph-steps li { flex: 1; display: flex; align-items: center; justify-content: center; gap: 6px; padding: 8px 6px; border-radius: 6px; background: var(--card); border: 1px solid var(--line); color: var(--ink-sub); font-size: 15px; font-weight: 600; }
.ph-steps li span { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; font-family: var(--font-mono); font-size: 13px; background: var(--line); color: var(--ink); }
.ph-steps li.now { background: var(--st-strong); color: var(--st-strong-ink); border-color: var(--st-strong); }
.ph-steps li.now span { background: var(--st-strong-ink); color: var(--st-strong); }
.ph-steps li.past span { background: var(--st-accent); color: var(--st-accent-ink); }
@media (max-width: 460px) { .ph-steps li { font-size: 13px; flex-direction: column; gap: 2px; } }

/* 카드 뒷면: 뜻 + 예문 */
.ph-card.back { gap: 10px; }
.ph-card-ko { font-size: clamp(26px, 6vw, 38px); font-weight: 600; text-align: center; word-break: keep-all; }
.ph-card-ex { font-family: var(--font-en-text); font-size: 20px; text-align: center; line-height: 1.45; margin-top: 8px; }
.ph-card-ex .hit { font-weight: 600; text-decoration: underline; text-underline-offset: 4px; text-decoration-thickness: 2px; }
.ph-card-exko { font-size: 16px; opacity: .85; text-align: center; }

/* 문제 · 말하기 문장 */
.ph-q, .ph-speak { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px 24px; display: flex; flex-direction: column; gap: 12px; text-align: center; }
.ph-q-guide { margin: 0; font-size: 16px; font-weight: 600; color: var(--ink-sub); }
.ph-q-sent { margin: 0; font-family: var(--font-en-text); font-size: clamp(22px, 4.5vw, 30px); line-height: 1.5; overflow-wrap: anywhere; }
.ph-q-sent .blank { display: inline-block; min-width: 4.2em; height: 1.1em; border-bottom: 3px solid var(--brand); vertical-align: -0.1em; margin: 0 .15em; }
.ph-q-sent .hit { color: var(--brand); background: var(--st-accent); border-radius: 4px; padding: 0 .2em; }
.ph-q-ko { margin: 0; font-size: 17px; color: var(--ink-sub); }

.ph-opts { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.ph-opt { min-height: 62px; border: 2px solid var(--line); background: var(--card); color: var(--ink); border-radius: 8px; font: inherit; font-family: var(--font-en-text); font-size: 21px; font-weight: 500; cursor: pointer; padding: 8px 12px; transition: border-color .15s; }
.ph-opt:hover:not([disabled]) { border-color: var(--brand); }
.ph-opt:focus-visible { outline: 3px solid var(--brand-deep); outline-offset: 2px; }
.ph-opt[disabled] { cursor: default; }
.ph-opt.right { border-color: var(--brand); background: var(--brand); color: var(--brand-ink); }
.ph-opt.wrong { border-color: var(--seal); color: var(--seal); text-decoration: line-through; }
@media (max-width: 460px) { .ph-opts { grid-template-columns: 1fr; } }
.ph-q-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; min-height: 54px; }
.ph-q-foot .btn { min-height: 52px; min-width: 140px; }
.ph-res { font-weight: 700; font-size: 18px; }
.ph-res.ok { color: var(--brand); }
.ph-res.no { color: var(--seal); }

/* 말하기 버튼 3개 */
.ph-sp-btns { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
@media (max-width: 520px) { .ph-sp-btns { gap: 6px; } .ph-sp { min-height: 96px; padding: 12px 4px; } .ph-sp b { font-size: 15px; } .ph-sp small { font-size: 11px; text-align: center; } }
.ph-sp { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 16px 10px; min-height: 112px; border: 2px solid var(--line); border-radius: var(--radius); background: var(--card); color: var(--ink); font: inherit; cursor: pointer; }
.ph-sp .ic { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; background: var(--st-accent); color: var(--st-accent-ink); font-size: 16px; }
.ph-sp b { font-size: 17px; }
.ph-sp small { font-size: 13px; color: var(--ink-sub); }
.ph-sp:hover:not([disabled]) { border-color: var(--brand); }
.ph-sp:focus-visible { outline: 3px solid var(--brand-deep); outline-offset: 2px; }
.ph-sp[disabled] { opacity: .45; cursor: not-allowed; }
.ph-sp.did { border-color: var(--brand); }
.ph-sp.did .ic { background: var(--brand); color: var(--brand-ink); }
.ph-sp.rec .ic { color: var(--seal); }
.ph-sp.rec.on { border-color: var(--seal); }
.ph-sp.rec.on .ic { background: var(--seal); color: var(--seal-ink); animation: ph-pulse 1s infinite; }
@keyframes ph-pulse { 50% { transform: scale(1.12); } }
@media (prefers-reduced-motion: reduce) { .ph-sp.rec.on .ic { animation: none; } .ph-bar i { transition: none; } }
#app { display: flex; flex-direction: column; gap: 14px; }

/* ---------- 동사 테스트 (10/25) — 구동사와 같은 문제 화면을 함께 씀 ---------- */
.vt-intro { background: var(--st-accent); color: var(--st-accent-ink); border-radius: var(--radius); padding: 22px 26px; display: flex; flex-direction: column; gap: 6px; }
.vt-intro .label-mono { color: var(--mint-ink); }
.vt-intro h2 { font-family: var(--font-ko-title); font-weight: 800; font-size: 24px; margin: 0; }
.vt-intro p { margin: 0; color: var(--mint-ink); }
.vt-types { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); gap: 12px; }
.vt-type { text-align: left; display: flex; flex-direction: column; gap: 6px; padding: 18px; min-height: 150px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); font: inherit; color: var(--ink); cursor: pointer; transition: border-color .15s, transform .15s; }
.vt-type:hover:not([disabled]) { border-color: var(--brand); transform: translateY(-2px); }
.vt-type:focus-visible { outline: 3px solid var(--brand-deep); outline-offset: 2px; }
.vt-type[disabled] { opacity: .5; cursor: not-allowed; }
.vt-type .label-mono { color: var(--brand-deep); }
.vt-type b { font-size: 18px; }
.vt-type small { font-size: 14px; color: var(--ink-sub); }
.vt-type em { margin-top: auto; font-style: normal; font-size: 14px; font-weight: 600; color: var(--brand); }
.vt-history { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 20px; }
.vt-history h3 { font-family: var(--font-ko-title); font-weight: 800; font-size: 18px; margin: 0 0 8px; }
.vt-history h3 small { font-family: var(--font-mono); font-size: 13px; font-weight: 500; color: var(--ink-sub); margin-left: 6px; }
.vt-history ul { list-style: none; margin: 0; padding: 0; }
.vt-history li + li { border-top: 1px solid var(--line); }
.vt-history li button { width: 100%; display: grid; grid-template-columns: minmax(0, 9em) minmax(0, 1fr) auto auto; gap: 12px; align-items: baseline; padding: 11px 4px; background: none; border: 0; font: inherit; color: var(--ink); cursor: pointer; text-align: left; }
.vt-history li button:hover span { color: var(--brand); }
.vt-history time { font-size: 14px; color: var(--ink-sub); font-variant-numeric: tabular-nums; }
.vt-history b { font-family: var(--font-en-title); font-size: 20px; font-variant-numeric: tabular-nums; }
.vt-history b small { font-size: 14px; color: var(--ink-sub); }
.vt-history i { font-style: normal; font-size: 13px; color: var(--brand); }
@media (max-width: 520px) { .vt-history li button { grid-template-columns: 1fr auto; } .vt-history time { grid-column: 1 / -1; } .vt-history i { display: none; } }
.vt-q { position: relative; padding: 34px 24px; }
.vt-prompt { margin: 0; font-family: var(--font-en-title); font-weight: 700; font-size: clamp(38px, 9vw, 60px); line-height: 1.15; overflow-wrap: anywhere; }
.vt-prompt.ko { font-family: var(--font-body); font-weight: 700; font-size: clamp(28px, 6vw, 40px); word-break: keep-all; }
.vt-say { position: absolute; top: 12px; right: 12px; width: 44px; min-height: 44px; padding: 0; font-size: 18px; }
.ph-opt.ko { font-family: var(--font-body); font-size: 18px; word-break: keep-all; }
.vt-detail-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 12px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 22px; }
.vt-detail-head h2 { font-size: 20px; margin: 4px 0 0; }
.vt-detail-head .label-mono { color: var(--ink-sub); }
.vt-score { text-align: right; }
.vt-score b { font-family: var(--font-en-title); font-size: 40px; color: var(--brand); font-variant-numeric: tabular-nums; }
.vt-score small { font-size: 17px; color: var(--ink-sub); }
.vt-score span { display: block; font-size: 14px; color: var(--ink-sub); }
.vt-answers { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.vt-answers li { display: grid; grid-template-columns: 28px minmax(0, 1fr) auto; gap: 12px; align-items: center; background: var(--card); border: 1px solid var(--line); border-radius: 8px; padding: 10px 14px; }
.vt-answers li.no { border-color: var(--seal); }
.vt-answers .n { font-family: var(--font-mono); font-size: 14px; color: var(--ink-sub); text-align: center; }
.vt-answers b.en { font-family: var(--font-en-text); font-size: 19px; }
.vt-answers b.ko { font-size: 17px; }
.vt-answers p { margin: 2px 0 0; font-size: 15px; color: var(--ink-sub); overflow-wrap: anywhere; }
.vt-answers em { font-style: normal; font-weight: 600; color: var(--brand); }
.vt-answers s { color: var(--seal); }
.vt-answers .mark { font-size: 13px; font-weight: 700; padding: 3px 9px; border-radius: 999px; background: var(--st-accent); color: var(--st-accent-ink); }
.vt-answers li.no .mark { background: var(--seal); color: var(--seal-ink); }
/* 11/13 Tori: 단계 표시를 눌러 카드 ↔ 구동사 고르기 오가기 */
.ph-steps li:has(button) { padding: 0; }
.ph-steps li button { all: unset; box-sizing: border-box; width: 100%; display: flex; align-items: center; justify-content: center; gap: 6px; padding: 8px 6px; border-radius: 6px; cursor: pointer; color: var(--brand); text-decoration: underline; text-underline-offset: 3px; }
.ph-steps li button:hover { background: var(--st-accent); }
.ph-steps li button:focus-visible { outline: 2px solid var(--brand); outline-offset: 1px; }
@media (max-width: 460px) { .ph-steps li button { flex-direction: column; gap: 2px; } }
/* 11/13 Tori: 상황별 묶음 = 한글 제목 + 아래 작게 영어 */
.ph-set-name.ko { font-family: var(--font-ko-title); font-size: 21px; }
.ph-set-en { display: block; text-align: center; margin-top: -4px; font-size: 14px; color: var(--ink-sub); }
.ph-rec-note { margin: 4px 0 0; text-align: center; font-size: 14px; color: var(--ink-sub); }
