/* 色差感知（找不同色块）测试 */
.main {
    grid-template-columns: minmax(0, 1fr) 400px;
}

.mode-note {
    font-size: 13px;
    color: #6b7280;
    line-height: 1.7;
    background: #f9fafb;
    border: 1px solid #eef0f4;
    border-radius: 8px;
    padding: 10px 12px;
}

.zone {
    border-radius: 14px;
    min-height: 380px;
    padding: 30px 20px;
    text-align: center;
    user-select: none;
    -webkit-user-select: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 14px;
    transition: background .25s ease, box-shadow .25s ease;
}
.zone.idle {
    background: #f1f2f4;
    border: 2px dashed #d1d5db;
    color: #6b7280;
}
.zone.play {
    background: #f8fafc;
    border: 2px solid #e2e8f0;
    color: #334155;
}
.zone.over {
    background: linear-gradient(135deg, #0ea5e9 0%, #22c55e 160%);
    border: 2px solid #10b981;
    color: #083344;
}
.zone .z-big {
    font-size: 88px;
    font-weight: 800;
    line-height: 1;
}
.zone .z-big.hidden { display: none; }
.zone .z-sub {
    font-size: 17px;
    opacity: .9;
}
.zone .z-cps {
    font-size: 14px;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
    background: rgba(255, 255, 255, .9);
    border-radius: 999px;
    padding: 5px 16px;
    box-shadow: 0 1px 4px rgba(0, 0, 0, .06);
}
.zone .z-cps.hidden { display: none; }

.grid-wrap {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    width: 100%;
    max-width: 420px;
}
.grid-wrap.hidden { display: none; }
.swatch {
    aspect-ratio: 1 / 1;
    border-radius: 10px;
    cursor: pointer;
    box-shadow: 0 1px 3px rgba(0, 0, 0, .08);
    transition: transform .12s ease, box-shadow .12s ease;
    border: 2px solid rgba(0, 0, 0, .04);
}
.swatch:hover {
    transform: scale(1.04);
    box-shadow: 0 3px 10px rgba(0, 0, 0, .14);
}
.swatch.hit {
    box-shadow: 0 0 0 4px #22c55e;
    transform: scale(1.06);
}
.swatch.miss {
    box-shadow: 0 0 0 4px #ef4444;
    transform: scale(0.96);
}

.zone-btn {
    margin-top: 6px;
    padding: 11px 30px;
    font-size: 16px;
    font-weight: 700;
    color: #fff;
    background: #0ea5e9;
    border: none;
    border-radius: 999px;
    cursor: pointer;
    box-shadow: 0 3px 10px rgba(0, 0, 0, .15);
    transition: background .2s ease, transform .15s ease;
}
.zone-btn:hover {
    background: #0284c7;
    transform: translateY(-1px);
}
.zone-btn.hidden { display: none; }
.zone-btns { display: flex; gap: 10px; }

.z-report {
    width: 100%;
    max-width: 420px;
    text-align: left;
    background: rgba(255, 255, 255, .92);
    border-radius: 10px;
    padding: 10px 12px;
}
.z-report.hidden { display: none; }
.rep-head {
    font-size: 13px;
    font-weight: 700;
    color: #083344;
    margin-bottom: 6px;
}
.rep-body {
    max-height: 190px;
    overflow-y: auto;
    font-size: 13px;
}
.rep-row {
    display: flex;
    justify-content: space-between;
    padding: 3px 2px;
    border-bottom: 1px dashed #e5e7eb;
    color: #334155;
}
.rep-row .rep-ed {
    font-weight: 700;
    color: #0ea5e9;
    font-variant-numeric: tabular-nums;
}

/* ---- 统计 ---- */
.stat-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    margin-top: 12px;
}
.stat {
    background: #f9fafb;
    border: 1px solid #eef0f4;
    border-radius: 8px;
    padding: 12px 8px;
    text-align: center;
    transition: border-color .2s ease, background .2s ease, box-shadow .2s ease;
}
.stat b {
    display: block;
    font-size: 20px;
    font-weight: 800;
    color: #4338ca;
    font-variant-numeric: tabular-nums;
    line-height: 1.3;
}
.stat span {
    display: block;
    margin-top: 3px;
    font-size: 12px;
    color: #6b7280;
}
.stat.best {
    background: #f0fdf4;
    border-color: #bbf7d0;
    box-shadow: 0 1px 4px rgba(22, 163, 74, .08);
}
.stat.best b {
    color: #16a34a;
}

/* ---- 历史记录 ---- */
.record-title {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
    font-weight: 600;
    color: #374151;
    margin: 16px 0 8px;
}
.record-title .link-btn {
    background: #f3f4f6;
    border: 1px solid #e5e7eb;
    border-radius: 999px;
    font-size: 12px;
    color: #6b7280;
    cursor: pointer;
    padding: 4px 12px;
    transition: background .2s ease, color .2s ease, border-color .2s ease;
}
.record-title .link-btn:hover {
    background: #fef2f2;
    border-color: #fca5a5;
    color: #ef4444;
}