 body {
      font-family: 'Georgia', serif;
      background: #2C3E50 url('images/fence the paint/paint 1.jp') center/cover fixed;
      margin: 0;
      padding: 30px 10px;
      display: flex;
      flex-direction: column;
      align-items: center;
      min-height: 100vh;
      position: relative;
      padding: 15px 5px;
    }

    body::before {
      content: '';
      position: absolute;
      top: 0;
      left: 0;
      right: 0;
      bottom: 0;
      background: rgba(0, 0, 0, 0.7);
      z-index: 0;
    }

    #welcome-screen {
      background: linear-gradient(145deg, #2c3e50 0%, #3498db 100%);
      padding: 40px;
      border-radius: 20px;
      max-width: 700px;
      box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
      text-align: center;
      margin-top: 40px;
      color: white;
      position: relative;
      z-index: 1;
      border: 2px solid #3498db;
      animation: glow 2s infinite alternate;
      margin: 10px 5px;
      padding: 20px;
      width: calc(100% - 10px);
      max-width: 700px;
      box-sizing: border-box;

    }

    @keyframes glow {
      from { box-shadow: 0 0 20px rgba(52, 152, 219, 0.5); }
      to { box-shadow: 0 0 30px rgba(52, 152, 219, 0.8); }
    }

    .game-container {
      display: none;
      background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%);
      padding: 30px;
      max-width: 700px;
      border-radius: 20px;
      box-shadow: 0 15px 30px rgba(0, 0, 0, 0.4);
      width: 100%;
      color: white;
      position: relative;
      z-index: 1;
      border: 2px solid #3498db;
      margin: 10px 5px;
      padding: 15px;
      width: calc(100% - 10px);
      box-sizing: border-box;
      
    }

    #story-img {
      width: 100%;
      max-height: 400px;
      object-fit: cover;
      border-radius: 15px;
      margin-bottom: 25px;
      box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
      transition: transform 0.3s ease;
    }

    #story-img:hover {
      transform: scale(1.02);
    }

    .choice-btn {
      display: block;
      margin: 15px auto;
      padding: 15px 25px;
      background: linear-gradient(to right, #3498db, #2980b9);
      color: white;
      border: none;
      border-radius: 10px;
      font-size: 1.1rem;
      cursor: pointer;
      width: 85%;
      max-width: 350px;
      transition: all 0.3s ease;
      text-transform: uppercase;
      letter-spacing: 1px;
      position: relative;
      overflow: hidden;
      width: 100%;
      max-width: 300px;
      margin: 10px auto;
    }

    .choice-btn:hover {
      transform: translateY(-2px);
      box-shadow: 0 5px 15px rgba(52, 152, 219, 0.4);
      background: linear-gradient(to right, #2980b9, #3498db);
    }

    .choice-btn:active {
      transform: translateY(1px);
    }

    #top-bar {
      display: none;
      justify-content: space-between;
      width: 100%;
      max-width: 700px;
      margin-bottom: 20px;
      font-weight: bold;
      font-size: 1.2rem;
      background: rgba(52, 152, 219, 0.2);
      padding: 15px 25px;
      border-radius: 15px;
      backdrop-filter: blur(5px);
      color: rgb(255, 255, 255);
      z-index: 1;
      position: relative;
      margin: 10px 5px;
      padding: 10px 15px;
      width: calc(100% - 10px);
      box-sizing: border-box;
    }
    

    .control-btn {
      padding: 12px 20px;
      font-size: 1rem;
      background: linear-gradient(to right, #e74c3c, #c0392b);
      color: white;
      border: none;
      border-radius: 8px;
      cursor: pointer;
      transition: all 0.3s ease;
      text-transform: uppercase;
      letter-spacing: 1px;
      gap: 5px;
      position: relative;
      z-index: 1;
    }

    .control-btn:hover {
      transform: translateY(-2px);
      box-shadow: 0 5px 15px rgba(231, 76, 60, 0.4);
    }

    .small-btn {
      padding: 12px 25px;
      font-size: 1.1rem;
      background: linear-gradient(to right, #2ecc71, #27ae60);
      color: white;
      border: none;
      border-radius: 10px;
      cursor: pointer;
      transition: all 0.3s ease;
      text-transform: uppercase;
      letter-spacing: 1px;
      margin-top: 20px;
    }

    .small-btn:hover {
      transform: translateY(-2px);
      box-shadow: 0 5px 15px rgba(46, 204, 113, 0.4);
    }
    @media screen and (max-width: 480px) {
      body {
        padding: 10px 0;
      }
      
      #story {
        font-size: 1rem;
        padding: 0 10px;
      }

      .choice-btn {
        font-size: 0.9rem;
        padding: 12px 15px;
      }

      .control-btn {
        padding: 8px 12px;
        font-size: 0.9rem;
      }
    }
    #controls{
      gap: 20px;
      width: 300px;
      display: flex;
      margin-top: 30px;
    }
    #welcome-screen label {
  font-size: 1.2rem;
  font-weight: bold;
  color: #fff;
  display: block;
  margin-bottom: 8px;
  text-shadow: 1px 1px 2px #000;
}

