partitioncloud-server/partitioncloud/static/style.css
2023-06-10 16:46:55 +02:00

454 lines
7.8 KiB
CSS

@import url('https://augustin64.fr/static/font/iosevka.css');
/** Color Schemes */
/* Themes used: Catppuccin Latte & Moccha
* https://github.com/catppuccin/catppuccin */
/* Light theme : catppuccin Latte */
:root {
--color-rosewater: #f5e0dc;
--color-flamingo: #f2cdcd;
--color-pink: #f5c2e7;
--color-mauve: #cba6f7;
--color-red: #f38ba8;
--color-maroon: #eba0ac;
--color-peach: #fab387;
--color-yellow: #f9e2af;
--color-green: #a6e3a1;
--color-teal: #94e2d5;
--color-sky: #89dceb;
--color-sapphire: #74c7ec;
--color-blue: #89b4fa;
--color-lavender: #b4befe;
--color-text: #cdd6f4;
--color-subtext1: #bac2de;
--color-subtext0: #a6adc8;
--color-overlay2: #9399b2;
--color-overlay1: #7f849c;
--color-overlay0: #6c7086;
--color-surface2: #585b70;
--color-surface1: #45475a;
--color-surface0: #313244;
--color-base: #1e1e2e;
--color-mantle: #181825;
--color-crust: #11111b;
--font-family: Iosevka Web;
}
/* Dark theme: Catpuccin Mocha */
@media (prefers-color-scheme: light) {
:root {
--color-rosewater: #dc8a78;
--color-flamingo: #dd7878;
--color-pink: #ea76cb;
--color-mauve: #8839ef;
--color-red: #d20f39;
--color-maroon: #e64553;
--color-peach: #fe640b;
--color-yellow: #df8e1d;
--color-green: #40a02b;
--color-teal: #179299;
--color-sky: #04a5e5;
--color-sapphire: #209fb5;
--color-blue: #1e66f5;
--color-lavender: #7287fd;
--color-text: #4c4f69;
--color-subtext1: #5c5f77;
--color-subtext0: #6c6f85;
--color-overlay2: #7c7f93;
--color-overlay1: #8c8fa1;
--color-overlay0: #9ca0b0;
--color-surface2: #acb0be;
--color-surface1: #bcc0cc;
--color-surface0: #ccd0da;
--color-base: #eff1f5;
--color-mantle: #e6e9ef;
--color-crust: #dce0e8;
}
}
/** Various settings (variables) */
:root {
/*--sidebar-size: max(10vw, 160px);*/
--sidebar-size: 200px;
}
/** Generic things */
h1 {
margin-left: 30px;
}
a {
text-decoration: none;
color: var(--color-blue);
}
body {
color: var(--color-text);
background-color: var(--color-base);
}
#page-header {
margin-left: 10px;
}
/** Just general styling of elements */
#content-container {
background-color: var(--color-base);
position: absolute;
top: 0;
left: var(--sidebar-size);
right: 0;
bottom: 0;
-moz-transition: left 0.5s ease;
transition: left 0.5s ease;
padding: 0 25px;
}
.album-cover {
padding: 5px;
margin: 5px;
border-radius: 3px;
background-color: inherit;
}
.album-cover:hover {
background-color: var(--color-base);
}
/** Sidebar toggle */
#sidebar {
background-color: var(--color-mantle);
width: var(--sidebar-size);
position: fixed;
top: 0;
left: 0;
bottom: 0;
}
#slide {
padding: 10px 6px 3px 10px;
border-radius: 3px;
background-color: var(--color-crust);
color: var(--color-blue);
}
#slide-sidebar {
display: none;
}
input:checked#slide-sidebar~#content-container {
left: 0;
overflow: unset;
}
input:checked#slide-sidebar~#sidebar {
display: none;
transition: display 0s 0.5s;
}
input:checked#slide-sidebar~label {
left: 10px;
}
#slide-sidebar~label {
z-index: 1;
position: absolute;
top: 20px;
left: calc(var(--sidebar-size) + 10px);
background-color: var(--color-base);
-moz-transition: left 0.5s ease;
transition: left 0.5s ease;
}
/** Albums: users */
#album-header {
display: flex;
}
section#users {
display: flex;
}
#header-actions {
align-self: center;
margin-left: auto;
margin-right: 0;
display: flex;
}
.user-profile-picture,
.dropdown {
margin: 3px;
width: 30px;
height: 30px;
text-align: center;
line-height: 30px;
border-radius: 5px;
font-weight: 600;
}
.user-profile-picture {
color: var(--color-mantle);
}
.dropdown {
background-color: var(--color-surface1);
}
/** Partitions Grid */
#partitions-grid {
margin-top: 50px;
display: grid;
grid-template-columns: repeat(auto-fill, 200px);
justify-content: center;
overflow-x: scroll;
}
#partitions-grid a {
text-decoration: none;
}
#search-partitions-grid {
display: flex;
overflow-x: scroll;
}
.partition {
background-color: var(--color-surface0);
width: 178px;
margin: 15px 0;
border-radius: 5px;
}
img.partition-thumbnail {
border-radius: 5px 5px 0 0;
height: 178px;
width: 178px;
background-color: var(--color-surface2);
}
.partition {
color: var(--color-text);
}
.partition-author {
font-style: italic;
font-size: .9rem;
}
.partition-description {
padding: 3px;
min-height: 50px;
}
/** Sidebar: "settings" */
#albums {
overflow: scroll;
height: 70vh;
}
.user {
display: flex;
}
.username {
margin-top: 7px;
margin-left: 5px;
}
#settings-container>button {
background-color: inherit;
color: inherit;
border-style: none;
border-radius: 3px;
font-size: .9rem;
width: -moz-available;
padding: 5px;
}
#settings-container>button:hover {
background-color: var(--color-crust);
}
#settings-container {
position: fixed;
bottom: 0;
background-color: var(--color-base);
width: 180px; /*TODO width: calc(var-(--sidebar-size) - 20px); ?*/
padding: 5px;
margin: 5px;
border-radius: 3px;
}
button#logout:hover {
background-color: var(--color-red);
color: var(--color-mantle);
}
button#logout {
color: var(--color-red);
}
button#logout>svg {
scale: 0.9;
position: absolute;
top: 7px;
left: 10px;
}
#settings-container>.user {
margin-top: 6px;
border-radius: 3px;
}
#settings-container>.user:hover {
background-color: var(--color-mantle);
}
/** Dropdown */
.dropdown-content {
display: none;
position: absolute;
z-index: 2;
background-color: var(--color-surface1);
font-size: 0.9rem;
transform: translateX(-130px);
min-width: 160px;
border-radius: 3px;
box-shadow: 0 4px 10px var(--color-surface1); /* Little shadow to add some depth */
}
.dropdown:hover .dropdown-content {
display: block;
width: unset;
}
.dropdown-content > a > div:hover {
background-color: var(--color-surface0);
}
.dropdown-content > a {
color: var(--color-text);
}
/** Dialogs */
dialog {
display: none;
z-index: 3;
/* Geometry */
top: 0;
border-width: 2px;
border-radius: 3px;
/* Colors */
background-color: var(--color-crust);
color: var(--color-text);
border-color: var(--color-lavender);
min-width: 75vw;
}
.close-dialog {
float: right;
}
dialog:target {
display: block;
}
dialog:target ~ .mask {
display: block;
}
.mask {
display: none;
position: fixed;
top: 0;
left: 0;
width: 100vw;
height: 100vh;
background-color: var(--color-crust);
z-index: 1;
opacity: 50%;
}
/** Forms */
input[type="text"],
input[type="search"],
select,
textarea {
padding: 7px;
background-color: var(--color-surface1);
color: var(--color-text);
margin: 3px;
border-radius: 3px;
border-width: 0;
border-style: unset;
}
textarea {
resize: vertical;
}
input[type="submit"] {
padding: 10px 20px;
border: none;
border-radius: 3px;
margin: 5px;
background-color: var(--color-blue);
color: var(--color-base);
cursor: pointer;
}
/* Styles for input[type="file"] */
input[type="file"] {
padding: 7px 20px;
border: none;
border-radius: 3px;
margin: 3px;
background-color: var(--color-blue);
color: var(--color-base);
cursor: pointer;
}
/** Search bar */
#search-form {
margin: 10px;
}
#search-bar {
width: -moz-available;
}
#search-submit {
padding: 5px 5px;
}