|
1 |
| -<div class="bg-navy py-f24 text-white"> |
2 |
| - <div class="flex items-center justify-center gap-f12 md:gap-f24"> |
3 |
| - <h2 class="title-70 text-[30px] sm:text-[46px] md:text-[70px]">Your:</h2> |
| 1 | +<div class="flex items-center justify-center gap-f12 bg-navy text-white md:gap-f24"> |
| 2 | + <h2 class="title-70 text-[48px] md:text-[70px]">Your:</h2> |
4 | 3 |
|
5 |
| - <div class="text-slide-container overflow-hidden h-[300px]"> |
6 |
| - <div class="text-slide"> |
7 |
| - <span class="emphasized-text">Content</span> |
8 |
| - <span class="emphasized-text">Followers</span> |
9 |
| - <span class="emphasized-text">Network</span> |
10 |
| - <span class="emphasized-text">Content</span> |
11 |
| - <span class="emphasized-text">Followers</span> |
12 |
| - <span class="emphasized-text">Network</span> |
13 |
| - </div> |
| 4 | + <div class="h-[240px] overflow-hidden"> |
| 5 | + <div class="text-slider-container"> |
| 6 | + <span class="slider-item" id="first">Content</span> |
| 7 | + <span class="slider-item" id="second">Followers</span> |
| 8 | + <span class="slider-item" id="third">Network</span> |
| 9 | + <span class="slider-item" id="fourth">Content</span> |
| 10 | + <span class="slider-item" id="fifth">Followers</span> |
| 11 | + <span class="slider-item" id="sixth">Network</span> |
14 | 12 | </div>
|
15 | 13 | </div>
|
16 | 14 | </div>
|
17 | 15 |
|
18 | 16 | <style>
|
19 |
| - .thin-text { |
20 |
| - @apply text-[20px] font-thin opacity-40 sm:text-[30px] md:text-[50px] h-[100px]; |
| 17 | + .text-slider-container { |
| 18 | + @apply flex flex-col gap-0; |
| 19 | + animation: text-slide 10s linear infinite; |
21 | 20 | }
|
22 | 21 |
|
23 |
| - .emphasized-text { |
24 |
| - @apply text-[30px] font-thin sm:text-[48px] md:text-[70px] h-[100px]; |
| 22 | + .slider-item { |
| 23 | + @apply flex h-[80px] origin-[center_left] items-center text-[48px] font-thin md:text-[70px]; |
25 | 24 | }
|
26 | 25 |
|
27 |
| - .text-slide-container { |
28 |
| - position: relative; |
29 |
| - overflow: hidden; |
| 26 | + /*Text Slider Items bold and scale animations*/ |
| 27 | + #first { |
| 28 | + scale: 0.75; |
| 29 | + opacity: 0.33; |
30 | 30 | }
|
31 |
| -
|
32 |
| - .text-slide { |
33 |
| - @apply flex flex-col gap-0; |
34 |
| - animation: text-slide 4s linear infinite; |
| 31 | + #second { |
| 32 | + animation: second 10s linear infinite; |
35 | 33 | }
|
36 |
| -
|
37 |
| - .text-slide span:nth-child(1) { |
38 |
| - animation: unbold 2s linear; |
| 34 | + #third { |
| 35 | + animation: third 10s linear infinite; |
| 36 | + } |
| 37 | + #fourth { |
| 38 | + animation: fourth 10s linear infinite; |
| 39 | + } |
| 40 | + #fifth { |
| 41 | + animation: fifth 10s linear infinite; |
| 42 | + } |
| 43 | + #sixth { |
| 44 | + scale: 0.75; |
| 45 | + opacity: 0.33; |
39 | 46 | }
|
40 | 47 |
|
41 |
| - /*.text-slide span:nth-child(2) {*/ |
42 |
| - /* animation: middle-bold 8s linear infinite 2s; !* Adjust timing for each *!*/ |
43 |
| - /*}*/ |
44 |
| -
|
45 |
| - /*.text-slide span:nth-child(3) {*/ |
46 |
| - /* animation: middle-bold 8s linear infinite 4s;*/ |
47 |
| - /*}*/ |
| 48 | + /*Followers bold and scale animation*/ |
| 49 | + @keyframes second { |
| 50 | + 0%, |
| 51 | + 20% { |
| 52 | + transform: scale(1); |
| 53 | + opacity: 1; |
| 54 | + } |
| 55 | + 33.33%, |
| 56 | + 100% { |
| 57 | + transform: scale(0.75); |
| 58 | + opacity: 0.33; |
| 59 | + } |
| 60 | + } |
48 | 61 |
|
49 |
| - /* Animation to emphasize the middle word */ |
50 |
| - @keyframes unbold { |
51 |
| - 0% { |
| 62 | + /*Network bold and scale animation*/ |
| 63 | + @keyframes third { |
| 64 | + 0%, |
| 65 | + 20% { |
52 | 66 | transform: scale(0.75);
|
53 |
| - opacity: 0.75; |
| 67 | + opacity: 0.33; |
54 | 68 | }
|
55 |
| - 100% { |
| 69 | + 33.33%, |
| 70 | + 53.33% { |
56 | 71 | transform: scale(1);
|
57 | 72 | opacity: 1;
|
58 | 73 | }
|
| 74 | + 66.66%, |
| 75 | + 100% { |
| 76 | + transform: scale(0.75); |
| 77 | + opacity: 0.33; |
| 78 | + } |
59 | 79 | }
|
60 | 80 |
|
61 |
| - /* Animation to emphasize the middle word */ |
62 |
| - @keyframes bold-unbold { |
63 |
| - 0% { |
| 81 | + /*Content bold and scale animation*/ |
| 82 | + @keyframes fourth { |
| 83 | + 0%, |
| 84 | + 53.33% { |
64 | 85 | transform: scale(0.75);
|
65 |
| - opacity: 0.75; |
| 86 | + opacity: 0.33; |
66 | 87 | }
|
67 |
| - 33.33%, 66.66% { |
| 88 | + 66.66%, |
| 89 | + 86.66% { |
68 | 90 | transform: scale(1);
|
69 | 91 | opacity: 1;
|
70 | 92 | }
|
71 | 93 | 100% {
|
72 | 94 | transform: scale(0.75);
|
73 |
| - opacity: 0.75; |
| 95 | + opacity: 0.33; |
| 96 | + } |
| 97 | + } |
| 98 | +
|
| 99 | + /*Followers 2 bold and scale animation*/ |
| 100 | + @keyframes fifth { |
| 101 | + 0%, |
| 102 | + 86.66% { |
| 103 | + transform: scale(0.75); |
| 104 | + opacity: 0.33; |
| 105 | + } |
| 106 | + 100% { |
| 107 | + transform: scale(1); |
| 108 | + opacity: 1; |
74 | 109 | }
|
75 | 110 | }
|
76 | 111 |
|
77 |
| - /* Animation to slide text */ |
| 112 | + /* Animation to slide all text */ |
78 | 113 | @keyframes text-slide {
|
79 |
| - 0%, 20% { |
| 114 | + 0%, |
| 115 | + 20% { |
80 | 116 | transform: translateY(0);
|
81 | 117 | }
|
82 |
| - 33.33%, 53.33% { |
83 |
| - transform: translateY(-100px); |
| 118 | + 33.33%, |
| 119 | + 53.33% { |
| 120 | + transform: translateY(-80px); |
84 | 121 | }
|
85 |
| - 66.66%, 86.66% { |
86 |
| - transform: translateY(-200px); |
| 122 | + 66.66%, |
| 123 | + 86.66% { |
| 124 | + transform: translateY(-160px); |
87 | 125 | }
|
88 | 126 | 100% {
|
89 |
| - transform: translateY(-300px); |
| 127 | + transform: translateY(-240px); |
90 | 128 | }
|
91 | 129 | }
|
92 | 130 | </style>
|
0 commit comments