/* styles.css — version bleu sombre */

/* Reset très léger */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html,
body {
  height: 100%;
  width: 100%;
  margin: 0;
  padding: 0;
  background: #000;
  overflow: hidden;
}

body {
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial;
  background: #000;
  color: rgb(28, 36, 58);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.app {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: #000;
  overflow: hidden;
}

/* Fullscreen video container */
.video-container {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: #000;
  overflow: hidden;
}

video#rideVideo {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  pointer-events: none;
}

/* Hidden panel for beamer projection */
.hidden-panel {
  display: none !important;
}

/* Floating title overlay */
.title-overlay {
  position: absolute;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 100;
  text-align: center;
}

.title-overlay h1 {
  color: #fff;
  font-size: 2.5rem;
  font-weight: 700;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.8);
  margin: 0;
}

.title-overlay .subtitle {
  color: rgba(255, 255, 255, 0.8);
  font-size: 1.2rem;
  font-weight: 400;
  text-shadow: 0 2px 6px rgba(0, 0, 0, 0.8);
  margin-top: 5px;
}

/* Floating speed overlay */
.speed-overlay {
  position: absolute;
  bottom: 30px;
  right: 30px;
  width: 140px;
  height: 140px;
  z-index: 100;
}

.speed-overlay svg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.speed-overlay .speed-content {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
  z-index: 10;
}

.speed-overlay .speed-big {
  font-size: 1.8rem;
  font-weight: 700;
  color: #fff;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
  line-height: 1;
}

.speed-overlay .speed-big .units {
  font-size: 0.7rem;
  font-weight: 400;
  display: block;
  margin-top: 2px;
}

/* Legacy classes kept for JS compatibility */
.left {
  display: none;
}

.right {
  width: 30%;
  padding: 26px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* Vidéo : grand écran (legacy) */
.video-wrap {
  width: 100%;
  height: 100%;
  background: #000;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.12);
}

/* Right column */
.title {
  color: rgb(28, 36, 58);
  /* ancien : rgb(41,33,24) */
  font-size: 1.9rem;
  margin-bottom: 6px;
  font-weight: 700;
}

/* Status */
.status {
  background: rgba(255, 255, 255, 0.6);
  padding: 10px;
  border-radius: 8px;
  box-shadow: inset 0 1px 0 rgba(0, 0, 0, 0.02);
}

.status-row {
  display: flex;
  justify-content: space-between;
  padding: 6px 0;
  align-items: center;
}

.label {
  font-size: 0.95rem;
  color: #32405a;
  /* ancien : #5a4f42 */
}

.value {
  font-weight: 700;
  font-size: 1.1rem;
  color: rgb(28, 36, 58);
  /* ancien : rgb(41,33,24) */
}

/* Buttons */
.btn-row {
  display: flex;
  gap: 10px;
  margin: 8px 0 12px 0;
}

.btn {
  flex: 1;
  background: rgb(70, 90, 130);
  /* ancien : rgb(137,121,99) */
  color: #fff;
  border: none;
  padding: 10px 12px;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 600;
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.08);
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn-ghost {
  background: rgb(180, 200, 235);
  /* ancien : rgb(233,208,173) */
  color: rgb(28, 36, 58);
  /* ancien : rgb(41,33,24) */
}

/* Wheel config */
.wheel-config {
  margin: 8px 0 12px 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.wheel-config input[type="number"] {
  padding: 8px;
  border-radius: 6px;
  border: 1px solid rgba(0, 0, 0, 0.08);
}

/* Simulation */
.simulation-panel {
  margin-top: 6px;
  padding: 10px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.6);
}

.sim-controls {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 8px;
}

#simSpeed {
  width: 100%;
  margin-top: 6px;
}

.sim-controls #simSpeedValue {
  min-width: 80px;
  text-align: center;
  font-weight: 700;
}

/* Footer small */
.footnote {
  margin-top: auto;
  font-size: 0.8rem;
  color: #3c4a62;
  /* ancien : #6b6156 */
}

hr {
  border: none;
  border-top: 1px solid rgba(0, 0, 0, 0.06);
  margin: 12px 0;
}

/* Responsive : empilement pour petites largeurs */
@media (max-width: 900px) {
  .app {
    flex-direction: column;
  }

  .left,
  .right {
    width: 100%;
  }

  .left {
    height: 50vh;
  }
}