ProjectGenesis commited on
Commit
97e45ce
·
verified ·
1 Parent(s): acef970

Design a premium, cinematic “Double Spin Loot Box” feature module for an online sweepstakes casino platform called Nioplay.

Browse files

This module should feel like a hero feature section that can be dropped into Nioplay’s existing desktop layout: dark, neon, glassmorphism, and high-end. The entire design should be centered around two stacked RNG interactions:

1) A top horizontal loot box carousel (primary spin).
2) A bottom horizontal multiplier slider styled like a minimal glowing meter (secondary spin).

Overall visual style and theme:
- Theme: modern online casino / sweepstakes gaming, inspired by Stake.com but with Nioplay’s own identity.
- Colors: deep black and charcoal background, neon orange (#FF8C00) as the main accent, warm gold (#FFCC66 / #FFD700) for highlights, with subtle amber glows.
- Background: dark radial gradient with a warm, smoky casino atmosphere. Soft light beams, faint particles, and glow around the main module.
- UI style: clean, sharp edges mixed with rounded glassmorphism cards. Translucent panels with blur and inner/outer glow. No cartoon look; everything should feel sleek, premium, and high-value.
- Lighting: cinematic and directional, with subtle volumetric lighting behind the loot box track and multiplier slider to draw the eye.

Layout structure (top to bottom):
1) Header / Title Row:
- Left: A bold feature label such as “MYSTERY LOOT BOX ROLL” in uppercase, spaced lettering, with a subtle gradient fill (gold to warm white) and a soft glow.
- Subheading under it: one or two lines explaining the mechanic in clear UI copy, e.g. “Roll across mystery boxes, unlock a random reward, then boost it with a multiplier spin.”
- Right side: a small info badge and stat line such as “Today’s Legendary Boost: +3%” or “Daily Bonus Loot Active”. Use a pill-shaped glass badge with small icon or subtle SC coin emblem.

2) Main Loot Box Track (top spin):
- Centered horizontally in the module.
- A wide, horizontal track that looks like a glassmorphic rail or shelf.
- On this rail, display a row of at least 10–14 loot boxes spread horizontally. The boxes should be evenly spaced, slightly floating above the track.
- Each loot box:
- Shape: rounded rectangular or cube-like, with metallic and glass surfaces.
- Rarity colors:
- Common: subtle green glow.
- Rare: blue glow.
- Epic: purple glow.
- Legendary: intense gold/orange glow.
- Each box has a glowing seam or lid outline, suggesting it can open. Optional faint SC icon emboss on the front.
- Use small rarity labels beneath them: “COMMON”, “RARE”, “EPIC”, “LEGENDARY” in uppercase micro text.
- Add a centered “selection frame” overlay: a vertical, rounded rectangle aligned in the center of the track, slightly translucent with a white/orange glow. This indicates where the boxes must land to be selected.
- Convey animation/state:
- Use motion blur, ghosted duplicates, or streaks to suggest that the whole row of boxes can rapidly slide horizontally left and right.
- Show a final state where one loot box is perfectly centered in the selection frame. That centered box should glow brighter, be slightly larger (scaled up), and appear as the chosen box.
- Optionally show the lid of the chosen box slightly opened with a burst of light and SC coins emerging, while the other boxes are dimmer in comparison.

3) Primary Action and Status:
- Below the loot box track, place a prominent circular or pill-shaped button labeled “ROLL” or “ROLL LOOT BOX” in uppercase.
- Button styling:
- Big, satisfying CTA.
- Gradient from golden yellow to neon orange (#FF8C00), with strong glow and subtle inner light.
- Slight 3D depth and drop shadow to feel clickable.
- Next to or under the button, include a small status label area, e.g. “Status: Ready”, “Rolling…”, or “Landed on: EPIC BOX”. This status text should feel like a slim HUD indicator.

4) Secondary Multiplier Slider (bottom spin, meter style):
- Directly beneath the loot box track and main button, design a second horizontal component: a simple, elegant multiplier slider that feels like a digital meter.
- Concept: instead of more boxes or graphics, this second slider is a row of minimal glowing “multiplier pills” with text only.
- Layout:
- A long horizontal strip, visually lighter and thinner than the loot box rail.
- A central “selection window” overlay (like the top selection frame, but smaller) that shows which multiplier is finally chosen.
- Inside the slider, display several multiplier values as repeating items, for example:
- ×1
- ×1.25
- ×1.5
- ×2
- ×3
- ×5
- Each multiplier item:
- Appears as a soft, rounded pill or mini-rectangle.
- Has a glassmorphism background (translucent, blurred, slightly reflective).
- Contains only the multiplier text (e.g. “×2”) in a bold, clean sans-serif font.
- Text color: warm gold or off-white with a subtle glow.
- The slider behavior to visualize:
- The entire row of multiplier pills can scroll horizontally at high speed, similar to a ticker or roulette, aligned with the central selection window.
- Show a sense of motion with slight blur or multiple trailing copies, indicating that the strip can move quickly.
- The final state should show one multiplier pill perfectly centered inside the selection window, enlarged slightly and glowing brighter than the rest.
- The chosen pill should have a stronger neon orange edge glow, inner light, and maybe a subtle pulse to indicate it’s locked in.
- Style of the multiplier slider:
- Overall feel like a “power meter” or “data strip” rather than another heavy loot box row.
- Minimalistic, tech-flavored, clean.
- Background of the slider strip should be darker, with a subtle gradient and faint grid or texture to suggest precision and control.
- No icons, no complex graphics, just glowing pills with text.

