:root {
  --background-1: #ffffff;
  --background-2: #dddddd;
  --background-3: #333333;
  --foreground-1: #333333;
  --foreground-2: #111111;
  --foreground-3: #ffffff;
  --blue-1: #4acdff;
  --blue-2: #00a0dd;
  --blue-3: #0078a6;
  --green-1: #aad58a;
  --green-2: #77bc43;
  --green-3: #598230;
  --orange-1: #f9c971;
  --orange-2: #f5a81c;
  --orange-3: #A16B08;
  --red-1: #f97171;
  --red-2: #f51c1c;
  --red-3: #c40909;
}

body {
  background: var(--background-2);
  color: var(--foreground-2);
  font-family: "Montserrat", sans-serif;
  text-align: center;
  line-height: 1.25;
}

h1,
h2,
h3 {
  font-family: "Roboto Slab", serif;
  margin: 0.5em;
}

a {
  color: var(--blue-1);
}

p {
  line-height: 1.3;
  margin: 0.5em;
}

@font-face {
  font-family: "icomoon";
  src: url(../fonts/icomoon.ttf);
}

.fonticon {
  font-family: "icomoon";
}

header {
  background: var(--blue-3);
  color: var(--foreground-3);
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1rem;
}

header img {
  max-width: 96px;
  margin: 16px 0 0 16px;
  align-self: flex-end;
}

header > div {
  text-align: left;
}

header > div > * {
  margin: 0.5rem 0;
}

header h1 {
  font-size: 1.5rem;
}

header button {
  appearance: none;
  border: none;
  font-size: 3rem;
  margin-left: auto;
  align-self: stretch;
  background: inherit;
  color: inherit;
  padding: 0 0.25em;
}

header button:hover {
  background: var(--blue-2);
}

header button.open {
  background: var(--orange-3);
  color: var(--foreground-3);
}

nav.hidden {
  display: none;
}

nav {
  background: var(--orange-3);
  color: var(--foreground-3);
  border-bottom: 4px solid var(--blue-3);
}

nav ul {
  padding: 0;
  margin: 0;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

nav ul li {
  list-style-type: none;
  text-align: center;
  width: 100%;
}

nav ul li a {
  display: block;
  width: 100%;
  color: inherit;
  text-decoration: none;
  padding: 0.5em 0;
}

nav ul li a:hover {
  color: var(--foreground-2);
  background-color: var(--orange-2);
}

nav ul li.current a {
  font-weight: bold;
  color: var(--foreground-1);
  background-color: var(--orange-1);
}

main > h2 {
  margin: 1em auto;
}

section {
  margin: 0.5em auto;
  padding: 0.5em;
}

section.col-w {
  background: var(--background-1);
  color: var(--foreground-1);
}

section.col-x {
  background: var(--background-3);
  color: var(--foreground-3);
}

section.col-b {
  background: var(--blue-3);
  color: var(--foreground-3);
}

section.col-g {
  background: var(--green-3);
  color: var(--foreground-3);
}

section.col-o {
  background: var(--orange-3);
  color: var(--foreground-3);
}

section[class*="col-"] a {
  color: var(--foreground-2);
}

section.col-w a {
  color: var(--blue-3);
}

section.col-x a {
  color: var(--blue-1);
}

section.left p,
section.left ul,
section.left li {
  text-align: left;
}

#home-gallery .grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.5em;
  align-items: center;
  gap: 0.5em;
}

#gallery-main,
#home-gallery .grid > img.thumb {
  display: block;
  width: 100%;
  border-radius: 4px;
}

#gallery-main {
  grid-column: 1/5;
}

#home-gallery img.thumb.current {
  filter: contrast(25%);
}

#home-ads {
  margin: 0;
  padding: 0;
}

#home-ads section {
  margin: 0.5em auto;
  padding: 0.5em;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

#home-ads section a {
  display: block;
  margin-bottom: 1em;
}

#home-ads section img {
  display: block;
  margin: 0 auto;
  width: 100%;
  max-width: 480px;
  border-radius: 4px;
}

