/* ============================================================
 * 纯净 H5 游戏壳：移除站点外壳（顶栏/页脚/推广/外链）后的布局修正
 * 仅覆盖布局，不动游戏组件样式（merge-Czdz4_4I.css）与图标/隐藏规则
 * （dafish-manifest-QCQroIpy.css）。
 * ============================================================ */

/* 站点外壳残留：全部压掉（标记里已删，这里再兜底） */
.topbar,
.page-footer,
.utility-community,
.creator-links,
.gj-foot-nav,
#ad-banner-top { display: none !important; }

/* 全屏游戏容器：移动端优先，居中单列 */
.app-shell {
  display: flex !important;
  flex-direction: column;
  width: min(480px, 100%) !important;
  min-height: 100dvh;
  margin: 0 auto;
  padding: 8px !important;
  gap: 8px;
}

/* 操作条：横排，置于游戏上方 */
.utility-sidebar {
  position: static !important;
  display: flex !important;
  flex-direction: row !important;
  flex-wrap: wrap;
  grid-column: auto !important;
  grid-row: auto !important;
  order: -1;
  gap: 6px !important;
  align-items: center;
  justify-content: center;
  padding: 6px 8px !important;
  box-shadow: none !important;
}
.utility-actions,
.utility-community { display: contents; }
.utility-sidebar .utility-action {
  display: inline-flex !important;
  width: auto !important;
  min-width: 0;
  flex: 0 1 auto;
  grid-template-columns: none !important;
  justify-content: center;
  align-items: center;
  gap: 5px;
  padding: 6px 10px !important;
}
.utility-sidebar .utility-label,
.utility-sidebar .utility-copy { display: inline !important; }
.utility-sidebar .utility-copy { display: none !important; }
.utility-divider { display: none !important; }
.utility-feedback {
  position: absolute;
  top: calc(100% + 4px);
  left: 50%;
  transform: translateX(-50%);
  z-index: 40;
  box-shadow: 0 6px 18px rgb(28 63 88 / 14%);
}

/* 游戏区：画布在上，信息卡在下 */
.game-layout {
  display: flex !important;
  flex-direction: column;
  grid-column: auto !important;
  grid-row: auto !important;
  gap: 8px !important;
  align-items: stretch;
}
.play-column {
  display: flex;
  flex-direction: column;
  padding: 8px !important;
}
.board-frame {
  width: min(100%, 420px);
  height: auto;
  min-height: 0;
  margin: 0 auto;
}
#game {
  width: 100%;
  height: auto;
  display: block;
  touch-action: none;
  outline: none;
}
.play-footer { padding-top: 8px; }
.play-footer p { font-size: .59rem; text-align: center; }

/* 信息卡：两列紧凑排列 */
.info-column {
  display: grid !important;
  grid-template-columns: 1fr 1fr !important;
  grid-template-rows: auto auto auto !important;
  gap: 7px !important;
}
.score-strip { grid-column: 1 / -1; grid-row: 1; }
.items-card { grid-column: 1 / -1; grid-row: 2; }
.next-card { grid-column: 1; grid-row: 3; min-height: 150px; }
.collection-card { grid-column: 2; grid-row: 3; min-height: 200px; }

/* 弹窗在窄屏更友好 */
.achievement-layout { gap: 12px; padding: 19px; }
.result-dialog { max-width: calc(100% - 24px); }

/* 深色背景下整页底色统一 */
body { background: var(--page); }
