
        /* ============================================================
   Vertical Subtraction — Per-Game Styles
   /maths/css/verticalsubtraction.css
   ============================================================ */

/* ===== COLOUR SCHEME ===== */
:root {
    --primary-color:       #F18805;
    --primary-hover:       #D67604;
    --primary-light:       rgba(241, 136, 5, 0.12);
    --primary-shadow:      rgba(241, 136, 5, 0.30);
    --btn-text-color:      #7a3d00;
    --hero-gradient-start: rgba(241, 136, 5, 0.15);
    --hero-gradient-end:   rgba(241, 136, 5, 0.06);
}

/* ===== GAME-SPECIFIC: level cards ===== */

.vs-level-cards {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 0.5rem;
}

.vs-level-card {
    flex: 0 1 180px;
    padding: 1.25rem 1rem;
    border: 3px solid #e5e7eb;
    border-radius: 0.75rem;
    cursor: pointer;
    transition: all 0.2s ease;
    background: white;
    text-align: center;
}

.vs-level-card:hover {
    border-color: var(--primary-color);
    transform: translateY(-3px);
    box-shadow: 0 6px 20px var(--primary-shadow);
}

.vs-level-card.active {
    border-color: var(--primary-color);
    background: var(--primary-light);
}

.vs-level-number {
    font-size: 2.2rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 0.4rem;
}

.vs-level-title {
    font-size: 1rem;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 0.5rem;
}

.vs-level-card ul {
    list-style: none;
    padding: 0;
    margin: 0;
    font-size: 0.82rem;
    color: #6b7280;
    line-height: 1.7;
}

/* ===== GAME-SPECIFIC: question text ===== */

.vs-question-text {
    text-align: center;
    font-size: 1.6rem;
    font-weight: 700;
    color: #1f2937;
    padding: 0.75rem 1rem;
    background: var(--primary-light);
    border-radius: 0.5rem;
    border-left: 4px solid var(--primary-color);
    margin-bottom: 0.75rem;
    font-family: 'Courier New', monospace;
}

/* ===== GAME-SPECIFIC: instructions ===== */

.vs-instructions {
    text-align: center;
    font-size: 0.92rem;
    color: #6b7280;
    background: #f9fafb;
    border-radius: 0.4rem;
    padding: 0.5rem 1rem;
    margin-bottom: 0.5rem;
}

/* ===== GAME-SPECIFIC: column subtraction grid ===== */

.problem-container {
    display: flex;
    justify-content: center;
    margin: 0.5rem 0;
    overflow-x: auto;
}

.vs-column-subtraction {
    display: table !important;
    border-collapse: collapse;
    margin: 0 auto;
    white-space: nowrap;
}

.vs-carry-row, .vs-number-row, .vs-answer-row {
    display: table-row !important;
}

.vs-digit-cell {
    display: table-cell !important;
    padding: 6px;
    text-align: center;
    vertical-align: middle;
    min-width: 60px;
    width: 70px;
    height: 70px;
}

.vs-carry-cell {
    display: table-cell !important;
    padding: 4px;
    text-align: center;
    vertical-align: top;
    min-width: 60px;
    width: 70px;
    height: 48px;
}

.vs-operator-cell {
    display: table-cell !important;
    padding: 6px;
    text-align: center;
    vertical-align: middle;
    min-width: 40px;
    width: 50px;
    font-size: 2.4rem;
    font-weight: 700;
    color: var(--primary-color);
}

.vs-answer-row { border-top: 3px solid #1f2937; }

/* Carry boxes (yellow) */
.vs-carry-box {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 40px;
    border: 2px solid #d97706;
    border-radius: 0.35rem;
    background: #fffbeb;
}

.vs-carry-box input {
    width: 100%;
    height: 100%;
    border: none;
    background: transparent;
    text-align: center;
    font-size: 1.2rem;
    font-weight: 700;
    outline: none;
}

/* Digit boxes (top number) */
.vs-digit-box {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    width: 58px;
    height: 58px;
    border: 3px solid #cbd5e1;
    border-radius: 0.5rem;
    font-size: 2rem;
    font-weight: 700;
    color: #1f2937;
    background: white;
    position: relative;
}

.vs-clickable {
    cursor: pointer;
    transition: background-color 0.15s;
}

.vs-clickable:hover { background: #f3f4f6; }

/* Crossed-out digit (borrowing) */
.vs-crossed {
    color: #9ca3af;
    cursor: default;
}

.vs-crossed::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 2px;
    background: var(--primary-color);
    transform: rotate(-45deg);
    top: 50%;
    left: 0;
}

/* Tooltip */
.vs-tooltip {
    position: absolute;
    bottom: 110%;
    left: 50%;
    transform: translateX(-50%);
    background: #1f2937;
    color: white;
    padding: 5px 10px;
    border-radius: 4px;
    font-size: 0.75rem;
    white-space: nowrap;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.15s;
    z-index: 10;
}

.vs-clickable:hover .vs-tooltip { opacity: 1; }
.vs-crossed .vs-tooltip         { display: none; }

/* Answer boxes */
.vs-answer-box {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    width: 58px;
    height: 58px;
    border: 3px solid var(--primary-color);
    border-radius: 0.5rem;
    background: var(--primary-light);
}

.vs-answer-box input {
    width: 100%;
    height: 100%;
    border: none;
    background: transparent;
    text-align: center;
    font-size: 2rem;
    font-weight: 700;
    outline: none;
}

.vs-answer-box input:focus {
    box-shadow: 0 0 0 3px var(--primary-shadow);
    border-radius: 0.4rem;
}

/* ===== GAME-SPECIFIC: feedback ===== */

.vs-feedback {
    text-align: center;
    font-size: 1rem;
    font-weight: 600;
    padding: 0.5rem 1rem;
    margin: 0.5rem auto;
    max-width: 500px;
    display: none;
    border-radius: 0.4rem;
}

.vs-feedback-success { display: block; color: #28a745; background: rgba(40, 167, 69, 0.08); border: 1px solid #28a745; }
.vs-feedback-error   { display: block; color: #dc3545; background: rgba(220, 53, 69, 0.08); border: 1px solid #dc3545; }

/* ===== GAME-SPECIFIC: control buttons ===== */

.vs-controls { text-align: center; margin-top: 1rem; }

.vs-btn-row {
    display: flex;
    gap: 0.75rem;
    justify-content: center;
    flex-wrap: nowrap;
}

.vs-clear-btn {
    flex: 0 0 auto;
    width: auto !important;
    min-width: 120px;
    background: white !important;
    border: 2px solid #adb5bd !important;
    color: #374151 !important;
    box-shadow: none !important;
}

.vs-clear-btn:hover {
    border-color: #6c757d !important;
    background: #f8f9fa !important;
    box-shadow: none !important;
    transform: none !important;
}

.vs-check-btn {
    flex: 1;
    max-width: 300px;
}

/* ===== RESULTS: 4-column stats ===== */

#gsResultsView .gs-results-stats { grid-template-columns: repeat(4, 1fr); }