leilukin-site/shrines/starwarskotor/starwarskotor.css

355 lines
5.9 KiB
CSS
Raw Normal View History

2023-06-15 09:18:46 +00:00
:root {
--header-image: url('./img/swkotor-header.jpg');
--body-color: #fceaff;
--body-bg: #212121;
--content-bg: #000000;
--content: #43256E;
--title-color: #ffc400;
--title-border: #ffe387;
--code-bg: #241445;
--code-border: #e4dbbe;
--link-color: #bb9671;
--link-hover: #94575a;
--blockquote-bg: #2f2d2d;
--blockquote-border: #4d4385;
--box-bg: #13092D;
}
@font-face {
font-family: 'Nunito';
src: url('/assets/fonts/Nunito-VariableFont_wght.ttf') format("truetype");
font-weight: 125 950;
font-stretch: 75% 125%;
font-style: normal;
}
@font-face {
font-family: 'Nunito';
src: url('/assets/fonts/Nunito-Italic-VariableFont_wght.ttf') format("truetype");
font-weight: 125 950;
font-stretch: 75% 125%;
font-style: italic;
}
html,
body {
scroll-behavior: smooth;
}
body {
font-family: 'Nunito', Arial, sans-serif;
font-size: 1rem; /* 16px */
2023-06-15 09:18:46 +00:00
margin: 0;
background-color: var(--body-bg);
background-size: 4rem;
2023-06-15 09:18:46 +00:00
color: var(--body-color);
background-image: var(--body-bg-image);
background-attachment: fixed;
line-height: 1.6;
}
* {
box-sizing: border-box;
}
h1,
h2,
h3 {
color: var(--title-color);
}
h1 {
font-size: 2.2rem;
border-bottom: 0.18rem solid var(--title-border);
padding-bottom: 0.5rem;
2023-06-15 09:18:46 +00:00
}
h1:not(:first-child) {
padding-top: 30px;
}
h2 {
font-size: 1.7rem;
}
strong {
color: var(--title-color);
}
hr {
width: 75%;
margin-top: 1.5rem;
margin-bottom: 1.5rem;
}
blockquote {
border-left: var(--blockquote-border) 3px solid;
background: var(--blockquote-bg);
padding: 0 0.75rem;
2023-06-15 09:18:46 +00:00
margin: 0 1.5rem;
}
.linkBtn {
font: 1.1rem 'Source Sans Pro', Arial, sans-serif;
border: 0.125rem solid var(--link-color);
2023-06-15 09:18:46 +00:00
border-radius: 10px;
padding: 0.75rem 1rem;
2023-06-15 09:18:46 +00:00
margin: 0.25em 0.15em;
background: none;
color: var(--link-color);
cursor: pointer;
font-weight: 700;
text-transform: uppercase;
}
.linkBtn:hover {
cursor:pointer;
color: white;
background-color: var(--link-color);
transition: 0.5s;
}
span.monospace {
font-family: monospace;
border: 1px solid var(--code-border);
padding: 2px;
2023-06-15 09:18:46 +00:00
background-color: var(--code-bg);
}
.code-snippet {
background-color: var(--code-bg);
border: 1px solid var(--code-border);
display: block;
padding: 0.5em;
overflow-x: auto;
word-break: break-all;
}
.box {
background-color: var(--box-bg);
border: 1px solid var(--title-color);
padding: 10px;
}
.full-width-youtube-video {
position: relative;
padding-bottom: 56.25%;
height: 0;
}
.full-width-youtube-video iframe {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
}
/* CONTAINER for wrapping the entire website */
#container {
max-width: 1100px;
/* the width of the layout */
/* if you change the above value, scroll to the bottom
and change the media query according to the comment! */
margin: 0 auto;
/* this centers the entire page */
}
/* For all links on your page EXCEPT for the navigation */
#container a {
color: var(--link-color);
font-weight: bold;
}
#container a:hover {
color: var(--link-hover);
}
#header {
width: 100%;
background-color: var(--content-bg);
height: 480px;
2023-06-15 09:18:46 +00:00
background-image: var(--header-image);
background-size: 100%;
background-repeat: no-repeat;
background-position: center;
}
/* NAVIGATION SECTION */
.sticky-nav {
position: fixed;
top: 0;
2023-06-15 12:00:48 +00:00
max-width: 1100px;
2023-06-15 09:18:46 +00:00
}
#navbar {
height: 2.5rem;
2023-06-15 09:18:46 +00:00
background-color: var(--content-bg);
width: 100%;
margin-bottom: 0.625rem;
2023-06-15 09:18:46 +00:00
z-index: 999;
}
#navbar ul {
display: flex;
padding: 0;
margin: 0;
list-style-type: none;
justify-content: space-evenly;
}
#navbar li {
padding-top: 0.625rem;
2023-06-15 09:18:46 +00:00
}
#navbar li a {
color: var(--link-color);
/* navbar text color */
font-weight: 800;
text-decoration: none;
/* this removes the underline */
}
#navbar li a:hover {
color: var(--link-hover);
text-decoration: underline;
}
#flex {
display: flex;
}
/* EXTRAS */
#topBar {
width: 100%;
height: 1.875rem;
padding: 0.625rem;
2023-06-15 09:18:46 +00:00
font-size: smaller;
background-color: var(--box-bg);
}
/* MAIN CONTENT AREA, between the sidebars */
main {
font-size: 1.2rem;
flex: 1;
order: 2;
}
.content-section {
background-color: var(--content-bg);
padding: 1.25rem;
2023-06-15 09:18:46 +00:00
}
.content-section:not(:first-child) {
margin-top: 0.625rem;
2023-06-15 09:18:46 +00:00
}
/* This colors BOTH sidebars
If you want to style them separately,
create styles for #leftSidebar and #rightSidebar */
aside {
background-color: var(--content-bg);
width: 12.5rem;
padding: 1.25rem;
2023-06-15 09:18:46 +00:00
font-size: smaller;
/* this makes the sidebar text slightly smaller */
}
aside h1, aside h2, aside h3 {
margin-bottom: 0;
}
aside ul {
margin-top: 0.5rem;
}
aside .box ul {
padding-left: 1.25rem;
2023-06-15 09:18:46 +00:00
}
#leftSidebar {
order: 1;
margin-right: 1.25rem;
2023-06-15 09:18:46 +00:00
}
#rightSidebar {
order: 3;
margin-left: 1.25rem;
2023-06-15 09:18:46 +00:00
}
.sidebar-content {
position: sticky;
top: 40px;
font-size: 0.9rem;
}
/* TABLE OF CONTENTS */
.toc-title {
font-size: 1.3rem;
font-weight: bold;
}
.toc-list {
list-style: none;
margin-left: 0;
padding-left: 0;
font-size: 1rem;
}
.toc-list li {
margin-bottom: 0.5em;
}
/* FOOTER */
footer {
background-color: var(--content-bg);
width: 100%;
height: 2.5rem;
2023-06-15 09:18:46 +00:00
text-align: center;
2023-06-15 15:26:50 +00:00
display: flex;
justify-content: center;
align-items: center;
margin-top: 1.25rem;
2023-06-15 09:18:46 +00:00
}
/* MEDIA QUERY STARTS HERE */
/* To keep things responsive,
if you want to change the width of your page,
take your new width of the #container, and then subtrack it by 100.
Use this new number as the "max-width" value below */
@media only screen and (max-width: 1000px) {
#flex {
flex-wrap: wrap;
}
aside {
width: 100%;
}
/* the order of the items is adjusted here for responsiveness.
since the sidebars would be too small on a mobile device. */
main {
order: 1;
2023-06-15 09:18:46 +00:00
}
#leftSidebar {
order: 2;
margin-right: 1.25rem;
2023-06-15 09:18:46 +00:00
}
#rightSidebar {
order: 3;
margin-left: 1.25rem;
2023-06-15 09:18:46 +00:00
}
#navbar ul {
flex-wrap: wrap;
}
}