.cc-shell { max-width:1280px; margin:0 auto; }
.cc-heading { display:flex; align-items:center; justify-content:space-between; flex-wrap:wrap; gap:12px; margin-bottom:16px; }
.cc-heading > div { display:flex; align-items:center; flex-wrap:wrap; gap:12px; }
.cc-beta { display:inline-flex; padding:4px 10px; border:1px solid #e8c0b4; border-radius:6px; color:#a74e42; background:var(--coral-soft); font-size:11px; font-weight:700; white-space:nowrap; }
.cc-lesson { color:var(--navy); font-size:13px; font-weight:600; }
.cc-heading > a,.cc-footer > a { color:#a75b4d; font-size:12px; }
.cc-frame { display:block; width:100%; min-height:400px; height:850px; border:1px solid #e6dcd2; border-radius:18px; background:var(--surface); }
.cc-footer { display:flex; align-items:center; justify-content:space-between; flex-wrap:wrap; gap:10px; padding:18px 2px; }
.cc-footer > p { margin:0; color:var(--muted); font-size:12px; line-height:1.8; }
.cc-footer > a { white-space:nowrap; }
.cc-gate { max-width:920px; padding:clamp(24px,5vw,52px); border-color:#e6dcd2; background:var(--surface); }
.cc-gate > .section-kicker { margin:26px 0 12px; }
.cc-gate h2 { color:var(--navy); font:700 clamp(24px,3vw,36px)/1.5 Georgia,"Songti SC",serif; letter-spacing:-.03em; margin:0 0 18px; }
.cc-gate > p:not(.section-kicker) { max-width:600px; color:var(--muted); font-size:14px; line-height:1.9; }
.cc-preview { margin:28px 0; padding:20px 0 20px 20px; border-left:3px solid var(--coral); }
.cc-preview b { color:var(--navy); font-size:14px; }
.cc-preview p { margin:8px 0; font-size:13px; color:var(--muted); line-height:1.8; }
.cc-preview-item + .cc-preview-item { margin-top:20px; }
.cc-preview-item p { margin-bottom:0; }
.cc-gate > .cc-access-note { margin:0 0 18px; font-size:13px; }
.cc-preview > span { display:block; color:#987e70; font-size:12px; line-height:2; }
.cc-actions { display:flex; flex-wrap:wrap; gap:10px; }
.cc-loading { padding:40px 24px; color:var(--muted); }
.cc-heading > a:focus-visible,.cc-footer > a:focus-visible { outline:3px solid var(--coral); outline-offset:4px; }
body.courseware-active .paipai-pet { display:none; }
.mobile-nav { grid-template-columns:repeat(4,minmax(0,1fr)); }
.camp-course-nav .cc-menu-beta { display:block; margin-top:3px; color:#ad6555; font-size:10px; font-weight:400; }
@media(max-width:820px) {
  body.courseware-active #mainContent { padding:18px 12px 26px; }
  body.courseware-active .topbar h1 { font-size:20px; }
  .cc-heading { gap:10px; margin-bottom:12px; }
  .cc-heading > a { font-size:11px; }
  .cc-lesson { font-size:12px; }
  .cc-frame { border-radius:12px; }
  .cc-gate { padding:24px 20px; }
  .cc-preview { margin:22px 0; padding-left:15px; }
}
@media(max-width:420px) { .mobile-nav button { font-size:10px; padding-left:3px; padding-right:3px; }.cc-actions > button { flex:1; justify-content:center; } }

/* Current teacher course owns the area below the bilingual site heading. */
body.courseware-active .page-column { height:100dvh; display:flex; flex-direction:column; padding-bottom:16px; }
body.courseware-active .topbar { flex:0 0 auto; }
body.courseware-active #mainContent { flex:1; min-height:0; padding:14px 0 0; }
body.courseware-active #coursewareView { height:100%; min-height:0; }
body.courseware-active .cc-shell { max-width:none; height:100%; }
body.courseware-active .cc-frame { height:100% !important; min-height:0; box-sizing:border-box; }
@media(max-width:820px) {
 body.courseware-active .page-column { padding-bottom:calc(76px + env(safe-area-inset-bottom)); }
 body.courseware-active #mainContent { padding:10px 0 0; }
}

/* Courseware is part of the page, including every daily homework document. */
body.courseware-active :is(.page-column,#mainContent,#coursewareView,#campIntroView,.cp-lesson,.cc-shell){height:auto!important;min-height:0!important;max-height:none!important;overflow:visible!important;flex:none!important}
body.courseware-active .cc-frame{height:var(--courseware-flow-height,800px)!important;min-height:0!important;max-height:none!important}
body.courseware-active .page-column{padding-bottom:0!important}

@media print {
  html:has(body.courseware-active .cc-frame) > body {
    display: none !important;
  }
  html:has(body.courseware-active .cc-frame)::after {
    content: "本课件仅供在线学习";
    display: block !important;
    color: #333;
    font: 16px sans-serif;
  }
}
