koehr.ing/zig-out/style.css
2024-09-16 22:02:39 +02:00

328 lines
5.4 KiB
CSS

:root {
--header-bg-color: #1b1c1d;
--header-fg-color: #a3bd8d;
--header-height: 192px;
--header-height-small: calc(var(--header-height) * .25);
--header-height-multiplier: .25;
--page-bg-color: #232425;
--page-fg-color: #7e9fbe;
--page-link-color: #aabbee;
--menu-bg-color: #000;
--highlight-fg-color: #eacb8b;
--emboss-color: #000;
}
@font-face {
font-family: 'rubikregular';
src: url('/rubik-regular-minimal.woff2') format('woff2');
font-weight: normal;
font-style: normal;
font-display: swap;
}
@media (prefers-color-scheme: light) {
:root {
--page-bg-color: #efe9d9;
--page-fg-color: #261b00;
--menu-bg-color: #fff;
--header-fg-color: #143373;
--header-bg-color: #a49570;
--emboss-color: #fff;
}
.light\:invert,
.contacts img {
filter: invert();
}
}
* {
transition: color 300ms ease, background-color 300ms ease, fill 500ms ease;
}
html,
body {
width: 100vw;
display: flex;
flex-flow: column nowrap;
justify-content: center;
margin: auto;
background: var(--page-bg-color);
color: var(--page-fg-color);
font-size: 20px;
font-family: 'rubikregular', sans-serif;
scroll-behavior: smooth;
}
#main-menu {
position: fixed;
top: var(--header-height);
width: 100vw;
background-color: var(--menu-bg-color);
transition: top .3s ease-in-out, background-color 1s ease-in;
}
#main-menu>menu {
width: 960px;
max-width: 98%;
height: 1.2rem;
margin: 0 auto 0;
padding: 0;
display: flex;
justify-content: space-around;
align-items: center;
list-style: circle;
}
#main-menu > li {
padding: 0;
}
body>header.small + #main-menu {
top: var(--header-height-small);
background-color: var(--header-bg-color);
}
body>header.small + #main-menu>menu {
padding: .5rem 0;
}
pre {
background: var(--emboss-color);
padding: .5rem;
}
li.active>a {
color: var(--highlight-fg-color);
font-weight: bold;
}
body>#spacer,
body>header {
position: fixed;
top: 0;
left: 0;
width: 100vw;
background-color: var(--header-bg-color);
}
body>#spacer {
height: var(--header-height-small);
}
body>header, body>header>a {
height: var(--header-height);
color: transparent;
transition: transform .3s ease-in-out;
transform-origin: top center;
}
body>header.small {
transform: scale(var(--header-height-multiplier));
}
body>header svg {
display: block;
width: 960px;
max-width: 98vw;
margin: .5em auto;
color: var(--header-fg-color);
}
body>main {
width: 960px;
max-width: 98vw;
margin: var(--header-height) auto 4rem;
}
body>main>header {
display: block;
padding: 2em 0;
}
a {
color: var(--page-link-color);
}
blockquote {
margin: 0;
padding: .5em .5em .5em 1em;
background-color: rgba(128, 128, 128, .1);
border-radius: 12px;
}
code {
background-color: var(--emboss-color);
}
#intro {
display: flex;
flex-flow: column nowrap;
min-height: calc(100vh - var(--header-height));
margin: 2rem 0;
}
#content {
padding-top: 2rem;
}
#content>h1,
#contact h1,
main > header > h1 {
margin: 0 0 .25em;
font-size: 2rem;
font-variant: small-caps;
text-shadow: 1px 1px 0 var(--emboss-color);
color: var(--header-fg-color);
}
#content>h1,
#contact h1 {
padding-top: 2em;
}
h2 {
color: var(--highlight-fg-color);
}
#cta {
display: flex;
flex-flow: row wrap;
justify-content: space-between;
align-items: center;
gap: 1rem;
}
#cta>a {
width: 450px;
padding: 2rem .5rem 0;
display: flex;
flex-flow: column nowrap;
justify-content: center;
align-items: center;
gap: 1rem;
text-decoration: none;
font-variant: small-caps;
font-size: 2rem;
text-align: center;
background-color: rgba(128, 128, 128, .1);
transition: background-color .3s ease;
border-radius: 12px;
}
#cta>a:hover {
background-color: rgba(128, 128, 128, .2);
}
#cta>a>svg {
display: block;
max-width: 200px;
opacity: .3;
transition: opacity .3s ease;
}
#cta>a:hover>svg {
opacity: .8;
}
.contacts {
margin: 1.5em 0;
columns: 3;
column-fill: balance;
}
.contacts>li {
display: flex;
align-items: center;
gap: 1rem;
margin: 0 0 1em 0;
}
.contacts img {
width: 3rem;
}
#header-tilde,
#header-bracket,
#header-underscore {
fill: var(--highlight-fg-color);
}
#header-k,
#header-o,
#header-e,
#header-h,
#header-r {
fill: var(--header-fg-color);
}
#header-underscore {
animation: fade 2s linear infinite;
}
hr {
display: block;
border: none;
width: 100%;
height: 1px;
margin: 2rem 0;
background-color: var(--emboss-color);
}
span[title] {
text-decoration: underline wavy gray;
}
@keyframes fade {
0% {
opacity: 1.0;
}
50% {
opacity: 0.0;
}
60% {
opacity: 0.0;
}
80% {
opacity: 1.0;
}
100% {
opacity: 1.0;
}
}
@media (max-width: 980px) {
:root {
--header-height: calc(100vw * 0.17);
--header-height-small: 48px;
}
#cta>a {
width: 100%;
}
.contacts {
columns: 2;
}
}
@media (max-width: 480px) {
body>header.small {
transform: none;
}
body>header.small + #main-menu {
top: var(--header-height);
}
#main-menu>menu {
height: 2.4rem;
margin-left: 1.5rem;
padding: .5rem 0;
flex-flow: column wrap;
align-items: flex-start;
}
body>main {
margin: calc(var(--header-height) + 2rem) auto 4rem;
}
#content > h1 {
padding-top: calc(var(--header-height) + 2rem);
}
.contacts {
columns: 1;
}
}
iframe{width:640px;max-width:100%;height:30em;}