PluginProbe
Ultimate Store Kit – Store Builder Addons for Elementor, WooCommerce Store Builder, EDD Store Builder / 3.1.4
Ultimate Store Kit – Store Builder Addons for Elementor, WooCommerce Store Builder, EDD Store Builder v3.1.4
3.1.4 3.0.8 3.0.9 3.1.0 3.1.2 3.1.3 3.0.7 3.0.5 3.0.4 3.0.3 3.0.2 trunk 1.5.0 1.5.1 1.5.2 1.6.1 1.6.2 1.6.3 1.6.4 2.0.0 2.0.1 2.0.2 2.0.3 2.0.4 2.0.5 All 93 releases
ultimate-store-kit / src / scss / widgets / image-hotspot.scss

image-hotspot.scss in Ultimate Store Kit – Store Builder Addons for Elementor, WooCommerce Store Builder, EDD Store Builder 3.1.4, at src/scss/widgets/image-hotspot.scss

375 lines 8.7 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 /* Image Hotspot - Interactive image with clickable hotspots */
2
3 :root {
4 /* Colors */
5 --usk-hotspot-dark: #2b2d42;
6 --usk-hotspot-white: #fff;
7 --usk-hotspot-bg: #ffffff;
8
9 /* Spacing */
10 --usk-hotspot-gap: clamp(15px, 3vw, 30px);
11 --usk-hotspot-margin: clamp(15px, 3vw, 30px);
12 --usk-hotspot-thumb-size: clamp(32px, 3vw, 40px);
13 --usk-hotspot-btn-height: clamp(40px, 3vw, 50px);
14 --usk-hotspot-spacing: clamp(10px, 1vw, 25px);
15
16 /* Animation */
17 --usk-hotspot-transition: all 0.3s ease;
18 }
19
20 /* Base Layout */
21 .usk-image-hotspot {
22 display: flex;
23 align-items: center;
24 justify-content: center;
25 flex-direction: column;
26 gap: var(--usk-hotspot-gap);
27 width: 100%;
28 }
29
30 /* Thumbnails Container */
31 .usk-image-hotspot-thumbs {
32 position: relative;
33 width: 100%;
34 display: flex;
35 }
36
37 .usk-image-hotspot-thumbs .swiper-wrapper {
38 position: absolute !important;
39 left: 0;
40 top: 0;
41 width: 100%;
42 }
43
44 /* Thumbnail Items */
45 .usk-image-hotspot-thumbs .usk-thumbs-item {
46 position: absolute !important;
47 height: var(--usk-hotspot-thumb-size);
48 width: var(--usk-hotspot-thumb-size) !important;
49 display: flex;
50 justify-content: center;
51 align-items: center;
52 cursor: pointer;
53 overflow: visible !important;
54 z-index: 1;
55 }
56
57 .usk-image-hotspot-thumbs .usk-thumbs-box {
58 background-color: var(--usk-hotspot-bg);
59 display: flex;
60 height: 100%;
61 width: 100%;
62 justify-content: center;
63 align-items: center;
64 border-radius: 100px;
65 overflow: hidden;
66 box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
67 }
68
69 .usk-image-hotspot-thumbs .usk-thumbs-box i,
70 .usk-image-hotspot-thumbs .usk-thumbs-box svg {
71 width: 1em;
72 height: 1em;
73 transition: var(--usk-hotspot-transition);
74 }
75
76 .usk-image-hotspot-thumbs .usk-thumbs-box i {
77 color: var(--usk-hotspot-dark);
78 font-size: 14px;
79 }
80
81 .usk-image-hotspot-thumbs .usk-thumbs-box svg {
82 fill: var(--usk-hotspot-dark);
83 }
84
85 /* Image Wrap */
86 .usk-image-hotspot-thumbs .usk-image-wrap {
87 height: 100%;
88 width: 100%;
89 display: flex;
90 position: relative;
91 }
92
93 .usk-image-hotspot-thumbs .usk-image-wrap .usk-img {
94 height: 100%;
95 width: 100%;
96 object-fit: cover;
97 }
98
99 /* Active Thumbnail State */
100 .usk-image-hotspot-thumbs
101 .usk-thumbs-item.swiper-slide-thumb-active
102 .usk-thumbs-box {
103 background-color: var(--usk-hotspot-dark);
104 transform: scale(1.1);
105 }
106
107 .usk-image-hotspot-thumbs
108 .usk-thumbs-item.swiper-slide-thumb-active
109 .usk-thumbs-box
110 i,
111 .usk-image-hotspot-thumbs
112 .usk-thumbs-item.swiper-slide-thumb-active
113 .usk-thumbs-box
114 svg {
115 color: var(--usk-hotspot-white);
116 fill: var(--usk-hotspot-white);
117 }
118
119 /* Hotspot Animation */
120 .usk-image-hotspot-thumbs .usk-thumbs-item:after {
121 content: "";
122 position: absolute;
123 display: block;
124 animation: 2s infinite hotspot-icon;
125 border-radius: 50%;
126 backface-visibility: hidden;
127 perspective: 800px;
128 background-color: var(--usk-hotspot-white);
129 opacity: 0.3;
130 width: 64px;
131 height: 64px;
132 transition: 0.2s ease-in-out;
133 z-index: -1;
134 left: 50%;
135 top: 50%;
136 transform: translate(-50%, -50%);
137 }
138
139 /* Main Content */
140 .usk-image-hotspot-main {
141 width: 80%;
142 position: relative;
143 }
144
145 /* Tippy Tooltip Styles */
146 .tippy-box[data-theme^="bdt-tippy-image-hotspot-"]^="bdt-tippy-image-hotspot-""] {
147 background-color: transparent !important;
148 max-width: 300px !important;
149 }
150
151 .tippy-box[data-theme^="bdt-tippy-image-hotspot-"]^="bdt-tippy-image-hotspot-""] .tippy-content {
152 padding: 0;
153 border-radius: 0;
154 background-color: transparent;
155 }
156
157 .tippy-box[data-theme^="bdt-tippy-image-hotspot-"]^="bdt-tippy-image-hotspot-""] .tippy-arrow {
158 color: var(--usk-hotspot-white);
159 z-index: 1;
160 }
161
162 .tippy-box[data-theme^="bdt-tippy-image-hotspot-"]^="bdt-tippy-image-hotspot-""] a {
163 text-decoration: none;
164 color: inherit;
165 }
166
167 /* Common Styles for Tippy and Main Content */
168 .tippy-box[data-theme^="bdt-tippy-image-hotspot-"]^="bdt-tippy-image-hotspot-""],
169 .usk-image-hotspot-main {
170 --btn-width: 100%;
171 }
172
173 .tippy-box[data-theme^="bdt-tippy-image-hotspot-"]^="bdt-tippy-image-hotspot-""] .usk-item,
174 .usk-image-hotspot-main .usk-item {
175 overflow: hidden;
176 background-color: var(--usk-hotspot-white);
177 position: relative;
178 border-radius: 4px;
179 box-shadow: 0 2px 15px rgba(0, 0, 0, 0.08);
180 }
181
182 /* Action Button */
183 .tippy-box[data-theme^="bdt-tippy-image-hotspot-"]^="bdt-tippy-image-hotspot-""] .usk-action-btn,
184 .usk-image-hotspot-main .usk-action-btn {
185 transform: translateX(25px);
186 transition: var(--usk-hotspot-transition);
187 }
188
189 .tippy-box[data-theme^="bdt-tippy-image-hotspot-"]^="bdt-tippy-image-hotspot-""]
190 .usk-item:hover
191 .usk-action-btn,
192 .usk-image-hotspot-main .usk-item:hover .usk-action-btn {
193 transform: translateX(0);
194 }
195
196 /* Shopping and Badge Positioning */
197 .tippy-box[data-theme^="bdt-tippy-image-hotspot-"]^="bdt-tippy-image-hotspot-""] .usk-shoping,
198 .usk-image-hotspot-main .usk-shoping {
199 position: absolute;
200 top: var(--usk-hotspot-spacing);
201 right: var(--usk-hotspot-spacing);
202 z-index: 2;
203 }
204
205 .tippy-box[data-theme^="bdt-tippy-image-hotspot-"]^="bdt-tippy-image-hotspot-""] .usk-badge-label-wrapper,
206 .usk-image-hotspot-main .usk-badge-label-wrapper {
207 position: absolute;
208 left: 0;
209 top: 0;
210 z-index: 2;
211 }
212
213 /* Button Styles */
214 .tippy-box[data-theme^="bdt-tippy-image-hotspot-"]^="bdt-tippy-image-hotspot-""] .usk-button,
215 .tippy-box[data-theme^="bdt-tippy-image-hotspot-"]^="bdt-tippy-image-hotspot-""] .added_to_cart,
216 .usk-image-hotspot-main .usk-button,
217 .usk-image-hotspot-main .added_to_cart {
218 position: absolute;
219 font-weight: 600;
220 text-align: center;
221 left: 0;
222 bottom: 0;
223 width: var(--btn-width);
224 margin: 0 calc(calc(100% - var(--btn-width)) / 2);
225 background: var(--usk-hotspot-dark);
226 text-decoration: none;
227 color: var(--usk-hotspot-white);
228 text-transform: capitalize;
229 transform: translateY(100%);
230 opacity: 0;
231 visibility: hidden;
232 transition: var(--usk-hotspot-transition);
233 height: var(--usk-hotspot-btn-height);
234 line-height: var(--usk-hotspot-btn-height);
235 font-size: 14px;
236 z-index: 3;
237 }
238
239 /* Button States */
240 .tippy-box[data-theme^="bdt-tippy-image-hotspot-"]^="bdt-tippy-image-hotspot-""] .usk-button.added,
241 .usk-image-hotspot-main .usk-button.added {
242 display: none;
243 }
244
245 .tippy-box[data-theme^="bdt-tippy-image-hotspot-"]^="bdt-tippy-image-hotspot-""] .usk-button.loading i,
246 .usk-image-hotspot-main .usk-button.loading i {
247 transition: var(--usk-hotspot-transition);
248 transform: translate(70px);
249 opacity: 0.02;
250 }
251
252 .tippy-box[data-theme^="bdt-tippy-image-hotspot-"]^="bdt-tippy-image-hotspot-""] .usk-item:hover .usk-button,
253 .tippy-box[data-theme^="bdt-tippy-image-hotspot-"]^="bdt-tippy-image-hotspot-""]
254 .usk-item:hover
255 .added_to_cart,
256 .usk-image-hotspot-main .usk-item:hover .usk-button,
257 .usk-image-hotspot-main .usk-item:hover .added_to_cart {
258 transform: translateY(0);
259 opacity: 1;
260 visibility: visible;
261 }
262
263 /* Loading State */
264 .tippy-box[data-theme^="bdt-tippy-image-hotspot-"]^="bdt-tippy-image-hotspot-""] .usk-button.loading::after,
265 .usk-image-hotspot-main .usk-button.loading::after {
266 content: "";
267 width: 20px;
268 height: 20px;
269 border: 2px dotted var(--usk-hotspot-white);
270 border-radius: 50%;
271 margin-left: -15px;
272 display: inline-block;
273 position: absolute;
274 top: 31%;
275 text-align: center;
276 animation: rotation 2s linear infinite;
277 }
278
279 /* Added to Cart State */
280 .tippy-box[data-theme^="bdt-tippy-image-hotspot-"]^="bdt-tippy-image-hotspot-""] .added_to_cart::after,
281 .usk-image-hotspot-main .added_to_cart::after {
282 content: "\2713";
283 margin-left: 5px;
284 font-size: 20px;
285 }
286
287 .tippy-box[data-theme^="bdt-tippy-image-hotspot-"]^="bdt-tippy-image-hotspot-""] .added_to_cart i,
288 .usk-image-hotspot-main .added_to_cart i {
289 display: none;
290 }
291
292 /* Rating and Price Toggle */
293 .tippy-box[data-theme^="bdt-tippy-image-hotspot-"]^="bdt-tippy-image-hotspot-""] .usk-have-rating .usk-price,
294 .usk-image-hotspot-main .usk-have-rating .usk-price {
295 margin: 0;
296 opacity: 1;
297 transition: var(--usk-hotspot-transition);
298 transform: translateY(0);
299 }
300
301 .tippy-box[data-theme^="bdt-tippy-image-hotspot-"]^="bdt-tippy-image-hotspot-""] .usk-have-rating .usk-rating,
302 .usk-image-hotspot-main .usk-have-rating .usk-rating {
303 transform: translateY(0);
304 opacity: 0;
305 transition: var(--usk-hotspot-transition);
306 position: absolute;
307 width: 100%;
308 display: flex;
309 }
310
311 .tippy-box[data-theme^="bdt-tippy-image-hotspot-"]^="bdt-tippy-image-hotspot-""]
312 .usk-have-rating:hover
313 .usk-rating,
314 .usk-image-hotspot-main .usk-have-rating:hover .usk-rating {
315 transform: translateY(-20px);
316 opacity: 1;
317 }
318
319 .tippy-box[data-theme^="bdt-tippy-image-hotspot-"]^="bdt-tippy-image-hotspot-""]
320 .usk-have-rating:hover
321 .usk-price,
322 .usk-image-hotspot-main .usk-have-rating:hover .usk-price {
323 transform: translateY(-20px);
324 opacity: 0;
325 visibility: hidden;
326 }
327
328 /* Animations */
329 @keyframes hotspot-icon {
330 0% {
331 opacity: 0;
332 transform: translate(-50%, -50%) scale(0.2);
333 }
334 50% {
335 opacity: 0.4;
336 }
337 100% {
338 opacity: 0;
339 transform: translate(-50%, -50%) scale(1);
340 }
341 }
342
343 @keyframes rotation {
344 from {
345 transform: rotate(0deg);
346 }
347 to {
348 transform: rotate(360deg);
349 }
350 }
351
352 /* Responsive Styles */
353 @media (min-width: 768px) {
354 .usk-image-hotspot-main {
355 width: 27%;
356 min-width: 27%;
357 }
358
359 .usk-image-hotspot-slider-left .usk-image-hotspot {
360 flex-direction: row;
361 }
362
363 .usk-image-hotspot-slider-left .usk-image-hotspot-main {
364 margin-left: var(--usk-hotspot-margin);
365 }
366
367 .usk-image-hotspot-slider-right .usk-image-hotspot {
368 flex-direction: row-reverse;
369 }
370
371 .usk-image-hotspot-slider-right .usk-image-hotspot-main {
372 margin-right: var(--usk-hotspot-margin);
373 }
374 }
375