.background {
  padding-top: 2rem;
  padding-bottom: 2rem;
  height: 100%;
  width: 100%;
  /* background-color: #f7f7f7; */
}

.popup {
  width: 90%;
  height: 90%;
  /* background-color: white; */
}

.col {
  height: auto;
}

[class*='row'] {
  padding: 1rem;
}

hr {
  margin-top: 2rem;
  margin-bottom: 2rem;
}

.options-panel .row {
  height: auto;
}

.options-panel .row button {
  width: auto;
}

#display {
  min-height: 200px;
  height: fit-content;
  width: 200px;
}

.phrases {
  transform: rotate(180deg);
  width: 100%;
  text-align: left;
  position: fixed;
  bottom: 20px; /* Will appear at top after rotation */
  left: 20px;
  padding: 20px;
}

.phrases h1 {
  margin: 0;
  font-size: 24px;
  margin-bottom: 15px;
}

.phrases .lead {
  margin-bottom: 10px;
}

.phrases #calibrationBeginButton {
  margin-top: 20px;
  margin-left: 0;
}

.turnMeToReadBelow {
  position: fixed;
  top: 20px;
  left: 20px;
  line-height: 1.2rem;
  text-align: left;
}

.updateDisplay {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) rotate(180deg);
  width: 100%;
  text-align: center;
  background: white;
  -webkit-overflow-scrolling: touch; /* For smooth scrolling on iOS */
}

.container {
  display: none;
}

#modelNumberInput {
  width: 50vw;
  height: 100%;
  font-size: 1rem;
  border-radius: 5px;
  border: 1px solid black;
  margin-top: 10px;
  margin-bottom: 10px;
}

#modelNameInput {
  width: 50vw;
  height: 100%;
  font-size: 1rem;
  border-radius: 5px;
  border: 1px solid black;
  margin-top: 10px;
  margin-bottom: 10px;
}

#headerContainer {
  border-top: 1px solid #eee;
  box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
}

/* Ensure content doesn't get hidden under fixed elements */
#display {
  width: 100%;
  margin: 0 auto;
  text-align: center;
  padding-bottom: 20px;
}

@media (max-width: 768px) {
  #listenerContainer {
    padding: 0;
    position: relative;
    height: 100vh;
    overflow: hidden;
  }

  #headerContainer h1 {
    font-size: 20px;
  }

  #recordingInProgress {
    font-size: 16px;
  }

  .phrases {
    margin-bottom: 1rem;
  }

  #recordingInProgress {
    margin: 0;
    padding: 0.5rem;
  }

  #allowMicrophone {
    margin: 0;
    padding: 0.5rem;
  }
}
