/* 人工智能导论 学—练—评—诊 一体化教学支持系统 · 共享样式 */
:root {
  --primary: #2563eb;
  --primary-d: #1d4ed8;
  --teal: #0d9488;
  --amber: #d97706;
  --purple: #7c3aed;
  --red: #dc2626;
  --green: #16a34a;
  --bg: #f4f6fb;
  --surface: #ffffff;
  --line: #e6e9f0;
  --text: #1f2937;
  --muted: #6b7280;
  --soft: #f8fafc;
  --radius: 14px;
  --shadow: 0 6px 22px rgba(31, 45, 90, 0.07);
  --font: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Microsoft YaHei', sans-serif;
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; padding: 0; }
body { font-family: var(--font); background: var(--bg); color: var(--text); font-size: 14px; line-height: 1.6; }
a { color: var(--primary); text-decoration: none; }
button { font-family: inherit; cursor: pointer; }

/* ===== 登录页 ===== */
.login-wrap { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 20px; background: radial-gradient(circle at 15% 10%, #e8efff 0, transparent 40%), radial-gradient(circle at 85% 90%, #e6f7f4 0, transparent 40%), var(--bg); }
.login-card { width: 100%; max-width: 420px; background: var(--surface); border-radius: 20px; box-shadow: var(--shadow); padding: 34px 30px; border: 1px solid var(--line); }
.login-card .logo { width: 52px; height: 52px; border-radius: 14px; background: linear-gradient(135deg, var(--primary), var(--purple)); display: flex; align-items: center; justify-content: center; color: #fff; font-size: 26px; margin-bottom: 18px; }
.login-card h1 { font-size: 21px; margin: 0 0 6px; }
.login-card .sub { color: var(--muted); margin: 0 0 24px; font-size: 13px; }
.field { margin-bottom: 16px; }
.field label { display: block; font-size: 13px; color: var(--muted); margin-bottom: 7px; }
.field select, .field input { width: 100%; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; font-size: 14px; background: var(--soft); color: var(--text); outline: none; transition: .2s; }
.field select:focus, .field input:focus { border-color: var(--primary); background: #fff; box-shadow: 0 0 0 3px rgba(37,99,235,.1); }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 7px; padding: 11px 18px; border: none; border-radius: 10px; background: var(--primary); color: #fff; font-size: 14px; font-weight: 500; transition: .2s; }
.btn:hover { background: var(--primary-d); }
.btn:active { transform: translateY(1px); }
.btn-block { width: 100%; }
.btn-ghost { background: var(--soft); color: var(--text); border: 1px solid var(--line); }
.btn-ghost:hover { background: #eef1f7; }
.btn-sm { padding: 7px 12px; font-size: 12px; border-radius: 8px; }
.hint { font-size: 12px; color: var(--muted); margin-top: 14px; text-align: center; }
.err { color: var(--red); font-size: 12px; min-height: 18px; margin-top: 4px; }
.switch-link { text-align: center; margin-top: 18px; font-size: 13px; color: var(--muted); }

/* ===== 应用布局 ===== */
.app { display: flex; min-height: 100vh; }
.sidebar { width: 232px; flex: 0 0 232px; background: var(--surface); border-right: 1px solid var(--line); display: flex; flex-direction: column; position: sticky; top: 0; height: 100vh; z-index: 30; transition: transform .25s; }
.sb-head { padding: 13px 16px; border-bottom: 1px solid var(--line); display: flex; align-items: center; gap: 11px; background: linear-gradient(120deg, #f5f8ff 0%, #eef3ff 60%, #f0fbf9 100%); }
.sb-brand-logo { width: 42px; height: 42px; flex: 0 0 42px; object-fit: contain; background: #fff; border-radius: 11px; padding: 4px; box-shadow: 0 3px 10px rgba(37,99,235,.14); }
.sb-logo { width: 38px; height: 38px; border-radius: 10px; background: linear-gradient(135deg, var(--primary), var(--purple)); color: #fff; display: flex; align-items: center; justify-content: center; font-size: 19px; flex: 0 0 auto; }
.sb-title { font-size: 14px; font-weight: 700; line-height: 1.35; color: #1e3a8a; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.sb-title small { display: block; color: var(--muted); font-weight: 400; font-size: 11px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: 2px; }
.sb-user { padding: 14px 18px; background: var(--soft); border-bottom: 1px solid var(--line); }
.sb-user .u-name { font-weight: 600; }
.sb-user .u-sid { font-size: 12px; color: var(--muted); }
.sb-user .u-major { font-size: 12px; color: var(--muted); margin-top: 2px; }
.tbl .ipt-sm { width: 100%; min-width: 70px; padding: 5px 8px; border: 1px solid var(--line); border-radius: 7px; font-size: 13px; background: #fff; color: var(--text); outline: none; }
.tbl .ipt-sm:focus { border-color: var(--primary); box-shadow: 0 0 0 2px rgba(37,99,235,.12); }
.tbl tr.roster-editing { background: #f7faff; }
.nav { flex: 1; overflow-y: auto; padding: 6px 0; scrollbar-width: thin; scrollbar-color: #d5dbe6 transparent; }
.nav::-webkit-scrollbar { width: 6px; }
.nav::-webkit-scrollbar-thumb { background: #d5dbe6; border-radius: 3px; }
.nav::-webkit-scrollbar-thumb:hover { background: #b9c2d2; }
.nav::-webkit-scrollbar-track { background: transparent; }
.nav-group { padding: 13px 18px 4px; font-size: 11px; font-weight: 600; letter-spacing: .6px; color: #7c8798; margin-top: 2px; }
.nav-item + .nav-group { border-top: 1px solid #eef1f7; margin-top: 10px; padding-top: 13px; }
.nav-group-toggle { cursor: pointer; user-select: none; display: flex; align-items: center; justify-content: space-between; }
.nav-group-toggle::after { content: '▾'; font-size: 10px; opacity: .55; transform: scale(.9); }
.nav-group-toggle:hover { color: var(--primary); }
.nav-group-toggle.collapsed::after { content: '▸'; }
.nav-item { display: flex; align-items: center; gap: 11px; padding: 8px 18px; color: #4b5563; font-size: 13.5px; border-left: 3px solid transparent; transition: .15s; cursor: pointer; }
.nav-item:hover { background: var(--soft); }
.nav-item.active { background: #eef3ff; color: var(--primary); border-left-color: var(--primary); font-weight: 500; }
.nav-item .ico { width: 22px; height: 22px; flex: 0 0 22px; display: flex; align-items: center; justify-content: center; border-radius: 6px; background: #f2f4f9; font-size: 12.5px; line-height: 1; transition: background .15s; filter: grayscale(1) opacity(.9); }
.nav-item:hover .ico { background: #e8edf8; }
.nav-item.active .ico { background: #d9e4ff; filter: none; }
.sb-foot { padding: 14px 18px; border-top: 1px solid var(--line); }
.badge { display: inline-block; padding: 2px 8px; border-radius: 20px; font-size: 11px; background: #eef3ff; color: var(--primary); }

.main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.topbar { height: 62px; flex: 0 0 62px; background: var(--surface); border-bottom: 1px solid var(--line); display: flex; align-items: center; padding: 0 26px; gap: 14px; position: sticky; top: 0; z-index: 20; }
.menu-btn { display: none; background: none; border: none; font-size: 22px; color: var(--text); padding: 4px 8px; }
.topbar h2 { font-size: 17px; margin: 0; font-weight: 600; }
.topbar .spacer { flex: 1; }
.topbar .who { font-size: 13px; color: var(--muted); }
.content { padding: 24px 26px 50px; max-width: 1240px; width: 100%; margin: 0 auto; }
.view { display: none; animation: fade .25s ease; }
.view.active { display: block; }
.view.active > * + * { margin-top: 16px; }
@keyframes fade { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

/* ===== 卡片与栅格 ===== */
.cards { display: grid; gap: 16px; }
.grid-2 { grid-template-columns: repeat(2, minmax(0,1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0,1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0,1fr)); }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px; }
.card h3 { margin: 0 0 14px; font-size: 15px; font-weight: 600; }
.kpi { display: flex; flex-direction: column; gap: 6px; }
.kpi .k-val { font-size: 30px; font-weight: 600; line-height: 1; }
.kpi .k-label { color: var(--muted); font-size: 13px; }
.kpi .k-tag { font-size: 11px; }
.kpi.c-blue .k-val { color: var(--primary); }
.kpi.c-teal .k-val { color: var(--teal); }
.kpi.c-amber .k-val { color: var(--amber); }
.kpi.c-purple .k-val { color: var(--purple); }
.section-title { font-size: 15px; font-weight: 600; margin: 4px 0 14px; display: flex; align-items: center; gap: 8px; }
.section-title .dot { width: 4px; height: 16px; border-radius: 2px; background: var(--primary); }

/* 进度条 */
.bar { height: 8px; background: #edf0f6; border-radius: 20px; overflow: hidden; }
.bar > i { display: block; height: 100%; background: linear-gradient(90deg, var(--primary), var(--teal)); border-radius: 20px; }
.chip { display: inline-flex; align-items: center; gap: 5px; padding: 3px 10px; border-radius: 20px; font-size: 12px; background: var(--soft); color: var(--muted); }
.chip.ok { background: #e9f8ef; color: var(--green); }
.chip.warn { background: #fef3e2; color: var(--amber); }
.chip.info { background: #eef3ff; color: var(--primary); }

/* 模块卡片 */
.mod-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px,1fr)); gap: 14px; }
.mod { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 16px; transition: .2s; }
.mod:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.mod .mod-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; margin-bottom: 8px; }
.mod .mod-title { font-weight: 600; font-size: 14px; }
.mod .mod-goal { color: var(--muted); font-size: 12px; min-height: 36px; }
.mod .mod-meta { display: flex; justify-content: space-between; font-size: 12px; color: var(--muted); margin: 10px 0 6px; }

/* 表格 */
.tbl-wrap { overflow-x: auto; }
table.tbl { width: 100%; border-collapse: collapse; font-size: 13px; min-width: 560px; }
.tbl th, .tbl td { padding: 10px 12px; text-align: left; border-bottom: 1px solid var(--line); white-space: nowrap; }
.tbl th { color: var(--muted); font-weight: 500; background: var(--soft); position: sticky; top: 0; }
.tbl tr:hover td { background: #fbfcff; }
.mini-bar { display: inline-block; width: 70px; height: 7px; background: #edf0f6; border-radius: 20px; overflow: hidden; vertical-align: middle; margin-right: 6px; }
.mini-bar > i { display: block; height: 100%; background: var(--primary); }

/* 表单 / 题目 */
.q-block { border: 1px solid var(--line); border-radius: 12px; padding: 16px; margin-bottom: 14px; background: #fff; }
.q-block .q-title { font-weight: 500; margin-bottom: 10px; }
.q-block .q-type { font-size: 11px; color: var(--primary); background: #eef3ff; padding: 2px 8px; border-radius: 6px; margin-right: 8px; }
.opt { display: block; padding: 8px 10px; border: 1px solid var(--line); border-radius: 8px; margin: 6px 0; cursor: pointer; }
.opt:hover { background: var(--soft); }
.opt input { margin-right: 8px; }
textarea { width: 100%; padding: 11px 12px; border: 1px solid var(--line); border-radius: 10px; font-size: 14px; font-family: inherit; resize: vertical; min-height: 80px; outline: none; }
textarea:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(37,99,235,.1); }

/* 答疑 */
.chat { display: flex; flex-direction: column; gap: 12px; max-height: 460px; overflow-y: auto; padding: 4px 6px 8px; }
.msg { display: flex; gap: 10px; align-items: flex-start; }
.msg .av { width: 32px; height: 32px; border-radius: 9px; flex: 0 0 auto; display: flex; align-items: center; justify-content: center; color: #fff; font-size: 13px; }
.msg.me { flex-direction: row-reverse; }
.msg.me .av { background: var(--primary); }
.msg.ai .av { background: linear-gradient(135deg, var(--purple), var(--primary)); }
.msg.tchr .av { background: var(--teal); }
.msg .bubble { max-width: 78%; background: var(--soft); border: 1px solid var(--line); padding: 10px 13px; border-radius: 12px; font-size: 13px; white-space: pre-wrap; }
.msg.me .bubble { background: #eef3ff; border-color: #dbe6ff; }
.chat-input { display: flex; gap: 10px; margin-top: 14px; }
.chat-input input { flex: 1; padding: 11px 13px; border: 1px solid var(--line); border-radius: 10px; outline: none; }
.chat-input input:focus { border-color: var(--primary); }
.ai-note { font-size: 12px; color: var(--muted); background: #fff8e8; border: 1px solid #fde9b8; padding: 8px 12px; border-radius: 10px; margin-bottom: 12px; }

/* 图表 */
.chart { width: 100%; height: 300px; }
.chart-lg { height: 430px; }
.chart-sm { height: 250px; }
.legend-full { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.legend-full span { font-size: 12px; background: var(--soft); border: 1px solid var(--line); padding: 3px 9px; border-radius: 8px; }

/* Toast */
#toast { position: fixed; top: 18px; left: 50%; transform: translateX(-50%) translateY(-20px); background: #111827; color: #fff; padding: 11px 20px; border-radius: 10px; font-size: 13px; z-index: 100; opacity: 0; pointer-events: none; transition: .25s; box-shadow: 0 8px 24px rgba(0,0,0,.2); }
#toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
#toast.err { background: var(--red); }
#toast.ok { background: var(--green); }

.overlay { display: none; position: fixed; inset: 0; background: rgba(15,23,42,.35); z-index: 25; }
.overlay.show { display: block; }

/* 响应式 */
@media (max-width: 900px) {
  .grid-4 { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .grid-3 { grid-template-columns: repeat(2, minmax(0,1fr)); }
}
@media (max-width: 720px) {
  .sidebar { position: fixed; left: 0; top: 0; transform: translateX(-100%); box-shadow: 8px 0 30px rgba(0,0,0,.12); }
  .sidebar.open { transform: translateX(0); }
  .menu-btn { display: block; }
  .topbar { padding: 0 14px; }
  .content { padding: 16px 14px 40px; }
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .mod-list { grid-template-columns: 1fr; }
  .topbar .who { display: none; }
}

/* ===== 扩展组件 ===== */
.motto { font-size: 12px; color: var(--muted); background: #f0f4ff; border-left: 3px solid var(--primary); padding: 8px 12px; border-radius: 6px; margin: 0 0 18px; line-height: 1.5; }
.brand-strip { display: flex; align-items: center; gap: 14px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 16px; margin-bottom: 16px; box-shadow: var(--shadow); }
.brand-strip img { height: 44px; object-fit: contain; }
.brand-strip b { display: block; font-size: 15px; }
.brand-strip span { font-size: 12px; color: var(--muted); }
.tabs { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 16px; border-bottom: 1px solid var(--line); padding-bottom: 10px; }
.tab { padding: 8px 14px; border: none; background: var(--soft); border-radius: 8px; font-size: 13px; color: var(--muted); }
.tab.active { background: var(--primary); color: #fff; }
.case-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px,1fr)); gap: 12px; }
.case-card { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 13px; }
.case-head { display: flex; gap: 5px; flex-wrap: wrap; margin-bottom: 8px; }
.case-title { font-weight: 600; font-size: 13px; margin-bottom: 6px; }
.case-desc { color: var(--muted); font-size: 12px; line-height: 1.6; }
.case-foot { margin-top: 8px; font-size: 11px; color: var(--primary); border-top: 1px dashed var(--line); padding-top: 6px; }
.case-foot a { color: var(--primary); text-decoration: none; }
.case-foot a:hover { text-decoration: underline; }
.eth-card { border-left: 3px solid var(--purple); }
.prompt-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(340px,1fr)); gap: 12px; }
.prompt-card { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 12px; display: flex; flex-direction: column; }
.prompt-card-head { display: flex; gap: 5px; flex-wrap: wrap; align-items: center; margin-bottom: 8px; }
.prompt-card-head .copy-btn { margin-left: auto; }
.prompt-card-text { color: var(--text); font-size: 12.5px; line-height: 1.75; white-space: pre-wrap; word-break: break-word; flex: 1; }
.prompt-card-src { margin-top: 8px; padding-top: 6px; border-top: 1px dashed var(--line); font-size: 11px; color: var(--muted); }
.chapter-card { margin-bottom: 14px; border-left: 3px solid var(--teal); }
.chapter-head { display: flex; gap: 6px; margin-bottom: 6px; }
.chapter-card h3 { margin: 0 0 8px; font-size: 15px; }
.chapter-body { font-size: 12.5px; line-height: 1.85; color: var(--muted); max-height: 340px; overflow: auto; }
.eth-meta { font-size: 11px; color: var(--primary); background: rgba(37,99,235,.06); display: inline-block; padding: 3px 8px; border-radius: 6px; }
.eth-questions ol li { margin-bottom: 6px; }
.tpl { margin-bottom: 12px; }
.tpl-name { display: flex; justify-content: space-between; align-items: center; font-weight: 500; font-size: 13px; margin-bottom: 5px; }
.tpl pre { white-space: pre-wrap; word-break: break-word; background: var(--soft); border: 1px solid var(--line); border-radius: 8px; padding: 10px; font-size: 12px; color: #374151; margin: 0; font-family: var(--font); }
.guide-list { padding-left: 20px; margin: 0; }
.guide-list li { padding: 5px 0; border-bottom: 1px dashed var(--line); font-size: 13px; }
.qr-box { text-align: center; padding: 10px; }
.qr-box img { width: 150px; height: 150px; image-rendering: pixelated; background:#fff; padding:6px; border:1px solid var(--line); border-radius:8px; }
.mod-res { padding: 9px 0; border-bottom: 1px dashed var(--line); font-size: 13px; }
.mod-res a { color: var(--primary); }

/* ===== AI 智能工具（原 AIGC 工具库，样式已内置于 js/agenttools.js） ===== */

/* ===== 级联选择（专业 / 班级 / 学号）===== */
.cascade { display: flex; flex-direction: column; gap: 3px; }
.cascade .field { margin-bottom: 12px; }
.cascade-step { display: flex; align-items: center; gap: 8px; }
.cascade-step .step-no { width: 22px; height: 22px; flex: 0 0 auto; border-radius: 50%; background: #eef3ff; color: var(--primary); font-size: 12px; font-weight: 600; display: flex; align-items: center; justify-content: center; }

/* ===== 名单管理 ===== */
.roster-stat { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 14px; }
.roster-stat .chip { font-size: 13px; padding: 6px 14px; }
.roster-qr { display: flex; gap: 18px; flex-wrap: wrap; align-items: flex-start; }
.roster-qr canvas, .roster-qr img { width: 168px; height: 168px; background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 6px; }
.roster-tip { font-size: 12px; color: var(--muted); line-height: 1.8; }
.roster-tip b { color: var(--text); }
.upload-zone { border: 1.5px dashed #b9c4da; border-radius: 12px; padding: 16px; background: var(--soft); }
.upload-zone textarea { min-height: 110px; font-size: 12px; }

/* ====== 赋能个体·共生未来（AI育人主线） ====== */
.fut-hero { background: linear-gradient(125deg,#eef4ff 0%,#f0f7ff 45%,#ecfdf5 100%); border-color:#dbe7ff; }
.fut-hero-tag { display:inline-block; font-size:11px; letter-spacing:.5px; color:var(--primary); background:rgba(37,99,235,.1); padding:4px 10px; border-radius:20px; margin-bottom:10px; }
.fut-hero h2 { margin:0 0 10px; font-size:26px; background:linear-gradient(90deg,#1d4ed8,#0d9488); -webkit-background-clip:text; background-clip:text; color:transparent; }
.fut-hero p { margin:0; color:#475569; font-size:13px; line-height:1.9; }
.fut-hero-stats { display:flex; gap:26px; flex-wrap:wrap; margin-top:18px; padding-top:14px; border-top:1px solid #dbe7ff; }
.fut-hero-stats div { display:flex; flex-direction:column; }
.fut-hero-stats b { font-size:22px; color:var(--primary); }
.fut-hero-stats span { font-size:11px; color:var(--muted); }
.fut-tabs { display:flex; gap:4px; flex-wrap:wrap; margin:14px 0 16px; border-bottom:1px solid var(--line); }
.fut-tabs .tab { border:none; background:transparent; padding:9px 14px; font-size:13px; color:var(--muted); cursor:pointer; border-bottom:2px solid transparent; }
.fut-tabs .tab.active { color:var(--primary); border-bottom-color:var(--primary); font-weight:600; }
.fut-lead { background:rgba(37,99,235,.05); border-left:3px solid var(--primary); padding:12px 15px; border-radius:8px; font-size:12.5px; line-height:1.85; color:#475569; margin-bottom:16px; }
/* 时间轴 */
.timeline { position:relative; padding-left:8px; }
.tl-item { position:relative; padding:0 0 20px 34px; border-left:2px solid var(--line); margin-left:8px; }
.tl-item:last-child { border-left-color:transparent; }
.tl-dot { position:absolute; left:-7px; top:3px; width:12px; height:12px; border-radius:50%; background:var(--primary); border:2px solid #fff; box-shadow:0 0 0 2px rgba(37,99,235,.25); }
.era-1 .tl-dot{background:#7c3aed;box-shadow:0 0 0 2px rgba(124,58,237,.25)}
.era-2 .tl-dot{background:#d97706;box-shadow:0 0 0 2px rgba(217,119,6,.25)}
.era-3 .tl-dot{background:#0d9488;box-shadow:0 0 0 2px rgba(13,148,136,.25)}
.era-4 .tl-dot{background:#2563eb}
.tl-year { font-size:13px; font-weight:700; color:var(--primary); margin-bottom:4px; }
.tl-body { background:var(--surface); border:1px solid var(--line); border-radius:12px; padding:13px 15px; }
.tl-head { display:flex; align-items:center; gap:8px; flex-wrap:wrap; }
.tl-head h3 { margin:0; font-size:14px; }
.tl-person { font-size:11px; color:var(--teal); margin:6px 0; }
.tl-body p { margin:0; font-size:12.5px; line-height:1.8; color:#475569; }
.tl-src { font-size:10.5px; color:var(--muted); margin-top:8px; }
/* 政策 */
.policy-list { display:flex; flex-direction:column; gap:12px; }
.policy-card { display:flex; gap:14px; background:var(--surface); border:1px solid var(--line); border-radius:12px; padding:15px; }
.policy-no { flex:none; width:34px; height:34px; border-radius:10px; background:linear-gradient(135deg,#2563eb,#60a5fa); color:#fff; display:flex; align-items:center; justify-content:center; font-weight:700; font-size:14px; }
.policy-main { flex:1; min-width:0; }
.policy-head { display:flex; gap:6px; margin-bottom:6px; }
.policy-main h3 { margin:0 0 6px; font-size:14px; }
.policy-org { font-size:11px; color:var(--teal); margin-bottom:8px; }
.policy-main p { margin:0 0 7px; font-size:12.5px; line-height:1.75; color:#475569; }
.policy-meaning { color:var(--primary) !important; }
.policy-link { font-size:12px; color:var(--primary); text-decoration:none; font-weight:600; }
.policy-link:hover { text-decoration:underline; }
/* OPC */
.opc-intro { background:linear-gradient(120deg,#eef4ff,#ecfdf5); border:1px solid #dbe7ff; border-radius:14px; padding:18px; }
.opc-formula { display:inline-block; background:#1d4ed8; color:#fff; font-size:13px; font-weight:600; padding:7px 14px; border-radius:8px; margin-bottom:12px; }
.opc-intro h3 { margin:0 0 8px; font-size:17px; }
.opc-intro p { margin:0; font-size:12.5px; line-height:1.85; color:#475569; }
.opc-caution { margin-top:12px; font-size:12px; color:#92400e; background:rgba(217,119,6,.12); padding:9px 12px; border-radius:8px; }
.opc-src { font-size:10.5px; color:var(--muted); margin-top:10px; }
.opc-grid { display:grid; grid-template-columns:repeat(auto-fill,minmax(320px,1fr)); gap:12px; }
.opc-card { background:var(--surface); border:1px solid var(--line); border-radius:12px; padding:14px; }
.opc-card-head { display:flex; gap:10px; align-items:center; }
.opc-avatar { flex:none; width:38px; height:38px; border-radius:50%; background:linear-gradient(135deg,#0d9488,#34d399); color:#fff; display:flex; align-items:center; justify-content:center; font-size:16px; font-weight:700; }
.opc-card-head h3 { margin:0; font-size:14px; }
.opc-id { font-size:10.5px; color:var(--muted); }
.opc-tags { display:flex; gap:5px; margin:10px 0; }
.opc-card p { font-size:12px; line-height:1.8; color:#475569; margin:0 0 10px; }
.opc-quote { font-size:12px; color:var(--primary); font-style:italic; border-left:2px solid var(--primary); padding-left:9px; margin-bottom:10px; }
.opc-foot { display:flex; justify-content:space-between; align-items:center; font-size:11px; color:var(--muted); border-top:1px dashed var(--line); padding-top:8px; }
.opc-foot a { color:var(--primary); text-decoration:none; font-weight:600; }
/* 协同 */
.synergy-cols { display:grid; grid-template-columns:1fr 70px 1fr; gap:10px; align-items:stretch; }
.synergy-col { background:var(--surface); border:1px solid var(--line); border-radius:12px; padding:14px; }
.synergy-col h3 { margin:0 0 12px; font-size:15px; }
.synergy-col h3 small { font-size:10px; color:var(--muted); font-weight:400; }
.synergy-col.human { border-top:3px solid #2563eb; }
.synergy-col.ai { border-top:3px solid #0d9488; }
.syn-row { padding:7px 0; border-bottom:1px dashed var(--line); font-size:12px; }
.syn-row:last-child { border-bottom:none; }
.syn-row b { display:block; color:var(--primary); margin-bottom:2px; }
.synergy-col.ai .syn-row b { color:var(--teal); }
.syn-row span { color:#475569; line-height:1.6; }
.synergy-mid { display:flex; flex-direction:column; align-items:center; justify-content:center; }
.syn-plus { font-size:30px; color:var(--muted); }
.syn-formula { text-align:center; font-size:12px; font-weight:700; color:var(--primary); line-height:1.5; }
.syn-boundary { margin-top:14px; background:rgba(217,119,6,.12); color:#92400e; padding:11px 14px; border-radius:8px; font-size:12px; line-height:1.75; }
.syn-cases { background:var(--surface); border-radius:12px; overflow:hidden; }
/* 共生 */
.life-cols { display:grid; grid-template-columns:1fr 1fr; gap:12px; }
.life-card { background:var(--surface); border:1px solid var(--line); border-radius:12px; padding:15px; }
.life-card h3 { margin:0 0 10px; font-size:15px; }
.life-card h3 small { font-size:10px; color:var(--muted); font-weight:400; }
.life-card.carbon { border-top:3px solid #d97706; }
.life-card.silicon { border-top:3px solid #7c3aed; }
.life-card ul { margin:0; padding-left:18px; }
.life-card li { font-size:12px; line-height:1.85; color:#475569; margin-bottom:5px; }
.sym-qs { display:flex; flex-direction:column; gap:8px; }
.sym-q { background:var(--surface); border:1px solid var(--line); border-radius:10px; overflow:hidden; }
.sym-q-head { width:100%; display:flex; align-items:center; gap:10px; text-align:left; background:transparent; border:none; padding:12px 14px; cursor:pointer; font-size:13px; color:var(--text); }
.sym-q-no { flex:none; font-weight:700; color:var(--purple); }
.sym-toggle { margin-left:auto; font-size:11px; color:var(--muted); }
.sym-q-body { padding:0 14px 13px 44px; font-size:12.5px; line-height:1.85; color:#475569; }
.sym-motto { margin-top:14px; text-align:center; font-size:13px; font-weight:600; color:var(--primary); background:rgba(37,99,235,.05); padding:12px; border-radius:8px; }
/* 视频 */
.video-grid { display:grid; grid-template-columns:repeat(auto-fill,minmax(280px,1fr)); gap:12px; }
.video-card { display:flex; align-items:center; gap:12px; background:var(--surface); border:1px solid var(--line); border-radius:12px; padding:14px; text-decoration:none; color:var(--text); transition:.2s; }
.video-card:hover { box-shadow:0 8px 24px rgba(30,64,175,.1); transform:translateY(-2px); }
.video-play { flex:none; width:40px; height:40px; border-radius:50%; background:linear-gradient(135deg,#dc2626,#f87171); color:#fff; display:flex; align-items:center; justify-content:center; font-size:14px; }
.video-info { flex:1; min-width:0; }
.video-info h3 { margin:0 0 6px; font-size:13px; }
.video-meta { display:flex; gap:8px; align-items:center; font-size:11px; color:var(--muted); }
.video-go { color:var(--primary); font-size:16px; }
@media (max-width:720px){
  .synergy-cols,.life-cols { grid-template-columns:1fr; }
  .synergy-mid { flex-direction:row; gap:12px; }
  .fut-hero-stats { gap:16px; }
}

/* ====== 工具链 · Skill ====== */
.chain-hero { background:linear-gradient(125deg,#f0edff 0%,#eef4ff 48%,#ecfdf5 100%); border-color:#e2dcff; }
.chain-hero h2 { background:linear-gradient(90deg,#7c3aed,#2563eb,#0d9488); -webkit-background-clip:text; background-clip:text; color:transparent; }
.syn-tochain { margin-top:14px; background:rgba(13,148,136,.08); border-left:3px solid var(--teal); padding:10px 14px; border-radius:8px; font-size:12px; color:var(--teal); line-height:1.7; }
.syn-tochain-btn { cursor:pointer; transition:background .2s,transform .2s; }
.syn-tochain-btn:hover { background:rgba(13,148,136,.16); transform:translateX(3px); }
.chain-flow { display:flex; align-items:stretch; gap:0; flex-wrap:wrap; margin:6px 0 14px; }
.chain-step { flex:1; min-width:120px; background:var(--surface); border:1px solid var(--line); border-top:3px solid var(--step-color); border-radius:12px; padding:14px 10px; text-align:center; }
.chain-ico { width:38px; height:38px; margin:0 auto 8px; border-radius:10px; background:var(--step-color); color:#fff; display:flex; align-items:center; justify-content:center; font-size:18px; }
.chain-step-name { font-size:15px; font-weight:700; color:var(--text); }
.chain-step-en { font-size:10px; color:var(--muted); margin-top:3px; }
.chain-arrow { display:flex; align-items:center; padding:0 6px; color:var(--amber); font-size:20px; font-weight:700; }
.chain-relation { background:linear-gradient(120deg,#eef4ff,#ecfdf5); border:1px solid #dbe7ff; border-radius:10px; padding:12px 15px; font-size:12.5px; line-height:1.85; color:#475569; }
.chain-cards { display:grid; grid-template-columns:repeat(auto-fill,minmax(320px,1fr)); gap:12px; }
.chain-card { background:var(--surface); border:1px solid var(--line); border-left:4px solid var(--primary); border-radius:12px; padding:14px; }
.chain-card-head { display:flex; gap:10px; align-items:center; margin-bottom:10px; }
.chain-badge { flex:none; width:28px; height:28px; border-radius:8px; color:#fff; display:flex; align-items:center; justify-content:center; font-weight:700; font-size:13px; }
.chain-card h3 { margin:0; font-size:14px; }
.chain-card h3 small { font-size:10px; color:var(--muted); font-weight:400; }
.chain-role { font-size:11px; color:var(--teal); margin-top:2px; }
.chain-card p { margin:0 0 10px; font-size:12px; line-height:1.8; color:#475569; }
.chain-example { font-size:11.5px; background:rgba(37,99,235,.06); color:var(--primary); padding:8px 10px; border-radius:7px; line-height:1.7; margin-bottom:8px; }
.chain-limit { font-size:11px; color:#92400e; background:rgba(217,119,6,.1); padding:7px 10px; border-radius:7px; line-height:1.6; }
.skill-grid { display:grid; grid-template-columns:repeat(auto-fill,minmax(320px,1fr)); gap:12px; }
.skill-group { background:var(--surface); border:1px solid var(--line); border-top:3px solid var(--primary); border-radius:12px; padding:14px; }
.skill-group h3 { margin:0 0 10px; font-size:14px; display:flex; align-items:center; gap:6px; }
.skill-count { margin-left:auto; font-size:10px; color:var(--muted); font-weight:400; }
.skill-items { display:flex; flex-direction:column; gap:7px; }
.skill-item { font-size:11.5px; line-height:1.6; padding:6px 9px; background:var(--soft); border-radius:7px; }
.skill-item b { color:var(--text); margin-right:6px; }
.skill-item span { color:var(--muted); }
.skill-note { margin-top:14px; font-size:11.5px; line-height:1.8; color:var(--muted); background:var(--soft); border-radius:8px; padding:11px 14px; }
@media (max-width:720px){ .chain-arrow{display:none} .chain-step{min-width:46%} }

/* ====== 学习评价与诊断 · 分层干预 ====== */
.ev-layers { display:grid; grid-template-columns:repeat(auto-fit,minmax(240px,1fr)); gap:12px; padding:16px 18px 18px; }
.ev-layer { background:var(--surface); border:1px solid var(--line); border-left:4px solid var(--lay-color); border-radius:12px; padding:14px; }
.ev-layer-h { display:flex; align-items:center; gap:8px; margin-bottom:8px; }
.ev-layer-dot { width:10px; height:10px; border-radius:50%; background:var(--lay-color); flex:none; }
.ev-layer-h b { font-size:15px; color:var(--lay-color); }
.ev-layer-n { margin-left:auto; font-size:12px; font-weight:600; color:var(--text); background:var(--soft); padding:2px 10px; border-radius:20px; }
.ev-layer-rule { font-size:11px; color:var(--muted); margin-bottom:9px; padding-bottom:8px; border-bottom:1px dashed var(--line); }
.ev-layer-strat { font-size:12px; line-height:1.75; color:#475569; margin-bottom:9px; }
.ev-layer-names { font-size:11px; line-height:1.7; color:var(--muted); background:var(--soft); border-radius:7px; padding:7px 9px; }
@media (max-width:720px){ .ev-layers{grid-template-columns:1fr} }

/* ====== 学练评诊 · 模块地图 ====== */
.map-card { margin-bottom:16px; border:1px solid var(--line); border-radius:12px; background:var(--surface); overflow:hidden; }
.map-card > summary { cursor:pointer; padding:12px 16px; font-weight:600; color:var(--primary); list-style:none; display:flex; align-items:center; gap:8px; font-size:13px; }
.map-card > summary::-webkit-details-marker { display:none; }
.map-card > summary::before { content:'▸'; color:var(--muted); font-size:12px; }
.map-card[open] > summary::before { content:'▾'; }
.map-grid { display:grid; grid-template-columns:repeat(4,1fr); gap:12px; padding:0 16px 10px; }
.map-col { border:1px solid var(--line); border-top:3px solid var(--mc); border-radius:10px; padding:12px; background:var(--soft); }
.map-col h4 { margin:0 0 8px; font-size:13px; color:var(--mc); }
.map-col ul { margin:0; padding-left:16px; }
.map-col li { font-size:11.5px; line-height:1.9; color:var(--text); }
.map-note { margin:2px 16px 14px; padding:10px 12px; border-radius:8px; background:rgba(217,119,6,.09); color:#92400e; font-size:11.5px; line-height:1.85; }
@media (max-width:900px){ .map-grid{grid-template-columns:repeat(2,1fr);} }
@media (max-width:560px){ .map-grid{grid-template-columns:1fr;} }

/* —— 课堂计时器 —— */
@keyframes tmFlash { 0%, 100% { background: #0f172a; } 50% { background: #451a2e; } }
#tmBoard.tm-done { animation: tmFlash .5s ease 6; }
#tmBoard:fullscreen { display: flex; flex-direction: column; justify-content: center; border-radius: 0; }
#tmBoard:fullscreen #tmDisp { font-size: 18vh; }
#tmBoard:fullscreen #tmSub { font-size: 2.6vh; }

/* —— 3-2-1 词云（知识点 / 存疑 / 期待 三分区）—— */
#i32Cloud { display: grid; grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)); gap: 14px; }
.i32-cloud-sec { position: relative; border-radius: 14px; background: linear-gradient(180deg, #fbfdff, #eef4fb); overflow: hidden; padding: 10px 12px 8px; border: 1px solid rgba(46, 108, 181, .10); }
.i32-cloud-sec.span { grid-column: 1 / -1; }
.i32-cloud-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap; margin: 2px 2px 6px; }
.i32-cloud-head .ttl { font-weight: 700; font-size: 14.5px; }
.i32-cloud-head .ttl small { font-weight: 400; color: var(--muted); font-size: 12px; margin-left: 4px; }
.i32-cloud-head .sub { font-size: 12px; color: var(--muted); }
.i32-cloud-box { position: relative; height: 340px; overflow: hidden; }
.i32-cloud-sec.span .i32-cloud-box { height: 460px; }
.cloud-word { position: absolute; white-space: nowrap; cursor: pointer; font-weight: 700; letter-spacing: .5px; user-select: none; line-height: 1.05; }
.cloud-word:hover { text-shadow: 0 0 1px currentColor; }

/* ===== 作品附件（图片全屏 / 文档卡片） ===== */
.wk-imgbox { display: inline-block; max-width: 100%; border-radius: 8px; overflow: hidden; cursor: zoom-in;
  background: #f1f5f9; line-height: 0; }
.wk-imgbox .wk-img { max-width: 100%; border-radius: 8px; display: block; transition: transform .18s ease; }
.wk-imgbox:hover .wk-img { transform: scale(1.01); }
.wk-imghint { font-size: 11px; color: var(--muted); margin: 4px 0 2px; }

.wk-file { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: inherit;
  border: 1px solid var(--line); background: #fff; border-radius: 10px; padding: 10px 12px; margin: 8px 0;
  max-width: 100%; transition: border-color .15s, box-shadow .15s; }
.wk-file:hover { border-color: var(--primary); box-shadow: 0 2px 10px rgba(47,107,255,.12); }
.wk-file-ico { font-size: 22px; line-height: 1; }
.wk-file-main { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.wk-file-main b { font-size: 13.5px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wk-file-sub { font-size: 11.5px; color: var(--muted); }
.wk-file-go { color: var(--primary); font-size: 14px; margin-left: 4px; }
.wk-file.disabled { color: var(--muted); cursor: default; background: #f8fafc; border-style: dashed; }
.wk-broken { font-size: 12.5px; color: var(--muted); background: #f8fafc; border: 1px dashed var(--line);
  border-radius: 8px; padding: 10px 12px; display: inline-block; }

.ui-lightbox { position: fixed; inset: 0; background: rgba(9, 13, 22, .88); display: none;
  align-items: center; justify-content: center; z-index: 3000; padding: 24px; cursor: zoom-out;
  backdrop-filter: blur(2px); }
.ui-lightbox.on { display: flex; }
.ui-lightbox .ulb-stage { max-width: 100%; max-height: 100%; display: flex; align-items: center; justify-content: center; }
.ui-lightbox .ulb-stage img { max-width: 96vw; max-height: 92vh; border-radius: 10px;
  box-shadow: 0 18px 60px rgba(0, 0, 0, .5); background: #fff; }
.ui-lightbox .ulb-close { position: absolute; top: 14px; right: 18px; width: 40px; height: 40px;
  border-radius: 50%; border: none; background: rgba(255, 255, 255, .16); color: #fff; font-size: 24px;
  line-height: 1; cursor: pointer; }
.ui-lightbox .ulb-close:hover { background: rgba(255, 255, 255, .3); }
.ui-lightbox .ulb-tip { position: absolute; bottom: 16px; left: 0; right: 0; text-align: center;
  color: rgba(255, 255, 255, .6); font-size: 12px; pointer-events: none; }

@media (max-width: 560px) {
  .ui-lightbox { padding: 10px; }
  .ui-lightbox .ulb-stage img { max-width: 100vw; max-height: 86vh; }
  .wk-file { width: 100%; }
}