#home-events ul {
  text-align: left;
}

#home-events ul li {
  margin: 0.5em auto;
}

#home-weather {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

#home-weather div h2,
#home-weather div p {
  margin: 0.5em;
}

#forecast {
  margin-top: 2em;
  display: flex;
  gap: 2em;
}

#forecast div {
  display: flex;
  flex-direction: column;
}

#hero {
  display: block;
  width: 100%;
}

#hero img {
  display: block;
  width: 100%;
}

#dir-displaymode {
  display: flex;
  justify-content: center;
}

#dir-displaymode img {
  width: 2em;
  padding: 0.5em;
  filter: brightness(75%);
}

#dir-displaymode img:hover {
  filter: brightness(67%);
}

#dir-displaymode .current img {
  filter: brightness(50%);
}

#directory.list {
  display: block;
}

#directory.grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1em;
}

#directory.grid section {
  margin: 0;
}

#directory section {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: center;
  gap: 1em;
}

#directory section > * {
  margin: 0;
  padding: 0;
}

#directory section a:not(:hover) {
  text-decoration: none;
}

#directory section img {
  width: 128px;
  border-radius: 4px;
}

#board-list {
  margin-top: 1.25em;
}

section#join-form,
section#contact-form {
  max-width: 30em;
  margin: 0 auto;
  margin-bottom: 1em;
}

form {
  text-align: left;
}

form > p {
  text-align: center;
  color: var(--red-3);
}

form fieldset {
  border: none;
  /* border-right: 2px solid var(--blue-1);
  border-bottom: 2px solid var(--blue-1); */
  border-radius: 4px;
  margin: 1em 0;
}

form fieldset legend {
  font-weight: bold;
  margin: 1em;
  margin-bottom: 0;
  padding: 0;
}

#level-key-button {
  border-radius: 99px;
  background: var(--background-2);
  color: var(--foreground-2);
  display: inline-block;
  text-align: center;
  padding: 0.3em 0.6em;
}

#level-key-button:hover {
  background: var(--orange-1);
  color: var(--foreground-1);
}

#level-key-button.open {
  background: var(--orange-3);
  color: var(--foreground-3);
}

#level-key {
  display: none;
  background: var(--orange-1);
  color: var(--foreground-1);
  border-radius: 4px;
  padding: 0.5em;
  margin-bottom: 0.5em;
}

#level-key.open {
  display: block;
}

#level-key p {
  font-size: 0.8em;
  margin: 0.5em;
}

form label.above {
  display: block;
  margin: 0.5em 0;
}

form label.above input,
form label.above select,
form label.above textarea {
  display: block;
  width: 100%;
  max-width: 20em;
  padding: 0.5em;
}

form label.side {
  display: block;
  padding: 0.5em 0;
}

form input:required,
form select:required,
form textarea:required {
  box-shadow: 4px 4px var(--red-1);
}

form input:required:valid,
form textarea:required:valid {
  box-shadow: 4px 4px var(--green-1);
}

form input.submit {
  width: 100%;
  padding: 0.5em;
  background: var(--blue-3);
  color: var(--foreground-3);
  border: none;
  border-radius: 4px;
}

form input.submit:hover {
  font-weight: bold;
}

form input.submit:active {
  margin: 2px 0 -2px 0;
}

footer {
  background: var(--background-3);
  color: var(--foreground-3);
  display: grid;
  grid-template-columns: 1fr auto auto 1fr;
  justify-content: center;
  align-items: center;
  gap: 1em;
  padding: 1em;
}

footer .info {
  grid-column: 2;
  text-align: left;
}

footer .social {
  grid-column: 3;
  gap: 0.5em;
}

footer .social a {
  color: inherit;
  text-decoration: none;
  font-size: 32px;
  padding: 0.5em;
}

footer .social a:nth-child(1):hover {
  color: var(--blue-1);
}
footer .social a:nth-child(2):hover {
  color: var(--blue-3);
}
footer .social a:nth-child(3):hover {
  color: var(--blue-1);
}

footer .meta {
  grid-column: 2/4;
}
