/* ===========================================================
   场景实操页（/scene/*.html）专用样式
   与站内风格一致：主色 #5961f9 / #7673ef，白底卡片 + 10px 圆角
   =========================================================== */

/* 站内 reset.css 对全站文字做了 user-select:none（原站防复制）。
   场景页的核心用途之一就是「复制提示词」，这里定点放开。
   双写 .scene-page 是为压过 reset 里 :not(...) 选择器的权重。 */
html body .scene-page.scene-page,
html body .scene-page.scene-page * {
  -webkit-user-select: text !important;
  user-select: text !important;
  -webkit-touch-callout: default !important;
}

.scene-page { padding: 0 24px; }
.scene-inner { max-width: 1080px; margin: 0 auto; }

/* 站内 .main-content 是 overflow-y:scroll，overflow-x 会被算成 auto，
   只要子元素外扩一点（根子是站内 .about-us 的 margin-right:30px），
   内容区就能横向滑动，手机上很容易误滑。场景页锁定横向。 */
.ai-home > .main-content.scene-host { overflow-x: hidden; }
@media (max-width: 1200px) {
  .scene-host .about-us { margin-right: 0; }
}

/* bootstrap 的 h1~h6 / p / ul / ol / pre 用 rem 设外边距，而本站 rem 被 flexible
   放大成 clientWidth/7.5（桌面端 1rem ≈ 192px），直接沿用会凭空多出上百像素空档，
   ul 还会被 padding-left:2rem 顶掉半屏。这里统一清零，间距全部由下方 px 规则接管。 */
.scene-h1, .step-title, .scene-idx-head h1, .scene-idx-head p,
.scene-sub, .scene-lead, .step-why, .step-prompt pre,
.faq-q, .faq-a, .step-alts, .step-fallback {
  margin-top: 0;
  margin-bottom: 0;
}
.scene-meta, .step-how, .scene-pitfalls, .scene-faq { margin-bottom: 0; padding-left: 0; }

