/* =========================================================
   星月童话 2 · 业务组件
   沿用星悦童话的令牌与外壳，只补这个产品自己的零件
   ========================================================= */

/* ---------------- 基础补丁 ---------------- */

/* 参考 demo 里 .btn-primary 只在 views.css 被引用却没定义，这里补上 */
.btn-primary {
  color: var(--gold-ink);
}

.flow-actions .btn-block {
  flex: 1;
  min-height: 56px;
  font-size: 17px;
}

/* 视图通用间距 */
.record-view,
.plan-view,
.script-view,
.track-view,
.profile-view {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding-bottom: 24px;
}

.fine-print {
  font-size: 11px;
  line-height: 1.7;
  color: var(--muted-2);
  text-align: center;
}

/* .page-head 在参考 demo 里是「标题 + 右侧按钮」的两栏布局，
   本产品的标题区常常有 eyebrow + 标题 + 说明三段，这里改成纵向排列 */
.page-head.stack {
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
}

.page-head.stack h2 {
  font-size: clamp(21px, 4.6vw, 26px);
}

/* 页面内提示条：占位参与布局，出现时把内容往下推，不遮挡任何文字 */
.notice-bar {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 18px 4px;
  padding: 10px 14px;
  border-radius: 14px;
  font-size: 12.5px;
  font-weight: var(--w-medium);
  line-height: 1.5;
  color: var(--gold-ink);
  background: linear-gradient(135deg, #ffe9b0, var(--gold));
  border: 1px solid rgba(255, 255, 255, 0.4);
}

.notice-bar[hidden] { display: none; }

.notice-bar.error {
  color: #4a1414;
  background: linear-gradient(135deg, #ffd7d7, #ff9f9f);
  border-color: rgba(255, 255, 255, 0.32);
}

/* 登录页 / 首页没有顶栏，提示条自己留一点上边距 */
.app-window[data-mode="auth"] .notice-bar,
.app-window[data-view="home"] .notice-bar {
  margin-top: 12px;
}

@media (min-width: 768px) {
  .notice-bar { margin: 0 40px 8px; }
}

/* 字号档位：整页缩放，比逐个改字号更稳 */
.app-window.font-lg .view-root { zoom: 1.07; }
.app-window.font-xl .view-root { zoom: 1.16; }

.meta-row .tag { margin-right: 4px; }

/* ---------------- 孩子头像 / 缺口标签 ---------------- */

.child-avatar {
  width: 44px;
  height: 44px;
  flex: 0 0 44px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 18px;
  font-weight: var(--w-black);
  color: var(--gold-ink);
  background:
    radial-gradient(circle at 32% 24%, rgba(255, 255, 255, 0.85), transparent 52%),
    linear-gradient(160deg, #ffe291, #ffb246);
  border: 1px solid rgba(255, 240, 190, 0.6);
  box-shadow: 0 8px 22px rgba(255, 171, 61, 0.24);
}

.child-avatar.lg { width: 58px; height: 58px; flex-basis: 58px; font-size: 24px; }
.child-avatar.sm { width: 34px; height: 34px; flex-basis: 34px; font-size: 15px; }

.gap-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 11px;
  border-radius: var(--r-pill);
  font-size: 12px;
  font-weight: var(--w-bold);
  white-space: nowrap;
  border: 1px solid transparent;
}

.gap-pill.tone-0 { color: #bfe0ff; background: rgba(92, 200, 255, 0.14); border-color: rgba(92, 200, 255, 0.34); }
.gap-pill.tone-1 { color: #e0d1ff; background: rgba(179, 136, 255, 0.16); border-color: rgba(179, 136, 255, 0.34); }
.gap-pill.tone-2 { color: #ffc9c0; background: rgba(255, 155, 138, 0.16); border-color: rgba(255, 155, 138, 0.34); }
.gap-pill.tone-3 { color: #ffe6a8; background: rgba(255, 207, 107, 0.16); border-color: rgba(255, 207, 107, 0.34); }
.gap-pill.tone-4 { color: #c9f2c9; background: rgba(129, 199, 132, 0.16); border-color: rgba(129, 199, 132, 0.34); }
.gap-pill.tone-5 { color: #cfd8ff; background: rgba(126, 143, 255, 0.16); border-color: rgba(126, 143, 255, 0.34); }

/* ---------------- 首页 ---------------- */

.home-view { display: flex; flex-direction: column; gap: 14px; }

.home-top h1 em {
  font-style: normal;
  color: var(--gold);
}

.child-card { display: flex; flex-direction: column; gap: 12px; position: relative; }

.child-card-main { display: flex; align-items: center; gap: 14px; }

.child-card-copy { min-width: 0; flex: 1; }

.child-card-copy h3 {
  font-size: 19px;
  font-weight: var(--w-heavy);
  display: flex;
  align-items: baseline;
  gap: 8px;
  flex-wrap: wrap;
}

.child-card-copy h3 small {
  font-size: 11.5px;
  font-weight: var(--w-medium);
  color: var(--muted);
}

.child-card .tag-row { margin-top: 7px; }

.child-card-gap { position: absolute; top: 18px; right: 18px; }

.child-card > .btn-link { align-self: flex-start; font-size: 11.5px; }

.home-plan { border-color: var(--gold-line); box-shadow: var(--glow-gold), var(--shadow-card); }

.home-plan-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin: 6px 0 14px;
}

.home-plan-head h3 { font-size: 17px; line-height: 1.45; }

.home-plan-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  padding: 10px 0;
  border-top: 1px solid var(--line-soft);
  border-bottom: 1px solid var(--line-soft);
}

.home-plan-stats .stat strong { font-size: 20px; color: var(--gold); }
.home-plan-stats .stat span { font-size: 10.5px; color: var(--muted); }

.home-plan-actions { margin-top: 14px; padding-top: 0; border-top: 0; }
.home-plan-actions .btn { flex: 1; }

.empty-plan p { margin-bottom: 12px; font-size: 12px; }

.record-cta { margin-top: 2px; }

/* 事件行（首页最近记录 / 记录页时间线共用） */
.event-list,
.timeline { display: flex; flex-direction: column; gap: 8px; }

.event-item {
  border-radius: var(--r-md);
  background: var(--card);
  border: 1px solid var(--line-soft);
  overflow: hidden;
}

.event-row {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 13px 14px;
  text-align: left;
  background: none;
  color: var(--text);
}

.event-main { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.event-main strong { font-size: 13.5px; font-weight: var(--w-bold); }
.event-main small { font-size: 11px; color: var(--muted); }

.event-detail {
  padding: 0 14px 14px;
  border-top: 1px solid var(--line-soft);
  margin-top: -1px;
  padding-top: 12px;
}

.event-detail p { font-size: 12px; line-height: 1.7; }
.event-detail-actions { display: flex; gap: 8px; margin-top: 10px; flex-wrap: wrap; }

.timeline-group { display: flex; flex-direction: column; gap: 8px; margin-bottom: 10px; }

.timeline-label {
  font-size: 11px;
  font-weight: var(--w-bold);
  color: var(--muted-2);
  letter-spacing: 0.06em;
  padding-left: 2px;
}

/* 键值列表 */
.kv-list { display: flex; flex-direction: column; gap: 8px; margin-top: 10px; }

.kv-list > div {
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
}

.kv-list dt { font-size: 11.5px; color: var(--muted); }
.kv-list dd { font-size: 12px; line-height: 1.65; color: var(--text-soft); }

/* ---------------- 建档引导 ---------------- */

.setup-view { display: flex; justify-content: center; padding: 4px 0 30px; }

.setup-card { width: min(100%, 560px); border-radius: var(--r-xl); }

.setup-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 18px;
}

.setup-head h2 { font-size: 22px; margin: 4px 0 6px; }
.setup-head p { font-size: 12px; line-height: 1.7; }
.setup-head .btn-link { font-size: 12px; white-space: nowrap; }

.setup-dots { display: flex; gap: 6px; margin-bottom: 10px; }

.setup-dot {
  width: 22px;
  height: 4px;
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.14);
  transition: background var(--dur) var(--ease-soft);
}

.setup-dot.active { background: var(--gold); }
.setup-dot.done { background: rgba(255, 207, 107, 0.45); }

.form-section + .form-section { margin-top: 18px; }

/* ---------------- 记录表单 ---------------- */

.record-form { border-radius: var(--r-xl); }

/* views.css 的分节自带下边框，这里改成“上一节的下边框去掉、下一节加分隔线”，避免双线 */
.record-form .form-section { border-bottom: 0; }

.record-form .form-section + .form-section {
  margin-top: 20px;
  padding-top: 18px;
  border-top: 1px solid var(--line-soft);
}

.intensity-picker { width: 100%; }

.intensity-picker button {
  flex: 1;
  min-height: 40px;
  border: 0;
  background: none;
  color: var(--muted);
  font-size: 12.5px;
  font-weight: var(--w-bold);
  border-radius: 8px;
  transition: background var(--dur-fast), color var(--dur-fast);
}

.intensity-picker button.active {
  color: var(--gold-ink);
  background: linear-gradient(180deg, #ffe291, #ffc75c);
}

.choice.with-hint {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  text-align: left;
}

.choice.with-hint small { font-size: 10.5px; color: var(--muted); font-weight: 400; }
.choice.with-hint.active small { color: rgba(26, 19, 64, 0.7); }

/* ---------------- 方案页 ---------------- */

.gap-hero {
  border-radius: var(--r-xl);
  border: 1px solid var(--gold-line);
  background:
    radial-gradient(circle at 88% -10%, rgba(255, 207, 107, 0.16), transparent 46%),
    linear-gradient(160deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.03));
  box-shadow: var(--glow-gold), var(--shadow-card);
  padding: 20px;
}

.gap-hero-head { display: flex; gap: 14px; align-items: flex-start; }

.gap-hero-emoji {
  width: 52px;
  height: 52px;
  flex: 0 0 52px;
  border-radius: 18px;
  display: grid;
  place-items: center;
  font-size: 26px;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid var(--line-soft);
}

.gap-hero h2 { font-size: 22px; margin: 2px 0 6px; }
.gap-hero p { font-size: 12.5px; line-height: 1.75; color: var(--text-soft); }

.gap-hero-foot {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--line-soft);
}

.gap-hero-foot .btn-link { margin-left: auto; font-size: 12px; }

.evidence-box {
  margin-top: 12px;
  padding: 12px 14px;
  border-radius: var(--r-md);
  background: var(--card-deep);
  border: 1px solid var(--line-soft);
}

.evidence-list { display: flex; flex-direction: column; gap: 6px; }

.evidence-list li {
  position: relative;
  padding-left: 16px;
  font-size: 12px;
  line-height: 1.65;
  color: var(--text-soft);
}

.evidence-list li::before {
  content: "•";
  position: absolute;
  left: 2px;
  color: var(--gold);
}

.evidence-note { margin-top: 10px; font-size: 11.5px; line-height: 1.7; color: var(--muted-2); }

.secondary-card h3,
.manual-card h3 { font-size: 15px; margin-bottom: 6px; }
.secondary-card p,
.manual-card p { font-size: 12px; line-height: 1.65; }
.secondary-card .choice-row { margin-top: 12px; }

.gap-chip-list { display: flex; flex-direction: column; gap: 8px; margin-top: 12px; }

.gap-chip-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.gap-chip { flex: 1 1 auto; text-align: left; }

.gap-hint-btn {
  width: 26px;
  height: 26px;
  flex: 0 0 26px;
  border-radius: 50%;
  border: 1px solid var(--line-soft);
  font-size: 12px;
  text-decoration: none;
  color: var(--muted);
}

.gap-hint {
  flex: 1 1 100%;
  font-size: 11.5px;
  line-height: 1.7;
  color: var(--muted);
  padding: 8px 10px;
  border-radius: var(--r-sm);
  background: var(--card-deep);
}

.solution-grid { display: grid; grid-template-columns: 1fr; gap: 14px; }

.solution-card { display: flex; flex-direction: column; gap: 12px; }

.solution-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.solution-head h3 { font-size: 16px; }

.solution-goal {
  font-size: 13px;
  line-height: 1.75;
  font-weight: var(--w-medium);
  color: #fff5dc;
}

.solution-steps { display: flex; flex-direction: column; gap: 9px; counter-reset: step; }

.solution-steps li {
  position: relative;
  padding-left: 26px;
  font-size: 12.5px;
  line-height: 1.7;
  color: var(--text-soft);
  counter-increment: step;
}

.solution-steps li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: 1px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 10.5px;
  font-weight: var(--w-bold);
  color: var(--gold-ink);
  background: linear-gradient(180deg, #ffe291, #ffb246);
}

.quote-box {
  padding: 12px 14px;
  border-radius: var(--r-md);
  background: var(--gold-soft);
  border: 1px dashed var(--gold-line);
}

.quote-label { font-size: 10.5px; color: var(--muted); letter-spacing: 0.04em; }

.quote-text {
  margin: 6px 0 10px;
  font-size: 13.5px;
  line-height: 1.7;
  font-weight: var(--w-medium);
  color: #fff5dc;
}

.plan-actions { flex-wrap: wrap; }

/* ---------------- 脚本页 ---------------- */

.script-meta {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.meta-item .meta-label {
  display: block;
  font-size: 10.5px;
  color: var(--muted-2);
  letter-spacing: 0.05em;
  margin-bottom: 4px;
}

.meta-item p { font-size: 12.5px; line-height: 1.6; color: var(--text-soft); }

.script-principles h3 { font-size: 15px; margin-bottom: 8px; }
.script-principles ul { display: flex; flex-direction: column; gap: 6px; }

.script-principles li {
  position: relative;
  padding-left: 18px;
  font-size: 12px;
  line-height: 1.7;
  color: var(--text-soft);
}

.script-principles li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--green);
  font-size: 11px;
}

.round-list { display: flex; flex-direction: column; gap: 10px; }

.script-step {
  display: grid;
  grid-template-columns: 62px minmax(0, 1fr) 24px;
  gap: 10px;
  align-items: start;
  padding: 13px 14px;
  border-radius: var(--r-md);
  background: var(--card);
  border: 1px solid var(--line-soft);
}

.step-who {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 4px 6px;
  border-radius: 8px;
  font-size: 11px;
  font-weight: var(--w-bold);
  text-align: center;
  word-break: break-all;
}

.who-parent { color: var(--gold-ink); background: linear-gradient(180deg, #ffe291, #ffc75c); }
.who-child { color: #e6f7ff; background: rgba(92, 200, 255, 0.2); border: 1px solid rgba(92, 200, 255, 0.36); }
.who-timer { color: #f2eaff; background: rgba(179, 136, 255, 0.2); border: 1px solid rgba(179, 136, 255, 0.36); }

.script-line { font-size: 13.5px; line-height: 1.75; color: #fff; }

.step-action { margin-top: 6px; font-size: 11px; color: var(--muted); }

.step-edit { color: var(--muted-2); font-size: 13px; text-decoration: none; }

.misstep-card {
  padding: 16px 16px 18px;
  border-radius: var(--r-lg);
  border: 1px solid rgba(255, 128, 128, 0.42);
  background: linear-gradient(160deg, rgba(255, 128, 128, 0.12), rgba(255, 128, 128, 0.04));
}

.misstep-label {
  display: inline-block;
  font-size: 10.5px;
  letter-spacing: 0.08em;
  color: #ffb3b3;
  margin-bottom: 6px;
}

.misstep-card h3 { font-size: 15px; color: #ffd6d6; }
.misstep-line { margin: 8px 0; font-size: 13px; line-height: 1.7; color: #ffe3e3; }
.misstep-note { font-size: 12px; line-height: 1.75; color: #ffc9c9; }

.script-actions { flex-wrap: wrap; }

/* ---------------- 演练（全屏） ---------------- */

.drill-view {
  display: flex;
  flex-direction: column;
  min-height: 100%;
  padding: 12px 16px 24px;
}

.drill-head {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 4px 0 10px;
}

.drill-title {
  flex: 1;
  min-width: 0;
  font-size: 12.5px;
  font-weight: var(--w-medium);
  color: var(--muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.drill-count { font-size: 12px; color: var(--gold); font-weight: var(--w-bold); }

.drill-progress {
  height: 4px;
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.1);
  overflow: hidden;
}

.drill-progress span {
  display: block;
  height: 100%;
  border-radius: 2px;
  background: linear-gradient(90deg, var(--gold), #ffb246);
  transition: width var(--dur) var(--ease-soft);
}

.drill-stage {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  gap: 14px;
  padding: 26px 6px;
  min-height: 280px;
}

.drill-who {
  display: inline-flex;
  padding: 5px 14px;
  border-radius: var(--r-pill);
  font-size: 12px;
  font-weight: var(--w-bold);
}

.drill-line {
  font-size: clamp(19px, 5.2vw, 26px);
  line-height: 1.6;
  font-weight: var(--w-bold);
  color: #fff8e8;
  max-width: 720px;
}

.drill-action { font-size: 12.5px; color: var(--muted); }

.hourglass-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  margin-top: 8px;
}

.hourglass {
  position: relative;
  width: 54px;
  height: 84px;
  border-radius: 10px;
  border: 1.5px solid var(--gold-line);
  background: rgba(255, 255, 255, 0.04);
  display: flex;
  align-items: flex-end;
  overflow: hidden;
}

.hg-fill {
  width: 100%;
  background: linear-gradient(180deg, rgba(255, 207, 107, 0.85), rgba(255, 171, 61, 0.5));
  transition: height 900ms linear;
}

.hg-meta { display: flex; align-items: baseline; gap: 4px; }
.hg-time { font-family: var(--font-num); font-size: 26px; color: var(--gold); }
.hg-meta span { font-size: 11px; color: var(--muted); }

.drill-foot {
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
}

.drill-foot .btn { flex: 1 1 auto; min-width: 120px; }

.drill-hint {
  margin-top: 10px;
  text-align: center;
  font-size: 10.5px;
  color: var(--muted-2);
}

.drill-done .drill-stage { gap: 12px; }
.drill-emoji { font-size: 46px; }
.drill-done h2 { font-size: 22px; }
.drill-done p { font-size: 12.5px; line-height: 1.75; }

.drill-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
  width: min(100%, 340px);
  margin-top: 8px;
}

/* 演练时提示条照常显示：它是占位的，不会盖住大字话术 */

/* ---------------- 跟踪页 ---------------- */

.track-bar {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  justify-content: space-between;
}

.track-bar-main { min-width: 0; flex: 1; display: flex; flex-direction: column; gap: 6px; }
.track-bar-main p { font-size: 14px; font-weight: var(--w-bold); }
.track-bar-main small { font-size: 11px; }

.summary-card .summary-text {
  font-size: 14px;
  line-height: 1.75;
  color: #fff5dc;
  margin: 6px 0 14px;
}

.summary-card .stat-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  padding-top: 12px;
  border-top: 1px solid var(--line-soft);
}

.summary-card .stat strong { font-size: 18px; color: var(--gold); }
.summary-card .stat span { font-size: 10px; color: var(--muted); }

.practice-list { display: flex; flex-direction: column; gap: 0; padding: 6px 16px; }

.practice-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line-soft);
}

.practice-row:last-child { border-bottom: 0; }

.practice-main { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.practice-main strong { font-size: 13px; }
.practice-main small { font-size: 11px; color: var(--muted); }
.practice-note { color: var(--muted-2) !important; font-style: italic; }

.review-card h3 { font-size: 16px; margin-bottom: 6px; }
.review-card p { font-size: 12px; line-height: 1.7; }

.review-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin: 14px 0 10px;
}

.review-actions .btn { flex: 1 1 140px; }

/* 打卡表单（写在页面里，不用弹层） */
.checkin-card {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 18px;
}

.checkin-card h3 { font-size: 16px; }
.checkin-card > .muted { font-size: 12px; margin-top: -8px; }

.checkin-actions { display: flex; gap: 10px; }
.checkin-actions .btn { flex: 1; min-height: 48px; }

/* display:flex 的容器会忽略 hidden 属性，这里显式收起 */
.replacement-row[hidden] { display: none; }
.replacement-row { margin-top: 8px; }

/* 脚本：页内改一句话（不用弹窗） */
.round-edit-actions {
  display: flex;
  gap: 8px;
  margin-top: 10px;
}

.round-edit-actions .btn {
  min-height: 42px;
  padding: 0 20px;
}

/* 按钮二次确认态：不用弹窗，直接把按钮改成红色提示，再点一次才执行 */
.is-confirming {
  color: #ff9e9e !important;
  border-color: rgba(255, 128, 128, 0.55) !important;
  background: rgba(255, 90, 90, 0.12) !important;
  font-weight: 600;
}

/* ---------------- 我的 ---------------- */

.profile-child-head {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 4px;
}

/* 「我的」页顶部的说明文字：左对齐，不跟正文抢视线 */
.profile-note {
  text-align: left;
  margin: -4px 0 0;
}

.profile-child-head h3 { font-size: 19px; }
.profile-child-head p { font-size: 11.5px; }
.profile-child-head .btn { margin-left: auto; }

.account-row { display: flex; align-items: center; gap: 12px; }
.account-row div { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.account-row strong { font-size: 14px; }
.account-row small { font-size: 11.5px; color: var(--muted); }

.settings-card h3,
.data-card h3,
.about-card h3 { font-size: 16px; margin-bottom: 8px; }

.settings-row { gap: 14px; }
.settings-row .segmented { flex: 0 0 auto; }
.settings-row .segmented button { min-width: 52px; }

.settings-copy small { font-size: 10.5px; color: var(--muted-2); }

.data-actions { display: flex; gap: 8px; flex-wrap: wrap; margin: 10px 0; }
.data-actions .btn { flex: 1 1 150px; }

.about-card p { font-size: 12px; line-height: 1.75; }
.about-card .fine-print { text-align: left; margin-top: 8px; }

/* ---------------- 平板 / 桌面 ---------------- */

@media (min-width: 768px) {
  .record-view,
  .plan-view,
  .script-view,
  .track-view,
  .profile-view { gap: 18px; }

  .child-card {
    flex-direction: row;
    align-items: center;
  }

  .child-card-main { flex: 1; }
  .child-card-gap { position: static; }
  .child-card > .btn-link { align-self: center; }

  .script-meta { grid-template-columns: repeat(3, minmax(0, 1fr)); }

  .solution-grid { grid-template-columns: 1fr 1fr; align-items: start; }

  .script-step { grid-template-columns: 76px minmax(0, 1fr) 28px; padding: 15px 18px; }
  .script-line { font-size: 14.5px; }

  .drill-view { padding: 20px 32px 32px; }
  .drill-actions { flex-direction: row; width: auto; }
  .drill-actions .btn { flex: 1 1 auto; }

  .setup-card { padding: 26px; }
}

@media (min-width: 1024px) {
  .home-plan-head h3 { font-size: 19px; }
  .gap-hero { padding: 24px 26px; }
  .gap-hero h2 { font-size: 26px; }
}

/* ---------------- 打印：给老师的那一页 ---------------- */

@media print {
  body { background: #fff !important; }

  .sidebar,
  .topbar,
  .tabbar,
  .side-note,
  .plan-actions,
  .script-actions,
  .flow-actions,
  .evidence-box,
  .manual-card,
  .notice-bar,
  .btn,
  .btn-link,
  .step-edit { display: none !important; }

  .app-window,
  .app-shell,
  .app-main,
  .view-root {
    display: block !important;
    width: auto !important;
    height: auto !important;
    max-height: none !important;
    padding: 0 !important;
    margin: 0 !important;
    overflow: visible !important;
    box-shadow: none !important;
    border: 0 !important;
    background: #fff !important;
    border-radius: 0 !important;
  }

  .plan-view,
  .script-view { gap: 12px; color: #111; }

  .card,
  .gap-hero,
  .misstep-card,
  .script-step {
    background: #fff !important;
    border: 1px solid #ccc !important;
    box-shadow: none !important;
    color: #111 !important;
    break-inside: avoid;
  }

  .plan-view h2,
  .plan-view h3,
  .plan-view p,
  .plan-view li,
  .plan-view dd,
  .plan-view dt,
  .script-view h2,
  .script-view h3,
  .script-view p,
  .script-view li,
  .script-line,
  .step-action,
  .solution-goal,
  .quote-text,
  .misstep-card p { color: #111 !important; }

  .gap-pill,
  .tag { border: 1px solid #999 !important; color: #111 !important; background: #fff !important; }

  .fine-print { color: #555 !important; }
}
