/* ===== 美说阶段性学习报告 · A4 专业印刷工作台 v3.0 UI 样式 ===== */

:root {
  --bg: #f4f5f7;
  --surface: #ffffff;
  --surface-soft: #f8faf9;
  --border: #e2e6e4;
  --border-strong: #cbd2ce;
  --text: #1c2422;
  --text-muted: #5f6c68;
  --primary: #0f766e;
  --primary-hover: #115e59;
  --primary-soft: #e6f4f1;
  --amber: #b45309;
  --amber-soft: #fef3c7;
  --ai-grad: linear-gradient(135deg, #1d4ed8 0%, #4f46e5 100%);
  --positive-bg: #f0fdf4;
  --positive-border: #86efac;
  --positive-text: #166534;
  --positive-active: #15803d;
  --accent: #1d4ed8;
  --danger: #dc2626;
  --danger-soft: #fef2f2;
  --success: #15803d;
  --success-soft: #f0fdf4;
  --radius: 11px;
  --radius-sm: 7px;
  --shadow-sm: 0 1px 3px rgba(15, 23, 42, 0.06);
  --shadow-md: 0 8px 24px rgba(15, 23, 42, 0.09);
  --shadow-lg: 0 20px 50px rgba(15, 23, 42, 0.16);
  --topbar-h: 58px;
}

* { box-sizing: border-box; }
html, body {
  margin: 0; padding: 0; height: 100%; background: var(--bg); color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  font-size: 14px; line-height: 1.5; overflow: hidden;
  display: flex; flex-direction: column;
}
button, input, select, textarea { font-family: inherit; font-size: inherit; }
.hidden { display: none !important; }

/* ===== 登录门禁页 ===== */
.auth-overlay {
  position: fixed; inset: 0; z-index: 300;
  background: linear-gradient(145deg, #f5f3ee 0%, #eef5f3 55%, #f5f6f8 100%);
  display: flex; align-items: center; justify-content: center; padding: 24px;
}
.auth-card {
  width: min(460px, 95vw); background: #ffffff; border-radius: 18px;
  padding: 32px 30px; box-shadow: var(--shadow-lg); border: 1px solid var(--border);
}
.auth-brand { display: flex; align-items: center; gap: 12px; margin-bottom: 8px; }
.auth-brand .brand-badge { width: 42px; height: 42px; font-size: 20px; border-radius: 10px; }
.auth-title { font-size: 20px; font-weight: 800; margin: 0; }
.auth-subtitle { font-size: 13px; color: var(--text-muted); margin: 4px 0 20px 0; }
.auth-tabs {
  display: grid; grid-template-columns: 1fr 1fr; gap: 8px;
  background: var(--surface-soft); padding: 4px; border-radius: 10px; margin-bottom: 18px;
  border: 1px solid var(--border);
}
.auth-tab {
  border: none; background: transparent; padding: 9px 10px; border-radius: 7px;
  font-weight: 600; color: var(--text-muted); cursor: pointer;
}
.auth-tab.active { background: #ffffff; color: var(--primary); box-shadow: var(--shadow-sm); }
.auth-hint {
  margin-top: 14px; padding: 10px 12px; border-radius: 9px;
  background: #f8faf9; border: 1px dashed var(--border-strong);
  font-size: 12px; color: var(--text-muted); line-height: 1.65;
}

/* 顶栏 */
.topbar {
  min-height: var(--topbar-h); flex-shrink: 0; background: var(--surface); border-bottom: 1px solid var(--border);
  padding: 6px 14px; display: flex; align-items: center; justify-content: space-between;
  gap: 8px; flex-wrap: wrap; position: relative; z-index: 40; box-shadow: var(--shadow-sm);
}
.topbar-left, .topbar-center, .topbar-right { display: flex; align-items: center; gap: 7px; }
.brand { display: flex; align-items: center; gap: 8px; font-weight: 700; font-size: 15px; white-space: nowrap; }
.brand-badge {
  width: 30px; height: 30px; border-radius: 8px;
  background: #0f766e; color: #ffffff;
  display: inline-flex; align-items: center; justify-content: center;
  font-family: "Songti SC", "STSong", serif; font-size: 16px; font-weight: 700;
}
.role-pill {
  font-size: 12px; font-weight: 600; padding: 3px 10px; border-radius: 999px;
  background: var(--primary-soft); border: 1px solid #99d5cc; color: var(--primary-hover); white-space: nowrap;
}
.role-pill.principal { background: #fef3c7; border-color: #fcd34d; color: #92400e; }

.status-pill {
  font-size: 12px; padding: 3px 10px; border-radius: 999px;
  background: var(--surface-soft); border: 1px solid var(--border); color: var(--text-muted); white-space: nowrap;
}
.status-pill.saved { background: var(--success-soft); border-color: #bbf7d0; color: #15803d; }
.status-pill.dirty { background: var(--amber-soft); border-color: #fcd34d; color: #92400e; }

.template-select {
  height: 32px; width: 195px; max-width: 210px; padding: 0 24px 0 9px;
  border: 1px solid var(--border-strong); border-radius: var(--radius-sm);
  background: var(--surface); color: var(--text); font-size: 12px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; flex-shrink: 1;
}
.title-toggle-pill {
  display: inline-flex; align-items: center; gap: 5px; height: 32px; padding: 0 9px;
  border: 1px solid var(--border-strong); border-radius: var(--radius-sm);
  background: var(--surface-soft); color: var(--text); font-size: 12px; font-weight: 500;
  cursor: pointer; white-space: nowrap; user-select: none;
}
.title-toggle-pill:hover { background: #eef4f2; border-color: #94a3a0; }
.title-toggle-pill input { margin: 0; accent-color: var(--primary); cursor: pointer; }

/* 按钮 */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 5px;
  height: 33px; padding: 0 11px; border-radius: var(--radius-sm);
  border: 1px solid var(--border-strong); background: var(--surface); color: var(--text);
  font-size: 13px; font-weight: 500; cursor: pointer; white-space: nowrap; transition: all 0.14s ease;
}
.btn:hover:not(:disabled) { background: #f1f5f4; border-color: #94a3a0; }
.btn:disabled { opacity: 0.55; cursor: not-allowed; }
.btn-primary { background: var(--primary); border-color: var(--primary); color: #ffffff; font-weight: 600; }
.btn-primary:hover:not(:disabled) { background: var(--primary-hover); border-color: var(--primary-hover); }
.btn-amber { background: #d97706; border-color: #d97706; color: #ffffff; font-weight: 600; }
.btn-amber:hover:not(:disabled) { background: #b45309; border-color: #b45309; }
.btn-accent { background: var(--accent); border-color: var(--accent); color: #ffffff; font-weight: 600; }
.btn-accent:hover:not(:disabled) { background: #1e40af; border-color: #1e40af; }
.btn-ai { background: var(--ai-grad); border-color: #4f46e5; color: #ffffff; font-weight: 600; }
.btn-ai:hover:not(:disabled) { filter: brightness(1.06); }
.btn-success { background: #15803d; border-color: #15803d; color: #ffffff; font-weight: 600; }
.btn-success:hover:not(:disabled) { background: #166534; }
.btn-danger { background: var(--danger-soft); border-color: #fecaca; color: var(--danger); }
.btn-danger:hover:not(:disabled) { background: #fee2e2; border-color: #f87171; }
.btn-ghost { border-color: transparent; background: transparent; color: var(--text-muted); }
.btn-ghost:hover:not(:disabled) { background: #f1f5f4; color: var(--text); }
.btn-sm { height: 28px; padding: 0 9px; font-size: 12px; }

/* 顶部辅助条：班级流水线 / 校长审核条 */
.batch-ribbon, .review-ribbon {
  padding: 8px 16px; display: flex; align-items: center; justify-content: space-between;
  gap: 12px; flex-wrap: wrap; border-bottom: 1px solid var(--border); flex-shrink: 0;
}
.batch-ribbon { background: #fffbeb; border-color: #fde68a; }
.review-ribbon { background: #f0f9f8; border-color: #bae0da; }
.batch-ribbon-info { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.batch-class-badge {
  font-weight: 700; color: #92400e; background: #fef3c7; border: 1px solid #fcd34d;
  padding: 2px 10px; border-radius: 999px; font-size: 13px;
}
.batch-student-list { display: flex; align-items: center; gap: 6px; overflow-x: auto; max-width: 50vw; padding: 2px 0; }
.batch-student-pill {
  padding: 3px 10px; border-radius: 999px; border: 1px solid #fcd34d; background: #ffffff;
  color: #78350f; font-size: 12px; cursor: pointer; white-space: nowrap;
}
.batch-student-pill.done { border-color: #86efac; background: #f0fdf4; color: #166534; }
.batch-student-pill.active { background: #0f766e; border-color: #0f766e; color: #ffffff; font-weight: 600; }
.batch-ribbon-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }

/* 主体分栏（始终保持左 A4 实时预览 + 右侧编辑并排，仅极窄手机 <620px 才上下排列） */
.workspace { display: flex; flex: 1; min-height: 0; overflow: hidden; }

/* 左侧预览区 */
.preview-pane { flex: 1; min-width: 240px; background: #dfe3e8; position: relative; display: flex; flex-direction: column; overflow: hidden; }
.preview-alerts {
  position: absolute; top: 12px; left: 16px; right: 16px; z-index: 25;
  display: flex; flex-wrap: wrap; gap: 8px; pointer-events: none;
}
.alert-badge {
  pointer-events: auto; display: inline-flex; align-items: center; gap: 6px;
  padding: 6px 12px; border-radius: 999px; font-size: 12px; font-weight: 600; box-shadow: var(--shadow-md);
}
.alert-badge.warning { background: #fff7ed; border: 1px solid #fdba74; color: #c2410c; }
.alert-badge.danger { background: #fef2f2; border: 1px solid #fca5a5; color: #b91c1c; }
.alert-badge.info { background: #e6f4f1; border: 1px solid #99d5cc; color: #115e59; }

.canvas-scroll { flex: 1; overflow: auto; display: flex; align-items: flex-start; justify-content: center; padding: 20px 22px 76px 22px; }
.canvas-stage { position: relative; flex-shrink: 0; box-shadow: 0 14px 40px rgba(15, 23, 42, 0.22); border-radius: 6px; background: transparent; }
.canvas-stage > div { transform-origin: top left; }

.preview-toolbar {
  position: absolute; bottom: 14px; left: 50%; transform: translateX(-50%); z-index: 25;
  background: rgba(255, 255, 255, 0.96); backdrop-filter: blur(8px);
  border: 1px solid var(--border); border-radius: 999px; padding: 5px 10px;
  display: flex; align-items: center; gap: 6px; box-shadow: var(--shadow-md);
}
.zoom-label { min-width: 82px; text-align: center; font-size: 12px; font-weight: 600; color: var(--text-muted); white-space: nowrap; }
.toolbar-divider { width: 1px; height: 18px; background: var(--border); margin: 0 2px; }

/* 右侧表单面板 */
.editor-pane { width: clamp(330px, 49%, 700px); min-width: 310px; background: var(--bg); border-left: 1px solid var(--border); overflow-y: auto; padding: 14px 16px 76px 16px; }
.editor-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 14px 16px; margin-bottom: 12px; box-shadow: var(--shadow-sm); }
.editor-card.ai-card { background: linear-gradient(180deg, #f3f6ff 0%, #ffffff 100%); border-color: #c7d2fe; }
.card-header { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 10px; flex-wrap: wrap; }
.card-title { font-size: 15px; font-weight: 700; color: var(--text); display: flex; align-items: center; gap: 7px; }
.mod-num-tag {
  font-size: 11px; font-weight: 700; padding: 2px 7px; border-radius: 4px;
  background: var(--primary-soft); color: var(--primary-hover);
}
.card-subtitle { font-size: 12px; color: var(--text-muted); }

.form-grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.form-grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.field { display: flex; flex-direction: column; gap: 4px; }
.field label { font-size: 12px; font-weight: 600; color: var(--text-muted); }

.input-control, .textarea-control, .select-control {
  width: 100%; border: 1px solid var(--border-strong); border-radius: var(--radius-sm);
  padding: 7px 10px; background: var(--surface); color: var(--text); font-size: 13px;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.input-control:focus, .textarea-control:focus, .select-control:focus {
  outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(15, 118, 110, 0.14);
}
.textarea-control { resize: vertical; min-height: 76px; line-height: 1.55; }

/* 勋章选择器 */
.medal-picker-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(128px, 1fr)); gap: 8px; }
.medal-pick-card {
  border: 1px solid var(--border-strong); border-radius: 9px; padding: 8px 6px;
  background: var(--surface-soft); cursor: pointer; display: flex; flex-direction: column;
  align-items: center; gap: 5px; transition: all 0.14s ease; text-align: center;
}
.medal-pick-card:hover { border-color: var(--primary); background: #f2faf8; }
.medal-pick-card.selected {
  border-color: var(--primary); background: var(--primary-soft);
  box-shadow: 0 0 0 2px rgba(15, 118, 110, 0.15);
}
.medal-pick-thumb {
  width: 48px; height: 48px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
  background: #faf6ee; border: 1px solid #d6b67c; color: #9a6d1f;
  font-family: "Songti SC", serif; font-weight: 700; font-size: 15px; overflow: hidden;
}
.medal-pick-thumb:has(img) {
  width: 58px; height: 58px; border-radius: 0; background: transparent; border: none;
}
.medal-pick-thumb img { width: 100%; height: 100%; object-fit: contain; background: transparent; }
.medal-pick-name { font-size: 12.5px; font-weight: 600; color: var(--text); line-height: 1.3; }

/* 6 维能力编辑器 */
.skills-editor-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.skill-editor-row {
  border: 1px solid var(--border); border-radius: 9px; padding: 8px 10px; background: var(--surface-soft);
  display: flex; flex-direction: column; gap: 6px;
}
.skill-editor-name { font-size: 13px; font-weight: 700; color: var(--text); }
.skill-state-pills { display: flex; gap: 4px; flex-wrap: wrap; }
.state-pill-btn {
  border: 1px solid var(--border-strong); background: #ffffff; border-radius: 6px;
  padding: 3px 7px; font-size: 11px; cursor: pointer; color: var(--text-muted); transition: all 0.12s;
}
.state-pill-btn.active[data-state="star"] { background: #e6f4f1; border-color: #0f766e; color: #115e59; font-weight: 700; }
.state-pill-btn.active[data-state="progress"] { background: #dcfce7; border-color: #16a34a; color: #166534; font-weight: 700; }
.state-pill-btn.active[data-state="steady"] { background: #e0f2fe; border-color: #0284c7; color: #075985; font-weight: 700; }
.state-pill-btn.active[data-state="focus"] { background: #fef3c7; border-color: #d97706; color: #92400e; font-weight: 700; }

/* 作品与口语勾选行 */
.inline-add-row { display: flex; gap: 6px; margin-top: 8px; }
.inline-add-row .input-control { flex: 1; height: 32px; }

/* 话术芯片 */
.chip-group { margin-bottom: 10px; }
.chip-group:last-child { margin-bottom: 0; }
.chip-group-label { font-size: 12px; font-weight: 600; color: var(--text-muted); margin-bottom: 6px; }
.chip-list { display: flex; flex-wrap: wrap; gap: 6px; }
.chip {
  display: inline-flex; align-items: center; gap: 4px; padding: 5px 10px; border-radius: 7px;
  border: 1px solid var(--border-strong); background: var(--surface-soft); color: var(--text);
  font-size: 12.5px; cursor: pointer; user-select: none; transition: all 0.12s ease;
}
.chip:hover { border-color: var(--primary); background: #f0faf8; }
.chip.positive { background: var(--positive-bg); border-color: var(--positive-border); color: var(--positive-text); }
.chip.selected { background: var(--primary); border-color: var(--primary-hover); color: #ffffff; font-weight: 600; }
.chip.positive.selected { background: var(--positive-active); border-color: #166534; color: #ffffff; }
.chip.amber { background: #fffbeb; border-color: #fcd34d; color: #92400e; }
.chip.amber:hover { border-color: #d97706; background: #fef3c7; }
.chip.amber.selected { background: #b45309; border-color: #92400e; color: #ffffff; }

.sub-panel {
  border: 1px solid var(--border); border-radius: 9px; padding: 10px 12px;
  background: var(--surface-soft); margin-top: 10px;
}
.sub-panel-title { font-size: 13px; font-weight: 700; color: var(--text); margin-bottom: 8px; display: flex; justify-content: space-between; align-items: center; }

.section-meta-bar { display: flex; align-items: center; justify-content: space-between; margin-top: 4px; font-size: 12px; color: var(--text-muted); }

/* 弹窗 Modal */
.modal-backdrop {
  position: fixed; inset: 0; background: rgba(15, 23, 42, 0.45); backdrop-filter: blur(2px);
  z-index: 100; display: flex; align-items: center; justify-content: center; padding: 20px;
}
.modal {
  background: var(--surface); border-radius: 15px; width: min(940px, 95vw); max-height: 90vh;
  display: flex; flex-direction: column; box-shadow: var(--shadow-lg); overflow: hidden;
}
.modal.modal-sm { width: min(460px, 95vw); }
.modal.modal-lg { width: min(1120px, 96vw); }
.modal-header { padding: 14px 20px; border-bottom: 1px solid var(--border); display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.modal-title { font-size: 17px; font-weight: 700; margin: 0; }
.modal-body { padding: 16px 20px; overflow-y: auto; flex: 1; }
.modal-footer { padding: 12px 20px; border-top: 1px solid var(--border); display: flex; align-items: center; justify-content: flex-end; gap: 8px; background: var(--surface-soft); }

/* Tabs & 统计卡 */
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--border); margin-bottom: 16px; flex-wrap: wrap; }
.tab-btn { padding: 8px 13px; border: none; border-bottom: 2px solid transparent; background: transparent; color: var(--text-muted); font-weight: 600; cursor: pointer; font-size: 13px; }
.tab-btn.active { color: var(--primary); border-bottom-color: var(--primary); }

.stats-row { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin-bottom: 14px; }
.stat-box { background: var(--surface-soft); border: 1px solid var(--border); border-radius: 10px; padding: 10px 14px; }
.stat-num { font-size: 22px; font-weight: 800; color: var(--text); }
.stat-label { font-size: 12px; color: var(--text-muted); }

/* 表格与卡片 */
.table-scroll { overflow-x: auto; }
.filter-bar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 14px; }
.data-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.data-table th, .data-table td { text-align: left; padding: 9px 10px; border-bottom: 1px solid var(--border); vertical-align: middle; }
.data-table th { background: var(--surface-soft); color: var(--text-muted); font-weight: 600; font-size: 12px; white-space: nowrap; }
.data-table tr:hover td { background: #f8faf9; }

.badge { display: inline-block; padding: 2px 8px; border-radius: 999px; font-size: 11px; font-weight: 600; white-space: nowrap; }
.badge-draft { background: #f1f5f4; color: #475569; }
.badge-completed { background: var(--success-soft); color: #15803d; }
.badge-default { background: var(--primary-soft); color: var(--primary-hover); }
.badge-unreviewed { background: #f1f5f4; color: #64748b; }
.badge-reviewed { background: #dcfce7; color: #15803d; }
.badge-revision { background: #fee2e2; color: #b91c1c; }

.template-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 14px; margin-top: 14px; }
.template-card { border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; background: var(--surface); display: flex; flex-direction: column; }
.template-thumb { width: 100%; height: 220px; object-fit: contain; background: #f1f5f4; border-bottom: 1px solid var(--border); }
.template-info { padding: 10px 12px; display: flex; flex-direction: column; gap: 6px; }
.template-actions { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 4px; }

.medal-admin-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(195px, 1fr)); gap: 12px; margin-top: 14px; }
.medal-admin-card {
  border: 1px solid var(--border); border-radius: 10px; padding: 12px; background: var(--surface);
  display: flex; flex-direction: column; align-items: center; gap: 8px; text-align: center;
}
.medal-admin-preview {
  width: 76px; height: 76px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
  background: #faf6ee; border: 1.5px solid #d6b67c; color: #9a6d1f; font-family: "Songti SC", serif;
  font-size: 24px; font-weight: 700; overflow: hidden;
}
.medal-admin-preview:has(img) {
  width: 84px; height: 84px; border-radius: 0; background: transparent; border: none;
}
.medal-admin-preview img { width: 100%; height: 100%; object-fit: contain; background: transparent; }

.upload-box { border: 2px dashed var(--border-strong); border-radius: var(--radius); padding: 14px; background: var(--surface-soft); }
.admin-form-box { background: var(--surface-soft); border: 1px solid var(--border); border-radius: var(--radius); padding: 14px; margin-bottom: 16px; }

.logo-upload-panel {
  display: flex; align-items: center; gap: 12px; padding: 10px 12px;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm);
}
.logo-preview-box {
  width: 112px; height: 64px; flex-shrink: 0; border-radius: 7px;
  border: 1px dashed var(--border-strong); background: #fafaf9;
  display: flex; align-items: center; justify-content: center; overflow: hidden; padding: 4px;
}
.logo-preview-box img { max-width: 100%; max-height: 100%; object-fit: contain; }
.usage-view-pills { display: inline-flex; gap: 5px; flex-wrap: wrap; }
.usage-teacher-pill {
  display: inline-block; font-size: 11.5px; padding: 2px 7px; margin: 2px 4px 2px 0;
  border-radius: 999px; background: #eef6f4; border: 1px solid #cce3dd; color: #134e4a; white-space: nowrap;
}

.progress-track { width: 100%; height: 10px; background: #e2e6e4; border-radius: 999px; overflow: hidden; margin: 12px 0; }
.progress-fill { height: 100%; background: linear-gradient(90deg, #0f766e, #15803d); width: 0%; transition: width 0.2s ease; }

.toast-container { position: fixed; top: 68px; right: 20px; z-index: 400; display: flex; flex-direction: column; gap: 8px; pointer-events: none; }
.toast { background: #1e293b; color: #ffffff; padding: 10px 16px; border-radius: 9px; font-size: 13px; box-shadow: var(--shadow-md); animation: toastIn 0.2s ease; max-width: 380px; pointer-events: none; }
.toast.success { background: #15803d; }
.toast.error { background: #b91c1c; }
@keyframes toastIn { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: translateY(0); } }

.export-preview-img { width: 100%; max-height: 62vh; object-fit: contain; border: 1px solid var(--border); border-radius: var(--radius-sm); background: #f8faf9; }

@media (max-width: 1120px) {
  .form-grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .skills-editor-grid { grid-template-columns: 1fr; }
}

@media (max-width: 620px) {
  html, body { overflow: auto; display: block; }
  .workspace { flex-direction: column; height: auto !important; overflow: visible; }
  .preview-pane { height: 55vh; min-height: 400px; min-width: 0; }
  .editor-pane { width: 100%; min-width: 0; border-left: none; border-top: 1px solid var(--border); }
  .stats-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
