@font-face {
  font-family: DepartureMono-Regular;
  src: url(/fonts/DepartureMono-Regular.otf);
}
@font-face {
  font-family: Galmuri7;
  src: url(/fonts/Galmuri7.ttf);
}
@font-face {
  font-family: Galmuri9;
  src: url(/fonts/Galmuri9.ttf);
}
@font-face {
  font-family: '04B_19';
  src: url(/fonts/04B_19__.ttf);
}

* {
  box-sizing: border-box;
}

html {
  height: 100%;
  margin: 0;
  font-family: Galmuri9;
  font-size: 15px;
  background-color: #ACACAB;
  opacity: 0.8;
  background-size: 10px 10px;
  background-image:  repeating-linear-gradient(0deg, #B9B9B9, #B9B9B9 1px, #ACACAB 1px, #ACACAB);
}

body {
  width: 100%;
  height: 100%;
  max-width: 800px;
  margin: auto;

  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

body > img {
  position: absolute;
  bottom: -45px;
  height: 30px;
  right: 15px;
}

button, input[type="submit"], input[type="reset"] {
	background: none;
	color: inherit;
	border: none;
	padding: 0;
	font: inherit;
	cursor: pointer;
	outline: inherit;
}

nav {
  display: flex;
  flex-shrink: 0;
  flex-wrap: wrap;
}

a.nav-button {
  color: inherit;
  display: inline-block;
  flex-grow: 1;
}

.nav-button button {
  width: 100%;
  color: inherit;
  text-decoration: none;
  border: 2px solid #696969;
  padding: 4px 10px;
  font-size: 20px;
  background: linear-gradient(0deg, #E4E4E4, white);
  opacity: 1;

  &:hover {
    background: white;
  }
}

.nav-button.lg-button {
  height: 5rem;
  flex-grow: 0;
  text-decoration: none;
}

.nav-button.lg-button button {
  height: 100%;
  padding: 0 2rem;

  &:has(img) {
    padding-left: 0.25rem;
    padding-right: 1.75rem;
    display: flex;
    align-items: center;
    gap: 2rem;
  }
}

.nav-button.lg-button button img {
  height: 4.25rem;
  width: 4.25rem;
  border: 2px solid #00000050;
  background: #00000005;
  padding: 0.25rem;
}

.nav-button.lg-button button span {
  flex-grow: 1;
  width: 100%;
}

.page-nav {
  display: flex;
  width: 100%;
  justify-content: space-between;
  margin-bottom: 1rem;
}

.page-nav a {
  flex-grow: 0;
}

header {
  flex-shrink: 0;
}

header .header-bar {
  position: relative;
  display: flex;
  align-items: center;
  height: 32px;
  width: 100%;
  max-width: 800px;
  padding-left: 8px;
  background-image: url("/images/header.png");
  background-position: right;
  color: white;
}

header .site-title {
  text-decoration: none;
  color: white;
  max-width: calc(100% - 162px);
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

header .header-time {
  position: absolute;
  right: 98px;
  width: 61px;
  text-align: center;
}

header * {
  transform: translateY(-1px);
}

#content {
  background-image: url("/images/bg.png");
  display: flow-root;
  flex: 1;
  padding: 1rem;
  overflow-y: auto;
  position: relative;
}

.section-header {
  font-weight: bold;
  width: 100%;
  display: block;
  background: linear-gradient(0deg, #c6c4c4, #f7f7f7);
  border: 2px solid #696969;
  padding: 0.25rem 0.75rem;
  margin-bottom: 1rem;
  font-size: 18px;
}

article {
  display: flex;
  flex-direction: column;
  position: relative;
  border: 2px solid #696969;
  border-radius: 16px;
  background: white;
  overflow: hidden;
}

article:not(:last-child) {
  margin-bottom: 1rem;
}

article .title {
  width: fit-content;
  border: 2px solid #696969;
  border-radius: 0 0 16px 0;
  position: relative;
  top: -2px;
  left: -2px;
  padding: 0.25rem 1rem;
  font-weight: bold;
  background: lightskyblue;
  color: black;
  text-decoration: none;
}

article a.title:hover {
  text-decoration: underline;
}

article .subtitle {
  display: flex;
  align-items: center;
  gap: 0.5rem;

  margin-top: -3px;
  margin-bottom: 10px;
}

article .publish-date {
  display: block;
  font-family: Galmuri7;
  font-size: 12px;
}

article .tag-list {
  font-family: Galmuri7;
  display: flex;
  gap: 0.25rem;
}

article .tag {
  font-family: Galmuri7;
  font-size: 11px;
  color: #262626;
  text-decoration: none;
  border: 2px solid #262626;
  padding: 0 3px;

  &:hover {
    color: #696969;
    border-color: #696969;
  }
}

article .content {
  display: block;
  padding: 0.75rem;
}

article .content figure {
  margin: 0;
}

article .content figcaption {
  font-family: Galmuri7;
  font-size: 11px;
  color: #696969;
}

article .content p {
  margin-top: 0;
  margin-bottom: 1rem;
}

article .content img {
  max-width: 100%;
}

.comms-list {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2rem;
}

.comms-gallery {
  display: flex;
  justify-content: center;
  gap: 1rem;
  align-items: center;
  margin-top: 2rem;
  margin-bottom: 2rem;
}

.comms-thumb img {
  height: 200px;
  width: 200px;
  object-fit: cover;
  border: 2px solid #696969;
  margin-top: 0.5rem;
}

@media (min-width: 801px) {
  html {
    display: flex;
  }

  body {
    max-height: 670px;

    box-sizing: initial;
    border-top: 12px solid #e1e1e1;
    border-right: 12px solid #c6c6c6;
    border-bottom: 60px solid #e1e1e1;
    border-left: 12px solid #c6c6c6;
  }

  .comms-list {
    flex-wrap: wrap;
  }
}

@media (max-width: 800px) {
  body {
    max-width: unset;
    overflow: hidden;
  }

  body > img {
    display: none;
  }

  nav .nav-button button {
    height: 50px;
  }

  .comms-list {
    flex-direction: column;
    width: 100%;
  }

  .comms-list .lg-button {
    width: 100%;
  }

  .comms-gallery {
    flex-direction: column;
  }

  article .title {
    width: calc(100% + 4px);
    border-radius: 0;
  }
}

@keyframes fade-in {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.anim-fade-in {
  animation: 0.5s 1 ease fade-in;
}
