From b1fd0cdeff287e4cf0ec180ff9fee804cb2c8b8d Mon Sep 17 00:00:00 2001 From: Arda Serdar Pektezol <1669855+pektezol@users.noreply.github.com> Date: Wed, 22 Oct 2025 01:52:05 +0400 Subject: feat/frontend: add general mobile support (#275) --- frontend/src/css/About.css | 23 +- frontend/src/css/Dialog.css | 37 +- frontend/src/css/Games.css | 48 +++ frontend/src/css/Login.css | 10 +- frontend/src/css/Maplist.css | 47 ++- frontend/src/css/Maps.css | 650 +++++++++++++++++++++++++---------- frontend/src/css/ModMenu.css | 148 ++++++-- frontend/src/css/Profile.css | 229 +++++++++--- frontend/src/css/Rankings.css | 33 +- frontend/src/css/Rules.css | 6 + frontend/src/css/Sidebar.css | 380 ++++++++++++++++---- frontend/src/css/UploadRunDialog.css | 124 +++++-- 12 files changed, 1346 insertions(+), 389 deletions(-) (limited to 'frontend/src/css') diff --git a/frontend/src/css/About.css b/frontend/src/css/About.css index d4fdf07..c29e0bc 100644 --- a/frontend/src/css/About.css +++ b/frontend/src/css/About.css @@ -3,7 +3,7 @@ overflow-x: hidden; position: relative; - width: calc(100% - 380px); + width: calc(100% - 380px); height: 100vh; left: 350px; @@ -16,10 +16,27 @@ } h1 { - font-size: 80px; + font-size: 80px; } h2 { - font-size: 60px; + font-size: 60px; } +@media screen and (max-width: 768px) { + #about { + width: 100%; + left: 0; + padding: 70px 20px 20px 20px; + height: calc(100vh - 60px); + font-size: 18px; + } + + h1 { + font-size: 48px; + } + + h2 { + font-size: 36px; + } +} \ No newline at end of file diff --git a/frontend/src/css/Dialog.css b/frontend/src/css/Dialog.css index fc557d2..d2f0528 100644 --- a/frontend/src/css/Dialog.css +++ b/frontend/src/css/Dialog.css @@ -1,6 +1,6 @@ .dimmer { position: fixed; - /* WHAT A SCHTUPID ACTION */ + /* WHAT A SCHTUPID ACTION */ width: 200%; height: 100%; background-color: rgba(0, 0, 0, 0.5); @@ -8,12 +8,12 @@ } .dialog-container { - position: absolute; - top: 0px; - left: -350px; - width: 100%; - height: 100%; - z-index: 10000; + position: absolute; + top: 0px; + left: -350px; + width: 100%; + height: 100%; + z-index: 10000; } .dialog { @@ -40,7 +40,8 @@ padding: 8px; } -.dialog-header, .dialog-btns-container { +.dialog-header, +.dialog-btns-container { background-color: #202232; } @@ -93,3 +94,23 @@ opacity: 1; } } + +@media screen and (max-width: 768px) { + .dialog-container { + left: 0; + } + + .dialog { + min-width: 300px; + max-width: 90vw; + } + + .dialog-header { + font-size: 20px; + } + + .dialog-description { + font-size: 16px; + padding: 12px 8px; + } +} \ No newline at end of file diff --git a/frontend/src/css/Games.css b/frontend/src/css/Games.css index ec57a71..2fe5efa 100644 --- a/frontend/src/css/Games.css +++ b/frontend/src/css/Games.css @@ -96,4 +96,52 @@ span>b { .games-page-item-body-item-num { font-size: 50px; font-family: BarlowCondensed-Bold; +} + +@media screen and (max-width: 768px) { + .games-page { + left: 0; + width: 100%; + padding-top: 60px; + } + + .games-page-item-content { + left: 20px; + width: calc(100% - 40px); + } + + .games-page-header { + margin-top: 20px; + margin-left: 20px; + } + + span>b { + font-size: 40px; + } + + .games-page-item { + height: auto; + min-height: 200px; + } + + .games-page-item-header { + height: 120px; + } + + .games-page-item-body { + height: auto; + padding: 10px 0; + } + + .games-page-item-body-item { + height: 80px; + } + + .games-page-item-body-item-title { + font-size: 20px; + } + + .games-page-item-body-item-num { + font-size: 36px; + } } \ No newline at end of file diff --git a/frontend/src/css/Login.css b/frontend/src/css/Login.css index aa75f98..bb55237 100644 --- a/frontend/src/css/Login.css +++ b/frontend/src/css/Login.css @@ -2,11 +2,13 @@ span>img { scale: 1.1; padding: 4px 0 0 8px; } -.login>button>span{ + +.login>button>span { max-width: 22ch; overflow: hidden; } -.login>button:nth-child(2){ + +.login>button:nth-child(2) { position: relative; left: 210px; width: 50px !important; @@ -16,9 +18,9 @@ span>img { /* transition: opacity .1s; */ } -.login{ +.login { display: grid; - grid-template-columns: 50px auto 200px ; + grid-template-columns: 50px auto 200px; } button:disabled { diff --git a/frontend/src/css/Maplist.css b/frontend/src/css/Maplist.css index 9880a27..65c3a28 100644 --- a/frontend/src/css/Maplist.css +++ b/frontend/src/css/Maplist.css @@ -72,7 +72,8 @@ h3 { width: 100%; } -.game-cat-button:hover, .game-cat-button.selected { +.game-cat-button:hover, +.game-cat-button.selected { background-color: #202232; } @@ -196,3 +197,47 @@ h3 { opacity: 1; } } + +@media screen and (max-width: 768px) { + h1 { + font-size: 36px; + text-align: center; + } + + h3 { + font-size: 28px; + margin: 0px 5px; + } + + .portal-count { + font-size: 60px; + } + + .blur.map span:nth-child(1) { + font-size: 40px; + } + + .game-header-categories { + flex-direction: column; + height: auto; + } + + .game-cat-button { + font-size: 18px; + padding: 10px 0; + } + + .maplist { + grid-template-columns: repeat(1, 1fr); + grid-gap: 20px; + margin: 20px 0px; + } + + .maplist-entry span { + font-size: 16px; + } + + .map-entry-image { + height: 150px; + } +} \ No newline at end of file diff --git a/frontend/src/css/Maps.css b/frontend/src/css/Maps.css index 5f28055..4c90c6f 100644 --- a/frontend/src/css/Maps.css +++ b/frontend/src/css/Maps.css @@ -1,16 +1,18 @@ -#background-image{ +#background-image { z-index: -1; position: absolute; opacity: 10%; height: 50%; width: 100% } -#background-image>img{ + +#background-image>img { object-fit: cover; width: 100%; height: 100%; } -#background-image::before{ + +#background-image::before { content: ""; position: absolute; width: 100%; @@ -20,12 +22,12 @@ /* Section 1: map name*/ -#section1{ +#section1 { margin: 20px 0 0 0; cursor: default; } -.nav-button{ +.nav-button { height: 40px; background-color: #2b2e46; @@ -35,49 +37,67 @@ border: none; transition: background-color .1s; } + /* #section1>div>.nav-button:nth-child(1){border-radius: 0px;}:nth-child(1){border-radius: 20px 0 0 20px;} #section1>div>.nav-button:nth-child(2){border-radius: 0 20px 20px 0;margin-left: 2px;} */ -.nav-button>span{padding: 0 8px 0 8px;} -.nav-button:hover{background-color: #202232;cursor: pointer;} +.nav-button>span { + padding: 0 8px 0 8px; +} + +.nav-button:hover { + background-color: #202232; + cursor: pointer; +} /* Section 2: navbar */ -#section2{ +#section2 { margin: 40px 0 0 0; - display: grid; gap: 2px; + display: grid; + gap: 2px; grid-template-columns: 1fr 1fr 1fr; } -#section2>.nav-button{ +#section2>.nav-button { height: 50px; font-size: 22px; display: flex; justify-content: center; place-items: center; } -#section2>.nav-button>img{scale: 1.2;} -#section2>.nav-button:nth-child(1){border-radius: 30px 0 0 30px;} -#section2>.nav-button:nth-child(3){border-radius: 0 30px 30px 0;} + +#section2>.nav-button>img { + scale: 1.2; +} + +#section2>.nav-button:nth-child(1) { + border-radius: 30px 0 0 30px; +} + +#section2>.nav-button:nth-child(3) { + border-radius: 0 30px 30px 0; +} /* Section 3: category + history */ -#section3{ +#section3 { margin: 40px 0 0 0; - display: grid; + display: grid; grid-template-columns: 1fr 1fr; gap: 20px; } -#category{ +#category { display: grid; height: 350px; border-radius: 24px; overflow: hidden; - + } -#category>p{ + +#category>p { margin-bottom: 20px; text-align: center; font-size: 50px; @@ -85,9 +105,13 @@ color: white; } -p>span.portal-count{font-weight: bold;font-size: 100px;vertical-align: -15%;} +p>span.portal-count { + font-weight: bold; + font-size: 100px; + vertical-align: -15%; +} -#category-image{ +#category-image { transform: translate(-20%, -15%); z-index: -1; overflow: hidden; @@ -96,75 +120,103 @@ p>span.portal-count{font-weight: bold;font-size: 100px;vertical-align: -15%;} filter: blur(4px) contrast(80%) brightness(80%); } -#category>span{ +#category>span { margin-top: 70px; background-color: #202232; display: grid; gap: 2px; } -#category>span>button{ + +#category>span>button { font-family: inherit; font-size: 18px; border: none; height: 40px; color: inherit; - + cursor: pointer; transition: background-color .1s; } -#history>div>hr{border: 1px solid #2b2e46;margin: 8px 20px 0px 20px;} -#history{ +#history>div>hr { + border: 1px solid #2b2e46; + margin: 8px 20px 0px 20px; +} + +#history { min-width: 560px; background-color: #202232; border-radius: 24px; } -#records{overflow-y: auto; height: 256px;} -#records::-webkit-scrollbar{display: none;} +#records { + overflow-y: auto; + height: 256px; +} + +#records::-webkit-scrollbar { + display: none; +} -.record-top, .record{ +.record-top, +.record { font-size: 18px; display: grid; text-align: center; grid-template-columns: 1fr 1fr 1fr; } -.record-top{font-weight: bold;margin: 20px 20px 0 20px;cursor: default;} -.record{ + +.record-top { + font-weight: bold; + margin: 20px 20px 0 20px; + cursor: default; +} + +.record { margin: 10px 20px 10px 20px; - height: 44px; width: calc(100% - 40px); - + height: 44px; + width: calc(100% - 40px); + color: inherit; border-radius: 40px; place-items: center; - + border: 0; cursor: pointer; transition: background-color .1s; } -#history>span{ + +#history>span { border-top: #202232 solid 2px; display: grid; grid-template-columns: 1fr 1fr; } -#history>span>button{ - width: 100%; height: 40px; + +#history>span>button { + width: 100%; + height: 40px; font-family: inherit; font-size: 18px; border: none; color: inherit; - + cursor: pointer; transition: background-color .1s; } -#history>span>button:nth-child(1){border-radius: 0 0 0 24px;} -#history>span>button:nth-child(2){border-radius: 0 0 24px 0;} -#graph{ +#history>span>button:nth-child(1) { + border-radius: 0 0 0 24px; +} + +#history>span>button:nth-child(2) { + border-radius: 0 0 24px 0; +} + +#graph { display: grid; grid-template-columns: 20px 1fr; grid-template-rows: 1fr 20px; @@ -173,45 +225,53 @@ p>span.portal-count{font-weight: bold;font-size: 100px;vertical-align: -15%;} margin: 10px 10px 5px 10px; overflow: hidden; } -#graph>div:nth-child(1){ /* numbers */ - width: 20px; + +#graph>div:nth-child(1) { + /* numbers */ + width: 20px; display: grid; place-items: center; /* background-color: blue; */ } -#graph>div:nth-child(1)>span{ + +#graph>div:nth-child(1)>span { font-size: 12px; line-height: 0; } -#graph>div:nth-child(2){ /* big graph */ +#graph>div:nth-child(2) { + /* big graph */ position: relative; display: grid; } -#graph>div:nth-child(2)>tr{ + +#graph>div:nth-child(2)>tr { display: flex; align-items: center; grid-template-columns: repeat(auto-fit, minmax(1px, 1fr)); } -#graph>div:nth-child(2)>tr>td.graph_hor{ - width: 100%; + +#graph>div:nth-child(2)>tr>td.graph_hor { + width: 100%; height: 0; - padding: 0; - + padding: 0; + outline: 1px solid red; } -#graph>div:nth-child(2)>tr>td.graph_ver{ - width: 0; + +#graph>div:nth-child(2)>tr>td.graph_ver { + width: 0; height: 100%; padding: 0; - + outline: 1px solid blue; transform: translateY(50%); z-index: 0; overflow: hidden; } -#graph>div:nth-child(3){ /* dates */ +#graph>div:nth-child(3) { + /* dates */ padding-right: 20px; z-index: 1; height: 16px; @@ -223,7 +283,7 @@ p>span.portal-count{font-weight: bold;font-size: 100px;vertical-align: -15%;} grid-template-columns: repeat(auto-fit, minmax(1px, 1fr)); } -.graph-button{ +.graph-button { position: absolute; padding: 0; border: 5px solid white; @@ -232,12 +292,15 @@ p>span.portal-count{font-weight: bold;font-size: 100px;vertical-align: -15%;} transform: translateX(-50%); } -#history>div>h5{text-align: center;height: 197px;} +#history>div>h5 { + text-align: center; + height: 197px; +} /* Section 4: Difficulty + count */ -#section4{ +#section4 { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; @@ -245,9 +308,9 @@ p>span.portal-count{font-weight: bold;font-size: 100px;vertical-align: -15%;} } #difficulty, -#count { +#count { background-color: #202232; - min-width: 250px; + min-width: 250px; text-align: center; cursor: default; @@ -255,69 +318,86 @@ p>span.portal-count{font-weight: bold;font-size: 100px;vertical-align: -15%;} display: grid; grid-template-rows: 20px 40px 40px; } + #difficulty>span:nth-child(1), -#count>span:nth-child(1){ - padding-top:10px; +#count>span:nth-child(1) { + padding-top: 10px; font-size: 18px; - color:#cdcfdf + color: #cdcfdf } -#difficulty>span:nth-child(2){ + +#difficulty>span:nth-child(2) { font-size: 40px; } -#difficulty>div{ + +#difficulty>div { display: grid; grid-template-columns: 1fr 1fr 1fr 1fr 1fr; padding: 0 calc(50% - 125px) 0 calc(50% - 125px); place-items: center; } -.difficulty-rating{ +.difficulty-rating { border-radius: 24px; - width: 40px; height: 3px; + width: 40px; + height: 3px; background-color: #2b2e46; } -#count>div{ - padding-top:10px; +#count>div { + padding-top: 10px; font-size: 50px; - color:white + color: white } /* Section 5: route desc + video */ -#section5{ +#section5 { margin: 40px 0 20px 0; width: 100%; } -#description{ - width: 100%; height: auto; +#description { + width: 100%; + height: auto; min-height: 342px; } -#description>iframe{ +#description>iframe { margin: 20px; - float:right; + float: right; border: 0; border-radius: 24px; - width: 608px; height: 342px; + width: 608px; + height: 342px; +} + +#description>h3 { + margin: 0 0 10px 0; + color: white; } -#description>h3{margin: 0 0 10px 0; color: white;} -#description-text{ +#description-text { display: block; font-size: 21px; word-wrap: break-word; text-align: justify; } -#description-text>b{font-size: inherit;} -#description-text>a{font-size: inherit;color: #3c91e6;} + +#description-text>b { + font-size: inherit; +} + +#description-text>a { + font-size: inherit; + color: #3c91e6; +} /* Section 6: leaderboards */ -#section6{ +#section6 { margin: 40px 0 20px 0; min-height: 600px; background-color: #202232; @@ -328,39 +408,46 @@ p>span.portal-count{font-weight: bold;font-size: 100px;vertical-align: -15%;} } -#section6>hr{border: 1px solid #2b2e46;margin: 8px 20px 0px 20px;} -#leaderboard-top{ +#section6>hr { + border: 1px solid #2b2e46; + margin: 8px 20px 0px 20px; +} + +#leaderboard-top { display: grid; font-size: 20px; height: 34px; padding-left: 60px; margin: 0 20px 0 20px; } -#leaderboard-top>span{ - + +#leaderboard-top>span { + display: flex; place-items: flex-end; } -#runner{ +#runner { display: grid; grid-template-columns: 50% 50%; align-items: end; } -#page-number{ +#page-number { display: flex; width: auto; flex-direction: row-reverse; } -#page-number>div{ -width: 100px; -place-items: center; -display: grid; -grid-template-columns: 1fr 1fr 1fr; -text-align: center; + +#page-number>div { + width: 100px; + place-items: center; + display: grid; + grid-template-columns: 1fr 1fr 1fr; + text-align: center; } -#page-number>div>button{ + +#page-number>div>button { width: 30px; height: 30px; background-color: #202232; @@ -369,9 +456,10 @@ text-align: center; cursor: pointer; } -.leaderboard-record{ +.leaderboard-record { margin: 10px 20px 0px 20px; - height: 44px; width: calc(100% - 40px); + height: 44px; + width: calc(100% - 40px); width: auto; color: inherit; @@ -380,7 +468,7 @@ text-align: center; padding: 0 0 0 60px; font-size: 20px; font-family: inherit; - + grid-template-columns: 3% 4.5% 40% 4% 3.5% 15% 15% 15%; display: grid; @@ -389,33 +477,44 @@ text-align: center; background-color: #2b2e46; } -.leaderboard-record>span:nth-child(1){display: grid;} -.leaderboard-record>span:nth-child(4){display: grid;} -.leaderboard-record>span:last-child{flex-direction: row-reverse;} -.leaderboard-record>span{ +.leaderboard-record>span:nth-child(1) { + display: grid; +} + +.leaderboard-record>span:nth-child(4) { + display: grid; +} + +.leaderboard-record>span:last-child { + flex-direction: row-reverse; +} + +.leaderboard-record>span { display: flex; place-items: center; height: 44px; } -.leaderboard-record>div>a>span>img{ +.leaderboard-record>div>a>span>img { height: 36px; border-radius: 50px; padding: 0; scale: .95; } -.leaderboard-record>div{ + +.leaderboard-record>div { display: grid; grid-template-columns: 50% 50%; place-items: left; } -.leaderboard-record>div>a>span{ + +.leaderboard-record>div>a>span { display: flex; place-items: center; height: 44px; } -.leaderboard-record>span>button{ +.leaderboard-record>span>button { background-color: #0000; border: 0; cursor: pointer; @@ -425,9 +524,9 @@ text-align: center; .hover-popup { position: relative; display: inline-block; - } - - .hover-popup::after { +} + +.hover-popup::after { content: attr(popup-text); position: absolute; /* top: 0%; */ @@ -441,36 +540,42 @@ text-align: center; opacity: 0; color: #cdcfdf; /* transition: visibility 0s, opacity 0.3s ease; */ - } +} - .hover-popup:hover { +.hover-popup:hover { color: transparent; - } - - .hover-popup:hover::after { +} + +.hover-popup:hover::after { visibility: visible; opacity: 1; - } +} -.leaderboard-record:last-child{margin: 10px 20px 10px 20px;} +.leaderboard-record:last-child { + margin: 10px 20px 10px 20px; +} -#section7{ +#section7 { margin: 40px 0 20px 0; background-color: #202232; border-radius: 24px; padding: 10px; } -#discussion-search{ +#discussion-search { height: 46px; width: 100%; display: grid; grid-template-columns: 1fr 100px; margin: 0 0 20px 0; } -#discussion-search>input::placeholder{color: #aaa;} -#discussion-search>input{ + +#discussion-search>input::placeholder { + color: #aaa; +} + +#discussion-search>input { background-color: #2b2e46; font-size: 20px; padding-left: 10px; @@ -479,15 +584,19 @@ text-align: center; border-radius: 16px 0 0 16px; font-family: inherit; } -#discussion-search>div>button:hover{filter: brightness(75%);} -#discussion-search>div>button{ + +#discussion-search>div>button:hover { + filter: brightness(75%); +} + +#discussion-search>div>button { padding: 7px 16px; margin: 8px 0; border: 0; font-size: 16px; border-radius: 24px; display: block; - background-color:#3c91e6; + background-color: #3c91e6; font-family: inherit; font-weight: bold; cursor: pointer; @@ -495,30 +604,46 @@ text-align: center; transition: filter .2s; } -#discussion-search>div{ + +#discussion-search>div { background-color: #2b2e46; border-radius: 0 16px 16px 0; } -#discussion-post>button:nth-child(1)>span>b{font-size: 18px;color:#cdcfdf;font-weight: lighter;} -#discussion-post>button:nth-child(1){ + +#discussion-post>button:nth-child(1)>span>b { + font-size: 18px; + color: #cdcfdf; + font-weight: lighter; +} + +#discussion-post>button:nth-child(1) { background-color: #2b2e46; display: grid; grid-template-columns: minmax(0, 1fr) 150px; border-radius: 16px; - padding: 16px 12px; - margin: 8px 0 0 0; + padding: 16px 12px; + margin: 8px 0 0 0; border: 0; - width: 100%; height: 100px; + width: 100%; + height: 100px; text-align: start; white-space: nowrap; color: #cdcfdf; cursor: pointer; overflow: hidden; } -#discussion-post>button:nth-child(1)>span:nth-child(1){font-size: 32px;} -#discussion-post>button:nth-child(1)>span:nth-child(3){color: #aaa; font-size: 18px;} -#discussion-post>button:nth-child(1)>span:nth-child(4){ + +#discussion-post>button:nth-child(1)>span:nth-child(1) { + font-size: 32px; +} + +#discussion-post>button:nth-child(1)>span:nth-child(3) { + color: #aaa; + font-size: 18px; +} + +#discussion-post>button:nth-child(1)>span:nth-child(4) { opacity: .7; height: 40px; display: flex; @@ -526,15 +651,21 @@ text-align: center; justify-content: end; } -#discussion-post{height: 100px;} -#discussion-post>button>button:hover{filter: brightness(75%); } -#discussion-post>button>button{ +#discussion-post { + height: 100px; +} + +#discussion-post>button>button:hover { + filter: brightness(75%); +} + +#discussion-post>button>button { padding: 7px 16px; - + border: 0; font-size: 16px; border-radius: 24px; - background-color:#e52d04; + background-color: #e52d04; font-family: BarlowSemiCondensed-Regular; font-weight: bold; cursor: pointer; @@ -544,20 +675,27 @@ text-align: center; } -#discussion-create>div{ +#discussion-create>div { display: grid; text-align: start; -} -#discussion-create{ +} + +#discussion-create { display: grid; grid-template-columns: 1fr 40px; height: auto; word-wrap: break-word; } -#discussion-create>span{padding-left: 20px;} -#discussion-create>div>input::placeholder{color: #aaa;} -#discussion-create>div>input{ +#discussion-create>span { + padding-left: 20px; +} + +#discussion-create>div>input::placeholder { + color: #aaa; +} + +#discussion-create>div>input { background-color: #2b2e46; font-size: 20px; padding-left: 10px; @@ -567,17 +705,23 @@ text-align: center; border: 0; font-family: inherit; } -#discussion-create>div>input:nth-child(2){font-size: 16px;} -#discussion-create-button:hover{filter: brightness(75%);} -#discussion-create-button{ +#discussion-create>div>input:nth-child(2) { + font-size: 16px; +} + +#discussion-create-button:hover { + filter: brightness(75%); +} + +#discussion-create-button { padding: 7px 16px; margin: 8px 0 0 0; border: 0; font-size: 16px; border-radius: 24px; - - background-color:#3c91e6; + + background-color: #3c91e6; font-family: inherit; font-weight: bold; cursor: pointer; @@ -590,7 +734,7 @@ text-align: center; } -#discussion-thread>div:nth-child(1){ +#discussion-thread>div:nth-child(1) { display: grid; grid-template-columns: 1fr 40px; height: auto; @@ -599,10 +743,10 @@ text-align: center; } #discussion-create>button:nth-child(2), -#discussion-thread>div>button{ +#discussion-thread>div>button { height: 40px; - float:inline-end; - color:#cdcfdf; + float: inline-end; + color: #cdcfdf; background-color: #0000; border: 0; font-size: 38px; @@ -610,32 +754,41 @@ text-align: center; } -#discussion-thread>div:nth-child(2)>a>img{ - width: 60px; height: 60px; +#discussion-thread>div:nth-child(2)>a>img { + width: 60px; + height: 60px; border-radius: 100px; margin: 20px 0 0 0; } -#discussion-thread>div:nth-child(2)>div{ + +#discussion-thread>div:nth-child(2)>div { height: max-content; padding: 20px 0 0 10px; display: inline-grid; - grid-template-columns: min-content 1fr ; + grid-template-columns: min-content 1fr; overflow: hidden; - + } -#discussion-thread>div:nth-child(2)>div>span:nth-child(1){font-weight: bold;height: 30px;} -#discussion-thread>div:nth-child(2)>div>span:nth-child(2){ + +#discussion-thread>div:nth-child(2)>div>span:nth-child(1) { + font-weight: bold; + height: 30px; +} + +#discussion-thread>div:nth-child(2)>div>span:nth-child(2) { opacity: 0.6; height: 30px; font-size: 80%; padding-left: 10px; } -#discussion-thread>div:nth-child(2)>div>span:nth-child(3){ + +#discussion-thread>div:nth-child(2)>div>span:nth-child(3) { grid-column: 1 / span 2; height: max-content; word-wrap: break-word; } -#discussion-thread>div:nth-child(2){ + +#discussion-thread>div:nth-child(2) { display: grid; grid-template-columns: 60px 1fr; font-size: 20px; @@ -644,15 +797,19 @@ text-align: center; } -#discussion-send{ +#discussion-send { height: 48px; width: 100%; - display: grid; + display: grid; grid-template-columns: 1fr 80px; margin: 10px 0 0 0; } -#discussion-send>input::placeholder{color: #aaa;} -#discussion-send>input{ + +#discussion-send>input::placeholder { + color: #aaa; +} + +#discussion-send>input { background-color: #2b2e46; padding-left: 10px; color: white; @@ -661,20 +818,25 @@ text-align: center; border-radius: 16px 0 0 16px; font-family: inherit; } -#discussion-send>div{ + +#discussion-send>div { background-color: #2b2e46; border-radius: 0 16px 16px 0; } -#discussion-send>div>button:hover{ filter: brightness(75%);} -#discussion-send>div>button{ + +#discussion-send>div>button:hover { + filter: brightness(75%); +} + +#discussion-send>div>button { padding: 7px 20px; margin: 8px 0; font-size: 16px; border: 0; border-radius: 24px; display: block; - background-color:#3c91e6; + background-color: #3c91e6; font-family: inherit; font-weight: bold; cursor: pointer; @@ -685,42 +847,158 @@ text-align: center; -.triangle{ +.triangle { display: inline-block; - width: 8px; height: 0; - border-top: 7px solid transparent; - border-right: 8px solid #cdcfdf; - border-bottom: 7px solid transparent; + width: 8px; + height: 0; + border-top: 7px solid transparent; + border-right: 8px solid #cdcfdf; + border-bottom: 7px solid transparent; } - /* such responsive, very mobile */ @media screen and (max-width: 1480px) { - #section3.summary1{grid-template-columns: auto;} - #category{min-width: 608px;} - #history{min-width: 608px;} - #description{min-width: 608px;} - #section4.summary1{min-width: 588px;} - - #description>iframe{ + #section3.summary1 { + grid-template-columns: auto; + } + + #category { + min-width: 608px; + } + + #history { + min-width: 608px; + } + + #description { + min-width: 608px; + } + + #section4.summary1 { + min-width: 588px; + } + + #description>iframe { padding: 0 0 0 calc(50% - 304px); - float:none; + float: none; justify-content: center; align-items: center; } - #section1.summary1{ + #section1.summary1 { grid-template-columns: auto; place-items: center; text-align: center; - + } - #section2.summary1{ + #section2.summary1 { grid-template-columns: auto; width: 450px; margin: 40px auto 0 auto; } - #section2.summary1>.nav-button:nth-child(1){border-radius: 30px 30px 0 0;} - #section2.summary1>.nav-button:nth-child(2){border-radius: 0;} - #section2.summary1>.nav-button:nth-child(3){border-radius: 0 0 30px 30px;} + + #section2.summary1>.nav-button:nth-child(1) { + border-radius: 30px 30px 0 0; + } + + #section2.summary1>.nav-button:nth-child(2) { + border-radius: 0; + } + + #section2.summary1>.nav-button:nth-child(3) { + border-radius: 0 0 30px 30px; + } +} + +@media screen and (max-width: 768px) { + #section1 { + margin: 20px 0 0 0; + } + + #section2 { + grid-template-columns: 1fr; + gap: 0; + } + + #section2>.nav-button { + border-radius: 0; + font-size: 18px; + height: 45px; + } + + #section2>.nav-button:nth-child(1) { + border-radius: 20px 20px 0 0; + } + + #section2>.nav-button:nth-child(3) { + border-radius: 0 0 20px 20px; + } + + #section3 { + grid-template-columns: 1fr; + gap: 20px; + } + + #history { + min-width: unset; + width: 100%; + } + + #category { + min-width: unset; + width: 100%; + } + + #section4 { + grid-template-columns: 1fr; + } + + #description>iframe { + width: 100%; + height: 250px; + margin: 20px 0; + padding: 0; + } + + #section5 { + margin: 20px 0; + } + + #description { + min-height: unset; + width: 100%; + } + + #leaderboard-top { + font-size: 14px; + padding-left: 30px; + grid-template-columns: 20% 20% 8% 15% 8% 10% 10% 9%; + } + + .leaderboard-record { + font-size: 14px; + padding-left: 30px; + grid-template-columns: 20% 20% 8% 15% 8% 10% 10% 9%; + } + + .leaderboard-record>div>a>span>img { + height: 28px; + } + + #page-number>div { + width: 80px; + } + + #discussion-search { + grid-template-columns: 1fr 80px; + } + + #discussion-search>div>button { + padding: 7px 10px; + font-size: 14px; + } + + .nav-button { + font-size: 16px; + } } \ No newline at end of file diff --git a/frontend/src/css/ModMenu.css b/frontend/src/css/ModMenu.css index c6d3d8d..f09a4b0 100644 --- a/frontend/src/css/ModMenu.css +++ b/frontend/src/css/ModMenu.css @@ -1,35 +1,39 @@ -div#modview{ +div#modview { position: absolute; left: 50%; z-index: 20; - width: 320px; height: auto; + width: 320px; + height: auto; /* background-color: red; */ transform: translateY(-68%); } -div#modview>div>button{ + +div#modview>div>button { height: 30px; } -div#modview>div:nth-child(1){ +div#modview>div:nth-child(1) { display: grid; grid-template-columns: 50% 50%; } -div#modview>div:nth-child(2){ +div#modview>div:nth-child(2) { display: grid; place-items: center; } -#modview-menu{ +#modview-menu { position: absolute; - left: calc(50% + 160px); top: 130px; + left: calc(50% + 160px); + top: 130px; transform: translateX(-50%); background-color: #2b2e46; - z-index: 2; color: white; + z-index: 2; + color: white; } -#modview-menu-image{ +#modview-menu-image { box-shadow: 0 0 40px 16px black; outline: 8px solid #2b2e46; border-radius: 20px; @@ -37,27 +41,43 @@ div#modview>div:nth-child(2){ display: grid; grid-template-columns: 50% 50%; /* place-items: center; */ - + } -#modview-menu-image>div:nth-child(1){ - height: 400px; width: 500px; + +#modview-menu-image>div:nth-child(1) { + height: 400px; + width: 500px; display: grid; grid-template-rows: 30% 70%; } -#modview-menu-image>div:nth-child(2){ - height: 400px; width: 500px; + +#modview-menu-image>div:nth-child(2) { + height: 400px; + width: 500px; display: grid; grid-template-rows: 20% 10%; } -#modview-menu-image>div>button{width: 300px;margin-left:100px;} -#modview-menu-image>div>img{width: 500px;} -#modview-menu-image>div>button{font-size: 20px;} -#modview-menu-image>div>span>input[type="file"]{font-size: 15px;} +#modview-menu-image>div>button { + width: 300px; + margin-left: 100px; +} + +#modview-menu-image>div>img { + width: 500px; +} + +#modview-menu-image>div>button { + font-size: 20px; +} + +#modview-menu-image>div>span>input[type="file"] { + font-size: 15px; +} #modview-menu-add, -#modview-menu-edit{ +#modview-menu-edit { box-shadow: 0 0 40px 16px black; outline: 8px solid #2b2e46; border-radius: 20px; @@ -67,19 +87,24 @@ div#modview>div:nth-child(2){ } #modview-menu-add>div, -#modview-menu-edit>div{ +#modview-menu-edit>div { display: grid; margin: 20px; width: 200px; font-size: 20px; } -#modview-route-description>textarea{ + +#modview-route-description>textarea { resize: none; height: 160px; width: 1160px; } -#modview-route-showcase>input::placeholder{opacity: .5;} -#modview_block{ + +#modview-route-showcase>input::placeholder { + opacity: .5; +} + +#modview_block { position: absolute; background-color: black; opacity: .3; @@ -89,24 +114,89 @@ div#modview>div:nth-child(2){ z-index: 2; cursor: no-drop; } -#modview-md{ + +#modview-md { box-shadow: 0 0 40px 16px black; background-color: #2b2e46; outline: 8px solid #2b2e46; border-radius: 20px; position: absolute; - padding: 10px; top: 400px; - width: 1180px; height: 300px; + padding: 10px; + top: 400px; + width: 1180px; + height: 300px; overflow-y: auto; word-wrap: break-word; } -#modview-md>span>a{ + +#modview-md>span>a { padding-left: 20px; - color:aqua; + color: aqua; } -#modview-md>p{ + +#modview-md>p { font-family: BarlowSemiCondensed-Regular; color: #cdcfdf; font-size: 21px; +} + +@media screen and (max-width: 768px) { + #modview_block { + left: 0; + width: 100%; + } + + #modview-menu { + left: 50%; + top: 80px; + width: 90vw; + } + + #modview-menu-image { + grid-template-columns: 1fr; + width: 100%; + } + + #modview-menu-image>div:nth-child(1), + #modview-menu-image>div:nth-child(2) { + width: 100%; + height: auto; + } + + #modview-menu-image>div>img { + width: 100%; + max-width: 400px; + } + + #modview-menu-image>div>button { + width: 80%; + margin-left: 10%; + } + + #modview-menu-add, + #modview-menu-edit { + grid-template-columns: 1fr; + width: 90vw; + } + + #modview-menu-add>div, + #modview-menu-edit>div { + width: 90%; + } + + #modview-route-description>textarea { + width: 100%; + max-width: 90vw; + } + + #modview-md { + width: 90vw; + max-width: 600px; + top: 300px; + } + + div#modview { + width: 90vw; + } } \ No newline at end of file diff --git a/frontend/src/css/Profile.css b/frontend/src/css/Profile.css index 0829477..9b5b4ef 100644 --- a/frontend/src/css/Profile.css +++ b/frontend/src/css/Profile.css @@ -1,4 +1,4 @@ -#section1.profile{ +#section1.profile { margin: 20px; background: linear-gradient(0deg, #202232 50%, #2b2e46 50%); border-radius: 24px; @@ -8,7 +8,8 @@ grid-template-columns: 250px 1fr; } -#section1.profile>div:first-child{ + +#section1.profile>div:first-child { overflow: hidden; border-radius: 100%; display: grid; @@ -21,76 +22,88 @@ } -#profile-image>img{ + +#profile-image>img { border-radius: 100%; transition: filter 0.3s; cursor: pointer; } -#profile-image>span{ +#profile-image>span { z-index: 1; position: absolute; opacity: 0; - color:white; + color: white; transition: opacity 0.3s; cursor: pointer; } -#profile-image:hover > img{filter: blur(5px) brightness(60%);z-index: 1;} -#profile-image:hover > span{opacity: 1;} +#profile-image:hover>img { + filter: blur(5px) brightness(60%); + z-index: 1; +} -#profile-top{ +#profile-image:hover>span { + opacity: 1; +} + +#profile-top { height: 100px; display: grid; grid-template-columns: 80% 20%; } -#profile-top>div:nth-child(1)>div>img{ + +#profile-top>div:nth-child(1)>div>img { margin: 12px; border-radius: 10px; } -#profile-top>div:nth-child(1){ +#profile-top>div:nth-child(1) { display: flex; place-items: center; font-size: 50px; font-weight: bold; color: white; } -#profile-top>div:nth-child(1)>div{ + +#profile-top>div:nth-child(1)>div { display: flex; height: 60px; } -span.titles{ + +span.titles { margin: 12px 12px 12px 0; font-size: 18px; font-weight: 100; - + padding: 6px 20px 0px 20px; border-radius: 10px; } -#profile-top>div:nth-child(2){ +#profile-top>div:nth-child(2) { display: flex; flex-direction: row-reverse; align-items: center; padding-right: 10px; } -#profile-top>div:nth-child(2)>a>img{ + +#profile-top>div:nth-child(2)>a>img { height: 50px; - padding: 0 5px 0 5px; + padding: 0 5px 0 5px; scale: 0.9; - filter: brightness(200%); + filter: brightness(200%); } -#profile-bottom{ +#profile-bottom { height: 100px; display: grid; grid-template-columns: 1fr 1fr 1fr; } -#profile-bottom>div{ + +#profile-bottom>div { margin: 12px; background-color: #2b2e46; border-radius: 20px; @@ -98,28 +111,33 @@ span.titles{ place-items: center; grid-template-rows: 40% 50%; } -#profile-bottom>div>span:nth-child(1){ + +#profile-bottom>div>span:nth-child(1) { color: inherit; font-size: 18px; } -#profile-bottom>div>span:nth-child(2){ + +#profile-bottom>div>span:nth-child(2) { color: white; font-size: 40px; } -#profile-bottom>div>span:nth-child(2)>span{ + +#profile-bottom>div>span:nth-child(2)>span { color: white; font-size: 20px; } + /* #section1.profile>div>div{outline: red 1px dashed;} */ -#section2.profile{ - margin: 20px; +#section2.profile { + margin: 20px; height: 60px; display: grid; - grid-template-columns: 1fr 1fr; + grid-template-columns: 1fr 1fr; } -#section2.profile>button{ + +#section2.profile>button { display: flex; justify-content: center; align-items: center; @@ -133,32 +151,42 @@ span.titles{ transition: background-color .1s; } -#section2.profile>button:nth-child(1){border-radius: 24px 0 0 24px;} -#section2.profile>button:nth-child(2){border-radius: 0 24px 24px 0;} -#section3.profile1>hr{border: 1px solid #2b2e46;margin: 8px 20px 0px 20px;} -#section3.profile1{ +#section2.profile>button:nth-child(1) { + border-radius: 24px 0 0 24px; +} + +#section2.profile>button:nth-child(2) { + border-radius: 0 24px 24px 0; +} + +#section3.profile1>hr { + border: 1px solid #2b2e46; + margin: 8px 20px 0px 20px; +} + +#section3.profile1 { margin: 20px; display: block; - + background-color: #202232; border-radius: 24px; } -#profileboard-nav{ +#profileboard-nav { display: grid; grid-template-columns: 1fr 1fr; } -#profileboard-nav>select{ +#profileboard-nav>select { /* appearance: none; */ margin: 10px 20px 20px 20px; - height: 50px; + height: 50px; border-radius: 24px; text-align: center; - + color: inherit; font-family: inherit; font-size: 24px; @@ -168,9 +196,17 @@ span.titles{ } -#profileboard-top>span>img{height: 20px;scale: .8;} -#profileboard-top>span>img,#profileboard-top>span>span{cursor: pointer;} -#profileboard-top{ +#profileboard-top>span>img { + height: 20px; + scale: .8; +} + +#profileboard-top>span>img, +#profileboard-top>span>span { + cursor: pointer; +} + +#profileboard-top { height: 34px; display: grid; font-size: 20px; @@ -179,24 +215,24 @@ span.titles{ grid-template-columns: 15% 15% 5% 15% 5% 15% 15% 15%; } -#profileboard-top>span{ +#profileboard-top>span { display: flex; place-items: flex-end; } -#profileboard-records{ +#profileboard-records { padding-bottom: 10px; } -.profileboard-record{ +.profileboard-record { width: calc(100% - 40px); margin: 10px 20px 0px 20px; - height: 44px; + height: 44px; border-radius: 20px; padding: 0 0 0 40px; font-size: 20px; - + color: inherit; font-family: inherit; border: 0; @@ -211,35 +247,128 @@ span.titles{ } /* this right here should be illegal */ -.profileboard-record>span:nth-child(-n+8){filter: brightness(100%);} -.profileboard-record>span{ +.profileboard-record>span:nth-child(-n+8) { + filter: brightness(100%); +} + +.profileboard-record>span { display: flex; place-items: flex-end; filter: brightness(65%); } -.profileboard-record>hr{ +.profileboard-record>hr { margin: 0 0 0 -60px; border: 0; height: 2px; background-color: #202232; } -.profileboard-record>span:nth-child(4){display: grid;} -.profileboard-record>span{ +.profileboard-record>span:nth-child(4) { + display: grid; +} + +.profileboard-record>span { display: flex; place-items: center; height: 44px; } -.profileboard-record>a>span{ + +.profileboard-record>a>span { display: flex; place-items: center; height: 44px; } -.profileboard-record>span>button{ + +.profileboard-record>span>button { background-color: #0000; border: 0; cursor: pointer; } + +@media screen and (max-width: 768px) { + #section1.profile { + margin: 20px; + grid-template-columns: 1fr; + height: auto; + min-height: 300px; + background: linear-gradient(0deg, #202232 60%, #2b2e46 40%); + } + + #section1.profile>div:first-child { + margin: 15px auto; + grid-row: 1; + } + + #profile-top { + grid-template-columns: 1fr; + height: auto; + text-align: center; + } + + #profile-top>div:nth-child(1) { + justify-content: center; + font-size: 32px; + } + + #profile-top>div:nth-child(1)>div { + flex-direction: column; + height: auto; + } + + #profile-top>div:nth-child(2) { + justify-content: center; + padding: 10px 0; + } + + #profile-bottom { + grid-template-columns: 1fr; + height: auto; + } + + #profile-bottom>div { + margin: 8px 12px; + } + + #section2.profile { + margin: 20px; + height: 50px; + } + + #section2.profile>button { + font-size: 18px; + } + + #section3.profile1 { + margin: 20px; + } + + #profileboard-nav { + grid-template-columns: 1fr; + } + + #profileboard-nav>select { + margin: 20px; + height: 45px; + font-size: 18px; + } + + #profileboard-top { + font-size: 14px; + padding-left: 20px; + grid-template-columns: 18% 18% 8% 15% 8% 10% 10% 13%; + } + + .profileboard-record { + font-size: 14px; + padding-left: 20px; + grid-template-columns: 18% 18% 8% 15% 8% 10% 10% 13%; + } + + span.titles { + font-size: 14px; + padding: 4px 12px 0px 12px; + } +} \ No newline at end of file diff --git a/frontend/src/css/Rankings.css b/frontend/src/css/Rankings.css index edc5a00..b644ecd 100644 --- a/frontend/src/css/Rankings.css +++ b/frontend/src/css/Rankings.css @@ -27,7 +27,8 @@ transition: all 0.1s; } -.nav-container button:hover, .nav-container button.selected { +.nav-container button:hover, +.nav-container button.selected { background-color: #202232; } @@ -105,3 +106,33 @@ border-radius: 200px; transform: translateX(10px); } + +@media screen and (max-width: 768px) { + + .nav-1 div, + .nav-2 div { + width: 95%; + } + + .nav-container button { + font-size: 18px; + padding: 8px 0px; + } + + .ranks-container { + width: calc(95% - 20px); + } + + .rankings-leaderboard { + font-size: 16px; + } + + .leaderboard-entry { + grid-template-columns: 15% 50% 35%; + font-size: 14px; + } + + .leaderboard-entry img { + height: 28px; + } +} \ No newline at end of file diff --git a/frontend/src/css/Rules.css b/frontend/src/css/Rules.css index bbc84c0..b7807cf 100644 --- a/frontend/src/css/Rules.css +++ b/frontend/src/css/Rules.css @@ -1,3 +1,9 @@ main { font-size: 24px; +} + +@media screen and (max-width: 768px) { + main { + font-size: 18px; + } } \ No newline at end of file diff --git a/frontend/src/css/Sidebar.css b/frontend/src/css/Sidebar.css index a91862e..8675dca 100644 --- a/frontend/src/css/Sidebar.css +++ b/frontend/src/css/Sidebar.css @@ -2,62 +2,69 @@ overflow: hidden; position: absolute; background-color: #2b2e46; - width: 320px; height: 100vh; + width: 320px; + height: 100vh; min-height: 670px; - + transition: transform 0.3s ease; } - /* logo */ -#logo{ +/* logo */ +#logo { display: grid; grid-template-columns: 60px 220px; - height: 80px; + height: 80px; padding: 20px 0 20px 20px; cursor: pointer; user-select: none; -} +} -#logo-text{ +#logo-text { font-family: BarlowCondensed-Regular; font-size: 36px; color: #FFF; line-height: 38px; } -#logo-text>span>b{ + +#logo-text>span>b { font-family: BarlowCondensed-Bold; font-size: 56px; } - /* Sidelist */ -#sidebar-list{ +/* Sidelist */ +#sidebar-list { z-index: 2; background-color: #2b2e46; position: relative; height: calc(100vh - 120px); - width: 320px; + width: 320px; /* min-height: 670px; */ transition: width .3s; -} -#sidebar-toplist>button:nth-child(1){margin-top: 5px;} -#sidebar-toplist{ +} + +#sidebar-toplist>button:nth-child(1) { + margin-top: 5px; +} + +#sidebar-toplist { display: grid; - + margin: 0 5px 0 5px; justify-items: left; height: 400px; grid-template-rows: 45px 50px 50px 50px 50px 50px 50px 50px auto; } -#sidebar-bottomlist{ +#sidebar-bottomlist { display: grid; margin: 0 5px 0 5px; justify-items: left; grid-template-rows: calc(100vh - 720px) 50px 50px 50px; } -.sidebar-button>span{ + +.sidebar-button>span { font-family: BarlowSemiCondensed-Regular; font-size: 18px; color: #CDCFDF; @@ -65,36 +72,37 @@ line-height: 28px; transition: opacity .1s; } -.sidebar-button{ + +.sidebar-button { display: grid; grid-template-columns: 50px auto; place-items: left; text-align: left; - + background-color: inherit; cursor: pointer; border: none; width: 310px; height: 40px; border-radius: 20px; - padding: 0.3em 0 0 11px; + padding: 0.4em 0 0 11px; - transition: - width .3s, - background-color .15s, - padding .3s; + transition: + width .3s, + background-color .15s, + padding .3s; } .sidebar-button .avatar-img { - border-radius: 50px; + border-radius: 50px; } -.logout-button{ +.logout-button { display: grid; grid-template-columns: 50px auto; place-items: left; text-align: left; - + background-color: inherit; cursor: pointer; border: none; @@ -103,10 +111,10 @@ border-radius: 20px; padding: 0.4em 0 0 11px; - transition: - width .3s, - background-color .15s, - padding .3s; + transition: + width .3s, + background-color .15s, + padding .3s; } .submit-run-button { @@ -114,7 +122,7 @@ grid-template-columns: 50px auto; place-items: left; text-align: left; - + background-color: inherit; cursor: pointer; border: none; @@ -123,10 +131,10 @@ border-radius: 20px; padding: 0.4em 0 0 11px; - transition: - width .3s, - background-color .15s, - padding .3s; + transition: + width .3s, + background-color .15s, + padding .3s; background-color: #202232aa; } @@ -135,7 +143,7 @@ } -.submit-run-button>span{ +.submit-run-button>span { font-family: BarlowSemiCondensed-Regular; font-size: 18px; color: #CDCFDF; @@ -162,19 +170,21 @@ button>img { padding: 5px; } - /* Maplist */ -#sidebar>div:nth-child(3){ +/* Search Panel */ +#search-panel { position: relative; background-color: #202232; color: #424562; z-index: 1; - - left: 52px; - top: calc(-100vh + 120px); - width: 268px; height: calc(100vh - 120px); + + left: 52px; + top: calc(-100vh + 120px); + width: 268px; + height: calc(100vh - 120px); min-height: 550px; -} -input#searchbar[type=text]{ +} + +input#searchbar[type=text] { margin: 10px 0 0 6px; padding: 1px 0px 1px 16px; width: 240px; @@ -182,33 +192,47 @@ input#searchbar[type=text]{ font-family: BarlowSemiCondensed-Regular; font-size: 20px; - + background-color: #161723; - color:#CDCFDF; - + color: #CDCFDF; + border: 0; border-radius: 20px; } -input[type=text]::placeholder{color:#2b2e46} -input[type=text]:focus{outline: inherit;} -a{text-decoration: none;height: 40px;} + +input[type=text]::placeholder { + color: #2b2e46 +} + +input[type=text]:focus { + outline: inherit; +} + +a { + text-decoration: none; + height: 40px; +} -#search-data{ +#search-data { margin: 8px 0 8px 0; overflow-y: auto; max-height: calc(100vh - 172px); scrollbar-width: thin; } -#search-data::-webkit-scrollbar{display: none;} -.search-map{ + +#search-data::-webkit-scrollbar { + display: none; +} + +.search-map { margin: 10px 6px 0 6px; - height: 80px; + height: 80px; border-radius: 20px; text-align: center; - + display: grid; border: 0; @@ -217,26 +241,28 @@ a{text-decoration: none;height: 40px;} grid-template-rows: 20% 20% 60%; width: calc(100% - 15px); } -.search-map>span{ + +.search-map>span { color: #888; font-size: 16px; font-family: BarlowSemiCondensed-Regular; } -.search-map>span:nth-child(3){ + +.search-map>span:nth-child(3) { font-size: 30px; color: #CDCFDF; } -.search-player{ +.search-player { overflow: hidden; margin: 10px 6px 0 6px; - height: 80px; + height: 80px; border-radius: 20px; text-align: center; color: #CDCFDF; font-family: BarlowSemiCondensed-Regular; - + display: grid; place-items: center; grid-template-columns: 20% 80%; @@ -245,23 +271,237 @@ a{text-decoration: none;height: 40px;} border: 0; transition: background-color .1s; background-color: #2b2e46; + width: calc(100% - 15px); + box-sizing: border-box; } -.search-player>img{ - height: 60px; + +.search-player>img { + height: 60px; border-radius: 20px; } -.search-player>span{ - width:154px; + +.search-player>span { + width: 100%; font-size: 26px; + overflow: hidden; + text-overflow: ellipsis; + white-space: nowrap; } +#mobile-topbar { + display: none; +} +#mobile-logo { + display: none; +} +#hamburger-menu { + display: none; +} +.mobile-search-header { + display: none; +} +.mobile-search-close { + display: none; +} - - - - - +@media screen and (max-width: 768px) { + + #sidebar { + position: fixed; + left: 0; + top: 60px; + width: 100%; + height: calc(100vh - 60px); + transform: translateX(-100%); + z-index: 1000; + transition: transform 0.3s ease; + } + + #sidebar.mobile-open { + transform: translateX(0); + } + + #logo { + display: none !important; + } + + #mobile-topbar { + display: flex; + justify-content: space-between; + align-items: center; + position: fixed; + top: 0; + left: 0; + right: 0; + height: 60px; + background-color: #2b2e46; + padding: 0 18px; + z-index: 999; + box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2); + } + + #mobile-logo { + display: flex; + align-items: center; + gap: 10px; + } + + #mobile-logo img { + height: 40px !important; + } + + #mobile-logo-text { + display: flex; + flex-direction: column; + align-items: center; + font-family: BarlowCondensed-Regular; + color: #FFF; + line-height: 1.1; + } + + #mobile-logo-text span:first-child { + font-family: BarlowCondensed-Bold; + font-size: 24px; + } + + #mobile-logo-text span:last-child { + font-size: 14px; + } + + #hamburger-menu { + display: flex; + flex-direction: column; + justify-content: space-around; + width: 30px; + height: 25px; + background: transparent; + border: none; + cursor: pointer; + padding: 0; + z-index: 1001; + } + + #hamburger-menu span { + width: 30px; + height: 3px; + background: #CDCFDF; + border-radius: 10px; + transition: all 0.3s ease; + transform-origin: 1px; + } + + #hamburger-menu.open span:nth-child(1) { + transform: rotate(45deg); + } + + #hamburger-menu.open span:nth-child(2) { + opacity: 0; + transform: translateX(20px); + } + + #hamburger-menu.open span:nth-child(3) { + transform: rotate(-45deg); + } + + #sidebar-list { + height: calc(100vh - 60px); + width: 280px; + padding-top: 20px; + } + + #sidebar-toplist { + height: auto; + grid-template-rows: 45px 20px 50px 50px 50px 50px auto; + } + + #sidebar-bottomlist { + grid-template-rows: 50px 50px 50px 50px 50px; + margin-top: 20px; + } + + .sidebar-button, + .logout-button, + .submit-run-button { + width: 270px !important; + } + + .sidebar-button span, + .submit-run-button span { + opacity: 1 !important; + } + + #search-panel { + position: fixed; + left: 0; + top: 60px; + width: 100%; + height: calc(100vh - 60px); + z-index: 998; + background-color: #202232; + transform: translateY(100%); + opacity: 0; + transition: transform 0.3s ease, opacity 0.3s ease; + pointer-events: none; + } + + #search-panel.mobile-search-open { + transform: translateY(0); + opacity: 1; + pointer-events: auto; + } + + .mobile-search-header { + display: flex; + align-items: center; + justify-content: flex-end; + padding: 10px 20px 0 20px; + gap: 10px; + } + + #search-panel input#searchbar[type=text] { + width: calc(100% - 40px); + margin: 10px 20px; + } + + .mobile-search-close { + display: block; + background-color: #2b2e46; + border: none; + color: #CDCFDF; + font-size: 28px; + width: 40px; + height: 40px; + border-radius: 50%; + cursor: pointer; + line-height: 1; + padding: 0; + transition: background-color 0.2s; + } + + .mobile-search-close:hover { + background-color: #202232; + } + + #search-panel #search-data { + max-height: calc(100vh - 140px); + padding: 0 10px; + } + + .login { + grid-template-columns: 50px auto 50px; + } + + .login>button:nth-child(2) { + left: 170px; + } + + button>img { + scale: 2; + width: 20px; + padding: 5px; + } +} \ No newline at end of file diff --git a/frontend/src/css/UploadRunDialog.css b/frontend/src/css/UploadRunDialog.css index f129bb8..56c2080 100644 --- a/frontend/src/css/UploadRunDialog.css +++ b/frontend/src/css/UploadRunDialog.css @@ -1,44 +1,47 @@ -div#upload-run{ +div#upload-run { position: absolute; left: 50%; z-index: 20; - width: 320px; height: auto; + width: 320px; + height: auto; /* background-color: red; */ transform: translateY(-68%); } -#upload-run-menu{ +#upload-run-menu { position: absolute; - left: calc(50%); top: 130px; + left: calc(50%); + top: 130px; transform: translateX(-50%); background-color: #2b2e46; - z-index: 3; color: white; + z-index: 3; + color: white; font-family: BarlowSemicondensed-SemiBold; } #upload-run-menu-add, -#upload-run-menu-edit{ +#upload-run-menu-edit { box-shadow: 0 0 40px 16px black; outline: 8px solid #2b2e46; border-radius: 20px; font-size: 40px; - text-wrap: nowrap; + text-wrap: nowrap; } #upload-run-menu-add>div, -#upload-run-menu-edit>div{ +#upload-run-menu-edit>div { display: flex; font-size: 20px; padding: 0px 15px; - gap: 2px; + gap: 2px; } #upload-run-menu-add>div .upload-run-item { - margin: 0px 20px; + margin: 0px 20px; } -#upload-run-block{ +#upload-run-block { position: absolute; background-color: black; opacity: .3; @@ -51,7 +54,7 @@ div#upload-run{ .upload-run-dropdown-container .dropdown-cur { user-select: none; cursor: pointer; - width: 240px; + width: 240px; } .upload-run-dropdown { @@ -81,9 +84,9 @@ div#upload-run{ } .upload-run-demo-name { - text-overflow: ellipsis; - overflow: hidden; - width: 380px; + text-overflow: ellipsis; + overflow: hidden; + width: 380px; } @keyframes dropdown-in { @@ -96,7 +99,8 @@ div#upload-run{ } } -button, input { +button, +input { background-color: #2b2e46; border: none; font-family: BarlowSemiCondensed-Regular; @@ -123,38 +127,84 @@ button:hover { display: flex; margin-top: 10px; } + .upload-run-buttons-container button { width: 100%; } -#host_demo, #partner_demo { - background-color: rgba(0, 0, 0, 0); - display: none; +#host_demo, +#partner_demo { + background-color: rgba(0, 0, 0, 0); + display: none; } .upload-run-drag-area { - border: 2px dashed grey; - border-radius: 10px; - height: 150px; - cursor: pointer; - width: 360px; - transition: all 0.2s ease; - text-align: center; - display: flex; - flex-direction: column; - align-items: center; - justify-content: center; - margin: 20px 0px; + border: 2px dashed grey; + border-radius: 10px; + height: 150px; + cursor: pointer; + width: 360px; + transition: all 0.2s ease; + text-align: center; + display: flex; + flex-direction: column; + align-items: center; + justify-content: center; + margin: 20px 0px; } -.upload-run-drag-area-highlight, .upload-run-drag-area-highlight-partner { - border: 2px dashed white; +.upload-run-drag-area-highlight, +.upload-run-drag-area-highlight-partner { + border: 2px dashed white; } .upload-run-drag-area-hidden { - height: fit-content; - text-align: left; - border: none; - align-items: flex-start; + height: fit-content; + text-align: left; + border: none; + align-items: flex-start; } +@media screen and (max-width: 768px) { + div#upload-run { + width: 90vw; + max-width: 400px; + } + + #upload-run-menu { + left: 50%; + top: 80px; + width: 90vw; + } + + #upload-run-menu-add, + #upload-run-menu-edit { + font-size: 28px; + width: 90vw; + } + + #upload-run-menu-add>div, + #upload-run-menu-edit>div { + flex-direction: column; + font-size: 18px; + } + + .upload-run-dropdown-container .dropdown-cur { + width: 80vw; + max-width: 300px; + } + + .upload-run-dropdown { + width: 80vw; + max-width: 320px; + } + + .upload-run-demo-name { + width: 90%; + } + + .upload-run-drag-area { + width: 80vw; + max-width: 360px; + } +} \ No newline at end of file -- cgit v1.2.3