forked from HoloTech/twitch-subathon-timer
- added JS logic for controlling animations based on text length - added duplicate elements for looping scroll effect and JS logic for populating them
288 lines
4.4 KiB
CSS
288 lines
4.4 KiB
CSS
:root {
|
|
--time-color: #453960;
|
|
--details-color: #403060;
|
|
--background-color: transparent;
|
|
}
|
|
|
|
* {
|
|
box-sizing: border-box;
|
|
}
|
|
|
|
html, body {
|
|
height: 100%;
|
|
margin: 0;
|
|
padding: 0;
|
|
font-family: 'Inter', sans-serif;
|
|
background-color: var(--background-color);
|
|
background-color: transparent;
|
|
overflow: hidden;
|
|
}
|
|
|
|
main {
|
|
font-family: "Silkscreen", sans-serif;
|
|
font-weight: 400;
|
|
font-style: normal;
|
|
color: #EA4045;
|
|
height: 100%;
|
|
}
|
|
|
|
h1 {
|
|
margin: 0;
|
|
font-size: 3.4em;
|
|
color: #404145;
|
|
font-weight: normal;
|
|
}
|
|
|
|
h2 {
|
|
margin: 0;
|
|
font-size: 1.4em;
|
|
color: #404145;
|
|
font-weight: normal;
|
|
}
|
|
|
|
h3 {
|
|
margin: 0;
|
|
font-size: 1em;
|
|
color: #404145;
|
|
font-weight: normal;
|
|
}
|
|
|
|
p {
|
|
margin: 0;
|
|
font-size: 1.4em;
|
|
line-height: 95%;
|
|
}
|
|
|
|
.contentContainer {
|
|
height: fit-content;
|
|
width: fit-content;
|
|
position: relative;
|
|
text-align: center;
|
|
}
|
|
|
|
.mainHeart {
|
|
max-height: 100vh;
|
|
max-width: 75vw;
|
|
}
|
|
|
|
#SecondHeart {
|
|
position: absolute;
|
|
top: 0px;
|
|
left: 0px;
|
|
}
|
|
|
|
.infoWrap {
|
|
container-type: size;
|
|
height: 100%;
|
|
width: 100%;
|
|
position: absolute;
|
|
left: 0px;
|
|
top: 0px;
|
|
display: grid;
|
|
grid-template-columns: 56% 34% 1fr;
|
|
grid-template-rows: 11% 1fr 29%;
|
|
place-items: center;
|
|
text-wrap: nowrap;
|
|
}
|
|
|
|
.infoGroup {
|
|
height: 100%;
|
|
width: 100%;
|
|
grid-column-start: 2;
|
|
grid-column-end: 2;
|
|
grid-row-start: 2;
|
|
grid-row-end: 2;
|
|
}
|
|
|
|
.infoBox {
|
|
height: auto;
|
|
width: 100%;
|
|
font-size: 4cqh;
|
|
transform: translate(12%, -68%);
|
|
}
|
|
|
|
#InfoBox1 {
|
|
|
|
}
|
|
|
|
#InfoBox2 {
|
|
transform: translate(-1%, -88%);
|
|
}
|
|
|
|
#InfoBox3 {
|
|
width: 110%;
|
|
position: relative;
|
|
transform: translate(88%, 25%) scale(1, 1);
|
|
border-radius: 3cqh;
|
|
border: .4cqh solid;
|
|
border-color: #00A0F3;
|
|
background-color: white;
|
|
}
|
|
|
|
.rightFadeWrap {
|
|
mask-image: linear-gradient(to right, black 85%, transparent 100%);
|
|
}
|
|
|
|
#RightFadeWrapInfoBox3 {
|
|
|
|
}
|
|
|
|
#Timer {
|
|
margin-top: 10%;
|
|
margin-bottom: 2%;
|
|
transform: translate(-7.5%, 3%) scale(.95, 1.2);
|
|
}
|
|
|
|
#TimerInfo {
|
|
transform: translate(0%, -60%);
|
|
display: none;
|
|
}
|
|
|
|
#GoalLabel {
|
|
transform: translate(5%, 0%) scale(1);
|
|
color: #404145;
|
|
}
|
|
|
|
#GoalName {
|
|
width: fit-content;
|
|
position: relative;
|
|
color: #32B993;
|
|
text-wrap: nowrap;
|
|
display: inline-block;
|
|
padding-right: 4%;
|
|
transform: translate(.5ch, 0%);
|
|
/* --- animation-duration = JS VAR --- */
|
|
}
|
|
|
|
#GoalNameDupe {
|
|
width: fit-content;
|
|
position: relative;
|
|
color: #32B993;
|
|
text-wrap: nowrap;
|
|
padding-right: 4%;
|
|
transform: translate(.5ch, 0%);
|
|
/* --- animation-duration = JS VAR --- */
|
|
}
|
|
|
|
#GoalProgressWrap {
|
|
width: fit-content;
|
|
padding-left: .8cqh;
|
|
padding-right: .8cqh;
|
|
transform: translate(7%, 0%) scale(1, 1);
|
|
border-radius: 3cqh;
|
|
border: .4cqh solid;
|
|
border-color: #404145;
|
|
margin: 0 auto .8cqh auto;
|
|
}
|
|
|
|
#GoalProgress {
|
|
transform: translate(0%, -8%) scale(1);
|
|
text-align: center;
|
|
}
|
|
|
|
#TopUsers {
|
|
margin-bottom: 2%;
|
|
font-weight: normal;
|
|
color: #404145;
|
|
}
|
|
|
|
.giftUserWrap {
|
|
transform: translate(11%, -8%) scale(1, 1);
|
|
}
|
|
|
|
.giftUserRow {
|
|
width: 100%;
|
|
display: grid;
|
|
grid-template-columns: 8% 1fr;
|
|
grid-template-rows: 1fr;
|
|
text-wrap: nowrap;
|
|
overflow: hidden;
|
|
text-align: center;
|
|
transform: translate(0%, 0%) scale(1, 1);
|
|
}
|
|
|
|
.giftUserName {
|
|
width: fit-content;
|
|
margin-left: 0%;
|
|
position: relative;
|
|
color: #32B993;
|
|
text-align: left;
|
|
display: inline-block;
|
|
padding-right: 4%;
|
|
transform: translate(.5ch, 0%);
|
|
}
|
|
|
|
.giftUserNameDupe {
|
|
width: fit-content;
|
|
margin-left: 0%;
|
|
position: relative;
|
|
color: #32B993;
|
|
text-align: left;
|
|
padding-right: 4%;
|
|
transform: translate(.5ch, 0%);
|
|
}
|
|
|
|
#GiftUserName1 {
|
|
/* --- animation-duration = JS VAR --- */
|
|
}
|
|
|
|
#GiftUserName2 {
|
|
/* --- animation-duration = JS VAR --- */
|
|
animation-delay: 3s;
|
|
}
|
|
|
|
#GiftUserName3 {
|
|
/* --- animation-duration = JS VAR --- */
|
|
animation-delay: 6s;
|
|
}
|
|
|
|
#GiftUserNameDupe1 {
|
|
/* --- animation-duration = JS VAR --- */
|
|
}
|
|
|
|
#GiftUserNameDupe2 {
|
|
/* --- animation-duration = JS VAR --- */
|
|
animation-delay: 3s;
|
|
}
|
|
|
|
#GiftUserNameDupe3 {
|
|
/* --- animation-duration = JS VAR --- */
|
|
animation-delay: 6s;
|
|
}
|
|
|
|
.scrollWrap {
|
|
width: 100%;
|
|
}
|
|
|
|
.fadeLeft {
|
|
mask-image: linear-gradient(to right, transparent 0%, black 1ch);
|
|
}
|
|
|
|
#ScrollWrapGoal {
|
|
transform: translate(8%, -10%) scale(1);
|
|
}
|
|
|
|
.scrollWrapName {
|
|
}
|
|
|
|
.scrollWrapW {
|
|
width: fit-content;
|
|
display: flex;
|
|
}
|
|
|
|
#ScrollWrapGoalW {
|
|
}
|
|
|
|
.hide {
|
|
display: none;
|
|
}
|
|
|
|
.scrollAnim {
|
|
animation: myScroll linear infinite;
|
|
}
|
|
|
|
@keyframes myScroll {
|
|
0% {left: 0%; top: 0%;}
|
|
42% {left: 0%; top: 0%;}
|
|
100% {left: -54%; top: 0%;}
|
|
} |