:root{font-family:'DM Sans','PingFang SC','Hiragino Sans GB','Noto Sans SC','Microsoft YaHei',system-ui,sans-serif;color:#242824;background:#f4f3ed}*{box-sizing:border-box}body{margin:0}button,input,textarea{font:inherit}button,a{cursor:pointer}.top{height:74px;padding:0 max(24px,calc((100vw - 1120px)/2));display:flex;align-items:center;justify-content:space-between;background:#f4f3ed;border-bottom:1px solid #dedfd8}.top a{color:#565d54;text-decoration:none}.brand{font-size:20px;font-weight:700}.brand i{font-style:normal;color:#9cac8b}main{max-width:1120px;margin:auto;padding:34px 24px 100px}.hero{background:#e5e9dc;border-radius:22px;padding:50px 58px 30px;min-height:365px;display:flex;flex-direction:column;align-items:flex-start}.eyebrow{font-size:11px;font-weight:700;letter-spacing:.18em;color:#728366}.hero h1{font-size:clamp(34px,5vw,60px);line-height:1.18;letter-spacing:-.04em;margin:20px 0}.hero h1 em{font-style:normal;color:#697f5d}.hero p{max-width:610px;line-height:1.85;color:#596457;margin:0}.hero-bottom{display:flex;justify-content:space-between;align-items:center;align-self:stretch;margin-top:auto;padding-top:32px;color:#687565;font-size:13px}.hero-bottom #progress{font-weight:700;color:#38513e}.upload{display:flex;align-items:center;gap:28px;flex-wrap:wrap;margin:24px 0 50px;padding:25px 30px;border:1px solid #dce1d7;border-radius:18px;background:#fff}.upload h2,.section-heading h2{margin:0 0 8px;font-size:23px}.upload p{margin:0;color:#747d71;font-size:14px}.upload-button,.primary{margin-left:auto;border:0;border-radius:10px;background:#2d5438;color:white;padding:14px 20px;font-weight:600;white-space:nowrap}.upload-button input{display:none}#upload-state{font-size:13px;color:#526854}.section-heading{display:flex;justify-content:space-between;align-items:end;margin-bottom:17px}.section-heading h2{margin:6px 0 0}.section-heading>span{color:#768073;font-size:13px}#items{display:grid;gap:10px}.item{display:flex;align-items:center;gap:18px;padding:20px 24px;width:100%;border:1px solid #e1e4dc;border-radius:15px;background:#fff;text-align:left;color:inherit}.item:hover{border-color:#7b9676;transform:translateY(-1px)}.number{width:42px;height:42px;border-radius:10px;background:#e9eee5;color:#4b694b;display:grid;place-items:center;font-weight:700}.item .text{flex:1;min-width:0}.item strong{display:block;font-size:16px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.item small{display:block;margin-top:7px;color:#869084}.state{font-size:13px;color:#6a7968;padding:8px 12px;background:#edf1e9;border-radius:99px}.state.ready{background:#daeadc;color:#28643a}.state.review{background:#f6ebd7;color:#805f2d}dialog{width:min(940px,calc(100vw - 28px));max-height:calc(100vh - 38px);padding:0;border:0;border-radius:20px;box-shadow:0 25px 80px #1b302744;overflow:auto}dialog::backdrop{background:#17251ab3}.close{position:sticky;top:12px;float:right;z-index:5;border:0;background:#fff;border-radius:99px;width:42px;height:42px;font-size:28px;color:#627461;box-shadow:0 2px 10px #0002;margin:12px}.detail-content{padding:50px clamp(22px,6vw,68px) 68px}.detail-content h1{font-size:clamp(26px,4vw,42px);margin:12px 0 14px}.detail-content .problem{line-height:1.9;background:#f6f7f2;border-left:4px solid #829e77;padding:16px 20px;white-space:pre-wrap}.stage{color:#667664;font-size:14px}.board{margin-top:34px;border-radius:20px;background:#f9faf6;padding:30px}.board-head{border-bottom:1px solid #dee5d9;padding-bottom:20px}.board-head h2{font-size:26px;margin:4px 0}.board-head p{color:#647260;margin:0}.diagram{width:100%;max-height:320px;margin:22px auto;background:#fff;border-radius:14px}.step{display:grid;grid-template-columns:38px 1fr;gap:14px;margin:24px 0}.step-num{background:#dfe9d9;color:#385d40;border-radius:99px;width:34px;height:34px;display:grid;place-items:center;font-weight:700}.step h3{margin:2px 0 9px}.step p{line-height:1.8;margin:5px 0}.step .math{font-family:Georgia,serif;color:#26452f;background:#edf2e9;border-radius:9px;padding:12px 15px;overflow:auto}.why{color:#566751}.answer{border-top:1px solid #dee5d9;padding-top:22px;font-size:20px;font-weight:700}.actions{display:flex;gap:10px;flex-wrap:wrap;margin-top:30px}.actions button{margin:0}.secondary{border:1px solid #aac0a4;color:#355b39;border-radius:10px;background:#fff;padding:13px 18px}.teach{margin-top:30px;padding:24px;border-radius:14px;background:#eaf0e5}.teach textarea,.reflection textarea{width:100%;min-height:85px;border:1px solid #c5d4c0;border-radius:10px;padding:12px;resize:vertical;margin:12px 0}.teach-log{display:grid;gap:12px;margin:14px 0}.bubble{padding:13px 16px;border-radius:12px;line-height:1.7;background:#fff}.bubble.me{background:#d7e5d5;margin-left:10%}.muted{color:#788376}.models{margin-top:30px;font-size:13px;color:#6d796c}.models summary{cursor:pointer}.models table{border-collapse:collapse;width:100%;margin-top:10px}.models td,.models th{padding:8px;text-align:left;border-bottom:1px solid #e1e5de}@media(max-width:650px){.top{height:60px}.hero{padding:34px 28px;min-height:380px}.hero-bottom{align-items:start;gap:12px;flex-direction:column}.upload{padding:22px}.upload-button{margin-left:0}.item{padding:15px;gap:12px}.state{font-size:11px}.detail-content{padding-top:55px}}
.learning{margin-top:36px;padding:24px;border:1px solid #dfe8db;border-radius:14px;background:#f7f9f4}.learning h2{margin-top:0}.learning p{line-height:1.8}.learning summary{cursor:pointer;margin:18px 0}.learning .teach-log{max-height:420px;overflow:auto}.learning .secondary{margin-top:14px}
.source-diagram{display:block;max-width:100%;max-height:300px;object-fit:contain;margin:22px auto;border:1px solid #e2e8de;border-radius:12px;background:#fff;padding:12px}.problem .katex-display{margin:.4em 0}.step .math .katex-display{margin:.6em 0}.step .math{line-height:1.75}
.standard-diagram{margin:20px 0;padding:14px;background:#fff;border:1px solid #e2e8de;border-radius:12px;text-align:center}.standard-diagram svg{width:100%;max-height:290px}.standard-diagram text{font:17px 'DM Sans',sans-serif;fill:#3b593d}.standard-diagram figcaption{color:#6d7e6b;font-size:13px;margin-top:4px}
.board-diagram,.source-figure{margin:20px 0;padding:14px;background:#fff;border:1px solid #e2e8de;border-radius:12px;text-align:center}.board-diagram .diagram,.source-figure .source-diagram{margin:0 auto}.board-diagram figcaption,.source-figure figcaption{color:#60715e;font-size:12px;line-height:1.6;margin-top:8px}
.prepared-reference{margin:20px 0;border:1px solid #dce5d8;border-radius:14px;background:#f8faf6}.prepared-reference>summary{cursor:pointer;padding:17px 20px;color:#375840;font-weight:700}.prepared-reference .board{margin:0;border-radius:0 0 14px 14px}.detail-content>.actions{margin:22px 0 30px}.detail-content>.actions .primary{margin-left:0}
.speak-step{margin-left:10px;border:1px solid #b5cab0;background:#fff;color:#426746;border-radius:99px;padding:5px 11px;font-size:12px;font-weight:600;vertical-align:middle}.speak-step:disabled{opacity:.6}
.upload .billing-policy{margin-top:10px;max-width:680px;color:#506a54;font-size:12px;line-height:1.65}.billing-policy #balance-note{font-weight:700}.models p{line-height:1.8;padding:10px 0}
.prep-progress{margin:18px 0 24px;padding:18px 20px;border:1px solid #dce6d7;border-radius:12px;background:#f7faf5}.prep-progress p{margin:0 0 14px;color:#355b39;font-weight:700}.prep-progress ol{display:flex;flex-wrap:wrap;gap:8px;list-style:none;margin:0 0 12px;padding:0}.prep-progress li{padding:7px 10px;border-radius:8px;background:#e9ece7;color:#7b857b;font-size:12px}.prep-progress li.done{background:#e0ecdf;color:#55745a}.prep-progress li.current{background:#2d5438;color:#fff}.prep-progress small{display:block;color:#68766a;line-height:1.6}

.timing{color:#506a54;line-height:1.7;font-size:14px}.input-recovery{margin:20px 0;padding:18px;background:#f8faf6;border:1px solid #dce5d8;border-radius:12px}.input-recovery p{line-height:1.7}.input-recovery .upload-button{display:inline-flex}.input-recovery input[type=file]{max-width:100%}#queue-status{max-width:60%;line-height:1.7;text-align:right}
@media(max-width:600px){#queue-status{max-width:55%;font-size:12px}.input-recovery{padding:14px}}

.recovery-photo{display:block;width:100%;height:auto;max-height:420px;object-fit:contain;margin-top:12px}.input-recovery summary{cursor:pointer;color:#375840}
.step{grid-template-columns:38px minmax(0,1fr)}.step>div:last-child{min-width:0}.step .math{max-width:100%}.math-line{max-width:100%;overflow-x:auto;overflow-y:hidden}.math-line+.math-line{margin-top:8px}.math-line .katex-display{margin:.2em 0}.board,.prepared-reference,.detail-content{min-width:0}
.math-scroll-hint{font-family:'DM Sans','Noto Sans SC',sans-serif;font-size:12px;color:#5a705d;margin:0 0 8px!important}.math-line:focus-visible{outline:2px solid #729678;outline-offset:2px}@media(max-width:600px){.step .math{font-size:13px}}

/* Keep each long equation reachable without scrolling the whole explanation. */
.step .math .katex-display{max-width:100%;overflow-x:auto;overflow-y:hidden;text-align:left;padding-bottom:8px}.step .math .katex-display>.katex{text-align:left}
.hidden{display:none!important}
.monitor-panel{margin:20px 0 42px;padding:22px 24px;border:1px solid #dce1d7;border-radius:18px;background:#fff}
.monitor-header{display:flex;justify-content:space-between;align-items:center;gap:12px;flex-wrap:wrap;margin-bottom:16px}
.monitor-header h2{margin:4px 0 0;font-size:20px}
.monitor-actions{display:flex;align-items:center;gap:10px;font-size:13px}
.monitor-cards{display:grid;grid-template-columns:repeat(auto-fit,minmax(210px,1fr));gap:12px;margin-bottom:18px}
.m-card{padding:14px 16px;border-radius:12px;background:#f7faf5;border:1px solid #e1e8dd;display:flex;flex-direction:column;gap:4px}
.m-label{font-size:12px;color:#68766a;font-weight:600}
.m-val{font-size:18px;color:#273a29}
.m-sub{font-size:12px;color:#6c7a6e}
.monitor-grids{display:grid;grid-template-columns:repeat(auto-fit,minmax(300px,1fr));gap:16px;margin-bottom:16px}
.monitor-box,.monitor-table-wrap{overflow-x:auto}
.monitor-box h3{margin:0 0 8px;font-size:15px}
.monitor-panel table{width:100%;border-collapse:collapse;font-size:13px;min-width:520px}
.monitor-panel th,.monitor-panel td{padding:8px 10px;text-align:left;border-bottom:1px solid #e6ebe2;white-space:nowrap;vertical-align:top}
.monitor-table-wrap summary{cursor:pointer;font-weight:600;color:#355b39;padding:8px 0}

/* 11-04 删除按钮 + 切换孩子 */
.item-row{display:flex;align-items:stretch;gap:8px}.item-row .item{flex:1;min-width:0}
.item-del{flex:none;border:1px solid #e1e4dc;background:#fff;color:#8a6a5d;border-radius:15px;padding:0 14px;font-size:13px;cursor:pointer;min-width:64px}
.item-del:hover{border-color:#c98b78;color:#a4472f}.item-del.arm{background:#a4472f;color:#fff;border-color:#a4472f}
.hp-undo{position:fixed;left:50%;bottom:calc(24px + env(safe-area-inset-bottom,0px));transform:translateX(-50%);background:#2c3a30;color:#fff;padding:10px 12px 10px 18px;border-radius:999px;display:flex;gap:12px;align-items:center;z-index:50;font-size:14px;box-shadow:0 8px 24px #0003}
.hp-undo[hidden]{display:none}.hp-undo button{border:0;background:#f3d48a;color:#2c3a30;border-radius:999px;padding:6px 14px;font-weight:700;cursor:pointer}
.kid-switch{display:flex;gap:8px;flex-wrap:wrap;padding:10px max(24px,calc((100vw - 1120px)/2));background:#f4f3ed;border-bottom:1px solid #dedfd8}
.kid-switch[hidden]{display:none}
.kid-switch .kid{border:1px solid #d6dacf;background:#fff;border-radius:999px;padding:6px 14px;font-size:14px;cursor:pointer;color:#33402f}
.kid-switch .kid small{margin-left:6px;color:#869084}.kid-switch .kid.on{background:#2f4e3a;color:#fff;border-color:#2f4e3a}.kid-switch .kid.on small{color:#cfe0c9}
@media(max-width:600px){.kid-switch{padding:8px 16px}.item-del{min-width:54px;padding:0 10px}}

/* 11-22 命题4（方案A）：破题思考方向卡片 + 醒目绿色进课堂主按钮 + 默认收起备课详案折叠栏 */
.detail-content{padding:36px clamp(22px,5vw,56px) 52px}
.detail-content h1{font-size:clamp(24px,3.2vw,34px);margin:8px 0 10px}
.detail-content>.board-diagram,.detail-content>.source-figure{margin:14px 0;padding:10px 14px}
.detail-content>.board-diagram .diagram{max-height:190px;margin:0 auto}
.hp-roadmap-card{margin:16px 0 18px;padding:16px 20px;border-radius:16px;background:linear-gradient(180deg,#f2f8f3 0%,#fafcf9 100%);border:1px solid #cce0d0}
.hp-roadmap-head{font-size:14px;font-weight:700;color:#205437;margin-bottom:12px;letter-spacing:.01em}
.hp-roadmap-list{list-style:none;margin:0;padding:0;display:grid;gap:10px}
.hp-roadmap-list li{display:grid;grid-template-columns:26px minmax(0,1fr);gap:10px;align-items:start;padding:10px 12px;border-radius:11px;background:#fff;border:1px solid #e1ece3}
.hp-roadmap-idx{width:24px;height:24px;border-radius:99px;background:#dff0e4;color:#1d5e3a;font-size:12.5px;font-weight:700;display:grid;place-items:center;margin-top:1px}
.hp-roadmap-text{font-size:14.5px;line-height:1.68;color:#253528}
.actions.hero-actions{margin:22px 0 24px;display:flex;gap:12px;flex-wrap:wrap;align-items:center}
.actions.hero-actions .cta-tutor{background:linear-gradient(135deg,#1d7a46 0%,#166238 100%);color:#fff;padding:15px 24px;border-radius:12px;font-size:16px;font-weight:700;box-shadow:0 8px 22px rgba(24,104,60,.24);transition:transform .16s ease,box-shadow .16s ease}
.actions.hero-actions .cta-tutor:hover{transform:translateY(-1px);box-shadow:0 12px 26px rgba(24,104,60,.32)}
.actions.hero-actions .secondary{padding:14px 20px;border-radius:12px;font-weight:600;border-color:#9db9a3;color:#254d32}
.actions.hero-actions .cta-teach-bounty{background:linear-gradient(135deg,#f59e0b 0%,#d97706 100%);color:#fff;border:0;padding:15px 22px;border-radius:12px;font-size:15.5px;font-weight:800;box-shadow:0 8px 22px rgba(217,119,6,.28);transition:transform .16s ease,box-shadow .16s ease}
.actions.hero-actions .cta-teach-bounty:hover{transform:translateY(-1px);box-shadow:0 12px 28px rgba(217,119,6,.38)}
.actions.hero-actions .cta-teach-cert{background:linear-gradient(135deg,#1e293b 0%,#0f172a 100%);color:#fde68a;border:1.5px solid #f59e0b;padding:14px 20px;border-radius:12px;font-size:14.5px;font-weight:800;box-shadow:0 6px 18px rgba(15,23,42,.2)}
.teach-leo-badge{display:inline-flex;align-items:center;gap:4px;margin-left:8px;padding:3px 11px;border-radius:999px;background:linear-gradient(135deg,#fef3c7,#fde68a);border:1px solid #f59e0b;color:#92400e;font-size:12.5px;font-weight:800}
.teach-leo-badge.is-progress{background:#eff6ff;border-color:#60a5fa;color:#1d4ed8}
.hp-item-taught-pill{display:inline-block;margin-left:6px;padding:2px 8px;border-radius:999px;background:#fef3c7;border:1px solid #f59e0b;color:#92400e;font-size:11.5px;font-weight:800;vertical-align:middle}
.prepared-reference{margin:24px 0 6px;border:1px dashed #c5d6c7;border-radius:14px;background:#f8faf7}
.prepared-reference>summary{list-style:none;cursor:pointer;padding:15px 20px;color:#4a6650;font-size:14.5px;font-weight:650;display:flex;align-items:center;gap:8px;user-select:none}
.prepared-reference>summary::-webkit-details-marker{display:none}
.prepared-reference[open]{border-style:solid;border-color:#dce5d8}
.prepared-reference[open]>summary{border-bottom:1px solid #e2ebe0;color:#274a31}
@media(max-width:650px){.actions.hero-actions{flex-direction:column;align-items:stretch}.actions.hero-actions button{width:100%;text-align:center}}

/* #149 难题馆拆分独立「📷 拍照录题」实时摄像头取景与「🖼️ 上传照片」双入口 */
.upload-actions{margin-left:auto;display:flex;align-items:center;gap:10px;flex-wrap:wrap}
.upload-actions .upload-button{margin-left:0;display:inline-flex;align-items:center;justify-content:center;gap:6px;cursor:pointer;transition:transform .15s,background .15s,border-color .15s}
.upload-button:hover{transform:translateY(-1px)}
.upload-button.is-secondary{background:#f3f6f2;color:#274730;border:1.5px solid #bfd2c2}
.upload-button.is-secondary:hover{background:#e7f0e6;border-color:#7c9e82}
.input-recovery-actions{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin-top:10px}
.input-recovery-actions .upload-button{margin-left:0}
@media(max-width:650px){.upload-actions{margin-left:0;width:100%}}

/* 11-30 蘑菇家长反馈优化：日常拍题/错题本快车道指路 + 列表行直出「↻ 重试生成讲解」按钮 + 0 扣费定心丸标识 */
.upload .fast-lane-tip{margin-top:8px;max-width:680px;padding:7px 12px;border-radius:10px;background:#f2f7f2;border:1px solid #d4e4d6;color:#2e5136;font-size:12.5px;line-height:1.6}
.upload .fast-lane-tip a{color:#1b6b3a;font-weight:700;text-decoration:underline;text-underline-offset:2px}
.hp-zero-charge-pill{display:inline-block;margin-left:6px;padding:2px 8px;border-radius:999px;background:#e6f5ec;border:1px solid #9dd4b1;color:#1b6543;font-size:11.5px;font-weight:700;vertical-align:middle}
.hp-zero-charge-banner{margin:14px 0 16px;padding:12px 16px;border-radius:12px;background:#edf8f1;border:1px solid #b5dfc3;color:#1f5135;font-size:13.5px;line-height:1.68}
.hp-zero-charge-banner a{color:#155e34;font-weight:700;text-decoration:underline}
.item-retry{flex:none;border:1.5px solid #2d5438;background:#2d5438;color:#fff;border-radius:15px;padding:0 16px;font-size:13px;font-weight:700;cursor:pointer;white-space:nowrap;transition:background .15s,transform .15s}
.item-retry:hover:not(:disabled){background:#1f3f28;border-color:#1f3f28;transform:translateY(-1px)}
.item-retry:disabled{opacity:.65;cursor:wait}
.item-retry.is-photo{background:#eef5ef;color:#274d31;border-color:#93b69a}
.item-retry.is-photo:hover:not(:disabled){background:#dfece1}
.cta-retry-modal{padding:14px 22px;border-radius:12px;font-size:15px;font-weight:700}
.standard-diagram.qw-hard-widget{margin:12px 0;padding:12px 16px;border-radius:12px;background:#fffdf8;border:1px solid #e2e6dc;overflow-x:auto}
.standard-diagram.qw-hard-widget svg{max-width:100%;height:auto;display:block;margin:4px auto}
.source-figure{margin:14px 0;padding:12px 14px;border-radius:14px;background:#fff;border:1px solid #dde4da;text-align:center}
.source-figure .source-diagram{max-width:100%;max-height:360px;width:auto;height:auto;border-radius:10px;display:block;margin:0 auto}
.source-figure figcaption{margin-top:8px;font-size:12.5px;color:#5e6e5d}
@media(max-width:650px){body{overflow-x:hidden}main{padding:20px 14px 90px;max-width:100vw}.upload>div:first-child{min-width:0;max-width:100%}.upload-actions .upload-button{flex:1 1 auto;padding:12px 14px;font-size:13.5px}.item-row{flex-wrap:wrap;max-width:100%}.item-row .item{flex:1 1 100%;max-width:100%;flex-wrap:wrap}.item strong{white-space:normal}.item .state{margin-left:auto}.item-retry,.item-del{flex:1 1 calc(50% - 6px);min-height:42px;border-radius:11px;text-align:center}}

/* 12-03 手机端拍题框题与首屏触控体验全面适配 */
body:has(.xqbar) header.top{padding-left:max(156px,calc((100vw - 1120px)/2))}
dialog#detail[open]:not(:modal){position:fixed;inset:0;z-index:2147483005;width:100vw;max-width:none;height:100vh;height:100dvh;max-height:none;margin:0;border-radius:0;overflow:auto}
@media(max-width:680px){
  body:has(.xqbar) header.top{height:58px;padding:0 14px 0 150px;gap:8px}
  .brand{font-size:16.5px;white-space:nowrap}
  #child-name{font-size:13px;max-width:96px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
  main{padding:12px 14px calc(76px + env(safe-area-inset-bottom));display:flex;flex-direction:column}
  main > .xqf-banner{order:2;margin:0 0 24px}
  main > .list{order:3}
  main > .monitor-panel{order:4}
  .hero{min-height:0;padding:18px 18px 15px;border-radius:18px}
  .hero h1{font-size:25px;line-height:1.22;margin:8px 0}
  .hero p{font-size:13px;line-height:1.58}
  .hero-bottom{padding-top:12px;gap:6px;font-size:12px;flex-direction:row;flex-wrap:wrap;justify-content:space-between;align-items:center}
  .upload{padding:16px;margin:14px 0 28px;gap:12px;border-radius:16px}
  .upload h2{font-size:19px;margin:0 0 6px}
  .upload p{font-size:13px;line-height:1.55}
  .upload-actions{order:-2;width:100%;display:grid;grid-template-columns:1fr 1fr;gap:9px;margin:0}
  .upload-actions #camera-btn{grid-column:1 / -1;min-height:50px;font-size:16px;font-weight:700;border-radius:13px;box-shadow:0 6px 16px rgba(45,84,56,.22)}
  .upload-actions .upload-button.is-secondary{min-height:44px;padding:10px 8px;font-size:13px;border-radius:12px;text-align:center;white-space:normal;line-height:1.25}
  #upload-state:not(:empty){order:-1;width:100%;padding:8px 12px;border-radius:10px;background:#eef6f0;color:#234d30;font-weight:600}
  dialog#detail{width:100vw;max-width:none;height:100vh;height:100dvh;max-height:100dvh;margin:0;border-radius:0}
  .detail-content{padding:28px 16px calc(48px + env(safe-area-inset-bottom))}
  .board{padding:18px 14px;margin-top:20px;border-radius:16px}
  .input-recovery-actions{display:grid;grid-template-columns:1fr;gap:9px}
  .input-recovery-actions .upload-button{width:100%;min-height:46px;justify-content:center}
}
