/***********************************************************
  1. GLOBAL (no scroll, full viewport)
************************************************************/
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  font-family: sans-serif;
}

/***********************************************************
  2. HOME
************************************************************/
#home {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  height: 100vh;
  height: -webkit-fill-available;
  height: 100dvh;
}

@supports (padding: env(safe-area-inset-top)) {
  #home {
    padding-top: env(safe-area-inset-top);
    padding-bottom: env(safe-area-inset-bottom);
    padding-left: env(safe-area-inset-left);
    padding-right: env(safe-area-inset-right);
  }
}

#home .half {
  height: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
  cursor: pointer;
  text-decoration: none;
}
#home .top {
  background: black;
  color: white;
  z-index: 1;
}
#home .bottom {
  background: white;
  color: black;
  z-index: 1;
}

#home .side-text {
  position: absolute;
  font-size: 1.2rem;
  writing-mode: vertical-rl;
  text-orientation: mixed;
  font-weight: bold;
  text-decoration: underline;
  text-transform: lowercase;
  letter-spacing: 0;
}
#home .side-text.top { right: 10px; }
#home .side-text.bottom { left: 10px; }

#home .center-content {
  text-align: center;
}
#home .center-content h1 {
  font-size: 8rem;
  transition: color 0.3s ease;
}
#home .center-content p {
  font-size: 1rem;
  text-transform: uppercase;
}

.error-message {
  position: absolute;
  top: 1rem;
  width: 100%;
  color: red;
  text-align: center;
  font-weight: bold;
  z-index: 5;
}

/* Progress bar (top) */
.progress-container {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 0.7rem;
  z-index: 10;
}
.bar {
  width: 0;
  height: 100%;
  background-color: gold;
  transition: width 0.2s ease;
}

/***********************************************************
  3. STATION
************************************************************/
#station {
  position: relative;
  overflow: hidden;
  height: 100vh;
  height: -webkit-fill-available;
  height: 100dvh;
}
@supports (padding: env(safe-area-inset-top)) {
  #station {
    padding-top: env(safe-area-inset-top);
    padding-bottom: env(safe-area-inset-bottom);
    padding-left: env(safe-area-inset-left);
    padding-right: env(safe-area-inset-right);
  }
}

#station .header {
  text-align: center;
  padding-top: 2em;
}

.parent {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  grid-template-rows: repeat(3, 1fr);
  grid-column-gap: 0px;
  grid-row-gap: 0px;
}
.left {
  padding-left: 2em;
  display: flex;
  align-items: center;
}
.right {
  text-align: right;
  padding-right: 2em;
}
.bus {
  display: block;
  height: 60px;
  width: 60px;
  line-height: 60px;
  border-radius: 50%;
  text-align: center;
}

.time {
  font-size: 5rem;
  font-weight: bold;
}
.otherstation-1 .time {
  font-size: 3rem;
}
.otherstation-2 .time {
  font-size: 3rem;
}

.min {
  text-transform: uppercase;
  letter-spacing: 5px;
  font-weight: normal;
}

.other-stations {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  grid-template-rows: repeat(2, 1fr);
  grid-column-gap: 2rem;
  grid-row-gap: 0px;
}

/* Center headings both horizontally & vertically */
.otherstation-head-1 {
  grid-area: 1 / 1 / 2 / 2;
  display: flex;
  align-items: flex-start;
  justify-content: center;
}
.otherstation-head-2 {
  grid-area: 1 / 2 / 2 / 3;
  display: flex;
  align-items: flex-start;
  justify-content: center;
}

/* Remove default h2 spacing */
.otherstation-head-1 h2,
.otherstation-head-2 h2 {
  margin-top: 2em;
  padding: 0;
  line-height: 1.2;
  text-align: center;
}

