* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  }
  
  body {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    background-color: #f5f5f5;
    color: #333;
    padding: 20px;
  }
  
  .game-container {
    width: 100%;
    max-width: 600px;
    background-color: white;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    padding: 30px;
    text-align: center;
    min-height: 550px; /* Ensures consistent container height */
    display: flex;
    flex-direction: column;
  }
  
  .letter-of-day {
    font-size: 48px;
    font-weight: bold;
    color: #4a6fa5;
    margin-bottom: 20px;
  }
  
  .word-display {
    font-size: 32px;
    margin: 30px 0;
    height: 60px;
    min-height: 60px; /* Ensures consistent height */
    display: flex;
    justify-content: center;
    align-items: center;
  }
  
  .blank {
    display: inline-block;
    width: 30px;
    height: 40px;
    border-bottom: 3px solid #4a6fa5;
    margin: 0 2px;
    vertical-align: bottom;
  }
  
  .timer-bar {
    width: 100%;
    height: 10px;
    background-color: #e0e0e0;
    border-radius: 5px;
    overflow: hidden;
    margin: 20px 0;
  }
  
  .timer-progress {
    height: 100%;
    background-color: #4a6fa5;
    width: 100%;
    transition: width linear;
  }
  
  .current-guess {
    font-size: 36px;
    width: 60px;
    height: 60px;
    text-align: center;
    border: 2px solid #4a6fa5;
    border-radius: 5px;
    margin: 20px auto;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #f8f8f8;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  }
  
  .submit-btn {
    font-size: 18px;
    padding: 10px 20px;
    background-color: #4a6fa5;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.2s;
  }
  
  .submit-btn:hover {
    background-color: #3a5f95;
  }
  
  .submit-btn:disabled {
    background-color: #cccccc;
    cursor: not-allowed;
  }
  
  .result-container {
    margin-top: 30px;
    display: none;
  }
  
  .final-word-container {
    margin-top: 20px;
  }
  
  .final-word-guess {
    font-size: 24px;
    padding: 10px;
    width: 200px;
    text-align: center;
    border: 2px solid #4a6fa5;
    border-radius: 5px;
    margin-right: 10px;
  }
  
  .message {
    margin-top: 20px;
    font-size: 20px;
    font-weight: bold;
    height: 30px; /* Fixed height to prevent layout shifts */
    display: flex;
    align-items: center;
    justify-content: center;
  }
  
  .correct {
    color: #4caf50;
  }
  
  .incorrect-flash {
    animation: flash 0.3s;
  }
  
  @keyframes flash {
    0% { background-color: #f8f8f8; }
    50% { background-color: #ffdddd; }
    100% { background-color: #f8f8f8; }
  }
  
  .hidden {
    display: none;
  }
  
  .restart-btn {
    margin-top: 20px;
    font-size: 18px;
    padding: 10px 20px;
    background-color: #6a8fc5;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
  }
  
  .word-counter {
    font-size: 16px;
    color: #777;
    margin-bottom: 10px;
  }
  
  #startPhase h2 {
    text-align: center;
    margin-bottom: 25px;
    color: #4a6fa5;
    font-size: 28px;
  }
  
  .instructions-container {
    max-width: 450px;
    margin: 0 auto;
    text-align: left;
  }
  
  #startPhase .instructions {
    list-style-type: none;
    padding: 0;
    margin-bottom: 30px;
  }
  
  #startPhase .instructions li {
    padding: 10px 0;
    position: relative;
    padding-left: 30px;
    line-height: 1.4;
    margin-bottom: 8px;
  }
  
  #startPhase .instructions li:before {
    content: "•";
    color: #4a6fa5;
    font-size: 24px;
    position: absolute;
    left: 10px;
    top: 6px;
  }
  
  .start-button-container {
    text-align: center;
    margin-top: 20px;
  }
  
  .hint {
    text-align: center;
    font-size: 14px;
    color: #666;
    margin-top: 10px;
  }