*{box-sizing:border-box}html,body{margin:0;min-height:100%;font-family:Inter,"Microsoft YaHei",Arial,sans-serif;color:#27304b;background:#f7f8ff}button,input,select,textarea{font:inherit}button{cursor:pointer}body{overflow-x:hidden}.hidden{display:none!important}.toast{position:fixed;left:50%;top:22px;transform:translate(-50%,-20px);background:#24283d;color:#fff;padding:11px 18px;border-radius:14px;z-index:1000;opacity:0;pointer-events:none;transition:.2s;max-width:min(90vw,640px);text-align:center}.toast.show{opacity:1;transform:translate(-50%,0)}.login-shell{min-height:100vh;display:grid;grid-template-columns:minmax(360px,520px) minmax(420px,1fr);gap:clamp(30px,6vw,100px);align-items:center;padding:clamp(30px,7vw,110px);background:linear-gradient(135deg,#fff 0 46%,#f0efff 46% 100%)}.login-card{background:#fff;border-radius:30px;padding:clamp(28px,4vw,48px);box-shadow:0 28px 80px rgba(91,92,150,.16);max-width:520px}.login-brand{display:flex;gap:16px;align-items:center;margin-bottom:34px}.brand-mark{width:58px;height:58px;border-radius:18px;display:grid;place-items:center;color:#fff;font-weight:900;font-size:30px;background:linear-gradient(135deg,#6d5cff,#966dff);box-shadow:0 12px 30px #6d5cff45}.brand-mark.small{width:38px;height:38px;border-radius:12px;font-size:20px;box-shadow:none}.login-brand h1{margin:0;font-size:34px}.login-brand p{margin:4px 0 0;color:#7f87a1}.login-form{display:grid;gap:14px}.login-form input,.field,select,textarea{width:100%;border:1px solid #e6e8f4;background:#fbfbff;border-radius:14px;padding:12px 14px;outline:none;color:#30364f;transition:.2s}.login-form input:focus,.field:focus,select:focus,textarea:focus{border-color:#7667ff;box-shadow:0 0 0 4px #7667ff14}.btn{border:0;border-radius:13px;padding:10px 15px;font-weight:800;background:#eceeff;color:#525a79}.btn.big{padding:14px}.btn.primary{background:linear-gradient(135deg,#635bff,#8a66ff);color:#fff}.btn.orange{background:#fff0d5;color:#ae6900}.btn.green{background:#dcfaee;color:#12835e}.btn.red{background:#ffe3e8;color:#c6395a}.btn.ghost{background:#f4f5fb;color:#626b87}.btn.danger{background:#fff0f2;color:#ca3f58}.btn.small{padding:7px 10px;font-size:12px}.btn:disabled{opacity:.45;cursor:not-allowed}.demo-row{display:flex;gap:10px;margin-top:16px}.demo-row button{border:0;background:transparent;color:#8a90a7;font-size:12px}.login-art{position:relative;min-height:520px;display:flex;flex-direction:column;justify-content:center;align-items:flex-start;padding:50px;overflow:hidden}.login-art h2{font-size:clamp(48px,7vw,96px);line-height:.96;margin:24px 0;color:#443f75;letter-spacing:-4px}.pill{display:inline-flex;padding:7px 12px;border-radius:99px;background:#ffdd63;color:#654f00;font-size:12px;font-weight:900}.orbit{position:absolute;border:2px dashed #a79bff55;border-radius:50%}.o1{width:330px;height:330px;right:7%;top:14%}.o2{width:230px;height:230px;right:20%;bottom:10%}.bubble-word{position:absolute;padding:12px 18px;border-radius:18px;font-weight:900;box-shadow:0 12px 24px #554f8f18}.w1{right:10%;top:20%;background:#d9fbec;color:#137451}.w2{right:27%;top:49%;background:#ffe4a3;color:#9b6300}.w3{right:5%;bottom:17%;background:#ffdbe7;color:#a73b61}.topbar{height:68px;display:flex;align-items:center;justify-content:space-between;padding:0 clamp(16px,3vw,40px);background:#fff;border-bottom:1px solid #eef0f7;position:sticky;top:0;z-index:20}.brand-area,.user-area,.user-chip{display:flex;align-items:center}.brand-area{gap:11px}.brand-text{display:grid}.brand-text strong{font-size:17px}.brand-text span{font-size:11px;color:#9399ad}.user-area{gap:12px}.user-chip{gap:9px}.user-chip strong,.user-chip span{display:block}.user-chip span{font-size:10px;color:#9298ad}.avatar{width:36px;height:36px;border-radius:50%;display:grid;place-items:center;background:#ffe4a9;color:#8d5c00;font-weight:900}.icon-btn{border:0;background:#f1f2f8;width:38px;height:38px;border-radius:12px}.shell-grid{display:grid;grid-template-columns:210px minmax(0,1fr);min-height:calc(100vh - 68px)}.sidebar{background:#fff;border-right:1px solid #eef0f7;padding:22px 12px}.nav-group{display:grid;gap:7px}.nav-group button{border:0;background:transparent;border-radius:14px;padding:11px 13px;display:flex;gap:11px;align-items:center;color:#717992;text-align:left}.nav-group button span{width:26px;text-align:center;font-weight:900}.nav-group button.active{background:#efedff;color:#5b51df}.main-content{padding:clamp(18px,3vw,38px);min-width:0}.view{display:none;max-width:1560px;margin:auto}.view.active-view{display:block}.page-head{display:flex;align-items:end;justify-content:space-between;gap:18px;margin-bottom:22px}.page-head h1{margin:0;font-size:clamp(25px,2.2vw,36px);letter-spacing:-1px}.page-head p{margin:5px 0 0;color:#9298ad;font-size:13px}.page-actions{display:flex;gap:9px;flex-wrap:wrap}.eyebrow{font-size:11px;font-weight:900;color:#7868ff;letter-spacing:1.2px;margin-bottom:6px}.hero{border-radius:28px;padding:clamp(24px,4vw,46px);background:linear-gradient(120deg,#6a5eff,#9271ff 55%,#ff94be);color:#fff;display:grid;grid-template-columns:1.2fr .8fr;gap:28px;min-height:250px;overflow:hidden;position:relative}.hero h1{font-size:clamp(32px,4vw,58px);margin:4px 0 8px;letter-spacing:-2px}.hero p{max-width:660px;margin:0;color:#ffffffda}.hero-actions{display:flex;gap:10px;margin-top:24px}.hero .btn{background:#fff;color:#5e55df}.hero-right{display:grid;grid-template-columns:repeat(2,1fr);gap:12px;align-self:center}.hero-stat{background:#ffffff1f;border:1px solid #ffffff2d;border-radius:18px;padding:17px}.hero-stat strong{font-size:28px;display:block}.hero-stat span{font-size:11px;color:#fffde5}.feature-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:15px;margin-top:18px}.feature-card{border:0;border-radius:22px;padding:22px;text-align:left;min-height:160px;transition:.18s;position:relative;overflow:hidden}.feature-card:hover{transform:translateY(-2px)}.feature-card h3{font-size:17px;margin:16px 0 4px}.feature-card p{font-size:12px;color:#67708a;margin:0;line-height:1.55}.feature-card .icon{font-size:26px}.feature-card .go{position:absolute;bottom:18px;font-size:11px;font-weight:900}.feature-orange{background:#fff0cc}.feature-green{background:#dbf9eb}.feature-red{background:#ffe3ea}.feature-violet{background:#e9e4ff}.feature-blue{background:#dfeeff}.card{background:#fff;border:1px solid #eff0f7;border-radius:20px;box-shadow:0 8px 26px rgba(58,63,100,.045)}.pad{padding:20px}.workspace-grid{display:grid;grid-template-columns:minmax(210px,270px) minmax(0,1fr) minmax(210px,270px);gap:15px}.side-panel{padding:18px}.side-panel h3{font-size:13px;margin:0 0 13px}.form-label{display:grid;gap:6px;font-size:11px;color:#77809a;font-weight:700;margin-bottom:14px}.info-block{padding:11px 0;border-bottom:1px solid #f0f1f7}.info-block span,.info-block strong{display:block}.info-block span{font-size:10px;color:#9aa0b3}.info-block strong{font-size:12px;margin-top:3px}.term-chip{padding:9px 10px;border-radius:12px;background:#f7f7fc;margin-bottom:7px}.term-chip strong,.term-chip span{display:block}.term-chip strong{font-size:12px}.term-chip span{font-size:10px;color:#8e95aa;margin-top:3px}.fixed-main{padding:22px}.step-progress{display:flex;align-items:center;gap:12px;margin-bottom:20px}.step-progress b{font-size:11px}.progress-track{height:7px;background:#f0f0f8;border-radius:99px;flex:1;overflow:hidden}.progress-track i{display:block;height:100%;background:linear-gradient(90deg,#ffad31,#ffd75a)}.fixed-question{font-size:clamp(20px,2.2vw,30px);line-height:1.35;font-weight:800;margin:14px 0 16px}.prompt-card{background:#fff8df;border-radius:15px;padding:13px 15px;margin:14px 0}.prompt-card h4{margin:0 0 5px;font-size:12px}.prompt-card p{margin:0;font-size:12px;color:#6f6a55}.test-toolbar{display:flex;gap:8px;flex-wrap:wrap;margin-top:10px}.sample-answer,.feedback-box{margin-top:11px;padding:12px;border-radius:13px;font-size:12px}.sample-answer{background:#eaf8ff}.feedback-box.good{background:#e2faef}.feedback-box.warn{background:#fff3d9}.choice-row,.difficulty-row{display:flex;gap:7px;flex-wrap:wrap}.choice-btn{border:1px solid #e7e8f1;background:#fff;border-radius:12px;padding:8px 11px;color:#717992}.choice-btn.active{background:#675cff;color:#fff;border-color:#675cff}.chat-card{min-height:650px;display:grid;grid-template-rows:auto 1fr auto;overflow:hidden}.chat-head{padding:15px 18px;border-bottom:1px solid #f0f1f6;display:flex;justify-content:space-between;align-items:center}.chat-head h3{margin:0;font-size:15px}.chat-head small{color:#949aaf}.chat-log{padding:20px;overflow:auto;min-height:400px;max-height:calc(100vh - 300px)}.bubble-row{display:flex;gap:8px;margin:11px 0;align-items:flex-end}.bubble-row.me{justify-content:flex-end}.bubble{max-width:min(78%,720px);padding:12px 14px;border-radius:17px 17px 17px 5px;background:#f0efff;line-height:1.55;white-space:pre-wrap}.bubble-row.me .bubble{background:#dcf9ec;border-radius:17px 17px 5px 17px}.bubble-avatar{width:28px;height:28px;border-radius:9px;background:#e9e5ff;display:grid;place-items:center}.composer{padding:12px;border-top:1px solid #eff0f5;display:grid;grid-template-columns:46px minmax(0,1fr) auto;gap:8px;align-items:end}.composer textarea{resize:none;max-height:130px}.mic-btn{border:0;width:44px;height:44px;border-radius:14px;background:#fff0d6}.mic-btn.listening{animation:pulse 1s infinite;background:#ffd9e4}.hint-drawer{margin-top:10px}.hint-drawer summary{font-size:11px;color:#7168d8;cursor:pointer}.hint-drawer .hint-body{margin-top:8px;background:#f7f7ff;padding:11px;border-radius:12px;font-size:12px}.exam-picker{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px}.exam-option{border:2px solid transparent;border-radius:22px;padding:22px;text-align:left;background:#fff;min-height:190px}.exam-option.selected{border-color:#6b60ff;box-shadow:0 10px 28px #6b60ff18}.exam-option h3{margin:14px 0 6px}.exam-option p{font-size:12px;color:#8289a0}.exam-focus{max-width:980px!important}.exam-shell{min-height:calc(100vh - 140px);display:grid;grid-template-rows:auto 1fr auto;background:#fff;border-radius:24px;border:1px solid #eeeefa;overflow:hidden}.exam-top{padding:16px 20px;border-bottom:1px solid #eeeefa;display:flex;justify-content:space-between;align-items:center}.exam-top h2{margin:0;font-size:18px}.exam-top span{font-size:11px;color:#858ca4}.exam-log{padding:22px;overflow:auto}.exam-prompt{font-size:clamp(21px,2.4vw,32px);font-weight:800;line-height:1.4;margin:10px 0 18px}.exam-answer{background:#f3f4f9;border-radius:15px;padding:12px;margin:10px 0;font-size:13px}.exam-composer{padding:14px;border-top:1px solid #eeeefa;display:grid;grid-template-columns:48px minmax(0,1fr) auto;gap:8px}.score-grid{display:grid;grid-template-columns:repeat(5,1fr);gap:10px;margin:16px 0}.score-box{padding:15px;border-radius:17px;background:#f7f7fc;text-align:center}.score-box strong{font-size:25px;display:block}.score-box span{font-size:10px;color:#838aa0}.score-total{padding:22px;border-radius:20px;background:linear-gradient(135deg,#655aff,#8c6cff);color:#fff;display:flex;align-items:center;justify-content:space-between}.score-total strong{font-size:46px}.report-list{display:grid;gap:9px;margin-top:14px}.report-item{padding:12px 14px;border-radius:13px;background:#f7f7fc;font-size:12px}.vocab-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px}.vocab-card{padding:16px}.vocab-card h3{margin:0 0 5px}.vocab-card .phonetic{color:#786bdb;font-size:11px}.vocab-card p{font-size:12px;color:#717991}.table-card{overflow:hidden}.table-toolbar{padding:14px 16px;border-bottom:1px solid #eff0f6;display:flex;gap:10px;align-items:center;justify-content:space-between;flex-wrap:wrap}.filters{display:flex;gap:8px;flex-wrap:wrap;align-items:center}.filters .field,.filters select{width:auto;min-width:150px}.table-scroll{overflow:auto}.data-table{width:100%;border-collapse:collapse;font-size:12px}.data-table th,.data-table td{padding:12px 14px;border-bottom:1px solid #f0f1f6;text-align:left;white-space:nowrap}.data-table th{color:#8d94a9;font-size:10px}.tabs{display:flex;gap:7px;margin-bottom:14px}.tab-btn{border:0;border-radius:11px;padding:9px 13px;background:#efeff6;color:#707891;font-weight:800}.tab-btn.active{background:#675cff;color:#fff}.org-layout{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px}.org-panel{padding:14px;min-height:360px}.org-panel-head{display:flex;justify-content:space-between;align-items:center;margin-bottom:10px}.org-list{display:grid;gap:7px}.org-item{border:1px solid #eeeefa;border-radius:12px;padding:9px 10px;display:flex;align-items:center;justify-content:space-between;gap:7px;background:#fff}.org-item.active{border-color:#7668ff;background:#f1efff}.org-item button{border:0;background:transparent;color:#8d94a8;padding:4px}.modal-backdrop{position:fixed;inset:0;background:#24263a70;z-index:100;display:grid;place-items:center;padding:18px}.modal{width:min(620px,100%);max-height:90vh;overflow:auto;background:#fff;border-radius:22px;padding:22px;box-shadow:0 24px 70px #24263a45}.modal h3{margin:0 0 17px}.form-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.full-span{grid-column:1/-1}.modal-actions{display:flex;justify-content:flex-end;gap:8px;margin-top:18px}.provider-grid{display:grid;gap:12px}.provider-card{padding:18px}.provider-head{display:flex;justify-content:space-between;align-items:center;gap:10px}.provider-head h3{margin:0}.status-dot{font-size:11px;padding:5px 9px;border-radius:99px;background:#f1f2f7;color:#9096aa}.status-dot.ok{background:#def8eb;color:#157352}.masked-key{letter-spacing:2px;color:#5f6682}.route-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px}.connection-result{font-size:12px;margin-top:10px;color:#8c93a8}.connection-result.ok{color:#14805a}.connection-result.error{color:#c8475c}.trash-list{display:grid;gap:8px}.trash-item{display:flex;justify-content:space-between;align-items:center;gap:10px;padding:11px 13px;border-radius:13px;background:#f7f7fc}.exam-active .topbar,.exam-active .sidebar,.exam-active .mobile-bottom-nav{display:none!important}.exam-active .shell-grid{grid-template-columns:1fr;min-height:100vh}.exam-active .main-content{padding:clamp(8px,2vw,22px)}.exam-active{padding-bottom:0!important}.mobile-only,.mobile-bottom-nav{display:none}@keyframes pulse{50%{transform:scale(1.08)}}
@media(max-width:1280px){.feature-grid{grid-template-columns:repeat(2,1fr)}.workspace-grid{grid-template-columns:220px minmax(0,1fr)}.workspace-grid>aside:last-child{grid-column:1/-1;display:grid;grid-template-columns:repeat(3,1fr);gap:8px}.workspace-grid>aside:last-child h3{grid-column:1/-1}.vocab-grid{grid-template-columns:repeat(2,1fr)}}
@media(max-width:1024px){.login-shell{grid-template-columns:1fr;padding:26px}.login-art{display:none}.login-card{margin:auto;width:min(100%,520px)}.shell-grid{grid-template-columns:1fr}.sidebar{position:fixed;left:0;top:68px;bottom:0;width:230px;z-index:30;transform:translateX(-105%);transition:.2s;box-shadow:20px 0 50px #34355020}.sidebar.open{transform:translateX(0)}.mobile-only{display:grid}.workspace-grid{grid-template-columns:1fr}.workspace-grid>aside:last-child{grid-column:auto}.hero{grid-template-columns:1fr}.exam-picker{grid-template-columns:1fr}.org-layout{grid-template-columns:1fr}.route-grid{grid-template-columns:1fr}.score-grid{grid-template-columns:repeat(3,1fr)}}
@media(max-width:720px){body{padding-bottom:65px}.topbar{height:60px;padding:0 12px}.brand-text span{display:none}.user-chip>div:last-child{display:none}.main-content{padding:14px 12px}.page-head{align-items:flex-start;margin-bottom:15px}.page-head p{display:none}.page-head h1{font-size:24px}.hero{padding:22px;border-radius:21px;min-height:0}.hero p{font-size:12px}.hero-right{grid-template-columns:repeat(3,1fr)}.hero-stat{padding:12px}.hero-stat strong{font-size:22px}.feature-grid{grid-template-columns:1fr}.feature-card{min-height:128px}.workspace-grid{gap:10px}.side-panel{padding:14px}.chat-card{min-height:calc(100vh - 155px)}.chat-log{max-height:none;min-height:46vh;padding:14px}.bubble{max-width:88%;font-size:14px}.composer,.exam-composer{grid-template-columns:44px minmax(0,1fr) 54px;padding:9px}.composer .btn,.exam-composer .btn{padding:10px 8px}.workspace-grid>aside:first-child{order:-1}.workspace-grid>aside:last-child{display:block}.vocab-grid{grid-template-columns:1fr}.form-grid{grid-template-columns:1fr}.full-span{grid-column:auto}.score-grid{grid-template-columns:repeat(2,1fr)}.score-total strong{font-size:38px}.data-table thead{display:none}.data-table,.data-table tbody,.data-table tr,.data-table td{display:block;width:100%}.data-table tr{padding:10px;border-bottom:1px solid #eceef5}.data-table td{border:0;padding:5px 8px;white-space:normal;display:flex;justify-content:space-between;gap:16px}.data-table td:before{content:attr(data-label);font-size:10px;color:#9aa0b2;flex:0 0 74px}.mobile-bottom-nav{display:grid;position:fixed;bottom:0;left:0;right:0;height:62px;background:#fff;border-top:1px solid #eceef4;z-index:40;grid-auto-flow:column;grid-auto-columns:1fr}.mobile-bottom-nav button{border:0;background:transparent;color:#8b91a7;display:grid;place-items:center;padding:6px 2px;font-size:10px}.mobile-bottom-nav button span{font-size:17px}.mobile-bottom-nav button.active{color:#6358ed}.sidebar{bottom:62px}.exam-shell{min-height:calc(100vh - 98px);border-radius:15px}.exam-top{padding:12px}.exam-log{padding:15px}.exam-prompt{font-size:21px}.exam-focus{margin:0!important}.exam-focus .page-head{display:none}.exam-active .topbar,.exam-active .sidebar,.exam-active .mobile-bottom-nav{display:none!important}.exam-active .shell-grid{min-height:100vh}.exam-active .main-content{padding:8px}.exam-active{padding-bottom:0}.filters{display:grid;grid-template-columns:1fr 1fr;width:100%}.filters .field,.filters select{min-width:0;width:100%}}
@media(max-width:430px){.hero-right{grid-template-columns:repeat(2,1fr)}.score-grid{grid-template-columns:1fr 1fr}.demo-row{flex-direction:column}.filters{grid-template-columns:1fr}}

/* V3: button sizing + single-provider AI settings */
.btn{min-height:40px;display:inline-flex;align-items:center;justify-content:center;white-space:nowrap;line-height:1.1}
.btn.small,.btn.compact-btn{min-height:36px;padding:8px 13px;font-size:12px}
.key-row{display:grid;grid-template-columns:minmax(0,1fr) 92px;gap:10px;align-items:center}
.key-rewrite{width:92px;min-width:92px;padding:8px 10px;white-space:nowrap;word-break:keep-all}
.ai-route-card,.provider-selector-card{margin-bottom:14px}
.provider-selector-card{display:flex;align-items:end;gap:12px}
.provider-selector-label{margin:0;min-width:min(360px,100%);width:min(360px,100%)}
.single-provider-card{padding:22px}
.provider-form{margin-top:16px}
.provider-actions{display:flex;gap:9px;flex-wrap:wrap;margin-top:12px}
.model-select{min-height:44px}
.advanced-summary{font-size:11px;color:#858ca3;cursor:pointer;display:inline-flex;padding:4px 0}
.advanced-field{margin-top:10px}
.public-card{max-width:920px}
.public-status{margin-top:12px;font-size:12px;color:#7d849a}
.public-setup-note{max-width:920px;margin-top:14px;font-size:12px;color:#7d849a}
@media(max-width:700px){
 .key-row{grid-template-columns:minmax(0,1fr) 84px;gap:7px}.key-rewrite{width:84px;min-width:84px;font-size:11px}
 .provider-actions .btn{flex:1 1 130px}.route-grid{grid-template-columns:1fr}.provider-selector-card{display:block}.single-provider-card{padding:16px}
}
.nav-group button{min-height:44px}
.choice-btn,.tab-btn{min-height:38px;white-space:nowrap}
.org-item>span>button{width:30px;height:30px;min-height:30px;border-radius:8px}
.org-select{min-height:34px}
.demo-row button{min-height:30px}
.mobile-bottom-nav button{min-height:52px}

/* V5: mobile layout correction + production login cleanup */
@media(max-width:720px){
  .feature-card{
    min-height:0;
    padding:20px 18px;
    display:flex;
    flex-direction:column;
    align-items:flex-start;
    overflow:visible;
  }
  .feature-card .icon{
    font-size:27px;
    line-height:1;
    margin:0 0 18px;
    flex:0 0 auto;
  }
  .feature-card h3{
    margin:0 0 7px;
    font-size:18px;
    line-height:1.3;
    white-space:normal;
    word-break:break-word;
  }
  .feature-card p{
    margin:0;
    font-size:12px;
    line-height:1.55;
    white-space:normal;
    word-break:break-word;
  }
  .feature-card .go{
    position:static;
    margin-top:16px;
    font-size:12px;
    line-height:1.2;
    flex:0 0 auto;
  }
  .feature-grid{gap:14px}

  .mobile-bottom-nav button{
    display:flex;
    flex-direction:column;
    align-items:center;
    justify-content:center;
    gap:3px;
    line-height:1.1;
  }
  .mobile-bottom-nav button span{line-height:1}

  .login-shell{
    min-height:100svh;
    padding:18px 14px;
    align-items:center;
  }
  .login-card{
    width:100%;
    max-width:520px;
    padding:28px 22px;
    border-radius:24px;
  }
  .login-brand{
    gap:14px;
    margin-bottom:28px;
    align-items:center;
  }
  .login-brand>div:last-child{min-width:0}
  .login-brand h1{
    font-size:30px;
    line-height:1.15;
  }
  .login-brand p{
    font-size:13px;
    line-height:1.45;
    white-space:normal;
  }
  .login-form input{min-height:50px}
  .login-form .btn.big{min-height:52px;font-size:16px}

  .topbar .brand-area{min-width:0}
  .topbar .brand-text{min-width:0}
  .topbar .brand-text strong{white-space:nowrap}
  .user-area{gap:8px;flex:0 0 auto}
  .icon-btn{flex:0 0 auto}
}

@media(max-width:380px){
  .main-content{padding-left:10px;padding-right:10px}
  .feature-card{padding:18px 16px}
  .login-card{padding:24px 18px}
  .login-brand h1{font-size:28px}
  .brand-mark{width:54px;height:54px;font-size:28px}
}
.demo-row{display:none!important}

/* V7: administrator / teacher permission management */
.modal-wide{width:min(980px,94vw);max-height:90vh;overflow:auto}
.teacher-config-grid{display:grid;grid-template-columns:1fr 1fr;gap:14px;margin-top:16px}
.config-section{min-width:0}
.config-section>h3{font-size:14px;margin:0 0 9px;color:#29314b}
.scope-box{border:1px solid #e8eafb;border-radius:16px;background:#fafbff;padding:14px;max-height:330px;overflow:auto}
.scope-college+ .scope-college{margin-top:14px}.scope-college>h4{margin:0 0 8px;font-size:13px}.scope-major{padding:8px 0;border-top:1px solid #eceef8}.scope-major:first-of-type{border-top:0}.scope-major>b{display:block;font-size:12px;margin-bottom:8px;color:#68708a}
.permission-group+.permission-group{margin-top:14px}.permission-group h4{font-size:13px;margin:0 0 8px}
.check-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
.check-item{display:flex;align-items:center;gap:8px;min-height:38px;padding:8px 10px;border-radius:10px;background:#fff;border:1px solid #eceef7;font-size:12px;cursor:pointer}.check-item input{width:16px;height:16px;accent-color:#6c63ff;flex:0 0 auto}.check-item span{min-width:0;line-height:1.35}
#teacherNav .hidden{display:none!important}
@media(max-width:760px){.teacher-config-grid{grid-template-columns:1fr}.check-grid{grid-template-columns:1fr}.modal-wide{width:94vw;padding:18px}.scope-box{max-height:260px}}

/* V8 scoped speech controls */
.bubble-wrap{display:flex;align-items:flex-end;gap:6px;max-width:min(82%,760px)}
.bubble-wrap .bubble{max-width:100%}
.bubble-row.me .bubble-wrap{justify-content:flex-end}
.bubble-speak{border:0;background:#f1f2f8;color:#686f88;width:30px;height:30px;border-radius:10px;display:inline-grid;place-items:center;flex:0 0 auto;font-size:13px;padding:0;vertical-align:middle}
.bubble-speak:active{transform:scale(.96)}
@media(max-width:720px){.bubble-wrap{max-width:91%}.bubble-speak{width:34px;height:34px;border-radius:11px}}

/* V9 realtime voice conversation */
.live-dot{width:10px;height:10px;border-radius:50%;background:#d8dbe7;box-shadow:0 0 0 0 rgba(39,196,139,.25)}
.live-dot.on{background:#25c48b;animation:voiceDot 1.4s infinite}
.voice-console,.exam-voice-panel{border-top:1px solid #eff0f5;padding:18px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:10px;min-height:190px;background:linear-gradient(180deg,#fff,#fbfbff)}
.voice-orb{width:66px;height:66px;border-radius:50%;display:grid;place-items:center;font-size:28px;background:linear-gradient(135deg,#edeaff,#e1f8ff);box-shadow:0 10px 28px rgba(96,88,220,.13);transition:.2s}
.voice-orb.active{background:linear-gradient(135deg,#e8e4ff,#dbf9eb)}
.voice-orb.listening{background:linear-gradient(135deg,#ffdce8,#fff0cf);animation:voicePulse 1s infinite}
.voice-orb.thinking{background:linear-gradient(135deg,#e8e4ff,#dfeeff);animation:voiceFloat 1.1s infinite alternate}
.voice-orb.speaking{background:linear-gradient(135deg,#d8f7eb,#dfeaff);animation:voicePulse 1.2s infinite}
.voice-console>strong,.exam-voice-panel>strong{font-size:13px;color:#5f6781}
.voice-transcript{min-height:42px;width:min(100%,680px);padding:10px 14px;border-radius:14px;background:#f4f5fa;color:#4f5873;text-align:center;font-size:14px;line-height:1.5;word-break:break-word}
.voice-transcript:empty:before{content:"…";color:#b4b8c7}
.voice-console .btn{min-width:150px}
.realtime-chat{grid-template-rows:auto 1fr auto}
.exam-picker{grid-template-columns:repeat(2,minmax(0,1fr))}
.realtime-exam{grid-template-rows:auto 1fr auto}
.exam-voice-panel{min-height:180px}
.exam-transcript{background:#f5f6fa;color:#3d455e}
@keyframes voicePulse{50%{transform:scale(1.08);box-shadow:0 0 0 12px rgba(99,91,255,.08)}}
@keyframes voiceFloat{to{transform:translateY(-4px)}}
@keyframes voiceDot{50%{box-shadow:0 0 0 8px rgba(39,196,139,0)}}
@media(max-width:720px){
  .voice-console,.exam-voice-panel{min-height:168px;padding:14px 10px;gap:8px}
  .voice-orb{width:58px;height:58px;font-size:25px}
  .voice-transcript{font-size:13px;min-height:40px;padding:9px 10px}
  .voice-console .btn{width:min(86%,280px);min-height:46px}
  .realtime-chat{min-height:calc(100vh - 155px)}
  .realtime-exam .exam-log{padding-bottom:10px}
}


/* V10.4 入门练习麦克风可视反馈 */
.fixed-mic-status{display:flex;align-items:center;gap:11px;margin-top:10px;padding:11px 13px;border:1px solid #eceefa;border-radius:14px;background:#fafbff;min-height:58px;transition:.2s}
.fixed-mic-copy{display:grid;gap:3px;min-width:0;flex:1}.fixed-mic-copy strong{font-size:12px}.fixed-mic-copy small{font-size:10px;line-height:1.45;color:#8b92aa;white-space:normal;overflow-wrap:anywhere}
.mic-status-dot{width:10px;height:10px;border-radius:50%;background:#45c78b;box-shadow:0 0 0 5px #45c78b18;flex:0 0 auto}.fixed-mic-status.listening{background:#fff7f9;border-color:#ffd7e1}.fixed-mic-status.listening .mic-status-dot{background:#ff5275;box-shadow:0 0 0 6px #ff52751c;animation:fixedMicPulse 1s infinite}.fixed-mic-status.done{background:#f0fbf6;border-color:#d8f2e5}.fixed-mic-status.done .mic-status-dot{background:#2fbd7f}.fixed-mic-status.warn{background:#fff9e9;border-color:#ffe4a8}.fixed-mic-status.warn .mic-status-dot{background:#f0a52b}.fixed-mic-status.error{background:#fff1f3;border-color:#ffd1d8}.fixed-mic-status.error .mic-status-dot{background:#e64966}
.mic-wave{display:flex;align-items:center;gap:3px;height:24px;opacity:.28;flex:0 0 auto}.mic-wave i{display:block;width:3px;height:8px;border-radius:99px;background:#a0a6ba}.fixed-mic-status.listening .mic-wave{opacity:1}.fixed-mic-status.listening .mic-wave i{background:#ff5275;animation:fixedMicWave .8s ease-in-out infinite}.fixed-mic-status.listening .mic-wave i:nth-child(2){animation-delay:.12s}.fixed-mic-status.listening .mic-wave i:nth-child(3){animation-delay:.24s}.fixed-mic-status.listening .mic-wave i:nth-child(4){animation-delay:.36s}
#fixedMic.listening{background:#ff5275;color:#fff;box-shadow:0 8px 22px #ff527536;animation:fixedMicButtonPulse 1.15s infinite}
@keyframes fixedMicPulse{50%{transform:scale(1.22);box-shadow:0 0 0 9px #ff52750d}}@keyframes fixedMicWave{0%,100%{height:7px}50%{height:22px}}@keyframes fixedMicButtonPulse{50%{box-shadow:0 8px 28px #ff52755e}}
@media(max-width:720px){.fixed-mic-status{align-items:flex-start}.mic-wave{margin-top:4px}.fixed-mic-copy small{font-size:11px}}
