/* ─── 盲打指法演示组件（typetrain 版）：嵌入底部 #ttDock，键盘尽量大（≥1200px 且精确指针） ─── */

#ttDock { display: none; }

@media (min-width: 1200px) and (pointer: fine) {

    #ttDock {
        display: flex;
        flex-direction: column;
        gap: 0.5rem;
        box-sizing: border-box;
        width: min(1000px, 96vw);
        margin: 0 auto;
        padding: 10px 16px 4px;
        background: linear-gradient(180deg, rgba(15, 23, 42, 0.6), rgba(15, 23, 42, 0.9));
        border: 1px solid rgba(96, 165, 250, 0.18);
        border-radius: 16px;
        color: #cbd5e1;
        user-select: none;
    }

    #ttDock .tt-th-head {
        display: flex;
        align-items: center;
        justify-content: space-between;
        font-size: 0.82rem;
        color: #94a3b8;
    }
    #ttDock .tt-th-title { display: flex; align-items: center; gap: 6px; letter-spacing: 0.05em; }
    #ttDock .tt-th-title b { color: #60a5fa; font-weight: 700; }

    /* 当前键大字回显 */
    #ttThNow {
        display: flex;
        align-items: center;
        gap: 14px;
        padding: 6px 14px;
        background: rgba(51, 65, 85, 0.25);
        border: 1px solid rgba(148, 163, 184, 0.12);
        border-radius: 10px;
    }
    #ttThNowKey {
        font-size: 2.6rem;
        font-weight: 800;
        color: #60a5fa;
        font-family: monospace;
        min-width: 58px;
        text-align: center;
        line-height: 1.1;
        margin: 0 auto;
    }

    #ttDock .tt-th-body { width: 100%; flex-shrink: 0; }
    #ttDock svg { display: block; width: 100%; height: auto; }

    /* 十指图例 */
    #ttThLegend {
        display: grid;
        grid-template-columns: repeat(5, minmax(0, 1fr));
        gap: 4px 10px;
        font-size: 0.72rem;
        color: #94a3b8;
        padding: 0 6px;
    }
    #ttThLegend i {
        display: inline-block;
        width: 10px; height: 10px;
        border-radius: 50%;
        margin-right: 5px;
        vertical-align: -1px;
    }
    #ttThLegend .tt-th-lrow { grid-column: 1 / -1; font-size: 0.66rem; color: #64748b; margin-top: 2px; }

    #ttThStat {
        font-size: 0.72rem;
        color: #64748b;
        display: flex;
        justify-content: space-between;
        padding: 0 2px 2px;
    }
}

/* 小屏双保险（JS matchMedia 也会跳过挂载） */
@media (max-width: 1199px), (pointer: coarse) {
    #ttDock { display: none !important; }
}
