.x-match {
    max-width: 1000px;
    margin: 25px auto;
    padding: 24px;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 14px;
    color: #111;
    font-family: inherit;
}

.x-match * {
    box-sizing: border-box;
}

.x-match-title {
    font-size: 25px;
    font-weight: 800;
    margin-bottom: 7px;
}

.x-match-instruction {
    color: #666;
    margin-bottom: 22px;
}

.x-match-table {
    width: 100%;
}

.x-match-head,
.x-match-body {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 18px;
}

.x-match-head {
    margin-bottom: 10px;
    font-weight: 800;
    font-size: 14px;
    letter-spacing: .5px;
}

.x-match-column-a,
.x-match-column-b {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.x-match-static-card,
.x-match-card {
    min-height: 64px;
    padding: 14px 16px;
    border-radius: 10px;
    display: flex;
    align-items: center;
}

.x-match-static-card {
    background: #f7f7f7;
    border: 1px solid #ddd;
    font-weight: 700;
}

.x-match-card {
    background: #fff;
    border: 1px solid #c8c8c8;
    box-shadow: 0 2px 8px rgba(0,0,0,.07);
    font-weight: 700;
    cursor: grab;
    user-select: none;
    -webkit-user-select: none;
    touch-action: none;
    transition: transform .12s ease, opacity .12s ease;
}

.x-match-card:hover {
    transform: translateY(-2px);
}

.x-match-card.x-dragging,
.x-match-card.x-touch-dragging {
    opacity: .55;
    transform: scale(1.025);
    cursor: grabbing;
}

.x-match-drag-icon {
    margin-right: 12px;
    font-size: 19px;
    line-height: 1;
    letter-spacing: -3px;
    color: #888;
}

.x-match-actions {
    display: flex;
    gap: 10px;
    margin-top: 22px;
}

.x-match-actions button {
    border: 0;
    border-radius: 8px;
    padding: 12px 22px;
    font-weight: 800;
    cursor: pointer;
}

.x-match-submit {
    background: #111;
    color: #fff;
}

.x-match-reset {
    background: #ddd;
    color: #111;
}

.x-match-card.x-correct {
    border: 2px solid #25823b;
    background: #f2fbf4;
}

.x-match-card.x-wrong {
    border: 2px solid #c62828;
    background: #fff3f3;
}

.x-match-result {
    display: none;
    margin-top: 18px;
    padding: 15px;
    border-radius: 10px;
}

.x-match-result.x-scored,
.x-match-result.x-perfect {
    display: block;
}

.x-match-result.x-scored {
    background: #f4f4f4;
}

.x-match-result.x-perfect {
    background: #edf8ef;
}

.x-match-score {
    font-size: 30px;
    font-weight: 900;
}

.x-match-percent {
    font-size: 17px;
    margin: 2px 0 5px;
}

.x-match-error {
    padding: 14px;
    border-radius: 8px;
    background: #fff3f3;
    color: #8a1f1f;
}

@media (max-width: 700px) {
    .x-match {
        padding: 16px;
    }

    .x-match-head,
    .x-match-body {
        grid-template-columns: 1fr 1fr;
        gap: 8px;
    }

    .x-match-static-card,
    .x-match-card {
        min-height: 60px;
        padding: 12px 10px;
        font-size: 14px;
    }

    .x-match-drag-icon {
        margin-right: 7px;
    }
}
