#game-root {
    --ap-accent: #10B981;
    --ap-accent-dark: #0e9c6f;
    --ap-accent-light: #e3f9ef;
    --ap-accent-border: #a7f3d0;
    border-radius: var(--kw-radius, 16px);
}

.ap-wrap {
    max-width: 480px;
    margin: 0 auto;
    padding: 20px 16px 28px;
}

.ap-loading,
.ap-error {
    text-align: center;
    padding: 48px 16px;
}

.ap-loading-icon,
.ap-error-icon {
    font-size: 40px;
    margin-bottom: 10px;
}

.ap-loading-icon {
    animation: ap-pulse 1.2s ease-in-out infinite;
}

.ap-loading-text {
    font-size: 15px;
    color: #666;
}

.ap-error-text {
    font-size: 15px;
    font-weight: 700;
    color: #EF4444;
}

.ap-progress {
    height: 8px;
    border-radius: 999px;
    background: var(--ap-accent-light);
    overflow: hidden;
    margin-bottom: 12px;
}

.ap-progress-fill {
    height: 100%;
    width: 0;
    background: var(--ap-accent);
    border-radius: 999px;
    transition: width .3s ease;
}

.ap-stat-row {
    justify-content: center;
    margin-bottom: 14px;
}

.ap-stat {
    background: var(--ap-accent-light);
    color: var(--ap-accent-dark);
    border-radius: 999px;
    padding: 6px 14px;
    font-weight: 700;
    font-size: 14px;
}

.ap-card {
    background: #fff;
    border-radius: var(--kw-radius, 16px);
    padding: 24px 18px;
    text-align: center;
    box-shadow: 0 3px 12px rgba(0, 0, 0, .07);
    animation: ap-fade-in .25s ease;
}

.ap-prompt-emoji {
    font-size: 60px;
    margin-bottom: 6px;
}

.ap-prompt-word {
    font-size: 20px;
    font-weight: 800;
    color: var(--ap-accent-dark);
    letter-spacing: .5px;
}

.ap-prompt-hint {
    font-size: 13px;
    font-weight: 600;
    color: #999;
    margin: 4px 0 18px;
}

.ap-choices {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

.ap-bubble {
    aspect-ratio: 1;
    border: none;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--ap-accent), var(--ap-accent-dark));
    color: #fff;
    font-size: 22px;
    font-weight: 800;
    cursor: pointer;
    box-shadow: 0 3px 0 rgba(0, 0, 0, .12);
    transition: transform .12s ease, box-shadow .12s ease;
}

.ap-bubble:hover:not(:disabled) {
    transform: translateY(-2px) scale(1.04);
}

.ap-bubble:active:not(:disabled) {
    transform: translateY(0) scale(.97);
}

.ap-bubble:disabled {
    cursor: default;
}

.ap-bubble.correct {
    background: linear-gradient(135deg, #34d399, #10B981);
    animation: ap-pop .3s ease;
}

.ap-bubble.incorrect {
    background: linear-gradient(135deg, #FCA5A5, #EF4444);
    animation: ap-shake .3s ease;
    opacity: .6;
}

.ap-done-card {
    text-align: center;
    background: #fff;
    border-radius: var(--kw-radius, 16px);
    padding: 32px 20px;
    box-shadow: 0 3px 12px rgba(0, 0, 0, .07);
    animation: ap-pop .3s ease;
}

.ap-done-emoji {
    font-size: 56px;
    margin-bottom: 8px;
}

.ap-done-title {
    font-size: 20px;
    font-weight: 800;
    color: var(--ap-accent-dark);
    margin-bottom: 6px;
}

.ap-done-score {
    font-size: 16px;
    font-weight: 600;
    color: #555;
    margin-bottom: 10px;
}

.ap-done-stars {
    font-size: 24px;
    letter-spacing: 4px;
}

.ap-done-share {
    justify-content: center;
    margin-top: 16px;
}

.ap-done-actions {
    justify-content: center;
    margin-top: 20px;
}

.ap-btn-primary {
    border: none;
    padding: 12px 22px;
    border-radius: 999px;
    font-weight: 800;
    font-size: 14px;
    cursor: pointer;
    background: var(--ap-accent);
    color: #fff;
    box-shadow: 0 3px 0 var(--ap-accent-dark);
    transition: transform .1s ease;
}

.ap-btn-primary:hover {
    transform: translateY(-1px);
}

@keyframes ap-fade-in {
    from { opacity: 0; transform: translateY(6px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes ap-pop {
    0% { transform: scale(.85); }
    100% { transform: scale(1); }
}

@keyframes ap-shake {
    0%, 100% { transform: translateX(0); }
    20% { transform: translateX(-5px); }
    40% { transform: translateX(5px); }
    60% { transform: translateX(-3px); }
    80% { transform: translateX(3px); }
}

@keyframes ap-pulse {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.15); opacity: .7; }
}