.otherstation-1 {
  grid-area: 2 / 1 / 3 / 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  font-size:.5em;
}
.otherstation-2 {
  grid-area: 2 / 2 / 3 / 3;
  display: flex;
  flex-direction: column;
  align-items: center;
  font-size:.5em;
}
.gray { color: #999; }

.button-parent {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  position: absolute;
  bottom: 0;
  height: 6rem;
  width: 100%;
}
.button-1, .button-2 {
  display: flex;
  align-items: center;
  justify-content: center;
}
.button-2 { background-color: gold; }
.button-1 a, .button-2 a {
  display: block;
  width: 100%;
  height: 100%;
  text-align: center;
  line-height: 6rem;
  text-transform: uppercase;
  letter-spacing: 5px;
  font-weight: bold;
  text-decoration: underline;
}

/***********************************************************
  4. WORDLE
************************************************************/
#wordle {
  position: relative;
  overflow: hidden;
  height: 100vh;
  height: -webkit-fill-available;
  height: 100dvh;
}
@supports (padding: env(safe-area-inset-top)) {
  #wordle {
    padding-top: env(safe-area-inset-top);
    padding-bottom: env(safe-area-inset-bottom);
    padding-left: env(safe-area-inset-left);
    padding-right: env(safe-area-inset-right);
  }
}
#wordle .header {
  text-align: center;
  padding-top: 2em;
}

.wordle-parent {
  display: grid;
  grid-template-columns: repeat(5, 2.5em);
  grid-template-rows: repeat(6, 2.5em);
  grid-column-gap: 16px;
  grid-row-gap: 16px;
  margin: 1em auto;
  width: 100%;
  justify-content: center;
  flex: 1;
  margin-bottom: 1em;
}
.letter {
  font-size: 2em;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #000;
}

.green { background-color: darkseagreen; }
.yellow { background-color: gold; }
.lightgray { background-color: #999; }

#wordle-station-time {
  font-size: 1.1em;
  text-align: center;
  font-weight: bold;
  margin-bottom: 1em;
}
#wordle-message {
  min-height: 1.5em;
  text-align: center;
  font-size: 1.2em;
  margin-bottom: 1em;
  color: gold;
}
#wordle-show-keyboard {
  position: fixed;
  top: 1rem;
  right: 1rem;
  width: 2rem;
  height: 2rem;
  padding: 0;
  background: transparent;
  border: none;
  cursor: pointer;
  display: none;
  color: inherit;
}

#wordle-show-keyboard svg {
  width: 100%;
  height: 100%;
  display: block;
}

.button-3 {
  position: absolute;
  bottom: 0;
  width: 100%;
  background-color: gold;
}
.button-3 a {
  display: block;
  width: 100%;
  height: 100%;
  text-align: center;
  line-height: 6rem;
  color: #000 !important;
  text-transform: uppercase;
  letter-spacing: 5px;
  font-weight: bold;
  text-decoration: underline;
}


/* Centered at bottom, identical style to .button-3 maybe */
.keyboard {
  background-color: #999;
  color: #777;
  padding: 1em;
  margin-top: 1em;
}
.button-holder {
  text-align: center;
}

/***********************************************************
  5. GLOBAL LINKS + THEME
************************************************************/
a {
  color: gold;
  text-decoration: underline;
  -webkit-tap-highlight-color: transparent;
}

.black-theme {
  background-color: #000;
  color: #fff;
}
.black-theme .progress-container {
  background-color: #999;
}
.black-theme .letter {
  border: 1px solid #fff;
}
.black-theme .bus {
  border: 1px solid #fff;
}
.black-theme a {
  color: #000;
}
.black-theme h2 a {
  color: #999;
  text-transform: lowercase;
  letter-spacing: 0;
}
.black-theme .button-parent {
  background-color: #fff;
  color: #000;
}

.white-theme {
  background-color: #fff;
  color: #000;
}
.white-theme .progress-container {
  background-color: #ccc;
}
.white-theme .letter {
  border: 1px solid #000;
}
.white-theme .bus {
  border: 1px solid #000;
}
.white-theme a {
  color: #fff;
}
.white-theme h2 a {
  color: #999;
  text-transform: lowercase;
  letter-spacing: 0;
}
.white-theme .button-parent {
  background-color: #000;
  color: #fff;
}
.white-theme .button-2, .white-theme .button-2 a {
  color: #000 !important;
}

.gray { color: #999; }
