Make links box as flex box

This commit is contained in:
ChronosX88 2022-01-09 18:28:10 +03:00
parent 8d3984c9e6
commit 37ea2122b0
Signed by: ChronosXYZ
GPG Key ID: 085A69A82C8C511A
2 changed files with 102 additions and 83 deletions

View File

@ -2,7 +2,7 @@
<html> <html>
<head> <head>
<title>Amalthea</title> <title>Amalthea</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0"> <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0">
<meta name="color-scheme" content="dark"> <meta name="color-scheme" content="dark">
<meta name="robots" content="none noarchive"> <meta name="robots" content="none noarchive">
<link rel="shortcut icon" href="server-icon.png" type="image/x-icon"> <link rel="shortcut icon" href="server-icon.png" type="image/x-icon">
@ -13,18 +13,12 @@
<div class="content"> <div class="content">
<h1 class="address">mc.amalthea.one</h1> <h1 class="address">mc.amalthea.one</h1>
<div class="address-desc">Java + Bedrock</div> <div class="address-desc">Java + Bedrock</div>
<table class="links"> <div class="links">
<tbody> <a href="https://t.me/+1brxlMQR7kk5YzQy">Telegram chat</a>
<tr> <a href="https://discord.gg/9adwzUt76M">Discord</a>
<td><a href="https://t.me/+1brxlMQR7kk5YzQy">Telegram chat</a></td> <a href="#">Support us</a>
<td style="text-align: right;"><a href="https://discord.gg/9adwzUt76M">Discord</a></td> <a href="#">Server map</a>
</tr> </div>
<tr>
<td><a href="#">Support us</a></td>
<td style="text-align: right;"><a href="#">Server map</a></td>
</tr>
</tbody>
</table>
</div> </div>
</div> </div>
</body> </body>

165
style.css
View File

@ -1,70 +1,95 @@
@font-face { @font-face {
font-family: "PRegular"; font-family: "PRegular";
src: url("8bitOperatorPlus8-Regular.ttf"); src: url("8bitOperatorPlus8-Regular.ttf");
} }
@font-face { @font-face {
font-family: "PBold"; font-family: "PBold";
src: url("8bitOperatorPlus8-Bold.ttf"); /* see /license.txt */ src: url("8bitOperatorPlus8-Bold.ttf"); /* see /license.txt */
} }
::selection { ::selection {
background-color: beige; background-color: beige;
color: black; color: black;
} }
body {
padding: 0px; body {
margin: 0px; display: flex;
display: table; align-items: center;
position: absolute; justify-content: center;
top: 0; left: 0;
left: 0; top: 0;
height: 100%; height: 100%;
width: 100%; width: 100%;
background-color: black; position: fixed;
color: beige; background-color: black;
text-shadow: 1px 1px black; color: beige;
font-family: PRegular; text-shadow: 1px 1px black;
} font-family: PRegular;
td { }
padding: 10px;
} @media only screen and (max-width: 768px) {
a { .content {
color: beige; width: 100vw;
}
a:hover { }
background-color: beige;
color: midnightblue; .address {
} font-size: 160%;
a:focus-visible {
background-color: beige; }
color: midnightblue;
outline: none; .address-desc {
} font-size: 140%;
.card { }
display: table-cell;
vertical-align: middle; .links {
} margin-top: 10px;
.content { font-size: 140%;
padding: 20px 50px; }
margin-left: auto; }
margin-right: auto;
width: 400px; a {
background-color: midnightblue; color: beige;
border: 5px solid beige; }
} a:hover {
.address { background-color: beige;
text-align: center; color: midnightblue;
margin: 0px; }
text-shadow: 3px 3px black; a:focus-visible {
font-family: PBold; background-color: beige;
} color: midnightblue;
.address-desc { outline: none;
text-align: center; }
text-shadow: 2px 2px black;
font-size: 24px; .content {
} padding: 20px 50px;
.links { margin-left: auto;
width: 100%; margin-right: auto;
margin: auto; width: 400px;
margin-top: 10px; background-color: midnightblue;
font-size: 24px; border: 5px solid beige;
} }
.address {
text-align: center;
margin: 0px;
text-shadow: 3px 3px black;
font-family: PBold;
}
.address-desc {
text-align: center;
text-shadow: 2px 2px black;
font-size: 24px;
}
.links {
width: 100%;
margin: auto;
display: flex;
flex-wrap: wrap;
margin-top: 10px;
margin-bottom: 10px;
font-size: 24px;
justify-content: space-between;
}
.links > a {
margin: 10px;
}