/* --- ОСНОВНОЙ ФОН и БАЗА --- */
body {
  margin: 0;
  padding: 0;
  font-family: 'Inter', Arial, sans-serif;
  background: #0c1c2c;
  min-height: 100vh;
}

/* --- КОНТЕЙНЕР ДЕСКТОП --- */
.container {
  max-width: 900px;
  margin: 0 auto;
  background: rgba(16,32,64,0.93);
  border-radius: 2rem;
  box-shadow: 0 0 60px #00bfff22;
  padding: 1.2rem 0.7rem 1.6rem 0.7rem;
  margin-top: 2.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* --- ХЕДЕР ДЕСКТОП --- */
header {
  text-align: center;
  margin-bottom: 1.2rem;
}
h1 {
  color: #00bfff;
  margin-bottom: 0.1em;
  font-size: 2rem;
  font-weight: 400;
  font-family: 'Inter', Arial, sans-serif;
  letter-spacing: 0.01em;
}
.subtitle {
  color: #b0c6df;
  font-size: 1rem;
  margin: 0.1em 0 0.8em 0;
  font-family: 'Inter', Arial, sans-serif;
  font-weight: 300;
}

/* --- DIAL (КРУГЛЫЙ ИНДИКАТОР) ДЕСКТОП --- */
.dial-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 1.2rem;
  width: 100%;
}
#dial {
  width: 96vw;
  max-width: 220px;
  aspect-ratio: 1/1;
  border-radius: 50%;
  border: 4px solid #00bfff;
  background: #12263d;
  box-shadow: 0 0 45px #00bfff55;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  position: relative;
  margin-bottom: 0.4rem;
}
#speed-value {
  font-size: 2.6em;
  color: #fff;
  font-weight: 800;
  font-family: 'Inter', Arial, sans-serif;
  letter-spacing: 0.01em;
  text-shadow: 0 0 12px #00bfff, 0 0 2px #00fff2;
  margin-bottom: 0.1em;
}
#unit {
  color: #b0eaff;
  font-size: 1.18em;
  font-weight: 500;
  font-family: 'Inter', Arial, sans-serif;
  margin-bottom: 0.2em;
}
#percent {
  color: #00d6ff;
  font-weight: 400;
  font-size: 1.07em;
  font-family: 'Inter', Arial, sans-serif;
  margin-bottom: 0.2em;
}
#status {
  color: #b5e7ff;
  font-size: 1em;
  position: absolute;
  bottom: 0.95em;
  font-family: 'Inter', Arial, sans-serif;
  font-weight: 300;
}

/* --- КНОПКА СТАРТА ДЕСКТОП --- */
#start-button {
  background: none;
  color: #19d1ff;
  border: none;
  font-size: 2em;
  font-weight: 800;
  font-family: 'Inter', Arial, sans-serif;
  cursor: pointer;
  text-shadow: 0 0 15px #19d1ff, 0 0 1px #fff;
  margin: 0;
  padding: 0;
  border-radius: 0;
  box-shadow: none;
  animation: none;
  position: absolute;
  left: 50%;  top: 50%;
  transform: translate(-50%, -50%);
}
#start-button:hover, #start-button:focus {
  color: #fff;
  text-shadow: 0 0 25px #16b7ff, 0 0 5px #00fff7;
  outline: none;
}

/* --- ГРАФИКИ ДЕСКТОП --- */
.graph-section {
  display: flex;
  width: 96%;
  gap: 0.7rem;
  margin: 0.5em 0 1.3em 0;
  justify-content: center;
}
.graph-block {
  background: #10213d;
  border-radius: 1.1em;
  padding: 0.6em 0.2em 0.9em 0.2em;
  width: 60%;
  box-shadow: 0 0 8px #0cf3ff11;
  display: flex;
  flex-direction: column;
  align-items: center;
  height: 120px;
  min-height: 80px;
  max-height: 130px;
}
.graph-label {
  color: #b7e7fd;
  font-size: 1.03em;
  font-weight: 400;
  font-family: 'Inter', Arial, sans-serif;
  margin-bottom: 0.2em;
}
.graph-block canvas {
  height: 100px !important;
  max-height: 120px !important;
  width: 98% !important;
}

