/* VARIABLES */
:root {
  --black: #282A36;
  --blue: #8BE9FD;
  --gold: #FFB86C;
  --green: #50FA7B;
  --red: #FF5555;
  --white: #F8F8F2;
  --dark-grey: #565656;
  --light-grey: #7F848E;
}

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

body {
  background-color: var(--black);
  color: var(--white);
  font-family: "Roboto Mono", cursive;
  min-height: 100vh;
  padding: 1rem 1rem 0;
  position: relative;
}

#main-content {
  min-height: 90vh;
  display: flex;
  flex-direction: column;
  justify-content: space-around;
}

/* HEADER */
header {
  margin: 0 auto 2rem;
  text-align: center;
}

header h1 {
  font-size: 3rem;
  margin: 0 auto;
}

#tomato-icon {
  width: 4rem;
  height: 4rem;
  margin: 0.5em auto;
}

/* TIMER CONTAINER */
#timer-container {
  margin: 0 auto;
  position: relative;
  width: 100%;
}

#timer-svg {
  display: block;
  height: 25rem;
  margin: 0 auto;
  transform: scaleX(-1);
  width: 100%;
}

#timer-circle {
  fill: none;
  stroke: none;
}

#timer-circle-bg {
  stroke: var(--light-grey);
  stroke-width: 7px;
}

#timer-circle-remaining {
  stroke: currentColor;
  stroke-linecap: round;
  stroke-width: 7px;
  transform: rotate(90deg);
  transform-origin: center;
  transition: 0.5s linear all;
}

#timer-display-container {
  display: flex;
  align-items: center;
  flex-direction: column;
  justify-content: center;
  font-family: "Major Mono Display", monospace;
  height: 25rem;
  margin: 0 auto;
  position: absolute;
  top: 0;
  width: 100%;
}

#timer-display {
  font-size: 4rem;
}

#session-display {
  font-size: 2rem;
}

#rounds-display {
  font-size: 2rem;
  font-style: italic;
}

/* BUTTONS */
#buttons-container {
  margin: 2rem auto;
  display: flex;
  justify-content: space-around;
  align-items: center;
  flex-wrap: wrap;
  width: 50vw;
}

#play-button,
#reset-button,
#settings-button {
  font-size: 2rem;
  transition: 0.2s linear all;
}

#reset-button {
  color: var(--gold);
}

#settings-button {
  color: var(--blue);
}

#play-button:hover,
#reset-button:hover,
#settings-button:hover {
  cursor: pointer;
  transform: scale(1.1);
}

/* SETTINGS POP-UP */
#settings-container {
  position: absolute;
  top: 50%;
  left: 50%;
  display: none;
  visibility: hidden;
  align-items: center;
  flex-direction: column;
  justify-content: space-evenly;
  margin-right: -50%;
  padding: 1rem;
  transform: translate(-50%, -50%);
  border: 0.5em solid var(--light-grey);
  background-color: var(--black);
  box-shadow: 0 0 3px 1px var(--black);
}

.input-container {
  display: flex;
  align-items: center;
  flex-direction: column;
  justify-content: space-evenly;
}

p {
  margin: 0.5em 1rem;
}

.input-controls {
  display: flex;
  align-items: center;
}

.input-controls p {
  font-family: "Major Mono Display", monospace;
  font-weight: bold;
  width: 2rem;
  cursor: default;
  text-align: center;
}

#close-settings-button {
  margin: 2em 1rem 1rem;
  padding: 0.5em 1rem;
  cursor: pointer;
  transition: 0.2s linear all;
  border: none;
  background-color: var(--gold);
}

#close-settings-button:hover {
  background-color: var(--red);
}

.minus-button,
.add-button {
  font-size: 1.5rem;
  margin: 0.5em 1rem;
  padding: 0.2rem;
  cursor: pointer;
}

.minus-button:hover {
  color: var(--red);
}

.add-button:hover {
  color: var(--green);
}

#timer-icon {
  width: 2.5rem;
  height: 2.5rem;
  margin: 0.5em 1rem;
}

.settings-hr {
  width: 50%;
}

/* USER FEEDBACK POP-UP */
#message-container {
  position: absolute;
  top: 50%;
  left: 50%;
  display: none;
  visibility: hidden;
  align-items: center;
  flex-direction: column;
  justify-content: space-evenly;
  margin-right: -50%;
  padding: 2rem;
  transform: translate(-50%, -50%);
  border: 0.5em solid var(--light-grey);
  background-color: var(--black);
  box-shadow: 0 0 3px 1px var(--black);
}

#message {
  margin: 0.5em 1rem;
  padding: 0.5em 1rem;
  text-align: center;
}

#close-message-button {
  margin: 0.5em 1rem;
  padding: 0.5em 1rem;
  cursor: pointer;
  transition: 0.2s linear all;
  border: none;
  background-color: var(--gold);
}

#close-message-button:hover {
  background-color: var(--red);
}

/* FOOTER */
footer {
  width: 100%;
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translate(-50%, 0);
}

#petiteGriffe {
  margin: 0 auto;
  width: fit-content;
  display: flex;
  justify-content: center;
  align-items: center;
  color: var(--light-grey);
  font-size: .8rem;
  font-weight: bold;
  text-decoration: none;
  opacity: .5;
}

#petiteGriffe svg {
  width: .8rem;
  margin-right: .5rem;
  fill: var(--light-grey);
}

/* STATES */
.green {
  color: var(--green);
}

.blue {
  color: var(--blue);
}

.red {
  color: var(--red);
}

.grey {
  color: var(--light-grey);
}

.gold {
  color: var(--gold);
}

.white {
  color: white;
}

.bold {
  font-weight: bold;
}

.active {
  display: flex !important;
  visibility: visible !important;
}

.blur {
  filter: blur(0.5em);
}

/* MOBILE */
@media screen and (max-width: 450px) {
  header h1 {
    font-size: 2rem;
  }

  #timer-container {
    height: 50vh;
  }

  #timer-display-container {
    height: 50vh;
  }

  #timer-svg {
    height: 50vh;
  }

  #timer-display {
    font-size: 2.5rem;
  }

  #session-display {
    font-size: 1.5rem;
  }

  #rounds-display {
    font-size: 1rem;
  }

  #buttons-container {
    width: 90vw;
  }
}

@media screen and (max-width: 230px) {
  #timer-display {
    font-size: 2rem;
  }

  #session-display {
    font-size: 1rem;
  }

  #rounds-display {
    font-size: 1rem;
  }
}
