/* ============================================================
   成绩分析通 - 全局样式
   ============================================================ */
:root {
  --primary: #2563eb;
  --primary-dark: #1d4ed8;
  --primary-light: #dbeafe;
  --bg: #f1f5f9;
  --card: #ffffff;
  --text: #1e293b;
  --muted: #64748b;
  --border: #e2e8f0;
  --green: #16a34a;
  --green-bg: #dcfce7;
  --red: #dc2626;
  --red-bg: #fee2e2;
  --amber: #d97706;
  --amber-bg: #fef3c7;
  --violet: #7c3aed;
  --shadow: 0 1px 3px rgba(15, 23, 42, .08), 0 1px 2px rgba(15, 23, 42, .04);
  --shadow-lg: 0 10px 30px rgba(15, 23, 42, .14);
  --radius: 10px;
  --topbar-h: 58px;
  --sidebar-w: 240px;
  --sidebar-collapsed-w: 40px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html, body { height: 100%; }

body {
  font-family: "PingFang SC", "Microsoft YaHei", "Segoe UI", "Noto Sans CJK SC", sans-serif;
  background: var(--bg);
  color: var(--text);
  font-size: 14px;
  line-height: 1.55;
}

button, input, select { font-family: inherit; font-size: inherit; color: inherit; }
button { cursor: pointer; }

/* ---------------- 顶部导航 ---------------- */
#topbar {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  gap: 16px;
  height: var(--topbar-h);
  padding: 0 16px;
  background: var(--card);
  border-bottom: 1px solid var(--border);
  box-shadow: var(--shadow);
}

.brand {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 17px;
  font-weight: 700;
  color: var(--primary);
  cursor: pointer;
  white-space: nowrap;
  user-select: none;
}
.brand-icon { font-size: 22px; }

/* 返回工具箱：左上角，灰浅色、简洁不喧宾夺主 */
.back-home {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 6px 9px;
  border-radius: 8px;
  color: #94a3b8;
  font-size: 13px;
  text-decoration: none;
  white-space: nowrap;
  transition: color .15s, background .15s;
}
.back-home:hover {
  color: #475569;
  background: #f1f5f9;
}

#exam-switch {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  flex: 1;
}
.switch-label { color: var(--muted); font-size: 13px; white-space: nowrap; }
#exam-switch select {
  max-width: 320px;
  min-width: 160px;
  padding: 6px 10px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--card);
  font-size: 14px;
}

.top-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  padding: 7px 14px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--card);
  color: var(--text);
  font-weight: 500;
  white-space: nowrap;
  transition: background .15s, border-color .15s, box-shadow .15s;
}
.btn:hover { background: #f8fafc; border-color: #cbd5e1; }
.btn:active { transform: translateY(1px); }

.btn-primary {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
}
.btn-primary:hover { background: var(--primary-dark); border-color: var(--primary-dark); }

.btn-danger { background: var(--red); border-color: var(--red); color: #fff; }
.btn-danger:hover { background: #b91c1c; border-color: #b91c1c; }

.btn-ghost { background: transparent; border-color: transparent; color: var(--muted); }
.btn-ghost:hover { background: #f1f5f9; color: var(--text); }

.btn-sm { padding: 4px 10px; font-size: 13px; border-radius: 6px; }

.caret { font-size: 11px; }

.icon-btn {
  border: none;
  background: transparent;
  color: var(--muted);
  font-size: 15px;
  width: 26px;
  height: 26px;
  border-radius: 6px;
  line-height: 1;
}
.icon-btn:hover { background: var(--primary-light); color: var(--primary); }

#rate-toggle-wrap {
  display: flex;
  align-items: center;
  gap: 6px;
}
.rate-toggle-label { color: var(--muted); font-size: 13px; }
#rate-mode {
  padding: 5px 8px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--card);
}

/* ---------------- 下拉菜单 ---------------- */
.dropdown { position: relative; }
.dropdown-menu {
  display: none;
  position: absolute;
  right: 0;
  top: calc(100% + 6px);
  min-width: 210px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 10px;
  box-shadow: var(--shadow-lg);
  padding: 6px;
  z-index: 200;
}
.dropdown-menu.show { display: block; }
.dropdown-menu .menu-group {
  padding: 6px 10px 3px;
  font-size: 12px;
  color: var(--muted);
}
.dropdown-menu button {
  display: block;
  width: 100%;
  text-align: left;
  padding: 8px 10px;
  border: none;
  background: transparent;
  border-radius: 7px;
  font-size: 14px;
}
.dropdown-menu button:hover { background: var(--primary-light); color: var(--primary); }

/* ---------------- 整体布局 ---------------- */
#layout { display: flex; min-height: calc(100vh - var(--topbar-h)); }

.sidebar {
  width: var(--sidebar-w);
  flex-shrink: 0;
  background: var(--card);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  transition: width .2s ease, margin .2s ease;
  overflow: hidden;
}
.sidebar.collapsed { width: var(--sidebar-collapsed-w); }

/* 展开态内容（正常展示考试列表） */
.sidebar-main {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-width: 0;
  height: 100%;
}
.sidebar.collapsed .sidebar-main { display: none; }

/* 收起后的 40px 细条：☰ 在上，竖排“考试列表”在下 */
.sidebar-collapsed-bar {
  display: none;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  width: var(--sidebar-collapsed-w);
  height: 100%;
  padding: 16px 0;
  cursor: pointer;
  user-select: none;
  transition: background .15s, color .15s;
}
.sidebar.collapsed .sidebar-collapsed-bar { display: flex; }
.sidebar-collapsed-bar:hover { background: var(--primary-light); }
.sidebar-collapsed-bar:hover .scb-text { color: var(--primary); }

.sidebar-collapsed-bar .scb-icon {
  font-size: 19px;
  color: var(--primary);
  line-height: 1;
}
.sidebar-collapsed-bar .scb-text {
  writing-mode: vertical-rl;
  text-orientation: upright;
  letter-spacing: 8px;
  font-size: 14px;
  font-weight: 600;
  color: var(--muted);
}

.sidebar-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 14px 10px;
  font-weight: 600;
  white-space: nowrap;
}

