/* Let's go! · 科普竞赛 */
.view-body--games {
  flex: 1;
  min-height: 0;
  overflow: auto;
  padding: 0.1rem 0.2rem 0.25rem;
  display: flex;
  flex-direction: column;
}
#lcRoot {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: auto;
}
.lc-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem 0.7rem;
  margin: 0 0 0.3rem;
  flex: 0 0 auto;
}
.lc-head h2 {
  margin: 0;
  font-size: clamp(0.95rem, 1.8vw, 1.15rem);
  font-weight: 700;
}
.lc-head p {
  margin: 0;
  font-size: 0.78rem;
  color: #375a63;
  flex: 1;
  min-width: 12rem;
}

/* 选关：照片铺满卡片，说明条贴在照片下方，绝不叠字（对齐 Flutter 生命游戏） */
.lc-hub {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.7rem;
  flex: 1;
  min-height: 0;
}
.lc-hub.three {
  grid-template-columns: 1fr 1fr 1fr;
  flex: 0 0 auto;
  min-height: auto;
  align-content: start;
  gap: 0.55rem;
  padding-bottom: 0.45rem;
}
.lc-hub.three .lc-card {
  height: auto;
  min-height: auto;
  isolation: isolate;
}
.lc-hub.three .lc-card-photos,
.lc-card-cover {
  display: block;
  position: relative;
  flex: none;
  height: auto;
  min-height: 0;
  max-height: none;
  aspect-ratio: 4 / 3;
  grid-template-columns: none;
  grid-template-rows: none;
  overflow: hidden;
}
.lc-hub.three .lc-card-photos img,
.lc-card-cover img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  flex: none;
  object-fit: cover;
  object-position: center center;
  display: block;
}
.lc-hub.three .lc-card-body { padding: 0.42rem 0.65rem 0.5rem; }
.lc-hub.three .lc-card-body b { font-size: 0.92rem; }
.lc-card {
  display: flex;
  flex-direction: column;
  min-height: 0;
  height: 100%;
  border: 2px solid #b6d6db;
  border-radius: 14px;
  background: #fffef8;
  overflow: hidden;
  cursor: pointer;
  text-align: left;
  font: inherit;
  color: inherit;
  padding: 0;
  box-shadow: 0 8px 22px rgba(0,0,0,.08);
  transition: transform .2s, border-color .2s, box-shadow .2s;
}
.lc-card:hover, .lc-card:focus-visible {
  transform: translateY(-3px);
  border-color: #1e88e5;
  box-shadow: 0 12px 28px rgba(0,131,143,.18);
  outline: none;
}
.lc-card:focus-visible {
  outline: 3px solid #1e88e5;
  outline-offset: 3px;
}
.lc-card-photos {
  flex: 1 1 auto;
  min-height: 14rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: 1fr 1fr;
  background: #0d3b4a;
  overflow: hidden;
  position: relative;
  z-index: 0;
}
.lc-card-photos figure {
  margin: 0;
  min-width: 0;
  min-height: 0;
  height: 100%;
  overflow: hidden;
  position: relative;
  display: flex;
  flex-direction: column;
}
.lc-card-photos img {
  width: 100%;
  flex: 1 1 0;
  min-height: 0;
  height: 0;
  object-fit: cover;
  object-position: center 38%;
  display: block;
}
.lc-card-photos figcaption {
  position: static;
  z-index: 1;
  margin: 0;
  padding: 0.18rem 0.35rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: .02em;
  color: #fffef8;
  background: #0d3b4a;
  text-align: center;
  pointer-events: none;
  flex: 0 0 auto;
}
.lc-card-body {
  flex: 0 0 auto;
  position: relative;
  z-index: 2;
  padding: 0.5rem 0.8rem 0.55rem;
  background: #fffef8;
  border-top: 1px solid #cfe4e8;
}
.lc-card-body b {
  display: block;
  font-size: 1.08rem;
  color: #1a1a1a;
  margin-bottom: 0.2rem;
}
.lc-card-body span {
  font-size: 0.8rem;
  color: #4a6570;
  line-height: 1.45;
}
.lc-badge {
  display: inline-block;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: #0d47a1;
  background: #e0f7fa;
  border: 1px solid #4dd0e1;
  border-radius: 999px;
  padding: 0.12rem 0.5rem;
  margin-bottom: 0.35rem;
}
.lc-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  align-items: center;
  margin-bottom: 0.35rem;
  flex: 0 0 auto;
}
.lc-toolbar .sub { margin: 0; font-size: 0.78rem; color: #375a63; flex: 1; min-width: 10rem; }
.lc-msg {
  min-height: 1.2em;
  margin: 0.2rem 0 0;
  font-size: 0.82rem;
  font-weight: 600;
  color: #375a63;
  text-align: center;
}
.lc-msg.ok { color: #2e7d32; }
.lc-msg.bad { color: #c62828; }
.pg-quiz {
  display: grid;
  grid-template-columns: minmax(14rem, 1.1fr) minmax(16rem, 1fr);
  gap: 0.7rem;
  flex: 1;
  min-height: 0;
}
.pg-photo {
  border-radius: 14px;
  overflow: hidden;
  background: #0d3b4a;
  min-height: 12rem;
}
.pg-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.pg-q {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}
.pg-q h3 {
  margin: 0;
  font-size: clamp(0.95rem, 1.7vw, 1.2rem);
  line-height: 1.35;
}
.pg-q h3 small {
  display: block;
  margin-top: 0.2rem;
  color: #4a6570;
  font-size: 0.82rem;
  font-weight: 600;
}
.pg-choices {
  display: grid;
  gap: 0.4rem;
}
.pg-choice {
  text-align: left;
  font: inherit;
  padding: 0.55rem 0.7rem;
  border-radius: 10px;
  border: 2px solid #b6d6db;
  background: #fff;
  cursor: pointer;
  color: #1a1a1a;
}
.pg-choice b { display: block; }
.pg-choice small { display: block; color: #4a6570; margin-top: 0.12rem; }
.pg-choice.is-sel { border-color: #1e88e5; background: #e0f7fa; }
.pg-choice.is-ok { border-color: #43a047; background: #e8f5e9; }
.pg-choice.is-bad { border-color: #c62828; background: #ffebee; }
.pg-fact {
  font-size: 0.82rem;
  line-height: 1.45;
  background: #e0f7fa;
  border-radius: 10px;
  padding: 0.5rem 0.65rem;
  color: #0d47a1;
}
.pg-score {
  font-weight: 800;
  color: #1e88e5;
}
.lc-match {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.55rem 0.8rem;
  flex: 1;
  min-height: 0;
}
.lc-match-col { display: flex; flex-direction: column; gap: 0.4rem; min-height: 0; overflow: auto; }
.lc-m-photo, .lc-m-text {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  border: 2px solid #b6d6db;
  border-radius: 12px;
  background: #fff;
  padding: 0.3rem 0.45rem;
  cursor: pointer;
  text-align: left;
  font: inherit;
  color: inherit;
  min-height: 4.4rem;
}
.lc-m-photo.is-sel, .lc-m-text.is-sel { border-color: #1e88e5; box-shadow: 0 0 0 2px #4dd0e1; }
.lc-m-photo.is-ok, .lc-m-text.is-ok { border-color: #43a047; background: #f1f8e9; cursor: default; }
.lc-m-photo.is-bad, .lc-m-text.is-bad { animation: lcShake .35s; border-color: #c62828; }
.lc-m-photo img {
  width: 6.2rem;
  height: 4.4rem;
  object-fit: cover;
  border-radius: 8px;
  flex-shrink: 0;
  background: #222;
}
.lc-m-text b {
  font-family: "Source Serif 4", Georgia, serif;
  font-size: clamp(0.82rem, 1.5vw, 0.98rem);
  font-weight: 700;
}
.lc-m-text small { display: block; color: #4a6570; font-weight: 600; margin-top: 0.15rem; }
@keyframes lcShake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-5px); }
  75% { transform: translateX(5px); }
}
.trip-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}
.trip-actions .btn {
  min-height: 44px;
}
.trip-sort {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  margin-top: 0.15rem;
}
.trip-sort-lab {
  margin: 0;
  font-size: 0.78rem;
  font-weight: 600;
  color: #375a63;
}
.trip-sort-line,
.trip-sort-pool {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  min-height: 2.6rem;
  padding: 0.4rem;
  border-radius: 12px;
  border: 2px dashed #b6d6db;
  background: #fff;
}
.trip-sort-line {
  border-style: solid;
  background: #f7fbff;
  min-height: 3.1rem;
}
.trip-sort-line.is-ok {
  border-color: #43a047;
  background: #e8f5e9;
}
.trip-tile {
  font: inherit;
  font-weight: 800;
  font-size: 1rem;
  padding: 0.4rem 0.7rem;
  min-height: 44px;
  border-radius: 999px;
  border: 2px solid #1e88e5;
  background: #e3f2fd;
  color: #0d47a1;
  cursor: pointer;
  touch-action: manipulation;
}
.trip-tile.is-used {
  opacity: 0.35;
  cursor: default;
  border-color: #b0bec5;
  background: #eceff1;
  color: #78909c;
}
@media (max-width: 820px) {
  .trip-ask { grid-template-columns: 1fr; }
}
@media (pointer: coarse) and (max-width: 1024px), (max-width: 820px) {
  .book-top-right .btn { flex: 1 1 calc(50% - 0.35rem) !important; }
  .lc-hub, .lc-hub.three { grid-template-columns: 1fr; }
  .pg-quiz, .lc-match { grid-template-columns: 1fr; }
}