/* ---------- 面包屑 ---------- */
.scene-crumb { display: flex; flex-wrap: wrap; align-items: center; font-size: 13px; color: #7a7a8c; margin-bottom: 14px; }
.scene-crumb a { color: #7a7a8c; }
.scene-crumb a:hover { color: #5961f9; }
.scene-crumb .sep { margin: 0 6px; color: #c8c8d4; }
.scene-crumb .cur { color: #090524; font-weight: 600; }

/* ---------- 头部 ---------- */
.scene-hero { background: #fff; border-radius: 10px; padding: 26px 28px; box-shadow: 0 1px 3px rgba(9, 5, 36, .06); }
.scene-cat { display: inline-block; font-size: 12px; color: #5961f9; background: #eeedfd; border-radius: 999px; padding: 3px 11px; margin-bottom: 12px; }
.scene-h1 { font-size: 26px; font-weight: 700; color: #090524; line-height: 1.4; }
.scene-sub { font-size: 14px; color: #6c6c7c; line-height: 1.8; margin-top: 12px; }
.scene-meta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 20px; }
.scene-meta li { list-style: none; flex: 1 1 190px; background: #f7f7fc; border-radius: 8px; padding: 11px 14px; }
.scene-meta li b { display: block; font-size: 12px; font-weight: 400; color: #9a9aa8; margin-bottom: 4px; }
.scene-meta li span { font-size: 14px; color: #090524; font-weight: 600; line-height: 1.5; }

/* ---------- 通用标题 ---------- */
.scene-sec-title { display: flex; align-items: center; font-size: 18px; font-weight: 700; color: #090524; margin: 38px 0 16px; }
.scene-sec-title::before { content: ''; width: 4px; height: 18px; border-radius: 2px; background: #7673ef; margin-right: 10px; }

/* ---------- 导语 ---------- */
.scene-lead { background: #fff; border-radius: 10px; padding: 20px 24px; margin-top: 16px; font-size: 14px; color: #4a4a58; line-height: 1.9; box-shadow: 0 1px 3px rgba(9, 5, 36, .06); }
.scene-lead strong { font-weight: 600; color: #090524; }

/* ---------- 步骤 ---------- */
.scene-steps { position: relative; }
.scene-step { position: relative; padding-left: 46px; padding-bottom: 22px; }
.scene-step:last-child { padding-bottom: 0; }
.scene-step::before { content: ''; position: absolute; left: 15px; top: 34px; bottom: 0; width: 1px; background: #e6e6f0; }
.scene-step:last-child::before { display: none; }
.step-no { position: absolute; left: 0; top: 0; width: 32px; height: 32px; border-radius: 50%; background: #7673ef; color: #fff; font-size: 14px; font-weight: 700; line-height: 32px; text-align: center; }
.step-card { background: #fff; border-radius: 10px; padding: 20px 24px; box-shadow: 0 1px 3px rgba(9, 5, 36, .06); }
.step-head { display: flex; align-items: baseline; justify-content: space-between; }
.step-title { font-size: 17px; font-weight: 700; color: #090524; line-height: 1.5; }
.step-min { flex: none; margin-left: 12px; font-size: 12px; color: #9a9aa8; white-space: nowrap; }
.step-why { font-size: 14px; color: #6c6c7c; line-height: 1.85; margin-top: 8px; }

/* 步骤内工具卡 */
.step-tool { display: flex; align-items: center; margin-top: 16px; padding: 12px 14px; background: #f7f7fc; border-radius: 8px; }
.step-tool img { width: 42px; height: 42px; border-radius: 8px; object-fit: contain; flex: none; margin-right: 12px; background: #fff; }
.step-tool .tt-meta { flex: 1 1 auto; min-width: 0; }
.step-tool .tt-name { display: block; font-size: 15px; font-weight: 700; color: #090524; }
.step-tool .tt-name:hover { color: #5961f9; }
.step-tool .tt-desc { display: block; font-size: 12px; color: #9a9aa8; margin-top: 3px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.step-tool .tt-go { flex: none; font-size: 12px; color: #5961f9; border: 1px solid #d9d9f5; background: #fff; border-radius: 999px; padding: 5px 13px; margin-left: 10px; }
.step-tool .tt-go:hover { background: #5961f9; border-color: #5961f9; color: #fff; }

/* 步骤内备选工具 */
.step-alts { margin-top: 10px; font-size: 12px; color: #9a9aa8; }
.step-alts a { display: inline-block; margin-left: 6px; padding: 2px 10px; font-size: 12px; color: #5961f9; background: #f2f3ff; border-radius: 999px; }
.step-alts a:hover { background: #5961f9; color: #fff; }

/* 步骤内「卡住了怎么办」 */
.step-fallback { margin-top: 14px; padding: 10px 14px; background: #fdf6ee; border-left: 3px solid #f0a97b; border-radius: 0 6px 6px 0; font-size: 13px; color: #6b5540; line-height: 1.8; }
.step-fallback b { display: block; font-size: 12px; font-weight: 500; color: #b07a45; margin-bottom: 2px; }

/* 步骤内操作要点 */
.step-how { margin-top: 16px; }
.step-how li { list-style: none; position: relative; padding-left: 20px; font-size: 14px; color: #4a4a58; line-height: 1.9; margin-bottom: 6px; }
.step-how li::before { content: ''; position: absolute; left: 5px; top: 11px; width: 5px; height: 5px; border-radius: 50%; background: #b9b7ee; }

/* 提示词块 */
.step-prompt { margin-top: 16px; border: 1px solid #e6e6f0; border-radius: 8px; overflow: hidden; }
.sp-head { display: flex; align-items: center; justify-content: space-between; padding: 8px 14px; background: #f7f7fc; }
.sp-head span { font-size: 12px; color: #8d8d9c; }
.sp-copy { font-size: 12px; color: #5961f9; border: 1px solid #d9d9f5; background: #fff; border-radius: 999px; padding: 4px 12px; cursor: pointer; }
.sp-copy:hover { background: #5961f9; border-color: #5961f9; color: #fff; }
.sp-copy.done { background: #0f8a5f; border-color: #0f8a5f; color: #fff; }
.step-prompt pre { display: block; padding: 14px; font-size: 13px; line-height: 1.85; color: #2c2c2a; background: #fff; white-space: pre-wrap; word-break: break-word; font-family: Consolas, Menlo, "Microsoft YaHei", monospace; }

/* ---------- 避坑 ---------- */
.scene-pitfalls { background: #fff; border-radius: 10px; padding: 20px 24px; box-shadow: 0 1px 3px rgba(9, 5, 36, .06); }
.scene-pitfalls li { list-style: none; position: relative; padding-left: 24px; font-size: 14px; color: #4a4a58; line-height: 1.9; margin-bottom: 10px; }
.scene-pitfalls li:last-child { margin-bottom: 0; }
.scene-pitfalls li::before { content: ''; position: absolute; left: 6px; top: 10px; width: 8px; height: 8px; border-radius: 2px; background: #f0a97b; }

/* ---------- 常见问题 ---------- */
.scene-faq { display: grid; gap: 12px; }
.faq-item { background: #fff; border-radius: 10px; padding: 18px 22px; box-shadow: 0 1px 3px rgba(9, 5, 36, .06); }
.faq-q { font-size: 15px; font-weight: 700; color: #090524; line-height: 1.6; }
.faq-q::before { content: 'Q'; display: inline-block; width: 20px; height: 20px; margin-right: 8px; border-radius: 5px; background: #eeedfd; color: #5961f9; font-size: 12px; line-height: 20px; text-align: center; vertical-align: 2px; }
.faq-a { margin-top: 8px; padding-left: 28px; font-size: 14px; color: #4a4a58; line-height: 1.9; }

/* ---------- 本场景用到的工具 ----------
   注意：一律用 minmax(0, 1fr) 而不是 1fr。
   1fr 等价于 minmax(auto, 1fr)，其中 auto 的下限是「内容的 min-content 宽度」；
   而卡片里的 .tm-name / .tm-desc 是 nowrap + ellipsis，min-content 就是整行文字宽度
   （overflow:hidden 不会降低 min-content）。两者叠加会把三列撑到 1300px 以上，
   塞进 1080px 的容器后，第三列直接被 .scene-host 的 overflow-x:hidden 裁掉。
   这个坑只在 >1200px 三列时出现，≤1200px 媒体查询切成两列正好躲过。
   同一规律适用于下面所有网格。 */
.scene-tools { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.tool-mini { display: flex; align-items: center; background: #fff; border-radius: 10px; padding: 12px 14px; box-shadow: 0 1px 3px rgba(9, 5, 36, .06); }
.tool-mini:hover { box-shadow: 0 3px 10px rgba(9, 5, 36, .1); }
.tool-mini img { width: 36px; height: 36px; border-radius: 8px; object-fit: contain; flex: none; margin-right: 10px; background: #f7f7fc; }
.tool-mini .tm-meta { min-width: 0; }
.tool-mini .tm-name { display: block; font-size: 14px; font-weight: 700; color: #090524; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.tool-mini .tm-desc { display: block; font-size: 12px; color: #9a9aa8; margin-top: 2px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }

/* ---------- 相关场景 ---------- */
.scene-related { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.rel-card { display: block; background: #fff; border-radius: 10px; padding: 16px 18px; box-shadow: 0 1px 3px rgba(9, 5, 36, .06); }
.rel-card:hover { box-shadow: 0 3px 10px rgba(9, 5, 36, .1); }
.rel-card .rc-cat { font-size: 12px; color: #5961f9; }
.rel-card .rc-title { display: block; font-size: 15px; font-weight: 700; color: #090524; line-height: 1.55; margin-top: 6px; }
.rel-card:hover .rc-title { color: #5961f9; }
.rel-card .rc-desc { display: block; font-size: 12px; color: #9a9aa8; line-height: 1.7; margin-top: 6px; }

/* ===========================================================
   场景索引页 /scene/index.html
   =========================================================== */
.scene-idx-head { background: #fff; border-radius: 10px; padding: 26px 28px; box-shadow: 0 1px 3px rgba(9, 5, 36, .06); }
.scene-idx-head h1 { font-size: 26px; font-weight: 700; color: #090524; line-height: 1.4; }
.scene-idx-head p { font-size: 14px; color: #6c6c7c; line-height: 1.8; margin-top: 10px; }
.scene-group { margin-top: 30px; }
.scene-group .sg-title { font-size: 16px; font-weight: 700; color: #090524; margin-bottom: 14px; padding-left: 12px; border-left: 3px solid #7673ef; line-height: 1.2; }
.scene-group .sg-title em { font-style: normal; font-size: 12px; font-weight: 400; color: #9a9aa8; margin-left: 8px; }
.scene-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.scene-card { display: flex; flex-direction: column; background: #fff; border-radius: 10px; padding: 18px 20px; box-shadow: 0 1px 3px rgba(9, 5, 36, .06); }
.scene-card:hover { box-shadow: 0 3px 12px rgba(9, 5, 36, .1); }
.scene-card .sc-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.scene-card .sc-cat { font-size: 12px; color: #5961f9; background: #eeedfd; border-radius: 999px; padding: 2px 10px; }
.scene-card .sc-time { font-size: 12px; color: #9a9aa8; }
.scene-card .sc-title { font-size: 16px; font-weight: 700; color: #090524; line-height: 1.55; }
.scene-card:hover .sc-title { color: #5961f9; }
.scene-card .sc-desc { font-size: 13px; color: #8d8d9c; line-height: 1.75; margin-top: 8px; flex: 1 1 auto; }
.scene-card .sc-tools { display: flex; align-items: center; margin-top: 14px; }
.scene-card .sc-tools img { width: 24px; height: 24px; border-radius: 6px; object-fit: contain; margin-right: -6px; background: #fff; border: 1px solid #f0f0f5; }
.scene-card .sc-tools .sc-more { font-size: 12px; color: #9a9aa8; margin-left: 12px; }

/* ===========================================================
   首页「场景直达」入口条
   =========================================================== */
.scene-entry { max-width: 1920px; margin: 0 auto; margin-top: 26px; padding: 0 24px; }
.scene-entry .se-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 12px; }
.scene-entry .se-head .se-t { font-size: 16px; font-weight: 700; color: #090524; }
.scene-entry .se-head .se-t em { font-style: normal; font-size: 12px; font-weight: 400; color: #9a9aa8; margin-left: 8px; }
.scene-entry .se-head .se-all { font-size: 13px; color: #5961f9; }
.scene-entry .se-list { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 12px; }
.scene-entry .se-item { display: block; background: #fff; border-radius: 10px; padding: 14px 16px; box-shadow: 0 1px 3px rgba(9, 5, 36, .06); }
.scene-entry .se-item:hover { box-shadow: 0 3px 12px rgba(9, 5, 36, .1); }
.scene-entry .se-item .sei-t { display: block; font-size: 14px; font-weight: 700; color: #090524; line-height: 1.5; }
.scene-entry .se-item:hover .sei-t { color: #5961f9; }
.scene-entry .se-item .sei-d { display: block; font-size: 12px; color: #9a9aa8; margin-top: 6px; }

/* ---------- 响应式 ---------- */
@media (max-width: 1400px) {
  .scene-entry .se-list { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 1200px) {
  .scene-page { padding: 0 4px; }
  .scene-entry { padding: 0 4px; }
  .scene-tools, .scene-related, .scene-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 800px) {
  .scene-hero { padding: 20px 18px; }
  .scene-h1, .scene-idx-head h1 { font-size: 20px; }
  .scene-lead, .scene-pitfalls { padding: 16px 18px; }
  .step-card { padding: 16px 18px; }
  .scene-step { padding-left: 40px; }
  .scene-tools, .scene-related, .scene-grid { grid-template-columns: minmax(0, 1fr); }
  .scene-entry .se-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
