/* General Body and Text Styles */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    text-align: center;
    background-color: #f0f0f0;
    margin: 0;
    padding: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    min-height: 100vh;
    box-sizing: border-box;
    transition: background-color 0.3s ease;
}

h1 {
    color: #333;
    margin-bottom: 10px;
    font-size: 2.5em;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.1);
}

h2 {
    color: #555;
    margin-bottom: 10px;
    font-size: 1.2em;
}

h3 {
    color: #777;
    margin-bottom: 20px;
}

/* Main Game Container - The Simon Board */
.btn-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-content: center;
    width: 480px;
    height: 480px;
    margin: 20px auto;
    border: 20px solid #222;
    border-radius: 50%;
    background-color: #333;
    box-shadow: 0 0 30px rgba(0, 0, 0, 0.6),
                inset 0 0 15px rgba(0, 0, 0, 0.4);
    padding: 10px;
    position: relative;
}

/* Individual Button Styles */
.btn {
    height: 200px;
    width: 200px;
    border-radius: 50%;
    border: 8px solid rgba(0, 0, 0, 0.6);
    margin: 10px;
    box-sizing: border-box;
    cursor: pointer;
    transition: background-color 0.1s ease-out, box-shadow 0.1s ease-out, transform 0.2s ease;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 2.5em;
    color: rgba(255, 255, 255, 0.1);
    user-select: none;
}

/* Hover Interaction */
.btn:hover {
    filter: brightness(1.2);
    transform: scale(1.05);
    transition: 0.2s;
}

/* Specific Button Colors */
.red {
    background-color: #CC0000;
}
.yellow {
    background-color: #FFC000;
}
.green {
    background-color: #008000;
}
.blue {
    background-color: #0000CC;
}

/* Flash Effects */
.flash {
    background-color: white !important;
    box-shadow: 0 0 30px 10px rgba(255, 255, 255, 0.8);
    transition: background-color 0.05s ease-out, box-shadow 0.05s ease-out;
}

.userFlash {
    background-color: #888 !important;
    box-shadow: 0 0 20px 5px rgba(136, 136, 136, 0.6);
    transition: background-color 0.05s ease-out, box-shadow 0.05s ease-out;
}

/* Game Over Effect */
body.game-over {
    background-color: #ffcccc;
}

/* Start and Retry Buttons */
#startBtn, #retryBtn {
    padding: 10px 20px;
    font-size: 1.1em;
    background-color: #333;
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    margin: 10px 5px;
    transition: background-color 0.3s ease;
}

#startBtn:hover, #retryBtn:hover {
    background-color: #555;
}

/* High Score Animation */
#highScore.highlight {
    color: #1abc9c;
    animation: pop 0.4s ease;
}

@keyframes pop {
    0% { transform: scale(1); }
    50% { transform: scale(1.3); }
    100% { transform: scale(1); }
}

/* Layout Fix for Inner Rows */
.line-one, .line-two {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
}

.footer {
  text-align: center;
  padding: 15px 0;
  background-color: #3f3a3a;
  color: #fff;
  font-family: 'Arial', sans-serif;
  font-size: 0.95rem;
  position: relative;
  bottom: 0;
  left: 0;
  width: 102%;
  box-shadow: 0 -1px 5px rgba(0, 0, 0, 0.2);
  z-index: 10;
}

.footer strong {
  color: #ffb400;
}

/* How to Play Button */
.how-to-play-btn {
  padding: 10px 20px;
  font-size: 1em;
  background-color: #444;
  color: #fff;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  margin: 10px;
  transition: background-color 0.3s ease;
}
.how-to-play-btn:hover {
  background-color: #666;
}

/* Modal Background */
.modal {
  display: none;
  position: fixed;
  z-index: 999;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0, 0, 0, 0.6);
}

/* Modal Content */
.modal-content {
  background-color: #fff;
  margin: 10% auto;
  padding: 20px;
  border-radius: 10px;
  width: 80%;
  max-width: 500px;
  box-shadow: 0 0 12px rgba(0,0,0,0.2);
  position: relative;
  font-family: 'Segoe UI', sans-serif;
  text-align: left;
}

/* Close Button */
.close {
  color: #aaa;
  position: absolute;
  top: 10px;
  right: 20px;
  font-size: 28px;
  font-weight: bold;
  cursor: pointer;
}
.close:hover,
.close:focus {
  color: #000;
}

/* Footer icon spacing */
.footer i {
  margin-left: 5px;
}


