/* ==========================
   Base & Resets
========================== */

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  overscroll-behavior-x: none;
  overflow: hidden;
}

body {
  font-family: 'Stint Ultra Condensed', cursive;
  color: #e6d8b4;
  height: calc(var(--vh, 1vh) * 100);
  width: 100vw;
  margin: 0;
}

main {
  padding: 1rem 1.5rem .5rem 1.5rem;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
}

[data-page="gallery"] main {
  padding-bottom: 0 !important;
}

/* ==========================
   Responsive Headings
========================== */

.portrait { display: none; }

@media (orientation: portrait) {
  .landscape { display: none; }
  .portrait { display: block; }
}


/* ==========================
   Page Layout
========================== */

.pages {
  flex-grow: 1;
  justify-self: flex-start;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  position: relative;
}

.page {
  flex-grow: 1;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease;
  width: 100%;
  display: none;
  flex-direction: column;
  justify-content: flex-start;
  position: absolute;
  top: 0;
  bottom: 0;
}

.page.active {
  opacity: 1;
  pointer-events: auto;
}


/* ==========================
   Navigation
========================== */

nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 2rem;
  background: rgba(0, 0, 0, 0.4);
  width: 100%;
  z-index: 10;
}

nav ul {
  display: flex;
  gap: 2rem;
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: 1rem;
  line-height: 1rem;
}

nav ul li a {
  text-decoration: none;
  color: #e6d8b4;
  font-weight: bold;
  letter-spacing: 1.5px;
  text-transform: uppercase;
}

nav ul li a .link-arrow {
  display: none;
}

nav ul li a.active {
  border-bottom: 1px #e6d8b4 solid;
}

@media (orientation: portrait) {
  nav {
    flex-direction: column;
    align-items: flex-end;
    padding: .5rem .1rem 1rem .5rem;
    text-align: right;
  }

  nav ul {
    flex-direction: column;
    gap: 0.5rem;
  }

  nav ul li a {
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
    width: 100%;
    font-size: 1rem;
    line-height: 1rem;
  }

  nav ul li a.active {
    border-bottom: 0px;
  }

  nav ul li a .link-arrow {
    display: inline-block;
    align-items: center;
    justify-content: center;
    padding-left: .3rem;
    visibility: hidden;
    font-size: .8rem;
  }

  nav ul li a.active .link-arrow {
    visibility: visible;
  }
}


/* ==========================
   Loader
========================== */

.loader {
  position: fixed;
  inset: 0;
  background: #0d0d0d;
  z-index: 9999;
  display: flex;
  justify-content: center;
  align-items: center;
  transition: opacity 0.4s ease;
}

.loader .mjolnir {
  width: 80px;
  height: 80px;
  animation: loader-mjolnir-spin 1.5s linear infinite;
  transform-origin: 50% 50%;
  fill: #e6d8b4;
}

@keyframes loader-mjolnir-spin {
  0%   { transform: rotate(0deg) scale(1); }
  50%  { transform: rotate(180deg) scale(1.05); }
  100% { transform: rotate(360deg) scale(1); }
}

/* ==========================
   General Page Layout (index)
========================== */

body {
  background: url('/img/main-background.jpg') no-repeat right top fixed;
  background-size: cover;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
}

@media (max-aspect-ratio: 3/2) {
  body {
    background: url('/img/main-background.jpg') no-repeat 90% top fixed;
    background-size: cover;
  }
}

main h1 {
  display: block;
  justify-self: flex-start;
  font-size: 3rem;
}

main .content {
  display: flex;
  flex-direction: row;
  align-items: stretch;
  width: 100%;
  padding-top: 1rem;
}

.availableHeight {
  flex-grow: 1;
  min-height: 0;
  height: 100%;
}

@media (orientation: portrait) {
  body {
    flex-direction: column-reverse;
  }
  h1 {
    background: rgba(0, 0, 0, 0.4);
    width: 100%;
    padding: .5rem 1rem;
    font-size: 1.7rem;
    text-align: center;
  }
  main {
    padding: .5rem;
  }
  main .content {
    padding-top: 0;
  }
}
