/* 教师端 / 学生端 门户 */
.portal-chooser-wrap { max-width: 720px; }
.portal-session-bar {
    display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 16px;
    margin-bottom: 20px; padding: 12px 16px; border-radius: 10px;
    background: rgba(255,255,255,.12); color: rgba(255,255,255,.92); font-size: 13px;
}
.portal-session-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.portal-session-link { color: #91d5ff; text-decoration: none; font-weight: 500; }
.portal-session-link:hover { text-decoration: underline; }
.portal-session-link.muted { color: rgba(255,255,255,.65); font-weight: 400; }
.portal-chooser-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 20px;
}
@media (max-width: 640px) { .portal-chooser-grid { grid-template-columns: 1fr; } }

.portal-chooser-card {
    background: #fff;
    border-radius: 16px;
    padding: 28px 20px;
    text-align: center;
    text-decoration: none;
    color: #333;
    box-shadow: 0 8px 32px rgba(0,0,0,.12);
    transition: transform .2s, box-shadow .2s;
}
.portal-chooser-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(0,0,0,.18);
}
.portal-chooser-icon {
    width: 64px; height: 64px; border-radius: 16px;
    display: flex; align-items: center; justify-content: center;
    font-size: 28px; margin: 0 auto 14px; color: #fff;
}
.portal-chooser-card.teacher .portal-chooser-icon { background: linear-gradient(135deg, #00a0e9, #1890ff); }
.portal-chooser-card.student .portal-chooser-icon { background: linear-gradient(135deg, #52c41a, #389e0d); }
.portal-chooser-card h2 { font-size: 20px; margin-bottom: 8px; }
.portal-chooser-card p { font-size: 13px; color: #888; line-height: 1.5; margin-bottom: 16px; }
.portal-chooser-btn {
    display: inline-block; padding: 8px 18px; border-radius: 20px;
    font-size: 13px; font-weight: 600; color: #fff;
}
.portal-chooser-card.teacher .portal-chooser-btn { background: #00a0e9; }
.portal-chooser-card.student .portal-chooser-btn { background: #52c41a; }

.portal-shell { min-height: 100vh; background: transparent; }
.portal-shell.portal-ktp-header { padding-top: var(--ktp-header-h, 56px); }
.portal-shell.portal-ktp-header .portal-header { display: none; }
.portal-header {
    padding: 0 24px; height: 56px;
    display: flex; align-items: center; justify-content: space-between;
    position: sticky; top: 0; z-index: 10;
}
.portal-logo { display: flex; align-items: center; gap: 10px; font-weight: 700; color: #00a0e9; font-size: 17px; }
.portal-logo i { font-size: 22px; }
.portal-badge {
    font-size: 11px; padding: 3px 10px; border-radius: 20px; font-weight: 600; margin-left: 8px;
}
.portal-badge.teacher { background: #e6f7ff; color: #00a0e9; }
.portal-badge.student { background: #f6ffed; color: #389e0d; }
.portal-header-right { display: flex; align-items: center; gap: 12px; font-size: 14px; }
.portal-main { max-width: 1100px; margin: 0 auto; padding: 24px 16px 48px; }
/* 教师端：主内容与顶栏 logo 左对齐，全宽布局 */
body.ktp-role-teacher.portal-shell.portal-ktp-header .portal-main {
    max-width: none;
    width: 100%;
    margin: 0;
    padding: 24px 24px 48px;
    box-sizing: border-box;
}
body.ktp-role-teacher.portal-shell .tp-detail-header {
    padding-left: 0;
}

.portal-hero {
    border-radius: 12px; padding: 24px 28px; color: #fff; margin-bottom: 24px;
}
.portal-hero h1 { font-size: 22px; margin-bottom: 6px; }
.portal-hero p { opacity: .92; font-size: 14px; }
.portal-hero-actions { margin-top: 16px; display: flex; gap: 10px; flex-wrap: wrap; }

.portal-section-head {
    display: flex; align-items: center; justify-content: space-between;
    margin-bottom: 16px; flex-wrap: wrap; gap: 10px;
}
.portal-section-head h2 { font-size: 18px; font-weight: 600; }

.portal-course-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 16px;
}
.portal-course-card {
    border-radius: 12px; overflow: hidden;
    transition: box-shadow .2s, transform .2s;
}
.portal-course-card:hover { transform: translateY(-2px); }
.portal-course-top {
    height: 6px;
    background: linear-gradient(90deg, #1890ff, #52c41a);
}

.portal-course-body { padding: 16px; }
.portal-course-name { font-size: 16px; font-weight: 600; margin-bottom: 6px; }
.portal-course-meta { font-size: 12px; color: #999; line-height: 1.6; }
.portal-code-box {
    margin-top: 12px; padding: 10px 12px; background: #f0f9ff;
    border: 1px dashed #91d5ff; border-radius: 8px; text-align: center;
}
.portal-code-label { font-size: 11px; color: #888; }
.portal-code-value {
    font-size: 22px; font-weight: 700; letter-spacing: 4px; color: #00a0e9;
    font-family: monospace; margin-top: 4px;
}
.portal-course-actions {
    display: flex; gap: 8px; margin-top: 12px; flex-wrap: wrap;
}
.portal-course-actions .ktp-btn { flex: 1; min-width: 80px; font-size: 12px; padding: 6px 10px; }

.portal-join-box {
    background: #fff; border-radius: 12px; padding: 24px;
    box-shadow: 0 2px 8px rgba(0,0,0,.06); margin-bottom: 24px;
    border: 1px solid #eee;
}
.portal-join-row { display: flex; gap: 10px; flex-wrap: wrap; align-items: flex-end; }
.portal-join-row .ktp-input {
    flex: 1; min-width: 180px; text-align: center; font-size: 20px;
    letter-spacing: 6px; text-transform: uppercase; font-family: monospace;
}
.portal-qr-modal-body { text-align: center; padding: 8px 0; }
.portal-qr-modal-body img {
    width: 220px; height: 220px; border: 1px solid #eee;
    border-radius: 8px; padding: 8px; background: #fff;
}
.portal-empty {
    text-align: center; padding: 48px 20px; color: #bbb;
    background: #fff; border-radius: 12px; border: 1px dashed #ddd;
}
.portal-empty i { font-size: 48px; margin-bottom: 12px; display: block; }

.auth-portal-tag {
    display: inline-block; padding: 4px 12px; border-radius: 20px;
    font-size: 12px; font-weight: 600; margin-bottom: 12px;
}
.auth-portal-tag.teacher { background: #e6f7ff; color: #00a0e9; }
.auth-portal-tag.student { background: #f6ffed; color: #389e0d; }

/* 工作台 · 我的课程 */
.ktp-home-header { align-items: flex-start; margin-bottom: 20px; }
.ktp-home-actions { display: flex; gap: 8px; flex-wrap: wrap; }

/* 学生端首页 · 我的课程 */
.ktp-student-home-head { margin-bottom: 20px; }
.ktp-student-home-title-row {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    margin-bottom: 16px;
}
.ktp-student-join-btn {
    padding: 10px 22px;
    font-size: 15px;
    font-weight: 600;
    box-shadow: 0 4px 14px rgba(24, 144, 255, 0.35);
    flex-shrink: 0;
    position: relative;
    z-index: 2;
}
.ktp-student-home-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
}
.ktp-student-home-search {
    position: relative;
    flex: 1;
    min-width: 220px;
    max-width: 420px;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 0 14px;
    height: 40px;
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}
.ktp-autofill-trap {
    position: absolute;
    width: 0;
    height: 0;
    overflow: hidden;
    opacity: 0;
    pointer-events: none;
}
.ktp-student-home-search i { color: #bfbfbf; font-size: 14px; flex-shrink: 0; }
.ktp-student-home-search .ktp-input {
    border: none;
    box-shadow: none;
    padding: 0;
    height: 100%;
    background: transparent;
    flex: 1;
    min-width: 0;
}
.ktp-student-home-search .ktp-input:focus { outline: none; box-shadow: none; }
@keyframes ktpCourseSearchAutofillStart { from { opacity: 1; } to { opacity: 1; } }
.ktp-student-home-search .ktp-input:-webkit-autofill {
    animation: ktpCourseSearchAutofillStart 0.01s;
    -webkit-box-shadow: 0 0 0 1000px #fff inset !important;
    -webkit-text-fill-color: #262626 !important;
    caret-color: #262626;
}
.ktp-search-clear {
    border: none;
    background: transparent;
    color: #bfbfbf;
    font-size: 18px;
    line-height: 1;
    padding: 0 2px;
    cursor: pointer;
    flex-shrink: 0;
}
.ktp-search-clear:hover { color: #595959; }
.ktp-student-home-toolbar-extra { display: flex; gap: 8px; flex-wrap: wrap; }

.ktp-home-empty-title { font-size: 16px; font-weight: 600; color: #262626; margin: 0 0 8px; }
.ktp-home-empty-actions {
    display: flex;
    gap: 10px;
    justify-content: center;
    flex-wrap: wrap;
    margin: 16px 0 12px;
}
.ktp-home-empty-or {
    font-size: 12px;
    color: #bfbfbf;
    width: 100%;
    text-align: center;
    margin-bottom: 4px;
}
@media (max-width: 640px) {
    .ktp-student-home-title-row { flex-direction: column; align-items: stretch; }
    .ktp-student-join-btn { width: 100%; }
    .ktp-student-home-search { max-width: none; }
}
.ktp-home-section-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
}
.ktp-home-section-title {
    margin: 0;
    font-size: 17px;
    font-weight: 600;
    color: #262626;
}
.ktp-home-section-meta { font-size: 13px; color: #8c8c8c; }
.ktp-home-empty-hint {
    font-size: 13px;
    color: #8c8c8c;
    margin: 0 0 16px;
    max-width: 420px;
    line-height: 1.5;
}
.ktp-home-empty-join {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 4px;
}
.ktp-home-empty-join .ktp-input {
    width: 160px;
    text-align: center;
    letter-spacing: 2px;
    text-transform: uppercase;
    font-family: ui-monospace, monospace;
}
.ktp-home-course-grid { margin-top: 0; }
.ktp-course-enter-btn { width: 100%; margin-bottom: 6px; }

/* 工作台 · 近期待办预览 */
.ktp-home-todo-strip { margin-bottom: 20px; }
.ktp-home-todo-panel {
    background: #fff;
    border: 1px solid #f0f0f0;
    border-radius: 12px;
    padding: 14px 16px;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
}
.ktp-home-todo-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}
.ktp-home-todo-title {
    font-size: 14px;
    font-weight: 600;
    color: #262626;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}
.ktp-home-todo-title em {
    font-style: normal;
    font-size: 12px;
    font-weight: 600;
    color: #fff;
    background: #ff4d4f;
    min-width: 18px;
    height: 18px;
    line-height: 18px;
    text-align: center;
    border-radius: 9px;
    padding: 0 5px;
}
.ktp-home-todo-items {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.ktp-home-todo-row {
    width: 100%;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px 10px;
    padding: 10px 12px;
    border-radius: 8px;
    background: #fafafa;
    cursor: pointer;
    text-align: left;
    font-size: 13px;
    transition: background .2s;
}
.ktp-home-todo-row:hover {
    background: #f0f9ff;
}
.ktp-home-todo-type {
    flex-shrink: 0;
    font-size: 12px;
    font-weight: 600;
    white-space: nowrap;
}
.ktp-home-todo-text {
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: #434343;
}
.ktp-home-todo-jump {
    flex: 1 1 100%;
    font-size: 11px;
    color: #1890ff;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.ktp-home-todo-arrow { color: #bfbfbf; font-size: 11px; flex-shrink: 0; }

/* 课程内 · 成绩/错题 */
.ktp-cr-scores-wrap .ktp-cr-score-stats { margin-bottom: 16px; }
.ktp-cr-wrong-tools {
    display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 16px;
}
.ktp-cr-wrong-item {
    padding: 14px 0; border-bottom: 1px solid #f0f0f0;
}
.ktp-cr-wrong-head { display: flex; justify-content: space-between; margin-bottom: 6px; }
.ktp-cr-wrong-title { font-weight: 600; font-size: 14px; margin-bottom: 4px; }
.ktp-cr-wrong-body { font-size: 13px; color: #333; line-height: 1.5; }
.ktp-cr-wrong-reason { font-size: 12px; color: #999; margin-top: 4px; }
.ktp-hw-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
.ktp-hw-type { font-size: 11px; color: #00a0e9; background: #e6f7ff; padding: 2px 8px; border-radius: 4px; }
.ktp-hw-actions { display: flex; gap: 8px; margin-top: 12px; flex-wrap: wrap; }

/* 课程上下文导航条 */
.ktp-course-context-bar {
    display: flex; align-items: center; gap: 12px;
    padding: 10px 16px; margin-bottom: 12px;
    background: #fff7e6; border: 1px solid #ffd591; border-radius: 8px;
    font-size: 13px;
}
.ktp-course-context-back {
    border: none; background: #fff; color: #fa8c16; cursor: pointer;
    padding: 4px 10px; border-radius: 6px; font-size: 13px;
    border: 1px solid #ffd591;
}
.ktp-course-context-name { font-weight: 600; color: #333; }
.ktp-course-context-hint { color: #999; font-size: 12px; margin-left: auto; }

/* 课程内 Tab 嵌入白板/签到 */
.ktp-detached-modules { display: none !important; }
.cr-embedded-mount {
    --edu-embed-nav-w: 112px;
    min-height: 420px;
}
.cr-embedded-module {
    display: block !important;
    position: relative;
    padding: 0;
    margin: 0;
}
.cr-embedded-module.edu-wb-page .edu-wb-shell {
    min-height: 480px;
    grid-template-columns: var(--edu-embed-nav-w) 1fr;
}
.cr-embedded-module .ktp-page-header { padding-top: 0; }
.cr-embedded-module .ktp-page-header .ktp-page-desc { font-size: 12px; }
.cr-embedded-mount .edu-wb-nav {
    width: 100%;
    padding: 10px 6px;
}
.cr-embedded-mount .edu-wb-logo-text,
.cr-embedded-mount .edu-wb-nav-item span { display: none; }
.cr-embedded-mount .edu-wb-nav-item {
    justify-content: flex-start;
    align-items: center;
    padding: 9px 6px;
    min-height: auto;
    width: 100%;
    font-size: 12px;
    letter-spacing: 0;
    white-space: nowrap;
    border-radius: 6px;
    margin-bottom: 2px;
}
.cr-embedded-mount .edu-wb-center { margin-left: 0; }
#cr-sub-whiteboard.active .cr-embedded-mount,
#cr-tab-signin.active .cr-embedded-mount { display: block; }

/* 协作白板嵌入横幅 */
.cr-collab-banner {
    display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap;
    padding: 14px 18px; margin-bottom: 12px; border-radius: 10px;
    background: linear-gradient(135deg, #e6f7ff 0%, #f0f5ff 100%);
    border: 1px solid #91d5ff;
}
.cr-collab-banner-main { display: flex; align-items: flex-start; gap: 12px; }
.cr-collab-banner-main > i { font-size: 28px; color: #1890ff; margin-top: 2px; }
.cr-collab-banner-main strong { display: block; font-size: 15px; color: #003a8c; margin-bottom: 4px; }
.cr-collab-banner-main p { margin: 0; font-size: 12px; color: #595959; line-height: 1.5; }
.cr-collab-banner-tags { display: flex; gap: 8px; flex-wrap: wrap; }
.cr-collab-banner-tags span {
    font-size: 12px; padding: 4px 10px; border-radius: 20px;
    background: #fff; color: #1890ff; border: 1px solid #91d5ff;
}

/* 课程成员表 */
.ktp-members-table-wrap { overflow-x: auto; }
.ktp-members-table { width: 100%; font-size: 13px; }
.ktp-member-avatar-sm {
    display: inline-flex; width: 24px; height: 24px; border-radius: 50%;
    background: #1890ff; color: #fff; align-items: center; justify-content: center;
    font-size: 11px; margin-right: 4px; vertical-align: middle;
}
.ktp-members-hint { font-size: 12px; color: #999; margin-top: 10px; }
.ktp-cr-wrong-src { font-size: 11px; color: #fa8c16; margin-bottom: 4px; }
.ktp-cr-wrong-sync-hint { font-size: 12px; color: #8c8c8c; margin-left: 12px; }

/* 教师端学生列表 */
.portal-course-card-ext .portal-students-block {
    margin-top: 14px; padding-top: 12px; border-top: 1px dashed #e8e8e8;
}
.portal-students-head { font-size: 13px; font-weight: 600; color: #595959; margin-bottom: 8px; }
.portal-students-list { display: flex; flex-direction: column; gap: 6px; max-height: 200px; overflow-y: auto; }
.portal-student-chip {
    display: flex; align-items: center; gap: 10px; width: 100%; padding: 8px 10px;
    border-radius: 8px; background: #fafafa; cursor: pointer; text-align: left;
    transition: background .2s;
}
.portal-student-chip:hover { background: #e6f7ff; }
.portal-student-avatar {
    width: 32px; height: 32px; border-radius: 50%; background: #00a0e9; color: #fff;
    display: flex; align-items: center; justify-content: center; font-weight: 600; flex-shrink: 0;
}
.portal-student-info { flex: 1; min-width: 0; }
.portal-student-info strong { display: block; font-size: 13px; }
.portal-student-info small { color: #8c8c8c; font-size: 11px; }
.portal-students-empty { font-size: 12px; color: #bfbfbf; padding: 8px 0; }

/* 教师学情弹窗 */
.ts-modal-body { padding-top: 8px; }
.ts-student-head { margin-bottom: 16px; }
.ts-student-name { font-size: 20px; font-weight: 600; color: #262626; }
.ts-student-meta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 6px; font-size: 13px; color: #8c8c8c; }
.ts-stat-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(100px, 1fr)); gap: 10px; margin-bottom: 18px; }
.ts-stat { text-align: center; padding: 12px 8px; background: #fafafa; border-radius: 8px; border: 1px solid #f0f0f0; }
.ts-stat-val { font-size: 18px; font-weight: 700; color: #1890ff; }
.ts-stat-lbl { font-size: 11px; color: #8c8c8c; margin-top: 4px; }
.ts-section h4 { font-size: 14px; margin: 0 0 10px; color: #434343; }
.ts-analysis-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 12px; }
.ts-analysis-item { text-align: center; padding: 10px; background: #f6ffed; border-radius: 8px; border: 1px solid #b7eb8f; }
.ts-analysis-val { font-size: 16px; font-weight: 700; color: #52c41a; }
.ts-analysis-label { font-size: 11px; color: #8c8c8c; }
.ts-score-table { font-size: 12px; margin-top: 8px; }
.ts-empty { color: #bfbfbf; font-size: 13px; }

.auth-input-wrap .auth-select { width: 100%; border: none; background: transparent; font-size: 14px; outline: none; padding: 12px 12px 12px 0; }

/* 学生端隐藏教师功能 */
body.ktp-role-student .ktp-teacher-only { display: none !important; }
body.ktp-role-teacher .ktp-student-only { display: none !important; }
body.ktp-role-student .ktp-teacher-nav { display: none !important; }
body.ktp-role-student .ktp-student-nav { display: flex !important; }
body.ktp-role-teacher .ktp-student-nav { display: none !important; }
body.ktp-role-student .ktp-sidebar { display: none !important; }
body.ktp-role-student .ktp-main { margin-left: 0 !important; padding: 24px; padding-bottom: 72px; }
body.ktp-role-student #page-scores { display: none !important; }
body.ktp-role-student .hw-score-teacher-only { display: none !important; }
body.ktp-role-teacher .hw-score-student-only { display: none !important; }
body.ktp-role-student .ktp-student-only.ktp-page { display: none; }
body.ktp-role-student .ktp-student-only.ktp-page.active { display: block !important; }
body.ktp-role-student #page-home.active { display: block !important; }
.ktp-home-empty { padding: 48px 24px; margin-top: 12px; }
.ktp-course-actions { flex-wrap: wrap; gap: 6px; }
.ktp-course-actions .ktp-btn-sm { font-size: 12px; padding: 4px 8px; }

/* 成绩分析 · 教师批改 */
.hw-teacher-layout { display: grid; grid-template-columns: 220px 1fr; gap: 16px; margin-top: 12px; }
.hw-teacher-sidebar { border: 1px solid #f0f0f0; border-radius: 10px; padding: 14px; background: #fafafa; }
.hw-teacher-student-head { font-size: 13px; font-weight: 600; margin: 14px 0 8px; color: #595959; }
.hw-teacher-student-list { display: flex; flex-direction: column; gap: 6px; max-height: 420px; overflow-y: auto; }
.hw-student-chip { display: flex; align-items: center; gap: 8px; width: 100%; padding: 8px 10px; border-radius: 8px; background: #fff; cursor: pointer; text-align: left; transition: background .2s; }
.hw-student-chip.active { background: rgba(230, 247, 255, 0.65); color: #1890ff; }
.hw-student-avatar { width: 28px; height: 28px; border-radius: 50%; background: #1890ff; color: #fff; display: flex; align-items: center; justify-content: center; font-size: 12px; flex-shrink: 0; }
.hw-student-info { display: flex; flex-direction: column; font-size: 12px; min-width: 0; }
.hw-student-info strong { font-size: 13px; color: #262626; }
.hw-student-info small { color: #8c8c8c; }
.hw-teacher-detail-title { margin: 0 0 12px; font-size: 16px; }
.hw-score-empty { text-align: center; color: #8c8c8c; padding: 24px; font-size: 13px; }
.hw-grade-list .hw-grade-item { align-items: center; }
.cr-teacher-score-bar { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; padding: 10px 12px; background: #f6ffed; border-radius: 8px; border: 1px solid #b7eb8f; }
.cr-teacher-score-bar .ktp-select { max-width: 240px; }

/* 课程资源分组 */
.cr-res-group { margin-bottom: 20px; }
.cr-res-group-title { font-size: 14px; font-weight: 600; color: #434343; margin-bottom: 8px; display: flex; align-items: center; gap: 8px; }
.cr-res-count { font-size: 11px; background: #e6f7ff; color: #1890ff; padding: 1px 8px; border-radius: 10px; font-weight: normal; }
.cr-res-item { position: relative; padding-right: 12px; }
.cr-res-item > .cr-res-open,
.cr-res-item > .cr-res-dl {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
}
.cr-res-dl { color: #1890ff; font-size: 16px; }
.cr-res-static-tag { font-size: 11px; color: #bfbfbf; position: absolute; right: 12px; top: 50%; transform: translateY(-50%); }
.ktp-tag-purple { background: #f9f0ff; color: #722ed1; border: 1px solid #d3adf7; }

.ts-basic-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 8px; }
.ts-basic-item { background: #fafafa; border: 1px solid #f0f0f0; border-radius: 8px; padding: 10px; }
.ts-basic-item label { display: block; font-size: 11px; color: #8c8c8c; margin-bottom: 4px; }
.ts-basic-item span { font-size: 13px; color: #262626; font-weight: 500; }
.ts-section-basic { margin-bottom: 12px; }
.portal-resources-list { display: flex; flex-direction: column; gap: 6px; }
.portal-resource-chip {
    display: flex; align-items: center; gap: 8px; width: 100%; padding: 8px 10px;
    border-radius: 8px; background: #f0f9ff; cursor: pointer; text-align: left; font-size: 13px;
    transition: background .2s;
}
.portal-resource-chip:hover { background: #e6f7ff; }
.portal-resource-chip span { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.portal-res-more { font-size: 11px; color: #8c8c8c; padding: 4px 0; }
.portal-refresh-btn { border: none; background: none; color: #1890ff; cursor: pointer; font-size: 12px; margin-left: 6px; }
.cr-res-open { border: none; background: #e6f7ff; color: #1890ff; padding: 4px 10px; border-radius: 6px; cursor: pointer; font-size: 12px; }
.rv-modal { max-width: 900px; }
.rv-body { min-height: 360px; display: flex; flex-direction: column; align-items: stretch; justify-content: center; background: #1a1a1a; border-radius: 8px; overflow: hidden; }
.rv-body.rv-has-docx { align-items: flex-start; justify-content: flex-start; background: #f5f5f5; overflow: auto; max-height: 70vh; }
.rv-docx-preview {
    width: 100%; min-height: 360px; padding: 24px 28px; background: #fff; color: #262626;
    text-align: left; line-height: 1.7; font-size: 14px; box-sizing: border-box;
}
.rv-docx-preview table { border-collapse: collapse; width: 100%; margin: 8px 0; }
.rv-docx-preview td, .rv-docx-preview th { border: 1px solid #d9d9d9; padding: 6px 8px; }
.rv-docx-preview img { max-width: 100%; height: auto; }
.rv-body.rv-has-docx { align-items: flex-start; justify-content: flex-start; background: #f5f5f5; overflow: auto; max-height: 70vh; }
.rv-docx-preview {
    width: 100%; min-height: 360px; padding: 24px 28px; background: #fff; color: #262626;
    text-align: left; line-height: 1.7; font-size: 14px; box-sizing: border-box;
}
.rv-docx-preview table { border-collapse: collapse; width: 100%; margin: 8px 0; }
.rv-docx-preview td, .rv-docx-preview th { border: 1px solid #d9d9d9; padding: 6px 8px; }
.rv-docx-preview img { max-width: 100%; height: auto; }
.rv-body.rv-has-docx { align-items: flex-start; justify-content: flex-start; background: #f5f5f5; overflow: auto; max-height: 70vh; }
.rv-docx-preview {
    width: 100%; min-height: 360px; padding: 24px 28px; background: #fff; color: #262626;
    text-align: left; line-height: 1.7; font-size: 14px; box-sizing: border-box;
}
.rv-docx-preview table { border-collapse: collapse; width: 100%; margin: 8px 0; }
.rv-docx-preview td, .rv-docx-preview th { border: 1px solid #d9d9d9; padding: 6px 8px; }
.rv-docx-preview img { max-width: 100%; height: auto; }
.rv-body.rv-has-docx { align-items: flex-start; justify-content: flex-start; background: #f5f5f5; overflow: auto; max-height: 70vh; }
.rv-docx-preview {
    width: 100%; min-height: 360px; padding: 24px 28px; background: #fff; color: #262626;
    text-align: left; line-height: 1.7; font-size: 14px; box-sizing: border-box;
}
.rv-docx-preview table { border-collapse: collapse; width: 100%; margin: 8px 0; }
.rv-docx-preview td, .rv-docx-preview th { border: 1px solid #d9d9d9; padding: 6px 8px; }
.rv-docx-preview img { max-width: 100%; height: auto; }
.rv-body.rv-has-docx { align-items: flex-start; justify-content: flex-start; background: #f5f5f5; overflow: auto; max-height: 70vh; }
.rv-docx-preview {
    width: 100%; min-height: 360px; padding: 24px 28px; background: #fff; color: #262626;
    text-align: left; line-height: 1.7; font-size: 14px; box-sizing: border-box;
}
.rv-docx-preview table { border-collapse: collapse; width: 100%; margin: 8px 0; }
.rv-docx-preview td, .rv-docx-preview th { border: 1px solid #d9d9d9; padding: 6px 8px; }
.rv-docx-preview img { max-width: 100%; height: auto; }
.rv-video { max-width: 100%; max-height: 70vh; width: 100%; }
.cw-video { max-width: 100%; max-height: calc(85vh - 48px); width: 100%; background: #000; border-radius: 4px; }
.cw-video { max-width: 100%; max-height: calc(85vh - 48px); width: 100%; background: #000; border-radius: 4px; }
.cw-video { max-width: 100%; max-height: calc(85vh - 48px); width: 100%; background: #000; border-radius: 4px; }
.cw-video { max-width: 100%; max-height: calc(85vh - 48px); width: 100%; background: #000; border-radius: 4px; }
.cw-video { max-width: 100%; max-height: calc(85vh - 48px); width: 100%; background: #000; border-radius: 4px; }
.rv-iframe { width: 100%; height: 70vh; border: none; background: #fff; }
.rv-image { max-width: 100%; max-height: 70vh; object-fit: contain; }
.rv-fallback { text-align: center; color: #fff; padding: 40px; }
.rv-fallback i { font-size: 48px; margin-bottom: 16px; opacity: .7; }
.rv-fallback-hint { font-size: 13px; opacity: .75; margin-bottom: 16px; }
.rv-homework-panel { text-align: center; color: #fff; padding: 40px 32px; max-width: 520px; margin: 0 auto; }
.rv-homework-panel > i { font-size: 48px; margin-bottom: 16px; opacity: .85; color: #91d5ff; }
.rv-homework-panel strong { font-size: 18px; display: block; margin-bottom: 10px; }
.rv-homework-meta { font-size: 13px; opacity: .8; margin-bottom: 12px; }
.rv-loading { color: #fff; font-size: 28px; padding: 48px; }
.rv-empty { color: #fff; padding: 40px; }
.rv-text-preview { width: 100%; max-height: 70vh; overflow: auto; margin: 0; padding: 20px 24px; background: #fff; color: #262626; font-size: 14px; line-height: 1.65; white-space: pre-wrap; word-break: break-word; text-align: left; align-self: stretch; }
.rv-docx-preview { width: 100%; max-height: 70vh; overflow: auto; padding: 24px 32px; background: #fff; color: #262626; text-align: left; align-self: stretch; }
.rv-sheet-wrap { width: 100%; max-height: 70vh; overflow: auto; background: #fff; color: #262626; text-align: left; align-self: stretch; padding: 12px 16px 20px; }
.rv-sheet-tabs { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.rv-sheet-tab { border: 1px solid #d9d9d9; background: #fafafa; color: #595959; border-radius: 6px; padding: 4px 12px; font-size: 12px; cursor: pointer; }
.rv-sheet-tab.active, .rv-sheet-tab:hover { border-color: #00a0e9; color: #00a0e9; background: #e6f7ff; }
.rv-sheet-pane { overflow: auto; }
.rv-sheet-pane table { border-collapse: collapse; width: 100%; font-size: 13px; }
.rv-sheet-pane td, .rv-sheet-pane th { border: 1px solid #e8e8e8; padding: 6px 10px; white-space: nowrap; }
.rv-sheet-pane th { background: #fafafa; font-weight: 600; }
.rv-archive { width: 100%; max-height: 70vh; overflow: auto; padding: 20px 24px; background: #fff; color: #262626; text-align: left; align-self: stretch; }
.rv-archive-hint { font-size: 13px; color: #8c8c8c; margin: 0 0 12px; }
.rv-archive-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.rv-archive-item { display: flex; align-items: center; gap: 8px; width: 100%; padding: 10px 12px; border: 1px solid #f0f0f0; border-radius: 8px; background: #fafafa; cursor: pointer; font-size: 13px; color: #262626; text-align: left; }
.rv-archive-item:hover { border-color: #91d5ff; background: #e6f7ff; color: #00a0e9; }
.rv-empty-inline { color: #8c8c8c; padding: 12px; }
.rv-sheet-wrap { width: 100%; max-height: 70vh; overflow: auto; background: #fff; color: #262626; text-align: left; align-self: stretch; padding: 12px 16px 20px; }
.rv-sheet-tabs { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.rv-sheet-tab { border: 1px solid #d9d9d9; background: #fafafa; color: #595959; border-radius: 6px; padding: 4px 12px; font-size: 12px; cursor: pointer; }
.rv-sheet-tab.active, .rv-sheet-tab:hover { border-color: #00a0e9; color: #00a0e9; background: #e6f7ff; }
.rv-sheet-pane { overflow: auto; }
.rv-sheet-pane table { border-collapse: collapse; width: 100%; font-size: 13px; }
.rv-sheet-pane td, .rv-sheet-pane th { border: 1px solid #e8e8e8; padding: 6px 10px; white-space: nowrap; }
.rv-sheet-pane th { background: #fafafa; font-weight: 600; }
.rv-archive { width: 100%; max-height: 70vh; overflow: auto; padding: 20px 24px; background: #fff; color: #262626; text-align: left; align-self: stretch; }
.rv-archive-hint { font-size: 13px; color: #8c8c8c; margin: 0 0 12px; }
.rv-archive-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.rv-archive-item { display: flex; align-items: center; gap: 8px; width: 100%; padding: 10px 12px; border: 1px solid #f0f0f0; border-radius: 8px; background: #fafafa; cursor: pointer; font-size: 13px; color: #262626; text-align: left; }
.rv-archive-item:hover { border-color: #91d5ff; background: #e6f7ff; color: #00a0e9; }
.rv-empty-inline { color: #8c8c8c; padding: 12px; }
.rv-sheet-wrap { width: 100%; max-height: 70vh; overflow: auto; background: #fff; color: #262626; text-align: left; align-self: stretch; padding: 12px 16px 20px; }
.rv-sheet-tabs { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.rv-sheet-tab { border: 1px solid #d9d9d9; background: #fafafa; color: #595959; border-radius: 6px; padding: 4px 12px; font-size: 12px; cursor: pointer; }
.rv-sheet-tab.active, .rv-sheet-tab:hover { border-color: #00a0e9; color: #00a0e9; background: #e6f7ff; }
.rv-sheet-pane { overflow: auto; }
.rv-sheet-pane table { border-collapse: collapse; width: 100%; font-size: 13px; }
.rv-sheet-pane td, .rv-sheet-pane th { border: 1px solid #e8e8e8; padding: 6px 10px; white-space: nowrap; }
.rv-sheet-pane th { background: #fafafa; font-weight: 600; }
.rv-archive { width: 100%; max-height: 70vh; overflow: auto; padding: 20px 24px; background: #fff; color: #262626; text-align: left; align-self: stretch; }
.rv-archive-hint { font-size: 13px; color: #8c8c8c; margin: 0 0 12px; }
.rv-archive-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.rv-archive-item { display: flex; align-items: center; gap: 8px; width: 100%; padding: 10px 12px; border: 1px solid #f0f0f0; border-radius: 8px; background: #fafafa; cursor: pointer; font-size: 13px; color: #262626; text-align: left; }
.rv-archive-item:hover { border-color: #91d5ff; background: #e6f7ff; color: #00a0e9; }
.rv-empty-inline { color: #8c8c8c; padding: 12px; }
.rv-sheet-wrap { width: 100%; max-height: 70vh; overflow: auto; background: #fff; color: #262626; text-align: left; align-self: stretch; padding: 12px 16px 20px; }
.rv-sheet-tabs { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.rv-sheet-tab { border: 1px solid #d9d9d9; background: #fafafa; color: #595959; border-radius: 6px; padding: 4px 12px; font-size: 12px; cursor: pointer; }
.rv-sheet-tab.active, .rv-sheet-tab:hover { border-color: #00a0e9; color: #00a0e9; background: #e6f7ff; }
.rv-sheet-pane { overflow: auto; }
.rv-sheet-pane table { border-collapse: collapse; width: 100%; font-size: 13px; }
.rv-sheet-pane td, .rv-sheet-pane th { border: 1px solid #e8e8e8; padding: 6px 10px; white-space: nowrap; }
.rv-sheet-pane th { background: #fafafa; font-weight: 600; }
.rv-archive { width: 100%; max-height: 70vh; overflow: auto; padding: 20px 24px; background: #fff; color: #262626; text-align: left; align-self: stretch; }
.rv-archive-hint { font-size: 13px; color: #8c8c8c; margin: 0 0 12px; }
.rv-archive-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.rv-archive-item { display: flex; align-items: center; gap: 8px; width: 100%; padding: 10px 12px; border: 1px solid #f0f0f0; border-radius: 8px; background: #fafafa; cursor: pointer; font-size: 13px; color: #262626; text-align: left; }
.rv-archive-item:hover { border-color: #91d5ff; background: #e6f7ff; color: #00a0e9; }
.rv-empty-inline { color: #8c8c8c; padding: 12px; }
.rv-sheet-wrap { width: 100%; max-height: 70vh; overflow: auto; background: #fff; color: #262626; text-align: left; align-self: stretch; padding: 12px 16px 20px; }
.rv-sheet-tabs { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.rv-sheet-tab { border: 1px solid #d9d9d9; background: #fafafa; color: #595959; border-radius: 6px; padding: 4px 12px; font-size: 12px; cursor: pointer; }
.rv-sheet-tab.active, .rv-sheet-tab:hover { border-color: #00a0e9; color: #00a0e9; background: #e6f7ff; }
.rv-sheet-pane { overflow: auto; }
.rv-sheet-pane table { border-collapse: collapse; width: 100%; font-size: 13px; }
.rv-sheet-pane td, .rv-sheet-pane th { border: 1px solid #e8e8e8; padding: 6px 10px; white-space: nowrap; }
.rv-sheet-pane th { background: #fafafa; font-weight: 600; }
.rv-archive { width: 100%; max-height: 70vh; overflow: auto; padding: 20px 24px; background: #fff; color: #262626; text-align: left; align-self: stretch; }
.rv-archive-hint { font-size: 13px; color: #8c8c8c; margin: 0 0 12px; }
.rv-archive-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.rv-archive-item { display: flex; align-items: center; gap: 8px; width: 100%; padding: 10px 12px; border: 1px solid #f0f0f0; border-radius: 8px; background: #fafafa; cursor: pointer; font-size: 13px; color: #262626; text-align: left; }
.rv-archive-item:hover { border-color: #91d5ff; background: #e6f7ff; color: #00a0e9; }
.rv-empty-inline { color: #8c8c8c; padding: 12px; }
.rv-file-actions { display: inline-flex; align-items: center; gap: 6px; margin-left: 8px; vertical-align: middle; }
.rv-act-btn { display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px; border-radius: 8px; border: 1px solid #d9d9d9; background: #fff; color: #595959; cursor: pointer; text-decoration: none; transition: all .15s; }
.rv-act-btn:hover { border-color: #00a0e9; color: #00a0e9; background: #e6f7ff; }
.rv-act-view { color: #00a0e9; border-color: #91d5ff; background: #f0f9ff; }
.cl-hw-file-row { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin: 8px 0 4px; }
.cl-hw-fname { font-weight: 500; color: #262626; word-break: break-all; }
.cl-hw-desc-muted { font-size: 12px; color: #8c8c8c; margin-top: 4px; }
.cl-hw-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; justify-content: flex-end; }
.cl-hw-title-link {
    background: none; border: none; padding: 0; margin: 0;
    color: #1890ff; font: inherit; font-weight: 500; cursor: pointer; text-align: left;
}
.cl-hw-title-link:hover { color: #096dd9; text-decoration: underline; }
.cl-hw-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; justify-content: flex-end; }
.cl-hw-title-link {
    background: none; border: none; padding: 0; margin: 0;
    color: #1890ff; font: inherit; font-weight: 500; cursor: pointer; text-align: left;
}
.cl-hw-title-link:hover { color: #096dd9; text-decoration: underline; }
.cl-hw-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; justify-content: flex-end; }
.cl-hw-title-link {
    background: none; border: none; padding: 0; margin: 0;
    color: #1890ff; font: inherit; font-weight: 500; cursor: pointer; text-align: left;
}
.cl-hw-title-link:hover { color: #096dd9; text-decoration: underline; }
.cl-hw-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; justify-content: flex-end; }
.cl-hw-title-link {
    background: none; border: none; padding: 0; margin: 0;
    color: #1890ff; font: inherit; font-weight: 500; cursor: pointer; text-align: left;
}
.cl-hw-title-link:hover { color: #096dd9; text-decoration: underline; }
.cl-hw-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; justify-content: flex-end; }
.cl-hw-title-link {
    background: none; border: none; padding: 0; margin: 0;
    color: #1890ff; font: inherit; font-weight: 500; cursor: pointer; text-align: left;
}
.cl-hw-title-link:hover { color: #096dd9; text-decoration: underline; }
.grade-file-actions { margin-top: 10px; }

/* 单元资源管理 */
.tp-unit-mgr { display: grid; grid-template-columns: 200px 1fr; gap: 16px; min-height: 320px; }
.tp-unit-sidebar { border: 1px solid #f0f0f0; border-radius: 10px; padding: 12px; background: #fafafa; }
.tp-unit-sidebar-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; font-size: 13px; }
.tp-unit-list { display: flex; flex-direction: column; gap: 6px; max-height: 280px; overflow-y: auto; }
.tp-unit-item { display: flex; align-items: center; justify-content: space-between; width: 100%; padding: 8px 10px; border-radius: 8px; background: #fff; cursor: pointer; text-align: left; font-size: 13px; transition: background .2s; }
.tp-unit-item.active { background: rgba(230, 247, 255, 0.65); color: #1890ff; }
.tp-unit-item-count { font-size: 11px; background: #f0f0f0; padding: 1px 6px; border-radius: 8px; }
.tp-unit-item.active .tp-unit-item-count { background: #bae7ff; }
.tp-unit-main { border: 1px solid #f0f0f0; border-radius: 10px; padding: 14px; }
.tp-current-unit-title { margin: 0 0 12px; font-size: 15px; color: #262626; }
.tp-unit-res-list { margin-bottom: 14px; max-height: 160px; overflow-y: auto; }
.tp-unit-upload-grid { margin-top: 8px; }
.portal-unit-summary-list { display: flex; flex-direction: column; gap: 6px; }
.portal-unit-summary { display: flex; align-items: center; gap: 8px; font-size: 12px; color: #595959; padding: 6px 8px; background: #fafafa; border-radius: 6px; }
.portal-unit-summary span { margin-left: auto; color: #8c8c8c; }
.cr-unit-block { margin-bottom: 20px; border: 1px solid #f0f0f0; border-radius: 10px; overflow: hidden; }
.cr-unit-title { padding: 10px 14px; background: #fafafa; font-size: 14px; font-weight: 600; color: #262626; display: flex; align-items: center; gap: 8px; border-bottom: 1px solid #f0f0f0; }
.cr-unit-block .ktp-file-list { padding: 8px 12px 12px; }

/* 消息通知 */
.ktp-notify-btn { position: relative; border: none; background: #f5f5f5; width: 36px; height: 36px; border-radius: 50%; cursor: pointer; color: #595959; display: inline-flex; align-items: center; justify-content: center; }
.ktp-notify-btn:hover, .ktp-notify-btn.has-unread { background: #e6f7ff; color: #1890ff; }
.ktp-notify-badge { position: absolute; top: -2px; right: -2px; min-width: 16px; height: 16px; padding: 0 4px; border-radius: 8px; background: #ff4d4f; color: #fff; font-size: 10px; line-height: 16px; text-align: center; }
.ktp-notify-body { max-height: 360px; overflow-y: auto; }
.ktp-notify-item { display: flex; gap: 12px; padding: 14px 16px; border-radius: 10px; background: #fff; box-shadow: 0 2px 8px rgba(0,0,0,.05); }
.ktp-notify-item.unread { background: #f6ffed; }
.ktp-notify-text { font-size: 14px; color: #262626; line-height: 1.5; }
.ktp-notify-time { font-size: 12px; color: #8c8c8c; margin-top: 4px; }
.ktp-notify-empty { text-align: center; padding: 40px 20px; color: #8c8c8c; }
.ktp-notify-empty i { font-size: 36px; margin-bottom: 12px; opacity: .5; }

/* 学生待办事项 */
.ktp-todo-body { max-height: 420px; overflow-y: auto; padding: 0 !important; }
.ktp-todo-page-list { display: flex; flex-direction: column; gap: 10px; }
.ktp-todo-section-title { font-size: 13px; font-weight: 600; color: #595959; margin: 8px 0 4px; }
.ktp-todo-section-title.done { color: #8c8c8c; margin-top: 16px; }
.ktp-todo-item { display: flex; gap: 12px; padding: 14px 16px; border-radius: 10px; background: #fff; box-shadow: 0 2px 8px rgba(0,0,0,.05); }
.ktp-todo-item.ktp-todo-clickable { cursor: pointer; transition: box-shadow .2s, border-color .2s; }
.ktp-todo-item.ktp-todo-clickable:hover { box-shadow: 0 4px 16px rgba(0,160,233,.12); }
.ktp-todo-item.unread { background: #f6ffed; }
.ktp-todo-icon { width: 40px; height: 40px; border-radius: 10px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; font-size: 16px; }
.ktp-todo-main { flex: 1; min-width: 0; }
.ktp-todo-head { display: flex; justify-content: space-between; gap: 8px; margin-bottom: 4px; }
.ktp-todo-type { font-size: 12px; color: #8c8c8c; }
.ktp-todo-time { font-size: 12px; color: #bfbfbf; white-space: nowrap; }
.ktp-todo-title { font-size: 15px; font-weight: 600; color: #262626; line-height: 1.4; }
.ktp-todo-desc { font-size: 13px; color: #595959; margin-top: 6px; line-height: 1.5; }
.ktp-todo-deadline { font-size: 12px; color: #fa8c16; margin-top: 6px; }
.ktp-todo-deadline.urgent { color: #fa541c; font-weight: 600; }
.ktp-todo-deadline.overdue { color: #ff4d4f; font-weight: 600; }
.cl-deadline.urgent { color: #fa541c; font-weight: 600; }
.cl-deadline.overdue { color: #ff4d4f; font-weight: 600; }
.ktp-todo-jump { font-size: 12px; color: #1890ff; margin-top: 8px; display: flex; align-items: center; gap: 6px; line-height: 1.4; }
.ktp-todo-jump i { font-size: 11px; opacity: .85; flex-shrink: 0; }
.ktp-todo-actions { display: flex; gap: 8px; margin-top: 10px; flex-wrap: wrap; }
.ktp-todo-empty { text-align: center; padding: 40px 20px; color: #8c8c8c; }
.ktp-todo-empty i { font-size: 40px; margin-bottom: 12px; opacity: .45; display: block; }
.ktp-todo-empty span { display: block; font-size: 12px; margin-top: 6px; color: #bfbfbf; }
.ktp-link-btn { border: none; background: none; color: #1890ff; cursor: pointer; font-size: 13px; padding: 0; }

.ktp-nav-badge { display: inline-flex; min-width: 16px; height: 16px; padding: 0 4px; margin-left: 4px; border-radius: 8px; background: #ff4d4f; color: #fff; font-size: 10px; line-height: 16px; vertical-align: middle; }
.join-tab-bar { display: flex; gap: 8px; margin-bottom: 4px; }
.join-tab-btn { flex: 1; background: #fafafa; border-radius: 8px; padding: 8px 10px; font-size: 13px; cursor: pointer; color: #595959; }
.join-tab-btn.active { background: transparent; color: #1890ff; font-weight: 500; }
.join-scan-viewport { width: 100%; max-width: 320px; margin: 0 auto; min-height: 260px; aspect-ratio: 3 / 4; border-radius: 10px; overflow: hidden; background: #111; position: relative; }
.join-scan-viewport #joinScanReader,
.join-scan-viewport #studentQrReader { width: 100% !important; height: 100% !important; min-height: 260px !important; padding: 0 !important; border: none !important; position: relative !important; }
.join-scan-viewport video { width: 100% !important; height: 100% !important; object-fit: cover !important; display: block !important; }
.join-scan-viewport #qr-shaded-region { border: none !important; box-shadow: none !important; }
.student-signin-scan { max-width: 320px; }
#crSigninMount .join-scan-viewport { min-height: 280px; max-width: 320px; margin: 0 auto; }
#crSigninMount #studentQrReader { min-height: 260px !important; }
.student-qr-loading { display:flex;align-items:center;justify-content:center;height:100%;min-height:240px;color:#8c8c8c;font-size:13px;background:#111;border-radius:10px; }
.join-scan-reader { width: 100%; max-width: 300px; margin: 0 auto; }
.ktp-attendance-list { display: flex; flex-direction: column; gap: 12px; }
.ktp-attendance-card { border-radius: 12px; padding: 16px; background: #fff; box-shadow: 0 2px 8px rgba(0,0,0,.06); }
.ktp-attendance-head { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; }
.ktp-attendance-name { font-size: 16px; font-weight: 600; color: #262626; }
.ktp-attendance-meta { font-size: 12px; color: #8c8c8c; margin-top: 4px; }
.ktp-attendance-rate { font-size: 22px; font-weight: 700; }
.ktp-attendance-rate.good { color: #52c41a; }
.ktp-attendance-rate.ok { color: #1890ff; }
.ktp-attendance-rate.warn { color: #fa8c16; }
.ktp-attendance-rate.none { color: #bfbfbf; }
.ktp-attendance-bar-wrap { height: 8px; background: #f5f5f5; border-radius: 4px; margin: 12px 0 8px; overflow: hidden; }
.ktp-attendance-bar { height: 100%; border-radius: 4px; background: #1890ff; transition: width .3s; }
.ktp-attendance-bar.good { background: #52c41a; }
.ktp-attendance-bar.ok { background: #1890ff; }
.ktp-attendance-bar.warn { background: #fa8c16; }
.ktp-attendance-foot-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: 4px;
}
.ktp-attendance-foot { font-size: 12px; color: #8c8c8c; margin-bottom: 0; flex: 1 1 180px; }
.ktp-attendance-actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; justify-content: flex-end; }
.ktp-att-print-btn { min-width: 108px; }
.ktp-att-signin-btn { min-width: 96px; }
.ktp-att-detail-btn { font-size: 13px; color: #0284c7; padding: 6px 10px; }
.ktp-btn-text { background: transparent; border: none; box-shadow: none; cursor: pointer; }
.ktp-btn-text:hover { color: #0369a1; text-decoration: underline; }
.ktp-att-sheet-meta { font-size: 13px; color: #64748b; margin: 0 0 12px; }
.ktp-att-sheet-scroll { overflow-x: auto; max-width: 100%; }
.ktp-att-sheet-table { min-width: 640px; }
.ktp-att-sheet-table .good { color: #52c41a; font-weight: 600; }
.ktp-att-sheet-table .warn { color: #ff4d4f; font-weight: 600; }
.ktp-attendance-foot { font-size: 12px; color: #8c8c8c; margin-bottom: 0; flex: 1 1 180px; }
.ktp-attendance-actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; justify-content: flex-end; }
.ktp-att-print-btn { min-width: 108px; }
.ktp-att-signin-btn { min-width: 96px; }
.ktp-att-detail-btn { font-size: 13px; color: #0284c7; padding: 6px 10px; }
.ktp-btn-text { background: transparent; border: none; box-shadow: none; cursor: pointer; }
.ktp-btn-text:hover { color: #0369a1; text-decoration: underline; }
.ktp-att-sheet-meta { font-size: 13px; color: #64748b; margin: 0 0 12px; }
.ktp-att-sheet-scroll { overflow-x: auto; max-width: 100%; }
.ktp-att-sheet-table { min-width: 640px; }
.ktp-att-sheet-table .good { color: #52c41a; font-weight: 600; }
.ktp-att-sheet-table .warn { color: #ff4d4f; font-weight: 600; }
.ktp-attendance-foot { font-size: 12px; color: #8c8c8c; margin-bottom: 0; flex: 1 1 180px; }
.ktp-attendance-actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; justify-content: flex-end; }
.ktp-att-print-btn { min-width: 108px; }
.ktp-att-signin-btn { min-width: 96px; }
.ktp-att-detail-btn { font-size: 13px; color: #0284c7; padding: 6px 10px; }
.ktp-btn-text { background: transparent; border: none; box-shadow: none; cursor: pointer; }
.ktp-btn-text:hover { color: #0369a1; text-decoration: underline; }
.ktp-att-sheet-meta { font-size: 13px; color: #64748b; margin: 0 0 12px; }
.ktp-att-sheet-scroll { overflow-x: auto; max-width: 100%; }
.ktp-att-sheet-table { min-width: 640px; }
.ktp-att-sheet-table .good { color: #52c41a; font-weight: 600; }
.ktp-att-sheet-table .warn { color: #ff4d4f; font-weight: 600; }
.ktp-attendance-foot { font-size: 12px; color: #8c8c8c; margin-bottom: 0; flex: 1 1 180px; }
.ktp-attendance-actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; justify-content: flex-end; }
.ktp-att-print-btn { min-width: 108px; }
.ktp-att-signin-btn { min-width: 96px; }
.ktp-att-detail-btn { font-size: 13px; color: #0284c7; padding: 6px 10px; }
.ktp-btn-text { background: transparent; border: none; box-shadow: none; cursor: pointer; }
.ktp-btn-text:hover { color: #0369a1; text-decoration: underline; }
.ktp-att-sheet-meta { font-size: 13px; color: #64748b; margin: 0 0 12px; }
.ktp-att-sheet-scroll { overflow-x: auto; max-width: 100%; }
.ktp-att-sheet-table { min-width: 640px; }
.ktp-att-sheet-table .good { color: #52c41a; font-weight: 600; }
.ktp-att-sheet-table .warn { color: #ff4d4f; font-weight: 600; }
.ktp-attendance-foot { font-size: 12px; color: #8c8c8c; margin-bottom: 0; flex: 1 1 180px; }
.ktp-attendance-actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; justify-content: flex-end; }
.ktp-att-print-btn { min-width: 108px; }
.ktp-att-signin-btn { min-width: 96px; }
.ktp-att-detail-btn { font-size: 13px; color: #0284c7; padding: 6px 10px; }
.ktp-btn-text { background: transparent; border: none; box-shadow: none; cursor: pointer; }
.ktp-btn-text:hover { color: #0369a1; text-decoration: underline; }
.ktp-att-sheet-meta { font-size: 13px; color: #64748b; margin: 0 0 12px; }
.ktp-att-sheet-scroll { overflow-x: auto; max-width: 100%; }
.ktp-att-sheet-table { min-width: 640px; }
.ktp-att-sheet-table .good { color: #52c41a; font-weight: 600; }
.ktp-att-sheet-table .warn { color: #ff4d4f; font-weight: 600; }
.ktp-notify-page-list { display: flex; flex-direction: column; gap: 10px; }
.ktp-notify-item { display: flex; gap: 12px; padding: 14px 16px; border-radius: 10px; background: #fff; box-shadow: 0 2px 8px rgba(0,0,0,.05); }
.ktp-notify-item.unread { background: #f6ffed; }
.ktp-notify-icon { width: 40px; height: 40px; border-radius: 10px; background: #e6f7ff; color: #1890ff; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.ktp-notify-main { flex: 1; min-width: 0; }

/* 签到方式选择 */
.ktp-signin-method-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 8px;
    margin-top: 8px;
}
@media (max-width: 900px) {
    .ktp-signin-method-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 560px) {
    .ktp-signin-method-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.ktp-signin-method-card {
    display: flex; flex-direction: column; align-items: flex-start; gap: 4px;
    padding: 12px 14px;
    border-radius: 10px;
    background: transparent;
    border: none;
    box-shadow: none;
    cursor: pointer; text-align: left;
    transition: background .2s;
}
.ktp-signin-method-card strong { font-size: 14px; color: #262626; }
.ktp-signin-method-card span { font-size: 11px; color: #8c8c8c; line-height: 1.35; }
.ktp-signin-method-card:hover {
    background: rgba(240, 249, 255, 0.6);
}
.ktp-signin-method-card.active {
    background: rgba(230, 247, 255, 0.45);
    color: #1890ff;
}

/* 签到页 · 顶部横幅 */
.ktp-signin-page-head {
    position: relative;
    margin-bottom: 20px;
}
.ktp-signin-page-head .ktp-signin-hero {
    margin-bottom: 0;
    padding-right: 140px;
}
.ktp-signin-page-head .ktp-page-title {
    font-size: 22px;
    margin-bottom: 6px;
    color: #fff;
}
.ktp-signin-page-head .ktp-page-desc {
    opacity: .92;
    font-size: 14px;
    color: #fff;
    margin: 0;
}
.ktp-signin-start-btn {
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    background: #fff !important;
    color: #1890ff !important;
    border: none;
    box-shadow: 0 2px 8px rgba(0, 0, 0, .12);
}
@media (max-width: 640px) {
    .ktp-signin-page-head .ktp-signin-hero { padding-right: 28px; padding-bottom: 52px; }
    .ktp-signin-start-btn {
        right: 16px;
        top: auto;
        bottom: 16px;
        transform: none;
    }
}
.ktp-signin-student-status { display: flex; align-items: center; gap: 8px; padding: 10px 12px; border-radius: 8px; font-size: 13px; margin-bottom: 12px; }
.ktp-signin-student-status.idle { background: #fafafa; border: 1px solid #f0f0f0; color: #8c8c8c; }
.ktp-signin-student-status.active { background: #f6ffed; border: 1px solid #b7eb8f; color: #389e0d; }
.ktp-signin-student-status.success { background: #f6ffed; border: 1px solid #52c41a; color: #237804; }
.ktp-signin-student-status.fail { background: #fff7e6; border: 1px solid #ffd591; color: #d46b08; }
.student-qr-viewport-wrap { margin-bottom: 8px; }
.student-qr-result { display: none; text-align: center; padding: 20px 16px; border-radius: 10px; margin-bottom: 8px; }
.student-qr-result.success { display: block; background: #f6ffed; border: 1px solid #b7eb8f; color: #389e0d; }
.student-qr-result.fail { display: block; background: #fff2f0; border: 1px solid #ffccc7; color: #cf1322; }
.student-qr-result i { font-size: 28px; display: block; margin-bottom: 8px; }
.student-qr-result p { margin: 0 0 10px; font-size: 14px; }
.ktp-signin-active-badge { display: inline-flex; padding: 4px 10px; border-radius: 20px; font-size: 12px; font-weight: 600; margin-bottom: 8px; background: #e6f7ff; color: #096dd9; }
.ktp-signin-active-badge.type-qrcode { background: #f9f0ff; color: #722ed1; }
.ktp-signin-active-badge.type-location { background: #fff7e6; color: #d46b08; }
.ktp-signin-active-badge.type-wb_sign { background: #f6ffed; color: #389e0d; }
.ktp-signin-active-badge.type-gesture { background: #fff0f6; color: #c41d7f; }
.cr-signin-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 10px 12px; margin-bottom: 10px; border-radius: 10px; background: linear-gradient(90deg, #e6f7ff, #f6ffed); border: 1px solid #bae7ff; font-size: 13px; color: #595959; }

/* 学生端底部导航（小屏） */
.ktp-student-mobile-bar { display: none; }
@media (max-width: 768px) {
    body.ktp-role-student .ktp-student-nav { display: flex !important; flex-wrap: wrap; gap: 4px; }
    body.ktp-role-student .ktp-student-mobile-bar {
        display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 900;
        background: #fff; border-top: 1px solid #f0f0f0; box-shadow: 0 -2px 8px rgba(0,0,0,.06);
        padding: 6px 8px calc(6px + env(safe-area-inset-bottom));
    }
    .ktp-student-mobile-bar button {
        flex: 1; border: none; background: none; padding: 6px 4px; font-size: 11px; color: #8c8c8c;
        display: flex; flex-direction: column; align-items: center; gap: 2px; cursor: pointer;
    }
    .ktp-student-mobile-bar button i { font-size: 18px; }
    .ktp-student-mobile-bar button.active { color: #1890ff; font-weight: 600; }
}
@media (min-width: 769px) {
    body.ktp-role-student .ktp-student-mobile-bar { display: none !important; }
}

/* 资源操作按钮 */
.tp-res-actions { display: flex; gap: 4px; flex-shrink: 0; }
.cr-res-edit, .cr-res-del { border: 1px solid #e8e8e8; background: #fff; border-radius: 6px; width: 30px; height: 30px; cursor: pointer; color: #595959; }
.cr-res-edit:hover { border-color: #1890ff; color: #1890ff; }
.cr-res-del:hover { border-color: #ff4d4f; color: #ff4d4f; }
.ktp-btn-danger { background: #fff1f0; border-color: #ffa39e; color: #cf1322; }
.ktp-btn-danger:hover { background: #ff4d4f; border-color: #ff4d4f; color: #fff; }

/* 教师端 · 课程详情 */
.tp-course-detail { animation: tpFadeIn .2s ease; }
@keyframes tpFadeIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.tp-detail-header { display: flex; flex-wrap: wrap; gap: 16px; align-items: flex-start; margin-bottom: 20px; padding: 20px; background: #fff; border-radius: 12px; border: 1px solid #f0f0f0; }
.tp-back-btn {
    flex-shrink: 0;
    font-size: 14px !important;
    font-weight: 700;
    padding: 8px 18px !important;
    min-height: 38px;
    color: #0050b3 !important;
    background: linear-gradient(135deg, #e6f7ff 0%, #bae7ff 100%) !important;
    border: 1px solid #69c0ff !important;
    border-radius: 999px;
    box-shadow: 0 2px 10px rgba(0, 80, 179, 0.12);
    display: inline-flex;
    align-items: center;
    gap: 7px;
    letter-spacing: 0.02em;
}
.tp-back-btn i {
    font-size: 14px;
}
.tp-back-btn:hover {
    background: linear-gradient(135deg, #bae7ff 0%, #91d5ff 100%) !important;
    border-color: #40a9ff !important;
    color: #003a8c !important;
}
.tp-detail-head-main { flex: 1; min-width: 200px; }
.tp-detail-head-main h1 { font-size: 22px; margin: 0 0 6px; }
.tp-detail-meta { font-size: 13px; color: #8c8c8c; margin: 0 0 10px; }
.tp-detail-code-row { display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px; background: #e6f7ff; border-radius: 8px; }
.tp-detail-code-label { font-size: 12px; color: #595959; }
.tp-detail-code-value { font-size: 18px; font-weight: 700; letter-spacing: 3px; color: #1890ff; font-family: monospace; }
.tp-detail-actions {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    min-width: 0;
}
.tp-detail-actions .ktp-btn {
    width: 100%;
    min-height: 36px;
    height: 36px;
    padding: 0 10px;
    font-size: 13px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    white-space: nowrap;
}
@media (max-width: 640px) {
    .tp-detail-actions { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.tp-detail-tabs { display: flex; gap: 8px; margin-bottom: 16px; flex-wrap: wrap; }
.tp-detail-tab { background: #fff; padding: 10px 18px; border-radius: 8px; cursor: pointer; font-size: 14px; color: #595959; display: inline-flex; align-items: center; gap: 6px; position: relative; }
.tp-detail-tab:hover { color: #1890ff; }
.tp-detail-tab:hover i { color: #1890ff; }
.tp-detail-tab.active { background: #fff; color: #1890ff; font-weight: 600; }
.tp-tab-panel { display: none; background: #fff; border-radius: 12px; border: 1px solid #f0f0f0; padding: 20px; min-height: 200px; }
.tp-tab-panel.active { display: block; }
/* 教师端 · 章节资源：与学生端目录区一致 */
#tpTabUnits.tp-tab-panel {
    background: #fff;
    border: 1px solid #f0f0f0;
    box-shadow: var(--ktp-shadow, 0 4px 24px rgba(15, 23, 42, 0.06));
}
#tpTabUnits .tp-chapter-block {
    background: #fff;
    border: 1px solid #f0f0f0;
    border-radius: 10px;
    box-shadow: none;
}
#tpTabUnits .tp-chapter-head {
    padding: 10px 14px;
    background: #fafafa;
    border-bottom: 1px solid #f0f0f0;
    font-size: 14px;
    color: #262626;
}
#tpTabUnits .cr-section-block {
    background: #fff;
    border-top-color: #f5f5f5;
}
#tpTabUnits .ktp-file-list {
    background: transparent;
    margin: 0;
    border: none;
    border-radius: 0;
}
#tpTabUnits .ktp-file-item {
    background: #fff;
    border-bottom-color: #f0f0f0;
}
#tpTabUnits .ktp-file-item:hover {
    background: #fafafa;
}
.tp-chapter-block { margin-bottom: 16px; border: 1px solid #f0f0f0; border-radius: 10px; overflow: hidden; }
.tp-chapter-head { padding: 10px 14px; background: #fafafa; font-weight: 600; font-size: 14px; display: flex; align-items: center; gap: 8px; border-bottom: 1px solid #f0f0f0; color: #262626; }
.tp-chapter-count { margin-left: auto; font-size: 12px; font-weight: normal; color: #8c8c8c; }
.tp-students-toolbar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; font-size: 14px; }
.tp-students-table-wrap {
    overflow-x: hidden;
    overflow-y: visible;
    margin-bottom: 0;
}
.tp-students-table { font-size: 13px; width: 100%; }
.tp-students-table .portal-student-avatar { width: 24px; height: 24px; font-size: 11px; display: inline-flex; }
.tp-student-row { cursor: pointer; }
.tp-student-row:hover { background: #f6ffed; }
.tp-hw-toolbar { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 16px; padding-bottom: 12px; border-bottom: 1px solid #f0f0f0; }
.tp-hw-toolbar-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.tp-hw-stats { display: flex; gap: 8px; flex-wrap: wrap; }
.tp-hw-filters { display: flex; gap: 6px; }
.tp-hw-filter { border: 1px solid #e8e8e8; background: #fafafa; padding: 4px 12px; border-radius: 6px; font-size: 12px; cursor: pointer; }
.tp-hw-filter.active { background: #1890ff; border-color: #1890ff; color: #fff; }
.tp-hw-task-item .ktp-file-name { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; }
.tp-hw-manage-btns { display: inline-flex; gap: 4px; margin-left: auto; }
.tp-hw-manage-btns .cr-res-edit,
.tp-hw-manage-btns .cr-res-del { border: none; background: transparent; color: #999; cursor: pointer; padding: 2px 6px; border-radius: 4px; font-size: 13px; }
.tp-hw-manage-btns .cr-res-edit:hover { color: #1890ff; background: #e6f7ff; }
.tp-hw-manage-btns .cr-res-del:hover { color: #ff4d4f; background: #fff1f0; }
.tp-grade-feedback { margin-top: 6px; font-size: 12px; color: #595959; background: #fffbe6; padding: 6px 8px; border-radius: 6px; border: 1px solid #ffe58f; }
.grade-meta { background: #fafafa; border-radius: 8px; padding: 12px; margin-bottom: 14px; font-size: 13px; line-height: 1.7; }
.grade-meta-row { color: #595959; }
.grade-meta-row strong { color: #262626; font-size: 15px; }
.hw-grade-list .hw-grade-item { align-items: flex-start; }
.hw-grade-list .ktp-btn { flex-shrink: 0; margin-top: 4px; }

/* 章节资源建设页 */
.tcb-shell { background: transparent; }
.tcb-header .tcb-back-link { color: #1890ff; margin-right: 8px; text-decoration: none; }
.tcb-course-title { font-weight: 600; margin-right: 16px; color: #262626; }
.tcb-main { display: grid; grid-template-columns: 360px 1fr; gap: 16px; max-width: 1280px; margin: 0 auto; padding: 20px 16px 48px; min-height: calc(100vh - 60px); }
@media (max-width: 900px) { .tcb-main { grid-template-columns: 1fr; } }
.tcb-sidebar, .tcb-content { background: #fff; border-radius: 12px; border: 1px solid #f0f0f0; }
.tcb-sidebar { padding: 16px; max-height: calc(100vh - 100px); overflow-y: auto; }
.tcb-sidebar-head h2 { font-size: 16px; margin: 0 0 6px; }
.tcb-hint { font-size: 12px; color: #8c8c8c; margin: 0 0 14px; line-height: 1.5; }
.tcb-ocr-block { background: #f6ffed; border: 1px solid #b7eb8f; border-radius: 10px; padding: 12px; margin-bottom: 14px; }
.tcb-ocr-title { font-size: 13px; font-weight: 600; margin-bottom: 4px; }
.tcb-ocr-desc { font-size: 11px; color: #666; margin: 0 0 8px; }
.tcb-ocr-preview img { max-width: 100%; border-radius: 6px; margin: 8px 0; }
.tcb-ocr-status { font-size: 11px; color: #8c8c8c; margin-top: 6px; line-height: 1.4; }
.tcb-outline-actions { margin-bottom: 10px; }
.tcb-outline-tree { display: flex; flex-direction: column; gap: 10px; }
.tcb-unit-block { border: 1px solid #f0f0f0; border-radius: 8px; overflow: hidden; transition: box-shadow .2s, opacity .2s; }
.tcb-unit-block.tcb-dragging { opacity: .55; box-shadow: 0 4px 12px rgba(24, 144, 255, .2); }
.tcb-unit-block.tcb-drag-over { border-color: #1890ff; box-shadow: 0 0 0 2px rgba(24, 144, 255, .15); }
.tcb-unit-row { display: flex; align-items: center; gap: 6px; padding: 8px; background: #fafafa; }
.tcb-drag-handle {
    display: inline-flex; align-items: center; justify-content: center;
    width: 22px; height: 28px; flex-shrink: 0;
    color: #bfbfbf; cursor: grab; border-radius: 4px;
    touch-action: none; user-select: none;
}
.tcb-drag-handle:hover { color: #1890ff; background: #e6f7ff; }
.tcb-drag-handle:active { cursor: grabbing; }
.tcb-unit-prefix, .tcb-sec-prefix { font-size: 12px; font-weight: 600; color: #1890ff; white-space: nowrap; min-width: 56px; }
.tcb-name-input { flex: 1; font-size: 12px; padding: 4px 8px; min-width: 0; }
.tcb-sec-input { font-size: 12px; }
.tcb-icon-btn { border: none; background: #e6f7ff; color: #1890ff; width: 28px; height: 28px; border-radius: 6px; cursor: pointer; flex-shrink: 0; }
.tcb-icon-btn.danger { background: #fff1f0; color: #ff4d4f; }
.tcb-section-list { padding: 6px 8px 8px; }
.tcb-section-row { display: flex; align-items: center; gap: 6px; padding: 4px 0; border-radius: 6px; }
.tcb-section-row.active { background: #e6f7ff; }
.tcb-section-select { border: none; background: none; cursor: pointer; padding: 0; }
.tcb-sec-count { font-size: 11px; color: #8c8c8c; min-width: 18px; text-align: center; }
.tcb-content { padding: 20px; }
.tcb-empty-panel { text-align: center; padding: 80px 24px; color: #8c8c8c; }
.tcb-empty-panel i { font-size: 40px; margin-bottom: 12px; opacity: .5; }
.tcb-section-head h2 { margin: 0 0 4px; font-size: 20px; }
.tcb-section-path { color: #8c8c8c; font-size: 13px; margin: 0 0 16px; }
.tcb-res-list { margin-bottom: 16px; max-height: 240px; overflow-y: auto; }
.tcb-res-empty { color: #bfbfbf; font-size: 13px; }
.tcb-upload-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.tcb-hw-deadline { margin-top: 12px; padding: 12px 14px; background: #fffbe6; border: 1px solid #ffe58f; border-radius: 8px; }
.tcb-hw-deadline-label { display: block; font-size: 13px; font-weight: 600; color: #ad6800; margin-bottom: 8px; }
.tcb-hw-deadline-hint { font-size: 11px; color: #8c8c8c; margin: 6px 0 0; }
.tcb-upload-footer { margin-top: 16px; }
.cr-section-block { padding: 8px 14px 12px 24px; border-top: 1px solid #f5f5f5; }
.cr-section-title { font-size: 14px; font-weight: 600; color: #434343; margin-bottom: 8px; display: flex; align-items: center; gap: 6px; }
.portal-unit-summary-block { margin-bottom: 8px; }
.portal-section-summary { display: flex; align-items: center; gap: 8px; font-size: 12px; padding: 4px 8px 4px 20px; color: #595959; }
.portal-section-summary span { margin-left: auto; color: #8c8c8c; }

/* ===== 课程学习 · 七 Tab 子模块 ===== */
.cl-learning-wrap { min-height: 420px; }
.cl-tabs {
    display: flex; flex-wrap: wrap; gap: 4px;
    border-bottom: 1px solid #f0f0f0; margin: -4px -4px 16px; padding: 0 4px 8px;
    overflow-x: auto;
}
.cl-tab-btn {
    padding: 8px 14px; border: none; background: none;
    color: #8c8c8c; font-size: 13px; cursor: pointer; border-radius: 6px 6px 0 0;
    white-space: nowrap; transition: color .2s;
}
.cl-tab-btn:hover { color: #1890ff; }
.cl-tab-btn.active { color: #1890ff; font-weight: 600; }
.cl-tab-content { min-height: 360px; }
.cl-spin { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; padding: 48px; color: #8c8c8c; }
.cl-empty { text-align: center; padding: 48px 20px; color: #bfbfbf; }
.cl-empty-icon { font-size: 40px; margin-bottom: 10px; opacity: .6; }
.cl-pager { display: flex; align-items: center; justify-content: center; gap: 12px; margin-top: 16px; font-size: 13px; color: #8c8c8c; }

/* 目录 */
.cl-catalog-layout { display: flex; gap: 16px; min-height: 400px; flex-wrap: wrap; }
.cl-catalog-tree-wrap, .cl-catalog-detail-wrap {
    flex: 1; min-width: 260px; border: 1px solid #f0f0f0; border-radius: 10px; overflow: hidden;
}
.cl-panel-head { padding: 10px 14px; background: #fafafa; font-weight: 600; font-size: 14px; border-bottom: 1px solid #f0f0f0; }
.cl-tree-unit { border-bottom: 1px solid #f5f5f5; }
.cl-tree-unit-head {
    display: flex; align-items: center; gap: 8px; width: 100%; padding: 10px 12px;
    border: none; background: none; cursor: pointer; font-size: 13px; font-weight: 600; text-align: left;
}
.cl-tree-chevron { font-size: 10px; color: #8c8c8c; transition: transform .2s; }
.cl-tree-unit.expanded .cl-tree-chevron { transform: rotate(90deg); }
.cl-tree-sections { display: none; padding: 0 8px 8px 28px; }
.cl-tree-unit.expanded .cl-tree-sections { display: block; }
.cl-tree-section {
    display: flex; align-items: center; justify-content: space-between; width: 100%;
    padding: 8px 10px; margin-top: 4px; border: none; background: none; border-radius: 6px;
    cursor: pointer; font-size: 12px; color: #595959; text-align: left;
}
.cl-tree-section:hover { background: #f5f9ff; color: #1890ff; }
.cl-tree-section.active { background: #e6f7ff; color: #1890ff; font-weight: 500; }
.cl-tree-dur { font-size: 11px; color: #bfbfbf; margin-left: 8px; }
.cl-tree-section-wrap { margin-top: 4px; }
.cl-tree-section-wrap.active > .cl-tree-section { background: #e6f7ff; color: #1890ff; font-weight: 500; }
.cl-tree-files { padding: 2px 0 6px 14px; }
.cl-tree-file {
    display: flex; align-items: center; gap: 6px; width: 100%; padding: 5px 8px; margin-top: 2px;
    border: none; background: none; border-radius: 4px; cursor: pointer; font-size: 11px; color: #595959; text-align: left;
}
.cl-tree-file:hover { background: #f0f7ff; color: #1890ff; }
.cl-tree-file i { color: #1890ff; width: 14px; text-align: center; flex-shrink: 0; }
.cl-tree-file span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cl-catalog-files { list-style: none; margin: 0 0 16px; padding: 0; }
.cl-catalog-file-btn {
    display: inline-flex; align-items: center; gap: 8px; padding: 8px 12px; margin-bottom: 8px;
    border: 1px solid #e8e8e8; border-radius: 8px; background: #fafafa; cursor: pointer; font-size: 13px; color: #262626;
}
.cl-catalog-file-btn:hover { border-color: #91d5ff; background: #e6f7ff; color: #1890ff; }
.cl-catalog-file-btn i { color: #1890ff; }
.cl-tree-section-wrap { margin-top: 4px; }
.cl-tree-section-wrap.active > .cl-tree-section { background: #e6f7ff; color: #1890ff; font-weight: 500; }
.cl-tree-files { padding: 2px 0 6px 14px; }
.cl-tree-file {
    display: flex; align-items: center; gap: 6px; width: 100%; padding: 5px 8px; margin-top: 2px;
    border: none; background: none; border-radius: 4px; cursor: pointer; font-size: 11px; color: #595959; text-align: left;
}
.cl-tree-file:hover { background: #f0f7ff; color: #1890ff; }
.cl-tree-file i { color: #1890ff; width: 14px; text-align: center; flex-shrink: 0; }
.cl-tree-file span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cl-catalog-files { list-style: none; margin: 0 0 16px; padding: 0; }
.cl-catalog-file-btn {
    display: inline-flex; align-items: center; gap: 8px; padding: 8px 12px; margin-bottom: 8px;
    border: 1px solid #e8e8e8; border-radius: 8px; background: #fafafa; cursor: pointer; font-size: 13px; color: #262626;
}
.cl-catalog-file-btn:hover { border-color: #91d5ff; background: #e6f7ff; color: #1890ff; }
.cl-catalog-file-btn i { color: #1890ff; }
.cl-tree-section-wrap { margin-top: 4px; }
.cl-tree-section-wrap.active > .cl-tree-section { background: #e6f7ff; color: #1890ff; font-weight: 500; }
.cl-tree-files { padding: 2px 0 6px 14px; }
.cl-tree-file {
    display: flex; align-items: center; gap: 6px; width: 100%; padding: 5px 8px; margin-top: 2px;
    border: none; background: none; border-radius: 4px; cursor: pointer; font-size: 11px; color: #595959; text-align: left;
}
.cl-tree-file:hover { background: #f0f7ff; color: #1890ff; }
.cl-tree-file i { color: #1890ff; width: 14px; text-align: center; flex-shrink: 0; }
.cl-tree-file span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cl-catalog-files { list-style: none; margin: 0 0 16px; padding: 0; }
.cl-catalog-file-btn {
    display: inline-flex; align-items: center; gap: 8px; padding: 8px 12px; margin-bottom: 8px;
    border: 1px solid #e8e8e8; border-radius: 8px; background: #fafafa; cursor: pointer; font-size: 13px; color: #262626;
}
.cl-catalog-file-btn:hover { border-color: #91d5ff; background: #e6f7ff; color: #1890ff; }
.cl-catalog-file-btn i { color: #1890ff; }
.cl-tree-section-wrap { margin-top: 4px; }
.cl-tree-section-wrap.active > .cl-tree-section { background: #e6f7ff; color: #1890ff; font-weight: 500; }
.cl-tree-files { padding: 2px 0 6px 14px; }
.cl-tree-file {
    display: flex; align-items: center; gap: 6px; width: 100%; padding: 5px 8px; margin-top: 2px;
    border: none; background: none; border-radius: 4px; cursor: pointer; font-size: 11px; color: #595959; text-align: left;
}
.cl-tree-file:hover { background: #f0f7ff; color: #1890ff; }
.cl-tree-file i { color: #1890ff; width: 14px; text-align: center; flex-shrink: 0; }
.cl-tree-file span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cl-catalog-files { list-style: none; margin: 0 0 16px; padding: 0; }
.cl-catalog-file-btn {
    display: inline-flex; align-items: center; gap: 8px; padding: 8px 12px; margin-bottom: 8px;
    border: 1px solid #e8e8e8; border-radius: 8px; background: #fafafa; cursor: pointer; font-size: 13px; color: #262626;
}
.cl-catalog-file-btn:hover { border-color: #91d5ff; background: #e6f7ff; color: #1890ff; }
.cl-catalog-file-btn i { color: #1890ff; }
.cl-tree-section-wrap { margin-top: 4px; }
.cl-tree-section-wrap.active > .cl-tree-section { background: #e6f7ff; color: #1890ff; font-weight: 500; }
.cl-tree-files { padding: 2px 0 6px 14px; }
.cl-tree-file {
    display: flex; align-items: center; gap: 6px; width: 100%; padding: 5px 8px; margin-top: 2px;
    border: none; background: none; border-radius: 4px; cursor: pointer; font-size: 11px; color: #595959; text-align: left;
}
.cl-tree-file:hover { background: #f0f7ff; color: #1890ff; }
.cl-tree-file i { color: #1890ff; width: 14px; text-align: center; flex-shrink: 0; }
.cl-tree-file span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cl-catalog-files { list-style: none; margin: 0 0 16px; padding: 0; }
.cl-catalog-file-btn {
    display: inline-flex; align-items: center; gap: 8px; padding: 8px 12px; margin-bottom: 8px;
    border: 1px solid #e8e8e8; border-radius: 8px; background: #fafafa; cursor: pointer; font-size: 13px; color: #262626;
}
.cl-catalog-file-btn:hover { border-color: #91d5ff; background: #e6f7ff; color: #1890ff; }
.cl-catalog-file-btn i { color: #1890ff; }
.cl-detail-title { font-size: 18px; margin: 0 0 6px; padding: 14px 16px 0; }
.cl-detail-meta { font-size: 12px; color: #8c8c8c; padding: 0 16px 12px; }
.cl-detail-sub { font-size: 14px; margin: 0; padding: 0 16px 8px; color: #434343; }
.cl-objectives { margin: 0 0 12px; padding: 0 16px 0 32px; color: #595959; font-size: 13px; line-height: 1.6; }
.cl-rich-content { padding: 0 16px 20px; font-size: 14px; line-height: 1.7; color: #434343; }
.cl-rich-content img { max-width: 100%; border-radius: 8px; }
#clCatalogDetail { padding-bottom: 8px; min-height: 200px; }

/* 课件卡片 */
.cl-card-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.cl-courseware-card {
    display: flex; align-items: center; gap: 12px; padding: 14px;
    border: 1px solid #f0f0f0; border-radius: 10px; cursor: pointer; transition: box-shadow .2s, border-color .2s;
}
.cl-courseware-card:hover { border-color: #91d5ff; box-shadow: 0 4px 12px rgba(24,144,255,.12); }
.cl-cw-icon { width: 44px; height: 44px; border-radius: 10px; background: #e6f7ff; color: #1890ff; display: flex; align-items: center; justify-content: center; font-size: 20px; flex-shrink: 0; }
.cl-cw-icon-video { background: #fff7e6; color: #fa8c16; }
.cl-cw-icon-ppt { background: #fff1f0; color: #f5222d; }
.cl-cw-icon-pdf { background: #fff1f0; color: #cf1322; }
.cl-cw-badge-video { background: #fff7e6; color: #fa8c16; }
.cl-cw-badge-ppt { background: #fff1f0; color: #f5222d; }
.cl-cw-badge-pdf { background: #fff1f0; color: #cf1322; }
.cl-mat-icon-video { background: #fff7e6; color: #fa8c16; }
.cl-cw-body { flex: 1; min-width: 0; }
.cl-cw-title { font-size: 14px; font-weight: 600; margin-bottom: 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cl-cw-meta { font-size: 12px; color: #8c8c8c; }
.cl-cw-pages { font-size: 11px; color: #1890ff; background: #e6f7ff; padding: 2px 8px; border-radius: 10px; }

/* 表格 / 列表 */
.cl-table-wrap { overflow-x: auto; }
.cl-table { width: 100%; }
.cl-filter-bar { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; align-items: center; justify-content: space-between; }
.cl-filter-group { display: flex; flex-wrap: wrap; gap: 8px; }
.cl-filter-actions { margin-left: auto; }
.cl-mat-upload-hint { margin: 8px 0 0; font-size: 12px; color: #8c8c8c; line-height: 1.5; }
.cl-mat-upload-form .ktp-form-group { margin-bottom: 14px; }
.cl-mat-empty-actions { text-align: center; margin-top: 8px; }
.cl-mat-upload-btn { white-space: nowrap; }
.cl-mat-empty-actions { text-align: center; margin-top: 8px; }
.cl-mat-upload-btn { white-space: nowrap; }
.cl-mat-empty-actions { text-align: center; margin-top: 8px; }
.cl-mat-upload-btn { white-space: nowrap; }
.cl-mat-empty-actions { text-align: center; margin-top: 8px; }
.cl-mat-upload-btn { white-space: nowrap; }
.cl-mat-empty-actions { text-align: center; margin-top: 8px; }
.cl-mat-upload-btn { white-space: nowrap; }
.cl-filter-btn {
    padding: 4px 12px; border: 1px solid #e8e8e8; background: #fff; border-radius: 16px;
    font-size: 12px; cursor: pointer; color: #595959;
}
.cl-filter-btn.active { border-color: #1890ff; color: #1890ff; background: #e6f7ff; }
.cl-scroll-list { max-height: 420px; overflow-y: auto; }
.cl-mat-row { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid #f5f5f5; overflow: hidden; }
.cl-mat-row > .ktp-btn { flex-shrink: 0; align-self: center; white-space: nowrap; }
.ktp-page-header > .ktp-btn { flex-shrink: 0; align-self: center; white-space: nowrap; }
.cl-mat-row .cw-viewer,
.cl-mat-row .rv-viewer-root,
.cl-mat-row .cw-pptx-dom { display: none !important; }
.cl-mat-icon { width: 36px; height: 36px; background: #f5f5f5; border-radius: 8px; display: flex; align-items: center; justify-content: center; color: #1890ff; }
.cl-mat-info { flex: 1; min-width: 0; }
.cl-mat-name { font-size: 14px; font-weight: 500; }
.cl-mat-meta { font-size: 12px; color: #8c8c8c; margin-top: 2px; }

/* 公告 */
.cl-announce-item {
    display: block; width: 100%; text-align: left; padding: 12px 14px 12px 28px;
    border: none; background: none; border-bottom: 1px solid #f5f5f5; cursor: pointer; position: relative;
}
.cl-announce-item:hover { background: #fafafa; }
.cl-announce-item.unread { background: #f6ffed; }
.cl-unread-dot { position: absolute; left: 12px; top: 18px; width: 8px; height: 8px; background: #ff4d4f; border-radius: 50%; }
.cl-announce-title { font-size: 14px; font-weight: 500; color: #262626; }
.cl-announce-meta { font-size: 12px; color: #8c8c8c; margin-top: 4px; }

/* 协作白板 */
.cl-learning-wrap #crWbMount.cl-wb-embed-mount { display: none; min-height: 0; flex: 1; }
.cl-learning-wrap #crWbMount.cr-wb-active {
    display: flex !important;
    flex-direction: column;
    flex: 1;
    min-height: 520px;
    height: calc(100vh - 220px);
    max-height: none;
}
.cl-learning-wrap #clTabContent.cl-wb-hidden { display: none !important; }
.cl-learning-wrap .cr-embedded-mount .edu-wb-page { min-height: 520px; }
.cr-embedded-module.edu-wb-embed-active .edu-wb-shell {
    min-height: calc(100vh - 200px);
    height: 100%;
}
.cr-embedded-module.edu-wb-embed-active .edu-wb-center { min-height: 0; }
.cl-wb-join-banner {
    margin-bottom: 12px; padding: 10px 14px; border-radius: 8px;
    background: #f6ffed; border: 1px solid #b7eb8f; color: #389e0d; font-size: 13px;
}
.cl-wb-join-banner i { margin-right: 6px; }
.cl-wb-wrap { border: 1px solid #f0f0f0; border-radius: 10px; overflow: hidden; }
.cl-wb-embed-wrap {
    min-height: 480px;
    height: 100%;
    flex: 1;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid #e5e5e5;
    background: #ededed;
    position: relative;
}
.cl-learning-wrap .cl-wb-embed-wrap {
    height: calc(100vh - 260px);
    min-height: 520px;
    max-height: none;
}
.cl-wb-embed-loading { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; gap: 8px; color: #888; font-size: 14px; }
.cl-wb-offline { padding: 48px 24px; text-align: center; color: #666; background: #fafafa; border-radius: 12px; border: 1px dashed #d9d9d9; }
.cl-wb-offline-hint { font-size: 12px; color: #999; margin-top: 8px; }
.cl-wb-offline-cmd { font-size: 12px; margin: 12px 0; line-height: 1.8; }
.cl-wb-offline code { background: #f5f5f5; padding: 2px 6px; border-radius: 4px; }
.tp-wb-canvas-wrap.zj-wb-fallback-mode .tp-wb-iframe-host {
    position: relative;
    min-height: auto;
    height: auto;
    z-index: 3;
    margin-bottom: 8px;
}
.tp-wb-canvas-wrap.zj-wb-fallback-mode .cl-wb-offline {
    padding: 16px 14px;
    margin-bottom: 8px;
    text-align: left;
    background: #fffbe6;
    border: 1px solid #ffe58f;
    border-radius: 8px;
}
.tp-wb-canvas-wrap.zj-wb-fallback-mode #whiteboardCanvas { display: block !important; min-height: 420px; }
#tpWbPaneCanvas.zj-wb-offline-only .tp-wb-toolbar,
#tpWbPaneCanvas.zj-wb-offline-only .tp-wb-group-bar,
#tpWbPaneCanvas.zj-wb-offline-only .tp-wb-side {
    display: none !important;
}
#tpWbPaneCanvas.zj-wb-offline-only .tp-wb-layout {
    display: block;
}
#tpWbPaneCanvas.zj-wb-offline-only .tp-wb-canvas-wrap {
    min-height: min(520px, calc(100vh - 220px));
    height: min(68vh, calc(100vh - 220px));
    max-height: none;
    background: #fafafa;
}
#tpWbPaneCanvas.zj-wb-offline-only #tpWbEmbedHost {
    position: relative;
    inset: auto;
    min-height: min(480px, calc(100vh - 240px));
    height: 100%;
    z-index: 2;
}
#tpWbPaneCanvas.zj-wb-offline-only .cl-wb-offline {
    min-height: 320px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 32px 24px;
    text-align: center;
}
.tp-wb-status-retry {
    margin-left: 6px;
    border: none;
    background: transparent;
    color: #1890ff;
    cursor: pointer;
    font-size: 12px;
    text-decoration: underline;
    padding: 0;
}
.tp-wb-status-retry:hover { color: #096dd9; }
.tp-wb-group-bar {
    display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
    padding: 8px 12px; background: #f0f9ff; border-bottom: 1px solid #e6f4ff;
}
.tp-wb-group-label { font-size: 13px; color: #434343; font-weight: 600; white-space: nowrap; }
.tp-wb-group-tabs { margin-bottom: 0 !important; }
/* 教师 embed：入口为全屏多边形总览，进入白板后才显示侧边栏 */
#tpWbPaneCanvas.zj-wb-teacher-overview .tp-wb-group-bar,
#tpWbPaneCanvas.zj-wb-teacher-overview .tp-wb-toolbar,
#tpWbPaneCanvas.zj-wb-teacher-overview .tp-wb-side {
    display: none !important;
}
#tpWbPaneCanvas.zj-wb-teacher-overview .tp-wb-layout {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
}
#tpWbPaneCanvas.zj-wb-teacher-overview .tp-wb-canvas-wrap {
    width: 100% !important;
    flex: 1 1 auto;
    min-height: min(520px, calc(100vh - 240px));
    height: min(72vh, calc(100vh - 220px)) !important;
    max-height: none !important;
}
#tpWbPaneCanvas.tp-wb-embed-live.zj-wb-teacher-overview {
    min-height: calc(100vh - 168px);
}
#tpWbPaneCanvas.tp-wb-embed-live.zj-wb-teacher-overview #tpWbEmbedHost,
#tpWbPaneCanvas.tp-wb-embed-live.zj-wb-teacher-overview .tp-wb-iframe-host,
#tpWbPaneCanvas.tp-wb-embed-live.zj-wb-teacher-overview .zj-wb-platform-iframe-host {
    min-height: min(520px, calc(100vh - 240px)) !important;
    height: 100% !important;
    max-height: none !important;
}
#tpWbPaneCanvas.zj-wb-teacher-board .tp-wb-group-bar {
    display: flex !important;
}
#tpWbPaneCanvas.zj-wb-teacher-board .tp-wb-side {
    display: block !important;
}
/* 嵌入模式：隐藏 PHP 侧画笔工具（iframe 内自带），保留传文档/邀请/结束等 */
.tp-wb-toolbar-embed .tp-wb-tool,
.tp-wb-toolbar-embed #tpWbColor,
.tp-wb-toolbar-embed #tpWbSize {
    display: none !important;
}
.tp-wb-toolbar-embed button[onclick*="TeacherCourseWb.undo"],
.tp-wb-toolbar-embed button[onclick*="TeacherCourseWb.clearBoard"] {
    display: none !important;
}
#tpWbPaneCanvas.zj-wb-fallback-active .tp-wb-toolbar,
#tpWbPaneCanvas.zj-wb-fallback-active .tp-wb-group-bar {
    display: flex !important;
}
.cr-res-actions {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
    margin-left: auto;
}
.cr-res-actions .cr-res-open {
    position: static;
    transform: none;
    width: 32px;
    height: 32px;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #91d5ff;
}
.cr-res-open.cr-res-wb {
    color: #fff;
    border-color: #1890ff;
    background: #1890ff;
}
.cr-res-open.cr-res-wb:hover {
    color: #fff;
    border-color: #096dd9;
    background: #096dd9;
}
/* 教师 embed 已连接：保留原有侧栏与分组栏，画布区嵌入 iframe */
#tpWbPaneCanvas.tp-wb-embed-live {
    display: flex;
    flex-direction: column;
    min-height: calc(100vh - 168px);
}
#tpWbPaneCanvas.tp-wb-embed-live .tp-wb-layout {
    flex: 1;
    display: grid;
    grid-template-columns: 1fr 220px;
    gap: 14px;
    min-height: 0;
}
#tpWbPaneCanvas.tp-wb-embed-live .tp-wb-side {
    display: block !important;
    max-height: none;
}
#tpWbPaneCanvas.tp-wb-embed-live .tp-wb-canvas-wrap {
    position: relative;
    display: block;
    min-height: 440px;
    height: min(560px, calc(100vh - 260px));
    max-height: 560px;
    width: 100%;
    border-radius: 10px;
    overflow: hidden;
    background: #ededed;
}
/* 嵌入 iframe 时仅隐藏旧 canvas；有资料时叠在白板底层（wb-embed-doc-overlay） */
#tpWbPaneCanvas.tp-wb-embed-live .tp-wb-canvas-wrap > #whiteboardCanvas {
    display: none !important;
}
#tpWbPaneCanvas.tp-wb-embed-live .tp-wb-canvas-wrap:not(.wb-embed-doc-overlay) > #wbDocBg,
#tpWbPaneCanvas.tp-wb-embed-live .tp-wb-canvas-wrap:not(.wb-embed-doc-overlay) > #wbDocFrame,
#tpWbPaneCanvas.tp-wb-embed-live .tp-wb-canvas-wrap:not(.wb-embed-doc-overlay) > #wbDocText,
#tpWbPaneCanvas.tp-wb-embed-live .tp-wb-canvas-wrap:not(.wb-embed-doc-overlay) > #wbDocHtml,
#tpWbPaneCanvas.tp-wb-embed-live .tp-wb-canvas-wrap:not(.wb-embed-doc-overlay) > #wbDocPlaceholder,
#tpWbPaneCanvas.tp-wb-embed-live .tp-wb-canvas-wrap:not(.wb-embed-doc-overlay) > #wbAnnotateBar {
    display: none !important;
}
/* 资料垫底、协作画布透明叠在上面勾画 */
.wb-embed-doc-overlay {
    position: relative;
    overflow: hidden;
    background: #ededed;
    --wb-annotate-bar-h: 42px;
    --wb-embed-chrome-h: 108px;
    --wb-doc-reserve-top: calc(var(--wb-annotate-bar-h) + var(--wb-embed-chrome-h));
}
.wb-embed-doc-overlay #wbDocBg,
.wb-embed-doc-overlay #wbDocFrame,
.wb-embed-doc-overlay #wbDocText,
.wb-embed-doc-overlay #wbDocHtml,
.wb-embed-doc-overlay #wbDocPlaceholder {
    position: absolute !important;
    top: var(--wb-doc-reserve-top) !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100% !important;
    z-index: 1 !important;
    pointer-events: none;
}
.wb-embed-doc-overlay.wb-doc-scroll-mode #wbDocBg,
.wb-embed-doc-overlay.wb-doc-scroll-mode #wbDocFrame,
.wb-embed-doc-overlay.wb-doc-scroll-mode #wbDocText,
.wb-embed-doc-overlay.wb-doc-scroll-mode #wbDocHtml,
.wb-embed-doc-overlay.wb-doc-scroll-mode #wbDocPlaceholder {
    z-index: 5 !important;
    pointer-events: auto !important;
}
.wb-embed-doc-overlay #wbDocHtml {
    pointer-events: auto;
    background: #fff;
}
.wb-embed-doc-overlay.wb-doc-scroll-mode #wbDocHtml,
.wb-embed-doc-overlay.wb-doc-scroll-mode .wb-pptx-stage,
.wb-embed-doc-overlay.wb-doc-scroll-mode #wbDocText,
.wb-embed-doc-overlay.wb-doc-scroll-mode #wbDocFrame,
.wb-embed-doc-overlay.wb-doc-scroll-mode #wbDocBg {
    pointer-events: auto !important;
}
.wb-embed-doc-overlay.wb-doc-has-pptx #wbDocHtml.wb-pptx-host {
    display: flex !important;
    flex-direction: column;
    overflow: hidden !important;
    top: var(--wb-annotate-bar-h) !important;
    z-index: 5 !important;
    pointer-events: auto !important;
}
.wb-embed-doc-overlay.wb-doc-has-pptx.wb-doc-scroll-mode #wbDocHtml.wb-pptx-host,
.wb-embed-doc-overlay.wb-doc-has-pptx.wb-doc-scroll-mode .wb-pptx-stage {
    overflow: hidden !important;
}
.wb-embed-doc-overlay.wb-doc-has-pptx .wb-pptx-toolbar {
    flex-shrink: 0;
    margin-top: 0;
    pointer-events: auto;
    position: relative;
    z-index: 1;
}
.wb-embed-doc-overlay.wb-doc-has-pptx .wb-pptx-stage {
    flex: 1;
    min-height: 0;
    overflow: hidden;
    pointer-events: auto;
    display: flex;
    flex-direction: column;
    padding: 8px;
}
.wb-pptx-host.wb-pptx-single-view .wb-pptx-all-slides {
    flex: 1;
    min-height: 0;
    width: 100%;
    max-width: none;
    margin: 0;
    padding: 0;
    display: block;
    height: 100%;
    overflow: hidden;
}
.wb-pptx-host.wb-pptx-single-view .wb-pptx-stage {
    overflow: hidden !important;
    padding: 4px;
}
.wb-pptx-host.wb-pptx-single-view .wb-pptx-slide-block {
    display: none;
    height: 100%;
    min-height: 0;
    box-shadow: none;
    border-radius: 4px;
}
.wb-pptx-host.wb-pptx-single-view .wb-pptx-slide-block.wb-pptx-slide-active {
    display: flex;
    flex-direction: column;
    height: 100%;
}
.wb-pptx-host.wb-pptx-single-view .wb-pptx-slide-label {
    display: none;
}
.wb-pptx-host.wb-pptx-single-view .wb-pptx-slide-body {
    flex: 1;
    min-height: 0;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding: 0 4px 4px;
    overflow: hidden;
}
.wb-pptx-host.wb-pptx-single-view .wb-pptx-dom-slide {
    max-width: 100%;
    max-height: 100%;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    overflow: hidden;
    flex-shrink: 0;
    margin: 0 auto;
    align-self: flex-start;
}
.wb-pptx-host.wb-pptx-single-view .wb-pptx-slide-body img,
.wb-pptx-host.wb-pptx-single-view .wb-pptx-slide-img,
.wb-pptx-host.wb-pptx-single-view .wb-pptx-slide-body canvas,
.wb-pptx-host.wb-pptx-single-view .wb-pptx-slide-body .cw-lite-slide {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    margin: 0 auto;
    display: block;
    align-self: flex-start;
}
.wb-pptx-toolbar [data-wb-pptx-fs],
.wb-pptx-toolbar .wb-pptx-fs-btn {
    margin-left: auto;
}
.wb-embed-doc-overlay.wb-doc-has-html #wbDocHtml,
.wb-embed-doc-overlay.wb-doc-has-html #wbDocText {
    overflow-y: auto;
    overflow-x: hidden;
    pointer-events: auto;
    -webkit-overflow-scrolling: touch;
}
.wb-embed-doc-overlay .wb-doc-html-body {
    padding: 12px 18px 24px;
    box-sizing: border-box;
    min-height: 100%;
    line-height: 1.65;
    color: #222;
}
.wb-embed-doc-overlay.wb-doc-has-pdf #wbDocFrame {
    pointer-events: auto;
}
.wb-embed-doc-overlay.wb-doc-pen-mode #wbDocBg,
.wb-embed-doc-overlay.wb-doc-pen-mode #wbDocFrame,
.wb-embed-doc-overlay.wb-doc-pen-mode #wbDocText,
.wb-embed-doc-overlay.wb-doc-pen-mode #wbDocHtml {
    z-index: 1 !important;
    pointer-events: none !important;
}
.wb-embed-doc-overlay #wbDocText {
    padding: 12px 18px 24px;
    box-sizing: border-box;
    overflow-y: auto;
    line-height: 1.65;
    white-space: pre-wrap;
    color: #222;
    background: #fff;
}
.wb-pptx-host {
    display: flex;
    flex-direction: column;
    min-height: 100%;
    background: #f0f2f5;
    padding: 0;
}
.wb-pptx-toolbar {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
    padding: 6px 10px;
    background: #fafafa;
    border-bottom: 1px solid #e8e8e8;
    font-size: 12px;
    color: #595959;
}
.wb-pptx-hint {
    display: none;
}
.wb-pptx-stage {
    flex: 1;
    min-height: 0;
    overflow: auto;
    padding: 12px;
    -webkit-overflow-scrolling: touch;
}
.wb-pptx-stage .cw-lite-slide {
    max-width: 960px;
    margin: 0 auto;
    box-shadow: 0 4px 20px rgba(0,0,0,.12);
    border-radius: 4px;
    overflow: hidden;
}
.wb-pptx-all-slides {
    display: flex;
    flex-direction: column;
    gap: 20px;
    max-width: 960px;
    margin: 0 auto;
    padding-bottom: 24px;
}
.wb-pptx-slide-block {
    background: #fff;
    border-radius: 6px;
    box-shadow: 0 4px 20px rgba(0,0,0,.12);
    overflow: hidden;
}
.wb-pptx-slide-label {
    padding: 6px 12px;
    font-size: 12px;
    color: #8c8c8c;
    background: #fafafa;
    border-bottom: 1px solid #eee;
}
.wb-pptx-slide-body {
    padding: 8px;
}
.wb-pptx-slide-canvas {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 2px;
}
.wb-pptx-slide-img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 2px;
    background: #fff;
}
.wb-pptx-dom-slide {
    margin: 0 auto;
}
.wb-pptx-dom-slide > div {
    margin: 0 auto;
}
.wb-pptx-slide-block .cw-lite-slide {
    box-shadow: none;
    border-radius: 0;
}

/* PPT 演示模式：CSS 占满屏幕（智慧黑板 / 浏览器全屏 API 不稳定时仍可用） */
body.wb-pptx-presentation-active {
    overflow: hidden !important;
}
body.wb-pptx-presentation-active #wbAnnotateBar {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    z-index: 2147483647 !important;
    margin: 0 !important;
    border-radius: 0 !important;
}
body.wb-pptx-presentation-active #wbDocHtml.wb-pptx-host {
    position: fixed !important;
    top: var(--wb-ppt-present-top, 42px) !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100vw !important;
    height: calc(100vh - var(--wb-ppt-present-top, 42px)) !important;
    max-height: none !important;
    min-height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    z-index: 2147483646 !important;
    background: #111 !important;
    display: flex !important;
    flex-direction: column !important;
    overflow: hidden !important;
    box-sizing: border-box !important;
}
body.wb-pptx-presentation-active #tpWbEmbedHost,
body.wb-pptx-presentation-active iframe.zj-wb-embed,
body.wb-pptx-presentation-active #whiteboardCanvas {
    visibility: hidden !important;
    pointer-events: none !important;
}
body.wb-pptx-presentation-active .wb-pptx-toolbar {
    flex-shrink: 0;
    background: rgba(0, 0, 0, 0.72);
    color: #fff;
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}
body.wb-pptx-presentation-active .wb-pptx-stage {
    flex: 1 1 auto !important;
    min-height: 0 !important;
    overflow: hidden !important;
    padding: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    background: #111 !important;
}
body.wb-pptx-presentation-active .wb-pptx-stage .cw-lite-slide {
    max-width: none !important;
}
body.wb-pptx-presentation-active .wb-pptx-all-slides {
    flex: 1 1 auto !important;
    min-height: 0 !important;
    height: 100% !important;
    max-width: none !important;
    margin: 0 !important;
    padding: 0 !important;
}
body.wb-pptx-presentation-active .wb-pptx-slide-block.wb-pptx-slide-active {
    flex: 1 1 auto !important;
    min-height: 0 !important;
    height: 100% !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    background: transparent !important;
}
body.wb-pptx-presentation-active .wb-pptx-slide-body {
    flex: 1 1 auto !important;
    min-height: 0 !important;
    height: 100% !important;
    padding: 0 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    background: #111 !important;
}

/* PPT 演示：浏览器 Fullscreen API 备用 */
#wbDocHtml.wb-pptx-host:fullscreen,
#wbDocHtml.wb-pptx-host:-webkit-full-screen,
#wbDocHtml.wb-pptx-host.wb-pptx-presenting {
    position: fixed !important;
    inset: 0 !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    max-height: none !important;
    min-height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    z-index: 2147483000 !important;
    background: #111 !important;
    display: flex !important;
    flex-direction: column !important;
    overflow: hidden !important;
    box-sizing: border-box !important;
}
#wbDocHtml.wb-pptx-host:fullscreen .wb-pptx-toolbar,
#wbDocHtml.wb-pptx-host:-webkit-full-screen .wb-pptx-toolbar {
    flex-shrink: 0;
    background: rgba(0, 0, 0, 0.65);
    color: #fff;
    border-bottom: 1px solid rgba(255, 255, 255, 0.15);
}
#wbDocHtml.wb-pptx-host:fullscreen .wb-pptx-stage,
#wbDocHtml.wb-pptx-host:-webkit-full-screen .wb-pptx-stage {
    flex: 1 1 auto !important;
    min-height: 0 !important;
    height: auto !important;
    overflow: hidden !important;
    padding: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    background: #111 !important;
}
#wbDocHtml.wb-pptx-host:fullscreen .wb-pptx-all-slides,
#wbDocHtml.wb-pptx-host:-webkit-full-screen .wb-pptx-all-slides {
    flex: 1 1 auto !important;
    min-height: 0 !important;
    height: 100% !important;
    max-width: none !important;
    margin: 0 !important;
    padding: 0 !important;
}
#wbDocHtml.wb-pptx-host:fullscreen .wb-pptx-slide-block.wb-pptx-slide-active,
#wbDocHtml.wb-pptx-host:-webkit-full-screen .wb-pptx-slide-block.wb-pptx-slide-active {
    flex: 1 1 auto !important;
    min-height: 0 !important;
    height: 100% !important;
    border-radius: 0 !important;
    box-shadow: none !important;
}
#wbDocHtml.wb-pptx-host:fullscreen .wb-pptx-slide-body,
#wbDocHtml.wb-pptx-host:-webkit-full-screen .wb-pptx-slide-body {
    flex: 1 1 auto !important;
    min-height: 0 !important;
    height: 100% !important;
    padding: 0 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    background: #111 !important;
}
#wbDocHtml.wb-pptx-host:fullscreen .wb-pptx-slide-body .cw-lite-slide,
#wbDocHtml.wb-pptx-host:-webkit-full-screen .wb-pptx-slide-body .cw-lite-slide,
#wbDocHtml.wb-pptx-host:fullscreen .wb-pptx-slide-body img,
#wbDocHtml.wb-pptx-host:-webkit-full-screen .wb-pptx-slide-body img,
#wbDocHtml.wb-pptx-host:fullscreen .wb-pptx-dom-slide,
#wbDocHtml.wb-pptx-host:-webkit-full-screen .wb-pptx-dom-slide {
    max-width: 100% !important;
    max-height: 100% !important;
    margin: 0 auto !important;
}

.wb-embed-doc-overlay #tpWbEmbedHost,
.wb-embed-doc-overlay .cl-wb-embed-wrap,
.wb-embed-doc-overlay .zj-wb-platform-host,
.wb-embed-doc-overlay .edu-wb-iframe-host,
.wb-embed-doc-overlay .zj-wb-student-dual,
.wb-embed-doc-overlay .zj-wb-teacher-dual {
    position: absolute !important;
    top: var(--wb-annotate-bar-h, 42px) !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100% !important;
    height: calc(100% - var(--wb-annotate-bar-h, 42px)) !important;
    min-height: 0 !important;
    max-height: none !important;
    z-index: 2 !important;
    background: transparent !important;
}
.wb-embed-doc-overlay iframe.zj-wb-embed {
    background: transparent !important;
}
.wb-embed-doc-overlay #wbAnnotateBar,
.wb-embed-doc-overlay .ktp-wb-annotate-bar {
    position: absolute !important;
    top: 0 !important;
    left: 0;
    right: 0;
    bottom: auto !important;
    z-index: 100 !important;
    pointer-events: auto !important;
    flex-wrap: nowrap;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.14);
}
.wb-embed-doc-overlay .ktp-wb-annotate-actions {
    position: relative;
    z-index: 101;
    pointer-events: auto;
    flex-shrink: 0;
}
.wb-doc-media-host {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100%;
    background: #111;
    overflow: auto;
}
.wb-doc-video-wrap,
.wb-doc-audio-wrap {
    width: 100%;
    max-width: 100%;
    padding: 12px;
    box-sizing: border-box;
}
.wb-doc-video {
    display: block;
    width: 100%;
    max-width: 960px;
    max-height: calc(100vh - 220px);
    margin: 0 auto;
    background: #000;
    border-radius: 4px;
}
.wb-doc-audio {
    display: block;
    width: min(480px, 100%);
    margin: 24px auto;
}
.wb-embed-doc-overlay.wb-doc-scroll-mode .wb-doc-media-host,
.wb-embed-doc-overlay.wb-doc-scroll-mode .wb-doc-video,
.wb-embed-doc-overlay.wb-doc-scroll-mode .wb-doc-audio {
    pointer-events: auto;
}
#tpWbPaneCanvas.tp-wb-embed-live #tpWbEmbedHost,
#tpWbPaneCanvas.tp-wb-embed-live .tp-wb-iframe-host {
    position: absolute;
    inset: 0;
    flex: none;
    min-height: 0 !important;
    height: 100% !important;
    max-height: 100% !important;
    width: 100%;
    z-index: 5;
    background: #ededed;
}
#tpWbPaneCanvas.tp-wb-embed-live.wb-embed-doc-overlay #tpWbEmbedHost,
#tpWbPaneCanvas.tp-wb-embed-live .tp-wb-canvas-wrap.wb-embed-doc-overlay #tpWbEmbedHost,
#tpWbPaneCanvas.tp-wb-embed-live .tp-wb-canvas-wrap.wb-embed-doc-overlay .tp-wb-iframe-host {
    z-index: 2 !important;
    background: transparent !important;
}
#tpWbPaneCanvas.tp-wb-embed-live.wb-embed-doc-overlay .tp-wb-canvas-wrap,
#tpWbPaneCanvas.tp-wb-embed-live .tp-wb-canvas-wrap.wb-embed-doc-overlay {
    background: #ededed !important;
}
.wb-embed-doc-overlay #wbDocHtml.wb-pptx-host,
.wb-embed-doc-overlay #wbDocHtml.wb-doc-media-host {
    pointer-events: auto;
    background: #f0f2f5;
    display: flex !important;
    flex-direction: column;
    overflow: hidden;
}
#tpWbPaneCanvas.tp-wb-embed-live .cl-wb-embed-wrap,
#tpWbPaneCanvas.tp-wb-embed-live .zj-wb-platform-iframe-host {
    flex: 1;
    min-height: 0;
    height: 100%;
    max-height: 100%;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}
#tpWbPaneCanvas.tp-wb-embed-live iframe.zj-wb-embed {
    flex: 1;
    min-height: 0 !important;
    height: 100% !important;
    max-height: 100% !important;
    border-radius: 0;
}
#tpWbPaneCanvas.tp-wb-embed-live .zj-wb-student-dual,
#tpWbPaneCanvas.tp-wb-embed-live .zj-wb-teacher-dual {
    height: 100% !important;
    min-height: 0 !important;
}

#tpWbEmbedHost:fullscreen,
#tpWbEmbedHost:-webkit-full-screen,
.zj-wb-platform-iframe-host:fullscreen,
.zj-wb-platform-iframe-host:-webkit-full-screen,
.tp-wb-canvas-wrap:fullscreen,
.tp-wb-canvas-wrap:-webkit-full-screen {
    width: 100vw !important;
    height: 100vh !important;
    max-height: none !important;
    min-height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    border: none !important;
    border-radius: 0 !important;
    background: #ededed !important;
    box-sizing: border-box;
    overflow: hidden !important;
}
.tp-wb-canvas-wrap:fullscreen #wbDocHtml.wb-pptx-host,
.tp-wb-canvas-wrap:-webkit-full-screen #wbDocHtml.wb-pptx-host,
.ktp-wb-canvas-wrap:fullscreen #wbDocHtml.wb-pptx-host,
.ktp-wb-canvas-wrap:-webkit-full-screen #wbDocHtml.wb-pptx-host {
    top: var(--wb-annotate-bar-h, 42px) !important;
    bottom: 0 !important;
    left: 0 !important;
    right: 0 !important;
    height: auto !important;
    z-index: 5 !important;
}
.tp-wb-canvas-wrap:fullscreen.wb-doc-has-pptx #tpWbEmbedHost,
.tp-wb-canvas-wrap:-webkit-full-screen.wb-doc-has-pptx #tpWbEmbedHost,
.ktp-wb-canvas-wrap:fullscreen.wb-doc-has-pptx #tpWbEmbedHost,
.ktp-wb-canvas-wrap:-webkit-full-screen.wb-doc-has-pptx #tpWbEmbedHost {
    display: none !important;
}
.tp-wb-canvas-wrap:fullscreen.wb-doc-has-pptx .wb-pptx-stage,
.ktp-wb-canvas-wrap:fullscreen.wb-doc-has-pptx .wb-pptx-stage {
    flex: 1;
    min-height: 0;
    padding: 0 !important;
}
.tp-wb-canvas-wrap:fullscreen.wb-doc-has-pptx .wb-pptx-slide-body,
.ktp-wb-canvas-wrap:fullscreen.wb-doc-has-pptx .wb-pptx-slide-body {
    align-items: center !important;
    justify-content: center !important;
}
.tp-wb-canvas-wrap:fullscreen #wbDocHtml,
.tp-wb-canvas-wrap:-webkit-full-screen #wbDocHtml,
.ktp-wb-canvas-wrap:fullscreen #wbDocHtml,
.ktp-wb-canvas-wrap:-webkit-full-screen #wbDocHtml {
    z-index: 1 !important;
    background: #f5f5f5 !important;
}
.tp-wb-canvas-wrap:fullscreen #tpWbEmbedHost,
.tp-wb-canvas-wrap:-webkit-full-screen #tpWbEmbedHost,
.ktp-wb-canvas-wrap:fullscreen #tpWbEmbedHost,
.ktp-wb-canvas-wrap:-webkit-full-screen #tpWbEmbedHost {
    z-index: 2 !important;
    background: transparent !important;
}
.tp-wb-canvas-wrap:fullscreen .ktp-wb-annotate-bar,
.tp-wb-canvas-wrap:-webkit-full-screen .ktp-wb-annotate-bar,
.ktp-wb-canvas-wrap:fullscreen .ktp-wb-annotate-bar,
.ktp-wb-canvas-wrap:-webkit-full-screen .ktp-wb-annotate-bar {
    z-index: 6 !important;
}
#tpWbEmbedHost:fullscreen iframe.zj-wb-embed,
#tpWbEmbedHost:-webkit-full-screen iframe.zj-wb-embed,
.zj-wb-platform-iframe-host:fullscreen iframe.zj-wb-embed,
.zj-wb-platform-iframe-host:-webkit-full-screen iframe.zj-wb-embed {
    width: 100% !important;
    height: 100% !important;
    min-height: 0 !important;
}

/* 协作白板 Tab：仅保留「返回课程列表」，隐藏课程信息与 Tab 导航；保留资料/AI/词云子导航 */
#teacherCourseDetail.tp-wb-tab-active .tp-detail-head-main,
#teacherCourseDetail.tp-wb-tab-active .tp-detail-actions,
#teacherCourseDetail.tp-wb-tab-active .tp-detail-tabs,
#teacherCourseDetail.tp-wb-tab-active .tp-wb-intro {
    display: none !important;
}
#teacherCourseDetail.tp-wb-tab-active .tp-detail-header {
    margin-bottom: 12px;
    padding: 0;
    background: transparent;
    border: none;
    border-radius: 0;
}

/* 协作画布嵌入模式：加宽白板区域，仅保留返回按钮 */
body.tp-wb-focus-mode .portal-main {
    max-width: none;
    width: 100%;
    padding: 24px 24px 8px;
    box-sizing: border-box;
}
body.tp-wb-focus-mode #teacherCourseDetail .tp-detail-header {
    margin-bottom: 12px;
    padding: 0;
}
body.tp-wb-focus-mode #teacherCourseDetail .tp-detail-tabs {
    display: none !important;
}
body.tp-wb-focus-mode #tpTabWhiteboard.tp-wb-embed-live {
    padding: 0;
    border: none;
    border-radius: 8px;
    background: #ededed;
    position: relative;
    z-index: 2;
    isolation: isolate;
    overflow: hidden;
}
body.tp-wb-focus-mode .tp-wb-edu.tp-wb-embed-live .tp-wb-intro {
    display: none !important;
}
body.tp-wb-focus-mode #tpWbPaneCanvas.tp-wb-embed-live {
    min-height: 480px;
}
body.tp-wb-focus-mode #tpWbPaneCanvas.tp-wb-embed-live .tp-wb-group-bar {
    display: none !important;
}
body.tp-wb-focus-mode #tpWbPaneCanvas.tp-wb-embed-live .tp-wb-canvas-wrap {
    min-height: calc(100vh - var(--ktp-header-h, 56px) - 132px);
    height: calc(100vh - var(--ktp-header-h, 56px) - 132px);
    max-height: calc(100vh - var(--ktp-header-h, 56px) - 132px);
    border-radius: 0 0 8px 8px;
    border: none;
    background: #ededed;
}
body.tp-wb-focus-mode #tpWbPaneCanvas.tp-wb-embed-live #tpWbEmbedHost,
body.tp-wb-focus-mode #tpWbPaneCanvas.tp-wb-embed-live .tp-wb-iframe-host {
    background: #ededed;
}
@media (max-width: 900px) {
    body.tp-wb-focus-mode #tpWbPaneCanvas.tp-wb-embed-live .tp-wb-canvas-wrap {
        min-height: calc(100vh - var(--ktp-header-h, 56px) - 96px);
        height: calc(100vh - var(--ktp-header-h, 56px) - 96px);
        max-height: calc(100vh - var(--ktp-header-h, 56px) - 96px);
    }
    #tpWbPaneCanvas.tp-wb-embed-live .tp-wb-canvas-wrap {
        height: calc(100vh - 120px);
        max-height: calc(100vh - 120px);
    }
}

#tpTabWhiteboard.tp-wb-embed-live .tp-wb-intro {
    display: none !important;
}
#teacherCourseDetail.tp-wb-tab-active .tp-wb-subnav {
    display: flex !important;
    margin-bottom: 10px;
}
#teacherCourseDetail.tp-wb-tab-active .tp-wb-pane:not(#tpWbPaneCanvas).active {
    min-height: 420px;
}
.tp-wb-online-strip {
    margin-left: auto;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
    max-width: min(420px, 42vw);
    justify-content: flex-end;
}
.tp-wb-online-strip:empty { display: none; }
.tp-wb-online-strip-label {
    font-size: 12px;
    color: #8c8c8c;
    white-space: nowrap;
}
.tp-wb-online-chip {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 2px 8px;
    border-radius: 999px;
    background: #fff;
    border: 1px solid #d9f7be;
    font-size: 11px;
    color: #389e0d;
    white-space: nowrap;
}
.tp-wb-online-chip.is-teacher { border-color: #bae7ff; color: #096dd9; }
.tp-wb-online-chip.is-offline { opacity: 0.55; border-color: #f0f0f0; color: #8c8c8c; }
.tp-wb-online-chip.is-voice::after {
    content: '· 语音';
    color: #fa8c16;
    font-size: 10px;
}
.tp-wb-intro-online {
    margin-left: auto;
    max-width: min(520px, 55vw);
}
.tp-wb-intro-online:not(:empty) + .tp-wb-status { margin-left: 0; }
.tp-wb-iframe-host, .cr-wb-iframe-host { min-height: 520px; width: 100%; height: 100%; }
.cl-wb-group-bar {
    display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
    padding: 8px 12px; background: #fafafa; border-bottom: 1px solid #f0f0f0;
}
.cl-wb-group-bar .ktp-wb-group-tab { margin: 0; }
.zj-wb-student-dual {
    display: flex;
    flex-direction: column;
    min-height: 520px;
    height: calc(100vh - 260px);
    flex: 1;
}
.cl-learning-wrap .zj-wb-student-dual { height: calc(100vh - 260px); }
.zj-wb-student-dual .zj-wb-student-host,
.zj-wb-student-dual .cl-wb-embed-wrap {
    flex: 1;
    min-height: 460px;
}
.zj-wb-view-hint {
    margin-left: auto;
    font-size: 12px;
    color: #888;
    white-space: nowrap;
}
.cl-wb-student-wrap { min-height: 520px; }

/* 智教平台 · 全屏嵌入 classroom-whiteboard（与独立站一致） */
#page-whiteboard.zj-wb-platform-full {
    padding: 0 !important;
    margin: 0;
    max-width: none;
    min-height: calc(100vh - var(--ktp-header-h, 56px) - 16px);
}
#page-whiteboard.zj-wb-platform-full .edu-wb-shell {
    display: grid !important;
    min-height: calc(100vh - var(--ktp-header-h, 56px) - 24px);
}
#page-whiteboard.zj-wb-platform-full .edu-wb-mode-tabs,
#page-whiteboard.zj-wb-platform-full .edu-wb-toolbar,
#page-whiteboard.zj-wb-platform-full .edu-wb-statusbar,
#page-whiteboard.zj-wb-platform-full .edu-wb-right,
#page-whiteboard.zj-wb-platform-full #whiteboardCanvas {
    display: none !important;
}
#page-whiteboard.zj-wb-platform-full .edu-wb-canvas-wrap:not(.wb-embed-doc-overlay) .ktp-wb-doc-bg,
#page-whiteboard.zj-wb-platform-full .edu-wb-canvas-wrap:not(.wb-embed-doc-overlay) .ktp-wb-doc-frame,
#page-whiteboard.zj-wb-platform-full .edu-wb-canvas-wrap:not(.wb-embed-doc-overlay) .ktp-wb-doc-text,
#page-whiteboard.zj-wb-platform-full .edu-wb-canvas-wrap:not(.wb-embed-doc-overlay) .ktp-wb-doc-html,
#page-whiteboard.zj-wb-platform-full .edu-wb-canvas-wrap:not(.wb-embed-doc-overlay) .ktp-wb-doc-placeholder,
#page-whiteboard.zj-wb-platform-full .edu-wb-canvas-wrap:not(.wb-embed-doc-overlay) #wbAnnotateBar {
    display: none !important;
}
.zj-wb-platform-host {
    display: none;
    flex-direction: column;
    flex: 1;
    min-height: 0;
    border-radius: 0;
    overflow: hidden;
    background: #ededed;
    border: none;
}
#page-whiteboard.zj-wb-platform-full .edu-wb-canvas-wrap {
    flex: 1;
    min-height: 0;
    position: relative;
    display: flex;
    flex-direction: column;
}
#page-whiteboard.zj-wb-platform-full .zj-wb-platform-host {
    display: flex;
    position: absolute;
    inset: 0;
    min-height: 0;
    height: 100%;
}
#page-whiteboard.zj-wb-platform-full .zj-wb-embed {
    flex: 1;
    min-height: 100% !important;
    height: 100% !important;
    border-radius: 0;
}
.zj-wb-teacher-dual .zj-wb-teacher-bar {
    background: linear-gradient(90deg, #f0fdf4, #f0f9ff);
}
.zj-wb-landing {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 40px 32px;
    background: linear-gradient(to bottom, #f0fdf4, #fff, #f8fafc);
    min-height: 480px;
}
.zj-wb-landing-head {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 28px;
}
.zj-wb-landing-icon {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    background: hsl(152, 76%, 42%);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    box-shadow: 0 4px 14px rgba(7, 193, 96, 0.35);
}
.zj-wb-landing-head h2 {
    font-size: 20px;
    font-weight: 700;
    color: #111;
    margin: 0 0 4px;
}
.zj-wb-landing-head p {
    font-size: 12px;
    color: #888;
    margin: 0;
}
.zj-wb-landing-title {
    font-size: 28px;
    font-weight: 700;
    color: #111;
    margin: 0 0 12px;
}
.zj-wb-landing-desc {
    font-size: 15px;
    color: #666;
    line-height: 1.7;
    max-width: 560px;
    margin: 0 0 28px;
}
.zj-wb-landing-features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 12px;
    max-width: 520px;
}
.zj-wb-landing-feat {
    background: #fff;
    border: 1px solid #e5e5e5;
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}
.zj-wb-landing-feat i {
    color: hsl(152, 76%, 42%);
    font-size: 18px;
    margin-bottom: 8px;
    display: block;
}
.zj-wb-landing-feat strong {
    display: block;
    font-size: 14px;
    color: #111;
    margin-bottom: 4px;
}
.zj-wb-landing-feat span {
    font-size: 12px;
    color: #888;
}
.zj-wb-float-public {
    position: absolute;
    right: 16px;
    bottom: 16px;
    z-index: 20;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 18px;
    border: none;
    border-radius: 999px;
    background: linear-gradient(135deg, #1890ff, #096dd9);
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 6px 20px rgba(24, 144, 255, 0.45);
    transition: transform 0.15s, box-shadow 0.15s;
}
.zj-wb-float-public:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(24, 144, 255, 0.5);
}
.zj-wb-student-dual { position: relative; }
.cl-wb-toolbar {
    display: flex; flex-wrap: wrap; align-items: center; gap: 10px;
    padding: 10px 12px; background: #fafafa; border-bottom: 1px solid #f0f0f0;
}
.cl-wb-online { font-size: 13px; color: #389e0d; margin-right: auto; }
.cl-wb-color, .cl-wb-width { display: flex; align-items: center; gap: 6px; font-size: 12px; color: #666; }
.cl-wb-toolbar .active { background: #1890ff !important; color: #fff !important; border-color: #1890ff !important; }
.cl-wb-canvas-wrap { background: #fff; }
#clWbCanvas { display: block; width: 100%; touch-action: none; cursor: crosshair; }

/* 模态框 */
.cl-modal-full .ktp-modal { max-width: 96vw; width: 96vw; height: 90vh; display: flex; flex-direction: column; }
.cl-modal-body-fill { flex: 1; padding: 0 !important; min-height: 0; display: flex; flex-direction: column; }
.cl-preview-frame { width: 100%; height: 70vh; border: none; }

/* 课件在线演示（PDF / PPTX） */
.cw-viewer { display: flex; flex-direction: column; height: 70vh; min-height: 420px; background: #1a1a1a; border-radius: 8px; overflow: hidden; }
.cw-toolbar { display: flex; align-items: center; justify-content: center; gap: 12px; padding: 8px 12px; background: #2d2d2d; border-bottom: 1px solid #444; flex-shrink: 0; }
.cw-page { color: #eee; font-size: 14px; min-width: 72px; text-align: center; }
.cw-stage { flex: 1; position: relative; display: flex; flex-direction: column; align-items: stretch; justify-content: center; overflow: hidden; background: #111; min-height: 0; }
.cw-stage > iframe,
.cw-stage > video,
.cw-stage > canvas,
.cw-stage > .cw-pptx-dom,
.cw-stage > .cw-pptx-lite {
    flex: 1 1 auto;
    width: 100%;
    max-width: 100%;
    align-self: center;
    min-height: 0;
}
.cw-stage > .cw-media-hidden {
    display: none !important;
    flex: 0 0 0 !important;
    width: 0 !important;
    height: 0 !important;
    min-height: 0 !important;
    overflow: hidden !important;
    padding: 0 !important;
    margin: 0 !important;
    border: 0 !important;
}
.cw-stage > .cw-loading,
.cw-stage > .cw-error {
    align-self: center;
}
.cw-pdf-frame { width: 100%; height: 100%; border: none; background: #fff; }
.cw-pptx-canvas { max-width: 100%; height: auto; display: block; background: #fff; box-shadow: 0 4px 24px rgba(0,0,0,.35); }
.cw-loading { color: #ccc; font-size: 15px; display: flex; align-items: center; gap: 10px; }
.cw-error { width: 100%; padding: 40px 20px; }
.cw-error-inner { text-align: center; color: #ddd; }
.cw-error-inner i { font-size: 40px; color: #f59e0b; margin-bottom: 12px; }
.cl-modal-body-fill .cw-viewer { flex: 1; height: auto; min-height: 0; max-height: none; }
.cl-modal-body-fill .cw-stage { min-height: 50vh; }
.rv-body .cw-viewer { width: 100%; flex: 1; height: auto; max-height: 70vh; min-height: 360px; }
.cw-pptx-dom {
    width: 100%;
    max-width: 100%;
    flex: 1 1 auto;
    min-height: 0;
    overflow: auto;
    background: #fff;
    box-shadow: 0 4px 24px rgba(0,0,0,.35);
}
.cw-pptx-dom-inner { margin: 0 auto; }
.cw-pptx-dom-inner > div { margin: 0 auto; }
.cw-pptx-dom button { display: none !important; }
.cw-pptx-lite { width: 100%; max-width: 100%; max-height: none; min-height: 360px; overflow: auto; background: #fff; box-shadow: 0 4px 24px rgba(0,0,0,.35); }
.cw-lite-slide { min-height: 280px; box-sizing: border-box; }
.cw-lite-aspect { position: relative; width: 100%; max-width: 960px; margin: 0 auto; }
.cw-lite-inner { position: absolute; inset: 0; overflow: auto; padding: 20px 28px; box-sizing: border-box; }
.cw-lite-img { max-width: 100%; height: auto; display: block; margin: 0 auto 16px; }
.cw-lite-text { color: #222; font-size: 15px; line-height: 1.65; text-align: left; }
.cw-lite-text p, .cw-lite-p { margin: 0 0 10px; }
.cw-lite-bullet { display: inline-block; width: 1em; margin-left: -1em; color: #1890ff; }
.cw-lite-empty { color: #888; font-size: 13px; text-align: center; }
.cl-modal-meta { font-size: 13px; color: #8c8c8c; margin-bottom: 12px; }
.cl-ex-timer { margin-left: auto; margin-right: 12px; font-size: 14px; color: #ff4d4f; font-weight: 600; }
.cl-question { margin-bottom: 20px; padding-bottom: 16px; border-bottom: 1px dashed #f0f0f0; }
.cl-q-head { font-weight: 600; margin-bottom: 10px; font-size: 14px; }
.cl-q-score { font-weight: normal; color: #8c8c8c; font-size: 12px; }
.cl-q-opt { display: block; margin: 6px 0; font-size: 13px; cursor: pointer; }
.cl-q-text { width: 100%; margin-top: 6px; }
.cl-hw-desc { color: #666; margin-bottom: 16px; font-size: 13px; line-height: 1.6; }
.cl-hw-block {
    margin: 16px 0;
    padding: 16px;
    background: #fafafa;
    border: 1px solid #f0f0f0;
    border-radius: 8px;
}
.cl-hw-block-title {
    margin: 0 0 10px;
    font-size: 14px;
    font-weight: 600;
    color: #262626;
}
.cl-hw-block-title i { margin-right: 6px; color: #1890ff; }
.cl-hw-upload-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    background: #fff;
    border: 1px dashed #1890ff;
    border-radius: 8px;
    color: #1890ff;
    font-size: 14px;
    cursor: pointer;
    transition: background .2s;
}
.cl-hw-upload-btn:hover { background: #e6f7ff; }
.cl-hw-upload-btn input[type="file"] { display: none; }
.cl-hw-file-name { margin-top: 10px; font-size: 13px; color: #8c8c8c; }
.cl-hw-file-name.picked { color: #52c41a; font-weight: 500; }
.cl-hw-submitted { background: #f6ffed; border-color: #b7eb8f; }
.cl-hw-comment { margin-top: 16px; padding: 12px; background: #f6ffed; border-radius: 8px; font-size: 13px; }
.grade-meta-row { font-size: 13px; color: #595959; margin-bottom: 6px; }
.grade-meta-row a { color: #1890ff; }
.grade-download-row { margin: 12px 0 4px; }
.grade-download-row .ktp-btn { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hw-grade-item { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.hw-grade-item .ktp-file-info { flex: 1; min-width: 160px; }
.cl-ex-result { text-align: center; padding: 32px; }
.cl-ex-score { font-size: 48px; font-weight: 700; color: #1890ff; }
.cl-mat-preview { text-align: center; padding: 32px; background: #fafafa; border-radius: 8px; margin-top: 12px; color: #8c8c8c; }

@media (max-width: 768px) {
    .cl-catalog-layout { flex-direction: column; }
    .cl-tabs { flex-wrap: nowrap; overflow-x: auto; }
}

/* 签到 · 手势九宫格 */
.sg-wrap {
    position: relative;
    width: min(280px, 100%);
    margin: 0 auto;
    touch-action: none;
    user-select: none;
    -webkit-user-select: none;
}
.sg-lines {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}
.sg-grid {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 28px;
    padding: 16px;
    max-width: 280px;
    margin: 0 auto 10px;
}
.sg-dot {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    border: 3px solid #d9d9d9;
    background: #fafafa;
    padding: 0;
    margin: 0 auto;
    transition: background .15s, border-color .15s, transform .15s;
}
.sg-dot.active {
    background: #1890ff;
    border-color: #096dd9;
    transform: scale(1.08);
}
.sg-grid .sg-dot { cursor: crosshair; -webkit-tap-highlight-color: transparent; }
.sg-wrap.sg-dragging { cursor: crosshair; }
.sg-wrap.sg-dragging .sg-dot { pointer-events: none; }
.sg-hint { font-size: 13px; color: #8c8c8c; text-align: center; margin: 10px 0 0; line-height: 1.5; }
.ts-active-panel .sg-dot,
.ktp-signin-panel .sg-dot {
    background: rgba(255, 255, 255, .2);
    border-color: rgba(255, 255, 255, .75);
}
.ts-active-panel .sg-dot.active,
.ktp-signin-panel .sg-dot.active {
    background: #fff;
    border-color: #fff;
    box-shadow: 0 0 12px rgba(255, 255, 255, .45);
}
.ts-active-panel .sg-hint,
.ktp-signin-panel .sg-hint { color: rgba(255, 255, 255, .88); }

/* 签到 · 白板签名 */
.ts-wb-canvas-wrap {
    border: 1px solid #e8e8e8;
    border-radius: 8px;
    background: #fff;
    overflow: hidden;
}
.ts-wb-canvas-wrap canvas { display: block; width: 100%; touch-action: none; }
.ts-wb-ref { max-height: 90px; opacity: .85; }
.ts-wb-hint { font-size: 13px; color: #8c8c8c; margin-bottom: 8px; }

/* 教师签到独立页 */
.ts-shell { background: #f0f2f5; }
.ts-main { max-width: 720px; margin: 0 auto; padding: 20px 16px 48px; }
.ts-setup-panel .portal-hero.ts-hero {
    margin-bottom: 0;
    border-radius: 12px 12px 0 0;
}
.ts-setup-panel .ts-setup-card {
    margin-top: 0;
    border-radius: 0 0 12px 12px;
    border-top: none;
}
.ts-setup-card, .ts-history-card {
    background: #fff;
    border-radius: 12px;
    border: 1px solid #f0f0f0;
    padding: 20px;
    margin-bottom: 16px;
}
.ts-type-desc { font-size: 13px; color: #666; margin: -4px 0 14px; }
.ts-active-panel { text-align: center; }
.ts-active-title { font-size: 18px; margin-bottom: 12px; }
.ts-code-hint { font-size: 13px; opacity: .85; margin-bottom: 6px; }
.ts-count-line { margin: 12px 0; }
.ts-wb-setup { margin-bottom: 12px; }
.ts-setup-toolbar { margin-bottom: 14px; }
.ts-active-actions { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin-top: 12px; }
.ts-history-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.ts-history-head h3 { margin: 0; font-size: 15px; }
.ts-class-att-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-bottom: 16px; }
.ts-class-att-stat { background: #f6ffed; border: 1px solid #b7eb8f; border-radius: 10px; padding: 14px; text-align: center; }
.ts-class-att-stat .val { font-size: 24px; font-weight: 700; color: #389e0d; }
.ts-class-att-stat .lbl { font-size: 12px; color: #666; margin-top: 4px; }
.ts-section-title { font-size: 14px; margin: 0 0 8px; color: #434343; }
.ts-attendance-block { background: #fafafa; border-radius: 10px; padding: 16px; text-align: center; }
.ts-attendance-rate-big { font-size: 32px; font-weight: 700; }
.ts-attendance-rate-big.good { color: #52c41a; }
.ts-attendance-rate-big.ok { color: #faad14; }
.ts-attendance-rate-big.warn { color: #ff4d4f; }
.ts-attendance-meta { font-size: 13px; color: #666; margin-top: 6px; }
.ktp-attendance-rate.good { color: #52c41a; font-weight: 600; }
.ktp-attendance-rate.ok { color: #faad14; font-weight: 600; }
.ktp-attendance-rate.warn { color: #ff4d4f; font-weight: 600; }

/* 教师端 · 课程协作白板 */
.tp-wb-panel { padding: 0 !important; }
.tp-wb-intro {
    display: flex; align-items: center; gap: 14px; flex-wrap: wrap;
    padding: 14px 16px; background: linear-gradient(135deg, #e6f7ff 0%, #f0f5ff 100%);
    border-radius: 10px; margin-bottom: 12px; border: 1px solid #bae7ff;
}
.tp-wb-intro i { font-size: 28px; color: #1890ff; }
.tp-wb-intro p { margin: 4px 0 0; font-size: 12px; color: #666; }
.tp-wb-status { margin-left: auto; font-size: 13px; color: #389e0d; font-weight: 600; display: flex; align-items: center; gap: 6px; }
.tp-wb-toolbar {
    display: flex; flex-wrap: wrap; align-items: center; gap: 8px;
    padding: 10px 12px; background: #fafafa; border: 1px solid #f0f0f0; border-radius: 8px; margin-bottom: 12px;
}
.tp-wb-tool {
    width: 36px; height: 36px; border: 1px solid #e8e8e8; background: #fff; border-radius: 6px;
    cursor: pointer; color: #595959; display: inline-flex; align-items: center; justify-content: center;
}
.tp-wb-tool.active { background: #1890ff; border-color: #1890ff; color: #fff; }
.tp-wb-layout { display: grid; grid-template-columns: 1fr 220px; gap: 14px; }
@media (max-width: 900px) { .tp-wb-layout { grid-template-columns: 1fr; } }
.tp-wb-canvas-wrap {
    border: 1px solid #e8e8e8; border-radius: 10px; background: #fff; overflow: hidden; min-height: 440px;
}
.tp-wb-canvas-wrap canvas { display: block; width: 100%; touch-action: none; cursor: crosshair; }
.tp-wb-side {
    background: #fafafa; border: 1px solid #f0f0f0; border-radius: 10px; padding: 14px; max-height: 560px; overflow-y: auto;
}
.tp-wb-side h4 { font-size: 14px; margin: 0 0 10px; color: #434343; }
.tp-wb-side-hint { font-size: 11px; color: #8c8c8c; line-height: 1.5; margin-top: 12px; }
.tp-wb-empty { font-size: 12px; color: #bfbfbf; text-align: center; padding: 12px 0; }
.tp-wb-participant {
    display: flex; align-items: center; gap: 8px; padding: 8px; background: #fff;
    border-radius: 8px; margin-bottom: 6px; border: 1px solid #f0f0f0;
}
.tp-wb-part-avatar {
    width: 28px; height: 28px; border-radius: 50%; background: #1890ff; color: #fff;
    display: inline-flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 600;
}
.tp-wb-part-student .tp-wb-part-avatar { background: #52c41a; }
.tp-wb-part-name { flex: 1; font-size: 13px; color: #262626; }
.tp-wb-part-role { font-size: 11px; color: #8c8c8c; }
.wb-collab-live-dot {
    width: 8px; height: 8px; border-radius: 50%; background: #52c41a;
    display: inline-block; animation: tp-wb-pulse 1.2s infinite;
}
@keyframes tp-wb-pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.4; } }

.tp-wb-edu .tp-wb-subnav {
    display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 12px;
    padding: 8px; background: #f5f9ff; border-radius: 8px; border: 1px solid #e6f4ff;
}
.tp-wb-subnav-item {
    padding: 8px 14px; border-radius: 6px;
    background: #fff; color: #434343; font-size: 13px; cursor: pointer;
}
.tp-wb-subnav-item.active { background: transparent; color: #1890ff; font-weight: 600; }
.tp-wb-pane { display: none; }
.tp-wb-pane.active { display: block; }
.tp-wb-pane-head {
    display: flex; align-items: center; justify-content: space-between;
    gap: 12px; margin-bottom: 12px; flex-wrap: wrap;
}
.tp-wb-pane-head h3 { margin: 0; font-size: 16px; color: #262626; }
.tp-wb-edu .ktp-wb-canvas-wrap { position: relative; min-height: 420px; }

.signin-map-unavailable {
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    min-height: 220px; padding: 24px 16px; text-align: center;
    background: linear-gradient(180deg, #f5f9ff 0%, #fafafa 100%);
    border: 1px dashed #91caff; border-radius: 8px; color: #595959;
}
.signin-map-unavailable i { font-size: 36px; color: #69b1ff; margin-bottom: 12px; }
.signin-map-unavailable p { margin: 4px 0; font-size: 13px; line-height: 1.6; }
.signin-map-unavailable .hint { color: #8c8c8c; font-size: 12px; max-width: 420px; }
.tp-wb-edu #whiteboardCanvas { display: block; width: 100%; touch-action: none; cursor: crosshair; position: relative; z-index: 2; }
.tp-wb-edu .ktp-wb-doc-drop { margin-bottom: 12px; }
.tp-wb-edu .ktp-wb-ai-agent { max-width: 100%; }

/* 模块/区块标题旁装饰小图标（保留按钮、导航、空状态、列表类型图标） */
.ktp-panel-title > i,
.ktp-modal-title > i:first-child,
.ktp-todo-icon { display: none !important; }
.ktp-todo-actions .ktp-btn > i,
.ktp-home-todo-type > i,
.ktp-home-todo-arrow { display: none !important; }
.portal-students-head > i:first-child,
.ts-section > h4 > i,
.ts-section-title > i,
.portal-section-summary > i,
.portal-unit-summary > i,
.cr-section-title > i,
.cr-unit-title > i,
.tp-chapter-head > i,
.ktp-course-resource-title > i,
.tcb-sidebar-head h2 > i,
.tcb-ocr-title > i,
#wrongAiPanelTitle > i,
.ktp-home-todo-title > i,
.portal-logo > i,
.auth-portal-tag > i,
.ktp-signin-method-card > i,
.portal-resource-chip > i:first-child,
#rvTitle > i:first-child {
    display: none !important;
}

/* 协作白板 / 课程学习 · 导航 Tab 旁功能图标（需可见） */
.tp-detail-tab > i,
.tp-wb-subnav-item > i,
.tp-wb-intro > i:first-child,
.tp-wb-pane-head h3 > i,
.tp-wb-subhead h4 > i,
.tp-wb-group-label > i,
.edu-wb-nav-item > i,
.cl-tab-btn > i {
    display: inline-block !important;
    width: 1.05em;
    text-align: center;
    margin-right: 5px;
    opacity: 0.92;
    flex-shrink: 0;
}
.tp-detail-tab,
.tp-wb-subnav-item,
.edu-wb-nav-item,
.cl-tab-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
}
.edu-wb-nav-item { gap: 8px; }
.tp-wb-subnav-item i { color: inherit; }
.tp-wb-subnav-item.active i,
.tp-detail-tab.active i,
.edu-wb-nav-item.active i,
.cl-tab-btn.active i { color: #1890ff; }

.join-group-field { margin-top: 12px; }
.join-group-hint {
    font-size: 12px;
    color: #888;
    margin: 6px 0 0;
    line-height: 1.5;
}
