/* c4games.css · 综合与实践（第四大陆）18关动手小游戏 · 干净护眼浅色主题 */
.c4 {
  position: relative; width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(160deg, #eafaf1 0%, #eef3ff 55%, #fdf3ff 100%);
  padding: 10px; box-sizing: border-box;
}
.c4-card {
  width: 100%; max-width: 960px; background: #fffdf9;
  border: 3px solid #ece2f8; border-radius: 28px;
  box-shadow: 0 14px 40px rgba(120, 100, 180, .18);
  padding: 18px 22px; display: flex; flex-direction: column; align-items: center;
  box-sizing: border-box; min-height: 480px; max-height: 92vh; overflow-y: auto;
}
.c4-prompt { font-size: 25px; font-weight: 800; color: #4a3f6b; text-align: center; margin: 4px 0 10px; line-height: 1.35; }
.c4-hint { font-size: 18px; font-weight: 600; color: #8a7fb0; text-align: center; min-height: 26px; margin-top: 10px; }
.c4-stage { position: relative; flex: 1; width: 100%; min-height: 430px; }

/* 通用元素 */
.c4-item { position: absolute; cursor: grab; user-select: none; z-index: 5; touch-action: none; }
.c4-item.dragging, .c4-drag.grabbing { cursor: grabbing; z-index: 30; filter: drop-shadow(0 8px 16px rgba(90, 70, 150, .35)); }
.c4-drag { cursor: grab; }
.c4-btn {
  border: none; border-radius: 18px; padding: 15px 30px; font-size: 21px; font-weight: 800;
  color: #fff; background: linear-gradient(180deg, #9b7bff, #7a4cc0);
  box-shadow: 0 8px 18px rgba(122, 76, 192, .35); cursor: pointer; margin: 12px auto 0; display: block;
  transition: transform .12s ease;
}
.c4-btn:hover { transform: translateY(-2px); }
.c4-btn:active { transform: scale(.97); }
.c4-btn.c4-ghost { background: #fff; color: #7a4cc0; border: 3px solid #cdbce8; box-shadow: none; }

.c4-tile {
  display: flex; align-items: center; justify-content: center; min-width: 60px; min-height: 60px;
  padding: 8px 14px; border-radius: 16px; background: #fff3cf; color: #5a4a1a;
  font-size: 24px; font-weight: 800; text-align: center; box-shadow: 0 5px 12px rgba(0, 0, 0, .1);
  border: 3px solid #fff;
}
.c4-num { background: #fff3cf; }
.c4-month { flex-direction: column; background: #ffe2ef; color: #7a2d52; min-width: 78px; }
.c4-month b { font-size: 26px; }
.c4-month span { font-size: 14px; }
.c4-digit { background: #cfe8ff; color: #1b4f7a; min-width: 54px; }
.c4-digit.c4-fixed { background: #e7eef8; color: #3a4a5a; border-style: dashed; }
.c4-pattern { background: #e9e1ff; color: #5a3f8a; font-size: 30px; min-width: 60px; }
.c4-pattern.c4-fixed { background: #eee6f8; border-style: dashed; }
.c4-fixed { cursor: default; }

/* 钟面 */
.c4-clockarea { position: relative; width: 360px; height: 360px; margin: 4px auto; }
.c4-clockface { position: absolute; left: 30px; top: 30px; }
.c4-clockslot {
  position: absolute; width: 40px; height: 40px; border-radius: 50%;
  border: 3px dashed #cdbce8; background: rgba(205, 188, 232, .12);
}
.c4-clockslot.filled { border-style: solid; border-color: #5eead4; background: #5eead4; }
.c4-handwrap { position: absolute; width: 10px; margin-left: -5px; transform-origin: 50% 100%; z-index: 8; }
.c4-hand { width: 10px; border-radius: 6px; margin: 0 auto; box-shadow: 0 2px 6px rgba(0, 0, 0, .2); }
.c4-handwrap.grab { cursor: grabbing; }
.c4-handwrap::after { content: ''; position: absolute; left: -5px; top: -5px; width: 20px; height: 20px; border-radius: 50%; background: #8a5cff; }
.c4-clockarea { transition: box-shadow .3s ease; }
.c4-clockarea.c4-clock-done { box-shadow: 0 0 0 8px rgba(94, 234, 212, .4); border-radius: 50%; }
.c4-clock-tray { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; max-width: 360px; margin: 8px auto 0; padding: 8px; border: 3px dashed #ffd56b; border-radius: 18px; background: rgba(255, 213, 107, .12); }
.c4-clock-tile { position: relative !important; left: auto !important; top: auto !important; }
.c4-slot-flash { animation: c4-slotFlash .7s ease 2; }
@keyframes c4-slotFlash { 0%,100% { box-shadow: inset 0 0 0 0 rgba(94,234,212,0); } 50% { box-shadow: inset 0 0 0 6px rgba(94,234,212,.7); } }

/* 收纳筐 / 分组 / 抽屉 */
.c4-bins { display: flex; gap: 30px; justify-content: center; margin: 6px 0 0; flex-wrap: wrap; }
.c4-bin {
  width: 140px; min-height: 120px; border-radius: 0 0 20px 20px; padding-top: 26px;
  border: 4px solid var(--bc, #8a5cff); background: color-mix(in srgb, var(--bc) 16%, #fff);
  position: relative; display: flex; flex-direction: column; align-items: center;
}
.c4-bin-label { position: absolute; top: -34px; left: 0; right: 0; text-align: center; font-weight: 800; font-size: 17px; color: #4a3f6b; }
.c4-bin-label small { display: block; font-size: 13px; color: #8a7fb0; font-weight: 700; }
.c4-bin-mouth { position: absolute; top: 0; left: 6%; right: 6%; height: 16px; background: color-mix(in srgb, var(--bc) 55%, #fff); border-radius: 0 0 14px 14px; }
.c4-binflat { padding-top: 8px; min-height: 130px; }
.c4-bincount { font-size: 26px; font-weight: 800; color: #1b4f7a; margin-top: auto; margin-bottom: 10px; }
.c4-bin-progress { font-size: 15px; font-weight: 800; color: #6a5f8a; margin-top: auto; margin-bottom: 8px; }
.c4-bin-flash { animation: c4-binFlash .7s ease 2; }
@keyframes c4-binFlash { 0%,100% { box-shadow: 0 0 0 0 rgba(94,234,212,0); } 50% { box-shadow: 0 0 0 8px rgba(94,234,212,.55); } }
.c4-month { position: relative; }
.c4-month-days { position: absolute; right: -6px; top: -6px; background: #7a4cc0; color: #fff; font-size: 11px; font-weight: 800; padding: 2px 6px; border-radius: 10px; }
.c4-drawer { background: color-mix(in srgb, var(--bc) 14%, #fff); }

/* 商店 / 钱币 */
.c4-shop { display: flex; flex-direction: column; align-items: center; gap: 8px; margin-bottom: 6px; }
.c4-product { font-size: 54px; display: flex; flex-direction: column; align-items: center; }
.c4-price { font-size: 22px; font-weight: 800; color: #c0392b; }
.c4-total { font-size: 22px; font-weight: 800; color: #4a3f6b; margin: 6px 0; }
.c4-tray { display: flex; gap: 16px; flex-wrap: wrap; justify-content: center; align-items: center; margin-top: 12px; padding: 10px; }
.c4-coinbtn { cursor: pointer; transition: transform .12s ease; }
.c4-coinbtn:hover { transform: scale(1.08); }
.c4-coinbtn:active { transform: scale(.94); }

/* 秒表 */
.c4-stopwrap { display: flex; flex-direction: column; align-items: center; gap: 6px; margin: 10px 0; }
.c4-stopnum { font-size: 48px; font-weight: 800; color: #7a4cc0; }

/* 配对两列 */
.c4-paircols { display: flex; gap: 60px; justify-content: center; align-items: flex-start; flex-wrap: wrap; margin-top: 8px; }
.c4-pcol { display: flex; flex-direction: column; gap: 14px; align-items: center; }
.c4-pcoltitle { font-size: 20px; font-weight: 800; color: #6a5f8a; }
.c4-pair { background: #fff3cf; min-width: 200px; }
.c4-slot { min-width: 200px; min-height: 60px; border: 3px dashed #cdbce8; border-radius: 16px; background: rgba(255, 255, 255, .5); display: flex; align-items: center; justify-content: center; font-size: 22px; font-weight: 800; color: #6a5f8a; }
.c4-slot.filled { border-style: solid; border-color: #5eead4; background: #5eead4; color: #1b5e4a; }
.c4-slotnum, .c4-slotpat { min-width: 70px; min-height: 70px; font-size: 30px; }

/* 搭配：衣橱 + 试衣镜 + 相册 */
.c4-wardrobe { position: absolute; top: 0; left: 0; right: 0; height: 130px; display: flex; justify-content: space-around; align-items: flex-start; padding-top: 6px; pointer-events: none; }
.c4-wardrobe-col { display: flex; flex-direction: column; align-items: center; gap: 6px; pointer-events: auto; }
.c4-wardrobe-title { font-size: 16px; font-weight: 800; color: #6a5f8a; background: rgba(255, 255, 255, .75); padding: 5px 13px; border-radius: 14px; box-shadow: 0 2px 6px rgba(120, 100, 180, .08); }
.c4-wardrobe-piece { filter: drop-shadow(0 3px 5px rgba(90, 70, 150, .12)); }
.c4-mirror { position: absolute; top: 128px; left: 50%; transform: translateX(-50%); width: 300px; height: 205px; background: linear-gradient(160deg, #fff 0%, #f6f0ff 100%); border: 4px solid #cdbce8; border-radius: 26px; box-shadow: 0 10px 28px rgba(120, 100, 180, .12); display: flex; flex-direction: column; align-items: center; padding: 8px 0 10px; box-sizing: border-box; }
.c4-mirror-title { font-size: 18px; font-weight: 800; color: #4a3f6b; margin-bottom: 6px; }
.c4-mirror-slots { display: flex; flex-direction: column; align-items: center; gap: 8px; width: 100%; flex: 1; justify-content: center; }
.c4-dress-slot { width: 92px; height: 48px; border: 3px dashed #bdb1dd; border-radius: 16px; background: rgba(255, 255, 255, .6); display: flex; align-items: center; justify-content: center; position: relative; transition: background .2s ease, border-color .2s ease; }
.c4-slot-label { font-size: 14px; font-weight: 700; color: #9d92c0; }
.c4-outfit-album { position: absolute; bottom: 0; left: 0; right: 0; height: 112px; border: 3px dashed #cdbce8; border-radius: 18px; background: rgba(255, 255, 255, .6); padding: 8px; box-sizing: border-box; display: flex; flex-direction: column; }
.c4-outfit-album .c4-album-title { font-size: 15px; font-weight: 800; color: #4a3f6b; text-align: center; margin-bottom: 4px; }
.c4-album-photos { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; overflow-y: auto; flex: 1; }
.c4-photo { width: 56px; height: 56px; border-radius: 12px; border: 2px solid #5eead4; background: #eafaf1; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.c4-photo svg { width: 30px; height: 30px; }

/* 时间轴 / 工序 */
.c4-timeline { display: flex; gap: 14px; justify-content: center; margin: 8px 0; }
.c4-lane { width: 200px; min-height: 120px; border: 3px dashed #cdbce8; border-radius: 16px; background: rgba(255, 255, 255, .5); display: flex; flex-direction: column; gap: 8px; padding: 10px; align-items: center; }
.c4-task { background: #cfe8ff; color: #1b4f7a; border-radius: 14px; padding: 10px 14px; font-size: 20px; font-weight: 800; text-align: center; cursor: grab; box-shadow: 0 4px 10px rgba(0, 0, 0, .12); }
.c4-task span { display: block; font-size: 13px; font-weight: 600; color: #3a6a8a; }
.c4-task.locked { opacity: .55; }

/* 折扣 */
.c4-discount { display: flex; flex-direction: column; gap: 12px; margin: 6px 0; width: 100%; max-width: 560px; }
.c4-ditem { background: #fff; border: 3px solid #ece2f8; border-radius: 16px; padding: 10px 14px; }
.c4-dname { font-size: 20px; font-weight: 800; color: #4a3f6b; }
.c4-dopts { display: flex; gap: 12px; margin: 8px 0; }
.c4-sticker { border: none; border-radius: 14px; padding: 8px 16px; font-size: 19px; font-weight: 800; background: #ffd56b; color: #7a4a00; cursor: pointer; box-shadow: 0 4px 10px rgba(0, 0, 0, .12); }
.c4-sticker.sel { background: #9b7bff; color: #fff; }
.c4-dfinal { font-size: 18px; font-weight: 700; color: #2c7a4f; }

/* 购物车 */
.c4-list-panel { width: 100%; max-width: 560px; border: 3px solid #ffd56b; border-radius: 18px; padding: 12px 16px; background: #fffbe6; margin: 4px auto 10px; }
.c4-list-title { font-size: 20px; font-weight: 800; color: #7a4a00; text-align: center; margin-bottom: 8px; }
.c4-list-items { display: flex; gap: 10px; flex-wrap: wrap; justify-content: center; }
.c4-list-item { display: flex; align-items: center; gap: 6px; background: #fff; border: 2px solid #ffe082; border-radius: 12px; padding: 6px 12px; font-size: 18px; font-weight: 700; color: #4a3f6b; }
.c4-list-item.done { background: #eafaf1; border-color: #5eead4; }
.c4-list-check { font-size: 20px; }
.c4-cart { width: 100%; max-width: 520px; border: 3px solid #ece2f8; border-radius: 18px; padding: 12px 16px; background: #fff; margin-bottom: 8px; }
.c4-cart-label { font-size: 20px; font-weight: 800; color: #4a3f6b; }
.c4-cart-items { display: flex; gap: 8px; flex-wrap: wrap; min-height: 36px; margin: 8px 0; }
.c4-carttag { background: #eafaf1; border: 2px solid #5eead4; border-radius: 12px; padding: 4px 10px; font-size: 17px; font-weight: 700; color: #1b5e4a; }
.c4-goods { display: flex; flex-direction: column; align-items: center; font-size: 16px; font-weight: 700; color: #4a3f6b; gap: 2px; }
.c4-goods span { font-size: 14px; }
.c4-goods small { font-size: 12px; color: #8a7fb0; }
.c4-goods.c4-needed { border: 2px solid #5eead4; border-radius: 14px; background: rgba(94, 234, 212, .12); }
.c4-goods.c4-extra { opacity: .92; }

/* 植树 */
.c4-road { display: flex; gap: 8px; align-items: flex-end; justify-content: center; margin: 24px 0; padding: 0 10px; border-bottom: 8px solid #b98a5a; padding-bottom: 4px; }
.c4-plot { width: 56px; height: 64px; border: 3px dashed #cdbce8; border-bottom: none; border-radius: 12px 12px 0 0; display: flex; align-items: flex-end; justify-content: center; cursor: pointer; transition: background .12s; }
.c4-plot:hover { background: rgba(95, 184, 120, .15); }
.c4-plot.planted { border-style: solid; border-color: #5fb878; }

/* 鸡兔笼 */
.c4-cage { width: 100%; max-width: 520px; min-height: 140px; border: 4px solid #c9a06a; border-radius: 18px; background: rgba(255, 250, 240, .7); display: flex; gap: 10px; flex-wrap: wrap; align-items: center; justify-content: center; padding: 12px; margin-bottom: 6px; }
.c4-cageanim { cursor: pointer; line-height: 0; }
.c4-src { cursor: pointer; }

/* 天平 */
.c4-balance { position: relative; display: flex; gap: 40px; justify-content: center; align-items: flex-end; margin: 14px 0; }
.c4-pan { width: 130px; min-height: 90px; border: 3px solid #c9a06a; border-radius: 0 0 16px 16px; background: rgba(255, 250, 240, .8); display: flex; gap: 4px; flex-wrap: wrap; align-items: flex-end; justify-content: center; padding: 8px; }
.c4-candy { cursor: pointer; line-height: 0; }
.c4-candy.c4-found { filter: drop-shadow(0 0 8px #5eead4); }
.c4-beam { display: none; }

/* 24时计时法 */
.c4-h24-tray, .c4-h24-track { width: 100%; max-width: 720px; margin: 6px auto; border-radius: 18px; padding: 10px 14px; }
.c4-h24-tray { border: 3px dashed #7ec8ff; background: rgba(126, 200, 255, .12); }
.c4-h24-track { border: 3px dashed #a0e8af; background: rgba(160, 232, 175, .12); }
.c4-h24-title { font-size: 17px; font-weight: 800; color: #4a3f6b; text-align: center; margin-bottom: 8px; }
.c4-h24-cards, .c4-h24-slots { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; align-items: center; }
.c4-h24-card { display: flex; align-items: center; justify-content: center; min-width: 110px; padding: 10px 14px; border-radius: 14px; background: #fff; border: 3px solid #7ec8ff; color: #1b4f7a; font-size: 18px; font-weight: 800; cursor: grab; box-shadow: 0 4px 10px rgba(0, 0, 0, .1); }
.c4-h24-slot { display: flex; align-items: center; justify-content: center; min-width: 110px; min-height: 50px; border-radius: 14px; border: 3px dashed #cdbce8; background: rgba(255, 255, 255, .6); color: #6a5f8a; font-size: 18px; font-weight: 800; }
.c4-h24-slot.filled { border-style: solid; border-color: #5eead4; background: #5eead4; color: #1b5e4a; }

/* 编码 / 序列 */
.c4-postcode, .c4-seq { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; align-items: center; margin: 10px 0; }
.c4-postcode .c4-digit, .c4-seq .c4-pattern, .c4-slot { font-size: 32px; font-weight: 800; }
.c4-slotpat { font-size: 32px; }

/* 时间小火车 */
.c4-train-header { display: flex; gap: 12px; align-items: center; justify-content: center; margin: 6px 0; }
.c4-train-station { min-width: 110px; padding: 10px 14px; border-radius: 14px; text-align: center; font-size: 15px; font-weight: 700; }
.c4-train-station div { font-size: 13px; margin-bottom: 2px; }
.c4-train-station b { font-size: 22px; }
.c4-train-station.c4-start { background: #e7f5ff; border: 3px solid #7ec8ff; color: #1b4f7a; }
.c4-train-station.c4-end { background: #eafaf1; border: 3px solid #5eead4; color: #1b5e4a; }
.c4-train-arrow { font-size: 28px; font-weight: 800; color: #7a4cc0; }
.c4-train-track-wrap { width: 100%; max-width: 520px; margin: 14px auto; }
.c4-train-track { position: relative; height: 70px; border-radius: 35px; background: linear-gradient(180deg, #f0f4ff, #e7f5ff); border: 4px solid #7ec8ff; }
.c4-train { position: absolute; left: 10px; top: 50%; transform: translateY(-50%); font-size: 42px; cursor: grab; transition: transform .05s linear; user-select: none; }
.c4-train.dragging { cursor: grabbing; filter: drop-shadow(0 6px 12px rgba(90, 70, 150, .35)); }
.c4-train-flag { position: absolute; right: 10px; top: 50%; transform: translateY(-50%); font-size: 28px; }
.c4-train-ticks { display: flex; justify-content: space-between; margin-top: 6px; padding: 0 8px; font-size: 13px; font-weight: 700; color: #8a7fb0; }

/* 行程 */
.c4-trip { display: flex; flex-direction: column; align-items: center; gap: 12px; margin: 8px 0; }
.c4-speed { font-size: 22px; font-weight: 800; color: #4a3f6b; }
.c4-slider { width: 280px; height: 14px; accent-color: #7a4cc0; cursor: pointer; }

/* 优化统筹：双工作台时间轴 */
.c4-schedule-wrap { display: flex; flex-direction: column; gap: 14px; width: 100%; max-width: 680px; margin: 8px auto; }
.c4-stove { border: 3px dashed #cdbce8; border-radius: 18px; padding: 12px; background: rgba(255, 255, 255, .6); }
.c4-stove-title { font-size: 17px; font-weight: 800; color: #4a3f6b; text-align: center; margin-bottom: 8px; }
.c4-stove-lane { min-height: 74px; display: flex; flex-wrap: wrap; gap: 10px; align-items: center; padding: 8px; border-radius: 12px; background: rgba(255, 255, 255, .7); }
.c4-stove-side { border-color: #a0e8af; background: rgba(160, 232, 175, .12); }
.c4-stove-sum { font-size: 15px; font-weight: 700; color: #6a5f8a; text-align: right; margin-top: 6px; }
.c4-make { font-size: 20px; }
.c4-schedule-tray { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; align-items: center; margin-top: 10px; padding: 10px; border: 3px dashed #ffd56b; border-radius: 18px; background: rgba(255, 213, 107, .12); }
.c4-tray-title { width: 100%; text-align: center; font-size: 15px; font-weight: 800; color: #7a4a00; }
.c4-task { display: flex; flex-direction: column; align-items: center; justify-content: center; min-width: 90px; padding: 8px 12px; border-radius: 14px; background: #fff; border: 3px solid #cfe8ff; color: #1b4f7a; font-size: 16px; font-weight: 800; cursor: grab; box-shadow: 0 4px 10px rgba(0, 0, 0, .1); position: relative; }
.c4-task b { font-size: 18px; }
.c4-task span { font-size: 13px; font-weight: 600; color: #5a7a9a; }
.c4-task-tray { background: #fff3cf; border-color: #ffe082; }
.c4-schedule-wrap .c4-task { background: #fff; }
.c4-task.dragging { z-index: 30; filter: drop-shadow(0 8px 16px rgba(90, 70, 150, .35)); }
