
/*
  p1r0j's personal website.

  Copyright (C) 2026 p1r0j

  This program is free software: you can redistribute it and/or modify
  it under the terms of the GNU Affero General Public License as
  published by the Free Software Foundation, either version 3 of the
  License, or (at your option) any later version.

  This program is distributed in the hope that it will be useful,
  but WITHOUT ANY WARRANTY; without even the implied warranty of
  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  GNU Affero General Public License for more details.

  You should have received a copy of the GNU Affero General Public License
  along with this program.  If not, see <https://www.gnu.org/licenses/>.
*/

:root {
  --mono-font: monospace;
  --sans-font: sans-serif;
  --serif-font: serif;

  /* "1" colors have greater contrast */
  --accent-color: #f57d26;
  --background-color-1: #f2efdf;
  --background-color-2: #bec5b2;
  --error-color: #f85552;
  --foreground-color-1: #5c6a72;
  --foreground-color-2: #939f91;
  --link-color: #8da101;
}

@media (prefers-color-scheme: dark) {
  :root {
    color-scheme: dark;
    --accent-color: #e69875;
    --background-color-1: #1e2326;
    --background-color-2: #4f5b58;
    --error-color: #e67e80;
    --foreground-color-1: #d3c6aa;
    --foreground-color-2: #859289;
    --link-color: #a7c080;
  }
}

* {
  box-sizing: border-box;
  color: var(--foreground-color-1);
  line-height: 1.5;
}

html {
  background-color: var(--background-color-1);
  box-shadow: 0 3px 9px 0 rgba(0, 0, 0, 0.2), 0 6px 18px 0 rgba(0, 0, 0, 0.19);
  font-family: var(--serif-font);
  font-size: 18px;
  margin-inline: auto;
  max-width: 90ch;
}

body {
  margin: 0;
}

main {
  margin-inline: auto;
  max-width: 90ch;
}

aside {
  width: 30%;
  padding-left: 0.6rem;
  margin-left: 0.6rem;
  float: right;
  font-style: italic;
}

a {
  color: var(--link-color);
}

blockquote {
  border-inline-start: 3px solid var(--foreground-color-1);
  font-size: 0.9rem;
  padding-inline: .9rem;
  text-align: end;
}
blockquote cite {
  color: var(--foreground-color-2);
}

caption {
  caption-side: bottom;
  color: var(--foreground-color-2);
  font-size: 0.9rem;
  font-style: italic;
}

code {
  border: 1px dashed var(--background-color-2);
}

footer,
nav,
section {
  margin-block: 3rem;
}

footer p {
  color: var(--foreground-color-2);
  font-size: 0.9rem;
  text-align: center;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--sans-font);
  margin-block: 1.8rem;
}

h1 {
  margin: 0;
  margin-bottom: 1.8rem;
}

hr {
  border: none;
  border-top: medium double var(--background-color-2);
  color: var(--foreground-color-1);
  margin-block: 9rem;
  overflow: visible;
  padding: 0;
  text-align: center;
  width: 75%;
}
hr::after {
  content: "⚘";
  display: inline-block;
  position: relative;
  top: -0.7em;
  font-size: 1.5em;
  padding: 0 0.25em;
  background: var(--background-color-1);
}

img {
  max-width: 100%;
}

li {
  margin-block: 0.3rem;
}
li::marker {
  color: var(--accent-color);
}

nav {
  text-align: center;
}
nav * {
  font-size: 0.9rem;
}

ol,
ul {
  text-align: justify;
}

p {
  text-align: justify;
}
p.info {
  font-size: 0.9rem;
  text-align: center;
}
p.lead {
  font-family: var(--sans-font);
  font-size: 3rem;
  margin: 0;
  margin-bottom: 1.8rem;
  text-align: start;
}

section {
  padding: .9rem;
}

.lead.error {
  color: var(--error-color);
}

table {
  border-collapse: collapse;
  table-layout: fixed;
  width: 100%;
}

th {
  text-align: left;
}

tr {
  border-bottom: 1px solid var(--background-color-2);
}
