2021/src/assets/scss/news.scss
2021-01-19 17:39:16 +08:00

317 lines
6.1 KiB
SCSS

@import './hyperpoint.scss';
@import './color.scss';
// desktop mode
#news-header {
padding: 72px 280px;
.top-bar {
position: relative;
// background: red; // debug
height: 60px;
.return-wrapper {
// location
position: absolute;
left: -30px;
bottom: -4px;
.shape-wrapper {
background: $white;
border-radius: 12px;
-webkit-box-shadow: -18px 18px 0px -6px $mid-blue,
0px 0px 10px 0px rgba(0, 0, 0, 0.2);
-moz-box-shadow: -18px 18px 0px -6px $mid-blue,
0px 0px 10px 0px rgba(0, 0, 0, 0.2);
box-shadow: -18px 18px 0px -6px $mid-blue,
0px 0px 10px 0px rgba(0, 0, 0, 0.2);
@keyframes jump {
0% {position: relative;bottom: 0px;}
50% {position: relative;bottom: 20px;}
100% {position: relative;bottom: 0px;}
}
&:hover {
animation: jump .6s ease-in 0s infinite reverse;
}
.text-wrapper {
width: 68px;
height: 68px;
line-height: 68px;
text-align: center;
color: $mid-blue;
font-weight: bold;
font-size: 16pt;
}
}
}
.contribute-wrapper {
display: none; // display in mobile
}
.title-wrapper {
.svg-cfp-news {
height: 60px;
width: auto;
}
}
}
.cfp-body {
padding: 40px 48px;
margin-top: 54px;
border-radius: 24px;
color: $white;
background: $mid-blue;
font-size: 14pt;
font-weight: bold;
display: flex;
flex-direction: column;
align-items: center;
.spot-wrapper {
margin-bottom: 2.25em;
h1 {
font-size: 26pt;
margin-bottom: 1em;
}
.countdown {
line-height: 1.5;
}
}
.time-wrapper {
display: flex;
flex-direction: row;
align-items: flex-start;
h2 {
height: 24pt;
}
p {
font-size: 1.44em;
}
.tilde-wrapper {
margin-right: 0.85em;
}
}
}
}
@include lg {
#news-header {
padding-left: 120px;
padding-right: 120px;
}
}
// mobile mode
@include md {
#news-header {
font-size: 14pt;
padding: 72px 100px;
.top-bar {
position: initial;
height: 5em;
border-radius: 2.5em;
padding-left: 2.5em;
padding-right: 2.5em;
background: $white;
-webkit-box-shadow: 0px 0px 16px 0px rgba(0, 0, 0, 0.5);
-moz-box-shadow: 0px 0px 16px 0px rgba(0, 0, 0, 0.5);
box-shadow: 0px 0px 16px 0px rgba(0, 0, 0, 0.5);
display: flex;
flex-direction: row;
align-items: center;
.return-wrapper {
// location
position: initial;
flex: 1;
.shape-wrapper {
background: $white;
border-radius: 12px;
-webkit-box-shadow: -13px 13px 0px -6px $mid-blue,
0px 0px 10px 0px rgba(0, 0, 0, 0.2);
-moz-box-shadow: -13px 13px 0px -6px $mid-blue,
0px 0px 10px 0px rgba(0, 0, 0, 0.2);
box-shadow: -13px 13px 0px -6px $mid-blue,
0px 0px 10px 0px rgba(0, 0, 0, 0.2);
.text-wrapper {
width: 3em;
height: 3em;
line-height: 3em;
text-align: center;
color: $mid-blue;
font-weight: bold;
font-size: 1em;
}
}
}
.title-wrapper {
flex: 1;
.svg-cfp-news {
height: 2.25em;
width: auto;
}
}
.contribute-wrapper {
display: initial;
flex: 1;
text-align: end;
.btn-contribute {
display: inline-block;
border-radius: 6px;
background: $mid-blue;
color: $white;
font-weight: 900;
padding: 0.5em;
font-size: 1.2em;
}
}
}
.cfp-body {
padding-top: 2em;
padding-left: 2em;
padding-right: 2em;
padding-bottom: 3.5em;
margin-top: 54px;
border-radius: 24px;
color: $white;
background: $mid-blue;
font-weight: bold;
font-size: 1em;
.spot-wrapper {
h1 {
font-size: 2em;
margin-bottom: 1em;
}
margin-bottom: 2.25em;
}
.time-wrapper {
display: flex;
flex-direction: column;
h2 {
height: initial;
}
p {
font-size: 1.25em;
}
.start-time-wrapper {
h2,
p {
margin-bottom: 1.25em;
}
}
.end-time-wrapper {
h2 {
margin-bottom: 1.25em;
}
}
.tilde-wrapper {
display: none;
}
}
}
}
}
@include sm {
#news-header {
font-size: 12pt;
padding: 60px 40px;
.cfp-body {
font-size: 14pt;
}
}
}
// a 540px break point will be better = =
@media screen and (max-width: 539px) {
#news-header {
font-size: 10pt;
padding: 36px 18px;
.top-bar {
height: 4em;
border-radius: 2em;
padding-left: 1.66em;
padding-right: 1em;
-webkit-box-shadow: 0px 0px 16px 0px rgba(0, 0, 0, 0.5);
-moz-box-shadow: 0px 0px 16px 0px rgba(0, 0, 0, 0.5);
box-shadow: 0px 0px 16px 0px rgba(0, 0, 0, 0.5);
.return-wrapper {
.shape-wrapper {
.text-wrapper {
width: 2.4em;
height: 2.4em;
line-height: 2.4em;
text-align: center;
color: $mid-blue;
font-weight: bold;
font-size: 1em;
}
}
}
.title-wrapper {
flex: 1;
.svg-cfp-news {
height: 1.85em;
width: auto;
}
}
.contribute-wrapper {
display: initial;
flex: 1;
text-align: end;
.btn-contribute {
display: inline-block;
border-radius: 6px;
background: $mid-blue;
color: $white;
font-weight: 900;
padding: 0.5em;
font-size: 1.2em;
}
}
}
.cfp-body {
font-size: 12pt;
}
}
}