/* --- Menu Bar (Common Style) --- */
#menu-container {
    position: fixed; /* 画面に固定 */
    top: 15px;
    right: 20px;
    z-index: 1000; /* ゲームUIより手前に表示 */
    cursor: pointer;
}

#menu-icon {
    width: 30px;
    height: 25px;
    position: relative;
    transition: transform 0.3s ease;
}

#menu-icon span {
    display: block;
    position: absolute;
    height: 3px;
    width: 100%;
    background: #0f0;
    border-radius: 3px;
    opacity: 1;
    left: 0;
    transition: all 0.25s ease-in-out;
}

/* メニューが開いている時のアイコンの変化（X印にするアニメーション） */
#menu-icon span:nth-child(1) { top: 0px; }
#menu-icon span:nth-child(2) { top: 10px; }
#menu-icon span:nth-child(3) { top: 20px; }

#menu-container.open #menu-icon span:nth-child(1) {
    top: 10px;
    transform: rotate(135deg);
}

#menu-container.open #menu-icon span:nth-child(2) {
    opacity: 0;
    left: -30px;
}

#menu-container.open #menu-icon span:nth-child(3) {
    top: 10px;
    transform: rotate(-135deg);
}

#menu-content {
    position: absolute;
    top: 40px;
    right: 0;
    background-color: rgba(0, 0, 0, 0.9);
    border: 1px solid #0f0;
    border-radius: 5px;
    padding: 10px 20px;
    box-shadow: 0 0 15px rgba(0, 255, 0, 0.5);
}

#menu-content.hidden {
    display: none;
}

#menu-content ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

#menu-content li {
    margin: 10px 0;
}

#menu-content a {
    color: #0f0;
    text-decoration: none;
    font-family: 'Press Start 2P', cursive;
    font-size: 0.8rem;
    transition: color 0.2s;
}

#menu-content a:hover {
    color: #fff;
    text-shadow: 0 0 5px #fff;
}