:root {
  --home-app-grid-size: 300px;
  --home-chatbox-background: rgba(128, 128, 128, 0.4);

  --portrait-height: 70vh;
  --portrait-viewbox-width: 617;
  --portrait-viewbox-height: 800;
}
.home {
  width: 100vw;
}

@keyframes home-content-portrait-stroke-offset {
  to {
    stroke-dashoffset: 0;
  }
}

/* #region content */
.home-content-nexus {
  position: fixed;
  bottom: 15px;
  left: 20px;
  height: 40px;
  z-index: 250;
}
.home .nexusButton-icon svg {
  fill: #777;
}
.home .nexusButton-icon:hover svg {
  fill: white;
}
.home .nexusButton-menu-button svg {
  stroke: #777;
  fill: #777;
}
.home .nexusButton-menu-button:hover svg {
  stroke: white;
  fill: white;
}
.home-content-head {
  position: fixed;
  z-index: 150;
  left: calc(50vw - 5vw);
  transform: translateX(-100%);
  display: flex;
  flex-direction: column;
  justify-content: end;
  align-items: center;
  height: 100vh;
  width: calc(
    var(--portrait-height) / var(--portrait-viewbox-height) *
      var(--portrait-viewbox-width)
  );
}
.home-content-chatbox {
  /* text will overflow if word is too long */
  position: relative;
  margin-bottom: 30px;
  padding: 20px 30px;
  width: max-content;
  max-width: 100%;
  border-left: 2px solid white;
  border-right: 2px solid white;
  background-color: var(--home-chatbox-background);
  color: white;
  font-size: 20px;
  text-align: center;
  white-space: pre-wrap;
}
.home-content-chatbox::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translate(-50%, 100%) scaleX(0.7);
  border-width: 20px;
  border-style: solid;
  border-color: var(--home-chatbox-background) transparent transparent
    transparent;
}
.home-content-portrait {
  bottom: 0;
  height: var(--portrait-height);
  filter: brightness(90%);
}
.home-content-portrait svg {
  filter: drop-shadow(0 0 8px black);
}
.home-content-apps {
  position: absolute;
  z-index: 200;
  left: calc(50vw + 5vw);
  padding: calc(50vh - var(--home-app-grid-size) / 2) 0;
}
.home-content-apps table {
  border-collapse: collapse;
  border-spacing: 0;
}
.home-content-apps td {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: var(--home-app-grid-size);
  height: var(--home-app-grid-size);
  padding: 0;
}
/* .home-content-apps tr:nth-child(even) td {
  background-color: blue;
}
.home-content-apps tr:nth-child(odd) td {
  background-color: red;
} */

.home-content-app {
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #aaa;
  background-color: white;
  transition: box-shadow 0.3s;
}
.home-content-app:hover {
  box-shadow: 3px 3px 15px rgba(255, 255, 255, 0.7),
    3px -3px 15px rgba(255, 255, 255, 0.7),
    -3px 3px 15px rgba(255, 255, 255, 0.7),
    -3px -3px 15px rgba(255, 255, 255, 0.7);
}

.home-content-app img {
  width: 100%;
}

.home-content-bottomFrame {
  pointer-events: none;
}
.home-content-bottomFrame > svg {
  position: fixed;
  bottom: 0;
  left: 0;
  z-index: 200;
  width: 100%;
  height: 150px;
  fill: #272f3c;
}
/* #endregion */

/* #region background */
.home-background {
  position: fixed;
  z-index: 100;
  width: 100vw;
  height: 100vh;
  display: flex;
  /* justify-content: center; */
  justify-content: start;
  flex-direction: row-reverse;
  /* background-color: black; */
  background-color: #0f1419;
  overflow: hidden;
}

.home-background-title,
.home-background-title-focus {
  writing-mode: vertical-rl;
  text-orientation: sideways-right;
  font-weight: bold;
  font-size: 180px;
  white-space: nowrap;
  color: white;
  margin: 0 20px;
  opacity: 0.1;
  transition: margin 0.5s, font-size 0.5s;
}
.home-background-title-focus {
  text-orientation: sideways;
  margin-top: 20vh;
  font-size: 230px;
  color: #f59e0b;
  opacity: 0.17;
}
.home-background-focused-title {
  position: fixed;
  bottom: 30px;
  right: 50px;
  font-size: 300px;
  font-weight: bold;
  white-space: nowrap;
  color: white;
  opacity: 0.7;
}
/* #endregion */

/* #region nexus button basic */
.nexusButton {
  position: relative;
  cursor: pointer;
}
.nexusButton,
.nexusButton-icon,
.nexusButton-icon svg {
  height: 100%;
}

.nexusButton-menu-close,
.nexusButton-menu-open {
  position: absolute;
  display: flex;
  align-items: center;
  transition: 0.2s;
}

.nexusButton-menu-close {
  visibility: hidden;
  opacity: 0;
}
.nexusButton-menu-open {
  visibility: visible;
  opacity: 1;
}

.nexusButton-menu-right,
.nexusButton-menu-left {
  flex-direction: row;
  height: 90%;
  top: 50%;
  transform: translateY(-50%);
}
.nexusButton-menu-top,
.nexusButton-menu-bottom {
  flex-direction: column;
  width: 90%;
  left: 50%;
  transform: translateX(-50%);
}
.nexusButton-menu-right .nexusButton-menu-button,
.nexusButton-menu-left .nexusButton-menu-button {
  height: 70%;
}
.nexusButton-menu-right .nexusButton-menu-button svg,
.nexusButton-menu-left .nexusButton-menu-button svg {
  height: 100%;
}
.nexusButton-menu-top .nexusButton-menu-button,
.nexusButton-menu-bottom .nexusButton-menu-button {
  width: 70%;
}
.nexusButton-menu-top .nexusButton-menu-button svg,
.nexusButton-menu-bottom .nexusButton-menu-button svg {
  width: 100%;
}
/* .nexusButton-menu-top {
  padding-bottom: 5px;
  bottom: 100%;
} */
.nexusButton-menu-right {
  padding-left: 5px;
  left: 100%;
}
.nexusButton-menu-bottom {
  padding-top: 5px;
  top: 100%;
}
.nexusButton-menu-left {
  padding-right: 5px;
  right: 100%;
}
/* .nexusButton-menu-close.nexusButton-menu-top {
  bottom: 50%;
} */
.nexusButton-menu-close.nexusButton-menu-right {
  left: 50%;
}
.nexusButton-menu-close.nexusButton-menu-bottom {
  top: 50%;
}
.nexusButton-menu-close.nexusButton-menu-left {
  right: 50%;
}
/* #endregion */
