Welcome!

By registering with us, you'll be able to discuss, share and private message with other members of our community.

SignUp Now!

Шар предсказание на новый 2027 год

Ноя
174
40
Пользователь
Приветствую!
Я сделал шар предсказание сразу скажу
1. Баги | Перезагрузите страницу
2. Предсказания | Не гарантирую что они будут всегда разные
3. Пользоваться | Могут все без регистрации до администрации

Скрин;
Screenshot_20261129-085329.jpg

HTML код:
<div class="ny-globe-card">
    <svg class="ny-bg" viewBox="0 0 360 280" preserveAspectRatio="xMidYMid slice">
        <defs>
            <radialGradient id="gGlow" cx="50%" cy="50%" r="50%">
                <stop offset="0%" stop-color="#ff8c32" stop-opacity=".28"/>
                <stop offset="100%" stop-color="#141519" stop-opacity="0"/>
            </radialGradient>
        </defs>
        <rect width="360" height="280" fill="#141519"/>
        <circle cx="180" cy="140" r="150" fill="url(#gGlow)"/>
        
        <g fill="#1c2520" opacity=".85">
            <polygon points="310,45 275,115 345,115"/>
            <polygon points="310,85 265,165 355,165"/>
            <polygon points="310,130 255,220 365,220"/>
        </g>
       
        <g fill="#ffe600" opacity=".7">
            <circle cx="300" cy="95" r="2.5"/><circle cx="322" cy="105" r="2"/>
            <circle cx="290" cy="145" r="2.5"/><circle cx="325" cy="150" r="2.5"/>
            <circle cx="280" cy="195" r="2"/><circle cx="330" cy="200" r="3"/>
        </g>
        
        <g transform="translate(24, 105)" opacity=".9">
            <path d="M12,115 C12,75 58,75 58,115 Z" fill="#8b1c1c"/>
            <rect x="31" y="78" width="8" height="37" fill="#eee"/>
            <circle cx="35" cy="60" r="14" fill="#f3c6a5"/>
            <path d="M21,62 Q35,88 49,62 Q42,74 35,74 Q28,74 21,62 Z" fill="#fff"/>
            <path d="M20,52 L35,24 L50,52 Z" fill="#a82020"/>
            <rect x="19" y="49" width="32" height="6" rx="3" fill="#fff"/>
            <circle cx="35" cy="23" r="4.5" fill="#fff"/>
        </g>
        <!-- Силуэт Снегурочки рядом -->
        <g transform="translate(76, 122)" opacity=".9">
            <path d="M10,98 L20,58 L42,58 L52,98 Z" fill="#1d5b96"/>
            <rect x="28" y="58" width="6" height="40" fill="#e6f2ff"/>
            <circle cx="31" cy="44" r="11" fill="#f7d5bc"/>
            <path d="M20,38 L31,20 L42,38 Z" fill="#2573bd"/>
            <rect x="19" y="36" width="24" height="5" rx="2.5" fill="#fff"/>
            <path d="M21,48 L17,68 M41,48 L45,68" stroke="#f5d76e" stroke-width="3" stroke-linecap="round"/>
        </g>
        
        <path d="M0,255 Q90,242 180,252 T360,248 L360,280 L0,280 Z" fill="#1d2028"/>
    </svg>

    <div class="ny-globe" id="nyGlobe">
        <div class="ny-snow"></div>
        <div class="ny-content">
            <span class="ny-tag"><i class="fas fa-tree"></i> 2027</span>
            <p class="ny-text" id="nyText">Нажми на шар, чтобы узнать свой год</p>
        </div>
    </div>

    <div class="ny-base">
        <xf:if is="$xf.visitor.user_id">{$xf.visitor.username}<xf:else />ГОСТЬ</xf:if>
    </div>
</div>

<style>
.ny-globe-card {
    position: relative;
    border: 1px solid rgba(255, 160, 80, .22);
    border-radius: 12px;
    padding: 20px 14px 18px;
    margin-bottom: 16px;
    display: flex;
    flex-direction: column;
    align-items: center;
    overflow: hidden;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
}