/* --- СТАТЫ ДЕСКТОП --- */
.stats {
  display: flex;
  width: 97%;
  gap: 0.55em;
  justify-content: center;
  margin: 0.5em 0 0.7em 0;
}
.stat-block {
  background: #12294a;
  border-radius: 0.6em;
  width: 140px;
  min-width: 56px;
  max-width: 145px;
  text-align: center;
  color: #e9f9ff;
  font-size: 1.13em;
  font-family: 'Inter', Arial, sans-serif;
  margin-bottom: 0.22em;
  box-shadow: 0 0 9px #00d6ff22;
  font-weight: 200;
  letter-spacing: 0.01em;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  padding: 0.43em 0.6em 0.28em 0.6em;
}
.stat-block label {
  font-weight: 300;
  color: #99d9ff;
  font-size: 0.92em;
  font-family: 'Inter', Arial, sans-serif;
  margin-bottom: 0.12em;
  display: block;
}

/* --- ФУТЕР ДЕСКТОП --- */
footer {
  text-align: center;
  margin-top: 1.9em;
  color: #60b2de;
  font-size: 1em;
  opacity: 0.83;
  letter-spacing: 0.12em;
  font-family: 'Inter', Arial, sans-serif;
  font-weight: 400;
}

/* --- МОБИЛЬНАЯ ВЕРСИЯ: свои стили ДЛЯ КАЖДОГО ЭЛЕМЕНТА --- */
@media (max-width: 700px) {
  .container {
    max-width: 98vw;
    padding: 0.5rem 0.1rem 1.2rem 0.1rem;
    margin-top: 0.7rem;
    border-radius: 1.3rem;
    box-shadow: 0 0 15px #00bfff33;
  }
  header h1 {
    font-size: 1.3rem;
    font-weight: 400;
    font-family: 'Inter', Arial, sans-serif;
    letter-spacing: 0.01em;
  }
  .subtitle {
    font-size: 0.87rem;
    font-weight: 200;
    font-family: 'Inter', Arial, sans-serif;
  }
  .dial-container {
    margin-bottom: 0.7rem;
  }
  #dial {
    max-width: 37vw;
    min-width: 0;
    border-width: 2.5px;
    box-shadow: 0 0 18px #00bfff99;
    padding: 0.5em 0.2em;
    margin-bottom: 0.15rem;
  }
  #speed-value {
    font-size: 1.5em;
    font-weight: 500;
    font-family: 'Inter', Arial, sans-serif;
    letter-spacing: 0.01em;
  }
  #unit {
    font-size: 0.85em;
    font-weight: 300;
    font-family: 'Inter', Arial, sans-serif;
  }
  #percent {
    font-size: 0.85em;
    font-weight: 200;
    font-family: 'Inter', Arial, sans-serif;
  }
  #status {
    font-size: 0.95em;
    font-weight: 200;
    font-family: 'Inter', Arial, sans-serif;
  }
  #start-button {
    font-size: 1.4em;
    font-weight: 600;
    font-family: 'Inter', Arial, sans-serif;
  }
  /* --- САМОЕ ГЛАВНОЕ: не переносить графики --- */
  .graph-section {
    flex-direction: row !important; /* ВСЕГДА в ряд даже на мобиле */
    gap: 0.35rem;
    margin-bottom: 0.2em;
  }
  .graph-block {
    background: #10213d;
    border-radius: 1.1em;
    padding: 0.6em 0.2em 0.9em 0.2em;
    width: 60%;
    box-shadow: 0 0 8px #0cf3ff11;
    display: flex;
    flex-direction: column;
    align-items: center;
    height: 100px;
    min-height: 80px;
    max-height: 130px;
  }
  .graph-label {
    font-size: 0.95em;
    font-weight: 300;
    font-family: 'Inter', Arial, sans-serif;
  }
  .graph-block canvas {
    height: 90px !important;
    max-height: 90px !important;
  }
  .stats {
    flex-wrap: wrap;
    gap: 1em;
  }
  .stat-block {
    width: 45vw;
    min-width: 29vw;
    max-width: 44vw;
    font-size: 0.92em;
    font-family: 'Inter', Arial, sans-serif;
    font-weight: 100;
    padding: 0.91em 0.2em 0.22em 0.2em;
  }
  .stat-block label {
    align-self: flex-start;   /* Заголовок прижимается к верху */
    margin-bottom: auto;      /* Отпихивает label вверх */
    padding-top: 0.2em;       /* Чуть вниз от верхнего края */
    font-size: 0.88em;
    font-weight: 200;
    padding: 0.1em 0.2em 0.92em 0.2em;
    font-family: 'Inter', Arial, sans-serif;
  }
  footer {
    margin-top: 0.5em;
    font-size: 0.84em;
    font-family: 'Inter', Arial, sans-serif;
    font-weight: 400;
  }
}
