* {
  font-family: 'Montserrat', sans-serif;
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

header {
  background-color: #eef0f7;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: rgba(0, 0, 0, 0.16) 0px 3px 6px, rgba(0, 0, 0, 0.23) 0px 3px 6px;
  margin-bottom: 1.3em; 
}

header a {
  cursor: pointer;
}

header img {
  width: 13em;
  height: auto;
  padding: 0.6em 0.8em 0.4em 0.5em; 
}

@media (min-width: 600px) {
  header img 
  {
    width: 16em;
  }
}

main {
  padding-top: 0.7em;
  min-height: 80vh;
}

.app {
  border: 3px dashed black;
  border-radius: 1em;
  width: 96%;
  max-width: 950px;
  margin: auto;
  margin-bottom: 1em;
  padding: 0.4em;
  background-color: #dce3ff;
}

@media (min-width: 600px) {
  .app {
    width: 70%;
    margin-left: 1rem;
  } 
}

@media (min-width: 900px) {
  .app {
    width: 65%; 
    margin-left: auto;
  } 
}

h1 {
  margin-top: 0.6em;
  text-align: center;
  margin-bottom: 0.2em;
  font-size: 2rem;
}

h1 + p {
  text-align: center;
  font-size: 1rem;
  margin: 0.2rem;
}

@media (min-width: 900px) {
  h1 + p {
    margin: 0.2rem 3rem;
  } 
}

.app img {
  width: 5em;
  height: auto;
  display: block;
  margin: auto;
  margin-top: 1.3em;
  margin-bottom: 1.3em; 
}

.audio-preview{
  width: 100%;
  margin: auto;
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 65%;
  overflow-x: auto;
  gap: 0.5rem;
}

@media (min-width: 500px) {
  .audio-preview{
    grid-auto-columns: 40%;
  }
}

form {
  display: flex;
  justify-content: center;
  margin: 0.5em 0;
  flex-direction: column; 
  align-items: center;
}

form label {
  cursor: pointer;
  border: 4px solid #6378d9;
  border-radius: 0.8em;
  font-size: 1.3rem;
  padding: 0.2em 1em;
  font-weight: 500;
  box-shadow: rgba(0, 0, 0, 0.24) 0px 3px 8px;
}

form label:hover {
  background-color: #6378d9;
  color: white; 
}

.hidden-element {
  font-size: 0rem; 
  opacity: 0; 
  margin: 0; 
  padding: 0; 
  overflow: hidden; 
  height: 0; 
  line-height: 0; 
}

.audio-display {
  width: 100%;
  margin: auto;
  background-color: #1d2b35;
  border-radius: 0.7em;
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 1em;
  margin-top: 1em;
  position: relative;
  box-shadow: rgba(50, 50, 93, 0.25) 0px 13px 27px -5px, rgba(0, 0, 0, 0.3) 0px 8px 16px -8px;
}

.audio-display > audio {
  object-fit: contain;
  border-radius: 0.5em;
  box-sizing: border-box;
  width: 95%;
  height: 11vh;
  margin: 1.5rem 0 0.5rem 0;
}

.close{
  color: white;
  font-size: 0.9rem;
  background-color: rgb(255,0,0);
  padding: 0.2em 0.5em;
  border-radius: 0.5em;
  position: absolute;
  right: 5px;
  top: 5px;
  cursor: pointer;
  z-index: 10;
}

.close:hover{
  background-color: rgb(180, 44, 44);
}

.audio-name{
  color: white;
  align-self: flex-start;
  align-items: start;
  margin-left: 10%;
  font-size: 0.96rem; 
  text-overflow: ellipsis; 
  overflow: hidden; 
  width: 85%;
  text-align: left;
  white-space: nowrap;
  overflow: hidden;
}

.audio-size{
  font-size: 1.2rem;
  text-overflow: ellipsis; 
  overflow: hidden; 
  width: 85%;
  text-align: left;
  white-space: nowrap;
  overflow: hidden;
  margin-left: 5%; 
}

.audio-size span{
  color: white;
  background-color: #17b06e; 
  border-radius: 0.2em; 
  padding: 0 0.3em;
}

.strike-through{
  text-decoration: line-through;
  margin-right: 0.2em;
  color: gray;
}

.audio-display > a{
  border: 1px solid white;
  color: white;
  width: 82%;
  margin: auto;
  text-align: center;
  text-decoration: none;
  margin: 0.5em 1em;
  border-radius: 0.2em;
  background-color: white;
  color: #1d2b35;
  font-size: 1.2rem;
}

.audio-display > a:hover{
  background-color: #dddee1;
}

.progress-div{
  width: 82%; 
  margin: auto; 
  position: relative;
  margin: 0.5em 1em;
}

.progress-div-text{
  position: absolute; 
  top: 15%; 
  left: 5%; 
  color: white;
  z-index: 2;
}

.progress-bar-new-indeterminate {
  height: 4px;
  background-color: rgba(5, 114, 206, 0.2);
  width: 100%;
  overflow: hidden;
  width: 100%;
  height: 26px;
  border: 1px solid white;
  border-radius: 0.2em;
  margin: auto;
}

.progress-bar-value-new-indeterminate {
  width: 100%;
  height: 100%;
  background-color: #17b06e;
  animation: indeterminateAnimation 1s infinite linear;
  transform-origin: 0% 50%;
}

@keyframes indeterminateAnimation {
  0% {
    transform:  translateX(0) scaleX(0);
  }
  40% {
    transform:  translateX(0) scaleX(0.4);
  }
  100% {
    transform:  translateX(100%) scaleX(0.5);
  }
}

.progress-bar-value-determinate{
  width: 45%;
  height: 100%;
  background-color: #17b06e;
  transition: width 0.5s ease;
}

.solid-border{
  border: 3px solid rgb(30, 29, 29);
}

.advanced-setting {
  padding: 16px;
  background: #f9fafb;
  border: 2px solid #e5e7eb;
  border-radius: 12px;
  width: 96%;
  max-width: 950px;
  margin: auto;
}

@media (min-width: 600px) {
  .advanced-setting {
    margin-left: 1rem;
    width: 70%; 
  } 
}
  
@media (min-width: 900px) {
  .advanced-setting {
    width: 65%;
    margin: auto;
  }
}

.advanced-setting-option {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.advanced-setting-option label {
  font-size: 0.9rem;
  font-weight: 600;
  color: #374151;
}

.advanced-setting-option input[type="range"] {
  width: 100%;
  height: 8px;
  border-radius: 6px;
  background: #e5e7eb;
  outline: none;
  cursor: pointer;
}

.advanced-setting-option input[type="range"]::-webkit-slider-runnable-track {
  height: 8px;
  border-radius: 6px;
  background: linear-gradient(to right, #bfdbfe, #93c5fd);
}

.advanced-setting-option input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  height: 18px;
  width: 18px;
  border-radius: 50%;
  background: #fff;
  border: 3px solid #60a5fa;
  margin-top: -5px;
  cursor: grab;
  transition: transform 0.15s ease;
}

.advanced-setting-option input[type="range"]::-webkit-slider-thumb:active {
  transform: scale(1.2);
}

#rangeValue {
  font-size: 14px;
  font-weight: 500;
  color: #374151;
  text-align: right;
}

@media (min-width: 768px) {
  .advanced-setting-option {
    flex-direction: row;
    align-items: center;
    gap: 16px;
  }
}