.ny-bg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.ny-globe {
    position: relative;
    width: 210px;
    height: 210px;
    border-radius: 50%;
    background: radial-gradient(circle at 50% 100%, rgba(235, 104, 24, .95) 0%, rgba(184, 41, 20, .9) 48%, rgba(42, 8, 8, .94) 88%);
    box-shadow: inset 0 4px 16px rgba(255, 255, 255, .4), inset 0 -16px 28px rgba(0, 0, 0, .85), 0 10px 25px rgba(0, 0, 0, .7);
    border: 1px solid rgba(255, 200, 150, .35);
    overflow: hidden;
    cursor: pointer;
    z-index: 2;
    transition: transform .15s;
}

.ny-globe:active {
    transform: scale(.96);
}

.ny-globe::after {
    content: '';
    position: absolute;
    top: 12px;
    left: 26px;
    width: 72px;
    height: 32px;
    border-radius: 50%;
    background: linear-gradient(180deg, rgba(255, 255, 255, .4), transparent);
    transform: rotate(-28deg);
    pointer-events: none;
}

.ny-snow {
    position: absolute;
    inset: 0;
    background-image:
        radial-gradient(2px 2px at 20% 25%, #fff, transparent),
        radial-gradient(2.5px 2.5px at 72% 18%, #fff, transparent),
        radial-gradient(1.5px 1.5px at 45% 55%, #fff, transparent),
        radial-gradient(2px 2px at 82% 68%, #fff, transparent),
        radial-gradient(2.5px 2.5px at 28% 78%, #fff, transparent);
    background-size: 140px 140px;
    animation: nySnow 5s linear infinite;
    opacity: .85;
}

.ny-globe.shake .ny-snow {
    animation-duration: .6s;
}

@keyframes nySnow {
    to { background-position: 25px 140px; }
}

.ny-content {
    position: relative;
    height: 100%;
    padding: 26px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    z-index: 2;
    transition: opacity .2s, transform .2s;
}

.ny-content.hide {
    opacity: 0;
    transform: scale(.92);
}

.ny-tag {
    background: rgba(0, 0, 0, .35);
    border: 1px solid rgba(255, 255, 255, .2);
    border-radius: 20px;
    padding: 3px 10px;
    font-size: 10px;
    font-weight: 800;
    color: #ffe600;
    margin-bottom: 10px;
}

.ny-tag i {
    margin-right: 4px;
}

.ny-text {
    margin: 0;
    color: #fff;
    font-size: 13.5px;
    font-weight: 700;
    line-height: 1.38;
    text-shadow: 0 2px 8px rgba(0, 0, 0, .85);
}

.ny-base {
    position: relative;
    width: 140px;
    height: 30px;
    margin-top: -12px;
    background: #22242b;
    border: 1px solid rgba(255, 160, 80, .35);
    border-radius: 6px 6px 14px 14px;
    box-shadow: 0 6px 14px rgba(0, 0, 0, .7);
    color: #fff;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 1px;
    text-transform: uppercase;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 3;
}
</style>

<script>
(() => {
    const globe = document.getElementById('nyGlobe');
    const content = globe.querySelector('.ny-content');
    const text = document.getElementById('nyText');

    const phrases = [
        'Год пойдёт ровно — без лишней суеты и нервов.',
        'В 2027-м заберёшь то, на что давно целился.',
        'Жди мощный финансовый буст ближе к весне.',
        'Наконец-то выспишься и разгребёшь все хвосты.',
        'Будет пара случайных встреч, которые всё поменяют.',
        'Меньше токсиков вокруг, больше своих людей.',
        'Сделаешь то, на что раньше не хватало духу.',
        'Всё сложится даже лучше, чем ты планировал.'
    ];

    let busy = false;

    globe.addEventListener('click', () => {
        if (busy) return;
        busy = true;

        globe.classList.add('shake');
        content.classList.add('hide');

        setTimeout(() => {
            let next;
            do {
                next = phrases[Math.floor(Math.random() * phrases.length)];
            } while (next === text.textContent);

            text.textContent = next;
            content.classList.remove('hide');
        }, 200);

        setTimeout(() => {
            globe.classList.remove('shake');
            busy = false;
        }, 650);
    });
})();
</script>
 
Сверху