/* 场景专属与运营层：启动遮罩、飞行卡片、标点彩蛋、工作人员模式、导出弹层、Attract */

/* ===== 启动遮罩 ===== */
.boot {
  position: fixed; inset: 0; z-index: 200;
  display: grid; place-items: center; gap: 18px;
  background: var(--dark); color: var(--dark-text);
  transition: opacity 620ms var(--ease), visibility 0s linear 620ms;
}
.boot.is-gone { opacity: 0; visibility: hidden; }
.boot-inner { display: flex; flex-direction: column; align-items: center; gap: 18px; }
.boot-amp { font-family: var(--serif); font-style: italic; font-size: 88px; color: var(--lime-2); line-height: 1; animation: amp-float 3.2s var(--ease) infinite; }
.boot-text { font-family: var(--mono); font-size: 10.5px; letter-spacing: .22em; text-transform: uppercase; color: var(--dark-muted); }
.boot-bar { width: 220px; height: 3px; background: rgba(217, 242, 169, .16); overflow: hidden; }
.boot-bar i { display: block; height: 100%; width: 34%; background: var(--lime-2); animation: boot-slide 1.15s var(--ease) infinite; }
@keyframes boot-slide { 0% { transform: translateX(-110%); } 100% { transform: translateX(320%); } }

/* ===== 飞行卡片 ===== */
.fly-card {
  position: absolute; left: 0; top: 0;
  width: 300px; padding: 14px 18px;
  background: var(--white); border: 1px solid var(--line); border-left: var(--edge-strong) solid var(--lime-2);
  box-shadow: 0 26px 54px rgba(12, 38, 24, .26);
  transform-origin: center center;
  will-change: transform, opacity;
}
.fly-card .fc-prefix { font-family: var(--serif); font-style: italic; font-size: 16px; color: var(--ink-2); }
.fly-card .fc-text { display: block; margin-top: 4px; font-size: 16px; font-weight: 750; line-height: 1.4; letter-spacing: -.015em; }

