@charset "UTF-8";
* { box-sizing: border-box; }
html { background: var(--night); }
body { margin: 0; min-width: 320px; background: var(--night); color: var(--text); }
button, textarea, input { font: inherit; }
button { cursor: pointer; -webkit-tap-highlight-color: transparent; touch-action: manipulation; }
button:focus-visible, textarea:focus-visible, input:focus-visible { outline: 2px solid var(--gold-bright); outline-offset: 3px; }
svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; }
.preview-layout { min-height: 100dvh; display: grid; grid-template-columns: minmax(270px, 350px) minmax(320px, 410px) minmax(170px, 220px); align-items: center; justify-content: center; gap: clamp(34px, 5vw, 80px); padding: 24px; overflow: hidden; background: radial-gradient(circle at 50% 35%, var(--standard-glow) 0, var(--night) 48%); }
.preview-notes { color: var(--text); }
.eyebrow { margin: 0 0 22px; color: var(--gold); font-size: 10px; letter-spacing: .18em; font-weight: 700; }
.preview-notes h1 { margin: 0; font-family: "Songti SC", "STSong", serif; font-size: clamp(42px, 4.7vw, 62px); line-height: 1.22; letter-spacing: .02em; font-weight: 500; }
.preview-notes h1 span { color: var(--gold); }
.notes-intro { max-width: 320px; margin: 24px 0 30px; color: var(--muted); font-size: 14px; line-height: 1.9; }
.notes-steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 19px; }
.notes-steps li { display: flex; gap: 15px; align-items: flex-start; }
.notes-steps li > span { padding-top: 3px; color: var(--gold); font: 11px Georgia, serif; }
.notes-steps strong { font-size: 14px; letter-spacing: .02em; }
.notes-steps p { margin: 5px 0 0; color: var(--faint); font-size: 12px; line-height: 1.65; }
.notes-status { display: flex; align-items: center; gap: 8px; margin-top: 32px; color: var(--faint); font-size: 11px; }
.notes-status i { width: 7px; height: 7px; border-radius: 50%; background: var(--jade); box-shadow: 0 0 0 4px rgba(131, 182, 165, .1); }
.device { position: relative; width: 100%; height: min(900px, calc(100dvh - 48px)); min-height: 650px; overflow: hidden; background: var(--night); border: 6px solid #202a38; border-radius: 42px; box-shadow: 0 30px 75px rgba(0, 0, 0, .36), 0 5px 16px rgba(0, 0, 0, .24); isolation: isolate; }
.app, .screen { height: 100%; }
.screen { position: relative; display: flex; flex-direction: column; overflow: hidden; background: var(--night); animation: page-in .18s var(--ease-out) both; }
@keyframes page-in { from { opacity: 0; transform: translateY(5px); } to { opacity: 1; transform: none; } }
.home-header { flex: 0 0 auto; min-height: 68px; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: max(14px, env(safe-area-inset-top)) 18px 8px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--text); font-size: 15px; font-weight: 700; letter-spacing: .04em; }
.brand > span:last-child { display: flex; align-items: baseline; gap: 7px; }
.brand small { color: var(--faint); font-size: 8px; letter-spacing: .12em; font-weight: 700; }
.brand-symbol { width: 32px; height: 32px; display: grid; place-items: center; border: 1px solid var(--line-strong); border-radius: 10px; background: var(--gold-soft); color: var(--gold); }
.brand-symbol svg { width: 18px; height: 18px; }
.streak-button { min-height: 44px; display: flex; align-items: center; gap: 6px; padding: 0 11px; border: 1px solid var(--line); border-radius: 13px; background: var(--surface); color: var(--text); font-size: 10px; transition: transform 140ms var(--ease-out), border-color 180ms ease; }
.streak-button svg { width: 15px; height: 15px; color: var(--gold); }
.streak-button:active { transform: scale(.97); }
.home-content { flex: 1; min-height: 0; display: grid; grid-template-rows: auto minmax(320px, 1fr) auto; gap: 14px; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: none; padding: 0 16px 14px; }
.home-content::-webkit-scrollbar, .page-content::-webkit-scrollbar, .assignment-content::-webkit-scrollbar, .symbol-bar::-webkit-scrollbar { display: none; }
.home-intro { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; padding: 0 2px; }
.home-kicker { display: block; margin-bottom: 5px; color: var(--gold); font-size: 8px; letter-spacing: .15em; font-weight: 650; }
.home-intro h1 { margin: 0; font-family: "Songti SC", "STSong", serif; font-size: 29px; line-height: 1.15; letter-spacing: .08em; font-weight: 500; }
.home-intro > p { margin: 0 0 3px; color: var(--muted); font-size: 10px; white-space: nowrap; }
.pavilion-scene { position: relative; min-height: 320px; overflow: hidden; border: 1px solid rgba(230, 199, 131, .26); border-radius: 20px; background: var(--scene-bg); color: var(--scene-text); }
.pavilion-photo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 50%; filter: saturate(.84) brightness(.88); }
.scene-shade { position: absolute; inset: 0; background: linear-gradient(90deg, rgba(4, 9, 18, .46) 0%, rgba(4, 9, 18, .08) 53%, transparent 100%), linear-gradient(180deg, rgba(4, 9, 18, .12) 45%, rgba(4, 9, 18, .44) 100%); pointer-events: none; }
.scene-topline { position: absolute; z-index: 2; top: 14px; left: 14px; right: 14px; display: flex; justify-content: space-between; gap: 12px; color: var(--scene-muted); font-size: 8px; letter-spacing: .13em; }
.scene-topline span:last-child { color: var(--scene-accent); letter-spacing: .06em; }
.floor-list { position: absolute; inset: 0; z-index: 3; }
.floor-button { position: absolute; left: 14px; width: 146px; min-height: 52px; display: flex; align-items: center; gap: 9px; padding: 7px 9px; border: 1px solid rgba(230, 199, 131, .26); border-radius: 12px; background: var(--scene-button); color: var(--scene-text); text-align: left; box-shadow: 0 8px 20px rgba(0, 0, 0, .18); transition: transform 140ms var(--ease-out), border-color 180ms ease, background 180ms ease; }
.floor-button::after { content: ""; position: absolute; left: 100%; top: 50%; width: 18px; height: 1px; background: linear-gradient(90deg, rgba(230, 199, 131, .5), transparent); pointer-events: none; }
.floor-button:active { transform: scale(.97); background: #142235; }
.floor-button.floor-3 { top: 36%; }
.floor-button.floor-2 { top: 57%; }
.floor-button.floor-1 { top: 76%; }
.floor-no { width: 25px; flex: 0 0 auto; color: var(--scene-accent); font: 11px Georgia, serif; }
.floor-copy { flex: 1; min-width: 0; display: grid; gap: 3px; }
.floor-copy strong { font-size: 12px; font-weight: 650; letter-spacing: .03em; }
.floor-copy small { color: var(--scene-muted); font-size: 9px; }
.floor-button > svg { width: 13px; height: 13px; flex: 0 0 auto; color: var(--scene-accent); }
.task-card { padding: 16px; border: 1px solid var(--line); border-radius: 18px; background: var(--surface); }
.task-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.section-label { color: var(--gold); font-size: 10px; font-weight: 700; letter-spacing: .06em; }
.deadline { color: var(--muted); font-size: 9px; }
.task-card h2 { margin: 9px 0 0; font-size: 17px; line-height: 1.4; letter-spacing: -.015em; }
.task-progress { display: flex; align-items: center; gap: 12px; margin-top: 13px; }
.progress-track { flex: 1; height: 4px; overflow: hidden; border-radius: 4px; background: var(--progress-bg); }
.progress-track span { display: block; width: 70%; height: 100%; border-radius: inherit; background: var(--gold); }
.task-progress strong { font-size: 14px; line-height: 1; }
.task-progress strong span { margin-left: 2px; color: var(--faint); font-size: 10px; font-weight: 500; }
.primary-button, .secondary-button { min-height: 48px; border-radius: 13px; font-size: 13px; font-weight: 700; transition: transform 140ms var(--ease-out), background 180ms ease, border-color 180ms ease; }
.primary-button { border: 1px solid var(--gold); background: var(--gold); color: var(--gold-ink); }
.secondary-button { border: 1px solid var(--line); background: var(--surface-raised); color: var(--text); }
.primary-button:active, .secondary-button:active { transform: scale(.98); }
.continue-button { width: 100%; display: flex; align-items: center; margin-top: 14px; padding: 0 14px; text-align: left; }
.continue-button > span { flex: 1; }
.continue-button small { margin-right: 10px; color: var(--gold-ink-soft); font-size: 9px; font-weight: 600; }
.continue-button svg { width: 18px; height: 18px; }
.bottom-nav { position: relative; z-index: 10; flex: 0 0 auto; min-height: 74px; display: grid; grid-template-columns: repeat(5, 1fr); padding: 7px 8px max(9px, env(safe-area-inset-bottom)); border-top: 1px solid var(--line); background: var(--nav-bg); }
.nav-item { position: relative; min-width: 0; min-height: 52px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; border: 0; border-radius: 12px; background: transparent; color: var(--nav-text); font-size: 9px; transition: color 160ms ease, transform 140ms var(--ease-out); }
.nav-item svg { width: 20px; height: 20px; }
.nav-item.active { color: var(--gold-bright); font-weight: 650; }
.nav-item.active::before { content: ""; position: absolute; top: -7px; width: 22px; height: 2px; border-radius: 2px; background: var(--gold); }
.nav-item:active { transform: scale(.96); }
.nav-badge { position: absolute; top: 2px; left: calc(50% + 8px); min-width: 15px; height: 15px; display: grid; place-items: center; padding: 0 4px; border: 2px solid var(--nav-bg); border-radius: 9px; background: var(--gold); color: var(--gold-ink); font-size: 8px; font-weight: 750; }
.page-content { flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: none; padding: 0 18px 26px; }
.standard-screen { background: radial-gradient(circle at 90% 0, var(--standard-glow) 0, transparent 32%), var(--night); }
.standard-content { padding-top: max(30px, env(safe-area-inset-top)); }
.section-head { margin: 0 2px 24px; }
.section-head > span { color: var(--gold); font-size: 9px; letter-spacing: .14em; font-weight: 700; }
.section-head h1 { margin: 9px 0 7px; font-size: 29px; line-height: 1.2; letter-spacing: -.035em; }
.section-head p { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.7; }
.recommendation { display: flex; align-items: flex-start; gap: 11px; padding: 15px; border: 1px solid var(--jade-line); border-radius: 15px; background: var(--jade-soft); color: var(--jade-text); }
.recommendation svg { flex: 0 0 auto; width: 20px; height: 20px; color: var(--jade); }
.recommendation p { margin: 0; font-size: 11px; line-height: 1.7; }
.recommendation strong { color: var(--jade-text); }
.filter-tabs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 5px; margin: 20px 0 15px; padding: 4px; border-radius: 13px; background: var(--input-bg); }
.filter-tabs button { min-height: 40px; border: 0; border-radius: 10px; background: transparent; color: var(--muted); font-size: 11px; transition: color 160ms ease, background 160ms ease, transform 140ms var(--ease-out); }
.filter-tabs button.active { background: var(--surface-raised); color: var(--gold-bright); font-weight: 700; }
.filter-tabs button:active { transform: scale(.97); }
.exercise-list { display: grid; gap: 11px; }
.exercise-card { width: 100%; display: flex; align-items: center; gap: 13px; min-height: 134px; padding: 16px 14px; border: 1px solid var(--line); border-radius: 17px; background: var(--surface); color: var(--text); text-align: left; transition: border-color 180ms ease, transform 140ms var(--ease-out); }
.exercise-card:active { transform: scale(.985); border-color: var(--line-strong); }
.exercise-index { align-self: flex-start; padding-top: 4px; color: var(--faint); font: 11px Georgia, serif; }
.exercise-copy { flex: 1; min-width: 0; display: flex; flex-direction: column; align-items: flex-start; }
.exercise-tag { margin-bottom: 6px; padding: 3px 6px; border-radius: 5px; background: var(--gold-soft); color: var(--gold); font-size: 8px; }
.exercise-copy strong { font-size: 14px; }
.exercise-copy > small { margin-top: 6px; color: var(--muted); font-size: 10px; }
.exercise-time { display: flex; align-items: center; gap: 4px; margin-top: 11px; color: var(--faint); font-size: 9px; }
.exercise-time svg { width: 13px; height: 13px; }
.circle-arrow { width: 30px; height: 30px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 50%; background: var(--surface-raised); color: var(--gold); }
.circle-arrow svg { width: 15px; height: 15px; }
.review-overview { display: flex; align-items: center; gap: 22px; padding: 20px; border: 1px solid var(--jade-line); border-radius: 18px; background: linear-gradient(135deg, var(--jade-soft), var(--surface)); }
.review-overview > div { flex: 0 0 auto; padding-right: 20px; border-right: 1px solid var(--jade-line); }
.review-overview > div strong { display: block; color: var(--gold-bright); font-size: 38px; line-height: 1; }
.review-overview > div span { display: block; margin-top: 6px; color: var(--jade-text); font-size: 10px; }
.review-overview p { margin: 0; color: var(--jade-text); font-size: 10px; line-height: 1.8; }
.review-overview p strong { color: var(--text); }
.wrong-list { display: grid; gap: 12px; margin-top: 18px; }
.wrong-item { padding: 17px; border: 1px solid var(--line); border-radius: 17px; background: var(--surface); }
.wrong-item-top { display: flex; align-items: center; justify-content: space-between; color: var(--faint); font-size: 9px; }
.status-dot { display: flex; align-items: center; gap: 5px; color: var(--gold); }
.status-dot::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: var(--gold); }
.wrong-item h2 { margin: 10px 0 6px; font-size: 15px; }
.wrong-item > p { margin: 0; color: var(--muted); font-size: 11px; }
.wrong-item-bottom { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 15px; padding-top: 12px; border-top: 1px solid var(--line); }
.wrong-item-bottom small { color: var(--faint); font-size: 9px; }
.wrong-item-bottom button { min-height: 40px; display: flex; align-items: center; gap: 5px; padding: 0 10px; border: 1px solid var(--line-strong); border-radius: 10px; background: var(--gold-soft); color: var(--gold-bright); font-size: 10px; font-weight: 700; transition: transform 140ms var(--ease-out); }
.wrong-item-bottom button:active { transform: scale(.97); }
.wrong-item-bottom svg { width: 14px; height: 14px; }
.my-rank { padding: 20px; border-radius: 19px; background: var(--gold); color: var(--gold-ink); }
.my-rank > span { color: var(--gold-ink-soft); font-size: 10px; }
.my-rank > div { display: flex; align-items: center; gap: 18px; margin-top: 12px; }
.my-rank > div > strong { font-size: 47px; line-height: 1; letter-spacing: -.05em; }
.my-rank p { margin: 0; font-size: 13px; }
.my-rank small { display: block; margin-top: 6px; color: var(--gold-ink-soft); font-size: 10px; }
.rank-list { margin-top: 18px; padding: 4px 15px; border: 1px solid var(--line); border-radius: 18px; background: var(--surface); }
.rank-row { display: flex; align-items: center; gap: 11px; min-height: 66px; border-bottom: 1px solid var(--line); }
.rank-row:last-child { border-bottom: 0; }
.rank-row.me { margin: 0 -8px; padding: 0 8px; border-radius: 12px; background: var(--gold-soft); }
.rank-number { width: 21px; color: var(--faint); font: 11px Georgia, serif; }
.avatar { width: 32px; height: 32px; display: grid; place-items: center; border-radius: 50%; background: var(--avatar-bg); color: var(--avatar-text); font-size: 11px; }
.rank-row > strong { flex: 1; font-size: 12px; }
.rank-row > strong small { margin-left: 6px; padding: 2px 5px; border-radius: 4px; background: var(--gold); color: var(--gold-ink); font-size: 8px; }
.rank-score { font-size: 12px; font-weight: 700; text-align: right; }
.rank-score small { margin-left: 3px; color: var(--faint); font-size: 8px; font-weight: 400; }
.rank-note { margin: 14px 0 0; color: var(--faint); font-size: 9px; text-align: center; }
.profile-welcome { display: flex; align-items: center; gap: 13px; padding: 18px; border: 1px solid var(--line); border-radius: 18px; background: var(--surface); }
.profile-avatar { width: 46px; height: 46px; display: grid; place-items: center; border-radius: 15px; background: var(--gold); color: var(--gold-ink); font-size: 17px; font-weight: 700; }
.profile-welcome > div { flex: 1; }
.profile-welcome h2 { margin: 0; font-size: 16px; }
.profile-welcome p { margin: 5px 0 0; color: var(--muted); font-size: 9px; }
.profile-welcome > button:last-child { width: auto; min-height: 40px; padding: 0 10px; border: 1px solid var(--line); border-radius: 10px; background: transparent; color: var(--muted); font-size: 10px; }
.profile-welcome > .profile-avatar { flex: 0 0 auto; padding: 0; border: 0; cursor: pointer; }
.profile-welcome button svg { width: 17px; height: 17px; }
.avatar-dialog .dialog-actions { grid-template-columns: 1fr; margin-top: 18px; }
.avatar-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-top: 18px; }
.avatar-choice { aspect-ratio: 1; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 14px; background: var(--surface-raised); font-size: 27px; }
.avatar-choice.selected { border-color: var(--gold); background: var(--gold-soft-strong); }
.profile-stats { display: grid; grid-template-columns: repeat(3, 1fr); margin: 18px 0; padding: 18px 5px; border: 1px solid var(--jade-line); border-radius: 17px; background: var(--jade-soft); }
.profile-stats div { text-align: center; border-right: 1px solid var(--jade-line); }
.profile-stats div:last-child { border: 0; }
.profile-stats strong { display: block; font-size: 21px; }
.profile-stats span { display: block; margin-top: 5px; color: var(--jade-text); font-size: 9px; }
.goal-card { padding: 18px; border: 1px solid var(--line); border-radius: 18px; background: var(--surface); }
.goal-heading { display: flex; align-items: center; justify-content: space-between; }
.goal-heading > span { display: flex; align-items: center; gap: 7px; font-size: 12px; font-weight: 700; }
.goal-heading svg { width: 18px; height: 18px; color: var(--gold); }
.goal-heading > strong { color: var(--gold); font-size: 11px; }
.goal-track { height: 5px; margin-top: 15px; overflow: hidden; border-radius: 4px; background: var(--progress-bg); }
.goal-track span { display: block; width: 71.4%; height: 100%; border-radius: inherit; background: var(--gold); }
.goal-card > p { margin: 8px 0 15px; color: var(--muted); font-size: 9px; }
.day-dots { display: flex; justify-content: space-between; }
.day-dots > span { width: 28px; height: 28px; display: grid; place-items: center; border-radius: 50%; background: var(--avatar-bg); color: var(--faint); font-size: 9px; }
.day-dots > span.done { background: var(--gold); color: var(--gold-ink); }
.day-dots svg { width: 13px; height: 13px; }
.settings-list { margin-top: 18px; padding: 0 15px; border: 1px solid var(--line); border-radius: 18px; background: var(--surface); }
.settings-list button { width: 100%; min-height: 54px; display: flex; align-items: center; gap: 11px; padding: 0; border: 0; border-bottom: 1px solid var(--line); background: transparent; color: var(--muted); text-align: left; }
.settings-list button:last-child { border-bottom: 0; }
.settings-list button > svg { width: 18px; height: 18px; }
.settings-list button > span { flex: 1; color: var(--text); font-size: 12px; }
.assignment-screen { background: var(--night-soft); }
.detail-head { flex: 0 0 auto; min-height: 76px; display: flex; align-items: center; gap: 11px; padding: max(14px, env(safe-area-inset-top)) 17px 9px; border-bottom: 1px solid var(--line); background: var(--surface); }
.back-button { width: 44px; height: 44px; display: grid; place-items: center; flex: 0 0 auto; border: 1px solid var(--line); border-radius: 13px; background: var(--surface-raised); color: var(--text); transition: transform 140ms var(--ease-out); }
.back-button:active { transform: scale(.96); }
.back-button svg { width: 18px; height: 18px; }
.detail-head > div { flex: 1; min-width: 0; }
.detail-head > div strong { display: block; overflow: hidden; font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.detail-head > div span { display: block; margin-top: 4px; color: var(--muted); font-size: 8px; }
.question-count { color: var(--gold); font-size: 12px; font-weight: 750; }
.assignment-content { flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: none; padding: 17px 18px 32px; }
.assignment-progress { height: 4px; margin-bottom: 20px; overflow: hidden; border-radius: 3px; background: var(--progress-bg); }
.assignment-progress span { display: block; height: 100%; border-radius: inherit; background: var(--gold); }
.question-meta { display: flex; align-items: center; justify-content: space-between; }
.question-meta > span { padding: 5px 8px; border-radius: 6px; background: var(--gold-soft); color: var(--gold); font-size: 9px; font-weight: 700; }
.question-meta small { color: var(--faint); font-size: 9px; }
.assignment-content h1 { margin: 14px 0 9px; font-size: 20px; line-height: 1.6; letter-spacing: -.02em; }
.assignment-content h1 code { padding: 2px 5px; border-radius: 5px; background: var(--avatar-bg); color: var(--gold-bright); font: 600 .9em "SFMono-Regular", Consolas, monospace; }
.question-desc { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.7; }
.editor-label { display: flex; justify-content: space-between; margin: 22px 1px 9px; font-size: 11px; font-weight: 650; }
.editor-label small { color: var(--faint); font-size: 9px; font-weight: 400; }
.code-editor { width: 100%; min-height: 172px; display: block; resize: vertical; padding: 17px; border: 1px solid var(--code-border); border-radius: 15px; background: var(--code-bg); color: var(--code-text); caret-color: var(--gold); font: 13px/1.75 "SFMono-Regular", Consolas, monospace; tab-size: 4; }
.symbol-bar { display: flex; gap: 7px; padding: 9px 0 4px; overflow-x: auto; scrollbar-width: none; }
.symbol-bar button { min-width: 40px; height: 40px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface-raised); color: var(--text); font-size: 11px; transition: transform 120ms var(--ease-out), background 160ms ease; }
.symbol-bar button:active { transform: scale(.94); background: var(--surface-raised); }
.test-label { display: block; margin: 15px 1px 8px; font-size: 11px; font-weight: 650; }
.test-input { width: 100%; height: 46px; padding: 0 13px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface-raised); color: var(--text); }
.test-hint { display: block; margin: 6px 1px 0; color: var(--faint); font-size: 9px; }
.run-output { display: none; margin: 13px 0 0; padding: 13px 14px; border: 1px solid var(--jade-line); border-radius: 12px; background: var(--jade-soft); color: var(--jade-text); white-space: pre-wrap; font: 11px/1.7 "SFMono-Regular", Consolas, monospace; }
.run-output.visible { display: block; animation: result-in .18s var(--ease-out); }
@keyframes result-in { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }
.run-output.error { border-color: var(--danger-line); background: var(--danger-soft); color: var(--danger-text); }
.assignment-actions { display: grid; grid-template-columns: 1fr 1.35fr; gap: 10px; margin-top: 18px; }
.run-button, .submit-button { width: 100%; margin: 0; padding: 0 12px; }
.run-button:disabled { opacity: .65; cursor: wait; }
.submit-button { display: flex; align-items: center; justify-content: center; gap: 7px; }
.submit-button svg { width: 16px; height: 16px; }
.preview-disclaimer { margin: 14px 0 0; color: var(--faint); font-size: 9px; text-align: center; }
.preview-caption { color: var(--muted); }
.preview-caption > span { color: var(--gold); font-size: 9px; letter-spacing: .15em; }
.preview-caption p { margin: 14px 0 20px; font-size: 23px; line-height: 1.45; letter-spacing: -.04em; font-weight: 650; }
.preview-caption small { color: var(--faint); font-size: 8px; line-height: 2; letter-spacing: .12em; }
.toast { position: fixed; z-index: 100; left: 50%; bottom: 28px; max-width: calc(100% - 36px); padding: 12px 17px; border: 1px solid var(--line-strong); border-radius: 12px; background: var(--surface-raised); color: var(--text); box-shadow: var(--shadow); font-size: 12px; opacity: 0; transform: translate(-50%, 10px); pointer-events: none; transition: opacity 180ms ease, transform 200ms var(--ease-out); }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.confirm-dialog { width: min(360px, calc(100% - 32px)); padding: 0; border: 1px solid var(--line-strong); border-radius: 22px; background: var(--surface); color: var(--text); }
.confirm-dialog::backdrop { background: var(--backdrop); }
.dialog-card { padding: 25px; text-align: center; }
.dialog-icon { width: 42px; height: 42px; display: grid; place-items: center; margin: 0 auto 14px; border-radius: 50%; background: var(--gold-soft-strong); color: var(--gold); }
.dialog-icon svg { width: 21px; height: 21px; }
.dialog-card h2 { margin: 0; font-size: 20px; }
.dialog-card > p { margin: 11px 0 20px; color: var(--muted); font-size: 12px; line-height: 1.75; }
.dialog-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.dialog-actions button { width: 100%; }
@media (hover: hover) and (pointer: fine) {
  .floor-button:hover { border-color: rgba(243, 215, 151, .7); background: rgba(17, 30, 47, .94); }
  .primary-button:hover { background: var(--gold-bright); border-color: var(--gold-bright); }
  .exercise-card:hover { border-color: var(--line-strong); }
}
@media (max-width: 900px) {
  .preview-layout { display: block; min-height: 100dvh; padding: 0; background: var(--night); }
  .device { width: 100%; height: 100dvh; min-height: 600px; border: 0; border-radius: 0; box-shadow: none; }
  .preview-notes, .preview-caption { display: none; }
}
@media (max-width: 350px) {
  .home-header { padding-left: 14px; padding-right: 14px; }
  .brand small { display: none; }
  .home-content { padding-left: 12px; padding-right: 12px; gap: 11px; }
  .home-intro h1 { font-size: 27px; }
  .home-intro > p { display: none; }
  .pavilion-scene { min-height: 300px; }
  .floor-button { left: 10px; width: 136px; }
  .floor-button::after { display: none; }
  .task-card { padding: 14px; }
  .task-card h2 { font-size: 16px; }
  .page-content { padding-left: 14px; padding-right: 14px; }
  .section-head h1 { font-size: 27px; }
  .exercise-card { gap: 9px; padding-left: 12px; padding-right: 12px; }
  .wrong-item-bottom { align-items: flex-start; flex-direction: column; }
  .wrong-item-bottom button { width: 100%; justify-content: center; }
  .assignment-content { padding-left: 15px; padding-right: 15px; }
  .assignment-content h1 { font-size: 18px; }
  .code-editor { font-size: 12px; }
  .day-dots > span { width: 26px; height: 26px; }
}
@media (max-height: 720px) {
  .home-header { min-height: 60px; }
  .home-content { grid-template-rows: auto minmax(300px, 1fr) auto; gap: 10px; }
  .home-intro h1 { font-size: 26px; }
  .home-kicker { margin-bottom: 3px; }
  .task-card { padding: 14px; }
  .task-card h2 { margin-top: 7px; }
  .task-progress { margin-top: 10px; }
  .continue-button { min-height: 44px; margin-top: 11px; }
  .bottom-nav { min-height: 66px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}

/* 正式学生端：保留海经阁主体，以下为真实业务组件。 */
.student-shell { width: 100%; max-width: 480px; height: 100vh; height: 100dvh; margin: 0 auto; overflow: hidden; background: var(--night); }
.student-shell .screen { height: 100%; }
.home-content { display: block; overflow-y: auto; }
.home-content > * + * { margin-top: 14px; }
.pavilion-scene { height: clamp(330px, 46vh, 470px); min-height: 330px; }
.home-assignments, .announcement-section { padding: 8px 0 18px; }
.list-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 22px 2px 11px; }
.list-heading h2 { margin: 0; font-size: 15px; }
.list-heading > span { color: var(--faint); font-size: 10px; }
.assignment-item { padding: 15px; border: 1px solid var(--line); border-radius: 16px; background: var(--surface); }
.assignment-item + .assignment-item { margin-top: 10px; }
.assignment-item-top, .assignment-item-meta { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.assignment-item h3 { margin: 10px 0 13px; font-size: 14px; line-height: 1.55; }
.assignment-item-meta > span { color: var(--faint); font-size: 10px; }
.assignment-item-meta .secondary-button { min-height: 40px; display: flex; align-items: center; gap: 5px; padding: 0 11px; font-size: 11px; }
.assignment-item-meta svg { width: 14px; height: 14px; }
.announcement { padding: 14px 15px; border-left: 2px solid var(--jade); border-radius: 0 12px 12px 0; background: var(--jade-soft); }
.announcement + .announcement { margin-top: 9px; }
.announcement p { margin: 0; color: var(--text); font-size: 12px; line-height: 1.7; white-space: pre-wrap; }
.announcement small { display: block; margin-top: 6px; color: var(--faint); font-size: 9px; }
.practice-grid { display: grid; gap: 11px; }
.practice-history { display: grid; gap: 9px; }
.practice-row { min-height: 58px; display: flex; align-items: center; gap: 12px; width: 100%; padding: 0 14px; border: 1px solid var(--line); border-radius: 13px; background: var(--surface); color: var(--text); text-align: left; }
.practice-row span { flex: 1; font-size: 12px; }
.practice-row strong { color: var(--gold); font-size: 12px; }
.practice-row svg { width: 15px; height: 15px; color: var(--faint); }
.my-rank .rank-score { color: var(--gold-ink); }
.my-rank > div > strong small { font-size: 15px; }
.profile-footer { margin: 25px 0 4px; color: var(--faint); font-size: 9px; line-height: 1.8; text-align: center; }
.radar { display: block; width: min(100%, 300px); height: auto; margin: 14px auto 5px; overflow: visible; }
.radar-grid { fill: none; stroke: var(--line); stroke-width: 1; }
.radar-value { fill: var(--gold-soft-strong); stroke: var(--gold); stroke-width: 1.5; }
.radar text { fill: var(--muted); stroke: none; font-size: 9px; }
.chapter-list { display: grid; gap: 12px; margin-top: 16px; }
.chapter-list > div { display: grid; grid-template-columns: 80px 1fr 36px; align-items: center; gap: 9px; }
.chapter-list span { font-size: 11px; }
.chapter-list span small { display: block; margin-top: 3px; color: var(--faint); font-size: 8px; }
.chapter-list strong { color: var(--gold); font-size: 11px; text-align: right; }
.login-screen { background: radial-gradient(circle at 85% 0, var(--login-glow) 0, transparent 34%), var(--night); }
.login-content { flex: 1; overflow-y: auto; padding: max(28px, env(safe-area-inset-top)) 24px 20px; }
.login-brand { display: flex; align-items: center; justify-content: space-between; }
.login-copy { margin: clamp(55px, 11vh, 100px) 0 34px; }
.login-copy > span { color: var(--gold); font-size: 8px; letter-spacing: .14em; }
.login-copy h1 { margin: 14px 0 16px; font-family: "Songti SC", "STSong", serif; font-size: 44px; line-height: 1.25; letter-spacing: .04em; font-weight: 500; }
.login-copy p { max-width: 320px; margin: 0; color: var(--muted); font-size: 13px; line-height: 1.85; }
.login-form { display: grid; gap: 17px; }
.login-form .primary-button { min-height: 52px; display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: 4px; }
.login-form .primary-button svg { width: 17px; height: 17px; }
.login-note { color: var(--faint); font-size: 10px; text-align: center; }
.login-footer { flex: 0 0 auto; padding: 15px 20px max(20px, env(safe-area-inset-bottom)); color: var(--faint); font-size: 9px; line-height: 1.8; text-align: center; }
.question-list { display: grid; grid-template-columns: minmax(0, 1fr); gap: 14px; }
.question-card { min-width: 0; padding: 17px; border: 1px solid var(--line); border-radius: 18px; background: var(--surface); }
.question-card h2 { margin: 13px 0 16px; font-size: 16px; line-height: 1.75; white-space: pre-wrap; overflow-wrap: anywhere; }
.question-image { display: block; width: 100%; max-height: 300px; object-fit: contain; margin: 0 0 14px; border-radius: 12px; background: var(--code-bg); }
.option-list { display: grid; gap: 9px; }
.opt { width: 100%; min-height: 52px; display: flex; align-items: center; gap: 11px; padding: 11px 12px; border: 1px solid var(--line); border-radius: 13px; background: var(--input-bg); color: var(--text); text-align: left; transition: transform 140ms var(--ease-out), border-color 180ms ease, background 180ms ease; }
.opt:active { transform: scale(.98); }
.opt.sel { border-color: var(--line-strong); background: var(--gold-soft); }
.opt .letter { width: 27px; height: 27px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 50%; background: var(--avatar-bg); color: var(--avatar-text); font-size: 11px; font-weight: 700; }
.opt.sel .letter { background: var(--gold); color: var(--gold-ink); }
.opt > span:nth-child(2) { flex: 1; font-size: 13px; line-height: 1.6; }
.opt > svg { width: 16px; height: 16px; color: var(--gold); }
.answer-input { margin-top: 4px; }
.answer-code { min-height: 230px; font-size: 16px; line-height: 1.65; }
.symbol-bar button { min-width: 44px; height: 44px; }
.test-input { min-height: 82px; display: block; resize: vertical; padding: 12px; border: 1px solid var(--code-border); border-radius: 12px; background: var(--code-bg); color: var(--code-text); font: 16px/1.6 "SFMono-Regular", Consolas, monospace; }
.case-buttons { display: flex; gap: 7px; margin-top: 8px; overflow-x: auto; }
.case-buttons button { min-height: 36px; padding: 0 11px; border: 1px solid var(--line); border-radius: 9px; background: transparent; color: var(--muted); font-size: 10px; }
.run-code { width: 100%; display: flex; align-items: center; justify-content: center; gap: 7px; margin-top: 12px; }
.run-code svg { width: 16px; height: 16px; }
.survey-box { margin-bottom: 18px; padding: 13px; border: 1px solid var(--jade-line); border-radius: 20px; background: var(--jade-soft); }
.survey-heading { padding: 5px 4px 14px; }
.survey-heading h2 { margin: 10px 0 6px; font-size: 18px; }
.survey-heading p { margin: 0; color: var(--muted); font-size: 11px; }
.survey-box .question-card { margin-bottom: 11px; background: var(--input-bg); }
.full-button { width: 100%; min-height: 52px; display: flex; align-items: center; justify-content: center; gap: 8px; }
.full-button svg { width: 17px; height: 17px; }
.submit-summary { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin: 22px 0 12px; color: var(--text); font-size: 12px; }
.submit-summary small { color: var(--faint); font-size: 9px; text-align: right; }
.score-hero { margin: 0 0 18px; border: 1px solid var(--line-strong); border-radius: 20px; background: linear-gradient(145deg, var(--surface-raised), var(--surface)); color: var(--text); text-align: center; }
.score-hero > span { color: var(--gold); font-size: 10px; letter-spacing: .08em; }
.score-hero .big { color: var(--gold-bright); }
.score-hero p { margin: 6px 0 0; color: var(--muted); font-size: 11px; }
.score-hero p strong { color: var(--text); }
.result-list { display: grid; gap: 10px; }
.result-item { padding: 15px; border: 1px solid var(--line); border-radius: 15px; background: var(--surface); }
.result-item > div { display: flex; justify-content: space-between; gap: 12px; font-size: 12px; }
.result-item > div strong { color: var(--gold); }
.result-item p { margin: 9px 0 0; color: var(--text); font-size: 11px; line-height: 1.7; }
.result-item small { display: block; margin-top: 7px; color: var(--faint); font-size: 9px; }
.result-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 18px; }
.password-form { text-align: left; }
.password-form h2 { margin-bottom: 18px; text-align: center; }
.password-form .field { margin-bottom: 13px; }
@media (min-width: 700px) {
  body { background: radial-gradient(circle at 50% 30%, var(--standard-glow), var(--night) 55%); }
  .student-shell { border-left: 1px solid var(--line); border-right: 1px solid var(--line); box-shadow: 0 20px 70px rgba(0, 0, 0, .32); }
}
@media (max-height: 700px) {
  .pavilion-scene { height: 330px; }
  .login-copy { margin-top: 40px; }
  .login-copy h1 { font-size: 38px; }
}
