* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

.game-card {
  font-family: "PingFang SC", "Microsoft YaHei", -apple-system, sans-serif;
  background: transparent;
  color: #2c3e50;
}

/* 外层容器透明：去掉外壳给 rounded-2xl 加的边框 */
.ot_workspace__inner .game-card {
  border: 0;
  box-shadow: none;
}

.app {
  margin: 0 auto;
  padding: 40px 16px 60px;
}

/* ---------- 头部 ---------- */
.app__header {
  text-align: center;
  margin-bottom: 24px;
}

.app__title {
  font-size: 30px;
  letter-spacing: 2px;
}

.app__subtitle {
  margin-top: 8px;
  color: #7f8c9b;
  font-size: 14px;
}

/* ---------- 状态条 ---------- */
.status-bar {
  display: flex;
  justify-content: center;
  gap: 28px;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 4px 16px rgba(50, 70, 100, 0.08);
  padding: 12px;
  margin-bottom: 18px;
  font-size: 14px;
  color: #8a97a6;
}

.status-bar strong {
  color: #0989E2;
  font-size: 16px;
  margin-left: 4px;
}

/* ---------- 面板 ---------- */
.panel {
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 6px 24px rgba(50, 70, 100, 0.08);
  padding: 36px 32px;
  text-align: center;
}

.panel__title {
  font-size: 22px;
  margin-bottom: 14px;
}

.panel__desc {
  color: #5a6a7e;
  font-size: 15px;
  line-height: 1.8;
  margin-bottom: 24px;
}

.panel__desc strong {
  color: #0989E2;
}

.intro-emoji {
  font-size: 44px;
  margin-bottom: 12px;
}

.is-hidden {
  display: none;
}

/* ---------- 按钮 ---------- */
.btn {
  padding: 12px 34px;
  border: none;
  border-radius: 8px;
  font-size: 16px;
  cursor: pointer;
  background: #e8edf5;
  color: #2c3e50;
  transition: all 0.15s;
}

.btn:hover {
  filter: brightness(0.96);
}

.btn:active {
  transform: scale(0.97);
}

.btn--primary {
  background: #0989E2;
  color: #fff;
}

.btn--sm {
  padding: 9px 18px;
  font-size: 14px;
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* ---------- 游戏区 ---------- */
.panel--game {
  padding: 28px 24px 30px;
}

.game-tip {
  font-size: 15px;
  color: #8a97a6;
  min-height: 24px;
  margin-bottom: 16px;
}

/* ---------- 画布 ---------- */
.board {
  position: relative;
  width: 100%;
  height: 440px;
  background:
    linear-gradient(#eef2f8 1px, transparent 1px),
    linear-gradient(90deg, #eef2f8 1px, transparent 1px);
  background-size: 40px 40px;
  background-color: #f7f9fc;
  border: 2px solid #dfe6f0;
  border-radius: 12px;
  overflow: hidden;
  user-select: none;
  touch-action: manipulation;
}

/* 数字块 */
.num-block {
  position: absolute;
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  font-weight: 700;
  border-radius: 12px;
  background: #fff;
  color: #2c3e50;
  border: 2px solid #0989E2;
  box-shadow: 0 3px 10px rgba(74, 125, 255, 0.25);
  cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s, transform 0.1s;
}

.num-block:hover {
  transform: scale(1.06);
}

.num-block:active {
  transform: scale(0.95);
}

/* 数字 1 的引导高亮 */
.num-block--first {
  border-color: #faad14;
  color: #faad14;
  box-shadow: 0 3px 10px rgba(250, 173, 20, 0.35);
}

/* 纯色遮盖状态 */
.num-block--hidden {
  background: #0989E2;
  border-color: #0989E2;
  color: transparent;
  box-shadow: 0 3px 10px rgba(74, 125, 255, 0.25);
}

/* 点对：恢复显示 */
.num-block--revealed {
  background: #fff;
  border-color: #7bc88f;
  color: #3d8b52;
  cursor: default;
}

.num-block--revealed:hover {
  transform: none;
}

/* 点错：标红 */
.num-block--wrong {
  background: #ff4d4f !important;
  border-color: #ff4d4f !important;
  color: #fff !important;
  animation: shake 0.3s;
  cursor: default;
}

.num-block--wrong:hover {
  transform: none;
}

/* 结束后普通数字恢复展示 */
.num-block--plain {
  background: #fff;
  border-color: #dfe6f0;
  color: #8a97a6;
  cursor: default;
  box-shadow: none;
}

.num-block--plain:hover {
  transform: none;
}

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-6px); }
  75% { transform: translateX(6px); }
}

.game-actions {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 20px;
}

/* ---------- 结果 ---------- */
.result {
  display: flex;
  justify-content: center;
  gap: 24px;
  flex-wrap: wrap;
  margin: 24px 0 30px;
}

.result__item {
  min-width: 130px;
  padding: 20px 16px;
  background: #f6f8fc;
  border-radius: 12px;
}

.result__num {
  font-size: 30px;
  font-weight: 700;
  color: #0989E2;
}

.result__label {
  margin-top: 6px;
  font-size: 13px;
  color: #8a97a6;
}

.result__actions {
  display: flex;
  justify-content: center;
  gap: 14px;
}

/* ---------- 底部介绍 ---------- */
.intro-footer {
  margin-top: 36px;
}

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

.intro-card {
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 6px 24px rgba(50, 70, 100, 0.08);
  padding: 24px 26px;
  text-align: left;
  display: grid;
  grid-template-columns: auto 1fr;
  grid-template-rows: auto auto;
  column-gap: 18px;
  align-items: center;
}

.intro-card__icon {
  grid-row: 1 / span 2;
  font-size: 30px;
}

.intro-card__title {
  align-self: end;
  font-size: 17px;
  margin-bottom: 6px;
  color: #2c3e50;
}

.intro-card__text {
  align-self: start;
  font-size: 13px;
  line-height: 1.9;
  color: #5a6a7e;
}

.intro-card__text strong {
  color: #0989E2;
  font-weight: 600;
}

@media (max-width: 700px) {
  .board {
    height: 340px;
  }

  .num-block {
    width: 44px;
    height: 44px;
    font-size: 19px;
    border-radius: 10px;
  }
}
