body { margin: 0; padding: 0; overflow: hidden; background: #202028; font-family: Roboto, Helvetica, Arial, sans-serif; font-size: 2.5em; color: #fff; } .menu { -webkit-transition: 0.1s -webkit-transform linear; transition: 0.1s -webkit-transform linear; transition: 0.1s transform linear; transition: 0.1s transform linear, 0.1s -webkit-transform linear; position: absolute; background: 0; float: left; height: 2.7rem; width: 3.5rem; z-index: 1; outline: 0; padding: 0; border: 0; -webkit-transform: scale(.5); -moz-transform: scale(.5); -ms-transform: scale(.5); -o-transform: scale(.5); transform: scale(.5); } #menu { position: fixed; width: 100%; height: 100%; background: rgba(0, 0, 0, .75); transform: translateX(-100%); -webkit-transition: transform .5s; -moz-transition: transform .5s; -ms-transition: transform .5s; -o-transition: transform .5s; transition: transform .5s; z-index: 100; top: 0; } #menu-content { position: fixed; left: 50%; top: 50%; transform: translate(-50%, -50%); font-size: .6em; width: 20%; } #menu-content > * { padding: 20px; border-bottom: 1px solid #444; } #menu-content h3 { margin: 0 0 15px; } #help-controls dl { height: 273px; margin: 0; } #help-controls dt { float: left; width: 30%; margin-bottom: 10px; } #help-controls dt code { background: rgba(255, 255, 255, 1); padding: 5px 10px; border-radius: 5px; color: #000; } #help-controls dd { float: left; width: 70%; margin: 0 0 10px; } .menu-open #menu { transform: none; } #menu-opener { position: absolute; left: 10px; top: 10px; z-index: 101; } .lang { display: inline; margin-left: 10px; border-radius: 2px; padding: 4px 8px; cursor: pointer; } .lang.active { background-color: #3877FF; } #game-title { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -25%) translateY(-200px); opacity: 1; transition: opacity .5s; } #game-play, #game-reset { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 300px; height: 75px; font-size: 30px; box-shadow: none; color: #ffff !important; background: #3877FF !important; border: 0 !important; border-radius: 0 !important; transition: box-shadow .2s, opacity .5s; cursor: pointer; opacity: 1; } #game-reset { display: none; background-color: #FF0D72 !important; transform: translate(-50%, -50%) translateY(85px); opacity: 0; } #game-play:hover, #game-play:active, #game-play:focus { outline: none !important; box-shadow: 3px 4px 0 3px rgba(0, 0, 0, 0.2) !important; } #background { width: 100%; height: 100%; position: absolute; left: 0; top: 0; filter: url(#f2); } #background.blurred { filter: url(#f1); } #canvas-container { height: 936px; width: 761px; position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); } #tetris, #tetris-background { position: absolute; left: 50%; top: 50%; -webkit-transform: translate(-50%, -50%); -moz-transform: translate(-50%, -50%); -ms-transform: translate(-50%, -50%); -o-transform: translate(-50%, -50%); transform: translate(-50%, -50%); border: solid .2em #fff; z-index: 1; background: transparent; } #tetris-background { border: none; z-index: 0; } #tetris-hold { position: absolute; left: 50%; border: solid .2em #fff; } #tetris-upcoming { position: absolute; right: 50%; border: solid .2em #fff; } #game-stats { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%) translateX(-30vw); text-align: right; } #score { font-weight: 900; } #time:before, #score:before { content: attr(data-prefix); } #controls { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%) translateX(30vw); font-size: 20px; max-width: 20vw; } #footer { position: absolute; bottom: 10px; width: 95%; left: 2.5%; right: 2.5%; font-size: 12px; color: rgba(255, 255, 255, .5); } #version-author { display: inline-block; } #corner-buttons { display: inline-block; position: absolute; right: 0; } #corner-buttons > a { text-decoration: none; display: inline-block; left: 10px; color: rgba(255, 255, 255, .5); -webkit-transition: color .2s; -moz-transition: color .2s; -ms-transition: color .2s; -o-transition: color .2s; transition: color .2s; } #corner-buttons > a:hover, #corner-buttons > a:active { color: rgba(255, 255, 255, 1); } .bar, .bar::before, .bar::after { -webkit-transition: 0.2s background linear 0.1s, 0.2s top linear 0.2s, 0.2s -webkit-transform linear; transition: 0.2s background linear 0.1s, 0.2s top linear 0.2s, 0.2s -webkit-transform linear; transition: 0.2s background linear 0.1s, 0.2s top linear 0.2s, 0.2s transform linear; transition: 0.2s background linear 0.1s, 0.2s top linear 0.2s, 0.2s transform linear, 0.2s -webkit-transform linear; position: absolute; background: #fff; margin: auto; width: 100%; height: 0.3rem; content: ''; top: 50%; left: 0; } .bar { margin-top: -0.2rem; } .bar::before { top: -1.2rem; } .bar::after { top: 1.2rem; } .bar::before, .bar::after { -webkit-transform: rotate(0deg); transform: rotate(0deg); } .active .bar { background: 0; } .active .bar::before { -webkit-transform: rotate(45deg); transform: rotate(45deg); } .active .bar::after { -webkit-transform: rotate(-45deg); transform: rotate(-45deg); } .active .bar::before, .active .bar::after { top: 0; } .active .bar, .active .bar::before, .active .bar::after { -webkit-transition: 0.2s background linear 0.1s, 0.2s top linear, 0.2s -webkit-transform linear 0.2s; transition: 0.2s background linear 0.1s, 0.2s top linear, 0.2s -webkit-transform linear 0.2s; transition: 0.2s background linear 0.1s, 0.2s top linear, 0.2s transform linear 0.2s; transition: 0.2s background linear 0.1s, 0.2s top linear, 0.2s transform linear 0.2s, 0.2s -webkit-transform linear 0.2s; } @media (max-width: 1400px) { #tetris, #tetris-background { height: 75%; } #game-stats { top: 10px; left: 50%; transform: translateX(-50%); } #game-stats > div { display: inline; } #time { margin-right: 50px; } #controls { top: initial; bottom: 10px; left: 50%; transform: translateX(-50%); height: 10%; overflow: auto; } #control-text { height: 100%; } #language-selector { font-size: 20px; } } @media (max-width: 840px) { #game-stats { font-size: 20px; text-align: center; } #game-stats > div { margin-right: 0; display: block; } #control-text { font-size: 14px; } } /* Radio Buttons */ .radio { margin: 0.5rem; } .radio input[type="radio"] { position: absolute; opacity: 0; } .radio input[type="radio"] + .radio-label:before { content: ''; background: #f4f4f4; border-radius: 100%; border: 1px solid #b4b4b4; display: inline-block; width: 1.4em; height: 1.4em; position: relative; top: -0.2em; margin-right: 1em; vertical-align: top; cursor: pointer; text-align: center; -webkit-transition: all 250ms ease; transition: all 250ms ease; } .radio input[type="radio"]:checked + .radio-label:before { background-color: #3197EE; -webkit-box-shadow: inset 0 0 0 4px #f4f4f4; box-shadow: inset 0 0 0 4px #f4f4f4; } .radio input[type="radio"]:focus + .radio-label:before { outline: none; border-color: #3197EE; } .radio input[type="radio"]:disabled + .radio-label:before { -webkit-box-shadow: inset 0 0 0 4px #f4f4f4; box-shadow: inset 0 0 0 4px #f4f4f4; border-color: #b4b4b4; background: #b4b4b4; } .radio input[type="radio"] + .radio-label:empty:before { margin-right: 0; }