#exam-list { flex: 1; overflow-y: auto; padding: 0 8px 8px; }

.exam-item {
  position: relative;
  padding: 10px 10px 10px 12px;
  margin-bottom: 4px;
  border-radius: 8px;
  cursor: pointer;
  border: 1px solid transparent;
  white-space: normal;
}
.exam-item:hover { background: #f8fafc; }
.exam-item.active {
  background: var(--primary-light);
  border-color: #bfdbfe;
}
.exam-item .exam-name {
  font-weight: 600;
  font-size: 13.5px;
  margin-bottom: 4px;
  padding-right: 26px;
  word-break: break-all;
}
.exam-item .exam-meta {
  font-size: 12px;
  color: var(--muted);
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.exam-item .exam-actions {
  position: absolute;
  top: 8px;
  right: 6px;
  display: flex;
  gap: 2px;
  opacity: 0;
  transition: opacity .15s;
}
.exam-item:hover .exam-actions { opacity: 1; }
.exam-item .exam-actions .icon-btn { width: 22px; height: 22px; font-size: 13px; }

.sidebar-foot {
  padding: 10px 14px 14px;
  border-top: 1px dashed var(--border);
  font-size: 12px;
  color: var(--muted);
  white-space: normal;
}
.sidebar-foot p { margin-bottom: 4px; }

#main { flex: 1; min-width: 0; display: flex; flex-direction: column; }

#tabs {
  display: flex;
  gap: 4px;
  padding: 10px 16px 0;
  background: var(--card);
  border-bottom: 1px solid var(--border);
  overflow-x: auto;
}
.tab {
  padding: 9px 16px;
  border: none;
  background: transparent;
  color: var(--muted);
  font-weight: 500;
  border-bottom: 2px solid transparent;
  white-space: nowrap;
}
.tab:hover { color: var(--text); }
.tab.active { color: var(--primary); border-bottom-color: var(--primary); font-weight: 600; }

#content { padding: 18px 20px 40px; max-width: 1400px; width: 100%; margin: 0 auto; }

/* ---------------- 通用组件 ---------------- */
.muted { color: var(--muted); }
.small { font-size: 12.5px; }
.center { text-align: center; }
.flex-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.spacer { flex: 1; }
.mt { margin-top: 16px; }
.mt-sm { margin-top: 8px; }
.mb { margin-bottom: 16px; }
.hidden { display: none !important; }

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 16px;
  margin-bottom: 16px;
}
.card-title {
  font-size: 15.5px;
  font-weight: 700;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.card-title .title-desc { font-size: 12.5px; color: var(--muted); font-weight: 400; }

.banner {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 9px;
  font-size: 13.5px;
  margin-bottom: 14px;
}
.banner-warn { background: var(--amber-bg); color: #92400e; border: 1px solid #fcd34d; }
.banner-info { background: var(--primary-light); color: #1e40af; border: 1px solid #bfdbfe; }
.banner-error { background: var(--red-bg); color: #991b1b; border: 1px solid #fca5a5; }
.banner button { border: none; background: transparent; color: inherit; font-weight: 700; text-decoration: underline; }

/* 统计卡片 */
.stat-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 12px;
  margin-bottom: 16px;
}
.stat-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 14px 16px;
}
.stat-card .stat-label { font-size: 13px; color: var(--muted); margin-bottom: 6px; }
.stat-card .stat-value { font-size: 24px; font-weight: 700; color: var(--text); }
.stat-card .stat-value.primary { color: var(--primary); }
.stat-card .stat-value.green { color: var(--green); }
.stat-card .stat-value.red { color: var(--red); }

/* 表格 */
.table-wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: 9px; }
table.data-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--card);
  font-size: 13.5px;
}
.data-table th, .data-table td {
  padding: 8px 10px;
  border-bottom: 1px solid var(--border);
  text-align: center;
  white-space: nowrap;
}
.data-table thead th {
  position: sticky;
  top: 0;
  background: #f8fafc;
  color: #475569;
  font-weight: 600;
  font-size: 13px;
  z-index: 2;
}
.data-table tbody tr:hover { background: #f8fafc; }
.data-table tbody tr:nth-child(even) { background: #fbfdff; }
.data-table tbody tr:nth-child(even):hover { background: #f1f5f9; }
.data-table .num { font-variant-numeric: tabular-nums; }
.data-table .left { text-align: left; }
.data-table th.sortable { cursor: pointer; user-select: none; }
.data-table th.sortable:hover { color: var(--primary); }
.data-table th .sort-mark { font-size: 10px; margin-left: 3px; color: var(--primary); }
.data-table .clickable { color: var(--primary); cursor: pointer; font-weight: 600; }
.data-table .clickable:hover { text-decoration: underline; }
.data-table .rank-1 { color: var(--amber); font-weight: 700; }
.data-table td.right { text-align: right; }

.table-toolbar {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 10px;
}
.table-toolbar input[type="text"], .table-toolbar select {
  padding: 6px 10px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--card);
}

/* 标签 */
.badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
}
.badge-on { background: var(--green-bg); color: var(--green); }
.badge-off { background: #e2e8f0; color: #64748b; }

/* 图表容器 */
.chart-box { width: 100%; height: 320px; }
.chart-box.sm { height: 260px; }
.chart-box.lg { height: 400px; }

/* 表单 */
.form-row { margin-bottom: 14px; }
.form-label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 6px; color: #334155; }
.form-input, .form-select {
  width: 100%;
  padding: 8px 11px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--card);
}
.form-input:focus, .form-select:focus { outline: 2px solid var(--primary-light); border-color: var(--primary); }
.form-check { display: inline-flex; align-items: center; gap: 6px; font-size: 13.5px; }
.form-check input { accent-color: var(--primary); width: 16px; height: 16px; }

/* 模态框 */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, .45);
  z-index: 300;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px;
  animation: fadeIn .15s ease;
}
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

