Files
web/css/base.css
T

947 lines
13 KiB
CSS

@font-face {
font-family: 'Hack Nerd Font Mono';
src: url('/data/resources/HackNerdFontMono-Regular.woff');
font-weight: normal;
font-style: normal;
}
* {
padding: 0;
margin: 0;
}
body {
padding-bottom: 50px;
}
h1,
h2,
h3,
h4,
h5,
h6,
p,
small,
label,
input,
input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus,
textarea,
a,
.modal_button,
th,
td,
li,
select,
option,
span {
font-family: 'Hack Nerd Font Mono', Hack, sans-serif;
padding: 0;
margin: 0;
}
h1 {
font-size: 3vw;
}
h2 {
font-size: 2.5vw;
}
h3,
h3 a {
font-size: 2vw;
}
h4,
h4 a {
font-size: 1.75vw;
}
h5,
h5 a {
font-size: 1.5vw;
}
h6,
h6 a {
font-size: 1.25vw;
}
p,
a,
label,
li,
.modal_button,
.button,
span {
font-size: 1vw;
}
p {
margin-bottom: 15px;
}
small {
font-size: .75vw;
}
a,
.modal_button {
color: orange;
transition-duration: 1s;
}
a {
-webkit-tap-highlight-color: transparent !important;
outline: none !important;
}
a.fill_div {
display: block;
height: 100%;
width: 100%;
text-decoration: none;
}
nav {
display: flex;
flex-direction: row;
position: sticky;
width: 100%;
padding: 0;
margin: 0;
backdrop-filter: blur(50px);
z-index: 100;
}
nav ul {
padding: 0;
margin: 0;
width: 100%;
}
nav ul li {
display: inline-block;
}
nav ul li a {
font-size: 2vw;
font-weight: 800;
text-decoration: none;
display: block;
height: 100%;
width: 100%;
padding: 15px;
transition-duration: 500ms;
}
nav ul li a:hover {
color: orange;
}
nav form {
padding: 15px;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
}
.nav_right_hand {
display: flex;
flex-direction: row;
align-items: center;
justify-content: center;
}
.nav_right_hand * {
margin: 0px 15px 0px 15px;
}
code {
padding: 1px;
border-radius: 4px;
}
.line {
height: 1px;
width: 100%;
margin-top: 5px;
margin-bottom: 5px;
}
.center-h {
margin: 0 auto;
}
.article_filters form .row_space_between {
display: flex;
align-items: center;
margin-top: 25px;
}
.article_filters form .row_space_between p {
margin-bottom: 0;
padding-bottom: 0;
}
.article_card,
.form_card,
.view_card {
margin: 0 auto;
margin-top: 50px;
margin-bottom: 50px;
width: 70%;
padding: 18px;
height: max-content;
border-radius: 18px;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
transition-duration: 1s;
}
.article_card {
width: 100%;
box-sizing: border-box;
}
.form_card {
width: 50%;
}
.form_card form {
width: 80%;
}
.view_card form {
width: 95%;
padding: 15px;
}
form table {
border-collapse: separate;
border-spacing: 5px;
width: 100%;
}
tbody tr {
transition-duration: 1s;
}
tbody tr:hover {
outline: solid 3px orange;
}
tbody tr td {
text-align: center;
align-items: center;
justify-content: center;
padding: 15px 0px 15px 5px;
}
table tr td label {
width: max-content;
}
.card_info_box {
display: flex;
}
.col-right {
margin-right: 25px;
display: flex;
flex-direction: column;
justify-content: center;
align-items: end;
}
.card_pic_box {
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
}
.button {
background-color: transparent;
padding: 15px;
text-decoration: none;
border-radius: 12px;
transition-duration: 1s;
border: 3px solid orange;
}
.narrow {
width: 20%;
}
.tag {
margin: 15px;
padding: 10px;
border-radius: 18px;
border: 2px solid orange;
text-decoration: none;
}
.tag_row {}
.tag_box {
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
}
.card_profile_picture {
height: 64px;
width: auto;
border-radius: 50%;
}
.underline {
text-decoration: underline;
text-decoration-thickness: 3px;
text-decoration-color: orange;
}
i {
border: none;
background: transparent;
font-size: 1.5vw;
transition-duration: 500ms;
}
#theme_toggle {
background: none;
border: none;
}
i:hover {
color: orange;
}
.article {
width: 60%;
margin: 0 auto;
}
.article ul li,
.article ol li {
margin-left: 50px;
}
#compose {
width: 100%;
height: 100%;
display: flex;
flex-direction: column;
justify-content: left;
}
input,
.autofilled,
input:-webkit-autofill,
textarea:-webkit-autofill,
input:-webkit-autofill:hover,
textarea:-webkit-autofill:hover,
input:-webkit-autofill:focus,
select,
option,
textarea {
/* Try this first */
border-radius: 12px;
width: 100%;
padding: 15px;
margin: 15px 15px 15px 0px;
box-sizing: border-box;
transition-duration: 500ms;
resize: none;
background-color: transparent;
}
input[type="datetime_local"] {
color: white;
}
input:focus,
textarea:focus,
input:hover,
textarea:hover {
border: 3px solid orange;
outline: none;
}
textarea {
border-radius: 18px;
height: 70%;
}
.checkboxes {
height: max-content;
}
input[type="radio"] {
display: none;
}
.form_checkbox_container {
display: flex;
align-items: center;
justify-content: center;
position: relative;
padding-left: 35px;
margin: 15px 15px 15px 0px;
cursor: pointer;
-webkit-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
user-select: none;
height: 29px;
width: max-content;
}
.checkmark {
position: absolute;
top: 0;
left: 0;
height: 25px;
width: 25px;
}
.form_checkbox_container input {
position: absolute;
opacity: 0;
cursor: pointer;
height: 0;
width: 0;
}
/* Create the checkmark/indicator (hidden when not checked) */
.checkmark:after {
content: "";
position: absolute;
display: none;
}
/* Show the checkmark when checked */
.form_checkbox_container input:checked~.checkmark:after {
display: block;
}
/* When the checkbox is checked, add a blue background */
.form_checkbox_container input:checked~.checkmark {
background-color: orange;
}
/* Style the checkmark/indicator */
.form_checkbox_container .checkmark:after {
left: 9px;
top: 5px;
width: 5px;
height: 10px;
border: solid white;
border-width: 0 3px 3px 0;
-webkit-transform: rotate(45deg);
-ms-transform: rotate(45deg);
transform: rotate(45deg);
}
input[type="file"] {
display: none;
}
.upload_button {
border-radius: 12px;
display: inline-block;
padding: 6px 12px;
cursor: pointer;
}
.error {
color: red;
border: 3px solid red;
border-radius: 12px;
padding: 15px;
margin: 15px 15px 15px 0px;
width: 100%;
box-sizing: border-box;
}
.user_view {
width: 70%;
margin: 0 auto;
}
.user_view h1,
.user_view .card_pic_box {
margin: 15px;
}
.user_view .line {
margin: 0px 0px 30px 0px;
}
.user_actions {
margin: 15px;
padding: 15px;
display: flex;
justify-content: space-evenly;
border-radius: 12px;
}
.form_card h3,
.form_card h5,
.view_card h3,
.view_card h5 {
padding-bottom: 15px;
}
.profile_picture {
height: 128px;
width: auto;
border-radius: 50%;
}
/* The Modal (background) */
.modal {
display: none;
position: fixed;
z-index: 1;
padding-top: 100px;
left: 0;
top: 0;
width: 100%;
height: 100%;
overflow: auto;
backdrop-filter: blur(10px);
}
/* Modal Content */
.form_card {
position: relative;
}
.modal_content {
display: fit-content;
margin: auto;
width: 40%;
height: max-content;
}
.modal_content .form_card {
width: 100%;
box-sizing: border-box;
}
/* The Close Button */
.modal_close {
position: absolute;
font-size: 48px;
top: 15px;
right: 30px;
font-weight: bold;
cursor: pointer;
}
.modal_close:hover,
.modal_close:focus {
color: orange;
cursor: pointer;
}
.modal_button {
background-color: transparent;
border: none;
}
#img_to_crop {
width: 70%;
height: auto;
max-width: 512px;
max-height: 512px;
user-select: none;
}
#img_crop_selection {
pointer-events: none;
height: 128px;
width: 128px;
outline: dashed 4px orange;
position: fixed;
left: 50%;
top: 50%;
transform: translate(-50%, -50%);
}
.corner {
position: absolute;
width: 10px;
height: 10px;
background-color: orange;
border-radius: 50%;
cursor: nwse-resize;
/* Default cursor for resizing */
pointer-events: all;
}
#corner_nw {
top: -5px;
left: -5px;
cursor: nw-resize;
}
#corner_ne {
top: -5px;
right: -5px;
cursor: ne-resize;
}
#corner_sw {
bottom: -5px;
left: -5px;
cursor: sw-resize;
}
#corner_se {
bottom: -5px;
right: -5px;
cursor: se-resize;
}
[data-href] {
cursor: pointer;
}
.article_cards_grid {
width: 70%;
margin: 0 auto;
display: block;
}
.article_grid {
display: grid;
grid-template-columns: 15% 85%;
}
/* Tooltip container */
.tooltip {
position: relative;
display: inline-block;
border-bottom: 1px dotted black;
/* If you want dots under the hoverable text */
}
/* Tooltip text */
.tooltip .tooltiptext {
visibility: hidden;
width: 120px;
background-color: black;
color: #fff;
text-align: center;
padding: 5px 0;
border-radius: 6px;
/* Position the tooltip text - see examples below! */
position: absolute;
z-index: 1;
}
/* Show the tooltip text when you mouse over the tooltip container */
.tooltip:hover .tooltiptext {
visibility: visible;
}
#required_field {
display: none;
}
::selection {
color: black;
background: orange;
}
.grid-2x1 {
margin: 0 auto;
width: 90%;
display: grid;
grid-template-columns: 50% 50%;
}
.grid-2x1 .form_card,
.grid-2x1 #md_preview {
width: 80%;
height: 90%;
overflow-y: scroll;
box-sizing: border-box;
}
.grid-2x1 #composer {
padding-top: 150px;
}
#md_preview {
border: none;
display: block;
}
.full-height {
height: 700px;
}
hr {
margin: 15px 0px 15px 0px;
}
::-webkit-scrollbar {
background-color: transparent;
border-radius: 18px;
}
::-webkit-scrollbar-button {
display: none;
}
::-webkit-scrollbar-track {
display: none;
}
::-webkit-scrollbar-thumb {
background-color: orange;
border-radius: 9px;
}
.dropdown {
position: relative;
display: block;
margin-right: 15px;
padding: 15px;
border-radius: 9px;
}
.dropdown_content {
display: none;
position: absolute;
min-width: 50px;
padding: 15px;
z-index: 2;
}
.dropdown:hover .dropdown_content {
display: block;
margin-left: -15px;
margin-top: 15px;
border-radius: 12px;
}
.dropdown_content form * {
margin-top: 5px;
margin-bottom: 5px;
}
@media screen and (max-width: 992px) {
body {
padding-bottom: 160px;
box-sizing: border-box;
}
h1 {
font-size: 8vw;
}
h2 {
font-size: 6vw;
}
h3,
h3 a {
font-size: 5vw;
}
h4,
h4 a {
font-size: 4vw;
}
h5,
h5 a {
font-size: 3vw;
}
h6,
h6 a {
font-size: 2.5vw;
}
p,
a,
label,
ul li,
ol li,
ul li a,
ol li a,
.modal_button,
.button,
span {
font-size: 2vw;
}
p {
margin-bottom: 30px;
}
small {
font-size: 1.5vw;
}
nav {
position: fixed;
bottom: -2px;
width: 100%;
margin: 0;
padding: 50px 0px 50px 0px;
backdrop-filter: blur(50px);
}
nav ul li a {
font-size: 3vw;
}
.site_navigation ul {
display: flex;
flex-direction: row-reverse;
}
nav .row_space_between .no_margin {
flex-direction: row-reverse;
}
.nav_right_hand {
flex-direction: row-reverse;
align-items: center;
justify-content: center;
}
.nav_right_hand * {
margin: 0px 0px 0px 15px;
}
.article_card,
.form_card,
.view_card,
.article_cards_grid,
.article,
.user_view {
width: 95%;
}
.user_actions {
flex-direction: column;
}
.user_actions * {
margin: 15px 0px 15px 0px;
}
.article_card .row {
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
}
.article_card .row .card_info_box {
display: flex;
justify-content: space-between;
align-items: center;
width: 100%;
}
.article_card .row .card_info_box .col-right {
display: flex;
flex-direction: column;
justify-content: center;
align-items: start;
}
.article_card>div:last-of-type {
display: flex;
flex-direction: row-reverse;
justify-content: space-between;
align-items: center;
}
#theme_toggle *,
i {
font-size: 3vw;
}
.full-height {
height: 100%;
}
.full-height #composer {
padding-top: 15px;
}
.full-height .form_card form textarea {
height: 300px;
}
.grid-2x1 {
display: block;
width: 100%;
}
.grid-2x1>div:last-of-type {
display: none;
}
#floating_compose {
padding: 15px;
border-radius: 50%;
position: fixed;
bottom: 200px;
right: 25px;
}
}
@media screen and (min-width: 993px) {
nav {
position: sticky;
width: 100%;
padding: 0;
margin: 0;
backdrop-filter: blur(50px);
top: 0;
}
#floating_compose {
padding: 15px;
border-radius: 50%;
position: fixed;
bottom: 50px;
right: 50px;
}
}