body {
    margin: 0;
    padding: 0;
    background: url('/assets/images/stats_background.webp') no-repeat center center fixed;
    background-size: cover;
    font-family: 'Schoolbell', cursive;
    color: white;
    display: flex;
    flex-direction: column;
    align-items: center;
    min-height: 100vh;
    padding-top: 60px;
  }
  
  /* Header fixe */
  .fixed-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 90%;
    max-width: 1200px;
    margin-bottom: 20px;
    padding: 5px 0;
    position: sticky;
    top: 0;
  }
  
  .stats-title {
    font-size: 3rem;
    font-weight: 800;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
    margin: 0;
    color: white;
  }
  
  .radar-container {
    width: 280px;
    height: 280px;
  }
  
  /* Carousel des catégories */
  .carousel-container {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 90%;
    max-width: 1000px;
    position: relative;
    margin-bottom: 20px;
    padding: 15px 0;
  }
  
  .carousel-track {
    display: flex;
    overflow: hidden;
    width: 100%;
    scroll-behavior: smooth;
    scroll-snap-type: x mandatory;
  }
  
  .category {
    min-width: 100%;
    scroll-snap-align: start;
    padding: 10px 20px 30px;
    box-sizing: border-box;
  }
  
  .carousel-btn {
    background: transparent;
    border: none;
    color: white;
    font-size: 3rem;
    cursor: pointer;
    padding: 10px;
    z-index: 10;
    font-weight: 900;
    transition: transform 0.2s ease;
    opacity: 0.8;
    text-shadow: 
      0 0 5px white,
      -1px -1px 0 white,
      1px -1px 0 white,
      -1px 1px 0 white,
      1px 1px 0 white;
    position: relative;
  }
  
  
  .carousel-btn:hover {
    transform: scale(1.2);
    opacity: 1;
  }
  
  /* Style des catégories */
  .category h2 {
    font-size: 2.2rem;
    font-weight: 800;
    margin: 5px 0 10px;
    text-align: center;
    text-shadow: 0 0 6px rgba(255, 255, 255, 0.5);
  }
  
  #strength h2 { color: red; }
  #endurance h2 { color: #2196f3; }
  #recovery h2 { color: #4caf50; }
  #agility h2 { color: gold; }
  
  .points-left {
    font-size: 1.2rem;
    font-weight: bold;
    margin-left: 10px;
  }
  
  /* Stats container */
  .stat-container {
    display: flex;
    align-items: center;
    margin-bottom: 10px;
  }
  
  .stat-container label {
    width: 120px;
    font-size: 1.5rem;
    font-weight: bold;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.8);
  }
  
  .stat-value {
    width: 40px;
    text-align: center;
    font-size: 1.4rem;
    font-weight: bold;
  }
  
  /* Sliders stylisés */
  .chalk-slider-container {
    position: relative;
    width: 100%;
    height: 40px;
    margin: 0 15px;
  }
  
  input[type=range].chalk-slider {
    -webkit-appearance: none;
    width: 100%;
    background: transparent;
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 2;
  }
  
  input[type=range].chalk-slider::-webkit-slider-runnable-track {
    height: 6px;
    background: transparent;
    border-radius: 0;
  }
  
  input[type=range].chalk-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 8px;
    height: 30px;
    border-radius: 1px;
    background: currentColor;
    cursor: pointer;
    margin-top: -12px;
    box-shadow: 
      0 0 8px rgba(255, 255, 255, 0.7),
      0 0 3px rgba(255, 255, 255, 0.9);
    filter: blur(0.3px);
  }
  
  input[type=range].chalk-slider::-moz-range-thumb {
    width: 8px;
    height: 30px;
    border-radius: 1px;
    background: currentColor;
    cursor: pointer;
    box-shadow: 
      0 0 8px rgba(255, 255, 255, 0.7),
      0 0 3px rgba(255, 255, 255, 0.9);
    filter: blur(0.3px);
  }
  
  input[type=range].chalk-slider:focus {
    outline: none;
  }
  
  /* Style tirets de craie */
  .chalk-marks {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 100%;
    height: 4px;
    display: flex;
    justify-content: space-between;
  }
  
  .chalk-marks:before {
    content: '';
    position: absolute;
    width: 100%;
    height: 3px;
    background: rgba(255, 255, 255, 0.6);
    top: 50%;
    transform: translateY(-50%);
    filter: blur(0.3px);
    box-shadow: 0 0 2px rgba(255, 255, 255, 0.5);
  }
  
  /* Les tirets de craie sont générés par JS pour correspondre exactement au nombre de points */
  .chalk-mark {
    width: 2px;
    height: 12px;
    background-color: rgba(255, 255, 255, 0.9);
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    filter: blur(0.3px);
  }
  
  /* Couleurs des sliders */
  .red { color: #ff5252; }
  .blue { color: #42a5f5; }
  .green { color: #66bb6a; }
  .yellow { color: #ffee58; }
  
  /* Boutons */
  .button-container {
    display: flex;
    gap: 20px;
    margin-top: -10px;
    margin-bottom: 20px;
  }
  
  .menu-button {
    background: none;
    border: none;
    color: white;
    font-size: 2rem;
    font-family: 'Schoolbell', cursive;
    
    cursor: pointer;
  }

  .save-button {
    background: none;
    border: none;
    color: green;
    font-size: 2rem;
    font-family: 'Schoolbell', cursive;
    text-shadow: 
      0 0 1px white,
      -1px -1px 0 white,
      1px -1px 0 white,
      -1px 1px 0 white,
      1px 1px 0 white;
    cursor: pointer;
  }
  
  .menu-button:before, .save-button:before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.1);
    z-index: -1;
  }
  
  .menu-button:hover, .save-button:hover {
    background: rgba(255, 255, 255, 0.4);
    transform: translateY(-3px);
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.3);
  }
  
  .save-button {
    background: rgba(76, 175, 80, 0.3);
    border-color: #4caf50;
  }
  
  /* Animation de sauvegarde */
  .category.saved {
    animation: flash-save 0.8s ease;
  }
  
  @keyframes flash-save {
    0%, 100% { background-color: transparent; }
    50% { background-color: rgba(76, 175, 80, 0.3); }
  }
  
  /* Style du radar chart */
  #radarChart {
    filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.5));
  }
  
  /* Responsive */
  @media (max-width: 768px) {
    .fixed-header {
      flex-direction: column;
      gap: 10px;
    }
    
    .stats-title {
      font-size: 2.5rem;
    }
    
    .radar-container {
      width: 220px;
      height: 220px;
    }
    
    .stat-container label {
      font-size: 1.2rem;
      width: 90px;
    }
    
    .stat-value {
      font-size: 1.2rem;
    }
    
    .carousel-btn {
      font-size: 2.5rem;
    }
  }