.modal {
  background: var(--card);
  border-radius: 14px;
  box-shadow: var(--shadow-lg);
  width: 100%;
  max-width: 640px;
  max-height: 88vh;
  display: flex;
  flex-direction: column;
  animation: slideUp .18s ease;
}
@keyframes slideUp { from { transform: translateY(14px); opacity: .5; } to { transform: none; opacity: 1; } }

.modal.modal-wide { max-width: 1100px; }
.modal.modal-lg { max-width: 900px; }

.modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 15px 18px;
  border-bottom: 1px solid var(--border);
}
.modal-head h3 { font-size: 16px; }
.modal-close {
  border: none;
  background: transparent;
  font-size: 22px;
  line-height: 1;
  color: var(--muted);
  width: 30px;
  height: 30px;
  border-radius: 7px;
}
.modal-close:hover { background: var(--red-bg); color: var(--red); }

.modal-body { padding: 18px; overflow-y: auto; }
.modal-foot {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  padding: 13px 18px;
  border-top: 1px solid var(--border);
  background: #fafbfc;
  border-radius: 0 0 14px 14px;
}

.confirm-msg { font-size: 14.5px; padding: 6px 0; }

/* Toast */
#toast-root {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 500;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.toast {
  padding: 11px 16px;
  border-radius: 10px;
  background: #1e293b;
  color: #fff;
  box-shadow: var(--shadow-lg);
  font-size: 13.5px;
  max-width: 380px;
  animation: slideUp .2s ease;
}
.toast-ok { background: var(--green); }
.toast-error { background: var(--red); }
.toast-info { background: #1e293b; }

/* ---------------- 首页 ---------------- */
.home-hero {
  text-align: center;
  padding: 44px 16px 26px;
}
.home-hero h1 { font-size: 28px; margin-bottom: 10px; }
.home-hero p { color: var(--muted); font-size: 15px; max-width: 640px; margin: 0 auto 22px; }
.home-hero .hero-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.home-hero .btn { padding: 11px 22px; font-size: 15px; }

.drop-zone {
  border: 2px dashed #cbd5e1;
  border-radius: 14px;
  background: var(--card);
  padding: 40px 20px;
  text-align: center;
  cursor: pointer;
  transition: border-color .15s, background .15s;
  margin-bottom: 26px;
}
.drop-zone:hover, .drop-zone.dragover { border-color: var(--primary); background: #eff6ff; }
.drop-zone .dz-icon { font-size: 42px; margin-bottom: 8px; }
.drop-zone .dz-title { font-size: 16px; font-weight: 600; margin-bottom: 6px; }
.drop-zone .dz-sub { color: var(--muted); font-size: 13px; }

.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 12px;
}
.feature-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
}
.feature-card .fc-icon { font-size: 24px; margin-bottom: 8px; }
.feature-card .fc-title { font-weight: 600; margin-bottom: 5px; }
.feature-card .fc-desc { font-size: 12.5px; color: var(--muted); }