/* ===== 标点彩蛋 ===== */
.punct {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--dark-line);
}
.punct .label { color: var(--dark-muted); }
.punct-btn {
  padding: 8px 13px; border: 1px solid var(--dark-line); background: transparent;
  font-family: var(--mono); font-size: 11px; font-weight: 700; letter-spacing: .06em;
  color: var(--dark-muted);
  transition: all var(--t-fast) var(--ease);
}
.punct-btn:hover { color: var(--lime-2); border-color: var(--lime-2); }
.punct-btn.is-on { background: var(--lime-2); color: var(--dark); border-color: var(--lime-2); }
.punct-out { margin-top: 12px; font-size: clamp(13.5px, 1.1vw, 17px); line-height: 1.6; color: #d3ded6; min-height: 2.6em; max-width: 78ch; }
.punct-out b { color: var(--lime-2); font-weight: 780; }

/* ===== 工作人员模式 ===== */
.staff-bar {
  position: fixed; z-index: 95; left: 0; right: 0; top: var(--topbar-h);
  display: none; align-items: center; gap: 14px;
  padding: 9px var(--pad-x);
  background: var(--yellow); color: var(--ink);
  font-family: var(--mono); font-size: 10.5px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase;
  border-bottom: 1px solid var(--ink);
}
.staff-bar.is-on { display: flex; }
.staff-bar button { font: inherit; text-decoration: underline; text-underline-offset: 3px; }
.staff-bar .sp { margin-left: auto; display: flex; gap: 14px; }

.wall-card .wc-staff { display: none; margin-top: 9px; gap: 6px; }
body.is-staff .wall-card .wc-staff { display: flex; }
.wc-staff button {
  flex: 1 1 auto; padding: 5px 6px; background: var(--ink); color: var(--white);
  font-family: var(--mono); font-size: 8.5px; letter-spacing: .08em; text-transform: uppercase;
}
.wc-staff button:hover { background: var(--lime-2); color: var(--ink); }
.wc-staff button.is-on { background: #4f7a25; color: var(--white); }

/* ===== 弹层（导出卡片 / 二维码） ===== */
.modal {
  position: fixed; inset: 0; z-index: 120;
  display: none; place-items: center; padding: 24px;
  background: rgba(9, 23, 15, .74);
}
.modal.is-on { display: grid; animation: fade 240ms var(--ease); }
@keyframes fade { from { opacity: 0; } }
.modal-box {
  position: relative; max-width: min(760px, 96vw); max-height: 92vh; overflow: auto;
  background: var(--paper); border-top: var(--edge-strong) solid var(--lime-2);
  padding: 24px; box-shadow: 0 40px 90px rgba(0, 0, 0, .45);
  animation: pop 340ms var(--ease-out);
}
@keyframes pop { from { opacity: 0; transform: translateY(18px) scale(.97); } }
.modal-close { position: absolute; top: 12px; right: 12px; width: 34px; height: 34px; display: grid; place-items: center; border: 1px solid var(--line); background: var(--white); }
.modal-close:hover { background: var(--ink); }
.modal-close svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 2.2; }
.modal-close:hover svg { stroke: var(--white); }
.modal-box canvas { display: block; width: 100%; height: auto; background: var(--white); border: 1px solid var(--line); }
.modal-actions { display: flex; gap: 10px; margin-top: 16px; flex-wrap: wrap; }
.modal-note { margin-top: 12px; font-size: 12px; color: var(--muted); line-height: 1.6; }

/* ===== Attract 待机 ===== */
body.is-attract .topbar, body.is-attract .chapter-dock, body.is-attract .sim-badge, body.is-attract .lang-toggle { opacity: .3; }
body.is-attract .topbar, body.is-attract .chapter-dock, body.is-attract .sim-badge, body.is-attract .lang-toggle { transition: opacity 700ms var(--ease); }
.attract-tip {
  position: fixed; z-index: 60; left: 50%; bottom: calc(var(--rail-h) + var(--hint-h) + 56px);
  transform: translateX(-50%);
  display: none; align-items: center; gap: 12px;
  padding: 13px 22px; background: var(--ink); color: var(--white);
  font-size: 14px; font-weight: 700; letter-spacing: -.01em;
  border-left: var(--edge-standard) solid var(--lime-2);
  animation: tip-bob 2.6s var(--ease) infinite;
}
body.is-attract .attract-tip { display: flex; }
@keyframes tip-bob { 0%, 100% { transform: translateX(-50%) translateY(0); } 50% { transform: translateX(-50%) translateY(-7px); } }

/* ===== 二维码占位 ===== */
.qr-box.is-real { border-style: solid; border-color: var(--ink); background: var(--white); padding: 6px; }

/* ===== 硬件场景细节 ===== */
/* 05 DEVICE 的对决面板不允许被 flex 压缩：min-height:0 会让面板在内容过高时
   原地缩水、溢出部分被后面的卡片网格压住（视觉上重叠，但场景 scrollHeight 不变，
   排版验收探测不到）。保持内容真实高度，放不下就让场景自然滚动。 */
.inner-device .card-grid { margin-top: clamp(12px, 1.8vh, 20px); }

/* ===== 滚动条 ===== */
.wall::-webkit-scrollbar, .scene::-webkit-scrollbar, .modal-box::-webkit-scrollbar { width: 6px; height: 6px; }
.wall::-webkit-scrollbar-thumb, .scene::-webkit-scrollbar-thumb, .modal-box::-webkit-scrollbar-thumb { background: var(--line); }
.wall::-webkit-scrollbar-track, .scene::-webkit-scrollbar-track { background: transparent; }

/* ===== 全屏微调 ===== */
:fullscreen body, :-webkit-full-screen body { background: var(--paper); }
:fullscreen .stage, :-webkit-full-screen .stage { bottom: calc(var(--rail-h) + var(--hint-h)); }

/* ===== 触屏：更大的可点区域 ===== */
@media (pointer: coarse) {
  .btn-solid, .btn-ghost { height: 52px; padding: 0 24px; font-size: 15px; }
  .chip { padding: 13px 16px; font-size: 14px; }
  .rail { height: 62px; }
  :root { --rail-h: 62px; }
  .device-btn { width: min(64vw, 300px); }
}

/* ===== 打印（现场若想直接把语录墙打出来） ===== */
@media print {
  .topbar, .rail, .hintbar, .chapter-dock, .sim-badge, .lang-toggle, .fx-canvas, .grid-bg, .takeaway, .toast-layer { display: none !important; }
  .stage { position: static; top: 0; bottom: 0; }
  .scene { position: static; opacity: 1; visibility: visible; transform: none; overflow: visible; page-break-after: always; }
  .wall { max-height: none; overflow: visible; }
  body { overflow: visible; background: #fff; }
}

/* 首屏：先看到难题，再带着可修改的示例进入体验。 */
.inner-brand { justify-content: flex-start; }
.inner-brand > * { flex-shrink: 0; }
.inner-brand .brand-say { font-size: clamp(48px, 6vw, 90px); }
.inner-brand .brand-amp { font-size: clamp(58px, 7vw, 106px); }
.inner-brand .brand-line { margin-top: 16px; }
.inner-brand .brand-sub { margin-top: 10px; max-width: none; }
.brand-pains { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; width: 100%; margin-top: 22px; }
.brand-pain { display: flex; flex-direction: column; gap: 10px; text-align: left; padding: 20px; border: 1px solid var(--dark-line); border-top: 3px solid var(--lime-2); background: rgba(217,242,169,.04); color: var(--dark-text); }
.brand-pain:hover, .brand-pain:focus-visible { background: rgba(217,242,169,.12); border-color: var(--lime-2); }
.brand-pain:focus-visible { outline: 2px solid var(--lime-2); outline-offset: 3px; }
.pain-num { font-size: 10px; letter-spacing: .1em; color: var(--dark-muted); }
.brand-pain strong { font-size: clamp(16px, 1.5vw, 23px); line-height: 1.4; }
.pain-answer { color: var(--lime-2); font-size: clamp(13px, 1.05vw, 17px); line-height: 1.5; }
.pain-note { color: #b9c8bd; font-size: 12px; line-height: 1.5; }
.inner-brand .brand-ticker { margin-top: 18px; }
@media (max-height: 800px) and (min-width: 701px) {
  .inner-brand .brand-say { font-size: 54px; }
  .inner-brand .brand-amp { font-size: 64px; }
  .inner-brand .brand-line { font-size: 26px; margin-top: 12px; }
  .brand-pains { margin-top: 14px; gap: 10px; }
  .brand-pain { padding: 14px; gap: 7px; }
  .inner-brand .cta-big { margin-top: 16px; }
}
@media (max-width: 700px) {
  .brand-pains { grid-template-columns: 1fr; margin-top: 16px; gap: 8px; }
  .brand-pain { padding: 12px 14px; gap: 5px; }
  .pain-note { display: none; }
  .brand-pain:last-child .pain-note { display: block; }
  .inner-brand .eyebrow { font-size: 9px; }
  .inner-brand .brand-line { font-size: 23px; }
}
