* {
  box-sizing: border-box;
}

:root {
  --logo-primary: #888bff;
  --logo-primary-dark: #7e6dd7;
  --logo-secondary: #fffd96;
  --logo-secondary-dark: #e0c880;

  --background: #1e2122;

  --primary-100: #e3e3ff;
  --primary-200: #aaacff;
  --primary-300: #7175ff;
  --primary-400: #393eff;
  --primary-500: #0006ff;
  --primary-600: #0005c6;
  --primary-700: #00048e;
  --primary-800: #000255;
  --primary-900: #00011c;

  --text: white;
  --text-subtle: #ddd;

  /* generated with ../scripts/gpl-to-css.sh */
  --colour-walo-taso: #ffffff;
  --colour-kiwen-walo: #dddddd;
  --colour-kiwen: #888888;
  --colour-pimeja-lili: #5a5a5a;
  --colour-kiwen-pimeja: #333333;
  --colour-pimeja-taso: #000000;

  --colour-unu-walo: #ccccff;
  --colour-unu-pimeja: #3333cc;

  --colour-jelo-walo: #ffffaa;
  --colour-jelo-pimeja: #665500;

  --colour-loje-walo: #ffcccc;
  --colour-loje-pimeja: #aa1111;

  --colour-laso-walo: #aaeedd;
  --colour-laso-pimeja: #114444;

  /* blobby heading titles */
  /* using https://codepen.io/ShadowShahriar/pen/BaKdyMJ */
  --blob-border-radius-01: 25% 75% 50% 50% / 66% 55% 45% 34%;
  --blob-border-radius-02: 70% 30% 59% 41% / 64% 46% 54% 36%;
  --blob-border-radius-03: 49% 51% 68% 32% / 59% 45% 55% 41%;
  --blob-border-radius-04: 40% 60% 68% 32% / 72% 50% 50% 28%;
}

@font-face {
  font-family: "Bogface", sans-serif;
  src: url("/fonts/Bogface.woff");
}

@font-face {
  font-family: "sitelen seli kiwen";
  src: url("/fonts/sitelenselikiwen/sitelenselikiwenasuki.eot");
  src: url("/fonts/sitelenselikiwen/sitelenselikiwenasuki.ttf")
    format("truetype");
}

html,
body {
  margin: 0;
  padding: 0;
  color: var(--text);
  font-family: "Andika", sans-serif;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  position: relative;
}

body {
  background-color: var(--background);
}

h2,
h3,
h4,
h5,
h6 {
  font-family: "Bricolage Grotesque", sans-serif;
}

.poki-insa {
  align-self: center;
  display: flex;
  flex-direction: column;
  justify-content: center;
  max-width: 60rem;
  padding: 0 2rem;
  width: 100%;
}

header {
  align-items: flex-start;
  display: flex;
  flex-flow: row wrap;
  font-family: "Bricolage Grotesque", sans-serif;
  justify-content: space-evenly;
  margin-top: 3rem;
}
header #banner {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  background-image: url("/banner.jpg");
  background-size: cover;
  background-position: center;
  z-index: -5;
  background-color: var(--background);
}
header .sewi-lipu {
  align-items: center;
  display: flex;
  margin: 0 4rem 1.5rem 1.5rem;
}
header .logo {
  width: 5rem;
  height: auto;
}
header h1 {
  font-size: 2rem;
  margin: 0 0 0.2rem 1rem;
  text-align: left;
}
header h1 a {
  color: white;
  text-decoration: none;
}
header .subtitle {
  font-size: 1.4rem;
  font-weight: bold;
  margin: 0 0 0.5rem 1rem;
}
header .subtitle a {
  color: var(--colour-kiwen);
  text-decoration: none;
}
header .subtitle a:hover {
  text-decoration: underline;
}
header nav ul {
  align-items: flex-start;
  display: flex;
  flex-wrap: wrap;
  list-style: none;
  margin: 0;
  padding: 0;
}
header nav {
  margin: 1rem 0.5rem 0 0;
}
header nav li {
  line-height: 1;
  position: relative;
  top: -1.5rem;
}
header nav li a {
  padding: 1.5rem;
  display: block;
  border-radius: var(--blob-border-radius-02);
}
header nav li.active a {
  background-color: var(--colour-unu-walo);
}
header nav li.active a {
  color: var(--primary-700);
}
header nav li.active .sitelen-tu::before {
  color: var(--primary-700);
}
header nav a {
  color: white;
  font-size: 1.4rem;
  text-align: left;
  text-decoration: none;
}
.sitelen-tu::before {
  color: var(--primary-200);
  content: attr(data-text);
  display: inline-block;
  font-family: "sitelen seli kiwen", sans-serif;
  margin-right: 0.5rem;
  text-align: center;
  width: 1.5rem;
}
.sitelen-tu {
  display: block;
}
header nav a:hover .sitelen-tu {
  text-decoration: underline;
}

hr.anpa-sewi {
  background-color: var(--colour-pimeja-lili);
  height: 4px;
  border-width: 0;
  border-bottom: 2px solid black;
  margin: 0 0 1rem;
}

main {
  padding: 0 0 1rem 0;
  flex-grow: 1;
}

main a {
  color: var(--primary-300);
}
main a:hover {
  color: var(--primary-200);
}

footer {
  font-family: "Andika", sans-serif;
  background-color: var(--logo-primary);
  padding: 1rem;
  margin-top: auto;
  position: relative;
  display: flex;
  justify-content: center;
}
footer section {
  padding: 0.5rem;
}
footer::before {
  content: "";
  width: 100%;
  height: 5rem;
  background-image: url("/texture_bumps_homepage.svg");
  background-size: auto;
  background-repeat: repeat-x;
  background-position: bottom;
  position: absolute;
  top: calc(-5rem + 1px);
  pointer-events: none;
}
footer a {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  margin: 0.5rem;
}
footer a img.icon {
  height: 2rem;
  width: auto;
  filter: invert(100%) sepia(7%) saturate(0%) hue-rotate(112deg)
    brightness(106%) contrast(109%);
}
footer a {
  font-family: "BogFace", sans-serif;
  color: white;
  text-decoration: none;
  font-size: 1.2rem;
  text-align: center;
}
footer a:hover {
  text-decoration: underline;
}

footer > section {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr 1fr;
  grid-template-areas:
    "linktree github licence email"
    "discord patreon licence form";
  align-items: center;
  justify-content: center;
}
footer .discord {
  grid-area: discord;
}
footer .linktree {
  grid-area: linktree;
}
footer .github {
  grid-area: github;
}
footer .patreon {
  grid-area: patreon;
}
footer .email {
  grid-area: email;
}
footer .form {
  grid-area: form;
}
footer .licence {
  max-width: 15rem;
  margin: auto 0.5rem;
  text-align: justify;
  grid-area: licence;
}

@media screen and (max-width: 900px) {
  footer > section {
    grid-template-columns: 1fr 1fr;
    grid-template-areas:
      "linktree licence"
      "discord licence"
      "github email"
      "patreon form";
  }
  @media screen and (max-width: 500px) {
    footer > section {
      grid-template-columns: 1fr;
      grid-template-areas: "linktree" "discord" "github" "patreon" "licence" "email" "form";
    }
  }
}

.sitelen-pona {
  font-family: "sitelen seli kiwen", sans-serif;
}