5) Combined Result / Payout Indication:
- Somewhere near the bottom or to the side, include a small “Result” or “Win Breakdown” panel showing how the top box and bottom multiplier combine.
- For example, a small glassmorphism card that reads:
- “Base Reward: 30 SC”
- “Multiplier: ×2”
- “Total Win: 60 SC”
- Use a visual hierarchy:
- Base reward text smaller and more subtle.
- Multiplier slightly larger.
- Total Win much larger, bold, with a neon glow and SC coin icon.
- This panel should still match the Nioplay theme: dark glass, thin glowing borders, subtle particle or light streaks.

Stylistic details to enforce:
- Typography: modern, clean, all-caps for labels and main CTAs; slightly rounded sans-serif with tight letter spacing.
- Use microcopy around the module to hint at the mechanic: “Spin the boxes”, “Then boost with a multiplier”, “Every roll is RNG-based”, etc.
- Use icons only where subtle: SC coins can appear as small circular gold coins with “SC” engraved, floating around the selected loot box.
- Emphasis on depth: shadows under boxes, layered glass panels, and overlapping glows to convey a rich, layered interface.
- Aspect ratio: design this as a wide, desktop-first module, roughly 16:9 feel (like a wide hero strip inside a page), with breathing room around it.
- Make the animations “visually implied”: use blur, streaks, ghosted positions, and slight offsets, but the final render is a still image that clearly communicates that both the top track and bottom slider are capable of animated RNG spins.
- Ensure the second slider (multiplier) is visually simpler than the top loot boxes: less graphic content, more about clean numbers on glowing pills. It should feel like a modern, horizontal meter.

Final composition:
- The viewer should instantly understand that:
1) The top row is a loot box RNG roll that picks a random box.
2) The bottom row is a separate multiplier RNG roll in a simple, horizontal meter-style slider.
3) The player presses one main button to trigger these spins.
4) The final prize = base reward from the loot box × multiplier from the second slider.
- The design should feel immersive, cinematic, and uniquely Nioplay, ready to be implemented as a functional double-spin module in a real product UI.

Files changed (7) hide show
  1. README.md +8 -5
  2. components/lootbox.js +237 -0
  3. components/multiplier.js +149 -0
  4. components/navbar.js +101 -0
  5. index.html +95 -19
  6. script.js +41 -0
  7. style.css +66 -18
README.md CHANGED
@@ -1,10 +1,13 @@
1
  ---
2
- title: Neon Loot Spinner Spectacle
3
- emoji: 💻
4
- colorFrom: yellow
5
- colorTo: red
6
  sdk: static
7
  pinned: false
 
 
8
  ---
9
 
10
- Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
 
 
1
  ---
2
+ title: Neon Loot Spinner Spectacle 🎰
3
+ colorFrom: green
4
+ colorTo: purple
5
+ emoji: 🐳
6
  sdk: static
7
  pinned: false
8
+ tags:
9
+ - deepsite-v3
10
  ---
11
 