#welcome-screen input#playerName {
  width: 80%;
  max-width: 400px;
  padding: 10px 15px;
  font-size: 1rem;
  border-radius: 10px;
  border: none;
  outline: none;
  margin-bottom: 20px;
  background-color: #f0f0f0;
  box-shadow: 0 0 10px rgba(0,0,0,0.2);
  transition: box-shadow 0.3s ease;
}

#welcome-screen input#playerName:focus {
  box-shadow: 0 0 12px rgba(0, 128, 255, 0.6);
}
#welcome-screen button#start-game {
  padding: 12px 25px;
  font-size: 1rem;
  border-radius: 10px;
  background-color: #28a745;
  color: white;
  border: none;
  cursor: pointer;
  font-weight: bold;
  transition: background-color 0.3s ease, transform 0.2s ease;
}

#welcome-screen button#start-game:disabled {
  background-color: #aaa;
  cursor: not-allowed;
}

#welcome-screen button#start-game:hover:enabled {
  background-color: #218838;
  transform: scale(1.05);
}
#name-input-wrapper {
  padding: 20px;
  border-radius: 15px;
  display: inline-block;
  text-align: left;
  margin-bottom: 20px;
  z-index: 1;
}
#playerName{
  background-color: #ffffff;
  color: rgb(0, 0, 0);
  padding: 20px;
  border-radius: 20px;
  text-align: center;
  font-size: larger;
  font-weight: bolder;
  animation: neon-glow 1.5s infinite alternate;
}
 @keyframes neon-glow {
            0% { box-shadow: 0px 0px 10px rgb(255, 0, 0); }
            100% { box-shadow: 0px 0px 25px rgb(255, 0, 247); }
        }

    .winning-screen {
      display: none;
      position: fixed;
      top: 50%;
      left: 50%;
      transform: translate(-50%, -50%);
      background: linear-gradient(145deg, #2c3e50 0%, #3498db 100%);
      padding: 40px;
      border-radius: 20px;
      text-align: center;
      color: white;
      box-shadow: 0 0 50px rgba(52, 152, 219, 0.5);
      animation: fadeIn 0.5s ease-out;
      z-index: 1000;
      border: 3px solid #f1c40f;
    }

    .trophy {
      font-size: 80px;
      margin-bottom: 20px;
      animation: bounce 1s infinite;
    }

    @keyframes bounce {
      0%, 100% { transform: translateY(0); }
      50% { transform: translateY(-20px); }
    }

    @keyframes fadeIn {
      from { opacity: 0; transform: translate(-50%, -50%) scale(0.9); }
      to { opacity: 1; transform: translate(-50%, -50%) scale(1); }
    }

    .player-stats {
      margin: 20px 0;
      font-size: 1.2em;
    }

    .final-score {
      font-size: 1.5em;
      color: #f1c40f;
      margin: 15px 0;
      text-shadow: 0 0 10px rgba(241, 196, 15, 0.5);
    }

    .replay-btn {
      padding: 15px 30px;
      font-size: 1.2em;
      background: linear-gradient(to right, #2ecc71, #27ae60);
      color: white;
      border: none;
      border-radius: 10px;
      cursor: pointer;
      transition: all 0.3s ease;
      text-transform: uppercase;
      letter-spacing: 1px;
      margin-top: 20px;
    }

    .replay-btn:hover {
      transform: translateY(-2px);
      box-shadow: 0 5px 15px rgba(46, 204, 113, 0.4);
    }
    .custom-alert {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0, 0, 0, 0.6);
  display: none;
  justify-content: center;
  align-items: center;
  z-index: 9999;
}

.custom-alert-box {
  background: white;
  color: black;
  padding: 20px 30px;
  border-radius: 15px;
  text-align: center;
  box-shadow: 0 0 20px rgba(255, 255, 255, 0.3);
  font-size: 1.1rem;
}
.custom-alert-box button {
  margin-top: 15px;
  padding: 8px 20px;
  background: #3498db;
  border: none;
  color: white;
  font-weight: bold;
  border-radius: 6px;
  cursor: pointer;
}

