:root {
  color-scheme:light;
  --ink:#173e31; --pine:#184c39; --muted:#52695b; --line:#d7ddcc; --cream:#f8f6ee;
  --card:#fffdf6; --ochre:#d88632; --pale:#edf1e6; --danger:#9c3626;
  font-family:"DM Sans","PingFang SC","Microsoft YaHei",system-ui,sans-serif;
  color:var(--ink); background:var(--cream); font-synthesis:none;
}
.btn.review-home{gap:10px}
.home-actions .btn.primary{border:2px solid #0e3325;box-shadow:0 2px 0 #0e3325}
.home-count{font-size:13px;font-weight:650;letter-spacing:0}
.home-count:empty{display:none}
.home-count::before{content:"·";margin-right:8px}
.portal-inner .member-strip{margin:16px 0 0;gap:6px;padding:11px 13px}
.member-strip .home-quota{max-width:none;width:100%;min-height:40px}
.home-tools a{font-size:14px;font-weight:650;min-height:44px;display:inline-flex;align-items:center}
.rxn{display:inline-flex;flex-direction:column;align-items:center;vertical-align:middle;margin:0 .3em;line-height:1.15;white-space:nowrap;font-weight:inherit}
.rxn-over,.rxn-under{font-size:.7em;min-height:1.15em;padding:0 .6em}
.rxn-line{align-self:stretch;min-width:2.4em}
.rxn-eq .rxn-line{height:.2em;border-top:.09em solid currentColor;border-bottom:.09em solid currentColor;margin:.06em 0}
.rxn-arrow .rxn-line{height:0;border-top:.09em solid currentColor;position:relative;margin:.16em .3em .16em 0}
.rxn-arrow .rxn-line::after{content:"";position:absolute;right:-.3em;top:-.3em;border-left:.5em solid currentColor;border-top:.26em solid transparent;border-bottom:.26em solid transparent}
.chips{display:flex;flex-wrap:wrap;gap:8px}
.chip{min-height:40px;padding:6px 14px;border-radius:20px;border:1px solid #c2cdbd;background:#fffef8;color:var(--ink);font-size:14px;font-weight:650}
.chip.on{background:var(--pine);border-color:var(--pine);color:#fffdf1}
.record-stem{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:3;overflow:hidden}
* {box-sizing:border-box}
html,body {margin:0;min-width:0;min-height:100%}
body {padding:env(safe-area-inset-top) env(safe-area-inset-right) env(safe-area-inset-bottom) env(safe-area-inset-left)}
button,input,select,textarea {font:inherit}
button,a,input,textarea,select,summary {touch-action:manipulation}
button,summary,select {cursor:pointer}
button {border:0;color:inherit}
button:disabled {cursor:wait;opacity:.65}
a {color:var(--pine);text-underline-offset:4px}
:focus-visible {outline:3px solid #c07831;outline-offset:3px}
h1,h2,h3,p {margin:0}
button {background:none}
svg.icon {display:inline-block;fill:none;stroke:currentColor;stroke-width:1.65;stroke-linecap:round;stroke-linejoin:round;width:21px;height:21px;flex:none}
[hidden] {display:none!important}
.portal {position:relative;min-height:100vh;min-height:100svh;display:grid;grid-template-columns:1fr 1fr;padding:clamp(14px,2.3vw,36px);gap:0;background-color:var(--cream);isolation:isolate}
.portal::before {content:"";position:absolute;inset:0;z-index:-1;pointer-events:none;background:radial-gradient(#47634413 .7px,transparent .8px) 0 0 / 6px 6px}
.portal-main {display:grid;place-items:center;padding:50px clamp(22px,5vw,85px);position:relative}
.portal-inner {width:min(100%,365px);margin-top:-1.5vh}
.brand {display:flex;align-items:center;flex-direction:column;gap:13px;margin-bottom:40px}
.brand img {width:185px;max-width:100%;height:auto;display:block}
.brand .lab-signature {width:clamp(194px,18vw,222px)}
.poster {border-radius:5px;background:#174a38;position:relative;overflow:hidden;min-height:min(660px,calc(100vh - 72px));min-height:min(660px,calc(100svh - 72px))}
.poster::before {content:"";position:absolute;inset:0;background:url('/study.svg') center / cover no-repeat}
.poster::after {content:"";position:absolute;inset:18px;border:1px solid #d3deb530;border-radius:2px;pointer-events:none}
.login-form {display:grid;gap:13px}
.input-row {display:flex;align-items:center;gap:12px;background:#fffdf8;border:1px solid #c6d0bf;border-radius:8px;padding:0 16px;height:57px;color:#5a7262}
.input-row:focus-within {box-shadow:0 0 0 3px #48774c18;border-color:#44805c}
.input-row input {border:0;background:transparent;outline:none;min-width:0;color:var(--ink);width:100%;height:100%;font-size:16px}
.input-row input::placeholder {color:#647a6b}
.btn {border:1px solid #cbd4c3;background:var(--card);border-radius:8px;display:inline-flex;align-items:center;justify-content:center;gap:9px;min-height:45px;padding:10px 16px;font-weight:650;line-height:1.4;text-decoration:none;transition:background .15s,transform .15s}
.btn:hover {background:var(--pale)}
.btn:active {transform:translateY(1px)}
.btn.primary {background:var(--pine);color:#fffdf1;border-color:var(--pine)}
.btn.primary:hover {background:#266147}
.btn.hero {width:100%;justify-content:center;min-height:56px;font-size:17px;letter-spacing:.05em}
.btn.hero .arrow {margin-left:4px}
.login-form .hero {margin-top:5px}
.error {color:var(--danger);font-size:14px;line-height:1.6}
.portal-menu {position:absolute;z-index:1;top:22px;left:22px}
.iconbtn {display:inline-grid;place-items:center;border:1px solid #d2d9c9;border-radius:50%;background:var(--cream);width:44px;height:44px}
.iconbtn:hover {background:var(--pale)}
/* Home star menu */
.portal-menu-star {
  --menu-star-shape:polygon(50% 2%,64% 32%,98% 37%,73% 61%,79% 96%,50% 79%,21% 96%,27% 61%,2% 37%,36% 32%);
  display:grid;place-items:center;width:80px;height:80px;padding:6px 0 0;
  border:0;background:transparent;color:#173e31;border-radius:12px;
  filter:drop-shadow(0 3px 2px #173e3130);isolation:isolate;
  transition:filter .15s,transform .15s;
}
.portal-menu-star::before,.portal-menu-star::after {content:"";position:absolute;clip-path:var(--menu-star-shape);pointer-events:none}
.portal-menu-star::before {inset:0;background:#1d6246;z-index:0}
.portal-menu-star::after {inset:3px;background:linear-gradient(155deg,#ffe78b,#f4bd3e);z-index:1}
.portal-menu-label {position:relative;z-index:2;font-size:16px;font-weight:750;line-height:1;letter-spacing:1px;pointer-events:none}
.portal-menu-star:hover {filter:drop-shadow(0 4px 3px #173e3140) brightness(1.04)}
.portal-menu-star:active {transform:scale(.96)}
@media(max-width:750px){.portal-menu-star{width:64px;height:64px;padding-top:5px}.portal-menu-star::after{inset:2.5px}.portal-menu-label{font-size:14px}}
/* End home star menu */
.sr {position:absolute!important;height:1px;width:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
dialog {border:1px solid #d1d9c5;box-shadow:0 30px 100px #183c313d;color:var(--ink);background:var(--card);border-radius:16px;padding:0;width:min(520px,calc(100% - 32px));max-height:88vh;max-height:88dvh;overscroll-behavior:contain}
dialog::backdrop {background:rgb(16 38 28 / .45)}
dialog[open] {animation:appear .16s ease-out}
@keyframes appear {from {opacity:.4;transform:translateY(6px)}}
.sheet-head {display:flex;justify-content:space-between;align-items:center;gap:15px;padding:22px 24px 15px;border-bottom:1px solid var(--line)}
.sheet-head h2 {font-size:21px}
.sheet-head .iconbtn {width:40px;height:40px}
.sheet-body {padding:20px 24px 25px;display:grid;gap:16px;min-width:0}
.row-list {display:grid;gap:0}
.row-button {display:flex;align-items:center;text-align:left;gap:12px;width:100%;padding:14px 8px;background:transparent;border-bottom:1px solid var(--line);min-height:52px;font-weight:600;color:var(--ink)}
.row-button:last-child {border-bottom:0}
.row-button:hover {background:var(--pale)}
.row-button .end {margin-left:auto;color:var(--muted)}
.stack {display:grid;gap:14px}
.field {display:grid;gap:7px;font-weight:600;min-width:0;font-size:14px}
.field select,.field input,.field textarea {display:block;width:100%;max-width:100%;min-height:46px;border-radius:7px;border:1px solid #c2cdbd;background:#fffef8;padding:10px 13px;font-weight:400;font-size:16px;color:var(--ink)}
.field textarea {resize:vertical;min-height:88px}
.form-grid {display:grid;grid-template-columns:1fr 1fr;gap:12px}
.small {font-size:14px;color:var(--muted);line-height:1.7;overflow-wrap:anywhere}
.note,.notice {font-size:14px;line-height:1.7;background:#eff2e8;border-left:3px solid #6d916a;padding:12px 14px;border-radius:3px;overflow-wrap:anywhere}
.notice {background:#fcf1dc;border-color:var(--ochre)}
.token {width:100%;text-align:left;display:grid;gap:8px;padding:15px;border:1px solid var(--line);border-radius:7px;background:var(--pale)}
.track {height:4px;border:0;border-radius:10px;width:100%;overflow:hidden;appearance:none;background:#d4dbc9;accent-color:var(--pine)}
.track::-webkit-progress-bar {background:#d4dbc9}.track::-webkit-progress-value {background:var(--pine)}.track::-moz-progress-bar {background:var(--pine)}
.metrics {margin:0;display:grid;grid-template-columns:1fr auto;gap:12px 8px}
.metrics dt {color:var(--muted)}.metrics dd {margin:0;font-weight:700}
.upload-choices {display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:9px}
.pick {padding:15px 4px;display:grid;place-items:center;gap:9px;font-weight:650;border:1px solid #c8d3bd;border-radius:9px;background:var(--pale);color:var(--ink)}
.pick:hover {background:#e0ead9}
.drop-area.over {outline:3px dashed var(--ochre);outline-offset:5px}
.rules {font-size:13px;color:var(--muted);line-height:1.7}
.bar {display:flex;align-items:center;gap:14px;border-bottom:1px solid var(--line);padding:12px max(18px,calc((100vw - 1220px)/2));background:var(--card)}
.bar .mark {margin-right:auto;padding:0;display:grid;place-items:center;min-width:48px;min-height:44px}.bar .mark img {width:78px;height:auto}
.bar .bar-label {font-weight:650;font-size:15px}
.bar.paper-bar {position:sticky;top:0;z-index:4;padding-top:max(8px,env(safe-area-inset-top));flex-wrap:nowrap}
.btn.capture-back,.btn.review-home {background:#f7a935;border:2px solid #8a4b12;color:#2e1a04;font-weight:750;box-shadow:0 2px 0 #8a4b12}
.btn.capture-back:hover,.btn.review-home:hover {background:#fabb5c}
.btn.capture-back:active,.btn.review-home:active {background:#ea982a;box-shadow:none}
.btn.capture-back {flex:none;min-height:46px;padding:8px 14px;gap:7px}
.bar .bar-label {flex:1;min-width:0}
.btn.invite-home {background:#2f5f7e;border:2px solid #1d4159;color:#fdfcf5;font-weight:700;box-shadow:0 2px 0 #1d4159}
.btn.invite-home:hover {background:#3a7095}
.btn.invite-home:active {background:#29546f;box-shadow:none}
.btn.invite-home .gift-mark {width:32px;height:32px;stroke-width:1.7}
.sheet-head .sheet-close {flex:none;min-height:40px;padding:6px 12px;gap:5px;font-size:14px;border-radius:20px}
.crop-sheet .sheet-head .sheet-close {order:-1}
.invite-code {margin:0;display:flex;align-items:baseline;gap:12px;font-size:15px}.invite-code b {font-size:24px;letter-spacing:.08em}
.invite-panel h3 {margin:0;font-size:16px}
.invite-rules {margin:0;padding-left:1.4em;display:grid;gap:8px;line-height:1.7}
.invite-gift {margin:0;display:flex;gap:12px;align-items:flex-start;padding:12px 14px;border-radius:10px;background:#e4eef5;border:2px solid #2f5f7e;color:#17364a;line-height:1.6;font-size:14px}
.invite-gift .icon {flex:none;width:26px;height:26px;margin-top:2px}
.invite-gift b {display:block;font-size:17px}
.tier-choice {border:0;margin:0;padding:0;min-width:0;display:grid;gap:8px}
.tier-choice legend {padding:0;margin-bottom:8px;font-weight:750;font-size:16px}
.tier-options {display:grid;grid-template-columns:1fr 1fr;gap:12px}
.tier-option {position:relative;display:block;min-width:0}
.tier-option input {position:absolute;inset:0;width:100%;height:100%;margin:0;opacity:0;cursor:pointer}
.tier-card {--tier-accent:#1754c4;position:relative;display:grid;gap:9px;align-content:start;min-height:154px;height:100%;padding:15px 16px;border:2px solid #85aeed;border-radius:12px;background:linear-gradient(135deg,#f3f8ff,#e2edff);color:#123a7a;transition:border-color .15s,box-shadow .15s}
.tier-card::before {content:"";position:absolute;left:16px;top:17px;width:20px;height:20px;border-radius:50%;border:2px solid var(--tier-accent);background:#fff}
.tier-card b {padding-left:30px;font-size:20px;line-height:1.25;color:var(--tier-accent)}
.tier-card .tier-tagline {font-size:16px;font-weight:750;line-height:1.55;overflow-wrap:anywhere}
.tier-card small {font-size:14px;line-height:1.65;color:#354b6c;overflow-wrap:anywhere}
.tier-strong {--tier-accent:#7136a8;border-color:#b194d4;background:linear-gradient(135deg,#faf3ff,#eae0fb);color:#502379}
.tier-strong .tier-tagline {padding:5px 8px;border-radius:6px;background:#ffe4a3;color:#643a08}
.tier-strong small {color:#574465}
.tier-option:hover .tier-card {border-color:var(--tier-accent)}
.tier-option input:checked + .tier-card {border-color:var(--tier-accent);box-shadow:0 3px 0 var(--tier-accent),0 0 0 1px var(--tier-accent)}
.tier-option input:checked + .tier-card::before {background:radial-gradient(circle,var(--tier-accent) 0 5px,#fff 6px)}
.tier-option input:focus-visible + .tier-card {outline:3px solid #122f57;outline-offset:4px}
@media(max-width:520px){.tier-options{grid-template-columns:1fr}.tier-card{min-height:0;padding:13px 14px;gap:7px}.tier-card::before{left:14px;top:15px}.tier-card b{font-size:19px}.tier-card .tier-tagline{font-size:15px}.tier-card small{font-size:13px}}
.tier-note {margin:0;padding:11px 14px;border:2px solid #8a4b12;border-radius:10px;background:#fff4d9;color:#3d2204;font-size:15px;font-weight:650;line-height:1.6}
.upload-actions {position:sticky;top:var(--upload-head,64px);z-index:3;display:flex;gap:10px;align-items:stretch;margin:-6px -24px;padding:8px 24px 10px;background:var(--card);border-bottom:1px solid var(--line);box-shadow:0 8px 12px -10px #234b3040}
.upload-actions .btn {min-height:52px;font-size:16px;justify-content:center}
.upload-actions .btn.primary {flex:1 1 0}
.upload-actions .clear-circle {flex:0 0 auto;border:2px solid #b3261e;color:#9c2018;background:#fff6f3;font-weight:750}
.upload-actions .clear-circle:disabled {border-color:#d9ddd2;color:#9aa598;background:#f4f5ef;box-shadow:none}
.stop-recognition {justify-self:start;color:#8b2926;border-color:#a83b36;background:#fff2ee}
.stop-recognition:hover {background:#ffe4db}
.result-question {scroll-margin-top:calc(80px + env(safe-area-inset-top))}
.container {width:min(1160px,calc(100% - 40px));margin:36px auto 70px}
.container.narrow {max-width:800px}
.page-head {display:flex;align-items:center;gap:16px;justify-content:space-between;margin:0 0 23px}
.page-head h1 {font-size:clamp(23px,3vw,34px);line-height:1.4;overflow-wrap:anywhere;letter-spacing:-.035em}
.meta {font-size:13px;color:var(--muted);line-height:1.7}
.paper-layout {display:grid;grid-template-columns:minmax(230px,.73fr) minmax(0,1.55fr);gap:20px;align-items:start}
.card {min-width:0;border:1px solid var(--line);border-radius:12px;background:var(--card);padding:clamp(16px,2.1vw,27px)}
.paper-side {display:grid;gap:14px}.paper-side h2,.panel-title {font-size:17px}
.qnav {display:flex;gap:7px;flex-wrap:wrap}
.qnav button {min-width:43px;min-height:43px;border:1px solid var(--line);border-radius:6px;background:var(--cream)}
.qnav button[aria-current=true] {background:var(--pine);color:white;border-color:var(--pine)}
.qlabel {font-size:14px;font-weight:650;color:#4e6e58}
.question-heading {display:flex;align-items:center;gap:6px 12px;justify-content:space-between;flex-wrap:wrap;margin-bottom:9px}
.result-list {display:grid;gap:1.4rem}
.question.result-question {display:grid;gap:.7rem;min-width:0}
.result-list + .actions {margin-top:1rem}
.analysis-label {justify-self:start;color:#355c48;border:1px solid #c9d6c3;border-radius:5px;padding:3px 7px;font-size:13px;line-height:1.45}
.upgrade-option {display:flex;align-items:center;flex-wrap:wrap;gap:9px 15px;padding:12px 14px;border-left:3px solid #c28a3c;background:#fbf1dc;border-radius:4px}
.upgrade-option p {color:#784710;font-size:14px;line-height:1.6;font-weight:650}
.upgrade-option .btn {color:#67411b;border-color:#bda07a}
.usage-line {display:grid;gap:6px;max-width:500px}
.question {display:grid;gap:19px;min-width:0}
.prose {font-size:16px;line-height:1.85;white-space:pre-wrap;overflow-wrap:anywhere;max-width:100%;overflow-x:auto}
.stem {font-size:19px;font-weight:650}
.point {display:grid;gap:6px}
.point h3,.point summary,.practice summary {font-size:15px;font-weight:700}
details summary {padding:12px 0;line-height:1.6;min-height:44px}
details summary:hover {color:#417b53}
.btn.question-action {width:100%;min-height:54px;font-size:18px;font-weight:700;text-align:center}
.saved-solution > summary {list-style:none}
.solution-action::-webkit-details-marker {display:none}
.saved-solution:not([open]) > summary .when-open,.saved-solution[open] > summary .when-closed {display:none}
.solution-caption {margin-top:6px}
.study-work {display:grid;gap:16px}
.study-work .page-head {margin:0}
.study-work .result-question {padding:clamp(15px,3vw,24px);border:1px solid var(--line);border-radius:12px;background:var(--card)}
.auto-question-title {font-size:1.12rem}
.auto-answer .answer-key {margin-top:0}
.steps {padding-left:24px;margin:5px 0}
.steps li {padding-left:3px}
.practice {border:1px solid #c8d6bd;background:#f1f4e9;border-radius:9px;padding:16px;display:grid;gap:12px}
.practice h3 {font-size:17px}
.answer-form h4 {font-size:16px;margin:0}
.answer-modes {display:flex;padding:3px;gap:3px;border:1px solid #c5d1bd;border-radius:10px;background:#e2e9da}
.answer-modes button {flex:1;min-height:44px;border-radius:7px;font-weight:650;color:var(--ink)}
.answer-modes [aria-pressed=true] {background:var(--pine);color:#fff}
.answer-form [data-voice-input] {justify-self:start}
.answer-form [data-voice-status]:empty {display:none}
.answer-pickers .btn {flex:1 1 120px;min-width:0}
.answer-pickers .file-label {display:none}
@media(hover:hover) and (pointer:fine){.answer-pickers .answer-camera,.answer-pickers .album-label{display:none}.answer-pickers .file-label{display:inline}}
.answer-preview,.saved-answer-photo {display:grid;gap:5px;justify-items:start;margin:0;min-width:0;text-align:left}
.answer-preview img,.saved-answer-photo img {max-width:100%;max-height:220px;object-fit:contain;border-radius:6px}
.answer-preview figcaption {overflow-wrap:anywhere}
.answer-status:empty {display:none}
.feedback {border-top:1px solid #cbd6c0;padding-top:11px;display:grid;gap:7px}
.actions {display:flex;align-items:center;flex-wrap:wrap;gap:9px}
.review-link {text-align:left;width:100%;padding:10px 0;border-bottom:1px solid var(--line);display:flex;align-items:center;gap:8px;justify-content:space-between;overflow-wrap:anywhere}
.record {width:100%;text-align:left;display:flex;justify-content:space-between;gap:15px;align-items:center;padding:18px 2px;border-bottom:1px solid var(--line)}
.record strong {display:block;overflow-wrap:anywhere;line-height:1.7}.record .icon {flex:none}
.file-preview {display:grid;gap:8px;color:var(--ink);text-align:left;overflow-wrap:anywhere}
.file-preview img {display:block;max-width:100%;max-height:240px;object-fit:contain;background:var(--pale);border-radius:7px}
.view-original {max-width:100%;height:auto;display:block}.original-link {display:inline-flex;align-items:center;gap:7px;min-height:44px}
#toast {position:fixed;bottom:max(20px,env(safe-area-inset-bottom));left:50%;transform:translateX(-50%);z-index:20;background:var(--ink);color:white;border-radius:8px;padding:10px 16px;max-width:90%;width:max-content;box-shadow:0 8px 28px #143c3026;pointer-events:none}
#toast:empty {display:none}
@media(min-width:1500px){.portal{grid-template-columns:1.06fr 1fr}.portal-inner{width:390px}.poster::before{background-size:100% 100%}}
@media(max-width:750px){
  .portal {display:flex;flex-direction:column;padding:0;min-height:100vh;min-height:100svh}
  .portal-main {min-height:100vh;min-height:100svh;flex:1;padding:38px 25px}
  .portal-inner {max-width:370px;margin:0}
  .brand {gap:8px;margin-bottom:28px}.brand img {width:153px}
  .poster {display:none}
  .portal-menu{left:14px;top:12px}
  .paper-layout {grid-template-columns:minmax(0,1fr);gap:12px}.paper-side {gap:12px}
  .bar {padding:8px 14px}.container{width:calc(100% - 28px);margin:20px auto 44px}
  .page-head {align-items:flex-start;margin-bottom:16px;gap:8px}.page-head .btn{flex:none}
  .layout-original img {max-height:120px}
  dialog {margin:auto 0 0;width:100%;border-radius:15px 15px 0 0;max-width:100vw;max-height:min(90vh,90vh);max-height:min(90svh,90dvh);padding-bottom:env(safe-area-inset-bottom)}
  .sheet-head{padding:14px 16px 10px}.sheet-body{padding:15px 16px 22px}.upload-actions{margin:-6px -16px;padding:8px 16px 10px}
}
@media (max-width:750px) and (max-height:650px) {
 .portal-main {padding-top:25px;padding-bottom:18px}.brand{margin-bottom:18px}.brand img{width:125px}
 .login-form{gap:8px}.input-row{height:48px}.btn.hero{min-height:49px}
}
@media(prefers-reduced-motion:reduce){*,*::after{animation:none!important;transition:none!important}}

.paper-layout{margin:15px 0}.usage-line{margin-top:16px}.sheet-body a.row-button{text-decoration:none}.question,.practice{scroll-margin-top:14px}.portal .hero:focus-visible{outline-offset:5px}
#viewer{width:min(96vw,980px);max-width:100%;padding-bottom:8px}
#viewer .sheet-head h2{overflow-wrap:anywhere;min-width:0}
#viewer .small{display:inline-flex;margin:8px 16px;align-items:center;min-height:38px}
.view-pane{overflow:auto;max-height:70vh;max-height:70dvh;overscroll-behavior:contain}
.view-pane iframe{display:block;width:100%;height:66vh;height:66dvh;border:0;background:white}
@media(max-width:750px){#viewer{width:100%}}
@font-face{font-family:ZhitiHappy;src:url("/ZCOOLKuaiLe-Regular.ttf") format("truetype");font-display:swap;font-weight:400}
/* The sentences of the circling page's status line use 63 characters. They come from a font of their own, 10 KB in
   place of 1.5 MB; the rule above still serves any other character. tests/test_status_font.py keeps the two in step. */
@font-face{font-family:ZhitiHappy;src:url("/zhiti-happy-status.ttf") format("truetype");font-display:swap;font-weight:400;unicode-range:U+20,U+30-39,U+3001,U+300C-300D,U+4E0A,U+4E2A,U+4EA4,U+4EE5,U+4F20,U+4F4F,U+5148,U+5168,U+518D,U+51E0,U+53EF,U+53F7,U+5708,U+597D,U+5B57,U+5DF2,U+5F20,U+6216,U+62CD,U+63A5,U+63D0,U+65B0,U+6709,U+6790,U+6CA1,U+70B9,U+7167,U+7528,U+7684,U+76EE,U+76F4,U+7B2C,U+7EA2,U+7EBF,U+7EE7,U+7EED,U+8981,U+89E3,U+8FD8-8FD9,U+9053,U+90E8,U+90FD,U+91CD,U+9898,U+FF08-FF09,U+FF0C,U+FF1A}
.home .brand{margin-bottom:20px}
.home-actions{display:grid;gap:10px;grid-auto-rows:1fr}
.home-scope{margin:0 auto 20px;text-align:center;color:#ab2928;font-weight:800;font-size:15px;line-height:1.65;text-wrap:balance}
.home-tools{display:flex;gap:16px;align-items:center;justify-content:space-between;margin-top:14px}
.home-tools .shortcut{min-height:44px;border:1px solid #b8c9ba;background:#fffdf6;padding:.55rem .8rem;font-size:14px}
.home-quota{max-width:52%;min-height:44px;text-align:start;font-size:13px;display:grid;align-content:center;gap:4px}
.home-quota progress.track{width:100%;margin:0;height:4px}
.install-guide{display:grid;gap:10px;line-height:1.7;margin:.5rem 0 1rem}
.install-guide img{border-radius:14px}
.study-output{
  font-family:"Times New Roman",Times,"Liberation Serif",Tinos,"Zhiti Study Latin",SimSun,"宋体","Songti SC",STSong,"Noto Serif CJK SC","Noto Serif SC","Source Han Serif SC","Zhiti Song Common","Zhiti Song",serif;
  line-height:1.85;
  font-synthesis:weight;
}
.study-output strong{font-weight:800;color:#163f32}
.answer-key{margin:1rem 0;padding:14px 18px;border-left:4px solid #d19042;border-radius:6px 12px 12px 6px;background:#fff5da}
.answer-key .study-output{font-size:1.2rem;margin:.3rem 0 0}
.steps.study-steps{padding-left:1.8rem}
.study-steps li{padding:.3rem 0 .4rem .25rem}
.study-steps li::marker{color:#975222;font-weight:bold}
.ask-box{min-width:0;padding:12px 15px;border:1px solid var(--line);background:var(--card);border-radius:12px}
.ask-box h3{font-size:16px;line-height:1.5}
.ask-box .stack{padding-top:9px;gap:8px}
.ask-form .field textarea{min-height:58px}
[data-voice-input][aria-pressed=true]{background:var(--pine);color:#fff}
.qa-pair{margin:1rem 0;background:#f1f5ed;border-radius:10px;padding:12px 16px}
.qa-pair .qlabel:not(:first-child){margin-top:.7rem}
.speech-status:empty{display:none}
.source-question{display:grid;justify-items:start;gap:6px;padding:0;max-width:100%;text-align:start}
.source-thumb{position:relative;display:inline-flex;max-width:100%;border:1px solid #d0dccf;border-radius:7px;overflow:hidden}
.source-thumb img{display:block;max-width:100%;max-height:210px;width:auto;height:auto}
.source-ellipse{position:absolute;border-radius:50%;border:2px solid #b93228;pointer-events:none}
.home-scope span{display:inline-block}
.member-card {display:grid;gap:8px;border:1px solid var(--line);border-radius:12px;padding:13px;background:var(--card);min-width:0;text-align:left}
.portal-inner .member-card {margin:12px 0}
.member-line {display:flex;align-items:center;justify-content:space-between;gap:5px;flex-wrap:wrap}
.member-card .btn {font-size:14px;padding:7px 10px}
.member-card .home-quota {display:grid;gap:4px;text-align:left}
.contact-box {display:grid;gap:12px;padding:16px;background:var(--pale);border-radius:10px}
.contact-box span {display:inline-block;max-width:100%;overflow-wrap:anywhere;user-select:all}
.login-label {font-size:16px;margin:0 0 12px}
.invite-login {display:grid;gap:9px;border-top:1px solid var(--line);margin-top:18px;padding-top:15px}
.invite-login .login-label {margin:0}
.invite-login .btn {background:var(--pale);border-color:#9db19d}
.invite-reminder {margin:0;padding:9px 12px;border-left:4px solid #ad3028;border-radius:5px;background:#fff1e9;color:#81221e;text-align:left;line-height:1.5;font-size:15px}
.invite-reminder strong,.invite-reminder span {display:block}
@media(max-width:750px){
  .login .portal-main {padding-block:18px}
  .login .brand {gap:6px;margin-bottom:18px}
}
@media(max-height:650px) and (max-width:750px){
  .login .brand img:first-child {width:108px}
  .login .brand .lab-signature {width:165px}
  .login .portal-main {padding-block:12px}
  .login .login-label {margin-bottom:4px}
  .invite-login {margin-top:12px;padding-top:10px;gap:6px}
}
#sheet.crop-sheet {padding:0;overflow-y:auto;overscroll-behavior:contain;scroll-padding-top:84px}
.crop-sheet .sheet-head {position:sticky;top:0;z-index:5;background:var(--card);padding-top:max(12px,env(safe-area-inset-top))}
.crop-sheet .sheet-head h2 {flex:1}
.crop-sheet .sheet-head .iconbtn {order:-1}
.ask-form .hold-mic {width:56px;height:56px;flex:0 0 56px;border-radius:50%;display:grid;place-items:center;background:var(--pine);color:white;touch-action:none;user-select:none;-webkit-touch-callout:none}
.ask-form .hold-mic .icon {width:30px;height:30px}
.ask-form [data-toggle-voice] {touch-action:manipulation}
.ask-form .hold-mic[aria-pressed=true] {background:#ab420b;box-shadow:0 0 0 4px #f5d2b9}
.voice-row {display:grid;grid-template-columns:minmax(0,1fr) 75px;align-items:center;gap:10px}
.hold-control {display:grid;justify-items:center;gap:3px;color:var(--muted);font-size:12px;text-align:center}
.solution-figure{margin:1rem 0;min-width:0}
.solution-figure button{display:block;width:100%;padding:0;background:white;border:1px solid #ced8cf;border-radius:.65rem;overflow:hidden;cursor:zoom-in}
.solution-figure img{display:block;width:100%;height:auto;max-height:65vh;object-fit:contain}
.solution-figure figcaption{margin-top:.5rem;color:var(--ink);line-height:1.55}
.work-meter {display:grid;gap:8px;min-width:0;width:100%}
.work-meter-heading,.work-reading {display:flex;align-items:baseline;gap:8px}
.work-meter-heading {justify-content:space-between;color:var(--ink);font-size:.93rem;line-height:1.45}
.work-reading {flex:none;white-space:nowrap;font-variant-numeric:tabular-nums;gap:5px}
.work-reading small {font-size:.74rem;color:var(--muted)}
.work-reading strong {font-size:1.03rem;color:var(--pine)}
.work-progress {display:block;appearance:none;-webkit-appearance:none;width:100%;height:9px;border:0;border-radius:10px;overflow:hidden;background:#e0e7d9;color:var(--pine);accent-color:var(--pine)}
.work-progress::-webkit-progress-bar {background:#e0e7d9;border-radius:10px}
.work-progress::-webkit-progress-value {background:#28654e;border-radius:10px}
.work-progress::-moz-progress-bar {background:#28654e;border-radius:10px}
.recognition-status .work-meter {margin-top:1rem}
.recognition-wait {margin:.5rem 0 0;color:var(--muted);line-height:1.6}
.operation-meter:empty {display:none}
.operation-meter:not(:empty) {padding:.8rem 1rem;background:var(--pale);border-radius:9px}
.solution-request .operation-meter {margin-top:.6rem}
.coach-home {margin:18px 0 12px;text-align:left;padding:20px;background:#fffdf8;box-shadow:0 7px 24px #234b3010}
.coach-heading,.coach-item-head,.coach-progress-item {display:flex;align-items:flex-start;justify-content:space-between;gap:10px}
.coach-heading {align-items:end;margin-bottom:16px}
.coach-heading h2 {font-size:20px;line-height:1.35;letter-spacing:.02em}
.coach-eyebrow {display:block;margin-bottom:3px;color:#668271;font-size:10px;font-weight:750;letter-spacing:.13em}
.coach-count,.coach-status {flex:none;border-radius:20px;background:#e9f0e5;color:#315e46;font-size:12px;font-weight:700;line-height:1.4;padding:4px 8px}
.coach-list {display:grid;gap:10px}
.coach-item {min-width:0;border:1px solid #e1e8d9;border-radius:10px;background:#f7f9f2;padding:14px}
.coach-item-head strong,.coach-progress-item strong {min-width:0;font-size:15px;line-height:1.55;overflow-wrap:anywhere}
.coach-reason {margin:7px 0;color:#455f50;font-size:14px;line-height:1.7;overflow-wrap:anywhere}
.coach-timing {margin:7px 0 0;color:#6b755f;font-size:12px;line-height:1.5}
.coach-actions {display:flex;flex-wrap:wrap;gap:7px;margin-top:12px}
.coach-actions .btn,.coach-progress-item .btn {min-height:40px;padding:7px 11px;font-size:13px}
.coach-footnote {margin:12px 0 0;color:#788577;font-size:12px;line-height:1.6}
.coach-empty {border-radius:9px;background:#f3f6ee;padding:14px;color:#52695b;font-size:14px;line-height:1.7}
.coach-progress {border-top:1px solid var(--line);margin-top:16px;padding-top:16px}
.coach-progress h3 {font-size:16px;margin:0 0 10px}
.coach-progress-item {align-items:center;padding:9px 0;border-bottom:1px solid #edf0e7}
.coach-progress-item .small {font-size:12px}
@media(max-width:360px){.coach-home{padding:16px}.coach-item{padding:12px}.coach-count{font-size:11px}.coach-actions .btn{flex:1 1 auto}}
.mindmap-request {display:grid;justify-items:start;gap:5px;padding:14px;border:1px solid #dbe5d7;border-radius:10px;background:#f8faf5}
.mindmap {display:grid;gap:14px;margin:8px 0;padding:clamp(16px,3vw,24px);border:1px solid #d6caee;border-radius:12px;background:#f7f4fc}
.mindmap h3 {display:inline-flex;align-items:center;justify-self:start;gap:8px;padding:6px 16px 6px 12px;border-radius:20px;background:#5d3f9c;color:#fff;font-size:16px;letter-spacing:.04em}
.mindmap h3 .icon {width:22px;height:22px}
.mindmap-center {justify-self:center;max-width:100%;padding:11px 20px;border-radius:10px;background:#3b2769;color:white;text-align:center;font-weight:700;line-height:1.55;overflow-wrap:anywhere}
.mindmap-branches {position:relative;display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,190px),1fr));gap:12px;padding-top:14px}
.mindmap-branches:before {content:'';position:absolute;top:0;left:50%;height:14px;border-left:2px solid #b7a6dc}
.mindmap-branch {position:relative;min-width:0;border:1px solid #ddd3f0;border-top:3px solid #8a6fc7;border-radius:9px;background:#fffef9;padding:13px 14px}
.mindmap-branch h4 {margin:0 0 8px;color:#3b2769;font-size:15px;line-height:1.55;overflow-wrap:anywhere}
.mindmap-branch ul {margin:0;padding-left:1.2em;color:#3a3350;font-size:14px;line-height:1.7;overflow-wrap:anywhere}
.mindmap-branch li+li {margin-top:5px}
@media(max-width:480px){.mindmap-branches{grid-template-columns:1fr}.mindmap-center{width:100%}.mindmap-branches:before{left:10px;top:0;bottom:20px;height:auto}.mindmap-branch{margin-left:22px}.mindmap-branch:before{content:'';position:absolute;left:-14px;top:20px;width:13px;border-top:2px solid #b7a6dc}}
/* Tablets. Upright, the home page is one column as on a phone: beside the picture the
   buttons would be squeezed into a third of the screen. Controls grow with the screen. */
@media (min-width:751px) and (max-width:1100px) and (orientation:portrait){
  .portal {display:flex;flex-direction:column;padding:0;min-height:100vh;min-height:100svh}
  .portal-main {min-height:100vh;min-height:100svh;flex:1;padding:56px 40px}
  .portal-inner {width:min(100%,500px);margin:0}
  .poster {display:none}
  .portal-menu {left:22px;top:18px}
  .brand {margin-bottom:34px}.brand img {width:215px}.brand .lab-signature {width:250px}
}
@media (min-width:560px) and (max-width:750px){
  .portal-inner {max-width:440px}
}
@media (min-width:560px) and (min-height:600px) and (pointer:coarse){
  .btn.hero {min-height:64px;font-size:19px}
  .btn.invite-home .gift-mark {width:36px;height:36px}
  .home-scope {font-size:17px}
  .home-count {font-size:15px}
  .home-tools .shortcut,.home-tools a {font-size:16px;min-height:48px}
  .member-strip {font-size:16px}
  .tier-card {min-height:76px}.tier-card b {font-size:19px}.tier-card small {font-size:15px}
  .tier-note {font-size:17px}
  .upload-actions .btn {min-height:58px;font-size:18px}
  .btn.capture-back {min-height:50px;font-size:17px}
  .chip {min-height:44px;font-size:16px}
}
@media (min-width:751px) and (min-height:600px) and (pointer:coarse) and (orientation:landscape){
  .portal-inner {width:min(100%,420px)}
}
/* A tablet on its side is short: the five home buttons and the membership line must fit without scrolling. */
@media (min-width:751px) and (min-height:600px) and (max-height:820px) and (pointer:coarse){
  .btn.hero {min-height:54px;font-size:18px}
  .portal-main {padding-block:22px}
  .brand {gap:8px;margin-bottom:18px}.brand img {width:150px}.brand .lab-signature {width:180px}
  .home-scope {margin-bottom:12px;font-size:15px}
  .home-actions {gap:8px}
}
/* The picture on the waiting page. Only transforms, opacity and colour move. */
.recognition-art {display:grid;place-items:center;padding:6px 0 2px}
.recognition-art svg {display:block;width:min(100%,300px);height:auto;overflow:visible}
.art-page {fill:#fffdf6;stroke:#c2cdbd;stroke-width:2}
.art-line {fill:#d9dfce;animation:art-read 3.2s ease-in-out infinite}
.art-line:nth-child(2){animation-delay:.3s}.art-line:nth-child(3){animation-delay:.9s}.art-line:nth-child(4){animation-delay:1.2s}
.art-line:nth-child(5){animation-delay:1.9s}.art-line:nth-child(6){animation-delay:2.2s}
.art-ring {fill:none;stroke:#de2724;stroke-width:3;stroke-linecap:round;stroke-dasharray:100;stroke-dashoffset:0;animation:art-ring 3.2s ease-in-out infinite}
.art-scan {fill:url(#art-glow);animation:art-scan 3.2s linear infinite}
.art-lens {transform:translate(150px,58px);animation:art-lens 6.4s ease-in-out infinite}
.art-lens circle {fill:#ffffffb8;stroke:#184c39;stroke-width:3.5}
.art-lens path {fill:none;stroke:#d88632;stroke-width:6;stroke-linecap:round}
@keyframes art-read {0%,100%{fill:#d9dfce}35%{fill:#7fae92}}
@keyframes art-ring {0%{stroke-dashoffset:100;opacity:1}45%,82%{stroke-dashoffset:0;opacity:1}100%{stroke-dashoffset:0;opacity:0}}
@keyframes art-scan {0%{transform:translateY(0);opacity:0}8%,88%{opacity:1}100%{transform:translateY(158px);opacity:0}}
@keyframes art-lens {0%,100%{transform:translate(88px,36px)}25%{transform:translate(158px,56px)}50%{transform:translate(104px,92px)}75%{transform:translate(160px,130px)}}
/* Adding the site to the home screen: the site's own icon, in colour, says what will appear there. */
.home-tools .shortcut.desktop-home {flex:1;justify-content:center;gap:12px;min-height:54px;padding:8px 14px;border:2px solid #184c39;border-radius:8px;background:#eaf2e2;color:var(--ink);font-size:16px;font-weight:750;box-shadow:0 2px 0 #184c39}
.home-tools .shortcut.desktop-home:hover {background:#dfebd5}
.home-tools .shortcut.desktop-home:active {box-shadow:none}
.desktop-mark {flex:none;width:34px;height:34px;border-radius:8px;display:block}
/* A RAW photo: the way to point at one question before uploading. */
.raw-circle {display:grid;gap:10px;padding:14px;border:2px solid #8a4b12;border-radius:10px;background:#fff7e6}
.raw-circle p {margin:0;line-height:1.7}
.raw-circle .btn {justify-self:start;min-height:50px;padding:8px 18px;font-size:16px}
/* The mind map of a question: one coloured button where the question's tools begin. */
.btn.mindmap-go {min-height:52px;padding:8px 22px;gap:10px;background:#5d3f9c;border:2px solid #3b2769;color:#fff;font-size:17px;font-weight:750;letter-spacing:.04em;box-shadow:0 2px 0 #3b2769}
.btn.mindmap-go:hover {background:#6b4bb0}
.btn.mindmap-go:active {background:#51368a;box-shadow:none}
.btn.mindmap-go .icon {width:24px;height:24px}
.mindmap {scroll-margin-top:84px}
/* The mind map draws itself where the question's tools begin: this is what stands there while it is being drawn. */
.mindmap-wait {display:flex;align-items:center;gap:12px;padding:14px 16px;border:2px solid #3b2769;border-radius:12px;background:#f3eefb;color:#3b2769;scroll-margin-top:84px}
.mindmap-wait .icon {flex:none;width:30px;height:30px;animation:mindmap-draw 1.4s ease-in-out infinite}
.mindmap-wait strong {font-size:17px}
.mindmap-wait .small {margin:2px 0 0;color:#574a78}
@keyframes mindmap-draw {0%,100%{opacity:.4;transform:scale(.9)}50%{opacity:1;transform:scale(1.06)}}
/* 标记已掌握: a coloured closing step on a question. Once marked, the state shows beside the way back. */
.btn.master-mark {min-height:52px;padding:8px 22px;gap:10px;background:#15803d;border:2px solid #0b5226;color:#fff;font-size:17px;font-weight:750;letter-spacing:.04em;box-shadow:0 2px 0 #0b5226}
.btn.master-mark:hover {background:#19913f}
.btn.master-mark:active {background:#126e35;box-shadow:none}
.btn.master-mark .icon {width:24px;height:24px;stroke-width:2.6}
.master-done {display:flex;flex-wrap:wrap;align-items:center;gap:10px}
.master-state {display:inline-flex;align-items:center;gap:6px;min-height:44px;padding:6px 16px 6px 12px;border:2px solid #15803d;border-radius:22px;background:#e4f4e8;color:#0b5226;font-weight:750}
.master-state .icon {width:20px;height:20px;stroke-width:2.6}
.btn.master-undo {min-height:44px;border:1px solid #9fc8ab;color:#0b5226;background:#f6fbf6}
/* Before iOS 15.4 there is no <dialog>: the element is an ordinary one. These rules give it the place, the size and the shade
   the browser gives a real dialog; plainDialog in app.js adds the class and the members the pages call. */
.plain-dialog {display:none;position:fixed;z-index:31;left:50%;top:50%;transform:translate(-50%,-50%);margin:0;overflow:auto;-webkit-overflow-scrolling:touch}
.plain-dialog[open] {display:block;animation:none}
.dialog-shade {position:fixed;z-index:30;top:0;right:0;bottom:0;left:0;background:rgba(16,38,28,.45)}
.dialog-shade[hidden] {display:none}
#viewer.plain-dialog {z-index:33}
.dialog-shade[data-shade=viewer] {z-index:32}
html.plain-dialog-open,html.plain-dialog-open body {overflow:hidden}
#toast {z-index:40}
@media(max-width:750px){.plain-dialog {left:0;right:0;top:auto;bottom:0;transform:none;margin:0}}
/* 重新拍照上传: the whole button is the camera input, so one tap opens the camera. */
.btn.retake-photo {position:relative;min-height:54px;gap:10px;font-size:17px;cursor:pointer;background:#f7a935;border:2px solid #8a4b12;color:#2e1a04;font-weight:750;box-shadow:0 2px 0 #8a4b12}
.btn.retake-photo:hover {background:#fabb5c}
.btn.retake-photo:active {background:#ea982a;box-shadow:none}
.btn.retake-photo input[type=file] {position:absolute;top:0;right:0;bottom:0;left:0;width:100%;height:100%;margin:0;opacity:0;cursor:pointer}
.btn.retake-photo:focus-within {outline:3px solid var(--ink);outline-offset:2px}
/* A trial opened with an invitation code: the password screen, the move to the phone's browser, the way to the home screen. */
.welcome-card {display:grid;gap:12px}
.welcome-card .login-label {margin:0;font-size:19px}
.welcome-line {display:flex;flex-wrap:wrap;align-items:baseline;justify-content:space-between;gap:0 12px;margin:0;padding:12px 16px;border:1px solid #c6d0bf;border-radius:8px;background:#f2f6ec}
.welcome-line span {flex:none;color:#4d6455;font-size:15px}
.welcome-line b {flex:1 1 auto;min-width:0;font-size:26px;letter-spacing:.08em;color:var(--ink);overflow-wrap:anywhere;text-align:right;user-select:all;-webkit-user-select:all}
.welcome-field {font-weight:650;font-size:15px;margin-bottom:-4px}
.welcome-card .input-row input {font-size:19px;letter-spacing:.04em}
.welcome-shot {display:flex;gap:9px;align-items:flex-start;margin:0;padding:9px 12px;border-left:4px solid #ad3028;border-radius:5px;background:#fff1e9;color:#81221e;line-height:1.5;font-size:15px}
.welcome-shot .icon {flex:none;width:21px;height:21px;margin-top:1px}
.welcome-next h3 {margin:0;font-size:17px}
.welcome-why .small {margin:0}
.welcome-next .welcome-line b {font-size:22px}
.welcome-next .welcome-line b.long {font-size:17px;letter-spacing:.04em}
.welcome-steps {margin:0;padding-left:1.4em;display:grid;gap:5px;line-height:1.6;font-size:16px}
.welcome-steps small {display:block;color:var(--muted);font-size:14px}
.term {white-space:nowrap}
.install-inner {width:min(100%,470px);margin-top:0}
.install-map {margin:0;gap:10px}
.install-map .mindmap-branches {grid-template-columns:1fr;gap:9px}
.install-map details.mindmap-branch {padding:0}
.install-map summary {box-sizing:border-box;min-height:44px;padding:9px 14px;color:#3b2769;font-size:15px;font-weight:650;line-height:1.7}
.install-map details summary:hover {color:#3b2769}
.install-map details ul {padding:0 14px 12px 2.5em}
.btn.install-tutorial {margin-top:10px;min-height:42px;padding:5px 14px;border-color:#b7a6dc;background:#f7f4fc;color:#3b2769;font-size:14px}
.install-map .mindmap-branch.here {border-color:#8a6fc7;border-width:2px;border-top-width:4px;background:#fff}
.install-map .here-mark {position:absolute;top:-13px;right:12px;padding:2px 10px;border-radius:11px;background:#5d3f9c;color:#fff;font-size:12px;font-weight:650;line-height:1.5;white-space:nowrap}
.install-actions {display:grid;gap:4px;margin-top:14px}
@media(max-width:750px){
  .portal.install .portal-main {place-items:start center;padding-bottom:0}
  .install-actions {position:sticky;bottom:0;z-index:1;margin-top:4px;padding:14px 0 10px;background:linear-gradient(rgba(248,246,238,0),var(--cream) 14px)}
}
.btn.text-button {border-color:transparent;background:transparent;color:#4d6455;min-height:40px;font-weight:500;text-decoration:underline;text-underline-offset:.2em}