12
+ # Welcome to your new DeepSite project!
13
+ This project was created with [DeepSite](https://huggingface.co/deepsite).
components/lootbox.js ADDED
@@ -0,0 +1,237 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ class CustomLootbox extends HTMLElement {
2
+ connectedCallback() {
3
+ this.attachShadow({ mode: 'open' });
4
+ this.shadowRoot.innerHTML = `
5
+ <style>
6
+ :host {
7
+ display: block;
8
+ position: relative;
9
+ }
10
+
11
+ .track-container {
12
+ position: relative;
13
+ width: 100%;
14
+ height: 180px;
15
+ margin: 2rem 0;
16
+ }
17
+
18
+ .loot-box-track {
19
+ position: absolute;
20
+ top: 50%;
21
+ left: 0;
22
+ transform: translateY(-50%);
23
+ width: 100%;
24
+ height: 120px;
25
+ background: rgba(30, 30, 30, 0.5);
26
+ border-radius: 8px;
27
+ border: 1px solid rgba(255, 255, 255, 0.05);
28
+ display: flex;
29
+ align-items: center;
30
+ overflow: hidden;
31
+ }
32
+
33
+ .loot-box-scroll {
34
+ display: flex;
35
+ transition: transform 0.1s linear;
36
+ will-change: transform;
37
+ }
38
+
39
+ .loot-box {
40
+ width: 90px;
41
+ height: 90px;
42
+ margin: 0 10px;
43
+ border-radius: 8px;
44
+ display: flex;
45
+ flex-direction: column;
46
+ align-items: center;
47
+ justify-content: center;
48
+ position: relative;
49
+ transition: all 0.3s ease;
50
+ transform-origin: center;
51
+ box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
52
+ }
53
+
54
+ .loot-box::before {
55
+ content: '';
56
+ position: absolute;
57
+ inset: 0;
58
+ border-radius: 8px;
59
+ padding: 2px;
60
+ background: linear-gradient(45deg, var(--glow-color) 0%, transparent 30%);
61
+ -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
62
+ -webkit-mask-composite: xor;
63
+ mask-composite: exclude;
64
+ pointer-events: none;
65
+ }
66
+
67
+ .loot-box.common { background: rgba(30, 30, 30, 0.9); }
68
+ .loot-box.rare { background: rgba(30, 30, 40, 0.9); }
69
+ .loot-box.epic { background: rgba(40, 30, 45, 0.9); }
70
+ .loot-box.legendary { background: rgba(45, 35, 20, 0.9); }
71
+
72
+ .loot-box-icon {
73
+ width: 40px;
74
+ height: 40px;
75
+ margin-bottom: 8px;
76
+ }
77
+
78
+ .loot-box-rarity {
79
+ font-size: 0.6rem;
80
+ font-weight: 700;
81
+ text-transform: uppercase;
82
+ letter-spacing: 1px;
83
+ margin-top: 4px;
84
+ }
85
+
86
+ .common .loot-box-rarity { color: #4CAF50; }
87
+ .rare .loot-box-rarity { color: #2196F3; }
88
+ .epic .loot-box-rarity { color: #9C27B0; }
89
+ .legendary .loot-box-rarity { color: #FFD700; }
90
+
91
+ .selection-frame {
92
+ position: absolute;
93
+ left: 50%;
94
+ top: 50%;
95
+ transform: translate(-50%, -50%);
96
+ width: 110px;
97
+ height: 110px;
98
+ border-radius: 12px;
99
+ border: 2px solid rgba(255, 215, 0, 0.5);
100
+ box-shadow: 0 0 20px rgba(255, 215, 0, 0.3);
101
+ pointer-events: none;
102
+ z-index: 10;
103
+ animation: pulse-glow 2s infinite;
104
+ }
105
+
106
+ .selected-box {
107
+ transform: scale(1.15);
108
+ box-shadow: 0 0 30px var(--glow-color);
109
+ z-index: 5;
110
+ }
111
+
112
+ .selected-box::before {
113
+ background: linear-gradient(45deg, var(--glow-color) 0%, transparent 20%);
114
+ opacity: 0.8;
115
+ }
116
+
117
+ @keyframes pulse-glow {
118
+ 0% { box-shadow: 0 0 0 0 rgba(255, 215, 0, 0.4); }
119
+ 70% { box-shadow: 0 0 0 10px rgba(255, 215, 0, 0); }
120
+ 100% { box-shadow: 0 0 0 0 rgba(255, 215, 0, 0); }
121
+ }
122
+ </style>
123
+
124
+ <div class="track-container">
125
+ <div class="loot-box-track">
126
+ <div class="loot-box-scroll" id="lootBoxScroll">
127
+ <!-- Loot boxes will be added dynamically -->
128
+ </div>
129
+ </div>
130
+ <div class="selection-frame"></div>
131
+ </div>
132
+ `;
133
+
134
+ // Generate loot boxes
135
+ this.generateLootBoxes();
136
+ }
137
+
138
+ generateLootBoxes() {
139
+ const scrollContainer = this.shadowRoot.getElementById('lootBoxScroll');
140
+
141
+ // Clear existing boxes
142
+ scrollContainer.innerHTML = '';
143
+
144
+ // Rarity distribution
145
+ const rarities = [
146
+ { class: 'common', name: 'COMMON', count: 6 },
147
+ { class: 'rare', name: 'RARE', count: 4 },
148
+ { class: 'epic', name: 'EPIC', count: 3 },
149
+ { class: 'legendary', name: 'LEGENDARY', count: 1 }
150
+ ];
151
+
152
+ // Create loot boxes
153
+ let allBoxes = [];
154
+
155
+ rarities.forEach(rarity => {
156
+ for (let i = 0; i < rarity.count; i++) {
157
+ const box = document.createElement('div');
158
+ box.className = `loot-box ${rarity.class}`;
159
+ box.innerHTML = `
160
+ <div class="loot-box-icon">
161
+ <i data-feather="box"></i>
162
+ </div>
163
+ <div class="loot-box-rarity">${rarity.name}</div>
164
+ `;
165
+ allBoxes.push(box);
166
+ }
167
+ });
168
+
169
+ // Shuffle and duplicate to create a longer track
170
+ allBoxes = this.shuffleArray(allBoxes);
171
+ const duplicateCount = 3; // How many times to duplicate the set
172
+
173
+ for (let i = 0; i < duplicateCount; i++) {
174
+ allBoxes.forEach(box => {
175
+ scrollContainer.appendChild(box.cloneNode(true));
176
+ });
177
+ }
178
+
179
+ // Initialize feather icons
180
+ if (window.feather) {
181
+ window.feather.replace();
182
+ }
183
+ }
184
+
185
+ shuffleArray(array) {
186
+ for (let i = array.length - 1; i > 0; i--) {
187
+ const j = Math.floor(Math.random() * (i + 1));
188
+ [array[i], array[j]] = [array[j], array[i]];
189
+ }
190
+ return array;
191
+ }
192
+
193
+ startSpin() {
194
+ const scrollContainer = this.shadowRoot.getElementById('lootBoxScroll');
195
+ scrollContainer.style.transition = 'transform 3s cubic-bezier(0.2, 0.8, 0.4, 1)';
196
+
197
+ // Random end position (simulate spin)
198
+ const boxWidth = 90 + 20; // width + margin
199
+ const boxCount = scrollContainer.children.length;
200
+ const randomOffset = Math.floor(Math.random() * boxCount) * boxWidth;
201
+
202
+ scrollContainer.style.transform = `translateX(-${randomOffset}px)`;
203
+
204
+ // Reset selected boxes
205
+ const boxes = scrollContainer.querySelectorAll('.loot-box');
206
+ boxes.forEach(box => {
207
+ box.classList.remove('selected-box');
208
+ });
209
+ }
210
+
211
+ stopSpin() {
212
+ const scrollContainer = this.shadowRoot.getElementById('lootBoxScroll');
213
+ const boxes = scrollContainer.children;
214
+
215
+ // Find which box is in the center
216
+ const containerRect = scrollContainer.getBoundingClientRect();
217
+ const containerCenter = containerRect.left + containerRect.width / 2;
218
+
219
+ let selectedBox = null;
220
+
221
+ for (let i = 0; i < boxes.length; i++) {
222
+ const boxRect = boxes[i].getBoundingClientRect();
223
+ const boxCenter = boxRect.left + boxRect.width / 2;
224
+
225
+ if (Math.abs(boxCenter - containerCenter) < boxRect.width / 2) {
226
+ selectedBox = boxes[i];
227
+ break;
228
+ }
229
+ }
230
+
231
+ if (selectedBox) {
232
+ selectedBox.classList.add('selected-box');
233
+ }
234
+ }
235
+ }
236
+
237
+ customElements.define('custom-lootbox', CustomLootbox);
components/multiplier.js ADDED
@@ -0,0 +1,149 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ class CustomMultiplier extends HTMLElement {
2
+ connectedCallback() {
3
+ this.attachShadow({ mode: 'open' });
4
+ this.shadowRoot.innerHTML = `
5
+ <style>
6
+ :host {
7
+ display: block;
8
+ position: relative;
9
+ margin-top: 3rem;
10
+ height: 80px;
11
+ }
12
+
13
+ .multiplier-track {
14
+ position: relative;
15
+ width: 100%;
16
+ height: 60px;
17
+ margin: 1rem 0;
18
+ background: rgba(20, 20, 20, 0.7);
19
+ border-radius: 9999px;
20
+ border: 1px solid rgba(255, 255, 255, 0.05);
21
+ overflow: hidden;
22
+ }
23
+
24
+ .multiplier-scroll {
25
+ display: flex;
26
+ align-items: center;
27
+ height: 100%;
28
+ transition: transform 0.1s linear;
29
+ will-change: transform;
30
+ }
31
+
32
+ .multiplier-pill {
33
+ min-width: 80px;
34
+ height: 40px;
35
+ margin: 0 10px;
36
+ border-radius: 9999px;
37
+ display: flex;
38
+ align-items: center;
39
+ justify-content: center;
40
+ background: rgba(255, 255, 255, 0.05);
41
+ border: 1px solid rgba(255, 255, 255, 0.1);
42
+ font-weight: 700;
43
+ font-size: 1.1rem;
44
+ color: rgba(255, 255, 255, 0.7);
45
+ transition: all 0.3s ease;
46
+ }
47
+
48
+ .selection-window {
49
+ position: absolute;
50
+ left: 50%;
51
+ top: 50%;
52
+ transform: translate(-50%, -50%);
53
+ width: 100px;
54
+ height: 50px;
55
+ border-radius: 9999px;
56
+ border: 2px solid rgba(255, 140, 0, 0.5);
57
+ box-shadow: 0 0 15px rgba(255, 140, 0, 0.3);
58
+ pointer-events: none;
59
+ z-index: 10;
60
+ }
61
+
62
+ .selected-pill {
63
+ background: rgba(255, 140, 0, 0.2);
64
+ border: 1px solid rgba(255, 140, 0, 0.5);
65
+ color: #FF8C00;
66
+ box-shadow: 0 0 15px rgba(255, 140, 0, 0.3);
67
+ transform: scale(1.1);
68
+ }
69
+ </style>
70
+
71
+ <div class="multiplier-track">
72
+ <div class="multiplier-scroll" id="multiplierScroll">
73
+ <!-- Multiplier pills will be added dynamically -->
74
+ </div>
75
+ <div class="selection-window"></div>
76
+ </div>
77
+ `;
78
+
79
+ // Generate multiplier pills
80
+ this.generateMultipliers();
81
+ }
82
+
83
+ generateMultipliers() {
84
+ const scrollContainer = this.shadowRoot.getElementById('multiplierScroll');
85
+
86
+ // Clear existing pills
87
+ scrollContainer.innerHTML = '';
88
+
89
+ // Multiplier values
90
+ const multipliers = ['×1', '×1.25', '×1.5', '×2', '×3', '×5'];
91
+
92
+ // Create multiplier pills
93
+ const duplicateCount = 5; // How many times to duplicate the set
94
+
95
+ for (let i = 0; i < duplicateCount; i++) {
96
+ multipliers.forEach(value => {
97
+ const pill = document.createElement('div');
98
+ pill.className = 'multiplier-pill';
99
+ pill.textContent = value;
100
+ scrollContainer.appendChild(pill);
101
+ });
102
+ }
103
+ }
104
+
105
+ startSpin() {
106
+ const scrollContainer = this.shadowRoot.getElementById('multiplierScroll');
107
+ scrollContainer.style.transition = 'transform 2s cubic-bezier(0.2, 0.8, 0.4, 1)';
108
+
109
+ // Random end position (simulate spin)
110
+ const pillWidth = 80 + 20; // width + margin
111
+ const pillCount = scrollContainer.children.length;
112
+ const randomOffset = Math.floor(Math.random() * pillCount) * pillWidth;
113
+
114
+ scrollContainer.style.transform = `translateX(-${randomOffset}px)`;
115
+
116
+ // Reset selected pills
117
+ const pills = scrollContainer.querySelectorAll('.multiplier-pill');
118
+ pills.forEach(pill => {
119
+ pill.classList.remove('selected-pill');
120
+ });
121
+ }
122
+
123
+ stopSpin() {
124
+ const scrollContainer = this.shadowRoot.getElementById('multiplierScroll');
125
+ const pills = scrollContainer.children;
126
+
127
+ // Find which pill is in the center
128
+ const containerRect = scrollContainer.getBoundingClientRect();
129
+ const containerCenter = containerRect.left + containerRect.width / 2;
130
+
131
+ let selectedPill = null;
132
+
133
+ for (let i = 0; i < pills.length; i++) {
134
+ const pillRect = pills[i].getBoundingClientRect();
135
+ const pillCenter = pillRect.left + pillRect.width / 2;
136
+
137
+ if (Math.abs(pillCenter - containerCenter) < pillRect.width / 2) {
138
+ selectedPill = pills[i];
139
+ break;
140
+ }
141
+ }
142
+
143
+ if (selectedPill) {
144
+ selectedPill.classList.add('selected-pill');
145
+ }
146
+ }
147
+ }
148
+
149
+ customElements.define('custom-multiplier', CustomMultiplier);
components/navbar.js ADDED
@@ -0,0 +1,101 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ class CustomNavbar extends HTMLElement {
2
+ connectedCallback() {
3
+ this.attachShadow({ mode: 'open' });
4
+ this.shadowRoot.innerHTML = `
5
+ <style>
6
+ :host {
7
+ display: block;
8
+ width: 100%;
9
+ background: rgba(10, 10, 10, 0.8);
10
+ backdrop-filter: blur(10px);
11
+ -webkit-backdrop-filter: blur(10px);
12
+ border-bottom: 1px solid rgba(255, 255, 255, 0.05);
13
+ z-index: 50;
14
+ }
15
+
16
+ .navbar-container {
17
+ display: flex;
18
+ justify-content: space-between;
19
+ align-items: center;
20
+ max-width: 1200px;
21
+ margin: 0 auto;
22
+ padding: 1rem 2rem;
23
+ }
24
+
25
+ .logo {
26
+ font-weight: 700;
27
+ font-size: 1.5rem;
28
+ letter-spacing: 1px;
29
+ background: linear-gradient(90deg, #FF8C00 0%, #FFD700 100%);
30
+ -webkit-background-clip: text;
31
+ background-clip: text;
32
+ color: transparent;
33
+ }
34
+
35
+ .nav-links {
36
+ display: flex;
37
+ gap: 2rem;
38
+ }
39
+
40
+ .nav-link {
41
+ color: rgba(255, 255, 255, 0.7);
42
+ text-decoration: none;
43
+ font-weight: 500;
44
+ font-size: 0.9rem;
45
+ letter-spacing: 0.5px;
46
+ transition: color 0.3s ease;
47
+ }
48
+
49
+ .nav-link:hover {
50
+ color: white;
51
+ }
52
+
53
+ .nav-link.active {
54
+ color: #FF8C00;
55
+ }
56
+
57
+ .user-section {
58
+ display: flex;
59
+ align-items: center;
60
+ gap: 1rem;
61
+ }
62
+
63
+ .balance {
64
+ background: rgba(255, 215, 0, 0.1);
65
+ padding: 0.5rem 1rem;
66
+ border-radius: 9999px;
67
+ font-size: 0.9rem;
68
+ display: flex;
69
+ align-items: center;
70
+ gap: 0.5rem;
71
+ }
72
+
73
+ .balance-amount {
74
+ font-weight: 600;
75
+ color: #FFD700;
76
+ }
77
+ </style>
78
+
79
+ <nav class="navbar-container">
80
+ <a href="/" class="logo">NIOPLAY</a>
81
+
82
+ <div class="nav-links">
83
+ <a href="/" class="nav-link active">Home</a>
84
+ <a href="/games" class="nav-link">Games</a>
85
+ <a href="/promotions" class="nav-link">Promotions</a>
86
+ <a href="/vip" class="nav-link">VIP</a>
87
+ </div>
88
+
89
+ <div class="user-section">
90
+ <div class="balance">
91
+ <i data-feather="dollar-sign"></i>
92
+ <span class="balance-amount">10,245 SC</span>
93
+ </div>
94
+ <i data-feather="user"></i>
95
+ </div>
96
+ </nav>
97
+ `;
98
+ }
99
+ }
100
+
101
+ customElements.define('custom-navbar', CustomNavbar);
index.html CHANGED
@@ -1,19 +1,95 @@
1
- <!doctype html>
2
- <html>
3
- <head>
4
- <meta charset="utf-8" />
5
- <meta name="viewport" content="width=device-width" />
6
- <title>My static Space</title>
7
- <link rel="stylesheet" href="style.css" />
8
- </head>
9
- <body>
10
- <div class="card">
11
- <h1>Welcome to your static Space!</h1>
12
- <p>You can modify this app directly by editing <i>index.html</i> in the Files and versions tab.</p>
13
- <p>
14
- Also don't forget to check the
15
- <a href="https://huggingface.co/docs/hub/spaces" target="_blank">Spaces documentation</a>.
16
- </p>
17
- </div>
18
- </body>
19
- </html>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <!DOCTYPE html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="UTF-8">
5
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
6
+ <title>Nioplay - Double Spin Loot Box</title>
7
+ <link rel="stylesheet" href="style.css">
8
+ <script src="https://cdn.tailwindcss.com"></script>
9
+ <script src="https://cdn.jsdelivr.net/npm/feather-icons/dist/feather.min.js"></script>
10
+ <script src="https://unpkg.com/feather-icons"></script>
11
+ <script src="components/navbar.js"></script>
12
+ <script src="components/lootbox.js"></script>
13
+ <script src="components/multiplier.js"></script>
14
+ <style>
15
+ :root {
16
+ --primary: #FF8C00;
17
+ --gold: #FFD700;
18
+ --purple: #9C27B0;
19
+ --blue: #2196F3;
20
+ --green: #4CAF50;
21
+ }
22
+ </style>
23
+ </head>
24
+ <body class="bg-gradient-to-br from-gray-900 via-black to-gray-900 min-h-screen overflow-x-hidden">
25
+ <custom-navbar></custom-navbar>
26
+
27
+ <main class="container mx-auto px-4 py-12 max-w-6xl">
28
+ <!-- Double Spin Loot Box Module -->
29
+ <div class="glass-panel relative rounded-2xl p-8 overflow-hidden">
30
+ <!-- Glow effects -->
31
+ <div class="absolute inset-0 overflow-hidden">
32
+ <div class="absolute -top-20 -left-20 w-80 h-80 bg-orange-500 rounded-full filter blur-3xl opacity-10"></div>
33
+ <div class="absolute -bottom-20 -right-20 w-80 h-80 bg-amber-500 rounded-full filter blur-3xl opacity-10"></div>
34
+ </div>
35
+
36
+ <!-- Header -->
37
+ <div class="flex flex-col md:flex-row justify-between items-start md:items-end mb-12">
38
+ <div>
39
+ <h1 class="text-3xl md:text-4xl font-bold uppercase tracking-wider text-transparent bg-clip-text bg-gradient-to-r from-amber-200 to-amber-400">
40
+ Mystery Loot Box Roll
41
+ </h1>
42
+ <p class="text-gray-300 mt-2 max-w-lg">
43
+ Roll across mystery boxes, unlock a random reward, then boost it with a multiplier spin.
44
+ </p>
45
+ </div>
46
+ <div class="mt-4 md:mt-0 glass-badge px-4 py-2 rounded-full flex items-center">
47
+ <i data-feather="zap" class="w-4 h-4 text-amber-400 mr-2"></i>
48
+ <span class="text-xs font-bold text-amber-100">Today's Legendary Boost: +3%</span>
49
+ </div>
50
+ </div>
51
+
52
+ <!-- Loot Box Track -->
53
+ <custom-lootbox></custom-lootbox>
54
+
55
+ <!-- Roll Button & Status -->
56
+ <div class="flex flex-col items-center mt-8">
57
+ <button id="spinButton" class="spin-button glow-effect relative px-12 py-4 rounded-full text-lg font-bold uppercase tracking-wider transform transition-all hover:scale-105 active:scale-95">
58
+ Roll Loot Box
59
+ </button>
60
+ <div id="statusDisplay" class="text-amber-100 text-sm font-medium mt-3 tracking-wider">Status: Ready</div>
61
+ </div>
62
+
63
+ <!-- Multiplier Slider -->
64
+ <custom-multiplier></custom-multiplier>
65
+
66
+ <!-- Result Panel -->
67
+ <div id="resultPanel" class="glass-panel mt-10 p-6 rounded-xl opacity-0 transition-opacity duration-500">
68
+ <div class="grid grid-cols-3 gap-2 items-end">
69
+ <div>
70
+ <p class="text-gray-400 text-xs uppercase tracking-wider">Base Reward</p>
71
+ <p class="text-white font-medium">30 SC</p>
72
+ </div>
73
+ <div>
74
+ <p class="text-gray-400 text-xs uppercase tracking-wider">Multiplier</p>
75
+ <p class="text-amber-300 font-medium text-xl">×2</p>
76
+ </div>
77
+ <div>
78
+ <p class="text-gray-400 text-xs uppercase tracking-wider">Total Win</p>
79
+ <p class="text-amber-400 font-bold text-2xl flex items-center">
80
+ 60 SC
81
+ <i data-feather="award" class="ml-2 w-5 h-5"></i>
82
+ </p>
83
+ </div>
84
+ </div>
85
+ </div>
86
+ </div>
87
+ </main>
88
+
89
+ <script src="script.js"></script>
90
+ <script>
91
+ feather.replace();
92
+ </script>
93
+ <script src="https://huggingface.co/deepsite/deepsite-badge.js"></script>
94
+ </body>
95
+ </html>
script.js ADDED
@@ -0,0 +1,41 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ document.addEventListener('DOMContentLoaded', function() {
2
+ const spinButton = document.getElementById('spinButton');
3
+ const statusDisplay = document.getElementById('statusDisplay');
4
+ const resultPanel = document.getElementById('resultPanel');
5
+
6
+ // Simulate spin animation
7
+ spinButton.addEventListener('click', function() {
8
+ // Disable button during spin
9
+ spinButton.disabled = true;
10
+ statusDisplay.textContent = "Rolling...";
11
+
12
+ // Trigger loot box and multiplier animations
13
+ const lootBoxComponent = document.querySelector('custom-lootbox');
14
+ const multiplierComponent = document.querySelector('custom-multiplier');
15
+
16
+ if (lootBoxComponent && multiplierComponent) {
17
+ lootBoxComponent.startSpin();
18
+ multiplierComponent.startSpin();
19
+
20
+ // Simulate spin completion
21
+ setTimeout(() => {
22
+ lootBoxComponent.stopSpin();
23
+
24
+ // Second spin starts after first completes
25
+ setTimeout(() => {
26
+ multiplierComponent.stopSpin();
27
+
28
+ // Show results
29
+ setTimeout(() => {
30
+ resultPanel.style.opacity = '1';
31
+ statusDisplay.textContent = "Landed on: EPIC BOX";
32
+ spinButton.disabled = false;
33
+ }, 500);
34
+ }, 1000);
35
+ }, 3000);
36
+ }
37
+ });
38
+
39
+ // Initialize feather icons
40
+ feather.replace();
41
+ });
style.css CHANGED
@@ -1,28 +1,76 @@
 
 
 
1
  body {
2
- padding: 2rem;
3
- font-family: -apple-system, BlinkMacSystemFont, "Arial", sans-serif;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
4
  }
5
 
6
- h1 {
7
- font-size: 16px;
8
- margin-top: 0;
 
 
 
9
  }
10
 
11
- p {
12
- color: rgb(107, 114, 128);
13
- font-size: 15px;
14
- margin-bottom: 10px;
15
- margin-top: 5px;
16
  }
17
 
18
- .card {
19
- max-width: 620px;
20
- margin: 0 auto;
21
- padding: 16px;
22
- border: 1px solid lightgray;
23
- border-radius: 16px;
 
 
 
 
 
 
 
24
  }
25
 
26
- .card p:last-child {
27
- margin-bottom: 0;
28
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /* Base Styles */
2
+ @import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;600;700&display=swap');
3
+
4
  body {
5
+ font-family: 'Inter', sans-serif;
6
+ color: white;
7
+ }
8
+
9
+ /* Glassmorphism Effects */
10
+ .glass-panel {
11
+ background: rgba(15, 15, 15, 0.65);
12
+ backdrop-filter: blur(12px);
13
+ -webkit-backdrop-filter: blur(12px);
14
+ border: 1px solid rgba(255, 255, 255, 0.08);
15
+ box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.36),
16
+ inset 0 0 0 1px rgba(255, 255, 255, 0.05);
17
+ }
18
+
19
+ .glass-badge {
20
+ background: rgba(255, 140, 0, 0.1);
21
+ backdrop-filter: blur(5px);
22
+ -webkit-backdrop-filter: blur(5px);
23
+ border: 1px solid rgba(255, 140, 0, 0.15);
24
  }
25
 
26
+ /* Spin Button */
27
+ .spin-button {
28
+ background: linear-gradient(135deg, #FFCC66 0%, #FF8C00 100%);
29
+ color: rgba(0, 0, 0, 0.8);
30
+ box-shadow: 0 4px 20px rgba(255, 140, 0, 0.4),
31
+ inset 0 2px 0 rgba(255, 255, 255, 0.2);
32
  }
33
 
34
+ .glow-effect {
35
+ position: relative;
36
+ z-index: 1;
 
 
37
  }
38
 
39
+ .glow-effect::after {
40
+ content: '';
41
+ position: absolute;
42
+ top: 0;
43
+ left: 0;
44
+ right: 0;
45
+ bottom: 0;
46
+ background: linear-gradient(135deg, #FFCC66 0%, #FF8C00 100%);
47
+ border-radius: 9999px;
48
+ z-index: -1;
49
+ filter: blur(15px);
50
+ opacity: 0.6;
51
+ transition: opacity 0.3s ease;
52
  }
53
 
54
+ .glow-effect:hover::after {
55
+ opacity: 0.8;
56
  }
57
+
58
+ /* Selection Frame Animation */
59
+ @keyframes pulse-glow {
60
+ 0% { box-shadow: 0 0 0 0 rgba(255, 215, 0, 0.4); }
61
+ 70% { box-shadow: 0 0 0 10px rgba(255, 215, 0, 0); }
62
+ 100% { box-shadow: 0 0 0 0 rgba(255, 215, 0, 0); }
63
+ }
64
+
65
+ /* Loot Box Rarity Colors */
66
+ .common { --glow-color: #4CAF50; }
67
+ .rare { --glow-color: #2196F3; }
68
+ .epic { --glow-color: #9C27B0; }
69
+ .legendary { --glow-color: #FF8C00; }
70
+
71
+ /* Responsive Adjustments */
72
+ @media (max-width: 640px) {
73
+ .glass-panel {
74
+ padding: 1.5rem;
75
+ }
76
+ }