/* Basic Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
  }
  
  body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #333;
    display: flex;
    flex-direction: column;
    height: 100vh;
    margin: 0;
    overflow: hidden;
  }
  
  header {
    text-align: center;
    background: linear-gradient(135deg, #2c3e50 0%, #3498db 100%);
    color: white;
    padding: 1rem;
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
  }
  
  header h1 {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 2rem;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
    animation: slideIn 0.5s ease-out;
  }
  
  @keyframes slideIn {
    from {
      transform: translateY(-20px);
      opacity: 0;
    }
    to {
      transform: translateY(0);
      opacity: 1;
    }
  }
  
  #bitmoji {
    width: 60px; /* Adjust as needed */
    height: auto;
  }
  
  header h2 {
    margin-top: 0.5rem;
    font-weight: normal;
    color: #f0f0f0;
    font-size: 1.2rem;
  }

  header .warning {
    margin-top: 0.6rem;
    display: inline-block;
    padding: 0.35rem 0.85rem;
    border-radius: 999px;
    background: rgba(0, 0, 0, 0.25);
    color: #fff;
    font-size: 0.95rem;
    letter-spacing: 0.02em;
  }
  
  main {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.95);
    margin: 0;
    overflow-y: auto;
  }
  
  /* Container for the static map (1200px wide) */
  #mapContainer {
    position: relative;
    margin-bottom: 1rem;
    border: 3px solid #3498db;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
    transition: transform 0.3s ease;
  }
  
  #mapContainer:hover {
    transform: scale(1.01);
  }
  
  /* Fixed size map - must match calibration tool */
  #mapImage {
    display: block;
    width: 800px;  /* Fixed width for consistency */
    height: auto;
  }
  
  /* User's guess pin */
  #pin.user-pin {
    position: absolute;
    width: 16px;
    height: 16px;
    background: #e74c3c;
    border: 2px solid white;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    pointer-events: none;
    display: none;
    box-shadow: 0 2px 8px rgba(0,0,0,0.4);
    animation: dropPin 0.3s ease-out;
    z-index: 10;
  }
  
  @keyframes dropPin {
    from {
      transform: translate(-50%, -250%);
      opacity: 0;
    }
    to {
      transform: translate(-50%, -50%);
      opacity: 1;
    }
  }
  
  .correct-pin {
    animation: pulse 1s infinite;
  }
  
  @keyframes pulse {
    0% { transform: translate(-50%, -50%) scale(1); }
    50% { transform: translate(-50%, -50%) scale(1.3); }
    100% { transform: translate(-50%, -50%) scale(1); }
  }
  
  .distance-line {
    animation: drawLine 0.5s ease-out;
  }
  
  @keyframes drawLine {
    from { width: 0; }
    to { width: 100%; }
  }
  
  /* Controls */
  #controls {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
  }
  
  #controls button {
    padding: 0.75rem 1.5rem;
    font-size: 1.1rem;
    cursor: pointer;
    background: linear-gradient(135deg, #3498db, #2980b9);
    color: white;
    border: none;
    border-radius: 25px;
    box-shadow: 0 3px 10px rgba(0,0,0,0.2);
    transition: all 0.3s ease;
    font-weight: 600;
  }
  
  #controls button:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
    background: linear-gradient(135deg, #2980b9, #21618c);
  }
  
  #controls button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
  }
  
  #feedback {
    text-align: center;
    padding: 0.5rem;
    background: rgba(255,255,255,0.9);
    border-radius: 10px;
    margin-top: 0.5rem;
    min-width: 400px;
  }
  
  #feedback p {
    margin: 0.25rem 0;
    font-size: 1rem;
    line-height: 1.4;
  }
  
  #resultText {
    font-weight: 500;
    animation: fadeIn 0.5s ease-out;
  }
  
  #scoreText {
    font-weight: bold;
    color: #2c3e50;
    animation: fadeIn 0.7s ease-out;
  }
  
  @keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
  }
  
  footer {
    background: linear-gradient(135deg, #2c3e50 0%, #3498db 100%);
    color: white;
    text-align: center;
    padding: 1rem;
    font-size: 1rem;
    box-shadow: 0 -2px 10px rgba(0,0,0,0.2);
  }
  
