.magic-ball-container {
    text-align: center;
   
    width: 100%;
}

.magic-ball {
    width: 100%;
    max-width: 200px;
    aspect-ratio: 1;
    margin: 0 auto 20px;
    background: linear-gradient(135deg, #1a1a2e 0%, #0f0f1e 100%);
    border-radius: 50%;
    position: relative;
    box-shadow: 
        0 10px 30px rgba(0, 0, 0, 0.5),
        inset 0 -5px 15px rgba(0, 0, 0, 0.3),
        inset 0 5px 15px rgba(255, 255, 255, 0.1);
    transition: transform 0.6s ease;
}

.magic-ball:hover {
    transform: scale(1.05);
}

.ball-shine {
    position: absolute;
    top: 15%;
    left: 25%;
    width: 30%;
    height: 30%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.3) 0%, transparent 70%);
    border-radius: 50%;
}

.ball-number {
    position: absolute;
    top: 12%;
    left: 50%;
    transform: translateX(-50%);
    font-size: clamp(24px, 8vw, 36px);
    font-weight: bold;
    color: #fff;
    text-shadow: 0 2px 10px rgba(138, 43, 226, 0.8);
}

.widget .ball-number {
    font-size: clamp(20px, 6vw, 28px);
}

.prediction-window {
    position: absolute;

    left: 50%;
    transform: translateX(-50%);
    width: 50%;
    aspect-ratio: 1;
    background: radial-gradient(circle, #4a0e8f 0%, #2d0854 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12%;
    box-shadow: inset 0 0 15px rgba(138, 43, 226, 0.5);
}

.prediction-text {
    color: #fff;
    font-size: clamp(10px, 2.5vw, 13px);
    text-align: center;
    line-height: 1.3;
    opacity: 0;
    transition: opacity 0.5s ease;
    word-wrap: break-word;
    overflow: hidden;
}

.widget .prediction-text {
    font-size: clamp(9px, 2vw, 11px);
}

.prediction-text.show {
    opacity: 1;
}

.magic-ball.shake {
    animation: shake 0.6s ease;
}

@keyframes shake {
    0%, 100% { transform: translateX(0) rotate(0deg); }
    10%, 30%, 50%, 70%, 90% { transform: translateX(-3px) rotate(-1deg); }
    20%, 40%, 60%, 80% { transform: translateX(3px) rotate(1deg); }
}

.magic-ball-button {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 12px 24px;
    font-size: clamp(13px, 3vw, 16px);
    font-weight: bold;
    border-radius: 50px;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
    transition: all 0.3s ease;
    width: 100%;
    max-width: 220px;
}

.widget .magic-ball-button {
    padding: 10px 20px;
    font-size: clamp(12px, 2.5vw, 14px);
}

.magic-ball-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.6);
}

.magic-ball-button:active {
    transform: translateY(0);
}

.magic-ball-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

@media (max-width: 768px) {
    .magic-ball-container {
        padding: 15px 10px;
    }
}