body {
    background: radial-gradient(circle at bottom, navy 0, black 100%);
    height: 100vh;
    overflow: hidden;
    font-family: 'Arial', sans-serif; 
}

#score {
    font-size: 1.5rem;
    color: white;
    text-align: center;
}

.header {
    font-size: 2rem;
    color: white;
    text-align: center;
    color: #fff;
    border-radius: 10px;
    margin-bottom: 10px;

    text-shadow:
        0 0 7px #fff,
        0 0 10px #fff,
        0 0 21px #fff,
        0 0 42px navy,
        0 0 82px navy,
        0 0 92px navy,
        0 0 102px navy,
        0 0 151px navy;
        animation: flicker 1.5s infinite alternate;
  }

  .header2 {
    color: white;
    text-align: center;
  }


.grid-container{
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
    width: 60%; /* Adjusted width for better responsiveness */
    max-width: 600px;
    margin: auto;
}

.grid-cell {
    width: 100%;
    height: 130px;
    background-color: white;
    border-radius: 5px;
    font-size: 1.5em; /* Adjusted font size */
    display: flex;
    align-items: center;
    justify-content: center;
}


.hidden-cell {
  color: transparent; /* Hide the text content */
}

.how {
    margin-top: 2rem;
    font-size: 1rem;
    color: white;
    text-align: center;

}

.space {
    background: rgba(128, 0, 128, 0.1) center / 200px 200px round;
    border: 1px  purple;
    bottom: 0;
    left: 0;
    position: absolute;
    right: 0;
    top: 0;
}


@keyframes flicker {
    0%, 18%, 22%, 25%, 53%, 57%, 100% {
      text-shadow:
        0 0 4px #fff,
        0 0 11px #fff,
        0 0 19px #fff,
        0 0 40px navy,
        0 0 80px navy,
        0 0 90px navy,
        0 0 100px navy,
        0 0 150px navy;
    }
    20%, 24%, 55% {       
      text-shadow: none;
    }
  }

  .fade-in {
    animation: fadeIn 0.5s ease-in-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
  }


/* ---------------------phone screens----------------- */
@media screen and (max-width: 600px) {

  body {
    background: radial-gradient(circle at bottom, navy 0, black 100%);
    height: 100vh;
    overflow: hidden;
    font-size: 16px; /* Added font size for better readability on mobile */
  }
  
  #score {
    font-size: 1.5rem;
    color: white; /* Set the text color for better visibility */
  }
  
  .header {
    font-size: 4em; /* Reduced font size for better fit on smaller screens */
    color: white;
    text-align: center;
    border-radius: 10px;
    text-shadow:
    0 0 7px #fff,
    0 0 10px #fff,
    0 0 21px #fff,
    0 0 42px navy,
    0 0 82px navy,
    0 0 92px navy,
    0 0 102px navy,
    0 0 151px navy;
    animation: flicker 1.5s infinite alternate;
  }
  
  .header2 {
    color: white;
    text-align: center;
  }
  
  .grid-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(20%, 1fr));
    gap: 10px;
    width: 100%; /* Make the grid container 100% width for better responsiveness */
    max-width: 600px; /* Set a max width to avoid stretching on larger screens */
    margin: auto;
  }
  
  .grid-cell {
    width: 100%; /* Make the grid cells 100% width for better responsiveness */
    height: 100px;
    background-color: white;
    border: 1px solid #560bad; /* Corrected border-style and border-color */
    text-align: center;
    font-size: 3em; /* Adjusted font size for better fit */
    border-radius: 10px;
  }
  
  .hidden-cell {
    color: transparent;
  }
  
  .space {
    background: rgba(128, 0, 128, 0.1) center / 200px 200px round;
    border: 1px solid purple; /* Corrected border property */
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
  }
  
}