@font-face {
  font-family: "CMU Typewriter";
  src: url("/assets/fonts/cmuntt.ttf") format("truetype");
  font-display: swap;
}

:root {
  color-scheme: dark;
  font-family: "CMU Typewriter", ui-monospace, monospace;
  background: #0c0b09;
  color: #e2d9c6;
}

* {
  box-sizing: border-box;
}

html,
body {
  width: 100%;
  min-height: 100%;
  margin: 0;
  background: #0c0b09;
}

body {
  overflow: hidden;
}

#poolrooms {
  position: fixed;
  inset: 0;
  z-index: 2;
  display: block;
  width: 100%;
  height: 100%;
  opacity: 0;
  outline: none;
  touch-action: none;
  transition: opacity 260ms ease;
}

#fallback {
  position: relative;
  z-index: 1;
  width: min(808px, calc(100% - 48px));
  margin: 0 auto;
  padding: 24px 0 32px;
  transition: opacity 180ms ease;
}

.masthead,
.portal {
  border: 1px solid #4e4230;
  border-radius: 2px;
}

.masthead {
  margin-bottom: 30px;
  padding: 20px 22px;
  background: #241e16;
  border-color: #8e7d64;
}

.masthead h1 {
  margin: 8px 0 4px;
  color: #ebc597;
  font-size: clamp(2rem, 7vw, 2.65rem);
  letter-spacing: 0.025em;
}

.masthead p:last-child {
  margin: 0;
  font-size: 0.93rem;
}

nav {
  display: grid;
  gap: 12px;
}

.portal {
  display: grid;
  gap: 7px;
  padding: 15px 18px;
  color: inherit;
  background: #110f0c;
  text-decoration: none;
  transition: border-color 100ms ease, background 100ms ease;
}

.portal:hover,
.portal:focus-visible {
  background: #241e16;
  border-color: #8e7d64;
  outline: none;
}

.portal strong {
  color: #e2d9c6;
  font-size: 1.08rem;
}

.portal > span:not(.eyebrow) {
  color: #9e9380;
  font-size: 0.82rem;
  line-height: 1.45;
}

.portal b {
  margin-top: 4px;
  color: #ebc597;
  font-size: 0.78rem;
}

.eyebrow,
footer {
  margin: 0;
  color: #9e9380;
  font-size: 0.7rem;
  letter-spacing: 0.08em;
}

footer {
  margin-top: 34px;
  text-align: center;
}

#status {
  position: fixed;
  z-index: 3;
  right: 16px;
  bottom: 12px;
  color: #a98556;
  font-size: 0.67rem;
  letter-spacing: 0.1em;
  pointer-events: none;
  transition: opacity 180ms ease;
}

.noscript {
  position: fixed;
  right: 16px;
  bottom: 28px;
  z-index: 3;
  color: #a98556;
  font-size: 0.72rem;
}

html[data-poolrooms="ready"] #poolrooms {
  opacity: 1;
}

html[data-poolrooms="ready"] #fallback,
html[data-poolrooms="ready"] #status {
  opacity: 0;
  pointer-events: none;
}

html[data-poolrooms="failed"] #status {
  color: #d29a72;
}

html[data-poolrooms="reduced"] #status {
  opacity: 0;
}

@media (max-height: 720px) and (min-width: 700px) {
  #fallback {
    padding-top: 16px;
  }

  .masthead {
    margin-bottom: 16px;
    padding-block: 14px;
  }

  nav {
    gap: 8px;
  }

  .portal {
    padding-block: 10px;
  }

  footer {
    margin-top: 16px;
  }
}

@media (max-width: 560px) {
  body {
    overflow-y: auto;
  }

  #fallback {
    width: min(100% - 24px, 808px);
    padding-top: 12px;
  }

  .masthead {
    margin-bottom: 12px;
    padding: 18px 16px;
  }

  .portal {
    padding: 14px;
  }

  footer {
    margin: 22px 12px 0;
    line-height: 1.5;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}
