/* ============================================
   MOBILE RESPONSIVE STYLES
   ============================================ */

@media (max-width: 768px) {
  /* HUD Adjustments */
  #hud {
    height: 60px;
    padding: 0.25rem 0.5rem;
    flex-wrap: wrap;
  }

  .hud-left, .hud-right {
    flex: 1;
    min-width: 50%;
  }

  .hud-center {
    flex: 100%;
    order: 3;
    margin-top: 0.25rem;
  }

  .stat-bar {
    min-width: 100px;
  }

  .bar-container {
    width: 80px;
  }

  .stat-icon {
    font-size: 1rem;
  }

  .stat-label, .stat-text {
    font-size: 0.7rem;
  }

  .player-info {
    font-size: 0.9rem;
  }

  .level-info {
    font-size: 0.8rem;
  }

  /* Game World */
  #game-world {
    top: 60px;
    bottom: 60px;
  }

  .npc-sprite, .player-sprite, .demon-sprite {
    font-size: 3rem;
  }

  .npc-name, .demon-name {
    font-size: 0.7rem;
  }

  /* Panels */
  .panel {
    width: 95%;
    max-height: 85vh;
  }

  .panel-header {
    padding: 0.75rem;
  }

  .panel-header h2 {
    font-size: 1rem;
  }

  .panel-content {
    padding: 0.75rem;
  }

  /* Body Parts Grid */
  #body-parts-grid {
    grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
    gap: 0.5rem;
  }

  .body-part-card {
    padding: 0.5rem;
    font-size: 0.85rem;
  }

  /* Breathing Guide */
  .breathing-circle {
    width: 120px;
    height: 120px;
  }

  .breathing-circle::before {
    font-size: 2.5rem;
  }

  #breathing-text {
    font-size: 1rem;
  }

  .meditation-timer {
    font-size: 1.5rem;
  }

  /* Bottom Navigation */
  #bottom-nav {
    height: 60px;
    padding: 0.25rem;
  }

  .nav-icon {
    font-size: 1.2rem;
  }

  .nav-label {
    font-size: 0.6rem;
  }

  .nav-btn {
    padding: 0.25rem;
  }

  /* Buttons */
  .btn-primary, .btn-secondary {
    padding: 0.6rem 1.2rem;
    font-size: 0.9rem;
  }

  /* Quest Cards */
  .quest-card {
    padding: 0.75rem;
  }

  .quest-card h3 {
    font-size: 1rem;
  }

  /* Inventory & Achievements Grid */
  #inventory-grid, #achievements-grid {
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 0.5rem;
  }

  .inventory-item, .achievement-item {
    padding: 0.75rem;
    font-size: 0.85rem;
  }

  /* Chat Panel */
  #chat-messages {
    height: 300px;
  }

  .chat-input-container {
    flex-direction: column;
  }

  #chat-input {
    width: 100%;
  }

  /* Language Switcher */
  #language-switcher {
    top: 5px;
    right: 5px;
  }

  #lang-select {
    padding: 0.4rem;
    font-size: 0.85rem;
  }

  /* Loading Screen */
  .loading-content h1 {
    font-size: 2rem;
  }

  .loading-bar {
    width: 250px;
  }

  /* Modal */
  .modal-content {
    padding: 1.5rem;
    margin: 1rem;
  }

  .modal-content h2 {
    font-size: 1.2rem;
  }

  /* Floating Text */
  .floating-text {
    font-size: 1.2rem;
  }

  /* Celebration */
  #celebration-content {
    font-size: 2rem;
  }
}

@media (max-width: 480px) {
  /* Extra Small Screens */
  #hud {
    height: 50px;
    font-size: 0.8rem;
  }

  .hud-center {
    font-size: 0.75rem;
  }

  #game-world {
    top: 50px;
    bottom: 50px;
  }

  #bottom-nav {
    height: 50px;
  }

  .nav-label {
    display: none;
  }

  .panel {
    width: 100%;
    max-height: 90vh;
    border-radius: 0;
  }

  #body-parts-grid {
    grid-template-columns: repeat(auto-fill, minmax(70px, 1fr));
  }

  .breathing-circle {
    width: 100px;
    height: 100px;
  }

  .breathing-circle::before {
    font-size: 2rem;
  }
}

/* Touch Optimizations */
@media (hover: none) and (pointer: coarse) {
  /* Larger touch targets */
  .nav-btn {
    min-height: 44px;
    min-width: 44px;
  }

  .body-part-card {
    min-height: 80px;
  }

  .btn-primary, .btn-secondary {
    min-height: 44px;
  }

  /* Remove hover effects on touch devices */
  .nav-btn:hover {
    transform: none;
  }

  .body-part-card:hover {
    transform: none;
  }
}

/* Landscape Mobile */
@media (max-height: 500px) and (orientation: landscape) {
  #hud {
    height: 50px;
  }

  #game-world {
    top: 50px;
    bottom: 50px;
  }

  #bottom-nav {
    height: 50px;
  }

  .panel {
    max-height: 90vh;
  }

  #chat-messages {
    height: 200px;
  }
}

