    /* ============================================================
   Vertical Addition — Per-Game Styles
   /maths/css/verticaladdition.css
   ============================================================ */

/* ===== COLOUR SCHEME ===== */
:root {
    --primary-color:       #15E6CD;
    --primary-hover:       #12CDB7;
    --primary-light:       rgba(21, 230, 205, 0.12);
    --primary-shadow:      rgba(21, 230, 205, 0.30);
    --btn-text-color:      #0a4a43;
    --hero-gradient-start: rgba(21, 230, 205, 0.15);
    --hero-gradient-end:   rgba(21, 230, 205, 0.07);
}

/* ===== GAME-SPECIFIC: ensure active game area is visible ===== */

.gs-active-game {
    display: block !important;
    min-height: 200px;
}

/* ===== GAME-SPECIFIC: level cards ===== */

.va-level-cards {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 0.5rem;
}

.va-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;
}

.va-level-card:hover {
    border-color: var(--primary-color);
    transform: translateY(-3px);
    box-shadow: 0 6px 20px var(--primary-shadow);
}

.va-level-card.active {
    border-color: var(--primary-color);
    background: var(--primary-light);
}

.va-level-number {
    font-size: 2.2rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 0.4rem;
}

.va-level-title {
    font-size: 1rem;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 0.5rem;
}

.va-level-card ul {
    list-style: none;
    padding: 0;
    margin: 0;
    font-size: 0.82rem;
    color: #6b7280;
    line-height: 1.7;
}

/* ===== GAME-SPECIFIC: question text ===== */

.va-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 ===== */

.sd-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 addition grid ===== */

.problem-container {
    display: flex;
    justify-content: center;
    margin: 0.5rem 0;
}

.column-addition {
    display: table !important;
    border-collapse: collapse;
    margin: 0 auto;
}

.carry-row, .number-row, .answer-row {
    display: table-row !important;
}

.digit-cell {
    display: table-cell !important;
    padding: 6px;
    text-align: center;
    vertical-align: middle;
    width: 70px;
    height: 70px;
}

.carry-cell {
    display: table-cell !important;
    padding: 4px;
    text-align: center;
    vertical-align: top;
    width: 70px;
    height: 44px;
}

.number-display {
    font-size: 2.4rem;
    font-weight: 700;
    color: #1f2937;
}

.operator {
    font-size: 2.4rem;
    font-weight: 700;
    color: var(--primary-color);
    padding-right: 8px;
}

.answer-row { border-top: 3px solid #1f2937; }

/* Digit input (answer boxes — teal) */
.digit-input {
    width: 58px !important;
    height: 58px !important;
    text-align: center;
    font-size: 2rem;
    font-weight: 700;
    border: 3px solid var(--primary-color);
    border-radius: 0.5rem;
    background: rgba(21, 230, 205, 0.08);
    display: block !important;
    outline: none;
    -moz-appearance: textfield;
}

.digit-input:focus {
    border-color: var(--primary-hover);
    box-shadow: 0 0 0 3px var(--primary-shadow);
}

/* Carry input (yellow boxes) */
.carry-input {
    width: 40px !important;
    height: 40px !important;
    text-align: center;
    font-size: 1.2rem;
    font-weight: 700;
    border: 2px solid #d97706;
    border-radius: 0.35rem;
    background: #fffbeb;
    display: block !important;
    outline: none;
}

.carry-input:focus { border-color: #b45309; }

/* Correct / incorrect states — scoped to inputs only */
.digit-input.correct   { background: #d4edda !important; border-color: #28a745 !important; color: #155724 !important; }
.digit-input.incorrect { background: #f8d7da !important; border-color: #dc3545 !important; color: #721c24 !important; }
.carry-input.correct   { background: #d4edda !important; border-color: #28a745 !important; color: #155724 !important; }
.carry-input.incorrect { background: #f8d7da !important; border-color: #dc3545 !important; color: #721c24 !important; }

/* ===== GAME-SPECIFIC: feedback ===== */

.feedback {
    text-align: center;
    font-size: 1rem;
    font-weight: 600;
    padding: 0.5rem 1rem;
    margin: 0.5rem auto;
    max-width: 500px;
    display: none;
}

.feedback.success { display: block; color: #28a745; }
.feedback.error   { display: block; color: #dc3545; }

/* ===== GAME-SPECIFIC: control buttons ===== */

.sd-controls { text-align: center; margin-top: 1rem; }

.sd-btn-row {
    display: flex;
    gap: 0.75rem;
    justify-content: center;
    flex-wrap: nowrap;
}

.sd-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;
}

.sd-clear-btn:hover {
    border-color: #6c757d !important;
    background: #f8f9fa !important;
    box-shadow: none !important;
    transform: none !important;
}

.sd-check-btn {
    flex: 1;
    max-width: 300px;
}


/* ===== RESULTS: 4-column stats ===== */

#resultsView .gs-results-stats { grid-template-columns: repeat(4, 1fr); }