/* ---------------- 分数线设置 ---------------- */
.th-table .th-input {
  width: 90px;
  padding: 6px 8px;
  border: 1px solid var(--border);
  border-radius: 7px;
  text-align: center;
}
.th-table .th-input:focus { outline: 2px solid var(--primary-light); border-color: var(--primary); }
.th-row-actions { display: flex; gap: 5px; }
.batch-panel {
  background: #f8fafc;
  border: 1px dashed #cbd5e1;
  border-radius: 9px;
  padding: 12px;
  margin-top: 12px;
}
.batch-panel .bp-title { font-weight: 600; margin-bottom: 8px; font-size: 13.5px; }
.batch-subjects { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 10px; }
.batch-subjects label { display: inline-flex; align-items: center; gap: 4px; font-size: 13px; }
.batch-subjects input { accent-color: var(--primary); }

/* ---------------- 分数段 ---------------- */
.seg-editor { display: flex; gap: 10px; align-items: flex-end; flex-wrap: wrap; }
.seg-editor .form-row { margin-bottom: 0; min-width: 180px; }
.seg-editor input { min-width: 240px; }

/* ---------------- 跨考试对比 ---------------- */
.trend-toolbar { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 10px; }
.trend-toolbar select, .trend-toolbar input {
  padding: 6px 10px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--card);
}

  .trend-up { color: #00B42A; font-weight: 700; }
  .trend-down { color: #F53F3F; font-weight: 700; }
.trend-flat { color: var(--muted); }

/* 跨考试对比：两大核心选项 Tab */
.xex-tabs {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 14px;
  margin-bottom: 18px;
}
.xex-tab {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 18px 16px;
  border: 2px solid var(--border);
  border-radius: 14px;
  background: var(--card);
  color: var(--muted);
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  transition: all .15s;
  box-shadow: var(--shadow);
}
.xex-tab:hover { border-color: var(--primary); color: var(--primary); }
.xex-tab.active {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
  box-shadow: 0 6px 18px rgba(37, 99, 235, .35);
}
.xex-tab-icon { font-size: 26px; }

/* 学生个体分析搜索区 */
.student-search { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.student-search input {
  flex: 1;
  min-width: 240px;
  padding: 11px 14px;
  border: 2px solid var(--border);
  border-radius: 10px;
  font-size: 15px;
}
.student-search input:focus { outline: none; border-color: var(--primary); }
.btn-lg { padding: 11px 20px; font-size: 15px; }

/* ---------------- 学生明细 ---------------- */
.student-scores { display: flex; flex-wrap: wrap; gap: 8px; margin: 6px 0 10px; }
.score-chip {
  padding: 6px 12px;
  border-radius: 8px;
  background: #f1f5f9;
  font-size: 13px;
}
.score-chip b { color: var(--primary); }

/* ---------------- PDF 报告容器 ---------------- */
.pdf-report {
  position: fixed;
  left: 0;
  top: 0;
  width: 860px;
  background: #fff;
  color: #111;
  padding: 24px;
  z-index: -1;
  opacity: 0;
  pointer-events: none;
}
.pdf-report.show { z-index: 9999; opacity: 1; pointer-events: auto; }
.pdf-report h1 { font-size: 20px; margin-bottom: 4px; }
.pdf-report h2 { font-size: 15px; margin: 18px 0 8px; border-left: 4px solid var(--primary); padding-left: 8px; }
.pdf-report table { width: 100%; border-collapse: collapse; font-size: 12px; margin-bottom: 8px; }
.pdf-report th, .pdf-report td { border: 1px solid #cbd5e1; padding: 5px 7px; text-align: center; }
.pdf-report th { background: #f1f5f9; }
.pdf-report .chart-box { height: 280px; }

/* ---------------- 滚动条 ---------------- */
::-webkit-scrollbar { width: 9px; height: 9px; }
::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 6px; }
::-webkit-scrollbar-thumb:hover { background: #94a3b8; }
::-webkit-scrollbar-track { background: transparent; }

/* ---------------- 响应式 ---------------- */
@media (max-width: 1100px) {
  .sidebar { width: 230px; }
  .sidebar.collapsed { width: var(--sidebar-collapsed-w); }
}

@media (max-width: 900px) {
  .sidebar {
    position: fixed;
    left: 0;
    top: var(--topbar-h);
    bottom: 0;
    z-index: 150;
    box-shadow: var(--shadow-lg);
  }
  .sidebar.collapsed { margin-left: 0; box-shadow: none; }
  body.sidebar-collapsed #main { margin-left: var(--sidebar-collapsed-w); }
  #topbar { flex-wrap: wrap; height: auto; padding: 8px 12px; gap: 8px; }
  #exam-switch { flex: 1 1 100%; order: 3; }
  #content { padding: 14px 12px 32px; }
  .brand-text { display: none; }
  .top-actions .btn { padding: 6px 10px; }
}

@media (max-width: 600px) {
  .stat-cards { grid-template-columns: repeat(2, 1fr); }
  .home-hero h1 { font-size: 22px; }
  .modal { max-height: 94vh; }
  .chart-box { height: 260px; }
  .back-home { font-size: 12px; padding: 4px 6px; }
  .top-actions #btn-import { font-size: 13px; }
  .xex-tabs { gap: 8px; }
  .xex-tab { padding: 12px 8px; font-size: 14px; flex-direction: column; gap: 4px; }
  .xex-tab-icon { font-size: 22px; }
}

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
}

/* 右下角下载卡片（自动下载被拦截时的手动保存入口） */
.download-card {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 480;
  display: flex;
  align-items: center;
  gap: 12px;
  max-width: 440px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: var(--shadow-lg);
  padding: 12px 14px;
  animation: slideUp .2s ease;
}
.dc-info { flex: 1; min-width: 0; }
.dc-name { font-weight: 600; font-size: 13.5px; margin-bottom: 2px; word-break: break-all; }
.dc-status { font-size: 12px; color: var(--muted); }
.dc-actions { display: flex; align-items: center; gap: 6px; flex-shrink: 0; }
.dc-open, .dc-close {
  border: none;
  background: transparent;
  color: var(--muted);
  font-size: 16px;
  cursor: pointer;
  width: 28px;
  height: 28px;
  border-radius: 7px;
  line-height: 1;
}
.dc-open:hover, .dc-close:hover { background: #f1f5f9; color: var(--text); }
@media (max-width: 600px) {
  .download-card { left: 12px; right: 12px; max-width: none; align-items: flex-start; }
}