html,body.practice-body{margin:0!important;padding-top:0!important}
.practice-header{top:0!important;margin-top:0!important}
.study-header{height:auto;min-height:72px;flex-wrap:wrap;padding:10px max(16px,2.2vw) 8px}
.study-header .practice-brand{margin-right:28px;flex:0 0 auto}
.study-header .study-nav{order:3;flex:0 0 100%;width:100%;height:auto;min-height:38px;display:flex;flex-wrap:wrap;align-content:center;justify-content:center;column-gap:20px;row-gap:0;min-width:0;margin-top:8px;padding:4px 0;white-space:nowrap;overflow:visible;border-top:1px solid #f0eef4;scrollbar-width:none;overscroll-behavior-x:contain}
.study-header .study-nav::-webkit-scrollbar{display:none}
.study-header .study-nav a{height:34px;flex:0 0 auto}
.study-header .study-nav a{font-size:13px}
.study-header .header-user{white-space:nowrap;flex:0 0 auto}
.study-header .header-profile-entry{display:flex;align-items:center;gap:5px;color:#514c5e;font-size:13px}.study-header .header-profile-entry i{color:#7666d8;font-size:10px;font-style:normal;opacity:0;transition:opacity .18s}.study-header .header-profile-entry:hover i{opacity:1}
.study-header .header-subject-switch{margin-left:auto;margin-right:14px;display:flex;align-items:center;gap:7px;white-space:nowrap;flex:0 0 auto}
.study-header .header-subject-switch>span{font-size:11px;color:#8b8fa0}
.study-header .header-subject-switch>a{height:34px;max-width:190px;padding:0 9px 0 11px;display:flex;align-items:center;gap:8px;border:1px solid #e0e2ea;border-radius:9px;background:#fff;color:#34384d;font-size:12px}
.study-header .header-subject-switch>a b{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.study-header .header-subject-switch>a i{color:#675bd1;font-size:11px;font-style:normal}
.study-header .header-subject-switch>a:hover{border-color:#887de1;box-shadow:0 0 0 3px rgba(108,92,231,.09)}
@media(min-width:1851px){
  .study-header{height:72px;min-height:72px;flex-wrap:nowrap;padding-top:0;padding-bottom:0}
  .study-header .practice-brand{margin-right:22px}
  .study-header .study-nav{order:0;flex:1 1 auto;width:auto;height:72px;min-height:0;flex-wrap:nowrap;justify-content:flex-start;column-gap:14px;margin-top:0;padding:0;overflow-x:auto;overflow-y:hidden;border-top:0;align-self:stretch}
  .study-header .study-nav a{height:auto}
  .study-header .header-subject-switch{margin-left:14px}
}
@media(max-width:1450px){
  .study-header{height:auto;min-height:72px;flex-wrap:wrap;padding-top:10px;padding-bottom:8px}
  .study-header .study-nav{order:3;flex:0 0 100%;width:100%;height:auto;min-height:38px;display:flex;flex-wrap:wrap;align-content:center;column-gap:20px;row-gap:0;overflow:visible;border-top:1px solid #f0eef4;margin-top:8px;padding:4px 0}
  .study-header .study-nav a{height:34px}
  .study-header .header-user{margin-left:auto}
  .study-header .header-subject-switch{margin-left:auto;margin-right:14px}
}
@media(max-width:800px){
  .study-header .study-nav{display:flex;flex-wrap:nowrap;justify-content:flex-start;overflow-x:auto;padding-bottom:3px}
  .study-header .practice-brand b,.study-header .header-user span{display:none}
  .study-header .header-subject-switch>span{display:none}
  .study-header .header-subject-switch>a{max-width:150px}
}
@media(max-width:480px){
  .study-header .practice-brand{margin-right:8px}
  .study-header .header-subject-switch{max-width:calc(100% - 120px);margin-left:auto;margin-right:8px}
  .study-header .header-subject-switch>a{min-width:0;max-width:100%}
  .study-header .header-user{gap:0}
}

/* Desktop: brand, menu, subject and user keep four stable columns.
   Only the middle menu is allowed to wrap when its available width is insufficient. */
@media(min-width:801px){
  .study-header{
    display:grid;
    grid-template-columns:max-content minmax(0,1fr) max-content max-content;
    column-gap:14px;
    align-items:center;
    height:auto;
    min-height:72px;
    padding:10px max(16px,2.2vw);
  }
  .study-header .practice-brand{
    grid-column:1;
    align-self:center;
    margin:0;
  }
  .study-header .study-nav{
    grid-column:2;
    order:initial;
    width:auto;
    min-width:0;
    min-height:52px;
    height:auto;
    margin:0;
    padding:9px 0;
    display:flex;
    flex:initial;
    flex-wrap:wrap;
    align-content:flex-start;
    justify-content:flex-start;
    column-gap:17px;
    row-gap:0;
    overflow:visible;
    border:0;
    align-self:start;
  }
  .study-header .study-nav a{
    height:34px;
    flex:0 0 auto;
    font-size:14px;
  }
  .study-header .header-subject-switch{
    grid-column:3;
    align-self:center;
    margin:0;
  }
  .study-header .header-subject-switch>span{
    font-size:12px;
  }
  .study-header .header-subject-switch>a{
    height:36px;
    font-size:13px;
  }
  .study-header .header-subject-switch>a i{
    font-size:12px;
  }
  .study-header .header-user{
    grid-column:4;
    align-self:center;
    margin:0;
    font-size:13px;
  }
  .study-header .header-user span,
  .study-header .header-user a{
    font-size:13px;
  }
}

/* 极窄视口（浏览器高倍缩放）：优先保证品牌完整，其他区域分行显示。 */
@media(max-width:600px){
  .study-header{
    display:grid;
    grid-template-columns:minmax(0,1fr) max-content;
    align-items:center;
    gap:7px 10px;
    padding:8px 12px 6px;
  }
  .study-header .practice-brand{
    grid-column:1;
    grid-row:1;
    min-width:0;
    margin:0;
    gap:8px;
    white-space:nowrap;
  }
  .study-header .practice-brand span{
    width:34px;
    height:34px;
    flex:0 0 34px;
    border-radius:9px;
    font-size:17px;
  }
  .study-header .practice-brand b{
    display:block;
    overflow:hidden;
    text-overflow:ellipsis;
    white-space:nowrap;
    font-size:16px;
  }
  .study-header .header-user{
    grid-column:2;
    grid-row:1;
    margin:0;
  }
  .study-header .header-user span{display:none}
  .study-header .header-subject-switch{
    grid-column:1 / -1;
    grid-row:2;
    width:100%;
    max-width:none;
    margin:0;
  }
  .study-header .header-subject-switch>a{
    width:100%;
    max-width:none;
    justify-content:space-between;
  }
  .study-header .study-nav{
    grid-column:1 / -1;
    grid-row:3;
    order:initial;
    width:100%;
    min-height:36px;
    margin-top:0;
    padding:3px 0 1px;
    flex-wrap:nowrap;
    justify-content:flex-start;
    overflow-x:auto;
    overflow-y:hidden;
    border-top:1px solid #f0eef4;
  }
}

/* Extreme browser zoom: keep the brand name horizontal and indivisible. */
.study-header .practice-brand{
  flex-wrap:nowrap;
  white-space:nowrap;
  word-break:keep-all;
}
.study-header .practice-brand b{
  display:block;
  flex:0 0 auto;
  min-width:max-content;
  white-space:nowrap;
  word-break:keep-all;
  overflow-wrap:normal;
  writing-mode:horizontal-tb;
  line-height:1.2;
}
@media(max-width:320px){
  .study-header .practice-brand{gap:6px}
  .study-header .practice-brand span{width:30px;height:30px;flex-basis:30px;font-size:15px}
  .study-header .practice-brand b{font-size:14px}
}
