/* --- Mobile Responsiveness (for viewports 768px and narrower) --- */
@media (max-width: 768px) {
  #device-screen {
    position: fixed;
    top: 0px;
    bottom: 0px;
    left: 0px;
    right: 0px;
    background: #2c2c2c;
    overflow: hidden;
    max-width: none;
    max-height: none;
    aspect-ratio: unset;
    margin: 0;
    width: auto;
    height: auto;

  }

  #threejs-container {
    width: 100%;
    height: 100%;
    position: relative;
    aspect-ratio: 9 / 16;
  }



#map-overlay-container {
  position: absolute;
    top: 41px !important;
    left: 31px !important;

}

.player-dot {
  position: absolute;
  width: 3px;
  height: 3px;
  background-color: #00ff00;
  border-radius: 50%;
  transform: translate(-50%, -50%);
  box-shadow: 0 0 3px #00ff00;
}

.location-dot {
  position: absolute;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  transform: translate(-50%, -50%);
}



  .d-pad-container {
    position: relative;
    left: 0;
    bottom: 0;
    width: 133px;
    height: 113px;
  }

  .menu-toggle,
  .menu-item {
    width: 46px;
    height: 46px;
    font-size: 18px;
    border-radius: 6px;
    /* Adjust for mobile too */
  }

  .menu-items {
    padding: 14px;
    gap: 10px;
    border-radius: 8px;
    /* Adjust for mobile too */
  }

  #hints-overlay {
    top: 40px !important;
    width: min(81vw, 629px);
    padding: 0px;
    max-height: 80vh;
    border-radius: 0px;
    left: 50%;
    transform: translateX(-50%);
    right: auto;
  }

  #hints-toggle {
    right: -5x;
    top: 0px;
    width: 35px;
    height: 35px;
    font-size: 20px;
    position: absolute;
  }

  .hints-header h1 {
    font-size: 20px;
  }

  .hints-close {
    padding: 5px 5px;
    /* Adjust for mobile too */
  }

  .synth-toggle-container {
    position: absolute;
    /* Match SVG height */
    right: -30px;
    bottom: -35px;
    pointer-events: auto !important;
  }

  /* Action Buttons
  .action-buttons {
    right: 20px;
    bottom: 5px;
    display: flex;
    margin-right: 0px;
    position: absolute;
  }
 */
 
  #synth-container {
    left: 50%;
    /* Center horizontally */
    transform: translateX(-50%);
    top: 7% !important;
    width: 83%;
    height: 60%;
    display: flex;
    flex-direction: column;
    display: none;
  }

  #synth-container.active {
    display: flex;
    /* Show when active class is added */
  }

  #synth-sections-container {
    flex: 1;
    /* Take all available space */
    overflow-y: auto;
    max-height: calc(100% - 40px);
    /* Reserve space for tab navigation */
  }

  .synth-section {
    padding: 0px;
    border-radius: 0px;

  }

  .synth-interface {
    width: 100%;
    position: relative;
  }

  .synth-tab-navigation {
    height: 36px;
    /* Fixed height for tab navigation */
    flex-shrink: 0;
    /* Prevent tab bar from shrinking */

  }

  /* Ensure all other elements fit properly */
  .synth-section h2 {
    font-size: 16px;
    margin-bottom: 0px;
  }

  .synth-control {
    margin-bottom: 0px;
  }

  .synth-control p {
    letter-spacing: 0.3px;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 0px;
  }

  .synth-range {
    height: 6px;
    border-radius: 2px;
    width: 100%;
  }

  .synth-range::-webkit-slider-thumb,
  .synth-range::-moz-range-thumb,
  .synth-range::-ms-thumb {
    width: 14px;
    height: 14px;
    border-radius: 2px;
    /* Smaller, sharper thumb for mobile */
  }

  .synth-radio-label {
    font-size: 11px;
  }

  .synth-button {
    padding: 8px 15px;
    font-size: 12px;
    border-radius: 5px;
  }

  .synth-tab-navigation {
    margin-top: 15px;
  }

  .synth-nav-button {
    padding: 6px 10px;
    font-size: 14px;
    border-radius: 4px;
  }

  .synth-tab-indicator {
    padding: 6px 8px;
    font-size: 12px;
    border-radius: 4px;
  }

  h1 {
    font-size: 3rem;
    /* Adjusted for mobile */
  }

  h2 {
    font-size: 2rem;
    /* Adjusted for mobile */
  }

  .hints-header h1 {
    font-size: 2rem;
    /* Adjusted for mobile */
  }

}