147 lines
2.2 KiB
CSS
147 lines
2.2 KiB
CSS
:root {
|
|
--btn-dark: #1C1C1C;
|
|
--btn-light: #E3E3E3;
|
|
}
|
|
|
|
@font-face {
|
|
font-family: 'Lato';
|
|
src: url('fonts/Lato-Regular.ttf');
|
|
src: url('fonts/Lato-Regular.ttf') format('truetype');
|
|
}
|
|
|
|
* {
|
|
box-sizing: border-box;
|
|
padding: 0;
|
|
margin: 0;
|
|
}
|
|
|
|
body {
|
|
display: grid;
|
|
grid-template-columns: 1fr;
|
|
grid-template-rows: 1fr;
|
|
width: 100vw;
|
|
height: 100vh;
|
|
}
|
|
|
|
main {
|
|
display: grid;
|
|
|
|
background: #0002;
|
|
}
|
|
|
|
.grid.center {
|
|
place-content: center;
|
|
place-items: center;
|
|
}
|
|
|
|
.btn:focus {
|
|
outline: none;
|
|
}
|
|
|
|
.btn.cbtn {
|
|
display: grid;
|
|
place-content: center;
|
|
place-items: center;
|
|
position: relative;
|
|
|
|
padding: 2.2rem;
|
|
|
|
width: 0;
|
|
height: 0;
|
|
|
|
border: none;
|
|
background: none;
|
|
color: #000;
|
|
font: unset;
|
|
|
|
border-radius: 100vw;
|
|
}
|
|
.btn.cbtn {
|
|
--padding: 5vmin;
|
|
padding: var(--padding);
|
|
font-size: 3vmin;
|
|
}
|
|
|
|
.btn.cbtn.medium {
|
|
--padding: 5vmin;
|
|
padding: var(--padding);
|
|
font-size: 3vmin;
|
|
}
|
|
|
|
.btn.cbtn.big {
|
|
--padding: 30vmin;
|
|
padding: var(--padding);
|
|
font-size: 20vmin;
|
|
}
|
|
|
|
.btn.cbtn.overlap {
|
|
margin: -1vmin;
|
|
}
|
|
.btn.cbtn > i {
|
|
display: grid;
|
|
place-items: center;
|
|
}
|
|
.btn.cbtn > i::after {
|
|
display: grid;
|
|
place-content: center;
|
|
position: absolute;
|
|
|
|
z-index: 1000;
|
|
|
|
overflow: hidden;
|
|
|
|
padding: 0rem;
|
|
|
|
background: var(--btn-light);
|
|
color: var(--btn-dark);
|
|
filter: invert(1);
|
|
|
|
width: 0;
|
|
height: 0;
|
|
|
|
border-radius: 100vw;
|
|
transition: padding .2s;
|
|
}
|
|
/* When deployed on a platform, choose one or the other, not both */
|
|
.btn.cbtn:focus > i::after, /* TV */
|
|
.btn.cbtn:hover > i::after /* PC */ {
|
|
padding: var(--padding);
|
|
}
|
|
|
|
@keyframes cbtn-click {
|
|
from {
|
|
padding: 0rem;
|
|
opacity: 1;
|
|
}
|
|
to {
|
|
padding: inherit;
|
|
opacity: 0;
|
|
}
|
|
}
|
|
.btn.cbtn > .click {
|
|
position: absolute;
|
|
padding: 0rem;
|
|
opacity: 1;
|
|
z-index: 10000;
|
|
|
|
border-radius: 100vw;
|
|
width: 0;
|
|
height: 0;
|
|
|
|
/*box-shadow: inset 0 0 2px #FFF;*/
|
|
background: #DDD8;
|
|
border: 4px solid #fff;
|
|
|
|
animation: cbtn-click .2s;
|
|
}
|
|
|
|
.btn.sbtn {
|
|
padding: 1rem 2rem;
|
|
text-align: center;
|
|
text-decoration: none;
|
|
font-family: Lato;
|
|
}
|
|
|
|
.btn.sbtn::after {
|
|
|
|
} |