/**
 * Стили для тренажёра "Текстовые задачи"
 */

.word-problems-game .game-title { color: #FFD700; }

/* Settings */
.word-problems-settings {
    display: block !important;
    transition: all 0.3s ease;
    max-height: 300px;
    overflow: hidden;
}

.word-problems-settings.collapsed {
    max-height: 0;
    margin: 0;
    padding: 0;
    opacity: 0;
}

.word-problems-settings .settings-row {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 12px;
}

.word-problems-settings .setting-item {
    flex: 1;
    min-width: 130px;
}

.word-problems-settings .setting-item.wide {
    min-width: 220px;
    flex: 2;
}

/* Player container */
.wp-player {
    background: white;
    border: 3px solid #FFD700;
    border-radius: var(--radius-xl);
    overflow: hidden;
    max-width: 700px;
    margin: 0 auto;
}

.wp-player-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 18px;
    background: linear-gradient(135deg, #FFD700, #FFA500);
    color: white;
    font-size: 15px;
    font-weight: 600;
}

.wp-player-content {
    padding: 25px;
    min-height: 200px;
}

/* Problem */
.wp-problem {
    text-align: center;
}

.wp-text {
    font-size: 1.15rem;
    line-height: 1.6;
    color: var(--text-primary);
    margin-bottom: 20px;
    text-align: left;
    padding: 15px;
    background: #f8f9fa;
    border-radius: var(--radius-md);
    border-left: 4px solid #FFD700;
}

.wp-hint {
    font-size: 0.9rem;
    color: #666;
    background: #fff8e1;
    padding: 10px 15px;
    border-radius: var(--radius-md);
    margin-bottom: 20px;
    text-align: left;
}

/* Input area */
.wp-input-area {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
}

.wp-label {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-secondary);
}

.wp-input {
    width: 120px;
    padding: 12px 15px;
    font-size: 1.3rem;
    font-weight: 700;
    text-align: center;
    border: 3px solid #FFD700;
    border-radius: var(--radius-md);
    font-family: 'Montserrat', sans-serif;
    outline: none;
}

.wp-input:focus {
    border-color: #FFA500;
    box-shadow: 0 0 0 4px rgba(255, 215, 0, 0.2);
}

.wp-unit {
    font-size: 1rem;
    color: var(--text-secondary);
    min-width: 40px;
}

.wp-check {
    padding: 12px 30px;
    font-size: 1rem;
    font-weight: 700;
    font-family: 'Montserrat', sans-serif;
    background: linear-gradient(135deg, #FFD700, #FFA500);
    color: white;
    border: none;
    border-radius: var(--radius-full);
    cursor: pointer;
    transition: transform 0.2s;
}

.wp-check:hover {
    transform: scale(1.05);
}

/* Feedback */
.wp-feedback {
    text-align: left;
}

.wp-feedback .wp-text {
    margin-bottom: 15px;
}

.wp-result {
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 10px;
    text-align: center;
}

.wp-result.correct { color: #27ae60; }
.wp-result.incorrect { color: #e74c3c; }

.wp-user-answer {
    color: #e74c3c;
    margin-bottom: 5px;
    text-align: center;
}

.wp-correct-answer {
    color: #27ae60;
    font-weight: 600;
    margin-bottom: 15px;
    text-align: center;
}

.wp-solution {
    background: #e8f5e9;
    padding: 12px 15px;
    border-radius: var(--radius-md);
    font-size: 0.95rem;
    color: #2e7d32;
    border-left: 4px solid #4caf50;
}

.wp-continue {
    display: block;
    margin: 20px auto 0;
    padding: 12px 40px;
    font-size: 1rem;
    font-weight: 700;
    font-family: 'Montserrat', sans-serif;
    background: linear-gradient(135deg, #FFD700, #FFA500);
    color: white;
    border: none;
    border-radius: var(--radius-full);
    cursor: pointer;
    transition: transform 0.2s;
}

.wp-continue:hover {
    transform: scale(1.05);
}

/* Results */
.wp-results {
    text-align: center;
    padding: 30px;
    background: var(--bg-secondary);
    border-radius: var(--radius-xl);
}

.wp-results .res-icon { 
    font-size: 50px; 
    margin-bottom: 10px; 
}

.wp-results h2 { 
    font-size: 24px; 
    color: var(--text-primary); 
    margin-bottom: 20px; 
}

.wp-results .res-stats {
    display: flex;
    gap: 20px;
    justify-content: center;
    margin-bottom: 15px;
}

.wp-results .res-stat {
    background: white;
    padding: 15px 25px;
    border-radius: var(--radius-lg);
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.wp-results .res-label {
    display: block;
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 5px;
}

.wp-results .res-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: #FFD700;
}

.wp-results .res-reward {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 10px 25px;
    background: linear-gradient(135deg, #FFD700, #FFA500);
    border-radius: var(--radius-full);
    font-size: 15px;
    font-weight: 700;
    color: white;
    margin-bottom: 20px;
}

.wp-results .res-btns {
    display: flex;
    gap: 10px;
    justify-content: center;
}

.wp-results .res-btns button {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 12px 24px;
    border: none;
    border-radius: var(--radius-full);
    font-family: 'Montserrat', sans-serif;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
}

.wp-results .res-btns button:first-child {
    background: linear-gradient(135deg, #FFD700, #FFA500);
    color: white;
}

.wp-results .res-btns button:last-child {
    background: #f0f0f0;
    color: var(--text-primary);
}

/* Responsive */
@media (max-width: 600px) {
    .wp-text { font-size: 1rem; padding: 12px; }
    .wp-input { width: 100px; font-size: 1.1rem; }
    .wp-input-area { flex-direction: column; }
    
    .word-problems-settings .setting-item {
        min-width: 100%;
    }
}