body {
    font-family: 'Courier New', Courier, monospace;
    background: linear-gradient(to bottom, #1a1a1a, #444);
    color: white;
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    overflow: hidden;
  }
  
  .container {
    text-align: center;
    background: rgba(0, 0, 0, 0.8);
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.5);
    width: 80%;
    max-width: 640px;
  }

  .description-box {
    display: inline-block;
    width: 90%;
    padding: 5px;
    font-size: 0.9rem;
    margin-bottom: 15px;
    border-radius: 5px;
    color: #7f8c8d;
    line-height: 1.6;
    border-left: 4px solid #3498db;
    font-style: italic;
    white-space: pre-wrap;
    text-align: left;
}

  .example-box {
    display: inline-block;
    width: 90%;
    padding: 10px;
    font-size: 1.2rem;
    margin-bottom: 10px;
    background-color: #2c3e50;
    border-radius: 5px;
    color: #ecf0f1;
    white-space: pre-wrap;
    text-align: left;
    font-family: monospace;
  }

  #user-input {
    width: 90%;
    padding: 10px;
    font-size: 1.2rem;
    margin-bottom: 20px;
    border: none;
    border-bottom: 2px solid #f1c40f;
    background: transparent;
    color: white;
    outline: none;
    font-family: monospace;
  }
  
  #result{
    margin-top: 20px;
    font-size: 1.2rem;
    font-weight: bold;
    min-height: 1.5em;
  }
    
  button {
    padding: 10px 20px;
    font-size: 1.2rem;
    color: white;
    background-color: #27ae60;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    margin: 10px;
  }
  
  button:hover {
    background-color: #2ecc71;
  }

  .hidden {
    display: none !important;
  }
  
  .modal {
    background: #2c3e50;
    color: #ecf0f1;
    padding: 20px;
    border-radius: 10px;
    width: 80%;
    max-width: 720px;
    text-align: center;
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.5);
    aspect-ratio: 16 / 9;
  }

  #mainMenuModal, #startModal, #resultModal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
  }

  .title {
    height: 70%; /* タイトル部分の高さ */
    display: flex;
    align-items: center; 
    justify-content: center;
    margin-bottom: 20px;
  }

  .title h1 {
    margin: 0;
    font-size: 2.5rem;
  }
  
  .menu-buttons {
    display: flex;
    flex-direction: row; 
    justify-content: center; 
    align-items: center;
    gap: 48px; 
  }
  
  #mainMenuModal button {
    margin: 10px;
    width: 240px; /* 必要に応じて調整 */
  }

  #mainMenuModal button:hover {
    background-color: #0056b3;
  }

  #startModal .header {
    height: 25%; 
    display: flex;
    align-items: center; 
    justify-content: center;
  }

  .category-btn {
    background: #007bff;
  }
  
  .category-btn:hover {
    background: #0056b3;
  }

  #resultModal .header {
    height: 25%; 
    display: flex;
    align-items: center; 
    justify-content: center;
  }

  #resultModal .content {
    height: 50%; 
    display: flex;
    flex-direction: column;
    align-items: center; 
    justify-content: center;
  }

  #resultModal .result-buttons {
    height: 25%; 
    display: flex;
    align-items: center; 
    justify-content: center;
    gap: 32px;
  }

  @keyframes shake {
    0%, 100% { transform: translateX(0); }
    10%, 30%, 50%, 70%, 90% { transform: translateX(-10px); }
    20%, 40%, 60%, 80% { transform: translateX(10px); }
  }

  .error-shake {
    animation: shake 0.5s;
    border: 2px solid red;
    background-color: rgba(255, 0, 0, 0.1);
  }

  .music-control {
    position: absolute;
    bottom: 10px;
    right: 20px;
    background: rgba(0,0,0,0.5);
    color: white;
    padding: 10px;
    border-radius: 5px;
    display: flex;
    align-items: center;
    z-index: 2000; 
  }

  .music-toggle {
    cursor: pointer;
  }

  .volume-slider {
    width: 100px;
    margin-left: 10px;
  }